1
$\begingroup$

If I roll an n-sided die m times, what is the probability of getting only one face, two faces, .... or n faces?

Let us assume that I have a 6-sided die and I roll it 10 times. I want to calculate different probabilities. The probability of getting only one face from all rolls. The probability of getting only 2 faces in all rolls and so on until calculating the probability of the appearance of the 6 faces (at least one time for each face) in all rolls.

$\endgroup$
  • $\begingroup$ Could you clarify. $\endgroup$ – marshal craft Nov 1 '17 at 6:37
  • $\begingroup$ OK, can you calculate the said probabilities after one roll? How about two rolls? $\endgroup$ – Ivan Neretin Nov 1 '17 at 7:32
2
$\begingroup$

The probability that $x$ faces have appeared at least once after $m$ throws of a fair $n$-faced die is $$Pr(X=x \mid m) = \frac{S_2(m,x) \, n!} {(n-x)!\,n^m}$$ where $S_2(m,x)$ is a Stirling number of the second kind

So for example with $n=6$ and $m=10$ you would get $$Pr(X=2) = \frac{511 \times 720} {24 \times 60466176} \approx 0.000254$$

You could calculate this recursively using $$Pr(X=x \mid m)=\frac{n-x+1}{n}Pr(X=x-1 \mid m-1) + \frac{x}{n}Pr(X=x \mid m-1)$$ starting with $Pr(X=0 \mid m)=0$ and $Pr(X=x \mid 0)$ except $Pr(X=0 \mid 0)=1$. That would give a table like this:

    x   1           2           3           4           5           6
m                           
1       1           0           0           0           0           0
2       0.166667    0.833333    0           0           0           0
3       0.027778    0.416667    0.555556    0           0           0
4       0.004630    0.162037    0.555556    0.277778    0           0
5       0.000772    0.057870    0.385802    0.462963    0.092593    0
6       0.000129    0.019933    0.231481    0.501543    0.231481    0.015432
7       0.000021    0.006752    0.129029    0.450103    0.360082    0.054012
8       0.000004    0.002268    0.069016    0.364583    0.450103    0.114026
9       0.000001    0.000759    0.036020    0.277563    0.496614    0.189043
10      0.0000001   0.000254    0.018516    0.203052    0.506366    0.271812
$\endgroup$
  • $\begingroup$ Many thanks dear, this is really helpful. $\endgroup$ – user498036 Nov 1 '17 at 23:36

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.