0
$\begingroup$

I am trying to model game with dice. I am throwing three dice, sum up results on them. If result is equal or less than given number, that's a success, if not - failure. Probability function $p(n)$ is defined on $n$ from 3 to 18. I suspect it's recursive: $p(n) = p(n-1)$ + number of combinations (permutations?), elements of which sum to n. As I have a probability table, I can guess $p(3)=1/216;$ $ p(4) = p(3) + 3/216;$ $ p(5) = p(4) + 6/216$. My problem is that I can't understand, how to calculate for given n number of combinations (permutations?) which sum to given n. Anyone can give any advice on this?

$\endgroup$

1 Answer 1

0
$\begingroup$

Use generating functions[assuming distinct die, I have a method for identical die too!]: $$\text{Coefficient of }x^n\text{ in }\left(\sum_{k=1}^6x^k\right)^3$$ That would be in: $$\left(\frac{1-x^7}{1-x}\right)^3=(1-x^7)^3(1-x)^{-3}$$ I hope you can use the binomial theorem now? $$(a+b)^n=\sum_{k=0}^n \binom nk a^kb^{n-k}\\\binom nr=\binom{n+r-1}r\qquad(n<0)$$

$\endgroup$
9
  • $\begingroup$ Nope, it's really not. $\endgroup$ Mar 13, 2015 at 16:36
  • $\begingroup$ @DarkArchon see edit. $\endgroup$
    – RE60K
    Mar 13, 2015 at 16:38
  • $\begingroup$ I am sorry, but it isn't any clearer to me. Still don't understand that is this thing and how it works. $\endgroup$ Mar 13, 2015 at 16:41
  • $\begingroup$ @DarkArchon I wish to create an explanatory question on this topic, w8. $\endgroup$
    – RE60K
    Mar 13, 2015 at 16:45
  • $\begingroup$ @Elaqqad that comment is uninformative, please explain what's wrong and i will gladly accept my mistake. $\endgroup$
    – RE60K
    Mar 13, 2015 at 16:48

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.