0% found this document useful (0 votes)
55 views

Chapter 20 - Queueing Theory

1) This chapter discusses queueing theory and mathematical models for waiting lines or queues. It introduces concepts like arrival and service processes, queue disciplines, the Kendall notation for describing queueing systems, and birth-death processes. 2) A birth-death process models the state of a queueing system over time, where arrivals increase the state (births) and services decrease it (deaths). The steady-state probabilities of this process can be used to analyze queueing systems. 3) The M/M/1 queue with Poisson arrivals and exponential service is analyzed using a birth-death process. Key metrics like expected queue length (L), waiting time (W), and Little's law (L =

Uploaded by

ramixz
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
55 views

Chapter 20 - Queueing Theory

1) This chapter discusses queueing theory and mathematical models for waiting lines or queues. It introduces concepts like arrival and service processes, queue disciplines, the Kendall notation for describing queueing systems, and birth-death processes. 2) A birth-death process models the state of a queueing system over time, where arrivals increase the state (births) and services decrease it (deaths). The steady-state probabilities of this process can be used to analyze queueing systems. 3) The M/M/1 queue with Poisson arrivals and exponential service is analyzed using a birth-death process. Key metrics like expected queue length (L), waiting time (W), and Little's law (L =

Uploaded by

ramixz
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 55

Chapter 20

Queueing Theory

to accompany
Operations Research: Applications and Algorithms
4th edition
by Wayne L. Winston

Copyright (c) 2004 Brooks/Cole, a division of Thomson Learning, Inc.


Description
Each of us has spent a great deal of time waiting in lines.

In this chapter, we develop mathematical models for waiting


lines, or queues. Thank you for holding.
Hello...are you there?

© 1995 Corel Corp.


2
20.1 Some Queueing Terminology
 To describe a queueing system, an input
process and an output process must be
specified.
 Examples of input and output processes are:
Situation Input Process Output Process
Bank Customers arrive at Tellers serve the
bank customers
Pizza parlor Request for pizza Pizza parlor send
delivery are out truck to deliver
received pizzas

3
The Input or Arrival Process
 The input process is called arrival process.
 Arrivals are called customers.
 We assume that no more than one arrival can
occur at a given instant.
 If more than one arrival can occur at a given
instant, we say that bulk arrivals are allowed.
 Models in which arrivals are drawn from a small
population are called finite source models.
 If a customer arrives but fails to enter the
system, we say that the customer has balked.

4
The Output or Service Process
 To describe the output process of a queueing
system, we usually specify a probability
distribution – the service time distribution –
which governs a customer’s service time.
 Servers can be arranged in parallel or in
series.
 Servers are in parallel if all server provide the
same type of service and a customer need only
pass through one server to complete service.
 Servers are in series if a customer must pass
through several servers before completing
service.
5
The Queue Discipline
 The queue discipline describes the method used
to determine the order in which customers are
served.
 The most common queue discipline is the FCFS
discipline (first come, first served), in which
customers are served in the order of their arrival.
 Under the LCFS discipline (last come, first
served), the most recent arrivals are the first to
enter service.
 If the next customer to enter service is randomly
chosen from those customers waiting for service, it
is referred to as the SIRO discipline (service in
random order).
6
 Some systems use priority queueing
disciplines.
 A priority discipline classifies each arrival into
one of several categories.
 Each category is then given a priority level, and
within each priority level, customers enter
service on an FCFS basis.
 Another factor that has an important effect on
the behavior of a queueing system is the
method that customers use to determine which
line to join.

7
20.2 Modeling Arrival and Service
Processes
 In modeling the arrival process, we assume
interarrivals times are continuous random
variables described by the random variable A
having a density function a(t).
 The most common choice for A is the
exponential distribution with parameter λ
and density a(t) = λe-λt.
 We define λ to be the arrival rate, which will
have units of arrivals per hour.
 We define 1/λ to be the mean or average
interarrival time.

8
Modeling the Service Process
 We assume that the service times of different
customers are independent random variables,
and that each customer’s service time is
governed by a random variable S having a
density function s(t).
 The most common choice for S is the
exponential distribution with parameter µ
and density s(t) = µe-µt.
 We let 1/µ be then mean service time for a
customer.
 We define µ to be the service rate, which will
have units of customers per hour.
9
The Kendall-Lee Notation for
Queueing Systems
 Standard notation used to describe many
queueing systems.
 The notation is used to describe a queueing
system in which all arrivals wait in a single line
until one of s identical parallel servers is free.
Then the first customer in line enters service,
and so on.
 To describe such a queueing system, Kendall
devised the following six characters notation:
1/2/3/4/5/6

10
 The first characteristic specifies the nature of
the arrival process. The following standard
abbreviations are used:
M = Interarrival times are independent, identically
distributed (iid)
D = Interarrival times are iid and deterministic
Ek = Interarrival times are iid Erlangs with shape
parameter k.
GI = Interarrival times are iid and governed by some
general distribution

11
 The second characteristic specifies the nature
of the service times:
M = Service times are iid and exponentially distributed
D = Service times are iid and deterministic
Ek = Service times are iid Erlangs with shape parameter
k.
G = Service times are iid and governed by some
general distribution

12
 The third characteristic is the number of
parallel servers. The fourth characteristic
describes the queue discipline:
 FCFS = First come, first served
 LCFS = Last come, first served
 SIRO = Service in random order
 GD = General queue discipline
 The fifth characteristic specifies the maximum
allowable number of customers in the system.
 The sixth characteristic gives the size of the
population from which customers are drawn.

13
 In many important models 4/5/6 is GD/∞/∞. If
this is the case, then 4/5/6 is often omitted.
 As an example, M/E2/8/FCFS/10/∞ might
represent a health clinic with 8 doctors,
exponential interarrival times, two-phase
Erlang service times, an FCFS queue discipline,
and a total capacity of 10 patients.

14
20.3 Birth-Death Processes
 We subsequently use birth-death processes to
answer questions about several different types
of queueing systems.
 A birth-death process is a continuous-time
stochastic process for which the system’s state
at any time is a nonnegative integer.
 We define the number of people present in any
queueing system at time t to be the state of
the queueing systems at time t.
 We call πj the steady state, or equilibrium
probability, of state j.

15
 The variable λj is called the birth rate in state j.
In most queuing systems, a birth is simply an
arrival.
 The variable µj is the death rate in state j. In
most queuing systems, a death is a service
completion

Rate transition diagram for a birth-death process


16
Derivation of Steady-State Probabilities
for Birth-Death Processes

 We now show how the πj’s may be determined


for an arbitrary birth-death process.
 From the diagram, we have

 The above equations are often called the flow


balance equations, or conservation of flow
equations, for a birth-death process.

17
Solution of Birth-Death Flow Balance
Equations

 If is finite, we can solve for π0:

 If is infinite, then no steady-state distribution


exists.
 The most common reason for a steady-state
failing to exist is that the arrival rate is at least
as large as the maximum rate at which
customers can be served.

18
20.4 The M/M/1/GD/∞/∞ Queueing
System and the Queueing Formula L=λW

 The M/M/1 can be modelled as a birth-death


process with the following parameters

 We define . We call the traffic intensity of


the queueing system.
 We now assume that Thus

19
Derivation of L
 Throughout the rest of this section, we assume
that , ensuring that a steady-state probability
distribution does exist.
 The steady state has been reached, the
average number of customers in the queueing
system (call it L) is given by

20
Derivation of Lq
 In some circumstances, we are interested in
the expected number of people waiting in line
(or in the queue).
 We denote this number by Lq.

21
Derivation of Ls
 Also of interest is Ls, the expected number of
customers in service.

 Note that

22
The Queueing Formula L=λW
 We define W as the expected time a customer
spends in the queueing system, including time
in line plus time in service, Wq as the expected
time a customer spends waiting in line, and W
= average time a customer spends in service.
 By using a powerful result known as Little’s
queueing formula, W, Wq, and Wsmay be
easily computed from L, Lq, and Ls:
L = λW
Lq = λWq
Ls = λWs
23
Example 3

24
 M/M/1
 lambda = 10 cars per hour
 1/mu = 4/1 minutes = 4/60 hours so
 mu = 15 cars per hour
 Rho = lambda/mu = 10/15 = 2/3 < 1
1) P(server idle) = P(no customer) = pi0 =(1-rho)
= 1/3
2) Lq = lambda^2/(mu(mu-lambda)) = … cars
3) W = 1/(mu – lambda) = 0.2 hours
4) Average number processed per hour = (2/3)
(15) = 10 customers 25
 Problems in which a decision maker must
choose between alternative queueing systems
are called queueing optimization problems.
Operations research:
Prescriptive model: LP, IP, NLP, …
Descriptive model: Queueing, simulation, …

26
Example 5

Cost per hour = labor cost per hour + delay cost


per hour
M/M/1, lambda = 10, 1/mu = 5 minutes so mu =
12 machinists per hour
27
Clerk by himself
Cost per hour = labor cost per hour + delay cost
per hour
M/M/1, lambda = 10, 1/mu = 5 minutes so mu =
12 minutes
Labor cost = 6
Delay cost = 10*L = 10*lambda/(mu-lambda) =
10*(10)/(12 – 10) = 50
Total cost = 6 + 50 = 56 $/hour

28
Clerk + helper
Cost per hour = labor cost per hour + delay cost
per hour
M/M/1, lambda = 10, 1/mu = 4 minutes so mu =
15 machinists per hour
Labor cost = 6 + 4 = 10
Delay cost = 10*L = 10*lambda/(mu-lambda) =
10*(10)/(15 – 10) = 20
Total cost = 10 + 20 = 30 $/hour

29
20.5 The M/M/1/GD/c/∞ Queueing
System
 The M/M/1/GD/c/∞ queueing system is
identical to the M/M/1/GD/∞/∞ system with a
total capacity of c customers.
 The M/M/1/GD/c can be modelled as a birth-
death process with the following parameters

 The steady-state probabilities are given by

30
20.5 The M/M/1/GD/c/∞ Queueing
System
 Some of the system characteristics

 For the M/M/1/GD/c/∞ system, a steady state


will exist even if λ ≥ µ.
 This is because, even if λ ≥ µ, the finite
capacity of the system prevents the number of
people in the system from “blowing up”.

31
Example 8

1) M/M/1/GD/c 2) =…

c = 10
Lambda = 20
Mu = 5
.
.
.
32
20.6 The M/M/s/GD/∞/∞ Queueing
System
 We now consider the M/M/s/GD/∞/∞ system.
 If j ≤ s customers are present, then all j
customers are in serve; if j >s customers are
present, then all s servers are occupied, and j
– s customers are waiting in line.
 The M/M/s/GD/∞/∞ system can be modeled
as a birth-death process with parameters

33
 We define =λ/(sµ). For <1, we have the
following steady state probabilities

34
A Spreadsheet for the
M/M/s/GD/∞/∞ Queueing System
 The probability that all servers are busy is
given by

 Then

35
Probability that all servers are
busy

36
Example 9

Prob a server is idle = pi_0 + .5*pi_1 = 0.1111 + .5* 0.1778

37
Example 10

38
 To determine the number of servers that
minimizes expected cost per minute we would
like to vary the number of servers (starting
with 5) and computer expected cost per
minutes for different number of servers.
 This is easily done with a one-way data
table.

39
20.7 The M/G/∞/GD/∞/∞ and
GI/G/∞/GD/∞/∞ Models
 There are many examples of systems in which
a customer never has to wait for service to
begin.
 In such a system, the customer’s entire stay in
the system may be thought of as his or her
service time.
 Since a customer never has to wait for service,
there is, in essence, a server available for each
arrival, and we may think of such a system as
an infinite-server (or self-service).

40
 Using Kendall-Lee notation, an infinite server
system in which interarrival and service times
may follow arbitrary probability distributions
may be written as GI/G/∞/GD/∞/∞ queueing
system.

41
 For GI/G/∞, we have:

 For M/G/∞, we have:

42
Example 11

Lambda = 3 shops per year; 1/mu = 10

L = lambda/mu = 3(10) = 30 shops

Pi_25 =

43
20.8 The M/G/1/GD/∞/∞ Queueing
System
 Next, we consider a single-server queueing
system in which interarrival times are
exponential, but the service time distribution S
need not be exponential.
 Let λ be the arrival rate (assumed to be
measured in arrivals per hour).
 Also define 1/µ = E(S) and σ2 = var S.
 In Kendall’s notation, such a queueing system
is described as an M/G/1/GD/∞/∞ queueing
system.

44
 An M/G/1/GD/∞/∞ queueing system is not a
birth-death process, because the probability
that a service completion occurs between t and
t+Δt when the state of the system at time t is j
depends on the length of time since the last
service completion.
 Determination of the steady-state probabilities
for M/G/1/GD/∞/∞ queueing system is a
difficult matter.
 Fortunately, however, utilizing the results of
Pollaczek and Khinchin, we may determine Lq,
L, Ls, Wq, W, Ws.
45
 Pollaczek and Khinchin showed that for the
M/G/1/GD/∞/∞ queueing system,

 It can also be shown that π0, the fraction of the


time that the server is idle, is .
 The result is similar to the one for the
M/M/1/GD/∞/∞ system.

46
Example
 Consider an M/M/1 with and Then = ,

 For M/G/1, E(S) = 1/8, var(S) = 1/64

47
 For M/D/1 , E(S) = 1/8, var(S) = 0

 In this M/D/1, a typical customer will spend


only half as much time in line as in an M/M/1
with identical arrival and service rates. As this
example shows, even if mean service times are
not decreased, a decrease in the variability of
service times can substantially reduce queue
size and customer waiting time.

48
20.9 Finite Source Models: The
Machine Repair Model
 Most models studied have displayed arrival
rates that were independent of the state of the
system.
 A situation where the assumption of the state-
independent arrival rate is invalid happens
when arrivals to a system are drawn from a
small population.
 Models in which arrivals are drawn from a
small population are called finite source
models.

49
 In the machine repair problem, the system
consists of K machines and R repair people.
 At any instant in time, a particular machine is in
either good or bad condition.
 The length of time that a machine remains in
good condition follows an exponential distribution
with rate λ.
 Whenever a machine breaks down the machine is
sent to a repair center consisting of R repair
people.

50
 The repair center services the broken machines
as if they were arriving at an M/G/R/GD/∞/∞
system.
 Thus, if j ≤ R machines are in bad condition, a
machine that has just broken will immediately be
assigned for repair; if j > R machines are broken,
j – R machines will be waiting in a single line for
a repair worker to become idle.
 The time it takes to complete repairs on a broken
machine is assumed exponential with rate µ.
 Once a machine is repaired, it returns to good
condition and is again susceptible to breakdown.
51
 The machine repair model may be modeled as
a birth-death process, where the state j at any
time is the number of machines in bad
condition:

 Note that a birth corresponds to a machine


breaking down and a death corresponds to a
machine having just been repaired

52
 If we define = λ /µ, an application of steady-
state probability distribution:

 is found first from

53
 Unfortunately, there are no simple formulas for
L, Lq, W, Wq.
 The best we can do is express these quantities
in terms of the πj’s:

where .

54
Example 12

K = 5, 1/lambda = 30 days, R = 2, 1/mu = 3 days


L = number of broken down cars

1) K - L = number of cars in good condition = 5 – 0.4648


2) W = 3.0746 days
3) pi_0 + 0.5pi_1 = 0.6186 + 0.5(0.3093)
55

You might also like