You are on page 1of 14

Queuing Theory

RK Jana

1
(M / M / 1) : (N / FCFS / ∞)

Single channel finite population model


Maximum number of customers allowed in the system: N
Maximum queue length: (N – 1)
N customers are in the system: No new arrival is permissible
In a steady state condition ρ < 1, it can be shown that

 1   (1   )  n
1   N 1 ,   1  1   N 1 ,   1
P0   Pn  
 1 ,  1  1 ,  1
 N  1  N  1
2
Continued…

In this model, ρ = λ/µ may be ≥ or ≤ 1 for steady state


condition. Because the number of customers allowed
in the system is controlled by the queue length and not
by the relative rates of arrival (λ) or departure (µ).

3
Characteristics of the Model

1. Expected number of customers in the system E(n):

 1  ( N  1)  N  N  N 1 
   ,  1
  (1   )(1   ) N 1
E ( n)  
N
 2 ,   1

4
Characteristics of the Model

2. Expected queue length E(q):

 1  ( N  1)  N  N  N 1  (1   )
    ,  1
  (1   )(1   )  (1   )
N 1 N 1
E (q)  
N 1
 2  N  1  1,  1

5
Continued…

3. Expected waiting time per customer in the system E(w1):


1  1 NN 
   N 
,  1
   (1   ) (1   ) 
E ( w1 )  
 N 1
 2 ,  1

4. Expected waiting time per customer in the queue E(w2):


1  1 NN 
    1 ,   1
   (1   ) (1   ) 
N
E ( w2 )  
 N 1  1 ,  1
 2 
6
Example

Assume that the goods trains are coming in a yard at the rate of
30 trains per day and suppose that the inter-arrival time follows an
exponential distribution. The service time for each train is
assumed to be exponential with an average of 36 minutes. If the
yard can admit 9 trains at a time, then calculate:

(i) The probability that the yard is empty.


(ii) The expected number of trains in the yard.
(iii) The expected number of trains in the queue.
(iv) Expected waiting time of a train in the yard.
(v) Expected waiting time of a train in the queue.

7
Solution

λ = 30/(24×60) = 1/48 trains/min


µ = 1/36 trains/min
ρ = λ/ µ = 36/48 = 0.75 ≠ 1

(i) Probability that the yard is empty

1 
P0  for   1
1  N 1

1  0.75

1  (0.75)10
8
Continued…

(ii) The expected number of trains in the yard:

1  ( N  1)  N  N  N 1 
E ( n)     ,  1
 (1   )(1   ) 
N 1

1  10(0.75)  9(0.75) 
9 10
 0.75  
 (1  0.75){1  (0.75) } 
10

9
Continued…

(iii) Expected number of trains in the queue:

1  ( N  1)   N  
N N 1
(1   )
E (q)      ,  1
 (1   )(1   )  (1   )
N 1 N 1

1  10(0.75)9  9(0.75)10  (1  0.75)


 0.75   
 (1  0.75){1  (0.75)10
}  {1  (0.75)10
}

10
Continued…

(iv) Expected waiting time of a train in the yard:


1 1 NN 
E ( w1 )    N 
,  1
  (1   ) (1   ) 
 1 9(0.75)9 
 36   9 
 (1  0.75) {1  (0.75) }
(v) Expected waiting time of a train in the queue:
1 1 NN 
E ( w2 )     1 ,   1
  (1   ) (1   ) 
N

 1 9(0.75)9 
 36    1
 (1  0.75) {1  (0.75) } 
9
11
Example

At a railway station, only one train is handled at a time. The


railway yard is sufficient only for two trains to wait while other is
given signal to leave the station. Trains arrive at the station at an
average rate of 6 per hour and the railway station can handle on
an average of 12 trains per hour. Assuming Poisson arrival and
exponential service distribution, find the steady state probabilities
for the various number of trains in the system. Also find the
expected number of trains in the queue and expected waiting time
per train in the queue.

12
Solution

λ = 6 per hr; µ = 12 per hr.


ρ = λ/ µ = 1/2 ≠ 1.
Maximum queue length is 2 and the maximum number of
trains in the system is N = 3.
1 
Now, P0  for   1
1  N 1

1  0.5
  0.53
1  (0.5)10

P1 = ρ P0 = (0.5)(0.53); P2 = ρ2 P0 = (0.52) (0.53) = 0.13;


P3 = ρ3 P0 = (0.53) (0.53) = 0.07
13
Continued…
3
E (n)   nPn  0  1(0.27)  2(0.13)  3(0.07)  0.74
n 0

So, the average number of trains in the station is 1.


Each train takes 1/12 hrs for service. So, service time
is 1/12 = 0.085 hrs. A newly arriving train finds 0.74
trains in the system with service time 0.085 hr each.
Therefore, the expected waiting time = (0.74)(0.085) =
0.0629 hr = 3.8 minutes.

You might also like