0

What is the expected number of tosses such that there are 3 consecutive sixes.

In solving the above, this comment uses the recursion $E_{n+1}=6(E_n+1)$, justified by:

to see n+1 sixes we need to first see n sixes and then we need another 6

I understand this informally. But can we make it more formal? Here is my attempt:

  • Let $n$ be the number of consecutive sixes in the current sequence. We begin at $n=0$
  • From $n=k, k\geq1$, the system moves to $n=k+1$ with probability $\frac{1}{6}$, and moves to $n=0$ with probability $\frac{5}{6}$. In either case, the number of rolls required increases by 1.
  • Using a geometric random variable, since $n$ moves from $k$ to $k+1$ with probability $\frac{1}{6}$, the expected number of iterations is 6.

The final number of expected iterations is: $$E_{n+1}=6(E_n+1)$$

Is this justification correct?

Starlight
  • 2,684
  • It's misleading, I think, to write "Let $n$ be the number of sixes that have happened." First of all, you don't mean to count the number of sixes that have happened, rather you mean to count the number of sixes in the current string. And $n$ isn't really the number of them, but rather the state in which the current string is exactly $n$ long. If you write, e.g., $S(n)$ to denote that state then, yes, $S(n)$ goes to $S(n+1)=End$ with probability $\frac 16$ and to $S(0)=Start$ with probability $\frac 56$. – lulu Aug 22 '24 at 18:24
  • For me, it's clearer to just think about the path to the first $n$ sixes in a row. Of course, we expect that to take $E_n$ tosses. What happens next? Well, either you get a $6$ or you don't but in either case you have now used $E_n+1$ tosses. Thus $E_n=\frac 16\times (E_n+1)+\frac 56\times (E_{n+1}+E_n+1)$ which implies what you want. – lulu Aug 22 '24 at 18:26
  • Should stress: other than the ambiguity in the definition of the state, there's nothing wrong in what you wrote. As it should, it relies on the fact that, having reached $n$ in a row, the next toss either ends the game or resets you back to the start. – lulu Aug 22 '24 at 18:28
  • I was thinking in terms of state spaces, but then dropped the idea. Will rephrase my attempt in terms of state spaces shortly. Thanks for the feedback. – Starlight Aug 22 '24 at 18:28
  • And yes, number of sixes is wrong. It should be number of sixes in the current sequence. – Starlight Aug 22 '24 at 18:30
  • And I think it is clear what you intended, but as you wanted to keep things formal, it's a good point to get straight. – lulu Aug 22 '24 at 18:30

1 Answers1

1

Personally I would say take "to see $n+1$ sixes we need to first see $n$ sixes and then we need another six" as saying you take an expected $E_n$ rolls from the start to get $n$ consecutive sixes and need another roll; if that next roll was a six then you stop, but if not then you start all over again trying to get $n+1$ sixes, so

$$E_{n+1} = E_n +1 + \frac16 \times 0 +\frac56 \times E_{n+1}$$

which rearranged gives

$$E_{n+1} = 6(E_n +1).$$

We also know that we start from the trivial $E_0=0$ or from the geometric distribution giving $E_1 = 6$.

I think this is similar to your argument, at least in part.

Henry
  • 169,616
  • I am not really sure how you got the main recursion that you then rearranged. In particular, why are you multiplying by zero and why do the first two terms have no probability multiplier – Starlight Aug 22 '24 at 18:38
  • @Starlight To get $n+1$ consecutive sixes, you certainly need $n$ consecutive sixes and then an additional roll, so an expected $E_n+1$ rolls from the start with no probability adjustment. If the roll after $n$ sixes is also a six (probability $\frac16$) then you stop and need $0$ more rolls; if it is not a six (probability $\frac56$) then you start again and need an expected $E_{n+1}$ further rolls to get $n+1$ consecutive sixes. – Henry Aug 22 '24 at 19:33
  • I did not understand your explanation. If it is not a six, then you need an expected $E_{n+1}$ further rolls. But then you should you not subtract the $E_n+1$ rolls you are considering as the baseline? – Starlight Aug 23 '24 at 03:10
  • @Starlight - no. $E_{n+1}$ is the expected number of rolls at the start, and is also the expected number of additional of rolls when the most recent roll was not a six. So you need to add this. – Henry Aug 23 '24 at 09:34