Stationary cycle occupation formula (source code)

= Stationary cycle occupation formula

For an irreducible positive-recurrent Markov chain with invariant distribution $\pi$, the expected number of visits to $j$ during one return cycle from $i$ to $i$ is
$$
\frac{\pi(j)}{\pi(i)}.
$$
Combining this with the two-state excursion visit law gives
$$
\frac{\mathbb P_i(T_j<T_i)}{\mathbb P_j(T_i<T_j)}
=\frac{\pi(j)}{\pi(i)}.
$$