When the formula is hard, simulate
A cereal company puts one of 4 different toys in each box, each equally likely. How many boxes do you expect to buy to collect all 4? The distribution of that number is hard to work out with the tools in this unit. But you can simulate it: roll a 4-sided device (or draw from 4 card suits), record which toys you get, and count boxes until you have them all. Repeat 100 times, and you have a good estimate of the whole distribution.
Simulation is also how scientists, engineers and actuaries check their theory, and it is used for problems with no formula at all, such as wait times in a hospital emergency room or the spread of traffic at an intersection. In the unit Probability you used simulation to estimate single probabilities. Here you will use it to estimate whole distributions.
Hands-on activitySimulate the toy collector at home
You need: a standard deck of cards (or a 4-sided spinner made from paper, a pencil and a paper clip), pencil and paper.
- Let the 4 suits stand for the 4 toys.
- Draw a card, note its suit, put it back and shuffle. Keep going until you have seen all 4 suits. Record X = the number of draws.
- Repeat for 25 trials (share the work with family members if you can).
- Make a frequency table and a histogram, and find the mean of X.
- Compare your mean with the theoretical 25/3 ≈ 8.33 and your histogram's shape with the one in this lesson.
- Extension: how would you change the simulation if one toy were rare (say, probability 1/10)?
What to look for: a mean somewhere around 7 to 10 and a right-skewed histogram with most values between 5 and 11. For the extension, use random digits: 0 = rare toy, and 1–3, 4–6, 7–9 for the other three toys (each 3/10). The rare toy makes the expected number of boxes much larger.