Teaching Queueing - PowerPoint PPT Presentation

1 / 65
About This Presentation
Title:

Teaching Queueing

Description:

Spreadsheet computer to record times. One computer operator (me) Agenda ... http://www.youtube.com/watch?v=IcP9Wo3OKY8&mode=related&search=kids in the hall ... – PowerPoint PPT presentation

Number of Views:111
Avg rating:3.0/5.0
Slides: 66
Provided by: meetings5
Category:

less

Transcript and Presenter's Notes

Title: Teaching Queueing


1
Teaching Queueing
  • TMS 2006 Workshop, San Francisco
  • Armann Ingolfsson
  • Armann.ingolfsson_at_ualberta.ca
  • School of Business
  • University of Alberta
  • Edmonton, Alberta, Canada

2
Exercise 1 Physical Queue Simulation
  • I need
  • One bank teller
  • One announcer
  • Ten bank customers
  • Also
  • Currency
  • Post-it notes and pen to identify customers
  • Spreadsheet computer to record times
  • One computer operator (me)

3
Agenda
  • First part of my first queuing lecture
  • Motivating students with examples of queues and
    queue management
  • How to get numerical answers simulation vs.
    formulas
  • What should one cover in two weeks?
  • What we dont do enough of
  • What we do too much of

4
Before We Start
  • Dont worry I wont try to go through every
    slide ?
  • My goal air opinions and ideas (mine and yours)
  • Most ideas Ill show you are classroom-tested,
    but not all

5
Asgard Bank Times Between Arrivals(pg. 173)
6
Asgard Bank Arrival Rate
  • Given avg. time between arrivals 1.00 minute
  • Want average arrival rate per hour ? (1
    customer / 1.00 min.) ? (60 min. / 1 hr.) 60
    customers / hr.

7
Asgard Bank Service Times
8
Asgard Bank Service Rate
  • Given avg. service time 0.95 minutes
  • Want average service rate per hour(if working
    continuously) ? (60 min. / 1 hr.) ? (1
    customer / 0.95 min.) 63 customers / hour
  • Note
  • the service rate is not the rate at which
    customers are served
  • its the rate at which customers could be served,
    if there were enough customers
  • service rate capacity of a server

9
Why Do Customers Wait?
  • GivenAverage inter-arrival time 1.00
    min.Average service time 0.95 min.

0.95
time
Whats missing from this picture? Answer
Randomness in arrivals and service
completion Randomness causes congestion
10
Including Randomness Simulation
  • Use the computer to generate random draws from
    the inter-arrival time distribution and service
    time distribution
  • Service times
  • Normal distribution, mean 57/3600 hrs, stdev
    10/3600 hrs.
  • MAX(NORMINV(RAND(),57/3600,10/3600),0)
  • Inter-arrival times
  • Exponential distribution, mean 1/ 60 hrs.
  • (1/60)LN(RAND())
  • To Excel

11
Simulated Lunch Hour 1
12
Simulated Lunch Hour 2
13
Simulated Lunch Hour 3
14
Causes of Congestion
  • Higher than average number of arrivals
  • Lower than average service capacity
  • Lost capacity due to timing

Lesson For a service where customers arrive
randomly, it is not a good idea to operate the
system close to its average capacity
15
Anatomy of a Congested System
a service completion

waiting room
queue

An arrival
parallel servers

potential customers

16
Exercise 2 Queues Youve Been In
  • To be done individually
  • List the three most annoying / interesting queues
    that you have waited in since last Thursday

17
Waiting for Housing
  • Who are the customers?
  • Who are the servers?
  • What are the consequences of waiting?
  • How would we predict the impact of actions such
    as creating more public housing?

Edmonton Journal, July 12, 2006
18
Waiting for Patents
Technology Review, May/June, 2006
19
More Examples Let the Students do the Work
  • Assignment on first day of class Find a
    newspaper article, magazine article, TV show,
    movie, web page, novel, etc., that is relevant to
    the course material
  • Due at end of semester
  • Example 1 Flying pig videohttp//www.youtube.com
    /watch?vIcP9Wo3OKY8moderelatedsearchkids20in
    20the20hall
  • Example 2 We Q 4 Uhttp//www.dontq.co.za/

20
Exercise 3
  • To be done in groups of 3-4
  • Answer this question what is queueing theory?

21
Exercise 3 follow-up questions
  • What should we call the part of a course where we
    discuss queues?
  • Queueing theory?
  • Congestion management?
  • Managing waiting lines?
  • Variability and its impact on process
    performance?
  • Managing flow variability safety capacity?
  • Queueing Science?

22
Developing a Queueing ToolkitGetting Numerical
Answers
  • Simulation
  • with a simulation language (Arena, Promodel,
    etc.)
  • in a spreadsheet
  • Analytical models (M/M/s, etc.), with
    calculations done
  • with paper, pencil, and a calculator
  • in a spreadsheet
  • Template
  • Function library
  • with standalone software
  • with a web-based calculator

23
Simulation vs. Analytical Models
  • Simulation models
  • Helps students understand queues construct
    arguments for why queues build up
  • Time-consuming expensive to build and debug
  • More realistic
  • More performance measures
  • Sampling error
  • Analytical models
  • Faster way to get numerical answers
  • Restrictive assumptions
  • Limited set of performance measures
  • Mostly steady state measures

24
Visualization of Simulated Queues Animation
  • Good for debugging, validation, convincing people
    that model works
  • Snapshot at one point in time
  • Difficult to see patterns over time

25
Visualization of Simulated Queues Customer and
Server Graphs
26
Visualization of Simulated Queues Customer and
Server Graphs
  • Show evolution over time
  • Allows students to create stories / explanations
    of why congestion occurred or didnt occur
  • Other uses
  • Clean / check data
  • Prove Littles Law
  • Explain various queue disciplines

27
Littles Law L leffW Why it is True
  • The short version
  • You go through a FCFS queueing system
  • Q How many customers will be in the system (L)
    when you leave?
  • A All the customers that arrived while you were
    in the system.
  • You spent an average of W time units in the
    system, so the average of number of customers
    that arrived would have been leffW
  • ? L leffW

28
The Long Version
t
F(t) area between A and F curves, up to t
A(t)
D(t)
29
The Long Version, continued
  • leff A(t) / t
  • W Total waiting / Total customers F(t) /
    A(t)
  • L Total customer-hours / Total hours F(t) /
    t
  • ? leff ? W (A(t) / t) ? (F(t) / A(t)) F(t)
    / t L

30
Transition from Simulation to Analytical Models
31
Transition from Simulation to Analytical Models
32
Transition from Simulation to Analytical Models
Q Where will this end up, after a very long time?
A 1.5 (well see how to find this answer next
time)
33
EOQ and Square Roots
  • Need to know how to compute square roots
  • Here is an efficient algorithm
  • Do you teach your students this?
  • Why or why not?
  • Why and when should we look inside the black
    box?

34
Analogy M/M/s Queues and P0
  • 2 of 4 service OM texts on my shelf contain
    this formula
  • Why?
  • Alternative

35
Analytical Models Software Choices
  • Custom software
  • Stand-alone
  • Web-based
  • Matlab / Mathematica / Maple
  • Spreadsheets
  • Templates
  • Function libraries, e.g., Queueing ToolPak
    add-in(free from www.bus.ualberta.ca/aingolfsson/
    qtp )

36
Checking Software
  • Test case 1 M/M/s, m 1, l x, s x1
  • Test case 2 M/M/s, m 1, l x, s 2x
  • All textbook software I have seen fails around
    x 710
  • QTP 3.0 and 4.0 work

37
OK, you dont like the P0 formula. Are any
equations worth showing?
38
Yes the Laws of Queueing
  • Suppose you know L and PrFull. Then you can
    calculate
  • Lq
  • W
  • Wq
  • leff l (1 PrFull)
  • r leff /(sm)
  • W Wq 1/m
  • Littles Law L leffW
  • Littles Law for the queue Lq leffWq
  • Littles Law for the servers sr leff (1/m)
  • L Lq sr

39
Exercise 4 Course Design
  • Do in groups of 3-4
  • Develop a prioritized list of topics to teach in
    a two-week module on queueing
  • Mention the type(s) of students you have in mind,
    if you think it is relevant

40
Opinions What We Leave Out When Teaching Queueing
  • Data collection, analysis, estimation
  • Transient non-stationary analysis
  • Fluid models are easy, and often appropriate
  • Simulation can be used
  • Analytical models are not as hard to use as some
    people think
  • Queue behavior
  • Reneging / abandonment Erlang A model
  • Perceptions of waiting, priorities / fairness
  • Balking, retrials
  • Analytical approximations
  • Square root safety staffing
  • G/G/s approximations Lq(G/G/s) (fudge factor)
    Lq(M/M/s)

41
Typical Call Centre Data 1
1 N. Gans, G. Koole, and A. Mandelbaum (2003),
Telephone Call Centers Tutorial, Review, and
Research Prospects, Manufacturing and Service
Operations Management 579-141.
42
Terminology
  • Recvd of calls received (arrival rate)
  • Answ of calls that were answered, i.e., did
    not abandon
  • Abn (Recvd Answ) / Recvd
  • ASA Average speed of answer Wq (seconds)
  • AHT Average handle time avg. service time

43
Sch Avail Logged in / Scheduled time On Prod
On production / Logged in Occ Active /
Logged in
On production
Active
Available
Unavailable
Unplanned breaks
Logged in
Scheduled time
44
Call Centre Data A Service Time Distribution 1
45
Call Centre Data Abandoment Rate vs. Time on
Hold 1
46
Example Vancouver Intl Airport Security
Checkpoint MBPF
  • Capacity 12 / min.
  • Three 250-seat planes depart at 10 am
  • Passengers start coming through checkpoint 80
    min. before departure
  • 2.5 / min. / flight for 30 min.
  • 5 / min / flight for 20 min.
  • 2.5 / min / flight for 30 min.

47
Example Vancouver Intl Airport Security
Checkpoint
48
Example Vancouver Intl Airport Security
Checkpoint
How long does the queue get? How long do people
have to wait? What can be done to reduce waiting?
This is fluid modeling! Even executives can do it!
49
What if Departures are Staggered 940, 1000,
1020
No queue build-up No waiting (?)
50
Analytical Modeling of Transients
  • Myths (?)
  • It cant be done
  • Its too hard
  • Its too slow
  • Its not important
  • Responses
  • Yes it can
  • Discrete time is easy (matrix multiplication),
    continuous time is not much harder, using
    uniformization method
  • Computations for many real systems can be done in
    seconds
  • Think of a real system that is in steady state
    (you can get back to me after the workshop)

51
Uniformization Example M/M/4/6
Transition rate L l s m 3.5 4 7.5
52
The Equations
And it can even be done in a spreadsheet!
53
Visible vs. Invisible Queues
invisible queue (e.g., on the phone)
visible queue (e.g., in the bank)
time
54
From a Pizza 73 Ad
What is the purpose of showing the customers this?
55
Ambulance Service
  • Response time for heart attack victim
  • 5 minutes life
  • 10 minutes death
  • ? 10 min. is more than twice as worse as 5 min.!
  • ? Wq not the appropriate performance measure
  • Prresponse time lt 859 min. might be more
    appropriate
  • QTPMMS_SERVICELEVEL(.) function

56
Fairness
  • Slips and skips
  • FCFS First-come-first-served
  • FIFO First-in-first-out
  • LCFS Last-come-first-served
  • SIRO Service-in-random-order
  • Priorities perceived as fair?
  • Ci slipped by Bo
  • Bo was skipped by Ci
  • For every slip there is a skip

57
Priority System Serve Customer from Highest
Priority Class Next
Example
58
Alternative System Serve Customer with highest
(Aging Factor)(Waiting Time) Next
Example
Aging factor 1 for high
0.5 for low
59
A Call Centre as a Queueing System
lost calls
agents (servers)
retrials
busy
Arrivals
Queue
abandon
retrials
returns
lost calls
60
Which Parts does M/M/s/sC Capture?
lost calls
agents (servers)
retrials
busy
Arrivals
Queue
abandon
retrials
returns
lost calls
61
A Better Model M/M/s/sCM
lost calls
agents (servers)
retrials
busy
Arrivals
Queue
abandon
retrials
Customers have exponentially distributed
patience. When they have waited in queue to the
limit of their patience, they abandon ( renege)
returns
lost calls
62
M/M/s/sCM Calculatorhttp//www.math.vu.nl/koo
le/ccmath/ErlangX.php
63
Reverse-Engineering Patience
  • A call centre has 8 agents and 30 hold lines.
    The average handling time is 4 minutes per
    customer, and the arrival rate is 110 per hour.
    The call centre manager knows that many customers
    are abandoning, but he does not know how long
    customers are willing to wait on hold before
    hanging up. He does know that customers spend an
    average of 0.67 minutes on hold before either
    being connected to an agent or abandoning.
  • What is the average customer patience?
  • What fraction of customers abandon?

64
How Variability Impacts Waiting
65
Opinions What We Do Too Much Of
  • Steady state results
  • Markovian models
  • Emphasize closed-form formulas
  • Manual plugging into formulas
Write a Comment
User Comments (0)
About PowerShow.com