03-Single Channel Queue
03-Single Channel Queue
Channel Queue
Arrival Departure
Checkout Counter
Assumptions
• Only one checkout counter.
• Customers arrive at this checkout counter at random from 1
to 8 minutes apart. Each possible value of interarrival time
has the same probability of occurrence, as shown in Table 2.6.
• The service times vary from 1 to 6 minutes with the
probabilities shown in Table 2.7.
• The problem is to analyze the system by simulating the arrival
and service of 20 customers.
Simulation of Queuing Systems – Single
Channel Queue
Simulation of Queuing Systems – Single
Channel Queue
Example (Cont.)
A simulation of a grocery store that starts with an empty system is
not realistic unless the intention is to model the system from
startup or to model until steady-state operation is reached.
A set of uniformly distributed random numbers is needed to
generate the arrivals at the checkout counter. Random numbers
have the following properties:
The set of random numbers is uniformly distributed between
0 and 1.
Successive random numbers are independent.
Random digits are converted to random numbers by placing a
decimal point appropriately.
*We shall tackle this later
The rightmost two columns of Tables 2.6 and 2.7 are used to
generate random arrivals and random service times.
Simulation of Queuing Systems – Single
Channel Queue
Example (Cont.)
The essence of a manual simulation is the simulation table.
The simulation table for the single-channel queue is shown in
Table 2.10.
Statistical measures of performance can be obtained form
the simulation table such as Table 2.10.
Statistical measures of performance in this example.
Each customer's time in the system
The server's idle time
In order to compute summary statistics, totals are formed as
shown for service times, time customers spend in the
system, idle time of the server, and time the customers
wait in the queue.
Simulation of Queuing Systems – Single
Channel Queue
Example (Cont.)
The average waiting time for a customer : 2.8 minutes
total time customers wait in queue 56
average waitng time 2.8 (min)
total numbers of customers 20
The probability that a customer has to wait in the queue : 0.65
number of customers who wait 13
probability ( wait ) 0.65
total numbers of customers 20
The fraction of idle time of the server : 0.21
total idle time of server 18
probability of idle server 0.21
total run time of simulation 86
The probability of the server being busy: 0.79 (=1-0.21)
Simulation of Queuing Systems – Single
Channel Queue
Example (Cont.)
The average service time : 3.4 minutes
total service time 68
average service time 3.4 (min)
total numbers of customers 20
This result can be compared with the expected service time by
finding the mean of the service-time distribution using the equation
in table 2.7.
E ( S ) sp ( s )
s 0
The expected service time is slightly lower than the average service
time in the simulation. The longer the simulation, the closer the
E (S )will be to
average
Simulation of Queuing Systems – Single
Channel Queue
Example (Cont.)
The average time between arrivals : 4.3 minutes
Example (Cont.)
The average time a customer spends in the system : 6.2 minutes
total time customers spend in system 124
average time customer spends in the system 6.2 (min)
total numbers of customers 20
average time customer spends in the system = 2.8 + 3.4 = 6.2 (min)