What's wrong with this approach for finding expected number of throws before 2 identical throws?

35 Views Asked by At

I am trying to find the expected number of throws before a die shows up the same twice in a row.

The definition of expected value is $$E(n) = \sum_nnP(n)$$

I have seen other answers elsewhere on how to solve this problem, but my approach is thus:

Succeeding on the $n^{th}$ throw requires that you failed on the $(n-1)^{th}$ throw. So it makes sense that $$P(n) = \frac{1}{6}(1-P(n-1))$$ since, after $n-1$ throws, you must roll what was rolled on the $(n-1)^{th}$ throw, and there is a $1/6$ chance of that. Having Wolfram do the heavy lifting with $P(2) = 1/6$ I get $$P(n) = \frac{1}{7}(-\frac{1}{6})^n((-6)^n+6)$$

So it seems to me that $$E(n) = \sum_{n=2}^\infty nP(n)$$ but, apparently, this is divergent. So what is wrong with this approach?