Decision Science Excel Simulation based on Flow Chart

profilegruiz
red_lion_scarves_simulation_logic_1.docx

Red Lion Scarves Simulation Logic – Refer to Flowchart

Logic of simulation steps: The simulation is initialized in the first block o the flowchart. A new scarf is then created. An inter-arrival time is generated to determine the time that has passed since the preceding scarf arrived. (Note: for the first scarf, the inter-arrival time determines the time since the simulation started. Thus the first inter-arrival time determines the time the first scarf arrives.) The arrival time for the new scarf must be compared to the completion time of the preceding scarf to determine whether the quality inspector is idle or busy. If the arrival time of the new scarf is greater than the completion time of the preceding scarf, the preceding scarf will have finished service (i.e., have been inspected) prior to the arrival of the new scarf. In this case, the quality inspector will be idle, and the new scarf can begin service immediately. In such cases, the service start time for the new scarf is equal to the arrival time of the new scarf. However, if the arrival time for the new scarf is not greater than the completion time of the preceding scarf, the new scarf arrived before the preceding scarf finished service. In this case, the quality inspector is busy, and the inspection of the new scarf cannot begin until the quality inspector completes the inspection of the preceding scarf. The service start time for the new scarf is equal to the completion time of the preceding scarf.

Note that the time the new scarf has to wait to use the quality inspector is the difference between the scarf’s service start time and the scarf’s arrival time. At this point, the scarf is ready to use the quality inspector, and the simulation run continues with the generation of the scarf’s service time. The time at which the scarf begins service plus the service time generated determines the scarf’s service completion time, which then becomes the earliest start time for inspection of the next scarf that arrives. Finally, the total time the scarf spends in the system is the difference between the scarf’s service completion time and the scarf’s arrival time. At this point, the computations are complete for the current scarf, and the simulation continues with the next scarf. The simulation is continued until a specified number of scarves have been served by the quality inspector.

The logic of the simulation (per the flowchart) for the first three trials is explained below. Refer to the simulated results in the lecture slides (see slide 57).

Scarf 1:

· An inter-arrival time (IAT) is generated using the function =5*RAND(). This number is 1.4 minutes.

· Because the simulation run begins at time 0, the arrival time for scarf 1 is 0 + 1.4 = 1.4 minutes.

· Scarf 1 may begin service immediately with a start time of 1.4 minutes.

· The waiting time for scarf 1 is the start time minus the arrival time: 1.4 - 1.4 = 0 minutes

· A service time ST is generated using the function =NORM.INV(Rand(), Mean, Standard Deviation). This function generated the value 2.3 minutes

· The completion time for scarf 1 is the start time plus the service time: 1.4 + 2.3 = 3.7 minutes

· The time in the system for scarf 1 is the completion time minus the arrival time: 3.7 – 1.4 = 2.3 minutes

Scarf 2:

· An inter-arrival time (IAT) is generated using the function =5*RAND(). This number is 1.3 minutes

· Because the arrival time of scarf 1 is 1.4 minutes, the arrival time for scarf 2 is 1.4 + 1.3 = 2.7 minutes

· Because the completion time of scarf 1 is 3.7 minutes, the arrival time of scarf 2 is not greater than the completion time of scarf 1, thus the quality inspector is busy when scarf 2 arrives.

· Scarf 2 must wait for scarf 1 to complete service before beginning service. Scarf 1 completes service at 3.7 minutes, which becomes the start time for scarf 2.

· The waiting time for scarf t is the start time minus the arrival time: 3.7 – 2.7 = 1 minute

· A service time ST is generated using the function =NORM.INV(Rand(), Mean, Standard Deviation). This function generated the value 1.5 minutes for the service time of scarf 2.

· The completion time for scarf 2 is the start time plus the service time: 3.7 + 1.5 = 5.2 minutes.

· The time in the system for scarf 2 is the completion time minus the arrival time: 5.2 – 2.7 = 2.5 minutes

Scarf 3:

· An inter-arrival time (IAT) is generated using the function =5*RAND(). This number is 4.9 minutes

· Because the arrival time of scarf 2 was 2.7 minutes, the arrival time for scarf 3 is 2.7 + 4.9 = 7.6 minutes

· The completion time of scarf 2 is 5.2 minutes, so the arrival time for scarf 3 is greater than the completion time of scarf 2. Thus the quality inspector is idle when scarf 3 arrives.

· Scarf 3 begins service immediately with a start time of 7.6 minutes.

· The waiting time for scarf 3 is the start time minus the arrival time: 7/6 – 7.6 = 0 minutes

· A service time ST is generated using the function =NORM.INV(Rand(), Mean, Standard Deviation). This function generated the value 2.2 minutes for the service time of scarf 3.

· The completion time for scarf 3 is the start time plus the service time: 7.6 + 2.2 = 9.8 minutes.

· The time in the system for scarf 3 is the completion time minus the arrival time: 9.8 – 7.6 = 2.2 minutes

After completing ten trials of scarves’ inspection, the average waiting time and the average time in the system were calculated. In addition, the results show the number of scarves that had to wait (i.e., 7 of the 10). The total time for the 10-scarf simulation is given by the completion time of the 10th scarf (i.e., 26.0 minutes). To get a better sense of the Red Lion Scarves inspection system, a much larger number of trials needs to be simulated.