Update time-persistent statistical accumulators (from last event to now)
Area under Q(t)
Max of Q(t)
Area under B(t)
“Mark” arriving part with current time (use later)
If machine is idle:
Start processing (schedule departure), Make machine busy, Tally waiting time in queue (0)
Else (machine is busy):
Put part at end of queue, increase queue-length variable
Schedule the next arrival event