Simultaneity in discrete-time single server queues with Bernoulli inputs

Simultaneity in discrete-time single server queues with Bernoulli inputs

Performance Evaluation 14 (1992) 123-131 North-Holland 123 Short communication Simultaneity in discrete-time single server queues with Bernoulli in...

453KB Sizes 3 Downloads 39 Views

Performance Evaluation 14 (1992) 123-131 North-Holland

123

Short communication

Simultaneity in discrete-time single server queues with Bernoulli inputs A. Gravey and G. H6buterne Centre National d'Etudes des T~l~communications, Route de Tr~;gastel, 22301 Lannion, France

Received 22 September 1989 Revised 24 July 1991

Abstract

Gravey, A. and G. H6buterne, Simultaneity in discrete-time single server queues with Bernoulli inputs (Short communication), Performance Evaluation 14 (1992) 123-131. In discrete-time systems, arrivals and departures occur simultaneously. The present work focuses on the scheduling of arrivals and departures in discrete-time queues with Bernoulli arrivals and general independent service times. Both finite and infinite capacity queues are analysed. The waiting-room management policy takes care of the simultaneity problem. Two waiting-room management policies, AF (Arrivals First) and DF (Departures First) are singled out and their influence on the derivation of the state probabilities is investigated. Furthermore, the outside observer's distribution is shown to be identical to the arriving customer's distribution in the AF queue and a formula relating both distributions is provided for the DF queues. Keywords: discrete-time queues, scheduling, Bernoulli process, geometric interarrivals, queue length, outside observer's distribution, arriving customer's distribution, GASTA property.

1. Introduction In a Broadband Integrated Service Digital Network (B-ISDN) and more spccifically in an Asynchronous Transfer M o d e (ATM) network, information is organized into fixed length blocks, the so-called "cells". Each cell is identified by its header and is individually transmitted through the network. Consequently, A T M traffic is essentially discrete and discrete-time systems are naturally used as models in order to study various performance issues related to A T M networks. Although discrete-time systems have already been used as modeling tools for a wide range of problems, they are not familiar as continuous-time systems. This paper highlights the influence of the scheduling of arrivals and departures in a discrete-time queue. The number of customers in a discrete-time system varies only at equally spaced epochs: during any s l o t - - a slot is an interval of time which boundaries are two successive e p o c h s - - n o customer enters or leaves the system. In contrast to the continuous-time, non-batch queueing systems where the probability that two or more arrivals or departures occur simultaneously is 0, in a discrete-time queueing system this probability can be positive. It is therefore important to know how the waiting-rooms are filled or emptied. For example, consider a single-server queue and assume that customer A arrives and customer D departs at the same epoch; D observes A's arrival if and only if its departure is scheduled after A's arrival (see Fig. 1). The waiting-room m a n a g e m e n t policy is qualified as A F (Arrivals First) if arrivals take precedence over departures in case of simultaneity and D F (Departures First) if it is the reverse. Define the state of the system to be the number of customers in system at a special set of epochs (departure epochs, arrival epochs, entry epochs) or at 0166-5316/92/$05.00 © 1992 - Elsevier Science Publishers B.V. All rights reserved

124

A. Gravey, G. H6buterne / Simultaneity in discrite-timesingle serverqueues Departure First

I

Policy

D

I

I

A

I

I

Arrival First

policy

Fig. 1. AF and DF waiting-room management policies.

an arbitrary time instant. There are significant discrepancies between the system's state distributions for AF and DF queues. These are quite noticeable, for example in simulation studies, and can lead to misinterpretations if the modeling process is not carefully carried out. The present paper analyses single-server queues with Bernoulli arrivals, general independent service times and either infinite or finite waiting-rooms. The influence of the waiting-room management policy on the derivation of the relevant state distributions is investigated. Some relationships existing between AF and DF distributions are also obtained. Furthermore, by means of the GASTA property [3], we point out that the arriving customer's distribution is identical to the outside observer's distribution in an AF queue. This result does not hold in a DF queue and a formula relating both distributions is provided.

2. The Bernoulli arrival process Take the length of a slot to be 0 units of time long. Assume furthermore that at any epoch, a customer arrives with probability p independently of what happens at the other epochs. The number of slots I elapsed between two successive arrivals (the corresponding interarrival time is I0) is therefore geometrically distributed on the set of positive integers

P(l=k)=p(1-p)

k-I

ifk>~l

For that reason, the short-hand notation G e o / G / 1 is used for a single-server queue with Bernoulli arrivals and general independent service times. The Bernoulli arrival process is memoryless in the sense that at the beginning of any slot, the number of slots till the next arrival has the same distribution as I. Note that there is another, widely used, geometric distribution on the set of integers given by P(I = k) =p(1 _p)k. This last distribution is not convenient for our problem since the interarrival times are positive for a Bernoulli arrival process (no batch arrivals).

3. Departing customer's distribution

3.1. The Geo / G / 1 queue Consider an infinite capacity single server queue with Bernoulli arrivals and general independent service times. Let E(S) be the mean service time, p ---pE(S) be the offered load and S(z) be the z-transform of the service time distribution. Let OTk be the epoch of the kth service completion and N k be the number of customers left in the system by the kth departing customer. Since the capacity of the waiting room is infinite, the sequence Tk, k = 1, 2. . . . is independent of the waiting room management policy. In contrast, NA (for the AF policy) and N ~ (for the DF policy) differ. However, at time O(Tk + ½), the number of customers in system is independent of the chosen policy. Let AT. be the Bernoulli variable such that AT, = 1 if and only if an arrival is scheduled at OTk. This event is independent o"f N~. Furthermore, we see that N A and N ~ differ by A t : N ~ = N ~ +Ark. We thus relate the z-transforms NA(z) and N ~ ( z ) of N~ and Nff respectively

N A ( z ) = (1 --p + p z ) N ~ ( z ) This relation holds too for the limits (if these limits exist) NA(z) and ND(z) of respectively N ~ ( z ) and N~(z):

XA( z) = (1 - p + p z ) U D ( z )

(1)

Clearly, NA(z) (respectively ND(z)) is the z-transform for the steady-state departing customer's distribution in the AF (respectively the DF) G e o / G / 1 / ~ queue. In [4], Kobayashi and Konheim use an imbedded Markov chain in

A. Gravey, G. Hdbuterne /Simultaneity in discrite-time single serverqueues

125

order to obtain NA(z): N A ( z ) = (1 - - p )

(1 - z ) S ( 1 - p + p z )

(2)

S(1 - p +pz) - z

Equations (1) and (2) yield together NO(z)=

1-p 1-p+pz

(1-z)S(1-p+pz) S(X-p+pz)-z

(3)

Observe that the A F and D F departing customer's distributions differ at 0: p(NA=0)=

l-p

p ( N D = O)

1-p 1 -p

The mean number of customers in system at departure time for the A F queue is obtained using L'Hopital's rule in eq. (2) E ( N A) =

pE( S) + V( S ) p 2 / 2 - ( E( S) + E( S)2)pZ/2 1 -pE(S)

where E(S) and V(S) are respectively the mean and variance of the service time. Next, using (1), we see that E(N D) = E(N A) - p . Note that Little's result does not apply for E ( N D) and E(NA). This result relates the mean sojourn time in system to the mean number of customers in system seen by an outside observer. We now derive from eq. (1) the following set of inverse relations which relate the departing customer's distributions of the A F and D F G e o / G / 1 / ~ queues

' P ( N A = k ) = (1 - p ) P ( U D = k) + p P ( U D = k - 1) (~)~ i p(ND=k)=(l_p)-I ~-,p(NA=i)

(4)

i = 0

These relations hold for k >/0, with the convention P(N D = - 1) = 0. The state probabilities corresponding to one management policy are thus easily derived, by means of (4), from the state probabilities corresponding to the other management policy.

3.2. The Geo / G / 1 / K queue Consider now a G e o / G / 1 queue with finite capacity K. Let M be the number of customers left in the G e o / G / 1 / K queue by a departing customer. The following equation relates the departing customer's distributions in finite and infinite queues for both waiting room management policies:

P(N=k) P(M=k)-p(N<~K_I

)

if0~
(5)

Relation (5) is obtained as follows. In both infinite and finite capacity G e o / G / 1 queues, the imbedded Markov chain method yields a system of simultaneous linear equations for respectively {P(N=k)}k>~o and { P ( M = k)}k=0,1..... K-V The first ( K - 1) equations of these two systems are identical; the vectors {P(N = k)}k 0..... K i and { P ( M = k)}k= o..... K 1 are therefore parallel, which yields (5) since ~ - I P ( M = k ) = 1. Using (4) and (5), we obtain after some simple algebra

I P(NA~
~<~-S-_~

K-I 1 - j--~oP ( M A = j ) ~

[ _p iK-j -1- ~ )

and using (4) and (5) once more, we derive the following equations relating M A and M ° which hold for

A. Gravey, G. Hdbuterne / Simultaneity in discrite-time single serverqueues

126

O<~k~
with the convention P(M D= - 1 ) = 0 .

p(MA=k) =

(1 - p ) P ( M D = k ) + p e ( M D =k - l)

1 - p P ( M D = K - 1) (l-p)

p(MD=k) =

p(MA=j)

'

K-I 1-

if0~
j=0

(6)

( _p ]K-j

if0~
Y~. p ( M A = j ) j=o ~ 1 -p ]

Equations (4) and (6) are identical, except for a normalizing constant.

4. Arriving customer's distribution The number of customers in the G e o / G / 1 queue (with either infinite or finite waiting room) can increase or decrease by at most one customer at a time. The steady-state distributions for the number of customers in system at entry time and at departure time are therefore identical (see [2] for a proof). This property holds for any waiting room management policy. The entering customer's distribution is thus also given by eqs. (2) and (3). If the waiting room capacity is infinite, every arriving customer enters the queue. Therefore, the steady-state distributions for the number of customers at entry time and at arrival time are identical. If the waiting room capacity is finite, some arriving customers are rejected. The probability that a customer is rejected--or loss probability--is indeed an important parameter of the system. We now derive the arriving customer's distribution for both AF and DF G e o / G / 1 / K queues. Let the number of customers in system at arrival time be L, at entry time be Q and at departure time be M (see Fig. 2). Keep in mind that M and Q are identically distributed. In order to obtain the loss probability, we first equate the input rate to the output rate. The input rate is pP(L ~ K - 1 ) for both policies. The output rate is the inverse of the mean interdeparture time. In the AF G e o / G / 1 / K queue, this mean interdeparture time is equal to E ( S ) + p - I p ( M A = 0) and in the DF G e o / G / 1 / K queue, it is equal to E(S) +p 1(1 - p ) P ( M ° = 0). Indeed, in the former case, the interdeparture time includes an idle period with probability P(M A = 0) whereas in the latter case, this probability takes the value (1 - p ) P ( M ° = 0). We thus obtain

{

1

P( L A~< K - 1 ) = P + p ( MA=O)

1 P(L D <~K-1)= P+(1-P)P(M

(7) D=O)

Next, note that the probability that a customer finds k customers in system when entering the queue is exactly the probability that a customer arriving to the queue finds k customers in system conditioned on the event {The customer is not rejected}. Therefore, since a customer is rejected if and only if the buffer is full,

P(Q=k)=P(L=kIL<~K-1)

O<~k<~K-1

and we see that for both waiting-room management policies:

P(Q=k)

P(L =k) P ( L <~K-1)

O<~k <~K- 1

X: Outside Observer . gCusto e~: DepartingCustomer S:

A~ri:v~:ge::st o me r m r

Fig. 2. Number of customers in a finite capacity queue at arrival, entry, departure times and at arbitrary time instants.

(8)

A.

Gravey, G. Hdbuterne / Simultaneity in discrite-time single server queues

127

0.400O.1D-

- w - DF queue

% % %

O.IO0-

[]

% % %

O.ZSO-

AF queue

II S.SSO" . . . . .

×

0,1500.100O.O50O.O00

!

I

I

I

2

I

I

I

5

I

!

I

I

I

I

I

I

I

I

10

I

I

I

20

system s i z e Fig. 3. AF versus DF arriving customer's distribution: P(L = 0). Lastly, using (7), (8) and the fact that M and Q are identically distributed, we relate the probability distributions for the number of customers in system at arrival time (L) and at departure time (M) for both waiting room management policies. /p(LA =k)=

[ P( LA p(L D

P(MA=k) p + ~ = 0

O<~k<~K-1

)

1

(9)

K)=I-p+P(MA=O

)

P(M D =k) =k)=o+(l_p)P(MD=O)

P(L D=K) = 1 -

1

O<~k<~K-1 (10)

p+(1-p)P(MD=O) We recognize in system (9) the relationship existing between the distributions of the number of customers in the system at arrival epochs and at departure epochs for the classical M / G / 1 / K queue. Note that system (10) is slightly different. It is also possible to relate directly the state probabilities {P(L A = k)}0..... K to {P(L D = k)} 0..... K by means of (6), (9) and (10). This derivation is straightforward but cumbersome and is not carried out here. Figures 3 and 4 compare AF and DF arriving customer's distributions for the special case of a G e o / D / 1 / K queue. The values of P(L = 0) and P ( L = K) in AF and DF queues are plotted for a system capacity of 2, 5, 10 and 20.

5. Outside observer's distribution

5.1. The Geo / G / 1 queue and the GASTA property Consider a G e o / G / 1 queue with either infinite of finite waiting-room and let X i be the number of customers in system at time O(i - ½). The following fact illustrates the difficulty met in attempting to relate the outside observer's distribution to the arriving customer's distribution. If a customer arrives to the queue at epoch iO(Ai = 1) but no customer leaves the queue at the same instant, the number of customers seen in the queue by the arriving customer is X~, for both AF and DF queue. This result does

128

A. Grat,ey, G. Hdbuterne / Simultaneity in discrite-time single server queues

11+00-

[]

b,d

AF queue

II l l - g l -

x

- ~ - DF queue

II

11-02-

,.=,

111-03-

~ tz-D4-

11-05

!

I

2

!

!

I

!

,5

I

I

!

I

I

|

|

!

!

I

I

10 system size

I

I

I

20

Fig. 4. AF versus DF arriving customer's distribution: P(L = K). not hold however if one customer arrives and another one departs at instant iO: in the A F queue, the arriving customer does find X i customers in the system, but in the D F queue, the arriving customer finds only X i - 1 customers in the queue. In this section, we use the G A S T A property [3], in order to obtain equations relating the outside observer's distribution to the arriving customer's distribution in A F and D F G e o / G / 1 queues. The version of the G A S T A property we shall use is now given. Following Halfin's notation [3], let U, be the indicator function of the event { X i = k}. Furthermore, let (Ai, i > 0) be the sequence of i.i.d Bernoulli random variables such that {A i = 1} if and only if there is an arrival at the epoch iO. Now, let V,, = n-lY:i'= IU/, Y,, = E,'_ iUiAi and Z,, = Y,,(E',',=IAi) 1. Theorem 1 in [3] states that if the set {X l, X 2. . . . . X,,} is independent of the sequence A , , A,,+l . . . . . then: V,, ~ V w . p 1 if and only if Z,, ~ V w . p 1 as n -* o0. We easily check that the above independence property is true for our choice of variables Ag and X~. By definition, the limiting value of V,,, if it exists, is the proportion of time that the n u m b e r of customers in system is k. Using a semi-regenerative process description of the n u m b e r of customers in system and the main renewal theorem [1], it may be shown that this limit exists and is equal to the probability P ( X = k ) that an outside observer finds k customers in the system. In the next subsections, we investigate the limiting value of Z,,. 5.2. Outside observer's distribution in a A F queue

Consider an A F G e o / G / 1 queue with either infinite or finite waiting-room. Let X A be the n u m b e r of customers an outside observer sees in the system and L A be the n u m b e r of customers found in the system by an arriving customer (see Fig. 2). The random variable A i ~ is positive if and only if the following event is realized {

a customer arrives at instant i0 } and finds k customers in the system

Therefore, in the A F queue, the limiting value of Z , is the system at arrival time. It is also the probability P ( L A = k) that By means of the G A S T A property, we now see that, in waiting-room, the arriving customer's distribution is identical to e(sA=k)

=p(LA=k)

proportion of customers which see k customers in an arriving customer finds k customers in system. the A F G e o / G / 1 queue with infinite or finite the outside observer's distribution. (11)

5.3. Outside observer's distribution in a D F queue

We first investigate the D F G e o / G / 1 / ~ queue. Let X D be the n u m b e r of customers seen in the system by an outside observer and L D be the n u m b e r of customers found in the system by an arriving customer. It is obvious that

A. Grat,ey, G. Hdbuterne / Simultaneity in discrite-time single serl,er queues

129

the outside observer's distribution does not depend on the waiting-room management policy which implies P ( X A = k) = P ( X D = k). Moreover, in an infinite queue, the distributions for the n u m b e r of customers in system at arrival (L) and departure ( N ) times are identical and therefore P ( L = k ) = P ( N = k) for both policies. Using the above results together with (4) and (11) yield P(X D=k)=(1-p)e(L o=k)+pe(L D=k-1) k>/0 with the convention P ( L D = - 1) = 0. Consider now the D F G e o / G / 1 / K queue. Let QD be the n u m b e r of customers found in the system by an entering customer and M D be the n u m b e r of customers left in the system by a departing customer (see Fig. 2). Keep in mind that M D and QD are identically distributed. Furthermore, define the partition {S, S'} of the event {an arrival occurs} as follows: S = {a departure and an arrival occur simultaneously} S ' = {an arrival occurs and no departure occurs simultaneously} The random variable A i U/ is positive if and only if one of the following mutually exclusive events is realized: no customer departs at instant iO a customer arrives at instant iO the arriving customer finds k customers in the system a customer departs at instant iO a customer arrives at instant iO the arriving customer finds k customers in the system Therefore, the limiting value of Z,, in the D F queue is P ( S ' N {L D = k } ) + P ( S N {L D = k - 1}) We evaluate below P ( S ' N {L D = k}) for k = 0 . . . . . K. Let k = K; since a departing customer leaves at most K - 1 customers in system, the events S and {L ° = K} are mutually exclusive which implies that P ( S ' A {L D = K } ) = P ( L D = K). Let now k < K ; the entering customer's distribution is obtained by conditioning the arriving customer's distribution on the event {L D K K - 1} and therefore P ( S N { n D = k}) = P ( L D <~K - 1 ) P ( S N {QD = k } ) (12) Now, if t is an arbitrary slot boundary, the event S n {QD = k} is the intersection of the 3 elementary events: {arrival at t+}, {departure at t } and {k customers in system at t}. Due to the Bernoulli arrival process, the first event is independent of the 2 others and P (arrival at t +) = p ; moreover, ( / d e p a r t u r e at t })=p(MD=k) P ~ ~ k customers in system at t

0.4000.350-

Arriving customer

-~%

~0.300-

Outside observer

o %

~D. 250N D.300~..,,0.150¢:~.-0,I00-

0,0500.000

I

I

I

I

I

5

I

I

I

|

I

I

I

10

I

I

!

!

!

!

I

I

ZO

system size Fig. 5. Arriving customer's versus outside observer's distributions in a DF queue: P (system is empty).

A. Grauey, G. Hdbuterne / Simultaneity in discrite-timesingle serverqueues

130

ll+O0-

II-01-

"- ~

-~- Arriving customer

l|-O2r...

~ ll-D3-

lZ-04-

1~-05

|

|

I

I

2

I

I

I

I

i

I

I

I

I

|

I

I

I

i

!

|

5

10 20 system size Fig. 6. Arriving customer's versus outside observer's distributions in a DF queue: P (buffer is full). On the other hand, M D and QD are identically distributed which implies P ( M ° = k) = p(QD = k). We then obtain

P ( S n {QD = k}) = p p ( Q D = k)

(13)

Combining (12), (13) and the fact that {S, S'} is a partition of {an arrival occurs} yield the following results

P(SA{LD=k})=pP(LD=k)

O<~k<~K-1

P(S'f~{LD=k})=(1-p)P(LD=k)

O<~k<~K-1

The GASTA property now yields the following set of relations:

p(XD=k)=(1-p)P(LD=k)+pP(LD=k P(X D=K)=P(L D=K)+pP(L D=K-1)

-1)

O<~k<~K-1

(14)

Relation (14) is illustrated by Figs. 5 and 6 in case of a G e o / D / 1 / K queue. P(L = 0) is compared to P ( X = 0) an P(L = K) to P ( X = K) for a system capacity equal to 2, 5, 10 or 20. We also easily check that for the G e o / G / 1 / K queue, the outside observer's distribution depends on the waiting-room management policy. 6. Limiting behaviour In order to make the presentation easier to read, we consider the special case of deterministic service times. However, a similar analysis can be carried out for any general independent service times. Consider a G e o / D / 1 queue for which the length of an elementary slot is I / n , the probability of an arrival during a slot is p / n , the length of a service time is nD slots. The length of the service time is D units of time and the offered load is p =pD regardless of n. The service time distribution's z-transform is S , ( z ) = (1 - p / n + p z / n ) "D. When n tends to infinity, the limit for S,(z) is exp(-p(1 - z ) ) . Therefore, using eqs. (2) and (3), we observe that the limiting value for the departing customer's distribution is (1 - z ) e x p ( - p ( 1 - z ) ) N(z)=(1-z) (15)

exp(-p(1 - z ) ) - z

for both waiting room management policies. This limit is the z-transform for the number of customers in a M / D / 1 queue with load p--which was of course to be expected. 7. Conclusion We have described the two different ways of scheduling simultaneous arrivals and departures in a discrete-time single server queue with Bernoulli arrivals and general independant service times. The influence of this scheduling policy on the state probability distributions is pointed out.

A. Gravey, G. H~buterne / Simultaneity in discrite-time single server queues

131

Closed form expressions relating the probability distributions at departure times, arrival times and at arbitrary time instants for both policies are obtained. It is shown that if the probability that a customer arrives in an elementary slot is low, the behaviour of AF and DF queues differ slightly, whereas if it is larger, the discrepancies between the queues' behaviours are more important. Lastly, the discrete-time analog of the M / G / 1 queue is shown to be the G e o / G / 1 queue for which arrivals are scheduled prior to departures in case of simultaneous arrival and departure. For this particular policy, the arriving customer's and the outside observer's distributions of the number of customers in system are shown to be identical.

References

[1] E. (~inlar, Introduction to Stochastic Processes (PrenticeHall, 1975). [2] R. Cooper, Introduction to Queueing Theory (Macmillan, 1972).

[3] S. Halfin, Batch delays versus customer delays, Bell Systems Tech. J. 62 (7) (1983) 2011-2015. [4] H. Kobayashi and A. Konheim, Queueing models for computer communications system analysis. IEEE Trans. Comm. 25 (1) (1977) 2-29.