Transcript Document

Lesson Objective
Understand how we can Simulate activities that have an element
of chance using probabilities and random numbers
Be able to use the random number generator on a calculator to
simulate a practical situation
The Rnd# button on your calculator generates a random number
between 0 and 1 every time you press it.
Suppose we wanted to simulate the tossing of a coin:
Read the first number after the decimal point if it is 0,1,2,3,4 = Head
if it is 5,6,7,8,9 = Tail
How do we simulate a fair 6 sided die?
How do we simulate a biased 6 sided die where the probabilities are:
P(1) = 0.1
P(2) = 0.25
P(3) = 0.4
P(4) = 0.05
P(5) = 0.1
P(6) = 0.1
Task 1
Use the Rnd# button on your calculator to decide if the Swimming
pool can be completed on time using both models.
Task 2
Example 1
A driving instructor keeps records of passes and fails. From his
records he finds the following probabilities.
Number of attempts taken to pass the test
1
2
3
Probability
0.2
0.3
0.2 0.15 0.1
4
5
(i) Give a rule to use two-digit random numbers to simulate the
number of attempts taken to pass the test.
(ii) Use your rule to simulate the results for five learner drivers,
using the random numbers below.
Random numbers:
26
56
65
35
34
74
14
34
6
0.05
Task 3
Example 2
A driving instructor keeps records of passes and fails. From his
records he finds the following probabilities.
Attempt at driving test
1
2
3
4
Probability of passing test
0.4
0.6
0.5
0.2 0.1 0.05
5
(i) Give rules to use two-digit random numbers to simulate the
number of attempts taken to pass the test.
(ii) Use your rule to simulate the results for five learner drivers,
using the random numbers below.
Random numbers:
87
54
4
51
52
38
73
95
39
33
23
95
76
69
34
6
Simulating Queuing Times
There are two basic approaches to model queuing situations:
1) Is to use a random number generator to calculate the times
between arrivals – the arrival interval time.
2) Is to split time into chunks and then decide using a random
number generator what the probability of someone arriving in
that interval actually is.
Eg From experiment it has been estimated that 12 people arrive
at a petrol station in an hour.
0 – 2 mins probability of someone arriving is 12/30
2 – 4 mins etc
A petrol station wants to install a/some car washes.
It always takes 12mins to wash a car in the car wash they intend to
purchase.
Interval between
arrivals
(ie. Time since
last arrival)
Frequency
3
6
9
12
15
30
45
15
5
5
What is the average interval time?
How many car washes would you therefore
recommend to meet demand?
Interval between
arrivals
(ie. Time since
last arrival)
Frequency
3
6
9
12
15
30
45
15
5
5
2 Car Washes
12mins to wash a car
Draw up a table to simulate the arrival of cars over a two hour
period based on a 2 digit random number.
Use your table to simulate the queue for the car
wash if we assume they install 2 car washes and
that there is a single queue with people going to
the first available washer.
2 Car Washes
12mins to wash a car
Draw up a table to simulate the arrival of cars over a two hour
period based on a 2 digit random number.