Chapter 05 - Basic IE models for simulation- introduction to SSQ
Chapter 05 - Basic IE models for simulation- introduction to SSQ
Basic IE models
for simulation:
introduction
to SSQ
Chapter 5
Slide 2 .
1.1 Problem Statement - SSQ
Introduction
Slide 3 .
1.1 Problem Statement - SSQ
Slide 7 .
1 Problem Statement (cont’d.)
(Input/Output)
• Quantities to be estimated
Expected average delay in queue (excluding service time)
of the n customers completing their delays
with i includes only customers that complete their delay in the queue
Expected average number of customers in queue
(excluding any in service)
– A continuous-time average
– =Area under Q(t), such that Q(t) = queue length at time t will be
divided by T(n) = time simulation ends …
Expected utilization (proportion of time busy) of the server
– Another continuous-time average
– =Area under B(t) proportion of server-busy elapsed time. B(t) = 1
if busy, 0 if idle at time t, …
Many others are possible (maxima, minima, time or number
in system, proportions, quantiles, variances …)
• Important: Discrete-time vs. continuous-time statistics
Slide 8 .
2 Intuitive Explanation
• Given (for now) interarrival times (all times are in
minutes):
0.4, 1.2, 0.5, 1.7, 0.2, 1.6, 0.2, 1.4, 1.9, …
• Given service times:
2.0, 0.7, 0.2, 1.1, 3.7, 0.6, …
• n = 6 delays in queue desired
• “Hand” simulation:
Display system, state variables, clock, event list, statistical
counters … all after execution of each event
Use above lists of interarrival, service times to “drive” simulation
Stop when number of delays hits n = 6, compute output
performance measures
Slide 10 .
2 Intuitive Explanation (cont’d)
Status
shown is
after all
changes
have
been
made in
each
case …
Interarrival times: 0.4, 1.2, 0.5, 1.7, 0.2, 1.6, 0.2, 1.4, 1.9, …
Service times: 2.0, 0.7, 0.2, 1.1, 3.7, 0.6, …
Interarrival times: 0.4, 1.2, 0.5, 1.7, 0.2, 1.6, 0.2, 1.4, 1.9, …
Service times: 2.0, 0.7, 0.2, 1.1, 3.7, 0.6, …
Slide 12 .
2 Intuitive Explanation (cont’d)
Interarrival times: 0.4, 1.2, 0.5, 1.7, 0.2, 1.6, 0.2, 1.4, 1.9, …
Service times: 2.0, 0.7, 0.2, 1.1, 3.7, 0.6, …
Interarrival times: 0.4, 1.2, 0.5, 1.7, 0.2, 1.6, 0.2, 1.4, 1.9, …
Service times: 2.0, 0.7, 0.2, 1.1, 3.7, 0.6, …
Slide 14 .
2 Intuitive Explanation (cont’d)
Interarrival times: 0.4, 1.2, 0.5, 1.7, 0.2, 1.6, 0.2, 1.4, 1.9, …
Service times: 2.0, 0.7, 0.2, 1.1, 3.7, 0.6, …
Interarrival times: 0.4, 1.2, 0.5, 1.7, 0.2, 1.6, 0.2, 1.4, 1.9, …
Service times: 2.0, 0.7, 0.2, 1.1, 3.7, 0.6, …
Slide 16 .
2 Intuitive Explanation (cont’d)
Interarrival times: 0.4, 1.2, 0.5, 1.7, 0.2, 1.6, 0.2, 1.4, 1.9, …
Service times: 2.0, 0.7, 0.2, 1.1, 3.7, 0.6, …
Interarrival times: 0.4, 1.2, 0.5, 1.7, 0.2, 1.6, 0.2, 1.4, 1.9, …
Service times: 2.0, 0.7, 0.2, 1.1, 3.7, 0.6, …
Slide 18 .
2 Intuitive Explanation (cont’d)
Interarrival times: 0.4, 1.2, 0.5, 1.7, 0.2, 1.6, 0.2, 1.4, 1.9, …
Service times: 2.0, 0.7, 0.2, 1.1, 3.7, 0.6, …
Interarrival times: 0.4, 1.2, 0.5, 1.7, 0.2, 1.6, 0.2, 1.4, 1.9, …
Service times: 2.0, 0.7, 0.2, 1.1, 3.7, 0.6, …
Slide 20 .
2 Intuitive Explanation (cont’d)
Interarrival times: 0.4, 1.2, 0.5, 1.7, 0.2, 1.6, 0.2, 1.4, 1.9, …
Service times: 2.0, 0.7, 0.2, 1.1, 3.7, 0.6, …
Interarrival times: 0.4, 1.2, 0.5, 1.7, 0.2, 1.6, 0.2, 1.4, 1.9, …
Service times: 2.0, 0.7, 0.2, 1.1, 3.7, 0.6, …
Slide 22 .
2 Intuitive Explanation (cont’d)
Interarrival times: 0.4, 1.2, 0.5, 1.7, 0.2, 1.6, 0.2, 1.4, 1.9, …
Service times: 2.0, 0.7, 0.2, 1.1, 3.7, 0.6, …
Interarrival times: 0.4, 1.2, 0.5, 1.7, 0.2, 1.6, 0.2, 1.4, 1.9, …
Service times: 2.0, 0.7, 0.2, 1.1, 3.7, 0.6, …
Final output performance measures:
Average delay in queue = 5.7/6 = 0.95 min./cust.
Time-average number in queue = 9.9/8.6 = 1.15 custs.
Server utilization = 7.7/8.6 = 0.90 (dimensionless)
Slide 24 .
3 Program Organization and Logic
• C or Matlab program to do this model
Event types: 1 for arrival, 2 for departure
Modularize for initialization, timing, events, library, report,
main
• Changes from hand simulation:
Stopping rule: n = 1000 (rather than 6)
Interarrival and service times “drawn” from an exponential
distribution (mean b = 1 for interarrivals, 0.5 for service
times)
– Density function
Slide 26 .
4. Alternative Stopping Rules
Slide 28 .
1.1 Problem Statement - SSQ
5. Specification model : notation