Queueing and service simulation

A question is this type if and only if it involves simulating arrivals, service times, and waiting in queue systems (laptop loans, bus passengers, traffic lights, service station).

4 questions

OCR MEI D1 2005 January Q5
5 There is an insert for use in parts (iii) and (iv) of this question.
This question concerns the simulation of cars passing through two sets of pedestrian controlled traffic lights. The time intervals between cars arriving at the first set of lights are distributed according to Table 5.1. \begin{table}[h]
Time interval (seconds)251525
Probability\(\frac { 3 } { 7 }\)\(\frac { 2 } { 7 }\)\(\frac { 1 } { 7 }\)\(\frac { 1 } { 7 }\)
\captionsetup{labelformat=empty} \caption{Table 5.1}
\end{table}
  1. Give an efficient rule for using two-digit random numbers to simulate arrival intervals.
  2. Use two-digit random numbers from the list below to simulate the arrival times of five cars at the first lights. The first car arrives at the time given by the first arrival interval. Random numbers: \(24,01,99,89,77,19,58,42\) The two sets of traffic lights are 23 seconds driving time apart. Moving cars are always at least 2 seconds apart. If there is a queue at a set of lights, then when the red light ends the first car in the queue moves off immediately, the second car 2 seconds later, the third 2 seconds after that, etc. In this simple model there is to be no consideration of accelerations or decelerations, and the lights are either red or green. Table 5.2 shows the times when the lights are red. \begin{table}[h]
    \multirow{2}{*}{
    first set
    of lights
    }
    red start time1450105155
    \cline { 2 - 6 }red end time2965120170
    \multirow{2}{*}{
    second set
    of lights
    }
    red start time1055105150
    \cline { 2 - 6 }red end time2570120165
    \captionsetup{labelformat=empty} \caption{Table 5.2}
    \end{table}
  3. Complete the table in the insert to simulate the passage of 10 cars through both sets of traffic lights. Use the arrival times given there.
  4. Find the mean delay experienced by these cars in passing through each set of lights.
  5. How could the output from this simulation model be made more reliable?
OCR MEI D1 2005 June Q5
3 marks
5 A computer store has a stock of 10 laptops to lend to customers while their machines are being repaired. On any particular day the number of laptop loans requested follows the distribution given in Table 5.1. \begin{table}[h]
Number requested01234
Probability0.200.300.200.150.15
\captionsetup{labelformat=empty} \caption{Table 5.1}
\end{table}
  1. Give an efficient rule for using two-digit random numbers to simulate the daily number of requests for laptop loans.
  2. Use two-digit random numbers from the list below to simulate the number of loans requested on each of ten successive days. Random numbers: \(23,02,57,80,31,72,92,78,04,07\) The number of laptops returned from loan each day is modelled by the distribution given in Table 5.2, independently of the number on loan (which is always at least 5 ). \begin{table}[h]
    Number returned0123
    Probability\(\frac { 1 } { 6 }\)\(\frac { 1 } { 4 }\)\(\frac { 1 } { 4 }\)\(\frac { 1 } { 3 }\)
    \captionsetup{labelformat=empty} \caption{Table 5.2}
    \end{table}
  3. Give an efficient rule for using two-digit random numbers to simulate the daily number of laptop returns.
  4. Use two-digit random numbers from the list below to simulate the number of returns on each of ten successive days. Random numbers: \(32,98,01,32,14,21,32,71,82,54,47\) At the end of day 0 there are 7 laptops out on loan and 3 in stock. Each day returns are made in the morning and loans go out in the afternoon. If there is no laptop available the customer is disappointed and never gets a loaned laptop.
  5. Use your simulated numbers of requests and returns to simulate what happens over the next 10 days. For each day record the day number, the number of laptops in stock at the end of the day, and the number of customers that have to be disappointed.
    [0pt] [3] To try to avoid disappointing customers, if the number of laptops in stock at the end of a day is 2 or fewer, the store sends out e-mails to customers with loaned laptops asking for early return if possible. This changes the return distribution for the next day to that given in Table 5.3. \begin{table}[h]
    Number returned01234
    Probability0.10.10.40.20.2
    \captionsetup{labelformat=empty} \caption{Table 5.3}
    \end{table}
  6. Simulate the 10 days again, but using this new policy. Use the requests you produced in part (ii). Use the random numbers given in part (iv) to simulate returns, but use either the distribution given in Table 5.2 or that given in Table 5.3, depending on the number of laptops in stock at the end of the previous day. Is the new policy better?
OCR MEI D1 2008 June Q4
2 marks
4 Joe is to catch a plane to go on holiday. He has arranged to leave his car at a car park near to the airport. There is a bus service from the car park to the airport, and the bus leaves when there are at least 15 passengers on board. Joe is delayed getting to the car park and arrives needing the bus to leave within 15 minutes if he is to catch his plane. He is the \(10 ^ { \text {th } }\) passenger to board the bus, so he has to wait for another 5 passengers to arrive. The distribution of the time intervals between car arrivals and the distribution of the number of passengers per car are given below.
Time interval between cars (minutes)12345
Probability\(\frac { 1 } { 10 }\)\(\frac { 3 } { 10 }\)\(\frac { 2 } { 5 }\)\(\frac { 1 } { 10 }\)\(\frac { 1 } { 10 }\)
Number of passengers per car123456
Probability\(\frac { 1 } { 6 }\)\(\frac { 1 } { 3 }\)\(\frac { 1 } { 12 }\)\(\frac { 1 } { 4 }\)\(\frac { 1 } { 12 }\)\(\frac { 1 } { 12 }\)
  1. Give an efficient rule for using 2-digit random numbers to simulate the intervals between car arrivals.
  2. Give an efficient rule for using 2-digit random numbers to simulate the number of passengers in a car.
  3. The incomplete table in your answer book shows the results of nine simulations of the situation. Complete the table, showing in each case whether or not Joe catches his plane.
  4. Use the random numbers provided in your answer book to run a tenth simulation.
    [0pt]
  5. Estimate the probability of Joe catching his plane. State how you could improve your estimate. [2]
OCR MEI D1 2006 January Q6
6 Answer part (iv) of this question on the insert provided. There are two types of customer who use the shop at a service station. \(70 \%\) buy fuel, the other \(30 \%\) do not. There is only one till in operation.
  1. Give an efficient rule for using one-digit random numbers to simulate the type of customer arriving at the service station. Table 6.1 shows the distribution of time taken at the till by customers who are buying fuel.
    Time taken (mins)11.522.5
    Probability\(\frac { 3 } { 10 }\)\(\frac { 2 } { 5 }\)\(\frac { 1 } { 5 }\)\(\frac { 1 } { 10 }\)
    \section*{Table 6.1}
  2. Specify an efficient rule for using one-digit random numbers to simulate the time taken at the till by customers purchasing fuel. Table 6.2 shows the distribution of time taken at the till by customers who are not buying fuel.
    Time taken (mins)11.522.53
    Probability\(\frac { 1 } { 7 }\)\(\frac { 2 } { 7 }\)\(\frac { 2 } { 7 }\)\(\frac { 1 } { 7 }\)\(\frac { 1 } { 7 }\)
    \section*{Table 6.2}
  3. Specify an efficient rule for using two-digit random numbers to simulate the time taken at the till by customers not buying fuel. What is the advantage in using two-digit random numbers instead of one-digit random numbers in this part of the question? The table in the insert shows a partially completed simulation study of 10 customers arriving at the till.
  4. Complete the table using the random numbers which are provided.
  5. Calculate the mean total time spent queuing and paying.