The response time distribution in such a queueing model is addressed in Section 4.4.. 70 4 M/MI 1 queueing models Figure 4.1: State transition diagram for the most general MIMI1 model Co
Trang 1Part II
Performance of Computer Communication Systems: A Model-Based Approach.
Boudewijn R Haverkort Copyright © 1998 John Wiley & Sons Ltd ISBNs: 0-471-97228-2 (Hardback); 0-470-84192-3 (Electronic)
Trang 2Chapter 4
I N the previous chapter we have already presented birth-death processes as an important class of CTMCs In this chapter, we will see that a birth-death model can be used perfectly for analysing various types of elementary queueing stations Furthermore, by the special structure of the birth-death process, the steady-state probability vector p can be - expressed explicitly in terms of the model parameters, thus making these models attractive
to use
In Section 4.1 we consider the solution of the most fundamental birth-death model:
an M(M( 1 queueing model with variable service and arrival rates In principle, all other queueing models discussed in this chapter are then derived from this model In Section 4.2
we deal with a (single server) queueing model with constant arrival and service rates We then discuss the important PASTA property for queues with Poisson arrivals in Section 4.3;
it is used in the derivation of many interesting performance measures The response time distribution in such a queueing model is addressed in Section 4.4 We then address multi- server queueing stations in Section 4.5, and infinite-server queueing stations in Section 4.6
A comparison of a number of queueing stations with equal capacity but different structure is presented in Section 4.7 We address the issue of limited buffering space and the associated losses of jobs in Section 4.8 for single servers and in Section 4.9 for multi-server stations
In Section 4.10 we address a queueing model in which the total number of customers is limited We finally present a mean-value based computational procedure for such a model
in Section 4.11
Performance of Computer Communication Systems: A Model-Based Approach.
Boudewijn R Haverkort Copyright © 1998 John Wiley & Sons Ltd ISBNs: 0-471-97228-2 (Hardback); 0-470-84192-3 (Electronic)
Trang 370 4 M/MI 1 queueing models
Figure 4.1: State transition diagram for the most general MIMI1 model
Consider a single-server queueing station at which jobs arrive As discussed already in
Chapter 3, we can see these arrivals as births Similarly, the departure of a job at the end
of its service (or transmission) can be regarded as a death We now make the following
assumptions regarding the time durations that are involved:
l the time between successive arrivals is exponentially distributed with mean l/Xi
whenever there are i jobs in the queueing station, i.e., we have a Poisson arrival
process with state dependent rates Xi;
l the time it takes to serve a job when there are i jobs present obeys a negative
exponential distribution with mean l/pi
We can now describe the overall behaviour of this queueing station with a very simple
CTMC on the state space Z = (0, 1,2, s e} From every state i E LV a transition with rate
Xi exists to state i + 1, corresponding to an arrival of a job From every state i E N+
a transition with rate pi exists to state i - 1, corresponding to a departure of a job In
Figure 4.1 we depict the state transition diagram The corresponding generator matrix
then has the following form:
We can now use (3.41) f or solving the steady-state probabilities p;, i = 0, 1, , that is,
we solve pQ - = Q under the normalisation condition Instead of using (3.41), we can also
infer the appropriate equations directly from the state transition diagram by assuming
“probability flow balance” Since we assume that the system will reach some equilibrium,
finally, the probability flow (or flux) into each state must equal the probability flow out of
Trang 44.1 General solution of the MIMI1 queue 71
each state, where the probability flow out of a state equals the state probability multiplied with the outgoing rates This interpretation also explains why (3.41) are often called the global balance equations (GBEs) Thus, we have:
For state 0 : pox0 = plpl, For states i = 1,2, e : POi + Pi) = Pi-A-1 +pi+1pi+1
of the system parameters An important aspect here is that it is in general difficult to say
a priori whether there exists such an explicit solution or not However, here we deal with such a special case From (4.2) we have:
Examining (4.7) gives us the idea that the general solution takes the form:
(4.7)
Substitution of (4.8) in (4.2)-(4.3) immediately confirms this We can use (4.8) to ex- press all the state probabilities in terms of po We finally obtain po by considering the normalisation equation (4.4):
(4.9) from which we derive:
(4.10)
Trang 572 4 MIM 11 queueing models
Of course, po is only positive when the infinite sum has a finite limit If the latter is the case, the queue is said to be stable In the more specific models that follow, we can state this stability criterion more exactly and in a way that is more easy to validate
An important remark here is the following It has been pointed out that the flow balance holds for any single state However, the flow balance argument holds for any connected group of states as well Sometimes, the resulting system of equations is easier
to solve when smartly chosen groups of states are addressed We will address this in more detail when such a situation arises
A third way to solve the steady-state probabilities of this birth-death Markov chain is the following From the GBE for state 0 we see that the probability flows from and to state 0 must be equal Because this is the case in the GBE for state 1, the terms pox0 and
following system of equations:
again under the normalisation condition These balance equations are called the local
obtained by setting equal the probability flow into a particular state due to the arrival of
a job with the probability flow out of that state due to the departure of that same job Important to note is the fact that not for all CTMCs do LBEs hold Only for a special class of queueing models is this the case (for more details we refer to [74])
Finally, note that since we are dealing with a queueing station with an infinite buffer,
no jobs will be lost Define the overall arrival rate X = CzopiXi and the overall service rate
X will be equal to the overall arrival rate X
Other measures of interest are the expected number of jobs in the queueing station and
in the queue, respectively defined as:
E[N] = Fipi, and E[N,] = g(i - l)pi,
from which, via Little’s law and X = X, the expected response time E[R] = E[N]/X and the expected waiting time E[W] = E[N,]/X = E[R] - E[S] can be derived Also more detailed measures such as the probability of having at least k jobs in the queueing system can easily be computed as B(lc) = Cz”=, pi
Trang 64.2 The M(M(1 queue with constant rates 73
Figure 4.2: State transition diagram of the constant-rate MIMI1 model
The simplest possible form of the general model discussed in Section 4.1 is the one in which all the arrival rates are the same, i.e., Xi = X, i = 0, 1,2, ., and in which all the service rates are the same, i.e., p( = p, i = 1,2,3, Figure 4.2 shows the state transition diagram Note that the arrival process is a Poisson process Substituting the model parameters in the general result (4.8) we obtain
where we use the well-known solution of the geometric series under the assumption that
p < 1 (see also Appendix B) We thus find p = 1 - p whenever p < 1 or X < p This existence condition is intuitively appealing since it states that a solution exists whenever the average number of arrivals per unit of time is smaller than the average number of services per unit of time In summary, we find for the steady-state probabilities in the MIMI1 queue:
pi = (1 - p)pi, i = 0,172, ’ ’ ’ ’ (4.15)
We observe that these steady-state probabilities are geometrically distributed with base p, Moreover, since p = 1 - p, we have p = 1 - p = CE”=, pi So, p equals the sum of the probabilities of the states in which at least one job is present, or, in other words, the sum
of the probabilities of states in which there is work to do This equality explains why p is often called the utilisation By the fact that all jobs that enter the queueing station also leave the queueing station, we can directly state that the throughput X = X, so that we can also express p = XE[S]
Having obtained the steady-state probabilities, we can easily calculate other quantities
of interest such as E[N], the average number of jobs in the queueing station (see also
Trang 774 4 M]M] 1 queueing models Appendix B.2):
E[N] = -&pi = (1 -p) -&pi = (1 - p)p&i-’
= (1- /&II$ & = p
(4.16) Note that we have again used the result for the geometric series and that we have changed the order of summation and differentiation Although the latter is not allowed at all times,
in the cases where we do so, it is We can continue to apply Little’s result to obtain the average time E[R] spent in the queueing station:
qq = E[N]/X = s = z = 1 p-x’ (4.17) What we see here is that the time spent in the station basically equals the average service time (E[S]); h owever, it is “stretched” by the factor l/(1 - p) due to the fact that there are other jobs in need of service as well Note that we have already seen these results in Chapter 2 Now we can, however, also derive more detailed results as follows
A measure of interest might be the variance a% of the number of packets in the station, This measure can be derived as the expectation of (i - E[N])2 under the probability distribution p:
a& = g(i - E[N])“pi = &
i=o
(4.18) The probability B(k) of h aving at least Ic packets in the queueing station is also of interest, for instance when dimensioning buffers We have
(4.19)
We observe that the probability B(k) of h aving Ic or more jobs in the station is decreasing exponentially with Ic Very often, the value B(lc) is called a blocking probability This name, however, might easily lead to confusion since no losses actually occur
A well-known and often applied result of queueing theory is the PASTA property (Poisson
Trang 84.3 The PASTA property 75
Theorem 4.1 PASTA property
The distribution of jobs in a queueing station at the moment a new job of a Poisson arrival process arrives is the same as the long-run or steady-state job
We have already used the PASTA property in Chapter 2 where we derived first moments for the performance measures of interest of an M]M] 1 q ueue There we used that an arriving customer “sees” the queue at which it arrives “as if in equilibrium”
Although the PASTA property is intuitively appealing, it is certainly not true for all arrival processes Consider as an example a DID] 1 queueing station where every second
a job arrives which requires 0.6 seconds to be served Clearly, since p = XE[S] = 0.6 this queueing station is stable However, whenever a job arrives it will find the station completely empty with probability 1, although in the long run the queue-empty probability will only be 1 - p = 0.4
The proof of the PASTA property is relatively simple, as outlined below Let us con- sider a queueing system in which the number of customers present is represented by a stochastic process (Xt,t 2 0) Furthermore, define the event “there was (at least) one arrival at this queueing station in the interval (t - h, ,I” Since the arrivals as such form a homogeneous Poisson process, the probability of this event equals the proba- bility that there is an arrival in the interval (0, h] which equals Pr{N(h) >_ l}, where N(t) is the counting process defined in Chapter 3 For non-Poisson processes, this “shift
to the origin” would not be valid Since the interarrival times are memoryless, the thus defined probability is independent of the past history of the arrival process and of the state of the queueing station: Pr{N(h) 2 11X,-, = i} = Pr{N(h) 2 1) so that Pr{N(h) 2 1 UXt-h = i} = Pr{N(h) 2 1) Pr{Xt_h = i} From this, we can conclude that also
Pr{Xt_h = i]N(h) 2 1) = Pr{Xt-h = i} (4.20)
If we now take the limit h + 0, the left-hand side of this equality simply expresses the probability that an arrival at time-instance t arrives at a queue with i customers in it This probability then equals the probability that the queue at time t has i customers in it, independent from any arrival, hence, the steady-state probability of having i customers in the queue As a conclusion, we see that a Poisson arrival acts as a random observer and sees the queue as if in equilibrium
Important to note is that we have used the memoryless property of the interarrival times here Indeed, it is only for the Poisson process that this property holds, simply since
Trang 976 4 MIMI 1 queueing models
there is no memoryless interarrival time distribution other than the negative exponential one used in the Poisson process The discrete-time analogue of the PASTA property is the BASTA property where in every time-slot an arrival takes place (or not) with a fixed probability p (or 1 - p) This means that in every slot the decision on an arrival is taken
by an independent Bernoulli trial so that the times between arrivals have a geometrically distributed length The latter might be no surprise since the geometric distribution is the only discrete-time memoryless distribution
In Section 4.2 we have computed the steady-state probability distribution of the number of customers in an MIMI 1 queueing station From this distribution, we were able to derive the mean response time (via Little’s law) In many modelling studies, obtaining such mean performance measures is enough to answer the dimensioning questions at hand, How- ever, in some applications it is required to have knowledge of the complete response time distribution, e.g., when modelling real-time systems for which the probability of missing deadlines should be investigated In general, obtaining complete response or waiting time distributions is a difficult task; however, for the M IM 11 q ueue it remains relatively simple,
as we will see below
When a job arrives at an MIMI1 queue, it will find there, due to the PASTA property,
n jobs with probability p, = (1 - p)p” As the exponential distribution is memoryless, the remaining processing time of a job in service again has an exponential distribution Therefore, the response time distribution of a job arriving at an MIMI1 queue which is already occupied by n other jobs has an Erlang-(n + 1) distribution, that is, the sum of n exponentially distributed service times, plus its own service time
From Appendix A we know that the Erlang-Ic (Ek) distribution with rate p per stage has the following form:
k-1 (pt)i
i=O ’ Using this result, we can calculate the response time distribution by unconditioning: the complete response time distribution is the weighted sum of response time distributions when there are n jobs present upon arrival, added over all possible n:
FR(t) = Pr{R 5 t} = 2 p, Pr{R 5 tin packets upon arrival}
n=O
- ~pnFk+,(t) = x(1 - p)pnFEn+l(t)
-
Trang 104.5 The MIMlm multi-server queue 77
= 1 _ pt 5 yi = 1 _ ptpt
i=O ’
= 1 _ p(lWt - - 1 _ &CL-W (4.22) Surprisingly, the response time is exponentially distributed, now with parameter (p - X)
We can directly conclude from this that the average response time equals E[R] = l/(p - X)
as we have seen before
Response time distributions can often be used to give system users guarantees of the form “with probability p the response time will be less than F&‘(p) seconds” Especially for time-critical applications such response time guarantees are often more useful than the average response time
Example 4.1 Response time distributions at varying p
Consider an MIMI1 queue with p = 1 and where X is either 0.2, 0.5 or 0.8 For these cases, the response time distribution is given in Figure 4.3 As can be observed, the higher p, the smaller Pr{R 5 t), i.e., the higher the probability that the response time exceeds a certain
In the previous sections we have discussed models of systems in which there is only a single server Now consider a system in which a number of service providing units can work independently on a number of jobs Examples of such systems are (homogeneous) multiprocessor systems or telecommunications systems (telephone switches) with multiple outgoing lines
The multi-server aspect can easily be incorporated in the general birth-death model we developed before We assume constant arrival rates, such that Xi = X for all i = 0, 1, , but the number of active servers depends on the number of jobs present, as follows:
Trang 1178 4 MIM 11 queueing models
1.0 0.9 0.8 0.7 0.6 Pr(R 5 t}
0.4 0.3 0.2 0.1 0.0
t
Figure 4.3: Response time distributions in an MIMI1 queue for p = 1 and various X’s
Figure 4.4: State transition diagram for the MlMlm model
This definition says that as long as there are less than m jobs present, the effective service rate equals that number times the per-server service rate, and when at least m jobs are present, the effective service rate equals mp In Figure 4.4 we show the corresponding state transition diagram
When we define p = X/mp, the stability condition for this model can again be expressed
as p < 1; p can also be interpreted as the utilisation of each individual server The expected number of busy servers equals mp = X/p When the station is not overloaded the throughput X = A When the station is highly loaded, it will operate at maximum speed, i.e., with rate mp Under these assumptions, we can compute the following steady-state probabilities from the global balance equations:
Pi = PQ -, bPY
Trang 124.6 The MIMI 00 infinite-server queue 79
C;gp$+&’
(4.28)
(4.29)
As an extreme form of a multi-server system, consider now a system which increases its capacity whenever more jobs are to be served Stated differently, the effective service rate increases linearly with the number of jobs present: ,LL~ = ip, for i = 1,2, - Combining this with an arrival process with fixed rate, i.e., Xi = X, for i = 0, 1, s ., and using (4.8) we can immediately derive that
Trang 1380 4 MIMI1 queueing models
Figure 4.5: State transition diagram for the infinite-server model
Now, we can compute E[N] as
E[N] = gipi = e-f’gi$ = e-Pgi$
i=O id) ’ i=l *
which can easily be explained Since all arriving jobs are immediately served, the queue will always be empty, i.e., E[N] = E[N,] + E[N,] = 0+ E[N,] = p The average time spent
in the queueing system simply equals the average service time l/cl
Infinite servers are often used for modelling the behaviour system user For instance, the delay that computer jobs perceive when a user has to give a command from a termi- nal can be modelled by an infinite-server There is no queueing of jobs at the terminal (every user has its terminal and there is only one job per user/terminal), but submitting
a command takes time Consequently, there is only a service delay (the “think time”) Infinite-server queueing stations are also used when fixed delays in communication links have to be modelled For that reason, infinite-servers are sometimes also called delay servers
When investments for computer systems have to be made, very often the question arises what is most effective to buy: a single fast multi-user computer, or a number of smaller single-user computers We can formalise this question now, using some of the models we have just presented, albeit in a fairly abstract way
The three abstract system models are given in Figure 4.6 In case (1) we consider
a single fast processing device with service rate Kp (all users share a single but fast computer) In the second case we consider K smaller computers, each with capacity /-A In doing so, we can either deal with a single queue with K servers (all users share a number
of smaller computers; case (2a)), each of speed p, or with K totally separate computers