chiaha-SLXFor classes · Materials

chiaha-SLX Lab 1: The barber shop

Time: 40–50 minutes
You need: a browser and a chiaha-SLX sign-in. Nothing to install.
Open it: https://slx.chiaha.com/slx?open=deck/barber

Learning goals

The problem

A one-chair barber shop opens for one 8-hour day (480 minutes). Customers arrive every 18 ± 6 minutes, spread evenly over that range. Each haircut takes 16 ± 4 minutes, also spread evenly. Customers wait in one line, first come first served.

This is the first problem in many GPSS textbooks. The deck is in the comment at the top of the model; the SLX below it is what runs. Find these lines in it:

Line in the model What it means
day_length = 480 the run length, in minutes
rv_uniform(Service, 12.0, 20.0) a haircut takes 12 to 20 minutes
iat = rv_uniform(Arrivals, 12.0, 24.0) a customer every 12 to 24 minutes
served, waited, busy customers finished, total minutes spent in line, total minutes of haircuts

Measures

Tick Show final values. After each run the output lists served, waited and busy. From them:

With several runs, each run prints its own values under a --- seed line. Work out each run's measures, then average them.

Tasks

Keep Seed at 1 throughout.

  1. One run. Set Runs to 1 and press ▶ Run. Write down served, mean wait and utilization.
  2. Five runs. Set Runs to 5 and run again. Write down each run's three measures and their averages. The first run matches task 1.
  3. Steadier haircuts. Change rv_uniform(Service, 12.0, 20.0) to rv_uniform(Service, 14.0, 18.0). The average haircut is still 16 minutes; only the spread changed. Run 5 again and record the averages.
  4. Slower haircuts. Change that line to rv_uniform(Service, 13.0, 21.0): 17 ± 4 minutes, one minute longer on average. Run 5 and record the averages.
  5. A long run. Put the haircut line back to 12.0, 20.0 and change day_length = 480 to day_length = 48000 (100 days without closing). Run 5. Record utilization and customers served per 480 minutes (served × 480 ÷ 48000).

Questions

Q1. In task 2, how far apart are the five runs' mean waits? What would you tell the shop owner if you had only run task 1?

Q2. Without simulating: on average the barber can cut one head every 16 minutes and a customer comes every 18. What share of the time should the barber be busy in the long run? How many customers should arrive in 480 minutes?

Q3. Compare task 5 with your answers to Q2. Why is the one-day utilization in task 2 lower than the long-run value?

Q4. Task 3 kept the average haircut the same and made it less variable. What happened to the mean wait? Task 4 added one minute to the average. What happened to the mean wait, and why is the effect so much larger than one minute's worth?

Q5. Five runs of one day can't separate a small change from luck. Using the five values from tasks 2 and 3, would you say steadier haircuts reduce waiting? What would you do to be more confident?


The answer key is shown to the course's instructor when signed in.