I was reading http://www.ams.org/bookstore/pspdf/mbk-58-prev.pdf and going through the first example for the frog jumping between the lily pads. I'm interested in find the steady-state probability for the fraction of time that the frog spends in the east lily pad.
Basically, given the transition matrix: $P = \left[\begin{array}{ccc} 1-p & p\\ q & 1-q\\ \end{array} \right]$
I want to find $\pi = \pi P$.
They get $\pi(e) = \frac{q}{q+p}$, which makes intuitive sense. However, no matter what I try I can't get a solution in terms of $p$ and $q$. They keep dropping out.
For example, I can view the formula above as an eigenvalue problem with $\lambda=1$, but the eigenvector I get is $(1,1)$ making $\pi(e)=1/2$.
This definitely satisfies $\pi(e) = \frac{q}{q+p}$ if $p=q=1/2$, but it's not a general solution.
I've seen this problem done before involving a geometric distribution, but I'm not entirely sure why the linear algebra approach is failing for me. Any ideas?
Make sure you calculate the correct eigenvector: $$\pi(P-I) = \pi\left[\begin{array}{ccc} -p & p\\ q & -q\\ \end{array} \right]=0$$ $$\implies \pi=\left[\begin{array}{ccc} \frac{q}{p+q} & \frac{p}{p+q} \end{array} \right]$$