DOTE2030 Lec 4
DOTE2030 Lec 4
Little’s Law
Queuing Models
◦ A popular formula
◦ M/M/c/K Model
2
The Call Center Process
Incoming Calls Answered Calls
(Customer Arrivals) Sales Reps (Customer Departures)
Processing
Calls
Calls
on Hold
(Service Inventory)
(Service Process)
3
Patients
11
Cumulative
10 Inflow
9
Cumulative
8
Outflow
7
Flow Time
6
5 Inventory
4
3
2
1
Inventory=Cumulative Inflow – Cumulative Outflow Time
0
7:00 8:00 9:00 10:00 11:00 12:00 13:00 14:00 15:00 16:00 17:00 18:00
4
Goods vs. Services
◦ Flow time matters for both physical-product and service settings, but more for service settings.
◦ For goods: inventory produced in advance vs. on demand; shorter vs. longer delivery time.
◦ For service: capacity cannot be stored in advance and must be on demand.
Measures of Interest
◦ Sales, e.g., throughput rate, abandonment rate, blocking rate
◦ Cost, e.g., capacity utilization
◦ Customer satisfaction, e.g., waiting time in queue /in system
5
6
Patients
11
Cumulative
10 Inflow
9
Cumulative
8
Outflow
7
Flow Time
6
5 Inventory
4
3
2
1
Inventory=Cumulative Inflow – Cumulative Outflow Time
0
7:00 8:00 9:00 10:00 11:00 12:00 13:00 14:00 15:00 16:00 17:00 18:00
7
What Is It?
◦ Average Inventory (𝐼) = Average Flow Rate (𝑅) * Average Flow Time (𝑇)
Why Important? Oftentimes, two of them are easier to track than the 3rd, and this law can find it indirectly.
Example: On average, you write 10 email responses per day and have 240 emails in your mailbox. Assume
that you will delete every email after responding to it. How long does it take you to response to an email on
average?
8
9
Arrival rate: 𝑅𝑖 (#/hour)
1
◦ Inter-arrival time: 𝑇𝑖 = (hour)
𝑅𝑖
The customer processing time of a server: 𝑇𝑝 (hour)
1
◦ Processing/service rate: (#/hour)
𝑇𝑝
10
Flow Time 𝑇= 𝑇𝑞 + 𝑇𝑝
Inventory 𝐼= 𝐼𝑞 + 𝐼𝑝
Flow Rate 𝑅 = min(𝑅𝑖 , 𝑅𝑝 )
Stable Process: 𝑅𝑖 < 𝑅𝑝 , so that 𝑅 = 𝑅𝑖 .
Little’s Law: 𝐼 = 𝑅𝑖 × 𝑇, 𝐼𝑞 = 𝑅𝑖 × 𝑇𝑞 , 𝐼𝑝 = 𝑅𝑖 × 𝑇𝑝 .
𝐼𝑝 𝑅𝑖
Capacity Utilization: 𝑢 = = < 1.
𝑐 𝑅𝑝
# of busy servers: 𝐼𝑝
𝑐
Process capacity: 𝑅𝑝 = (#/hour)
𝑇𝑝
Proportion of lost customers: 𝑃(𝑞𝑢𝑒𝑢𝑒 𝑙𝑒𝑛𝑔𝑡ℎ = 𝐾).
11
Example: 𝑇𝑝 = 5𝑚𝑖𝑛, 𝑇𝑖 = 6𝑚𝑖𝑛
Customer Number
7
3 12 17 5
6
4 18 23 5 5
5 24 29 5 4
6 30 35 5 3
2
7 36 41 5
1
8 42 47 5
0 10 20 30 40 50 60
9 48 53 5
Time
10 54 59 5
Capacity utilization 𝑢 =
Queue length = 0
12
Example: 𝑇𝑝 = 5𝑚𝑖𝑛, 𝑇𝑖 = 6𝑚𝑖𝑛
9
1 0 7 7
8
2 10 1 1
7
3 20 7 7
Customer
6
4 22 2 7
5
5 32 8 8 4
6 33 7 14 3
7 36 4 15 2
8 43 8 16 1
9 52 5 12 0 10 20 30 40 50 60 70
Time
10 54 1 11
Capacity utilization 𝑢 =
Queue length > 0
13
Reasons for Inventory Build Up:
The fundamental reason is customer inflow rate > processing rate:
1. If the average inflow rate 𝑅𝑖 > the average processing rate 𝑅𝑝 , inventory build up will for sure build up.
2. If the average inflow rate 𝑅𝑖 ≤ the average processing rate 𝑅𝑝 , inventory may still build up due to
variability in inter-arrival and/or processing times, e.g., customers may come in bulk rather than evenly
in time.
14
Average
Flow
Time T
Variability
Increases
Tp
15
Assumptions:
1. Identical servers.
2. Stability: 𝑅𝑖 < 𝑅𝑝 .
Inputs:
1. Interarrival time (a random variable)
2. Processing Time per customer (a random variable)
3. # of servers
4. Buffer capacity
Note: A general queuing model is prohibitively hard to analyze exactly, e.g., assuming arbitrary probability
distributions of interarrival/processing times already burdens analysis/calculation. This is mostly a non-
issue, especially in low-stake settings. In practice, there are two prevalent approximation methods:
1. Approximation formula for queue length.
2. M/M/c/K model.
16
17
2(𝑐+1) 𝐶 2 + 𝐶𝑝2
𝑢 𝑖
𝐼𝑞 =
1−𝑢 2
𝑐: # of servers
𝑅𝑖 𝑇𝑝
𝑢= = : capacity utilization
𝑅𝑝 𝑐𝑇𝑖
Note:
1. This formula is under the assumption that interarrival/processing times are independent of each
other and 𝑲 = ∞.
2. This formula is a mostly adopted approximation formula for queue length calculation.
3. 𝑇𝑝 , 𝑇𝑖 , 𝐶𝑝 , 𝐶𝑖 are estimated by sampling.
18
Example: For a queuing system with 𝒄 = 𝟏 and 𝑲 = ∞, we randomly sampled a few customers and observe:
◦ Interarrival times: 10, 10, 2, 10, 1, 3, 7, 9, 2
◦ Processing times: 7, 1, 7, 2, 8, 7, 4, 8, 5, 1
Q1: Find
𝑇𝑖 :
𝑅𝑖 :
𝑇𝑝 :
𝑅𝑝 :
𝑢:
𝐶𝑖 :
𝐶𝑝 :
𝐼𝑞 :
𝑇:
𝐼:
19
Q2: If we increase the # of servers to 𝒄 = 𝟐, and use the same sample:
◦ Interarrival times: 10, 10, 2, 10, 1, 3, 7, 9, 2
◦ Processing times: 7, 1, 7, 2, 8, 7, 4, 8, 5, 1
Find
𝑇𝑖 :
𝑅𝑖 :
𝑇𝑝 :
𝑅𝑝 :
𝑢:
𝐶𝑖 :
𝐶𝑝 :
𝐼𝑞 :
𝑇:
𝐼:
20
21
Assumptions:
1. Identical servers.
2. Stability: 𝑅𝑖 < 𝑅𝑝 .
Inputs:
1. Interarrival time: Exponential distribution with rate 𝑅𝑖 .
2. Processing Time per customer: Exponential distribution with rate 𝑅𝑝 .
3. 𝑐 and 𝐾.
Note:
Why exponential? This is the only memoryless continuous probability distribution (assuming time is
continuous): Information about history is irrelevant if the status at the time being is observed. This
assumption simplifies analysis significantly.
Validity of assuming exponential? An exponential distribution (with rate 𝜆) follows from almost
complete ignorance except that at every small time interval (𝒕, 𝒕 + 𝒅𝒕), there is a small chance 𝜆𝑑𝑡 that a
customer will arrive (or the service will be finished).
1. For interarrival times, an exponential distribution captures this state of knowledge.
2. For processing times, mainly for ease of analysis as one many times knows more.
𝒄 𝑢 𝑅𝑝 𝐼𝑖 𝑇𝑖 𝑇 𝐼
1
2
23
Example 2 (effect of increasing 𝑲): For a queuing system with 𝑅𝑖 = 20/ℎ𝑜𝑢𝑟, 𝑇𝑝 = 2.5𝑚𝑖𝑛𝑠, 𝒄 = 𝟏. Fill in
the blanks.
𝑲 𝑢 𝑷𝑏 𝐼𝑖 𝑇𝑖 𝑹 𝐼
4
5
6
24
Example 3 (Call Center): A call center with 𝑅𝑖 = 20/ℎ𝑜𝑢𝑟, 𝑇𝑝 = 2.5𝑚𝑖𝑛𝑠, is now trying to decide the values
of 𝒄 and 𝑲 by minimizing the hourly cost, which consists of the following:
Cost of server’s wages: $20𝑐
25
Example 3 (continued):
26