Main content

### Course: Grade 7 math (FL B.E.S.T.) > Unit 8

Lesson 2: Theoretical and experimental probabilities- Theoretical and experimental probabilities
- Making predictions with probability
- Making predictions with probability
- Experimental versus theoretical probability simulation
- Random number list to run experiment
- Random numbers for experimental probability
- Interpret results of simulations
- Simulation and randomness: Random digit tables

© 2024 Khan AcademyTerms of usePrivacy PolicyCookie Notice

# Simulation and randomness: Random digit tables

We can simulate events involving randomness like picking names out of a hat using tables of random digits. Tables of random digits can be used to simulate a lot of different real-world situations. Here's $2$ lines of random digits we'll use in this worksheet:

Line $1$ : $96565{\textstyle \phantom{\rule{0.167em}{0ex}}}{\textstyle \phantom{\rule{0.167em}{0ex}}}05007{\textstyle \phantom{\rule{0.167em}{0ex}}}{\textstyle \phantom{\rule{0.167em}{0ex}}}16605{\textstyle \phantom{\rule{0.167em}{0ex}}}{\textstyle \phantom{\rule{0.167em}{0ex}}}81194{\textstyle \phantom{\rule{0.167em}{0ex}}}{\textstyle \phantom{\rule{0.167em}{0ex}}}14873{\textstyle \phantom{\rule{0.167em}{0ex}}}{\textstyle \phantom{\rule{0.167em}{0ex}}}04197{\textstyle \phantom{\rule{0.167em}{0ex}}}{\textstyle \phantom{\rule{0.167em}{0ex}}}85576{\textstyle \phantom{\rule{0.167em}{0ex}}}{\textstyle \phantom{\rule{0.167em}{0ex}}}45195$

Line $2$ : $11169{\textstyle \phantom{\rule{0.167em}{0ex}}}{\textstyle \phantom{\rule{0.167em}{0ex}}}15529{\textstyle \phantom{\rule{0.167em}{0ex}}}{\textstyle \phantom{\rule{0.167em}{0ex}}}33241{\textstyle \phantom{\rule{0.167em}{0ex}}}{\textstyle \phantom{\rule{0.167em}{0ex}}}83594{\textstyle \phantom{\rule{0.167em}{0ex}}}{\textstyle \phantom{\rule{0.167em}{0ex}}}01727{\textstyle \phantom{\rule{0.167em}{0ex}}}{\textstyle \phantom{\rule{0.167em}{0ex}}}86595{\textstyle \phantom{\rule{0.167em}{0ex}}}{\textstyle \phantom{\rule{0.167em}{0ex}}}65723{\textstyle \phantom{\rule{0.167em}{0ex}}}{\textstyle \phantom{\rule{0.167em}{0ex}}}82322$

Things to know about random digit tables:

- Each digit is equally likely to be any of the
digits$10$ through$0$ .$9$ - The digits are independent of each other. Knowing about one part of the table doesn't give away information about another part.
- The digits are put in groups of
just to make them easier to read. The groups and rows have no special meaning. They are just a long list of random digits.$5$

## Problem 1: Getting a random sample

There are $90$ students in a lunch period, and $5$ of them will be selected at random for cleaning duty every week. Each student receives a number $01-90$ and the school uses a random digit table to pick the $5$ students as follows:

- Start at the left of Line
in the random digits provided.$1$ - Look at
-digit groupings of numbers.$2$ - If the 2-digit number is anything between
and$01$ , that student is assigned lunch duty. Skip any other$90$ -digit number.$2$ - Skip a
-digit number if it has already been chosen.$2$

Line $1$ : $\text{}96565{\textstyle \phantom{\rule{0.167em}{0ex}}}{\textstyle \phantom{\rule{0.167em}{0ex}}}05007{\textstyle \phantom{\rule{0.167em}{0ex}}}{\textstyle \phantom{\rule{0.167em}{0ex}}}16605{\textstyle \phantom{\rule{0.167em}{0ex}}}{\textstyle \phantom{\rule{0.167em}{0ex}}}81194{\textstyle \phantom{\rule{0.167em}{0ex}}}{\textstyle \phantom{\rule{0.167em}{0ex}}}14873{\textstyle \phantom{\rule{0.167em}{0ex}}}{\textstyle \phantom{\rule{0.167em}{0ex}}}04197{\textstyle \phantom{\rule{0.167em}{0ex}}}{\textstyle \phantom{\rule{0.167em}{0ex}}}85576{\textstyle \phantom{\rule{0.167em}{0ex}}}{\textstyle \phantom{\rule{0.167em}{0ex}}}45195$

## Problem 2: Doing a simulation

A cereal company is giving away a prize in each box of cereal and they advertise, "Collect all $6$ prizes!" Each box of cereal has $1$ prize, and each prize is equally likely to appear in any given box. Caroline wonders how many boxes it takes, on average, to get all $6$ prizes.

She decides to do a simulation using random digits as follows:

- Start at the left of Line
in the random digits provided.$2$ - Look at single digit numbers.
- The digits
represent the different prizes.$1-6$ - She ignores the digits
.$0,7,8,9$ - One trial of the simulation is done when all
digits have appeared.$6$ - At the end of the trial, she counts how many digits it took for every digit
to appear (ignoring the other digits).$1-6$

Line $2$ : $\text{}11169{\textstyle \phantom{\rule{0.167em}{0ex}}}{\textstyle \phantom{\rule{0.167em}{0ex}}}15529{\textstyle \phantom{\rule{0.167em}{0ex}}}{\textstyle \phantom{\rule{0.167em}{0ex}}}33241{\textstyle \phantom{\rule{0.167em}{0ex}}}{\textstyle \phantom{\rule{0.167em}{0ex}}}83594{\textstyle \phantom{\rule{0.167em}{0ex}}}{\textstyle \phantom{\rule{0.167em}{0ex}}}01727{\textstyle \phantom{\rule{0.167em}{0ex}}}{\textstyle \phantom{\rule{0.167em}{0ex}}}86595{\textstyle \phantom{\rule{0.167em}{0ex}}}{\textstyle \phantom{\rule{0.167em}{0ex}}}65723{\textstyle \phantom{\rule{0.167em}{0ex}}}{\textstyle \phantom{\rule{0.167em}{0ex}}}82322$

## Want to join the conversation?

- I still don’t understand how to assign random digits for a simulation. For example, if the problem gives you something like “Bob makes freethrow shots 70% of the time, and his coach wants to calculate the likelihood of Bob making his free throws 4 out of the 5 times”. How would you assign digits to that type of problem??(9 votes)
- Let each random digit represent one free throw. We could let a digit less than 7 represent making a free throw (note that this occurs with probability 7/10=70% since 7 of the 10 possible values from 0 to 9 are less than 7), and let a digit greater than or equal to 7 represent missing a free throw.

Now generate a larger number of separate groups of 5 random digits. Count the number of groups, and also count how many of these groups contain 4 or more digits that are less than 7 (or equivalently no more than 1 digit that is greater than or equal to 7) . The number of groups containing 4 or more digits that are less than 7, divided by the number of groups, is an estimate of the likelihood (or probability) of making at least 4 out of 5 free throws.

Example: let's look at the 16 groups of 5 random digits given in this lesson.

96565 05007 16605 81194 14873 04197 85576 45195 11169 15529 33241 83594 01727 86595 65723 82322

Out of these 16 groups, we find that 9 have 4 or more digits that are less than 7. So 9/16 is an estimate of the likelihood of making at least 4 out of 5 free throws.

By the way, the theoretical likelihood is

(5 choose 4)(0.7)^4 (0.3) + (5 choose 5)(0.7)^5 = 5*0.07203 + 1*0.16807 = 0.52822.

So the estimate 9/16 = 0.5625 is not bad, considering that we used only 16 groups of 5 random digits.(46 votes)

- So when assigning random digits, how do you know when to use double digits and when to use singe digits?(4 votes)
- How many digits you use all depends on your sample size. If you are assigning digits to a sample of 100 people, then you'll need double digits, all numbers from 0 to 99.

A general rule of thumb is to subtract your sample size by one and assign that many digits. So for a sample size of 20, you'll need the amount of digits in 19 (20 - 1), which is 2 digits.

Hope this helped.(11 votes)

- How could we solve Question A of problem 2 without using random tables?(2 votes)
- Jerry's answer is great, and following link is a wikipedia link to this concept

https://en.wikipedia.org/wiki/Coupon_collector%27s_problem(2 votes)

- Is it just me or there is a typo in Problem 1 when the parameters are given? It says

'If the 2-digit number is anything between 01 and 90, that student is assigned LUNCH duty. Skip any other 2-digit number.'

Then the question goes on an asks about CLEANING duty. I spent a good ten minutes thinking about how I'm supposed to solve it with no cleaning duty related information.. So it's a bit confusing.(3 votes)- Yeah mate. Cleaning duty or Lunch duty, I think they are talking about ignoring numbers 0 and 91-99.(5 votes)

- I am still confused on how to do the first 2 questions.(3 votes)
- The reason I missed the first question the first time is because I included the number 96 when we were asked to just include the numbers 1 through 90. Does that help? For the second question you look at start at the beginning of the line of numbers and count from left to right until you have counted all the numbers 1 through 6. Afterward you count how many times it took you to get from 1 to 6 starting at the left (once again) and this time you're going to count all the numbers 1 through 6 (you're going to ignore any numbers above 6 because there were only 6 prizes that she needed to get) therefore once you count every number that it took (even counting repeating numbers) you come up with the answer of 12 boxes that it took. Does that make sense?(3 votes)

- I don't understand the first and third one about choosing numbers between 1-90 and why more chances for the prizes?(3 votes)
- it basically tries to say in a random sense what are the chances of 5 students to be assigned for cleaning duty. And in a random sense what are the chances of someone winning 6 prizes.(3 votes)

- How likely are three "1"s in sequence to appear in one table of random digits?(2 votes)
- Assume every digit in the sequence is independent of each other, the digit generator is fair, so that would leave us with 3 digits in sequence.

Your question is a bit vague, but let us assume

we have a sequence of 10 digits.

We know, that the probability of 3 digits in sequence is

1/10 * 1/10 * 1/10 = 1/1000.

Now, let's look at the number of places in a sequence of 10 digits, where 3 ones can be placed.

111xxxxxxx

x111xxxxxx

...

xxxxxxx111

which leaves us with 8 possibilities.

So in total, we have 8 times 1/1000 = 8/1000 or

a probability of 1/125 so a bit less than 1%.(4 votes)

- How did they get 12 boxes and not 14?(2 votes)
- "11169155293324" amongst these ignore the 9s. Count every distinct number from 1 to 6. And you will get 12 boxes.(3 votes)

- This got me curious, on average how many boxes would it take to get all 6 prizes?

Someone correct me if my thinking is wrong.

First, any prize will do, so we only need to draw once.

Second time, we have a 5/6 chance to get the price we want, which means we need to draw around 1.2 (6/5) times, which doesn't make much sense from a practical perspective but when you add up all these numbers, it will give a good estimate.

So the idea is to add up the reciprocates of the probabilities.

This adds up to 14.7, which is pretty close to the results of Grant.(3 votes)- Your approach to estimating the average number of boxes needed to get all 6 prizes is reasonable. Each time a box is opened, there is a decreasing probability of encountering a new prize. The reciprocal of these probabilities can give an estimate of the average number of boxes needed. Adding up these reciprocals yields an estimate, which in your case is close to Grant's results. However, it's essential to note that this estimation assumes a uniform distribution of prizes and may not perfectly align with actual results due to randomness and other factors.(1 vote)

- For these real-world scenarios, why don't we just randomly generate stochastic values and determine the probability that a condition is met with that?(2 votes)
- Randomly generating stochastic values and determining the probability that a condition is met with that approach could be computationally intensive and impractical, especially for scenarios with complex conditions or large sample sizes. Using tables of random digits or conducting simulations allows for a more systematic and controlled approach to studying probability in real-world scenarios.(2 votes)