Take the 2-minute tour ×
Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. It's 100% free, no registration required.

Six dice are thrown. The six dice are thrown a second time. What is the probability of getting the same numbers as in the first throw? If the order of the six numbers matters, the problem is easy, but if the order does not matter, I find myself in troubles, because I should consider too many cases depending on the number of repeated numbers and don't know how to proceed.

share|improve this question
Here is a tabulation of the cases and the probability for each case. I hope this helps. –  MJD Mar 28 '12 at 16:02
Yes, it helps in the sense that now it is immediate to conclude, but is there some slick way to do this? I mean, how can one produce your table during an examination, when time is limited? (this is part of an exercise taken from an exam paper in probability) –  quark1245 Mar 28 '12 at 16:42
add comment

2 Answers 2

up vote 3 down vote accepted

The number $a_n$ of favourable events for $n$ $n$-sided dice is OEIS sequence A033935. There's a formula given there,


(where $[x^n]$ denotes extraction of the coefficient of $x^n$), which is a succinct statement of the perhaps more obvious formula

$$a_n=\sum_{1n_1+2n_2+\dotso+kn_k=n}\frac{n!}{(n-(n_1+\dotso+n_k))!}\frac1{n_1!\cdots n_k!}\left(\frac{n!}{1!^{n_1}\cdots k!^{n_k}}\right)^2\;,$$

where if we have $n_j$ groups of $j$ identical dice each, the first factor gives the number of ways of assigning values to the groups, the second factor accounts for the fact that it doesn't matter which group a value is assigned to as long as it has a certain number of dice, and the third factor gives the number of favourable events for each assignment, which is the square of the number of distinct permutations of the dice given the assignment.

share|improve this answer
add comment

Based initially on Mark Dominus's table, you get

Pattern  Ways Different Ways/Different  (Ways/Different)^2  Ways^2/Different
AAAAAA      6     6         1                1                    6
AAAAAB    180    30         6               36                 1080
AAAABB    450    30        15              225                 6750
AAAABC   1800    60        30              900                54000
AAABBB    300    15        20              400                 6000
AAABBC   7200   120        60             3600               432000
AAABCD   7200    60       120            14400               864000
AABBCC   1800    20        90             8100               162000
AABBCD  16200    90       180            32400              2916000
AABCDE  10800    30       360           129600              3888000
ABCDEF    720     1       720           518400               518400
Sum     46656   462      1602           708062              8848236

And the answer is $\dfrac{8848236}{46656^2} \approx 0.0040648\ldots$

Note, as joriki suggests, that $8848236$ is the sixth term of OEIS A033935, though if you are using a number of six-sided dice then OEIS A169715 is more relevant.

share|improve this answer
add comment

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

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