Entropy production rate of a Markov chain (source code)

= Entropy production rate of a Markov chain

For a finite <Continuous-time Markov chain>, let $w_{ij}$ be the rate from $i$ to $j$, and let $P_i$ be its current state <probability>. Define forward traffic $a_{ij}=P_iw_{ij}$ and current $J_{ij}=a_{ij}-a_{ji}$. The total <entropy production>[entropy production rate], in dimensionless entropy units $k_B=1$ with <natural logarithm>[natural logarithms], is
$$
\dot S_{\rm tot}=\frac12\sum_{i\ne j}(a_{ij}-a_{ji})\log\frac{a_{ij}}{a_{ji}}\geq0.
$$
The factor $1/2$ avoids counting an unordered pair twice. The expression is the same as $\sum_{i\ne j}a_{ij}\log(a_{ij}/a_{ji})$ after pairing opposite directions.<Stochastic thermodynamics, fluctuation theorems, and molecular machines by Udo Seifert>[arXiv:1205.4176v1, Section 6.2.3, equation (128): ensemble entropy production]{ref}

Nonnegativity is elementary: for $a,b>0$, the signs of $a-b$ and $\log a-\log b$ agree. A pair with both flows zero contributes zero. If exactly one flow is positive, its contribution is $+\infty$, the corresponding one-sided limiting convention. The rate vanishes exactly when every pair has equal opposing traffic at that instant, which is <Detailed balance> for that <Probability distribution>.

For a stationary three-state cycle with clockwise rate $r>0$ and anticlockwise rate $\ell>0$, the stationary law is uniform. Each <graph edge>[edge] has current $(r-\ell)/3$, so $\dot S_{\rm tot}=(r-\ell)\log(r/\ell)$. It is zero at equal rates and positive otherwise, even though the state <probability>[probabilities] no longer change. <stationary distribution>[Stationarity] balances total flow at each state; it need not eliminate circulating currents.