[Math] Probability of rolling a sum of N with up to infinite rolls of a die

diceprobability

I'm trying to figure out if there is some (relatively simple) formula for calculating the probability of rolling a sum of N with as many rolls as needed with a single regular six-sided die.
For example:
$N=1$ is $0.16666 = 1/6 = 1/6$ (1)
$N=2$ is $0.19444 = 7/36 = 1/6 + 1/36$ (2 or 1,1)
$N=3$ is $0.22685 = 49/216 = 1/6 + 2/36 + 1/216$ (3 or 1,2/2,1 or 1,1,1)
$N=4$ is $0.26466 = 343/1296 = 1/6 + 3/36 + 3/216 + 1/1296$ (4 or 2,1/1,2/2,2 or 1,1,2/1,2,1/2,1,1 or 1,1,1,1)

Does this series converge to essentially one and is there some good formula?

It seems like pascal's triangle is involved somehow (at least for n=1-6, but I'm not sure how (if even possible) to convert it into a formula. Any help/advice is appreciated.

Best Answer

Let $q(x)=\frac{1}{6}\left(x^1+x^2+x^3+x^4+x^5+x^6\right)$. Write:

$$\begin{align}G(x)&=\sum_{n=0}^\infty q(x)^n\\&=\frac{1}{1-q(x)}\\&=\frac{6}{6-x-x^2-x^3-x^4-x^5-x^6} \end{align}$$

Then the coefficient of $x^N$ in $G(x)$ is your probability.

So you need to know something about the roots of the denominator. $1$ is one such root, but you are going to need to deal with complex roots, as well, or at least get an upper bound for the roots.

The formula is:

$$p(N)=a_1\alpha_1^N+a_2\alpha_2^N+\cdots a_6\alpha_6^N$$

For some constants $a_i$ and with the $\alpha_i$ the inverse roots of the denominator.

According to Wolfram Alpha, the roots of the denominator are $1$ and a bunch of values (one real, four complex) with absolute value greater than $1$.

So for large enough $N$, $p(N)\approx a_1$.

We can find $a_1$ by doing the usual partial fractions computation:

$$\lim_{x\to 1} G(x)(1-x)=\frac{2}{7}=\frac{1}{3.5}$$ which is what Arthur conjectured in comments above.

It turns out for $i>1$, $|\alpha_i|<\frac{3}{4}$, so we have:

$$p(N)=\frac{2}{7} + o\left(\left(\frac 34\right)^N\right)$$


We can also get a recursion:

$$P(n+6)=\frac{1}{6}\left(P(n)+P(n+1)+P(n+2)+P(n+3)+P(n+4)+P(n+5)\right)$$

We get $P(28)=.2857\dots.$ For $n\geq 88$ we get:

$$P(n)=0.285714285714\dots$$ which is $12$ digits of accuracy to $\frac{2}{7}=0.\overline{285714}.$

We also get that $$\frac{P(100)-\frac{2}{7}}{\left(\frac34\right)^{100}}\approx -0.016$$

and

$$\frac{P(1000)-\frac{2}{7}}{\left(\frac34\right)^{1000}}\approx 7.34\times 10^{-13}$$

(Computing the left side with python Fraction class to get exact value, then converted to float.)

This gives:

$$P(1000)-\frac{2}{7}\approx 8.45\times 10^{-138}$$

Related Question