# A (simple ?) probability question.

**URL:** https://boards.straightdope.com/t/a-simple-probability-question/656348
**Category:** Factual Questions
**Created:** [April 21, 2013, 11:34pm UTC](https://boards.straightdope.com/t/a-simple-probability-question/656348 "2013-04-21T23:34:53Z")
**Posts on this page:** 15
**Page:** 3

<div class="post-metadata">

### Author: ![Jragon](https://avatars.discourse-cdn.com/v4/letter/j/e19b73/32.png) [@Jragon](https://boards.straightdope.com/u/Jragon)
#### Post date: [April 22, 2013, 11:22pm UTC](https://boards.straightdope.com/t/a-simple-probability-question/656348/41 "2013-04-22T23:22:18Z")

</div>

Oh, you’re right, I confused it with the chance of getting a unique ON THE FIRST ROLL (or perhaps getting at least one unique). Which is, indeed, 1.

---

<div class="post-metadata">

### Author: ![President\_Johnny\_Gentle](https://avatars.discourse-cdn.com/v4/letter/p/5f9b8f/32.png) [@President\_Johnny\_Gentle](https://boards.straightdope.com/u/President_Johnny_Gentle)
#### Post date: [April 22, 2013, 11:32pm UTC](https://boards.straightdope.com/t/a-simple-probability-question/656348/42 "2013-04-22T23:32:34Z")

</div>

> [@Jragon](#):
>
> Hmm, that’s a tricky one. I’m not going to hash it out now, but it strikes me that this is **similar** to a scenario without replacement, but couched in a medium with replacement, if that makes sense.

If I interpret you correctly, that’s essentially how I approached the problem.

The number of ways of getting 4 unique faces appears to be C(6,4)\*[C(4,1)\*C(6,3)\*3! + C(4,2)\*C(6,2)\*C(4,2)\*2!] = 23400.

To simplify, this is (# of ways to pick the 4 unique values)\*[(# of ways to arrange 4 values if only one is repeated) + (# of ways to arrange if two are repeated)]

---

<div class="post-metadata">

### Author: ![septimus](https://sea3.discourse-cdn.com/straightdope/user_avatar/boards.straightdope.com/septimus/32/410_2.png) [@septimus](https://boards.straightdope.com/u/septimus)
#### Post date: [April 23, 2013, 9:01am UTC](https://boards.straightdope.com/t/a-simple-probability-question/656348/43 "2013-04-23T09:01:03Z")

</div>

> [@President\_Johnny\_Gentle](#):
>
> The number of ways of getting 4 unique faces appears to be C(6,4)\*[C(4,1)\*C(6,3)\*3! + C(4,2)\*C(6,2)\*C(4,2)\*2!] = 23400.

If you do such a calculation for 3 unique faces or 5 unique faces you get ISTM, in both cases, 10800.

I guess the identity between the 3-unique and 5-unique numbers is a “coincidence,” but perhaps there is some elegant bijection between the two.

---

<div class="post-metadata">

### Author: ![Hari\_Seldon](https://sea3.discourse-cdn.com/straightdope/user_avatar/boards.straightdope.com/hari_seldon/32/5173_2.png) [@Hari\_Seldon](https://boards.straightdope.com/u/Hari_Seldon)
#### Post date: [April 23, 2013, 11:48am UTC](https://boards.straightdope.com/t/a-simple-probability-question/656348/44 "2013-04-23T11:48:02Z")

</div>

> [@Great\_Antibob](#):
>
> This part doesn’t seem correct. The probability should be 9/36.
> 
> And I’ll list all outcomes to make it clear:
> 
> 1-1 1-2 1-3 1-4 1-5 1-6  
> 2-1 2-2 2-3 2-4 2-5 2-6  
> 3-1 3-2 3-3 3-4 3-5 3-6  
> 4-1 4-2 4-3 4-4 4-5 4-6  
> 5-1 5-2 5-3 5-4 5-5 5-6  
> 6-1 6-2 6-3 6-4 6-5 6-6
> 
> Of these, 11 have at least one six. 9 have a 4 but no 6. And the remaining 16 have neither.
> 
> I think your error comes from a misunderstanding. Given there are no 6’s, the probability of a 4 is indeed 9/25.
> 
> But the probability of no 6’s is 25/36, which you must also include:
> 
> Prob(4s and no 6s) = Prob(4 given no 6s)_Prob(no 6s)  
> = (9/25)_(25/36)  
> = 9/36  
> .  
> In a textbook, you might see it given as:
> 
> ```
> P(A and B) = P(A|B)*P(B)
> 
> ```

That’s nonsense. You have actually shown directly that the probability of no 6 and at least one 4 is exactly 9/25. The odds of them getting a 6 are 11/36. so the odds of winning that way are (9/25)\*(11/36). The odds of winning directly are 11/36. Those two paths are mutually exclusive, so the odds of winning are the sum.

---

<div class="post-metadata">

### Author: ![septimus](https://sea3.discourse-cdn.com/straightdope/user_avatar/boards.straightdope.com/septimus/32/410_2.png) [@septimus](https://boards.straightdope.com/u/septimus)
#### Post date: [April 23, 2013, 11:59am UTC](https://boards.straightdope.com/t/a-simple-probability-question/656348/45 "2013-04-23T11:59:37Z")

</div>

> [@Hari\_Seldon](#):
>
> You have actually shown directly that the probability of no 6 and at least one 4 is exactly 9/25.

No. And do note that _any_ probability based on rolling fair six-sided dice a finite number of times must be a whole number divided by some power of six. 9/25 lacks that property.

---

<div class="post-metadata">

### Author: ![The\_Hamster\_King](https://avatars.discourse-cdn.com/v4/letter/t/8edcca/32.png) [@The\_Hamster\_King](https://boards.straightdope.com/u/The_Hamster_King)
#### Post date: [April 23, 2013, 1:25pm UTC](https://boards.straightdope.com/t/a-simple-probability-question/656348/46 "2013-04-23T13:25:18Z")

</div>

> [@hari seldon](#):
>
> you have actually shown directly that the probability of no 6 and at least one 4 is exactly 9/25.

1-1 1-2 1-3 **1-4** 1-5 1-6  
2-1 2-2 2-3 **2-4** 2-5 2-6  
3-1 3-2 3-3 **3-4** 3-5 3-6  
**4-1 4-2 4-3 4-4 4-5** 4-6  
5-1 5-2 5-3 **5-4** 5-5 5-6  
6-1 6-2 6-3 6-4 6-5 6-6

Tries with no 6 and at least one 4 bolded. Just count them. There are 9. The probability is 9/36.

---

<div class="post-metadata">

### Author: ![President\_Johnny\_Gentle](https://avatars.discourse-cdn.com/v4/letter/p/5f9b8f/32.png) [@President\_Johnny\_Gentle](https://boards.straightdope.com/u/President_Johnny_Gentle)
#### Post date: [April 23, 2013, 1:34pm UTC](https://boards.straightdope.com/t/a-simple-probability-question/656348/47 "2013-04-23T13:34:10Z")

</div>

> [@septimus](#):
>
> If you do such a calculation for 3 unique faces or 5 unique faces you get ISTM, in both cases, 10800.
> 
> I guess the identity between the 3-unique and 5-unique numbers is a “coincidence,” but perhaps there is some elegant bijection between the two.

I’ve been looking for one, but haven’t found it. I did realize what I did could be more succinctly summarized as the number of k-unique faces being C(6,k)\*S(6,k)\*k!, where S(n,k) is the Stirling number of the second kind, which counts the number of partitions of {1,2,…,n} into k parts. S(6,k)\*k! thus counts the number of surjective functions from {1,2,…,n} onto {1,2,…,k}. This didn’t prove enlightening for finding a bijection from 3-unique to 5-unique numbers.

I did note that this is included in sequence A101817 on OEIS. If you replace the 6 by another n, there are no other similar pairings for 2 \< n \<= 12, so I’m going with coincidence.

---

<div class="post-metadata">

### Author: ![Great\_Antibob](https://avatars.discourse-cdn.com/v4/letter/g/e47c2d/32.png) [@Great\_Antibob](https://boards.straightdope.com/u/Great_Antibob)
#### Post date: [April 23, 2013, 10:04pm UTC](https://boards.straightdope.com/t/a-simple-probability-question/656348/48 "2013-04-23T22:04:06Z")

</div>

> [@The\_Hamster\_King](#):
>
> Just count them. There are 9. The probability is 9/36.

Indeed.

It strikes me that another technique I like to use with students would be useful here - try the experiment directly.

Take a pair of 6-sided die (or two d6s if you will) and record the results of a few hundred rolls. It’s probably easier to simulate this with computer software, but if you have a couple hours, it’s not too difficult to perform by hand.

There’s a sizable difference between 9/25 (or 36%) and 9/36 (or 25%).

After a minimum of 500 trials, I’m willing to put my money where my mouth is. There will be fewer than 150 rolls (30%) where you see a 4 but no 6. If **Hari Seldon** is correct, we should see more than 150 such rolls.

I’ll take it further and state that if you disqualify all the rolls with any 6 leaving around 350 out of 500 rolls, then and only then will we see 9/25 or 36% of the remaining 350 rolls with a 4 (which are still 9/36 or 25% of the original 500 rolls).

If **Hari Seldon** names some reasonable terms for the bet (say $100 to be donated to the charity of the winner’s choice), off we’ll go on the experiment.

---

<div class="post-metadata">

### Author: ![R.P.McMurphy](https://avatars.discourse-cdn.com/v4/letter/r/7993a0/32.png) [@R.P.McMurphy](https://boards.straightdope.com/u/R.P.McMurphy)
#### Post date: [April 23, 2013, 11:51pm UTC](https://boards.straightdope.com/t/a-simple-probability-question/656348/49 "2013-04-23T23:51:36Z")

</div>

You folks are amazing! You’ve also shown me why I’m not so good at this stuff.

I had guesstimated that the answer was about 40% so I’m not totally out of touch, just not good at the calculations.

I’m dumbfounded that this thread has gotten to almost 50 posts. What are the odd of that?

Just kidding. 😃

---

<div class="post-metadata">

### Author: ![ZenBeam](https://avatars.discourse-cdn.com/v4/letter/z/3ab097/32.png) [@ZenBeam](https://boards.straightdope.com/u/ZenBeam)
#### Post date: [April 24, 2013, 1:35am UTC](https://boards.straightdope.com/t/a-simple-probability-question/656348/50 "2013-04-24T01:35:04Z")

</div>

50/50.

🙂

---

<div class="post-metadata">

### Author: ![Hari\_Seldon](https://sea3.discourse-cdn.com/straightdope/user_avatar/boards.straightdope.com/hari_seldon/32/5173_2.png) [@Hari\_Seldon](https://boards.straightdope.com/u/Hari_Seldon)
#### Post date: [April 24, 2013, 4:40pm UTC](https://boards.straightdope.com/t/a-simple-probability-question/656348/51 "2013-04-24T16:40:26Z")

</div>

Mea culpa, mea maxima culpa. Whoever claimed my solution was wrong was totally correct. I guess I had a brain cramp.

If you roll two dice, there are 36 possible outcomes, of which 11 include at least one 6 and 9 include no six and at least one 4, so the chances of the latter are 9/36 = 1/4. Then you roll again with another 11/36 probability so the total chances of winning are 11/36 + (1/4)\*(11/36), which works out to 55/144 about 38%.

---

<div class="post-metadata">

### Author: ![Learjeff](https://avatars.discourse-cdn.com/v4/letter/l/94ad74/32.png) [@Learjeff](https://boards.straightdope.com/u/Learjeff)
#### Post date: [April 24, 2013, 7:35pm UTC](https://boards.straightdope.com/t/a-simple-probability-question/656348/52 "2013-04-24T19:35:12Z")

</div>

> [@Great\_Antibob](#):
>
> Indeed.
> 
> It strikes me that another technique I like to use with students would be useful here - try the experiment directly.

First off, let me say that in all of my schooling, there were only two subjects where I felt just plain stupid when my homework was corrected: poetry, and probability. Fortunately, in both cases I didn’t feel any more stupid than just about everyone else in the class, so I didn’t take it too hard. What I learned about probability is that while the fundamentals are incredibly simple, any time we try to use intuition and math to make the cases easier to count, all bets are off. This particular case is nice because we can easily enumerate and count all the cases, which is why the first answer post above was so on-point.

But the quoted post raises the part I never learned how to do the math on. How do we know how many trials we must do before our answer is significant? (More specifically, how do we calculate significance?)

Please fight my ignorance! Thanks!

---

<div class="post-metadata">

### Author: ![perfectparanoia](https://avatars.discourse-cdn.com/v4/letter/p/a5b964/32.png) [@perfectparanoia](https://boards.straightdope.com/u/perfectparanoia)
#### Post date: [April 24, 2013, 9:30pm UTC](https://boards.straightdope.com/t/a-simple-probability-question/656348/53 "2013-04-24T21:30:24Z")

</div>

> [@ultrafilter](#):
>
> If the game is to roll at least one six on a pair of dice, then your probability of winning is 11/36, or slightly more than 30%. If you’re allowed to reroll once if you get a four, then your probability of winning goes up to 55/144, or slightly better than 38%. How much value is there in getting more chances to reroll?
> 
> Suppose I let you reroll up to two times. Then your probability of winning is 11/36 + 9/36(11/36 + 9/36 \* 11/36), which works out to be 77/192, or about 40.2%. That’s still a pretty good increase, so what if you get more rerolls than that?
> 
> Let’s now look at the most extreme case. Suppose that you can keep rerolling as long as you get a four. In that case, the probability of winning _p_ is given by the solution to the equation _p_ = 11/36 + 9/36_p_. This is an easy computation, and we find that _p_ = 11/27, or about 40.7%. There’s very limited value in having more than two rerolls–in fact, having three gets you all the way up to 40.5%, which is essentially the same probability unless you’re doing a lot of gambling.
> 
> But we can be a little bit more precise in quantifying the declining marginal value of rerolls. Let _p_(_n_) denote the probability of winning when you’re given _n_ reroll attempts. We can pretty easily see that _p_(0) = 11/36, and _p_(_n_) = 11/36 + 9/36_p_(_n_ - 1) for _n_ \> 0. This is easy to solve with your favorite computer algebra system, and it gives us the solution of _p_(_n_) = 11/27(1 - 1/4[sup]n + 1[/sup]). From this, we see that the additional value of each roll is going to zero roughly as fast as 1/4[sup]n[/sup].

This is the question I thought was being asked (since, of course if you keep getting fours you get to reroll) and the answer I would have given.

---

<div class="post-metadata">

### Author: ![Great\_Antibob](https://avatars.discourse-cdn.com/v4/letter/g/e47c2d/32.png) [@Great\_Antibob](https://boards.straightdope.com/u/Great_Antibob)
#### Post date: [April 24, 2013, 9:51pm UTC](https://boards.straightdope.com/t/a-simple-probability-question/656348/54 "2013-04-24T21:51:41Z")

</div>

> [@Learjeff](#):
>
> But the quoted post raises the part I never learned how to do the math on. How do we know how many trials we must do before our answer is significant? (More specifically, how do we calculate significance?)

In this case, I was making an educated guess with sufficiently large numbers (size of the sample guided by experience).

With 500 rolls, I could be 95+% sure (again not based on calculation but reasonable intuition) that with 500 rolls, the probabilities should hew closely to the expected outcomes. Probably even 100 rolls would be ok, but it doesn’t hurt to have a safety cushion.

If I were so inclined, I would have calculated the probability of getting between 110 and 140 rolls out of 500 with a 4 but no 6 vs the probability of getting in the neighborhood of 160-200 such rolls (the difference between 9/36 and 9/25, in other words).

I haven’t bothered running the numbers, but I’m sure the probability of getting in the neighborhood of the expected 125 rolls would be fairly high and certainly higher than the 180 rolls from the 9/25 figure. Given the 9/25 figure as a null hypothesis, a result with fewer than 140 rolls would have a low associated probability.

And that’s significance testing in a nutshell. You want to set up something like a null hypothesis and test against it.

For example, your null may be: this coin is fair. One test hypothesis would be that it is biased towards heads. Another would be it is biased towards tails. To reject the null, you’d want to show that the result of an experiment matches a test hypothesis and not the null. In this case, coin flip probabilities are pretty easy to do, so you can figure out a 95% confidence level from there that the coin is biased.

For instance, if you flipped it twice and it came up heads both times, you wouldn’t have a \< 5% probability it came from a fair coin. The probability of such an event with a fair coin is 25%, which is pretty high. Your working assumption would be it was still a fair coin until you had more data.

But say you flipped it 100 times with 90 heads. The probability of 10 or fewer heads are incredibly low and certainly less than 5% (~10^-15 %). So, you can reject the null hypothesis and conclude the coin is biased.

How to determine acceptance significance levels and compute probabilities obviously depends on the problem and can often be very tricky to do. Though with dice or coin probabilities, the math is pretty well established so you just need to figure out the question to ask and how to compute the corresponding probabilities.

With something like coin flips or anything that’s a simple 50/50 yes/no, the rule of thumb is about 30 trials, so my old stats prof claimed. It seems to work ok. With dice and 1/36 probability, I’d want more - probably well in excess of 500 trials. Though we were testing a 9/36 probability instead of 1/36 which is why 100 rolls probably would have been sufficient.

---

<div class="post-metadata">

### Author: ![septimus](https://sea3.discourse-cdn.com/straightdope/user_avatar/boards.straightdope.com/septimus/32/410_2.png) [@septimus](https://boards.straightdope.com/u/septimus)
#### Post date: [April 25, 2013, 7:29am UTC](https://boards.straightdope.com/t/a-simple-probability-question/656348/55 "2013-04-25T07:29:49Z")

</div>

> [@Learjeff](#):
>
> How do we know how many trials we must do before our answer is significant?

Do you know the dice are fair, but want to verify your probability calculation?  
Or are you sure of the calculation, but want to verify the dice are fair?  
These are different problems.

Anyway, the standard deviation of a single “fair” coin toss, with {0,1} assigned as the outcomes, is 0.5. This is easy to remember because the deviation is, in fact, _always exactly 0.5_ (mean = 0.5; |1 - 0.5| = 0.5; |0 - 0.5| = 0.5). (More generally, √(p\*(1-p)) is the standard deviation of a biased coin trial.

This means the standard deviation of 4D[sup]2[/sup] coin-toss trials is D. For example, setting D= 9.7, 4D[sup]2[/sup] = 376. The number (K) of heads in 376 tosses is 188 on average.  
You’ll get 178 \< K \< 198 about 68% of the time, and 168 \< K \< 208 about 95% of the time.

Working backwards from the 4D[sup]2[/sup] = 30 trials proposed by Great Antibob, D = 2.74. With 30 tosses of a fair coin you’ll get 12 \< #Heads \< 18 almost 68% of the time, and 9 \< #Heads \< 21 about 95% of the time.

[Previous page](https://boards.straightdope.com/t/a-simple-probability-question/656348.md?page=2)
