I am an avid board game player, especially ones with miniatures that duke it out (Risk, Axis and Allies, etc.) and I'm trying to analyze efficiency of different units in one of my more recent pickups.
In the game (Battlelore Second Edition for those who are curious), you get a hit on either a 5 or a 6. This would be simple if you're just rolling one die. However, figures in this game roll up from 1 die, all the way up to 5 dice (maybe more in certain situations) and I'm having a bugger of a time figuring out the probability. I set up a table in excel that takes the amount of dice being rolled in the column, and checks the probability of getting 1, 2, 3, 4 or 5 hits in each respective row. I'd rather not list out all of the possibilities and count them, so I'm look for an equation of course.
To sum up: I need an equation(s) that gives Z, the probability of getting X hits with Y dice where hits are on 5's and 6's.
EDIT: I have gotten as far as all of the chances of getting 1 hit with Y dice, as well as the chance of 2 hits with up to 3 dice, but 4 dice with 2 hits and onwards it giving me trouble.
This is a binomial distribution with $p = \frac13,$ since that is the probability of rolling a $5$ or $6$ on one die. The probability of exactly $k$ hits on $n$ dice is
$$ P_n(k) = \binom nk \left(\frac13\right)^k \left(\frac23\right)^{n-k} $$
where $\binom nk$ is a binomial coefficient; $$ \binom nk = \frac{n!}{(n-k)!k!} = \frac{n(n-1)(n-2)\cdots(n-k+2)(n-k+1)}{k(k-1)(k-2)\cdots(2)(1)}. $$