An Algorithm for Estimating the Expected Number of Customers for a Class of Markovian Queueing Systems

Abstract

An algorithm is presented for estimating the expected number of customers for a class of Markovian queueing systems. The class is characterized by those systems whose transition matrix for the underlying customer arrival and departure process is finite, irreducible, and aperiodic. The algorithm does not depend on a closed-form solution for the limiting behavior of the queue. The expected number of customers is frequently used as a measure of effectiveness to describe the behavior of the system or to optimize its design or control. To calculate such a quantity one must usually obtain a closed-form expression for the steady-state probabilities. Unfortunately, of the myriad of Markovian queueing systems, only a few have known closed-form expressions for their steady-state probabilities. The most well-known, using Kendall’s notation, are the M/M/1 and the M/M/c system. The algorithm described below estimates the expected number in the system under steady-state without a need for closed form steady-state probabilities. All that is needed is the transition matrix for the underlying Markov chain.

Share and Cite:

Tu, H. and Kumin, H. (2020) An Algorithm for Estimating the Expected Number of Customers for a Class of Markovian Queueing Systems. American Journal of Operations Research, 10, 132-137. doi: 10.4236/ajor.2020.104009.

1. Preliminaries

Consider a Markovian queueing system in which the customer arrival and departure process is described by a finite, irreducible, and aperiodic Markov Chain { X n : n = 0 , 1 , } whose N × N transition matrix is given by A = ( a i j ) , where a i j = p r { X n = j | X n + 1 = i } .

It is well known that for a finite, irreducible, aperiodic Markov chain, there exists a unique stationary probability vector V = ( v 0 , , v 0 ) such that V A = V [1].

Let L = Expected number of customers in the steady state system. The expected number of customers is frequently used as a measure of effectiveness to describe the behavior of the system or to optimize its design or control [2] [3] [4], and [5]. Now define the following

F = ( 0 , 1 , , N 1 ) t

A Z F = ( w 0 ( z ) , , w N 1 ( z ) ) t = W ( z )

w _ ( z ) = min i { w i ( z ) : i = 0 , 1 , , N 1 }

w ¯ ( z ) = max i { w i ( z ) : i = 0 , 1 , , N 1 }

L ^ ( z ) = ( w ¯ ( z ) + w _ ( z ) ) 2

Theorem 1 For any positive integer z,

1)

| L L ^ ( z ) | ( w ¯ ( z ) + w _ ( z ) ) 2

2)

lim z L ^ ( z ) = L

Proof.

1)

L = V F = V A Z F = v i w i ( z )

since w i ( z ) w ¯ ( z )

then,

v i w i ( z ) v i w ¯ ( z ) = w ¯ ( z ) v i = w ¯ ( z )

Similarly, since

w i ( z ) w ¯ ( z )

we have,

v i w i ( z ) v i w _ ( z ) = w _ ( z ) v i = w _ ( z )

thus

L L ^ ( z ) w ¯ ( z ) ( w ¯ ( z ) + w _ ( z ) ) 2 = ( w ¯ ( z ) w _ ( z ) ) 2

and

L L ^ ( z ) w ¯ ( z ) ( w ¯ ( z ) + w _ ( z ) ) 2 = ( w ¯ ( z ) w _ ( z ) ) 2

It follows that

| L L ^ ( z ) | ( w ¯ ( z ) + w _ ( z ) ) 2

2) Let A z = ( p 0 ( z ) , , p N 1 ( z ) ) t , where p i ( z ) is the ( i + 1 ) th row of A z . Since we are concerned with finite, irreducible, aperiodic Markov chains, we have

lim z p i ( z ) = V

For all i. It follows that

lim n w i ( z ) = lim z p i ( z ) F = V F = L

For all i. Let ( s n ) be the sequence formed by combining the N sequences ( w 0 ( z ) ) , , ( w N 1 ( z ) ) according to the ascendant order of z. Clearly,

lim z s n = L

Since ( w ¯ ( z ) ) and ( w _ ( z ) ) are both subsequence of ( s n ) , it is clear that

lim z w ¯ ( z ) = lim z w _ ( z ) = L

It therefore follows that

lim z L ^ ( z ) = lim z ( w ¯ ( z ) + w _ ( z ) ) 2 = ( lim z w ¯ ( z ) + lim z w _ ( z ) ) 2 = L + L 2 = L .

2. Algorithm for Estimating the Expected Number of Customers

The relationship between L ^ and L as stated in Theorem 1 can be used to develop an iterative algorithm for estimating the expected number of customers from the system’s transition matrix.

Definition 1

The absolute error of an estimation is the absolute value of the difference between the estimation and the true value. When the true value is unknown, the largest absolute error that may occur is called the maximal absolute error.

Definition 2

The relative error of an estimation is the ratio of the absolute error of the estimation to the true value. When the true value is unknown, the largest relative error that may occur is called the maximal relative error.

The algorithm can now be stated as follows:

Step 1. Determine the allowable maximal absolute error a.

Step 2. Set z = 0 and W ( 0 ) = ( 0 , , N l ) t .

Step 3. Compute W ( z + 1 ) = A W ( z ) .

Step 4. If ( w ¯ ( z + 1 ) w _ ( z + 1 ) ) 2 a , go to step 5; otherwise, increase z by 1 then go to step 3.

Step 5. The desired accuracy has been reached. Let L = L ^ ( z + 1 ) = ( w ¯ ( z + 1 ) + w _ ( z + 1 ) ) 2 . Terminate

Theorem 2 Let L ^ ( n ) be the estimation of the expected number of customers obtained from the Algorithm above. Using an allowable maximal absolute error of a, we then have that

1) The maximal absolute error of L ^ ( n ) is a,

2) The maximal relative of L ^ ( n ) is a ( L ^ ( n ) a )

Proof. 1) Step 4 of the algorithm implies ( w ¯ ( n ) w _ ( n ) ) 2 a . Thus, by Theorem 1, | L L ^ ( n ) | ( w ¯ ( n ) w _ ( n ) ) 2 a . Hence, the maximal absolute error of L ( n ) is a.

2) The maximal relative error occurs when L = L ^ ( n ) a . Thus, the maximal relative error = | L ^ ( n ) L | L = | L ^ ( n ) ( L ^ ( n ) a ) | ( L ^ ( n ) a ) = a ( L ^ ( n ) a )

The allowable error associated with the algorithm above is specified in terms of the maximal absolute error, and is thus independent of the magnitude of the expected number of customers. If one needs to associate the error of the estimation with the magnitude of the expected number of customers, then the algorithm may be modified as follows:

Step 1. Determine the allowable maximal relative error r.

Step 2. Set z = 0 and W ( 0 ) = ( 0 , , N l ) t

Step 3. Compute W ( z + 1 ) = A W ( z )

Step 4. If ( w ¯ ( z + 1 ) w _ ( z + 1 ) ) 2 r L ^ ( z + 1 ) ( 1 + r ) , go to step 5; otherwise, increase z by 1 then go to step 3.

Step 5. The desired accuracy has been reached. Let L = L ^ ( z + 1 ) = ( w ¯ ( z + 1 ) + w _ ( z + 1 ) ) 2 . Terminate.

Theorem 3 let L ^ ( n ) be the estimation of the expected number of customers obtained from the modified algorithm above, using an allowable maximal relative error of r, then

1) The maximal absolute error of the L ^ ( n ) is r L ^ ( n ) ( 1 + r )

2) The maximal relative error of L ^ ( n ) is r

Proof. 1) Step 4 of the modified algorithm 2 implies ( w ¯ ( n ) w _ ( n ) ) 2 r L ^ ( n ) ( 1 + r ) .

Thus, by Theorem 1, | L L ^ ( n ) | ( w ¯ ( n ) w _ ( n ) ) 2 r L ^ ( n ) ( 1 + r ) . Hence the maximal absolute error of L ^ ( n ) is r L ^ ( n ) ( 1 + r ) .

2) The maximal relative error occurs when L = L ^ ( n ) r L ^ ( n ) ( 1 + r ) . Thus the maximal relative error = | L ^ ( n ) L | L = | L ^ ( n ) ( L ^ ( n ) r L ^ ( n ) ( 1 + r ) ) | ( L ^ ( n ) r L ^ ( n ) ( 1 + r ) ) = r

Thus, the initial algorithm will have a maximal absolute error of a, and a maximal relative error of a ( L ^ ( n ) a ) . The modified algorithm will have a maximal absolute error of r L ^ ( n ) ( 1 + r ) and a maximal relative error of r.

3. Numerical Example (Table 1)

Consider the M/M/c/c queueing system with finite waiting space. Assume that customers arrive according to a Poisson process with rate λ, and that service times are exponential with mean 1/µ. Although the process that describe the number of customers in the system at time is a process that take place in continues time, several relevant Markov chains may be defined for this system in discrete time. For example, consider the Markov chain whose transition is given by

A = a i j = [ 1 λ λ μ 1 λ μ λ 2 μ 1 λ 2 μ λ ( c 1 ) μ 1 λ ( c 1 ) μ λ c μ 1 c μ ]

where λ and μ have been scaled such that A is a legitimate transition matrix, a is set at 0.01, and L is computed using the following formulas for the M/M/c/c (Erlang B) system [6].

Let

B ( c , r ) = p c = r c c ! i = 0 c r i i !

where r = λ μ and let

C ( c , r ) = c B ( c , r ) c r + r B ( c , r )

then L q = r c r C ( c , r ) and L = L q + r ( 1 p c ) where L q is the expected number in the queue.

Table 1. M/M/c/c system.

These computations were made on a 64-bit IntelÒ CoreTM m3-6Y30 CPU @ 0.90 GHZ laptop computer.

Conflicts of Interest

The authors declare no conflicts of interest regarding the publication of this paper.

References

[1] Cinlar, E. (1975) Introduction to Stochastic Processes. Prentice-Hall, New Jersey.
[2] Brigham, G. (1955) On a Congestion Problem in an Aircraft Factory. Operations Research, 3, 412-428.
https://doi.org/10.1287/opre.3.4.412
[3] Kumin, H. (1973) On Characterizing the Minimum of a Function of Two Variables, One of Which Is Discrete. Management Science, 20, 126-129.
https://doi.org/10.1287/mnsc.20.1.126
[4] Smith, J.M. (2004) Optimal Design and Performance Modelling of M/G/1/K Queueing Systems. Mathematical and Computer Modelling, 39, 1049-1081.
https://doi.org/10.1016/S0895-7177(04)90534-1
[5] Stidham, S. (2009) Optimal Design of Queueing Systems. CRC Press, New York.
https://doi.org/10.1201/9781420010008
[6] Gross, D., Shortle, J., Thompson, H. and Harris, C. (2008) Fundamentals of Queueing Theory. John Wiley & Sons, New York.
https://doi.org/10.1002/9781118625651

Copyright © 2024 by authors and Scientific Research Publishing Inc.

Creative Commons License

This work and the related PDF file are licensed under a Creative Commons Attribution 4.0 International License.