What It Means to Be Stationary
A Markov model describes how a probability distribution over states changes from one step to the next. A stationary distribution is a distribution that does not change under this update. Finding one means solving a fixed-point equation, while interpreting one requires care: a distribution can be stationary without every starting distribution converging to it.
We use the column-vector convention for a finite model with \(n\) states. A state distribution is a column \(\mathbf{x}\in\mathbb{R}^n\) whose entries are nonnegative and sum to \(1\). The transition matrix \(\mathbf{P}\in\mathbb{R}^{n\times n}\) is column-stochastic: its entries are nonnegative, and the entries in each column sum to \(1\). Thus \(p_{ij}\) is the probability of moving to state \(i\) from state \(j\). If the current distribution is \(\mathbf{x}\), then the next distribution is \(\mathbf{P}\mathbf{x}\).
The equation \(\mathbf{P}\boldsymbol{\pi}=\boldsymbol{\pi}\) is homogeneous when written as \((\mathbf{P}-\mathbf{I}_n)\boldsymbol{\pi}=\mathbf{0}\). That equation alone is not enough: it admits the zero vector, which is not a probability distribution, and any nonzero solution can be rescaled. The sum-to-one constraint selects the required scale, while nonnegativity must also be checked.
Proof. If \(\boldsymbol{\pi}\) is stationary, its defining conditions give all three stated conditions. Conversely, if a vector satisfies them, then \((\mathbf{P}-\mathbf{I}_n)\boldsymbol{\pi}=\mathbf{0}\) rearranges to \(\mathbf{P}\boldsymbol{\pi}=\boldsymbol{\pi}\), and the other two conditions say it is a probability distribution. Hence it is stationary. \(\square\)
Setting Up the Linear System
For each state, the corresponding equation in \(\mathbf{P}\boldsymbol{\pi}=\boldsymbol{\pi}\) balances the probability flowing into that state against the probability already assigned to it. In components, the \(i\)th equation is \(\sum_{j=1}^n p_{ij}\pi_j=\pi_i\). These equations are not all independent. Since the columns of \(\mathbf{P}\) sum to \(1\), the entries of \(\mathbf{P}\boldsymbol{\pi}\) sum to the entries of \(\boldsymbol{\pi}\). Consequently, summing all \(n\) equations in \((\mathbf{P}-\mathbf{I}_n)\boldsymbol{\pi}=\mathbf{0}\) gives \(0=0\). A system may therefore have a redundant equation; this does not remove the need to impose \(\sum_i\pi_i=1\).
Worked Example: A Two-State Model
Suppose the transition matrix is \(\mathbf{P}=\begin{bmatrix}\tfrac34&\tfrac14\\[2pt]\tfrac14&\tfrac34\end{bmatrix}\). Each column sums to \(1\). Find its stationary distribution.
Write \(\boldsymbol{\pi}=(\pi_1,\pi_2)^\top\). The fixed-point equations and the normalization condition are
The first equation gives \(\tfrac14\pi_2=\tfrac14\pi_1\), so \(\pi_2=\pi_1\). The second gives the same relation: \(\tfrac14\pi_1=\tfrac14\pi_2\). Substituting \(\pi_2=\pi_1\) into the sum condition gives \(2\pi_1=1\), hence \(\pi_1=\tfrac12\) and \(\pi_2=\tfrac12\).
Check:
Both entries are nonnegative and sum to \(1\), so this is a stationary distribution.
Solving a Three-State System
Worked Example: Following the Flow Between Three States
Consider the column-stochastic matrix
The columns sum to \(1\): their sums are \(\tfrac12+\tfrac12+0=1\), \(0+\tfrac12+\tfrac12=1\), and \(1+0+0=1\). Find a stationary distribution.
Let \(\boldsymbol{\pi}=(\pi_1,\pi_2,\pi_3)^\top\). The fixed-point equations are
From the second equation, \(\tfrac12\pi_1=\tfrac12\pi_2\), so \(\pi_2=\pi_1\). The third gives \(\pi_3=\tfrac12\pi_2=\tfrac12\pi_1\). The first equation is then satisfied because \(\tfrac12\pi_1+\tfrac12\pi_1=\pi_1\). Applying the sum condition gives
Therefore \(\pi_2=\tfrac25\), \(\pi_3=\tfrac15\), and \(\boldsymbol{\pi}=(\tfrac25,\tfrac25,\tfrac15)^\top\). All entries are nonnegative and their sum is \(\tfrac25+\tfrac25+\tfrac15=1\).
Check:
For a larger system, the same equations can be organized as one linear system. The matrix \(\mathbf{P}-\mathbf{I}_n\) has rows that sum to zero as a collection: because \(\mathbf{P}\) is column-stochastic, \(\mathbf{1}^{\top}(\mathbf{P}-\mathbf{I}_n)=\mathbf{0}^{\top}\), where \(\mathbf{1}\) is the column of \(n\) ones. Thus the sum of the rows of \(\mathbf{P}-\mathbf{I}_n\) is the zero row. One fixed-point equation is redundant. Keep a sufficient set of the fixed-point equations, add the normalization equation, solve, and then check every original equation and the probability conditions.
Existence and Long-Run Interpretation
Proof. Start with any probability distribution \(\mathbf{x}_0\), for example a standard basis vector. Define \(\mathbf{x}_{k+1}=\mathbf{P}\mathbf{x}_k\). Each \(\mathbf{x}_k\) remains a probability distribution: nonnegativity follows from multiplying a nonnegative matrix by a nonnegative vector, and the sum of the entries is preserved because \(\mathbf{1}^{\top}\mathbf{P}=\mathbf{1}^{\top}\). For each positive integer \(N\), form the average \(\mathbf{q}_N=\frac1N\sum_{k=0}^{N-1}\mathbf{x}_k\). Its entries are nonnegative and sum to \(1\), so the sequence \((\mathbf{q}_N)\) is bounded in \(\mathbb{R}^n\). By the Bolzano–Weierstrass theorem, a bounded sequence in finite-dimensional real space has a convergent subsequence; write its limit as \(\boldsymbol{\pi}\). Limits preserve nonnegativity and the finite sum, so \(\boldsymbol{\pi}\) is a probability distribution. Also, by cancellation of consecutive terms, \(\mathbf{P}\mathbf{q}_N-\mathbf{q}_N=(\mathbf{x}_N-\mathbf{x}_0)/N\). Each coordinate of \(\mathbf{x}_N-\mathbf{x}_0\) lies between \(-1\) and \(1\), so the right-hand side tends to \(\mathbf{0}\). Along the convergent subsequence, matrix multiplication by the fixed matrix \(\mathbf{P}\) preserves limits. Taking limits gives \(\mathbf{P}\boldsymbol{\pi}-\boldsymbol{\pi}=\mathbf{0}\). Therefore \(\boldsymbol{\pi}\) is stationary. \(\square\)
This existence result does not say that the stationary distribution is unique, or that the distributions \(\mathbf{x}_k\) from every starting state converge to one. A stationary distribution is invariant: if \(\mathbf{x}_0=\boldsymbol{\pi}\), then \(\mathbf{x}_1=\mathbf{P}\boldsymbol{\pi}=\boldsymbol{\pi}\), and repeated updates leave it unchanged. More generally, if the sequence \(\mathbf{x}_k\) does converge to a limit \(\mathbf{x}\), then \(\mathbf{x}\) must be stationary: \(\mathbf{x}_{k+1}=\mathbf{P}\mathbf{x}_k\), and taking limits gives \(\mathbf{x}=\mathbf{P}\mathbf{x}\). The reverse implication does not follow just from stationarity.
Worked Example: Stationarity Does Not Ensure Convergence
Consider the two-state transition matrix that swaps the states:
The fixed-point equations are \(\pi_2=\pi_1\) and \(\pi_1=\pi_2\). With \(\pi_1+\pi_2=1\), the stationary distribution is \(\boldsymbol{\pi}=(\tfrac12,\tfrac12)^\top\). Direct multiplication checks it:
But if the initial distribution is \(\mathbf{x}_0=(1,0)^\top\), then \(\mathbf{x}_1=(0,1)^\top\), \(\mathbf{x}_2=(1,0)^\top\), and the distributions continue alternating. They do not converge. The stationary distribution is still meaningful as an invariant distribution, but it is not the limit of this sequence of state distributions.
Common Pitfall: Mixing Up Row and Column Conventions
With the convention used here, state distributions are columns and are updated by \(\mathbf{x}_{k+1}=\mathbf{P}\mathbf{x}_k\). A common error is to solve \(\mathbf{P}\mathbf{q}=\mathbf{q}\) using a row vector, or to multiply a row vector on the right without changing the fixed-point equation. These choices describe a different convention and can produce the wrong answer.
For the three-state matrix above, solving \(\mathbf{q}\mathbf{P}=\mathbf{q}\) as though distributions were rows gives \(\mathbf{q}=(\tfrac13,\tfrac13,\tfrac13)\). This is not stationary under the column convention: multiplying the column \((\tfrac13,\tfrac13,\tfrac13)^\top\) by \(\mathbf{P}\) gives \((\tfrac12,\tfrac13,\tfrac16)^\top\), not \((\tfrac13,\tfrac13,\tfrac13)^\top\). The correction is to use the state-vector convention consistently and solve \(\mathbf{P}\boldsymbol{\pi}=\boldsymbol{\pi}\), which gives \((\tfrac25,\tfrac25,\tfrac15)^\top\).
Another error is to stop after finding a nonzero solution of the homogeneous equations. For instance, a scalar multiple of a stationary vector still solves \((\mathbf{P}-\mathbf{I}_n)\boldsymbol{\pi}=\mathbf{0}\), but it is a probability distribution only when its entries are nonnegative and sum to \(1\). Always impose the normalization condition and check the result in the original fixed-point equation.
Check Your Understanding
For each problem, use the column-vector convention and check any proposed distribution against the fixed-point equation.
- For \(\mathbf{P}=\begin{bmatrix}\tfrac12&\tfrac12\\[2pt]\tfrac12&\tfrac12\end{bmatrix}\), find a stationary distribution and verify it.
- Explain why the equation \((\mathbf{P}-\mathbf{I}_n)\boldsymbol{\pi}=\mathbf{0}\) by itself does not identify a probability distribution.
- For the three-state matrix in the worked example, write the three component equations and identify a redundant one.
- Give a reason that a convergent sequence of state distributions under a fixed transition matrix must converge to a stationary distribution.
- For the state-swap matrix, describe what happens from the initial distribution \((0,1)^\top\), and compare it with the stationary distribution.