Tutorials › Stochastic Processes › Arrival and Service Rates in the Birth-Death Model

The M/M/1 Queue · Tutorial 623 of 994

Arrival and Service Rates in the Birth-Death Model

Learn to translate M/M/1 arrival and service assumptions into the birth-death generator, including the special boundary behavior at zero.

Intermediate 10 min read

What You'll Learn

  • Define the queue-length process and its state space and filtration.
  • Derive the transition rates from independent exponential arrival and service clocks.
  • Construct the M/M/1 generator and check its row sums.
  • Determine holding times and the probabilities of upward and downward jumps.
  • Identify the boundary condition at an empty system and correct a common generator error.

From Queue Events to Transition Rates

In an M/M/1 queue, the state records how many customers are in the system, including any customer in service. Arrivals increase that count by one. A service completion decreases it by one only when the system is nonempty. Turning these event descriptions into transition rates gives a continuous-time birth-death model: births are arrivals, and deaths are service completions.

Assume throughout that the arrival rate \(\lambda\) and service rate \(\mu\) are finite and strictly positive. Arrivals form a Poisson process of rate \(\lambda\). Service times are independent exponential random variables of rate \(\mu\), independent of arrivals, and one customer is served at a time whenever the system is nonempty. The exponential memoryless property ensures that, conditional on the current queue length, the remaining service time of a customer in service is again exponential with rate \(\mu\).

Let \((\Omega,\mathcal F,\mathbb P)\) be a probability space supporting the arrival and service randomness, and let \((X_t)_{t\ge0}\) be the queue length at time \(t\). Its state space is \(S=\{0,1,2,\ldots\}\), and time is continuous. We use the filtration \((\mathcal F_t)_{t\ge0}\) generated by the queue history and the arrival and service information observed up to time \(t\). The memoryless and independence assumptions imply that, given \(X_t\), the future evolution has the same transition law as a new queue started in state \(X_t\).

Definition: For a continuous-time Markov chain, the transition rate from state \(i\) to a distinct state \(j\) is \(q_{ij}=\lim_{h\downarrow0}\mathbb P(X_{t+h}=j\mid X_t=i)/h\), when the limit exists. The generator \(Q=(q_{ij})\) has diagonal entries \(q_{ii}=-\sum_{j\ne i}q_{ij}\); thus each row sums to zero. For the M/M/1 queue, the only possible transitions from \(n\ge1\) are to \(n+1\) and \(n-1\), while from zero the only possible transition is to one.

The word “rate” describes the probability of a transition over a short interval: if the rate from \(i\) to \(j\) is \(r\), then the conditional transition probability over an interval of length \(h\) is \(rh+o(h)\) as \(h\downarrow0\). Here \(o(h)\) denotes a quantity whose ratio to \(h\) tends to zero. The transition rates are not themselves probabilities and need not sum to one. It is the generator row, including its negative diagonal entry, that sums to zero.

The Generator and the Boundary at Zero

Proposition: Under the M/M/1 assumptions above, the generator entries are \(q_{0,1}=\lambda,\ q_{0,0}=-\lambda\), and, for \(n\ge1\), \(q_{n,n+1}=\lambda,\ q_{n,n-1}=\mu,\ q_{n,n}=-(\lambda+\mu)\). Every other entry is zero.

Proof. Fix a state \(n\). If \(n=0\), an arrival is the only event that can change the queue length. The probability of an arrival during an interval of length \(h\) is \(1-e^{-\lambda h}=\lambda h+o(h)\), so \(q_{0,1}=\lambda\). There is no customer in service, hence no service completion can decrease the state. For \(n\ge1\), the time to the next arrival is exponential with rate \(\lambda\), and the time to the next service completion is exponential with rate \(\mu\); these times are independent. The probability of exactly one arrival and no service completion during an interval of length \(h\) is \(\lambda h e^{-(\lambda+\mu)h}=\lambda h+o(h)\). The probability of exactly one service completion and no arrival is \(\mu h e^{-(\lambda+\mu)h}=\mu h+o(h)\). The probability of two or more potential events in the interval is \(O(h^2)\), so it contributes zero after division by \(h\) and passage to the limit. Thus the upward and downward rates are \(\lambda\) and \(\mu\). A row of a generator sums to zero by its definition, so the diagonal entry is the negative of the sum of the rates to distinct states. No other state can be reached by a single event, so its rate is zero. \(\square\)

This calculation also explains the boundary condition. At a positive queue length, one arrival and one service completion are possible types of state-changing event. At zero, only an arrival is possible. The service rate \(\mu\) does not disappear from the model; rather, it is inactive when there is no customer to serve.

Result (holding time and jump direction): Starting from zero, the time until the next state change is exponential with rate \(\lambda\), and the next state is one. Starting from \(n\ge1\), the holding time is exponential with rate \(\lambda+\mu\). At the end of that holding time, the next state is \(n+1\) with probability \(\lambda/(\lambda+\mu)\) and \(n-1\) with probability \(\mu/(\lambda+\mu)\).

Proof. At zero, the next change occurs at the next arrival, whose waiting time is exponential with rate \(\lambda\), and that arrival moves the chain to one. At \(n\ge1\), let \(A\) and \(C\) be the independent waiting times to the next arrival and service completion. For \(s\ge0\), the chance that neither event occurs by time \(s\) is \(\mathbb P(A>s,C>s)=e^{-\lambda s}e^{-\mu s}=e^{-(\lambda+\mu)s}\). Thus the minimum of the two waiting times is exponential with rate \(\lambda+\mu\). The probability that the arrival occurs first is \(\int_0^\infty \lambda e^{-\lambda s}e^{-\mu s}\,ds=\lambda/(\lambda+\mu)\); the probability that the service completion occurs first is \(\int_0^\infty \mu e^{-\mu s}e^{-\lambda s}\,ds=\mu/(\lambda+\mu)\). These probabilities sum to one, and the corresponding events move the chain up or down by one. \(\square\)

The holding-time description and the generator describe the same local behavior in two forms. In particular, the total rate of leaving state \(n\) is \(-q_{nn}\): it is \(\lambda\) at zero and \(\lambda+\mu\) in every positive state. The jump probabilities are obtained by dividing each possible outgoing rate by this total rate.

Worked Examples

Worked Example: Writing the Generator for Specified Rates

Suppose arrivals occur at rate \(\lambda=\tfrac32\) and service completions occur at rate \(\mu=2\) while the queue is nonempty. Write the generator rows for states \(0,1,2,\ldots\), and check their sums.

From state zero, the only rate to a distinct state is \(q_{0,1}=\tfrac32\). Therefore \(q_{0,0}=-\tfrac32\), and the first row has entries \((-\tfrac32,\tfrac32,0,\ldots)\), whose sum is \(-\tfrac32+\tfrac32=0\).

From state one, the downward rate is \(q_{1,0}=2\), the upward rate is \(q_{1,2}=\tfrac32\), and the diagonal rate is \(q_{1,1}=-(2+\tfrac32)=-\tfrac72\). Its row sum is \(2-\tfrac72+\tfrac32=0\). For every \(n\ge2\), the row has \(q_{n,n-1}=2\), \(q_{n,n}=-\tfrac72\), and \(q_{n,n+1}=\tfrac32\), with all other entries zero; its sum is also \(2-\tfrac72+\tfrac32=0\).

Check: The state-zero row has no entry for a downward transition. The positive-state rows include both event rates, and each row sums to zero as required.

Worked Example: Comparing an Empty and a Busy Queue

Let \(\lambda=2\) and \(\mu=1\). Find the holding-time distribution and next-state probabilities from state zero and from any state \(n\ge1\), then check the generator rows.

At zero, only arrivals change the state, so the holding time has exponential rate \(2\), with mean \(1/2\), and the next state is one with probability one. The generator entries are \(q_{0,1}=2\) and \(q_{0,0}=-2\); their sum is \(-2+2=0\).

At any \(n\ge1\), the total rate of the competing arrival and service events is \(2+1=3\). The holding time has exponential rate \(3\), with mean \(1/3\). The next state is \(n+1\) with probability \(2/3\), since the arrival rate divided by the total rate is \(2/3\). It is \(n-1\) with probability \(1/3\), since the service rate divided by the total rate is \(1/3\). The generator row has entries \(q_{n,n-1}=1\), \(q_{n,n}=-3\), and \(q_{n,n+1}=2\); its sum is \(1-3+2=0\).

Check: The two next-state probabilities add to \(2/3+1/3=1\). The mean holding times are the reciprocals of the computed total rates: \(1/2\) at zero and \(1/3\) in positive states.

Worked Example: Recovering the Rates from Holding-Time Data

Suppose that in every positive state the observed mean holding time is \(1/5\), and the probability that the next jump is upward is \(2/5\). At zero, the observed mean holding time is \(1/2\). Recover the M/M/1 rates and write the generator.

In a positive state, the total departure rate is the reciprocal of the mean holding time, so \(\lambda+\mu=1/(1/5)=5\). The upward-jump probability is \(\lambda/(\lambda+\mu)=2/5\). Substituting the total rate gives \(\lambda=5(2/5)=2\), and then \(\mu=5-2=3\). At zero, the departure rate is \(\lambda\), so the predicted mean holding time is \(1/\lambda=1/2\), which matches the given value.

The generator therefore has \(q_{0,0}=-2\), \(q_{0,1}=2\), and, for \(n\ge1\), \(q_{n,n-1}=3\), \(q_{n,n}=-5\), \(q_{n,n+1}=2\). The state-zero row sums to \(-2+2=0\); each positive-state row sums to \(3-5+2=0\).

Check: The recovered positive-state holding mean is \(1/(2+3)=1/5\), and the upward-jump probability is \(2/(2+3)=2/5\). Both reproduce the supplied observations.

A Common Boundary Error

A frequent mistake is to give state zero the same diagonal entry as a positive state, namely \(-(\lambda+\mu)\). For example, with \(\lambda=2\) and \(\mu=3\), this would put \(-5\) on the diagonal at zero. If the only listed outgoing transition is the arrival to state one at rate \(2\), the proposed row sum is \(-5+2=-3\), not zero. The row is not a generator row, and the calculation has incorrectly included a service event when no customer is present.

The correction is to count only events that can change the state from the state in question. At zero, the only such event is an arrival, so the row is \((-2,2,0,\ldots)\), with sum \(-2+2=0\). At a positive state, both events are possible, so the diagonal entry is \(-(2+3)=-5\), and the row sum is \(3-5+2=0\). The two diagonal formulas differ because the set of possible events differs at the boundary.

The rates specify local transitions, holding times, and the behavior at an empty system. They do not by themselves assert that a stationary distribution exists or describe long-run queue behavior. Those questions require separate analysis; for constructing the birth-death model, the essential checks are that each listed rate corresponds to a possible event and that every generator row sums to zero.

Check Your Understanding

Use the transition-rate definitions and verify each generator row by summing its entries.

  1. For \(\lambda=1\) and \(\mu=4\), write the generator entries in state zero and in a positive state.
  2. With \(\lambda=3\) and \(\mu=2\), what is the holding-time distribution in state zero? What is it in state \(n\ge1\)?
  3. In a positive state, the mean holding time is \(1/6\), and the probability of a downward jump is \(1/3\). Recover \(\lambda\) and \(\mu\).
  4. Why is a service-completion transition from zero impossible, even though service times have rate \(\mu>0\)?
  5. For \(\lambda=2\) and \(\mu=1\), check the row sum that would result from incorrectly using diagonal entry \(-(\lambda+\mu)\) at zero while retaining only the upward rate.