Вы находитесь на странице: 1из 4

Queueing theory is the mathematical study of waiting lines (or queues).

The theory enables mathematical


analysis of several related processes, including arriving at the (back of the) queue, waiting in the queue
(essentially a storage process), and being served by the server(s) at the front of the queue. The theory permits
the derivation and calculation of several performance measures including the average waiting time in the queue
or the system, the expected number waiting or receiving service and the probability of encountering the system
in certain states, such as empty, full, having an available server or having to wait a certain time to be served.

The A/B/C notation designates a queueing system having A as interarrival time distribution, B as service time
distribution, and C as number of servers. For example, "G/D/1" would indicate a General (may be anything)
arrival process, a Deterministic (constant time) service process and a single server.

Application to telephony

The public switched telephone network (PSTN) is designed to accommodate the offered traffic intensity with
only a small loss. The performance of loss systems is quantified by their grade of service, driven by the
assumption that if insufficient capacity is available, the call is refused and lost.[4] Alternatively, overflow
systems make use of alternative routes to divert calls via different paths — even these systems have a finite or
maximum traffic carrying capacity.[4]

However, the use of queueing in PSTNs allows the systems to queue their customers' requests until free
resources become available. This means that if traffic intensity levels exceed available capacity, customers' calls
are here no longer lost; they instead wait until they can be served.[5] This method is used in queueing customers
for the next available operator.

A queueing discipline determines the manner in which the exchange handles calls from customers.[5] It defines
the way they will be served, the order in which they are served, and the way in which resources are divided
between the customers.[5][6] Here are details of four queueing disciplines:

Queueing is handled by control processes within exchanges, which can be modelled using state equations.[5][6]
Queueing systems use a particular form of state equations known as Markov chains which model the system in
each state.[5] Incoming traffic to these systems is modelled via a Poisson distribution and is subject to Erlang’s
queueing theory assumptions viz.[4]

• Pure-chance traffic – Call arrivals and departures are random and independent events.[4]
• Statistical equilibrium – Probabilities within the system do not change.[4]
• Full availability – All incoming traffic can be routed to any other customer within the network.[4]
• Congestion is cleared as soon as servers are free.[4]

Queues can be chained to form queueing networks where the departures from one queue enter the next queue.
Queueing networks can be classified into two categories: open queueing networks and closed queueing
networks. Open queueing networks have an external input and an external final destination. Closed queueing
networks are completely contained and the customers circulate continually never leaving the network.

The M/M/1 system is made of a Poisson arrival, one exponential (Poisson) server, FIFO (or not specified) queue
of unlimited capacity and unlimited customer population. Note that these assumptions are very strong, not
satisfied for practical systems (the worst assumption is the exponential distribution of service duration - hardly
satisfied by real servers). Nevertheless the M/M/1 model shows clearly the basic ideas and methods of Queuing
Theory

The system M/M/1

The M/M/1 system is made of a Poisson arrival (Arrival rate l ), one exponential server (Service rate m ),
unlimited FIFO (or not specified queue), and unlimited customer population. Because both arrival and service
are Poisson processes, it is possible to find probabilities of various states of the system, that are necessary to
compute the required quantitative parameters. System state is the number of customers in the system. It may be
any nonnegative integer number. Let pn(t) = P[n customers in the system at time t]. Like with the Poisson
process, by using the assumptions 1) and 2), it is possible to express the probability pn(t+h), h ® 0 in this way:
pn(t+h) = pn(t)[1 - lh][1 - mh] + (n customers at t, no came, no left)

pn(t)[lh][mh] + (n customers at t, one came, one left)

pn-1(t)[lh][1 - mh] + (n-1 customers at t, one came, no left)

pn+1(t)[1 - lh][mh] (n+1 customers at t, no came, one left )

p0(t+h) = p0(t)[1 - lh] + (no customer at t, no came)

p1(t)[1 - lh][mh] (one customer at t, no came, one left) (11)

Because of small h the terms at the left sides of (12) may be considered as derivatives:

(13)

Equations (13) represent a set of differential equations called Kolmogorov Differential Equations. Their solution
is a set of equations showing how each probability changes with time. Fortunately we actually do not need these
functions. Because of the third assumption (stationarity) after some transition period the system will become
stable. Of course the state will permanently change, but the probabilities of various numbers of customers in the
system will be constant. So the functions pn(t) become constants pn. Constant functions have zero derivatives, so
the set (13) becomes a set of algebraic equations for the stable state:

(14)

By dividing the equations (14) by m we get this set of equations that contain the only parameter r - the traffic
rate:

(15)

In the set (15) p1 is expressed by p0. By inserting p1 and p0 to the equation for p2, we get:

p2 = (1+r )p1 - r p0 = (1+r )r p0 - r p0 = r 2p0

Similarly p2 and p1 may by used to express p3, etc. which gives the general formula for pn:

pn = r np0 = (l /m )np0 (16)

The value p0 can be computed by using the obvious requirement, that the sum of all probabilities must be equal
to 1:

giving: (17)

In (17) the sum of geometric progression has been used. From (17) it is also obvious that the traffic rate r must
be less than 1, otherwise the sum of probabilities would not be 1 (not even limited). Inserting (17) to (16) gives
the general formula for pn:

(18)
The equations (18) represent a very important result used later to obtain all the characteristics of the M/M/1
system. The relatively simple derivation of (18) was enabled by the Poisson process assumptions used when
expressing the probabilities in (11). The equations (18) may be used directly to express these probabilities:

P[service idle] = P[not queuing on arrival] = p0 = 1 - r = 1 - l /m

P[service busy] = P[queuing on arrival] = 1 - p0 = r = l /m

P[n customers in the system] = pn = r n(1 - r )

P[n or more customers in the system] = r n

P[less than n customers in the system] = 1 - r n

The derivation of P[n or more customers in the system]:

Now the formula (18) will be used to derive quantitative characteristics of the M/M/1 system. (18) actually
represents a distribution of a discrete random variable Number of customers in the system (probabilities of all
possible random values). So it is possible to compute the mean value, that is the average number of customers in
the system:

In (19) the formula for geometric progression has been used. Note again, that r must be less than 1, otherwise
the number of customers in the system will grow permanently. In a similar way it is possible to find the average
number of customers in the queue. We assume, that the customer being served is not a part of the queue. So n
customers in the system means the queue length is n-1.

In (20) we have used the fact, that the second sum is a complement to p0 and (17). Note, that (20) may be also
used to compute LQ provided LS is known or vice versa. It is also possible to find an average queue length LQQ
provided there is a queue. For this we need the conditional probability pn/q = P[queue length is n / there is a
queue]. To find the conditional probability, let’s use the general formula:

The average queue length is a parameter that represents the quality of service especially from user’s point of
view. Another parameters we need is the average time WS spent in the system and the average time WQ spent in
the queue. These parameters are necessary to compute costs caused by customers waiting for service. There is a
very important the so called Little’s formula, that gives the relation between the average number of customers
in the system LS and the average time WS spent in the system and between the average number of customers in
the queue LQ and the average time WQ spent in the queue:

LS = l WS LQ = l WQ (22,23)

This is the justification (not the exact proof) of the formula (22): let’s assume the average time spent in the
system is WS. During this time the average number of newcomers is WSl, because l is the arrival rate (average
number of arrivals per time unit). So at the instant a customer is leaving the systems, it sees (on the average) WSl
customers left in the system. Because in the stable state the average number of customers in the system is LS, we
have the above formula. Similar justification can be given for LQ and WQ (average number of arrivals during the
time spent in the queue is lWQ, that is the average number left in the queue when leaving the queue, that is LQ).
Using the Little’s formula we get these formulae:

(24,25)

There is another obvious relationship between the average time spent in the system and the average time spent
in the queue, because the total time spent is made of the time in the queue (that may be zero) and the time of the
service:

(26)

(26) can also be obtained from (24). Using the Little’s formula, it is possible to express a similar relation
between LS and LQ by multiplying both sides of (26) by l :

(27)

LSERV = r is the average number of customers being served (that of course must be less than one). For a customer
it is also important to know the probability, that the time spent in the system (or in the queue) will be greater
than a certain value. Together with the queue length this probability represents a quality of service from user’s
point of view. Without proof (that is less trivial) these formulae may be used:

(28)

Of course the probabilities of spending less than t in the system (or in the queue) are complements of the above
values to 1. Because the time spent is a continuous random variable, the probability of spending exactly the time
t in system (queue) is zero, but using the formulae (28), we can compute the probability, that the time spent will
be in certain range (t1, t2):

P[spending more than t1 and less than t2] = P[more than t1] - P[more than t2]

Вам также может понравиться