COM 426 SIMULATION & MODELING

COM 426 SIMULATION &
MODELING
Chapter 5 Queuing Systems
Introduction
2




The basic phenomenon of queuing arises whenever a
shared facility needs to be accessed for service by a
large number of jobs or customers.
The primary tool for studying these problems [of
congestions] is known as queuing theory.
The study of the phenomena of standing, waiting, and
serving, and we call this study Queuing Theory.
Any system in which arrivals place demands upon a
finite capacity resource may be termed a queuing
system.
COM 426 Simulation & Modeling
March 17, 2015
Applications
•
•
•
•
•
Telecommunications
Traffic control
Determining the sequence of computer operations
Predicting computer performance
Health services (eg. control of hospital bed
assignments)
• Airport traffic, airline ticket sales
• Layout of manufacturing systems.
3
COM 426 Simulation & Modeling
March 17, 2015
The Queuing Model
Queuing System
Queue
Server
• Use Queuing models to
– Describe the behavior of queuing systems
– Evaluate system performance
• A Queue System is characterized by
– Queue (Buffer): with a finite or infinite size
• The state of the system is described by the Queue Size
4
– Server: with a given processing speed
COM
426 Simulation
& Modeling
March 17,
2015
– Events: Arrival (birth) or
Departure
(death)
with given
rates
Characteristics
5

Arrival Process
 The
distribution that determines how the tasks arrives in
the system.

Service Process
 The

distribution that determines the task processing time
Number of Servers
 Total
number of servers available to process the tasks
COM 426 Simulation & Modeling
March 17, 2015
arrival process:
6
 how
customers arrive e.g. singly or in groups (batch or
bulk arrivals)
 how the arrivals are distributed in time (e.g. what is the
probability distribution of time between successive
arrivals (the interarrival time distribution))
 whether there is a finite population of customers or
(effectively) an infinite number

The simplest arrival process is one where we have
completely regular arrivals (i.e. the same constant
time interval between successive arrivals).
COM 426 Simulation & Modeling
March 17, 2015

7


A Poisson stream of arrivals corresponds to arrivals
at random. In a Poisson stream successive customers
arrive after intervals which independently are
exponentially distributed.
The Poisson stream is important as it is a convenient
mathematical model of many real life queuing
systems and is described by a single parameter the average arrival rate.
Other important arrival processes are scheduled
arrivals; batch arrivals; and time dependent arrival
rates (i.e. the arrival rate varies according to the
time of day).
COM 426 Simulation & Modeling
March 17, 2015
service mechanism:

8












a description of the resources needed for service to begin
how long the service will take (the service time distribution)
the number of servers available
whether the servers are in series (each server has a separate queue) or
in parallel (one queue for all servers)
whether preemption is allowed (a server can stop processing a customer
to deal with another "emergency" customer)
First-come-first-served(FCFS)
Last-come-first-served(LCFS)
Shortest processing time first(SPT)
Shortest remaining processing time first(SRPT)
Shortest expected processing time first(SEPT)
Shortest expected remaining processing time first(SERPT)
Biggest-in-first-served(BIFS)
Loudest-voice-first-served(LVFS)
COM 426 Simulation & Modeling
March 17, 2015
Queue characteristics:
9
 how,
from the set of customers waiting for service, do we
choose the one to be served next (e.g. FIFO (first-in firstout) - also known as FCFS (first-come first served); LIFO
(last-in first-out); randomly) (this is often called the queue
discipline)
 do we have:
 balking
(customers deciding not to join the queue if it is too
long)
 reneging (customers leave the queue if they have waited too
long for service)
 jockeying (customers switch between queues if they think they
will get served faster by so doing)
 a queue of finite capacity or (effectively) of infinite capacity
COM 426 Simulation & Modeling
March 17, 2015
Typical Distributions
10





M :Markovian (Exponential / poisson)
Ek : Erlang with parameter k
Hk : Hyperexponential with parameter k(mixture of
k exponentials)
D : Deterministic(constant)
G : General(all)
COM 426 Simulation & Modeling
March 17, 2015
Model Notations
11

Kendall’s Notation: A/S/m/B/K/SD
 A:
arrival process
 S: service time distribution
 m: number of servers
 B: number of buffers(system capacity)
 K: population size
 SD: service discipline
COM 426 Simulation & Modeling
March 17, 2015
12
Standard: A/B/C/D/E,F






A represents the probability distribution for the arrival
process
B represents the probability distribution for the service
process
C represents the number of channels (servers)
D represents the maximum number of customers allowed
in the queuing system (either being served or waiting
for service)
E represents the maximum number of customers in total
F represents the queue discipline
COM 426 Simulation & Modeling
March 17, 2015
Examples
13

M/M/3/20/1500/FCFS
 Time
between successive arrivals is exponentially
distributed
 Service times are exponentially distributed
 Three servers
 20 buffers = 3 service + 17 waiting
 After
20, all arriving jobs are lost
 Total
of 1500 jobs that can be serviced
 Service discipline is first-come-first-served
COM 426 Simulation & Modeling
March 17, 2015
14
MM1
 The most commonly used type of queue
 Used to model single processor systems or individual
devices in a computer system
 Assumption
rate of   exponentially distributed
 Service rate of   exponentially distributed
 Single server
 FCFS
 Unlimited queue lengths allowed
 Infinite number of customers
 Interarrival
COM 426 Simulation & Modeling
March 17, 2015
An M/M/1 Queueing Example
 = mean number of arrivals per time period
 = mean number of people or items served per time

period
 
Average number of customers in the system LS =
Average time a customer spends in the system
1
WS =   
Average number of customers waiting in the queue

Lq =     
2
Average time a customer spends waiting in the queue
Wq =     
Utilization factor for the system  =
15


COM 426 Simulation & Modeling
March 17, 2015
Probability of 0 customers in the system P0 = 1 -


Probability of more than k customers in the
system Pk =   
k 1

Example 1: Peter’s Drive-In on 16th Avenue has one walk-up
service window for people who want to park their cars and eat
at a picnic table. On the Friday before a long weekend,
customers arrive at the window at a rate of 30 per hour,
following a Poisson distribution. There is a very large, almost
infinite number of hungry customers at this time of the year.
The customers are served on a first come, first served basis,
and it takes approximately 1.5 minutes to serve each customer.
16
COM 426 Simulation & Modeling
March 17, 2015
Example 2
17

You are entering Bank of America Arena at
Hec Edmunson Pavilion to watch a basketball
game. There is only one ticket line to
purchase tickets. Each ticket purchase takes
an average of 18 seconds. The average arrival
rate is 3 persons/minute.

Find the average length of queue and average
waiting time in queue assuming M/M/1
queuing.
COM 426 Simulation & Modeling
March 17, 2015