1. INTRODUCTION
Treatments of the G/M/1 queue can be found in several books on queuing theory (e.g., Asmussen [Reference Asmussen2], Cohen [Reference Cohen3], and Prabhu [Reference Prabhu4]). There are alternative methods to explicitly express the steady-state waiting times in a G/M/1 queue (e.g., Prabhu [Reference Prabhu4, p. 109], starting from the transient behavior of the system, or Asmussen [Reference Asmussen2, p. 228 and 238] based on the Wiener–Hopf factorization identity). The busy period in G/M/1 queues was also characterized (e.g., Cohen [Reference Cohen3, p. 225]) and, recently, it has been studied by Adan, Boxma, and Perry [Reference Adan, Boxma and Perry1] using the sample path approach.
In this study, we characterize the conditional law of the waiting time of the ith customer within a busy period of a G/M/1 queue given that at least i customers were served within this busy period. As we expect, this distribution is a normalized sum of Erlang(μ, j), E jμ, distributions with j = 1, … , i − 1. Therefore, our contribution is the explicit expressions for the probability that on arrival, the ith waiting customer in the busy period sees j customers in the system (or, equivalently, j − 1 customers in the queue).
We also state two straightforward applications for our results. The first is the law for the waiting time of the ith customer in a busy period of a G/M/c queue. The second uses the equivalence of the Lindley recursion, describing the waiting time in a G/G/1 queue with a first come–first serve (FCFS) service discipline, to random walks to describe the distribution of random walks condition on that they do not cross a given threshold.
For completeness, we call to mind that the probability density function (pdf) and cumulative distribution function (cdf) of an Erlang(μ, j) random variable, with j phases, each with mean μ−1, are given by

respectively, and the superscript μ emphasizes the mean of each phase.
2. WAITING TIME OF THE iTH CUSTOMER WITHIN A BUSY PERIOD
2.1. For the G/M/1 Queue
Consider a G/M/1 queue with interarrival times Z i for i ≥ 1 that are independent and identically distributed (i.i.d.) random variables with a cdf F Z(z) and service requirements S i for i ≥ 1 that are i.i.d. and exponentially distributed with mean μ−1.
We let N + 1 be the number of customers served during a busy period. We number the arrivals during a busy period such that the customer that initiates the busy period (and does not wait) is the i = 0 customer in the busy period. Then the first customer that waits, if such exists, is the i = 1 customer and so on until the i = Nth customer. Note that upon completion of service for the Nth customer, the server is idle. Furthermore, because E(X) < 0, busy periods are i.i.d. and E(N) < ∞ almost surely.
We let W i be distributed as the waiting time of the ith customer in a busy cycle onFootnote 1
Then, the cdf of W i is defined as
We let
be the probability that exactly i customers would be served within an interarrival time if there are an infinite number of customers in the queue. Again, the superscript μ emphasizes the mean service time. Moreover, it is clear that ∑i=0∞a iμ = 1.
Using the memoryless of the service time, W 1, the waiting time of the first customer that waits is exponentially distributed with mean μ−1. In the proof of Theorem 1 we use this fact to express the distribution of W i, for each i ≥ 1. Let
denote an equality in distribution; then we have the following theorem.
Theorem 1
Let W ibe a random variable with a cdf defined by Eq. ( 4) for a G/M/1 queue with interarrival times Z with a cdf F Z(z) and exponential service with mean μ−1. Then

where E jμis an Erlang(μ, j) distribution with a pdf and cdf given in Eq. ( 1), P 11 = 1 and P 0i = 0 for each i ≥ 1, and P jifor i ≥ 2 is

Proof
We argue by induction. For i = 1, the distribution of W 1 is exponential. Thus, P 11 = 1 and
, so the claim holds for i = 1. Now, we assume that for i − 1 ≥ 1,

and show that the claim holds for i.
We prove the theorem using the following observation. For each j = 1, … , i, we have
, if two independent events happened. The first is that
for k = j − 1, … , i − 1,Footnote 2 and the second event is that during the interarrival time of the ith customer, there were exactly l = k + 1 − j service completions; that is, upon arrival, the (i − 1)st customer is the (k + 1)st customer in the system (queue + service), and then k + 1−j service completions take place until the arrival of the ith customer. These two independent events lead to that j customers are seen by the ith arrival. Furthermore,
for k = j − 1, … , i − 1 and the probability that exactly k + 1 − j services are completed during an interarrival time is a k+1−jμ. Thus, because the ith customer can see j customers in the system only if W i−1 saw at least j − 1, we have

where the last equality follows from the induction assumption in Eq. (7). Observing that the ith customer can see 1 to i customers in the system upon arrival completes the proof.■
We conclude this subsection by establishing that the distribution given for W i in Theorem 1 is proper. This is equivalent to proving that

To establish Eq. (9), we observe that given
, the busy cycle ends if there were k + 1 or potentially more service completions during the interarrival time of the ith customer. Thus,

and using Eq. (10),

where the last is from the Total Expectation Theorem. This establishes Eq. (9).
2.2. For G/M/c Queues
Consider a G/M/c queue where each server has an exponential service time with mean μ−1, as was investigated by Asmussen [Reference Asmussen2] and Wolff [Reference Wolff6]. The busy period in this queue is the time from an arrival that makes all c servers busy to the first time when only c − 1 servers are busy. Denoting the waiting time of the ith customer in a busy period of a G/M/c queue by W ic, a similar proof to the one of Theorem 1 establishes the following corollary.
Corollary 1
For a G/M/c queue with interarrival times Z with a cdf F Z (z) and exponential service with mean μ−1, we have

where E jcμhas an Erlang(cμ, j) distribution with a pdf and cdf given in Eq. ( 1), P 11 = 1, and P 0i = 0 for each i ≥ 1, and P jifor i ≥ 2 is

2.3. The Busy Period in G/M/1 Queue and Random Walks
For the G/M/1 queue with a FCFS service discipline, let
with Z 0 = 0. Thus, {X i}i=2∞ is a sequence of i.i.d. random variables. Let X be the generic random variable of this sequence and assume that E(X) < 0 (i.e., E(Z) > 1/μ).
Consider the random walk {V i}i=1∞ given by V n = ∑i=1nX i (with V 0 ≡ 0) and observe that because E(X) < 0, V tends to −∞ almost surely (e.g., Ross [Reference Ross5]). A one-sided regulated random walk {Y i}i=1∞ that is regulated at zero is given by
Then from the equivalence of the waiting time in a G/G/1 queue with a FCFS service discipline to Eq. (15), known also as the Lindley recursion (e.g., Cohen [Reference Cohen3]), and from Theorem 1, Corollary 2 follows.
Acknowledgment
The author wishes to thank David Perry and an anonymous referee for useful comments on an earlier draft of this paper. The research was supported by an NSERC grant.