Solution (source code)

= Solution

The number present is an <M-M-s queue>: births occur at rate $\lambda$, deaths at rate $\mu\min(n,s)$. Both rates are bounded, so the chain is nonexplosive. For $\lambda,\mu>0$ and an integer $s\geq1$, the detailed-balance weights with $\pi_0=1$ are
$$
\pi_n=\frac{(\lambda/\mu)^n}{n!}\quad(0\leq n\leq s),\qquad
\pi_n=\frac{(\lambda/\mu)^s}{s!}\left(\frac\lambda{s\mu}\right)^{n-s}\quad(n\geq s).
$$
Their sum is finite precisely when $\lambda<s\mu$, giving \b[positive recurrence] and a stationary <probability distribution> after normalization.

For completeness, the birth–death recurrence criterion is $\sum_{n\geq0}(\lambda_n\pi_n)^{-1}=\infty$. It follows by solving the harmonic hitting-probability recurrence: successive differences are proportional to $(\lambda_n\pi_n)^{-1}$, and divergence makes the probability of escaping to infinity before reaching zero vanish. The geometric tail of the weights makes this sum diverge when $\lambda\leq s\mu$ and converge when $\lambda>s\mu$. Thus \b[$\lambda=s\mu$ gives null recurrence], since the chain is recurrent but has no finite invariant normalization, and \b[$\lambda>s\mu$ gives transience]. The critical case is not positive recurrent merely because arrival and maximum service rates balance.