Question: 5. (20 marks) A one-pump gas station is always open and has two types of customers. A red car arrives every 30 minutes (exactly), with

 5. (20 marks) A one-pump gas station is always open and

5. (20 marks) A one-pump gas station is always open and has two types of customers. A red car arrives every 30 minutes (exactly), with the rst red car arriving at time 15 minutes. The distributions of the interarrival time (the time span between two consecutive arrivals) of green cars, and the service time for both kinds of cars are listed below. The rst green car arrives at time 0. interarrival time (mins) probability probability A car arriving to nd the pump idle goes right into service, and green cars arriving to nd the pump busy join the end of a single queue. A red car arriving to nd the pump busy, however, goes to the front of the line, ahead of any green cars in line. [If there are already other red cars at the front of the line, assume that an arriving red car gets in line ahead of them as well. If a red car and a green car arrive exactly at the same time, the red car is served rst. Initially the system is empty and idle, and the simulation is to run until exactly 10 cars (of any type) have completed their delays in queue. Find the average waiting time of the 10 cars. Use the following numbers uniformly distributed on 0099, to generate the arrival time and service time. Please use the random numbers in a parsimonious way: if there is no need to use a random number, do not use it. When a red car arrives, rst make sure the next green car will arrive only after the service of the red car starts, then assign service time for the red car. Namely only assigning service time, when the next event is the service. 56 88 29 79 93 88 56 53 30 66 10 28 53 87 79 61 33 429 74

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Mathematics Questions!