Calculating Probability for Repeated Numbers in Random Number Generation

In summary, the conversation discusses the probability of getting at least 5 out of 6 random numbers to be the same when using a random number generator with 10 possibilities. Two methods are suggested to find the answer, one using combinations and the other using permutations. The formula for combinations with repetition is explained, but it is determined that the problem actually involves sampling with replacement. The conversation also mentions a card problem and explains why this problem does not work the same way. The second method involves counting the cases rather than using a formula. The final solution involves considering all possible configurations and adding them up.
  • #1
Physics_wiz
228
0
Say I have a random number generator that generates numbers between 0 and 9 inclusive (10 possibilities) and I run it 6 times. What I am trying to find is the probability that at least 5 of those 6 random numbers will be the same.

I could think of 2 ways to find the answer, the first one:

(10^6) is the total number of possible 6 digit numbers generated. The number of numbers that have the same 5 or 6 of the same digits will be
10*[ (6C5 + 6C6) ]. Where 6C5 is the number of choices for the locations of the 5 digits that are the same and 6C6 = 1 is for the possibility when all digits are the same). 10*[ (6C5 + 6C6) ] = 10*(6+1) = 70. The probability would then be 70/(10^6).

The second way:

This involves the number of combinations with repetition of picking out of 10 digits 6 times. The formula I found is (n+r-1)!/(r!(n-1)!) where in this case, n = 10 and r = 6. This gives me the total number of possible combinations after which I would divide 70 by that number to get the probability. However, in this case the number of possible combinations is 5005 instead of 10^6. I believe 5005 is wrong because the first way gives me an answer that I think is closer to the right answer.

What exactly does the formula for combinations with repetition calculate? How can I use it in the above problem?
 
Physics news on Phys.org
  • #2
The relevant concept for the denominator is not combination; it is permutation. 106 is the number of permutations that one can get out of 10 numbers and 6 slots, where ABCDEF is counted differently from ABCDFE (although A=B, etc., is allowed). In contrast, combination counts subsets, so ABCDEF is treated identical to ABCDFE. See http://en.wikipedia.org/wiki/Combinatorics
 
Last edited:
  • #3
Ahh I see now. I feel pretty stupid about missing that with the second way I thought the problem could be solved. Thanks for clarifying.
 
  • #4
A card problem involves sampling without replacement. But, this is a problem that involves sampling with replacement. Why? Well suppose you chose 10 integers for each digit, or 60 integers. Then the chance of pulling any given integer is 1/60, but if we pull a 1, then there are now only 59 integers remaining and the chances of pulling a 1 have dropped to 9/59, where as the chances of a 2 is 10/59. This problem does not work that way.

This problem is worked by attempting to count the cases, rather than first looking for a formula. So just consider five 5s. Now if we want to add another digit we have 6 places to put that, but we have only 9 integers we can so use, because for the 5 itself, we have only one way it can be used because six 5s are all the same. Thus there are 55 ways we can fill the spaces. Since there are 10 integers we can use, including the original choice of 5s, we have 550 such numbers.
 
Last edited:
  • #5
Consider the following

First, getting the prob of all numbers being the same is standard. Try getting five numbers equal, for every possible configuration(conditional probability).
for each configuration draw a sixth number, which will be either = or unequal to the five equal numbers. "Add" it all up, and you are done.

Regards,
Reilly Atkinson
 

1. What is probability calculation?

Probability calculation is a mathematical method used to determine the likelihood of a particular event occurring. It involves analyzing the possible outcomes of a given scenario and assigning a numerical value to represent the chances of each outcome happening.

2. How is probability calculated?

Probability is calculated by dividing the number of favorable outcomes by the total number of possible outcomes. This yields a decimal value between 0 and 1, which can be converted to a percentage to represent the likelihood of the event occurring.

3. What is the difference between theoretical and experimental probability?

Theoretical probability is based on mathematical calculations and assumes that all outcomes are equally likely. Experimental probability, on the other hand, is based on real-world data and takes into account the actual frequency of each outcome occurring.

4. What are the different types of probability?

There are three main types of probability: theoretical, experimental, and subjective. Theoretical probability is based on mathematical calculations, experimental probability is based on real-world data, and subjective probability is based on personal beliefs or opinions.

5. How is probability used in real life?

Probability is used in various fields such as statistics, economics, and science to make predictions and informed decisions. It is also commonly used in gambling and risk assessment to determine the likelihood of certain outcomes and make strategic choices.

Similar threads

  • Set Theory, Logic, Probability, Statistics
Replies
6
Views
1K
  • Set Theory, Logic, Probability, Statistics
Replies
8
Views
1K
  • Set Theory, Logic, Probability, Statistics
Replies
5
Views
2K
  • Set Theory, Logic, Probability, Statistics
Replies
1
Views
1K
  • Set Theory, Logic, Probability, Statistics
Replies
7
Views
2K
  • Set Theory, Logic, Probability, Statistics
Replies
14
Views
931
  • Set Theory, Logic, Probability, Statistics
Replies
3
Views
1K
  • Set Theory, Logic, Probability, Statistics
Replies
7
Views
338
  • Set Theory, Logic, Probability, Statistics
Replies
6
Views
1K
  • Set Theory, Logic, Probability, Statistics
Replies
6
Views
1K
Back
Top