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

07 Queuing Models

This document discusses queuing models and their key elements. It introduces the Poisson and exponential distributions that are commonly used to model arrivals and service times in queuing systems. The three conditions of a Poisson process are defined. The document also covers pure birth and pure death processes, and provides examples of calculating probabilities using the Poisson distribution for situations like failures, stock levels, and birth certificates.

Uploaded by

shofi maharani
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
98 views

07 Queuing Models

This document discusses queuing models and their key elements. It introduces the Poisson and exponential distributions that are commonly used to model arrivals and service times in queuing systems. The three conditions of a Poisson process are defined. The document also covers pure birth and pure death processes, and provides examples of calculating probabilities using the Poisson distribution for situations like failures, stock levels, and birth certificates.

Uploaded by

shofi maharani
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 59

Queuing Models

SESSION 7
QUANTITATIVE METHODS
Principal Actors
• The Customer
• The Server
Basic Elements
1. Arrivals Distribution (single or bulk arrivals)
2. Service-time Distribution (single or bulk service)
3. Design of service facility (series (tandem), parallel, or network
stations)
Basic Elements
4. Service discipline (FCFS, LCFS, SIRO) and service priority
◼ FCFS: First Come, First Served
◼ LCFS: Last Come, First Served
◼ SIRO: Service In Random Order
5. Queue size (finite or infinite)
Basic Elements
6. Calling Source (finite or infinite)
◼ The population from which the customers come
7. Human behavior (jockeying, balking (refusing), and reneging
(leaving), but not cheating)
Poisson and Exponential Distributions

• Poisson Process satisfies the following three conditions:


• Condition 1: the probability of an event (arrival or
departure (of a customer)) occurring between (the time
factor) t and t + s depends only on the length of s
• Probability of an event does not depend on t or number of event
occurring during the time period (0, t)
Poisson and Exponential Distributions
• Condition 2: The probability of an event occurring during
a very small time interval h is positive but less than one
• Condition 3: At most one event can occur during a very
small time interval h
Poisson and Exponential Distributions
• The Poisson Process:
• The count (number) of events during a given time interval is
Poisson
• The time interval between successive event is Exponential
Poisson and Exponential
Distributions
• Probability density function (pdf) of the time interval t
between the occurrence of successive event, t  0 = f(t)
𝑓 𝑡 = 𝛼𝑒 −𝛼𝑡 , 𝑡 ≥ 0 (Exponential)

Time Expectation = Mean value of Time = E(t) = 1/

The rate at which events occur = 


Poisson and Exponential Distributions

• Probability of n events occurring during time t = pn(t)


(𝛼𝑡)𝑛 𝑒 −𝛼𝑡
• 𝑝𝑛 𝑡 = , n = 0, 1, 2, … (Poisson)
𝑛!
Poisson’s Forgetfulness
• For S = the time interval since the occurrence of the last
event
• And in a duration of T hour onwards, the probability of
an even is given as
• 𝑃 𝑡 > 𝑇 + 𝑆 𝑡 > 𝑆) = 𝑃(𝑡 > 𝑇), since t is exponential
𝑃 𝑡 >𝑇+𝑆 𝑡 >𝑆 𝑒 −𝛼(𝑇+𝑆)
𝑃 𝑡>𝑇=𝑆𝑡>𝑆 = = −𝛼𝑆 = 𝑒 −𝛼𝑇 = 𝑃(𝑡 > 𝑇)
𝑃(𝑡 > 𝑆) 𝑒
Characteristics of Poisson Distribution
• Forgetfulness or lack of memory does exist means that Poisson
distribution is completely random
• Mean of Poisson Distribution = Variance of Poisson Distribution
Example
• A server machine always has a standby unit immediate
replacement upon failure
• The time to failure of the machine or its standby unit is
exponential with mean = 10 hours
• Failures thus occur at the rate of 0.1 event per hour ,  =
0.1
• The exponential distribution of the time to failure is thus
given as 𝑓 𝑡 = 0.1 𝑒 −0.1𝑡 , 𝑡 ≥0
Example
•  = 0.1
• The Poisson distribution of the number of failure during a
period T is given as
(0.1 𝑇)𝑛 𝑒 −0.1𝑇
• 𝑝𝑛 𝑇 = , n = 0, 1, 2, …
𝑛!
• with such f(t) and pn(t), we could compute the probability
that a failure will take place within 5 hours (the first 5
hours)
Example

• The probability that a failure will take place within 5


hours (the first 5 hours) is given as:
5
• 𝑃 𝑡 5 = ‫׬‬0 0.1 𝑒 −0.1𝑡 𝑑𝑡 = 1 − 𝑒 −0.5 = 0.393469 …
• 𝑓 𝑡 = 0.1 𝑒 −0.1 𝑡 , t0
Example

• with such f(t) and pn(t), we could also compute the


probability that a failure will occur after 6 hours from
now (T = 6), given the last failure happened 3 hours
earlier (S = 3)
• 𝑃 𝑡 > 6 + 3 𝑡 > 3 = 𝑃 𝑡 > 6 = 𝑒 −0.1 ×6 = 𝑒 −0.6 =
0.54881 …
Relationship between Poisson and Exponential
Distributions
• No failure (event) occurs in a day (24 hours)
(0.1 × 24)0 𝑒 −0.1×24
𝑝0 24 = = 𝑒 −2.4 = 0.09071 …
0!
• An inter-failure time of at least 24 hours

P t  24 = ‫׬‬24 0.1 𝑒 −0.1𝑡 𝑑𝑡 = 𝑒 −2.4
Pure Birth and Pure Death Processes

• A birth occurs when a customer enters the queue system


• A death happens if a customer leaves the queue
• The pure birth process is the birth without death,
meaning the arrival without the departure
• The process of pure death means the death without birth,
meaning the departure without the arrival.
Pure Birth and Pure Death Processes

• Pure Birth: customers arrive and never leave


• Pure Death: customers are withdrawn from an initial
stock and none arrives in the system
• Both occur in a completely random fashion
Pure Birth Model
• Issuing birth certificates for newborn babies
•  = rate at which birth certificates are issued
• For n birth during t time period, the probability is given as
(𝜆𝑡)𝑛 𝑒 −𝜆𝑡
• 𝑝𝑛 𝑡 = , n = 0, 1, 2, …
𝑛!
• Expected number of arrivals during t unit time = E(t) = t
Example
• One birth occurs every 7 minutes on the average
24×60
• 𝜆= = 205.7 births/day
7

• Probability of n birth during t (day)


(205.7×𝑡)𝑛 𝑒 −205.7𝑡
• 𝑝𝑛 𝑡 = , n = 0, 1, 2, … (day)
𝑛!
Example
• One birth occurs every 7 minutes on the average
• Probability to issue 10 birth certificates in one hour
60
• 𝜆= = 8.57
7

(8.57 ×1)10 𝑒 −8.57×1


• 𝑝10 1 = = 0.11172 …
10!
Pure Death
• Stock Problem
• N units of an item are stocked at the start of the
week
• Customers withdraw at the rate μ unit per day
• The withdraw process occurs randomly
Pure Death
• The probability for having n items remaining in stock
after time t is given as truncated Poisson distribution:

(𝜇𝑡)𝑁−𝑛 𝑒 −𝜇𝑡
• 𝑝𝑛 𝑡 = , 𝑛 = 1, 2, … 𝑁
(𝑁 −𝑛)!

• 𝑝0 𝑡 = 1 − σ𝑁
𝑛=1 𝑝𝑛 (𝑡)
Example • At the beginning of each week 15 units of an
inventory item are stocked for use during the week
• Withdrawals from stock occur only during the first 6
days (business is closed on Sundays) t = 6
• Withdrawals follows Poisson distribution with mean
= 3 units/day
• When the stock level reaches = 5 units, a new order of
15 units is placed for delivery at the beginning of the
next week N = 5; n = 5
• Because of the nature of the items, all units left at the
end of the week are discarded
• What is the Probability of having 5 unit (the reorder level
stock) on day t
• μ = 3 units/day

(𝜇𝑡)𝑁−𝑛 𝑒 −𝜇𝑡
• 𝑝𝑛 𝑡 = , 𝑛 = 1, 2, … 𝑁
(𝑁 −𝑛)!
(3)10 𝑒 −3
• 𝑝5 1 = = 0.0008101… = 0.0008
10!
(6)10 𝑒 −6
• 𝑝5 2 = = 0.0413030… = 0.0413
10!
(9)10 𝑒 −9
• 𝑝5 3 = = 0.0118580… = 0.1186
10!
• What is the Probability of having 5 unit (the reorder level
stock) on day t
• μ = 3 units/day

(𝜇𝑡)𝑁−𝑛 𝑒 −𝜇𝑡
• 𝑝𝑛 𝑡 = , 𝑛 = 1, 2, … 𝑁
(𝑁 −𝑛)!
(12)10 𝑒 −12
• 𝑝5 4 = = 0.10483… = 0.1048
10!
(1)10 𝑒 −10
• 𝑝1 5 = = 0.048610… = 0.0486
1!
(18)10 𝑒 −18
• 𝑝5 6 = = 0.014985… = 0.0150
10!
The peak

t (days) 1 2 3 4 5 6

μt 3 6 9 12 15 18
p5(t) 0.0008 0.0413 0.1186 0.1048 0.0486 0.0150

p5(t) = probability of reordering on day t

Using Excel:
Poisson(N-n= 10; t = 3, 6, 9, 12, 15, 18)
Poisson Table (Excel)

μt
N-n
3 6 9 12 15 18
0 0.0498 0.0025 0.0001 0.0000 0.0000 0.0000
1 0.1494 0.0149 0.0011 0.0001 0.0000 0.0000
2 0.2240 0.0446 0.0050 0.0004 0.0000 0.0000
3 0.2240 0.0892 0.0150 0.0018 0.0002 0.0000
4 0.1680 0.1339 0.0337 0.0053 0.0006 0.0001
5 0.1008 0.1606 0.0607 0.0127 0.0019 0.0002
6 0.0504 0.1606 0.0911 0.0255 0.0048 0.0007
7 0.0216 0.1377 0.1171 0.0437 0.0104 0.0019
8 0.0081 0.1033 0.1318 0.0655 0.0194 0.0042
9 0.0027 0.0688 0.1318 0.0874 0.0324 0.0083
10 0.0008 0.0413 0.1186 0.1048 0.0486 0.0150
• Probability of reordering by (at the latest on) day t =
Probability for having  the order level (n  5)
• For day t = 1, 2, 3, 4, 5, 6
• Compute:
pn  5(t) = p1(t) + p2(t) + p3 (t) + p4(t) + p5(t) + p6(t)
𝑝1 𝑡 = 1 − σ𝑁−𝑛−1
𝑡=0 𝑝1 (𝑡) 𝑝4 𝑡 = 1 − σ𝑁−𝑛−1
𝑡=0 𝑝4 (𝑡)
𝑝2 𝑡 = 1 − σ𝑁−𝑛−1
𝑡=0 𝑝2 (𝑡) 𝑝5 𝑡 = 1 − σ𝑁−𝑛−1
𝑡=0 𝑝5 𝑡
𝑝3 𝑡 = 1 − σ𝑁−𝑛−1
𝑡=0 𝑝3 (𝑡) 𝑝6 𝑡 = 1 − σ𝑁−𝑛−1
𝑡=0 𝑝6 (𝑡)
Check it!

t (days) 1 2 3 4 5 6

μt 3 6 9 12 15 18
p5(t) 0.0011 0.0839 0.4126 0.7576 0.9301 0.9847
Poisson Table (Excel)
μt
N-n
3 6 9 12 15 18
0 0.0498 0.0025 0.0001 0.0000 0.0000 0.0000
1 0.1494 0.0149 0.0011 0.0001 0.0000 0.0000
2 0.2240 0.0446 0.0050 0.0004 0.0000 0.0000
3 0.2240 0.0892 0.0150 0.0018 0.0002 0.0000
4 0.1680 0.1339 0.0337 0.0053 0.0006 0.0001
5 0.1008 0.1606 0.0607 0.0127 0.0019 0.0002
6 0.0504 0.1606 0.0911 0.0255 0.0048 0.0007
7 0.0216 0.1377 0.1171 0.0437 0.0104 0.0019
8 0.0081 0.1033 0.1318 0.0655 0.0194 0.0042
9 0.0027 0.0688 0.1318 0.0874 0.0324 0.0083
SUM 0.9989 0.9161 0.5874 0.2424 0.0699 0.0154
1 - SUM 0.0011 0.0839 0.4126 0.7576 0.9301 0.9846
10 0.0008 0.0413 0.1186 0.1048 0.0486 0.0150
• Average number of inventory unit will be discarded at the
end of the week
• Compute the expected number of unit available on day 6
• With μt = 3  6 = 18
15

𝐸 𝑛 𝑡 = 6 = ෍ 𝑛𝑝𝑛 6 = 0.5544
𝑛=0
Poisson Table (Excel)
N-n p(μt = 18) n np
0 0.0000 15 0.0000
1 0.0000 14 0.0000
2 0.0000 13 0.0000
3 0.0000 12 0.0002
4 0.0001 11 0.0007
5 0.0002 10 0.0024
6 0.0007 9 0.0065
7 0.0019 8 0.0148
8 0.0042 7 0.0291
9 0.0083 6 0.0500
10 0.0150 5 0.0749
11 0.0245 4 0.0981
12 0.0368 3 0.1103
13 0.0509 2 0.1019
14 0.0655 1 0.0655
15 0.0786 0 0.0000
sum 0.5544
Queues with Combined Arrivals
and Departures
Single Server

System

Queue or Service
waiting Facility
line
Arriving Departing
x x x x x 1
Customers Customers
.
.
.
Queues with Combined Arrivals
and Departures

Serial Servers
System
Queue or Service
waiting Facility
line
Arriving Departing
Customers x x x 1 2 … c
Customers
Queues with Combined Arrivals and
Departures
Parallel Servers
System
Queue or Service
waiting line Facility
1

Arriving 2 Departing
x x x x x
Customers . Customers
.
.

c
Queues with Combined Arrivals
and Departures
Network
Servers System
Queue or Service
waiting Facility
line

Arriving
x x x x …
Customers
Departing
Customers

… c
Queues with Combined Arrivals and
Departures
• Number of customers are serviced by c numbers of parallel servers
• Number of customers = number of customers in queue + number of customers in
service
Generalized Poisson Model

• Poisson Queues with state-dependent arrival and departure rates

n-1 n

... n–1 n n +1 ...

μn μn+1
Generalized Poisson Model
• pn: the steady-state probability of n customers in a system
• n: arrival rate
• μn : departure rate
Generalized Poisson Model

𝜆𝑛−1 𝜆𝑛−2 . . . 𝜆0
𝑝𝑛 = 𝑝0 , n = 1,2, . . .
𝜇𝑛 𝜇𝑛−1 . . . 𝜇0

𝑝0 = ෍ 𝑝𝑛 = 1
𝑛=0
Example
• A single server queuing with constant arrival
rate n = 3 arrivals per hour and departure rate
μn = 8 departures per hour for all n  0
𝑛 𝑛
𝜆 3
𝑝𝑛 = 𝑝0 = 𝑝0 = 0.375𝑛 𝑝0, 𝑛=0,1,2,…
𝜇 8

𝑝0 = ෍ 𝑝𝑛 = 1
𝑛=0

𝑝0 (1 + 0. 375 + 0. 3752 + 0. 3753 +. . . ) = 1

𝑝0 + 0. 375p0 + 0. 3752 p0 + 0. 3753 p0 +. . . = 1

1
𝑝0 =1 Geometric Series
1 − 0.375
𝑝0 = 0.625

𝑝𝑛 = 0.375𝑛 𝑝0 , 𝑛 = 1,2, …
Multiplication & Summation (Excel)

0.375
p0 0.625
n 0.375^n (0.375^n)*p
0 1 0.6250
1 0.3750 0.2344
2 0.1406 0.0879
3 0.0527 0.0330
4 0.0198 0.0124
5 0.0074 0.0046
6 0.0028 0.0017
7 0.0010 0.0007
8 0.0004 0.0002
9 0.0001 0.0001
10 0.0001 0.0000
11 0.0000 0.0000
sum 1
Steady-State Measures of Performance
• Ls: expected number of customers in system
• Lq: expected number of customers in queue
• Ws: expected waiting time in system
• Wq: expected waiting time in queue
• 𝑐ҧ ∶ utilization (of number of server)
•  : departure rate
•  : arrival rate
Steady-State Measures of
Performance

𝐿𝑠
𝑝𝑛 𝐿𝑠 = ෍ 𝑛𝑝𝑛 𝑊𝑠 =
𝜆eff
𝑛=0

1
𝑊𝑞 = 𝑊𝑠 − 𝐿𝑞 = 𝜆eff 𝑊𝑞 𝑐lj = 𝐿𝑠 − 𝐿𝑞
𝜇
𝐿𝑠 = σ∞
𝑛=0 𝑛𝑝𝑛 = 0 × 0.6250 + 1 × 0.2344 + 2 × 0.0879 + ... +
0.0000 = 0.6
𝐿𝑠 0.6
𝑊𝑠 = = = 0.2
𝜆eff 3
1 1
𝑊𝑞 = 𝑊𝑠 − = 0.2 − = 0.075
𝜇 8
𝐿𝑞 = 𝜆eff 𝑊𝑞 = 3 × 0.075 = 0.225

Single server, c = 1
𝑐lj = 𝐿𝑠 − 𝐿𝑞 = 0.6 − 0.225 = 0.375

percent utilization = × 100 % = 0.375 × 100 = 37.5 (%)
c
Multiplication & Summation (Excel)

n pn n*pn
0 0.6250 0.0000
1 0.2344 0.2344
2 0.0879 0.1758
3 0.0330 0.0989
4 0.0124 0.0494
5 0.0046 0.0232
6 0.0017 0.0104
7 0.0007 0.0046
8 0.0002 0.0020
9 0.0001 0.0008
10 0.0000 0.0003
11 0.0000 0.0001
Sum = Ls 0.5999
0.6
Specialized Poisson Queues

• Notation (a/b/c) : (d/e/f)


• a = arrivals distribution
• b = service time (or departures) distribution
• c = number of parallel servers
(c = 1, 2,…, )
Specialized Poisson Queues
• Notation (a/b/c) : (d/e/f)
• d = service discipline (incl.FCFS, LCFS, SIRO)
• e = maximum number of customers allowed in system (in queue
and in service)
• f = size of system
Values for (a) and (b)
• M = Poisson (Markovian) arrival or departure distribution
• D = Constant or Deterministic inter-arrival or service time
• GD: General distribution of departures (or service time)
Notation: Example
• (M/D/10) = (GD/N/ )
• Poisson distribution of arrival
• Constant Service Time
• 10 parallel servers
• GD general distribution of service discipline (FCFS,
LCFS, SIRO)
• N maximum number of customers
• Infinite capacity () of source generating the
arriving customer
Specialized Poisson Queues
1. (M/M/1):(GD//)
2. (M/M/1):(GD/N/)
3. (M/M/c):(GD//)
4. (M/M/c):(GD/N/), c  N

5. (M/ /):(GD//) = self-service model


6. (M/M/R):(GD/K/K) = R < K machine servicing model
Non-Poisson Queues
1. Queue with priorities for service
2. Tandem or Series Queues
Queue with priorities for service
1. (Mi/Gi/1) : (NPRP//)
2. (Mi/M/c) : (NPRP//)
Nonpreemptive Priority (NPRP): higher priority task/customer
should wait until the recent task terminates
Preemptive Priority (PRP): as soon as the higher priority comes, the
server stops the recent task and serves the higher priority task
Tandem or Series Queues
1. Two station series model with zero capacity

System

Station Station
Input Output
1 2
Tandem or Series Queues
2. k-station Series Model with Infinite Queue Capacity

1 2 k

1 2 k

 .  .   . 
. . .
Input . . . Output

c1 c2 ck

Station 1 Station 2 Station k


The End
• This is the end of Queuing Models

You might also like