The Wizard did the math on "What is the expected number of rolls of two dice for every total from 2 to 12 to occur at least once?"
That column can be found here:
Ask the Wizard #278
I hope I worded my question to be understandable.
added: (Yes, Rolling two six-sided dice)
The set we are looking for is {1,2,3,4,5,6} at least 1 of each.
So the first roll of 2 dice is 5,2
Now we wait for the 1,3,4,6 to show.
Second roll is a 4,4
Now we are waiting for the 1,3 and 6 to show.
It is the 2 dice that has my head in a spin.
I do not know where to begin.
(Get this: This question was asked by my 7 y/o grandson!
I think he gambles with his school teachers at recess.)
added: he knows the Penney Ante game rules for coin tossing!
He always makes me choose my pattern first. Kids are too smart these days.
1 roll +
1/(5/6) = 1.2 +
1/(4/6) = 1.5 +
1/(3/6) = 2 +
1/(2/6) = 3 +
1/(1/6) = 6
=14.7
Dare we just divide by 2?
7.35
Cant be that easy.
The first roll can produce 2 numbers with p = 30/36
and 1 number with 6/36
Back to the drawing board
Quote: 7crapsFor one die to see all 6 faces can be done easily.
1 roll +
1/(5/6) = 1.2 +
1/(4/6) = 1.5 +
1/(3/6) = 2 +
1/(2/6) = 3 +
1/(1/6) = 6
=14.7
Dare we just divide by 2?
7.35
Cant be that easy.
I think your result 7.35 is close. The only thing needed is to account for possible odd number of rolls of single die to get all numbers (rolling two dice just means that total number of single die rolls is always even).
N = Number of single die rolls to get all numbers 1-6.
There is no mathematical difference with rolling one die N times compared to rolling two dice N/2 times, since all the outcomes are independent from each other. So as long N is even, outcomes from N rolls of single die are indistinguishable from N/2 rolls of two dice.
The only difference between the two would come from when N is odd. Let's say that you roll all numbers 1-6 in 13 rolls of single die. With two dice this would mean 7 rolls (and not 13/2 = 6.5) and the outcome of the last die would be actually irrelevant (the first of the two dice would give you the last missing number).
If we assume that there is an equal chance of N to be even or odd, then it means that there is 50% chance that one extra roll is needed (in the odd case) to account for rolling two dice at a time, and the answer would be:
7.35 + 0.5 = 7.85 expected rolls.
However, I am not sure whether the odds for N to be even/odd is in fact 50/50 so a further calculation is needed: Rolling single die, what is the probability that collecting all numbers 1-6 ends up with even/odd number of rolls?
If you add that to the 14.7 = 15.2 then divide by 2.
=7.6
That number is very close to my sim results of 7.599786667
part of my data
roll | relative | cumulative |
---|---|---|
1 | ||
2 | ||
3 | 0.015873333 | 0.015873333 |
4 | 0.098303333 | 0.114176667 |
5 | 0.158176667 | 0.272353333 |
6 | 0.165873333 | 0.438226667 |
7 | 0.143973333 | 0.5822 |
8 | 0.114836667 | 0.697036667 |
9 | 0.087123333 | 0.78416 |
10 | 0.064303333 | 0.848463333 |
11 | 0.045086667 | 0.89355 |
12 | 0.03204 | 0.92559 |
13 | 0.022443333 | 0.948033333 |
14 | 0.01545 | 0.963483333 |
15 | 0.01114 | 0.974623333 |
16 | 0.007806667 | 0.98243 |
17 | 0.005373333 | 0.987803333 |
18 | 0.003663333 | 0.991466667 |
19 | 0.002613333 | 0.99408 |
20 | 0.00181 | 0.99589 |
Quote: 7crapsI have not had the time to look back at this. Maybe I will now, but I kind of understand the extra 0.5 roll being added.
If you add that to the 14.7 = 15.2 then divide by 2.
=7.6
That number is very close to my sim results of 7.599786667
part of my data
Ah yes, I think I made a mistake in my post. You need to add that 0.5 correction term to single die rolls and then divide by two for two dice, so your 7.6 would be correct. The fact that you got 7.599786667 from the sim suggests that this is correct. Could you also run another sim for the odds of total number of single die rolls to be odd / even?
I had a chance to get back to this problem tonight.Quote: Jufo81Ah yes, I think I made a mistake in my post. You need to add that 0.5 correction term to single die rolls and then divide by two for two dice, so your 7.6 would be correct.
The fact that you got 7.599786667 from the sim suggests that this is correct. Could you also run another sim for the odds of total number of single die rolls to be odd / even?
(I have been fighting off a real nasty cold this week and hope it is out of here.)
I started to set this up as a Markov Chain solution, thinking that "each face" one is waiting for would be a separate state with transition probabilities.
Before I finished my matrix, Matthew M. Conroy over at www.matthewconroy.com emailed me his solution.
He has an excellent paper called "A Collection of Dice Problems" that I have learned a lot from and Matt wanted to add it to his collection.
Well, I had to look at his solution, since my matrix is not yet completed.
Of course, he did an excellent job.
Link to the pdf and his solution. It is Question #3. Solution starts on page 9.
A Collection of Dice Problems
Just in case someone else is solving this.
Jufo81, I was really thinking that our solution was too easy and my simulations that I ran, sorry I have not ran any that you have asked, kept me right at that
7.599786667 value.
His exact answer is 70219/9240
about 7.59945887445....
With the matrix, one can also raise it to any power for each roll to get the probability distribution and Matt also included that up to 24 rolls.
Is there another solution?
Yes, I am sure there is. Maybe that will come later.
here is a part of Matt's solution
Quote: 7craps
Jufo81, I was really thinking that our solution was too easy and my simulations that I ran, sorry I have not ran any that you have asked, kept me right at that
7.599786667 value.
His exact answer is 70219/9240
about 7.59945887445....
With the matrix, one can also raise it to any power for each roll to get the probability distribution and Matt also included that up to 24 rolls.
Is there another solution?
Yes, I am sure there is. Maybe that will come later.
Hi, yes Matt's Markov Chain solution is the accurate and proper one, no question about that.
Anyway, I still think that the "easier" solution I proposed is correct one as well. But it requires solving the probability that the number of single die rolls to yield all numbers 1...6 is odd. If we use following notation:
N = Number of single die rolls to get all numbers 1...6
E[...] = Expected value of [...]
I propose that the following equation:
E[Number of two dice rolls to get all numbers 1...6] = ( E[N] + Prob(N is odd) ) / 2
will give the exact same solution.
You already calculated above that E[N] = 14.7, so it's only a matter of calculating: Prob(N is odd). However, calculating this might lead to the same kind of Markov Chain as in Matt's solution.