Simulations

Design and use simulations to estimate probabilities and compare results with theoretical values.

Worked examples

Estimating probability from simulation results

Straightforward

Problem

A simulation of spinning a four-section spinner (Red, Blue, Green, Yellow) was run 200 times. The results were:

| Colour | Frequency |
|--------|----------|
| Red | 54 |
| Blue | 68 |
| Green | 48 |
| Yellow | 30 |

Use the simulation results to estimate the probability of the spinner landing on each colour.

Comparing simulation estimate with theoretical probability

Moderate

Problem

A fair four-sided die (faces 1, 2, 3, 4) is rolled 80 times in a simulation. The number 1 appeared 26 times.

(a) Calculate the theoretical probability of rolling a 1.
(b) Find the expected frequency of rolling a 1 in 80 trials.
(c) Compare the simulation result with the expected frequency and explain any difference.

Designing a simulation

Challenging

Problem

A student wants to estimate the probability that **at least one** of two independent coin flips lands heads, where each flip has P(heads)=0.5P(\text{heads}) = 0.5. Design a complete simulation using random digits 0–9, run 10 example trials, and use the results to estimate the probability.

Practise

Q1·Straightforward
A simulation of 100 coin flips showed heads on 43 occasions. Use the simulation results to estimate P(heads)P(\text{heads}) as a decimal.
Q2·Straightforward
A spinner with four coloured sections was spun 200 times in a simulation. The colour blue appeared 52 times. Use the simulation results to estimate P(blue)P(\text{blue}) as a decimal.
Q3·Straightforward
A simulation uses random digits 0–9, where digits 0, 1 and 2 represent 'success' and digits 3–9 represent 'failure'. In 150 trials, 'success' occurred 48 times. Use the simulation results to estimate P(success)P(\text{success}) as a decimal.
Q4·Straightforward
A bag contains red and blue counters. A simulation of 80 draws with replacement produced 32 red results. Use the simulation results to estimate P(red)P(\text{red}) as a decimal.
Q5·Moderate
A fair six-sided die is simulated 120 times. In the simulation, the number 3 appeared 24 times, giving an estimated probability of 24120=0.2\dfrac{24}{120} = 0.2. What is the **theoretical** probability of rolling a 3 on a fair die? Give your answer as a fraction.
/
Q6·Moderate
A simulation of 240 trials produced 75 successes, giving an estimated probability of 752400.313\dfrac{75}{240} \approx 0.313. The theoretical probability of success is 0.3. How many successes would be **expected** in 240 trials based on the theoretical probability?
Q7·Moderate
A student simulates flipping a fair coin 50 times and gets 22 heads. The theoretical probability of heads is 0.5. Which statement **best** explains why the simulation result (2250=0.44\frac{22}{50} = 0.44) differs from 0.5?
Q8·Moderate
A student runs a simulation of 50 trials to estimate P(event)P(\text{event}) and gets an estimate of 0.46. They then increase the number of trials to 5000. What will most likely happen to the simulation estimate?
Q9·Challenging
A student wants to simulate an event where P(success)=0.6P(\text{success}) = 0.6 using random digits 0–9. Which mapping correctly models the situation?
Q10·Challenging
A student writes: *"I will roll a six-sided die 100 times. If I roll a 1 or 2, I record a success."* This description is incomplete. What is **missing**?
Q11·Challenging
A student uses a random number table with two-digit numbers to simulate randomly selecting a letter from the 26-letter English alphabet. They assign letters A–Z to numbers 01–26. Numbers such as 27, 58 and 00 also appear in the table. What should the student do when these numbers appear?
Q12·Challenging
Two independent events, AA and BB, have P(A)=0.5P(A) = 0.5 and P(B)=0.4P(B) = 0.4. A student wants to simulate one trial to estimate P(A and B)P(A \text{ and } B).

**Method 1:** Use two random digits per trial — the first digit models AA (digits 0–4 = AA occurs; digits 5–9 = AA fails), the second digit models BB (digits 0–3 = BB occurs; digits 4–9 = BB fails). Record success if both digits indicate their event occurred.

**Method 2:** Use one random digit per trial — digits 0–1 represent both AA and BB occurring; digits 2–9 represent at least one event failing.

Which statement is correct?