# M/M/1 Queueing theory with change in rates

Consider a single-server exponential system in which customers arrive at a rate $\lambda$ and have a regular service rate $\mu$. When a customers arrives and the system is busy, the customer joins the queue. However, when the queue length reaches a given threshold, say N, the service rate is increased to $\alpha\mu. (\alpha>1)$

a) Give a condition on $\lambda, \mu, \alpha$ which guarantees that the system is stable. (i.e the queue length does not go to infinity).

b) Determine the long term expected queue length.

c) Determine the mean time spent in the system for an arriving customer.

• Welcome to Math.SE! Please show what you have done yourself to answer these questions. – Hrodelbert Jun 19 '15 at 12:02

The system is stable iff there exists an invariant measure $\nu$ for the embedded jump chain with $\sum_n \nu_n<\infty$. The global balance equations for this process are \begin{align} \lambda\nu_n &= \mu\nu_{n+1}, 0\leqslant n\leqslant N\\ \lambda\nu_n &= a\mu\nu_{n+1}, n>N, \end{align} and so $$\nu_n = \begin{cases} \left(\frac\lambda\mu\right)^n\nu_0,& n\leqslant N\\ \left(\frac\lambda\mu\right)^N\left(\frac\lambda{a\mu}\right)^{n-N}\nu_0,& n>N \end{cases}.$$ Since \begin{align} \sum_{n=0}^\infty \nu_n &= \nu_0\left(\sum_{n=0}^N\left(\frac\lambda\mu\right) + \sum_{n=N+1}^\infty\left(\frac\lambda\mu\right)^N\left(\frac\lambda{a\mu}\right)^{n-N} \right)\\ &=\nu_0\left(\frac{1-\left(\frac\lambda\mu\right)^{N+1}}{1-\frac\lambda\mu} +\left(\frac\lambda\mu\right)^N\sum_{n=1}^\infty \left(\frac\lambda{a\mu}\right)^n \right), \end{align} we see that the necessary condition is $\frac\lambda{a\mu}<1$.

From here we may compute the stationary distribution, mean queue length, and mean wait times as for a regular $M/M/1$ queue.

• In the interesting case of $\mu\le\lambda<a\mu$, you get two queues connected at $N$, with one of them being direction-reversed. This makes it easier to visualize what's happening and compute the values needed. – A.S. Feb 24 '16 at 0:56