Queuing Theory
Prepared by: Pranav Mishra
Indian Institute of Technology Kharagpur
Indian Institute of Technology Kharagpur
Queuing Theory
Queuing theory is the mathematics of waiting lines. A queue forms whenever existing demand exceeds the existing capacity of service facility. It is extremely useful in predicting and evaluating system performance.
Queuing system
input Customer Server Queue
output
Key elements of queuing system
a) Customers : Refers to anything that arrives at facility and requires service b) Servers: Refers to any resource that provides the requested service
Indian Institute of Technology Kharagpur
Applications of queuing theory
Telecommunications Traffic control Layout of manufacturing systems Airport traffic Ticket sales counter, etc.
Examples:
System
Reception desk
Customers Server
People Receptionist
Hospital
Airport Road network Grocery Computer
Patients
Airplanes Cars Shoppers Jobs
Nurses
Runway Traffic light Checkout station CPU, disk, CD
Indian Institute of Technology Kharagpur
Components of a queuing system process
Population of dirty cars Arrivals from the general population Queue (waiting line) Service facility Daves Car Wash Exit the system
enter
exit
Arrivals to the system
In the system
Exit the system
1) Arrival process
2) Queue configuration 3) Queue discipline
4) Service discipline 5) Service facility
Indian Institute of Technology Kharagpur
Components of a queuing system process
1) Arrival process
The source may be, single or multiple. Size of the population may be, finite or infinite. Arrival may be single or bulk. Control on arrival may be, Total control. Partial control. No control Statistical distribution of arrivals may be, Deterministic, Probabilistic.
Indian Institute of Technology Kharagpur
Components of a queuing system process
2) Queue configuration
The queue configuration refers to, number of queues in the system, Their spatial consideration, Their relationship with server. A queue may be single or multiple queue. A queuing system may impose restriction on the maximum number of units allowed.
3) Queue discipline
If the system is filled to capacity, arriving unit is not allowed to join the queue. Balking A customer does not join the queue. Reneging A customer joins the queue and subsequently decides to leave. Collusion Customers collaborate to reduce the waiting time. Jockeying A customer switching between multiple queues. Cycling A customer returning to the queue after being served.
A queue may be single or multiple queue.
Indian Institute of Technology Kharagpur
Components of a queuing system process
4) Service discipline
First In First Out (FIFO) a.k.a First Come First Serve (FCFS) Last In First Out (LIFO) a.k.a Last Come First Served (LCFS). Service In Random Order (SIRO). Priority Service Preemptive Non-preemptive
5) Service facility
Single queue single server
Service facility
Arrivals
Departures after service
Queue
Indian Institute of Technology Kharagpur
Components of a queuing system process
5) Service facility
Single queue multiple server
Queue Arrivals
Service facility Channel 1 Service facility Channel 2 Service facility Channel 3
Departures after service
Indian Institute of Technology Kharagpur
Components of a queuing system process
5) Service facility
Multiple queue multiple server Customers leave
Arrivals
Queues
Service station
Indian Institute of Technology Kharagpur
Components of a queuing system process
5) Service facility
Multiple server in series Service station 1 Arrivals Phase 1 Queues Queues Customers leave Phase 2 Service station 2
Indian Institute of Technology Kharagpur
Queuing models : some basic relationships
= = Assumptions: If > , then waiting line shall be formed and increased indefinitely and service system would fail ultimately. If < , there shall be no waiting line. Mean number of arrivals per time period Mean number of units served per time period
Average number of units (customers) in the system (waiting and being served) = / ( - ) Average time a unit spends in the system (waiting time plus service time) = 1/ ( - )
Indian Institute of Technology Kharagpur
Queuing models : some basic relationships
Average number of units waiting in the queue = 2/ ( - ) Average time a unit spends waiting in the queue = / ( - ) Intensity or utilization factor
= /
Indian Institute of Technology Kharagpur
Special Delay studies
a) Merging delays b) Peak flow delay c) Parking
a)
Merging delays
Merging may be defined as absorption of one group of traffic by another.
Oliver & Bisbee postulated that minor stream queue length are function of
major street flow rates. This model assumes that: A gap of at-least T is required to enter the major stream. Only one entry is permitted through one acceptable gap.
Entries occur just after passing of vehicles, that signals beginning of gap of
acceptable size.
Indian Institute of Technology Kharagpur
Special Delay studies
Appearance of gap in major stream is not affected by queue in minor stream; and, Arrivals into the minor stream queue are Poisson
Average number of vehicles in minor stream queue E(n)
Where, qa = minor stream flow, qb = major stream flow, T = minimum acceptable gap
Indian Institute of Technology Kharagpur
Special Delay studies
This model works particularly better for the situation, Where major stream flow rate is high, and Vehicles in minor stream queue are served on FIFO basis, with the appearance of a minimum acceptable gap T.
HO formulated a model to predict the amount of time required to clear two
joining traffic streams through a merging point. This model assumes that:
Merging is permitted only at merging point.
Vehicles are served in FIFO basis.
Indian Institute of Technology Kharagpur
Special Delay studies
The total time required for n1 and n2 vehicles to pass through the merging point is,
Where,
hi = ith time gap on major road,
to = time required for a vehicle to merge into through traffic, assuming all vehicles take same time to merge. = number of vehicle that merge into ith gap. n1 = number of vehicle in major road, n2 = number of vehicle waiting to merge
Indian Institute of Technology Kharagpur
Special Delay studies
b) Peak flow delay
If traffic demand exceeds the capacity, there is a continuous buildup of traffic. Mean service rate exceeds the mean rate of arrival. Expected number of vehicle n, waiting in the system at any time t can be
represented as E[n(t)] and will grow indefinitely as t increases.
E[n(t)] = E(n) + (t) - (t) E(n) = expected number of vehicles in system with initial traffic intensity o, where, o <1 = mean arrival rate and, = mean service rate
Indian Institute of Technology Kharagpur
Special Delay studies
Now, say traffic intensity o increases to 1 , where 1 >1 Therefore, 1 = / or = . 1 So, E[n(t)] = E(n) - . 1 (t) - (t) E[n(t)] = E(n) + (1 - 1) . t Or, E[n(t)] = 0 /(1 - 0 ) + (1 - 1) . t When, service rate () is constant, E[n(t)] = (1/2) 0 2 / ( - 0 ) + 0/ + (1 - 1) [ initial 0 increases to ]
Indian Institute of Technology Kharagpur
Special Delay studies
Numerical example: A queue with random arrival rate 1 vehicle per minute and a mean service time of 45 seconds. In peak period, arrival rate suddenly doubles and this peak period rate is maintained for 1 hour. Find the average number of vehicles in the system at the end of peak hour. Sol. Given, 0 = 1, = 4/3 Therefore, 0 = 0 / = 3/4
In peak period, = 2 and remains same. So, 1 = 3/2
Putting the values in eqn - , E[n(t)] = 0 /(1 - 0 ) + (1 - 1) . t we get, E[n(60)] = 43 If the service rate were constant, Putting the values in eqn - , E[n(t)] = (1/2) 0 2 / ( - 0 ) + 0/ + (1 - 1) we get, E[n(60)] = 41.87~ 42
Indian Institute of Technology Kharagpur
Special Delay studies
Now, to find out how long it takes the peak hour queue to dissipate, COX developed the equation =
For developing this model, he made following assumption:
Service time is constant.
When traffic starts to dissipate, there are large number of vehicles in the queue and traffic intensity 1 has decreased to less than 1. The queuing time of newly arrived vehicle is equal to average queuing time of vehicles already in the system.
Indian Institute of Technology Kharagpur
Special Delay studies
For the previous problem, find out the mean time it takes for queue to get dissipated. Sol: putting the values in the equation E (t) = [ E(n)t / o / 2(1- o ) ] / (1 o ) We get, E(t) = 123 min.
Indian Institute of Technology Kharagpur
Special Delay studies
c) Parking
The characteristics of queuing analysis dealing with length of queue and waiting time are not too meaningful for parking as potential parkers usually leave and seek another location rather than wait, if parking is full Though there has been attempts to establish relationship between number
of potential parkers turned away from parking of a specified capacity and
various fractions of occupancy.
Indian Institute of Technology Kharagpur