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

Announcements

PS #3 out this afternoon


Due: October 19 (graded by 10/23)
Queueing Systems: Lecture 1
Office hours Odoni: Mon. 2:30-4:30
- Wed. 2:30-4:30 on Oct. 18 (No office hrs 10/16)
Amedeo R. Odoni
_ Or send me a message
October 4, 2006

Quiz #1: October 25, open book, in class


Old quiz problems and solutions:
posted on 10/19

Topics in Queueing Theory Lecture Outline


Introduction to Queues Introduction to queueing systems
Littles Law Conceptual representation of queueing
Markovian Birth-and-Death Queues systems
The M/M/1 and Other Markovian Variations
Codes for queueing models
The M/G/1 Queue and Extensions
Priority Queues
Terminology and notation
Some Useful Bounds Littles Law and basic relationships
Congestion Pricing Birth-and-death models
Queueing Networks; State Representations The M/M/1 queueing system
Dynamic Behavior of Queues Reference: Chapter 4, pp. 182-203
Queues A Generic Queueing System
Queueing theory is the branch of operations research
Servers
concerned with waiting lines (delays/congestion)
Arrival point C Departure point
A queueing system consists of a user source, a queue at the system from the system
and a service facility with one or more identical parallel C
servers Source
Queue C
A queueing network is a set of interconnected queueing of users/ C C CC CC C
customers
systems C
Fundamental parameters of a queueing system: C
- Demand rate - Capacity (service rate) C
- Demand inter-arrival times - Service times
- Queue capacity and discipline (finite vs. infinite;
FIFO/FCFS, SIRO, LIFO, priorities)
Arrivals
process
- Myriad details (feedback effects, balking,

Size of Service process


jockeying, etc.)
user source
Queue discipline and
Queue capacity
Number of servers

Queueing network consisting of


Applications of Queueing Theory
five queueing systems
Some familiar queues:
_ Airport check-in; aircraft in a holding pattern
_ Automated Teller Machines (ATMs)
Queueing Queueing
system system _ Fast food restaurants
2 3
_ Phone centers lines
Queueing
In
Queueing Point where Point where Out _ Urban intersection
system users make users merge + system
1 a choice 5 _ Toll booths
_ Spatially distributed urban systems and services
Queueing
system
4
Level-of-service (LOS) standards
Economic analyses involving trade-offs among
operating costs, capital investments and LOS
Congestion pricing
Queueing Models Can Be Essential in

The Airside as a Queueing Network


Analysis of Capital Investments

Cost
Total cost

Optimal
cost Cost of building the capacity

Cost of losses due to waiting

Optimal capacity Airport Capacity

Strengths and Weaknesses of


A Code for Queueing Models:

Queueing Theory
A/B/m

Queueing models necessarily involve approximations Distribution of Queueing System


service time
and simplification of reality Number of servers

Results give a sense of order of magnitude, changes // C S


Queue
relative to a baseline, promising directions in which to Customers C S Service
Distribution of CCCCCC
C S facility
move interarrival time
C S
Closed-form results essentially limited to steady
state conditions and derived primarily (but not solely)
for birth-and-death systems and phase systems
Some standard code letters for A and B:
Some useful bounds for more general systems at
_ M: Negative exponential (M stands for memoryless)
steady state
Numerical solutions increasingly viable for dynamic _ D: Deterministic
systems _ Ek:kth-order Erlang distribution

Huge number of important applications _ G: General distribution


Terminology and Notation Terminology and Notation (2)

Number in system: number of customers in Transient state: state of system at t is


queueing system influenced by the state of the system at t = 0
Number in queue or Queue length: number of Steady state: state of the system is independent
customers waiting for service of initial state of the system
Total time in system and waiting time m: number of servers (parallel service
N(t) = number of customers in queueing system channels)
at time t If n and the service rate per busy server are
Pn(t) = probability that N(t) is equal to n at time t constants and , respectively, then n=, n=
n: mean arrival rate of new customers when min (n, m); in that case:

N(t) = n _ Expected inter-arrival time = 1/

n: mean (total) service rate when N(t) = n _ Expected service time = 1/

Some Expected Values of Interest


at Steady State
Littles Law
Number of A(t): cumulative arrivals to the system
Given: users C(t): cumulative service completions in the system

_ = arrival rate

_ = service rate per service channel


A(t)

Unknowns:
N(t)
_L = expected number of users in queueing system
_ Lq = expected number of users in queue C(t)

_ W = expected time in queueing system per user (W =


E(w))
_ Wq = expected waiting time in queue per user (Wq =
t T Time
E(wq)) T T
4 unknowns We need 4 equations
LT = 0
N (t ) dt
=
A(T ) 0

N (t ) dt
= T WT
T T A(T )
Relationships among L, Lq, W, Wq Birth-and-Death Queueing Systems

Four unknowns: L, W, Lq, Wq


1. m parallel, identical servers.
Need 4 equations. We have the following 3 equations:
_ L = W (Littles law) 2. Infinite queue capacity (for now).
_ Lq = Wq 3. Whenever n users are in system (in
1
_ W = Wq +

queue plus in service) arrivals are
If we can find any one of the four expected values, we
Poisson at rate of n per unit of time.
can determine the three others 4. Whenever n users are in system,
The determination of L (or other) may be hard or easy service completions are Poisson at
depending on the type of queueing system at hand

rate of n per unit of time.
L = nPn (Pn : probability that n customers are in the system) 5. FCFS discipline (for now).
n=0

The differential equations that


The Fundamental Relationship

determine the state probabilities


Time: t Time: t+t Pn (t + t) = Pn +1 (t) n +1 t + Pn 1 (t) n 1 t + Pn (t) [1 ( n + n ) t]
n+1 users
nt After a simple manipulation:
Pn(t) = Prob [n users
dPn (t)
1-(n+ n)t in system at time t] = (n + n ) Pn (t) + n 1 Pn 1 (t) + n +1 Pn +1 (t) (1)
n users dt
n users
(1) applies when n = 1, 2, 3,.; when n = 0, we have:
nt dP0 (t)
= 0 P0 (t) + 1 P1 (t) (2)
dt
n-1 users
The system of equations (1) and (2) is known as the
Chapman-Kolmogorov equations for a birth-and-death
Pn (t + t) = Pn +1 (t) n +1 t + Pn 1 (t) n 1 t + Pn (t) [1 ( n + n ) t] system
Birth-and-Death System: State
The state balance equations
Transition Diagram
We now consider the situation in which the queueing 0 1 2 m-1 m m+1
system has reached steady state, i.e., t is large
enough to have Pn (t) = Pn , independent of t, or dPn (t) = 0 0 1 2 m m+1
dt
3 m m+1 m+2
Then, (1) and (2) provide the state balance equations: 1 2

0 P0 = 1 P1 n=0 (3)
We are interested in the characteristics of the system
(n + n ) Pn = n 1 Pn 1 + n +1 Pn +1 n = 1, 2, 3,.. (4) under equilibrium conditions (steady state), i.e., when
The state balance equations can also be written directly the state probabilities Pn(t) are independent of t for
from the state transition diagram large values of t

Can write system balance equations and obtain


closed form expressions for Pn, L, W, Lq, Wq

Solving.. M/M/1: Observing State Transition


Diagram from Two Points
Solving (3) and (4), we have: From point 1:
P0 = P1 ( + )P1 = P0 + P2 ( + )Pn = Pn1 + Pn+1
P1 = 0 P0 ; P2 = 1 P1 = 1 0 P0 etc.
1 2 2 1
and, in general, 0 1 2 n-1 n n+1

..... 1 0
Pn = n 1 n 2 P0 = K n P0
n n 1 ..... 2 1
From point 2:
But, we also have: 1= Pn = P0 (1 + K n )
n =0 n =1 P0 = P1 P1 = P2 Pn = Pn+1
1
Giving, P0 = Condition for steady state:



1+ Kn Kn < 0


n-1


n+1


n =1 n=1
M/M/1: Derivation of P0 and Pn M/M/1: Derivation of L, W, Wq, and Lq

2 n L = nPn = n n (1 ) = (1 ) n n = (1 ) n n1

Step 1: P1 = P0 , P2 = P0 , L, Pn = P0
n=0 n=0 n=0 n=1


d n d 1
= (1 ) = (1 )
d n=0 d 1
n

1

Step 2: P n = 1, P0 = 1 P0 =
n=0
n
1
= (1 ) =

=

=


2
(1 ) (1 ) 1
n=0

n=0
L 1 1
W= = =
n


1 1
Step 3: =

, then = n
= =
1 1
(Q < 1)

n=0 n=0 1
Wq = W =
1

1
=
( )
1
Step 4: P0 =
= 1 and Pn = n (1 ) 2
n Lq = Wq = =
n=0
( ) ( )

High Sensitivity of Delay at High


M/M/1: An alternative, direct derivation
Levels of Utilization
of L and W
Expected delay For an M/M/1 system, with FCFS discipline:


(n +1) N +1 E[N ] +1 L +1
W = Pn = E[ ]= = (1)
n=0
But from Littles theorem we also have:
L = W (2)
It follows from (1) and (2) that, as before:
Demand 1
L= ; W =
Capacity
=1
Does the queueing discipline matter?
M/M/1: E[B], the expected length of a

Additional important M/M/1 results


busy period

The pdf for the total time in the system, w, can N


B = busy period
be computed for a M/M/1 system (and FCFS):
I = idle period
f w (w) = (1 ) e (1 ) w = ( )e ( )w for w 0
Thus, as already shown, W = 1/( -) = 1/[ (1-)] t
I B I B I B
The standard deviation of N, w, Nq, wq are all
proportional to 1/(1-), just like their expected E[length Idle period ]
P0 =
values (L, W, Lq, Wq, respectively) E[length Busy period ] + E[length Idle period ]
The expected length of the busy period, E[B], But, P0 = 1 E[length Idle period ] = 1

is equal to 1/( -) 1 1 1
Therefore, E[B] = E[length Busy period ] = =
(1 )

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