1
$\begingroup$

I have been modelling a dice game, trying to tweak the parameters to make it reasonably close to fair.

The rules are as follows: The player pays a \$1 game fee. Then she throws one normal die repeatedly until the running total hits or exceeds $10$. If the total passes $10$ without equalling it, that's a loss - no prize. If the total reaches $10$ the prize is dependent on the highest single throw value in the sequence, as follows:

  • Maximum single throw was $6$ - prize \$2
  • Maximum single throw was $5$ - prize \$3
  • Maximum single throw was $4$ - prize \$5
  • Maximum single throw was $3$ - prize \$10
  • Maximum single throw was $2$ - prize \$20
  • Maximum single throw was $1$ - prize \$50

Of course the last two prizes are mostly there for decoration, or "sucker value" if I weren't trying to make the game fair

Anyhow, the tricky part is trying to get the actual probabilities of each prize, since the number of rolls is not fixed. So can anyone see a short or pretty way of doing that?


For guidance, the probabilities from simulation (not exact values) are

$\begin{array}{c|c} \text{Outcome} & p \\ \hline \text{win, max } 1 & 0 \\ \text{win, max }2 & 0.00058 \\ \text{win, max }3 & 0.01632 \\ \text{win, max }4 & 0.06095 \\ \text{win, max }5 & 0.10498 \\ \text{win, max }6 & 0.10768 \\ \text{loss} & 0.70949 \\ \end{array}$

$\endgroup$
0

4 Answers 4

2
$\begingroup$

There are $35$ partitions of $10$ with maximal part $\leq6$.

Example: The partition $(4,2,2,1,1)$ has maximal part $4$, requires $5$ throws, and can be realized in $5\cdot{4\choose 2}=30$ ways. The probability that this partition is realized therefore comes to $30/6^5$.

Going through all $35$ partitions in this way leads to the following probabilities $p_k$ $(1\leq k\leq 6)$ of ending the game successfully with a maximal throw of $k$:

enter image description here

This means that $p_6={833\over7776}$, etc. The sum of the $p_k$ is about $0.289288$.

$\endgroup$
1
  • $\begingroup$ Good method, thanks $\endgroup$
    – Joffan
    Jul 1, 2016 at 16:17
2
$\begingroup$

As derived at Balls In Bins With Limited Capacity, there are

$$ \sum_{t=0}^m(-1)^t\binom mt\binom{m+n-t(r+1)-1}{m-1} $$

ways to distribute $n$ balls over $m$ bins with capacity $r$, where, contrary to convention, binomial coefficients with negative upper index are taken to be zero. If we subtract $1$ from each die and regard a die with rolls up to $k$ as a bin with capacity $k-1$, then with $n=10-m$ and $r=k-1$ we get the probability

$$ \textsf{Pr}(\text{win with max}\le k)=\sum_{m=1}^{10}6^{-m}\sum_{t=0}^m(-1)^t\binom mt\binom{9-tk}{m-1} $$

for obtaining a sum of $10$ in $m$ rolls up to $k$. Then the probability to obtain a sum of $10$ in $m$ rolls with a maximum roll of $k$ is the difference

$$ \textsf{Pr}(\text{win with max}=k)=\sum_{m=1}^{10}6^{-m}\sum_{t=0}^m(-1)^t\binom mt\left(\binom{9-tk}{m-1}-\binom{9-t(k-1)}{m-1}\right)\;. $$

Substituting $k=1,\ldots,6$ yields the desired probabilities, in agreement with Christian Blatter's results:

\begin{array}{c|c|c} k&\textsf{Pr}(\text{win with max}\le k)&\textsf{Pr}(\text{win with max}=k)\\\hline 1&\frac{1}{60466176}\approx0.000000&\frac{1}{60466176}\approx0.000000\\ 2&\frac{35839}{60466176}\approx0.000593&\frac{1991}{3359232}\approx0.000593\\ 3&\frac{997759}{60466176}\approx0.016501&\frac{835}{52488}\approx0.015908\\ 4&\frac{4692871}{60466176}\approx0.077612&\frac{17107}{279936}\approx0.061110\\ 5&\frac{11014759}{60466176}\approx0.182164&\frac{271}{2592}\approx0.104552\\ 6&\frac{17492167}{60466176}\approx0.289288&\frac{833}{7776}\approx0.107124\\ \end{array}

Note that the total win probability of $\frac{17492167}{60466176}\approx0.289288$ is quite close to the win probability $\frac1{\frac72}=\frac27\approx0.285714$ in the limit where the target (here $10$) goes to infinity.

$\endgroup$
3
  • $\begingroup$ Nice. I'm not sure I understand how this bit works: " If we subtract $1$ from each die..." since doesn't that then make the target variable? $\endgroup$
    – Joffan
    Jul 1, 2016 at 16:17
  • $\begingroup$ @Joffan: It does. That part was perhaps a bit unclear because I wrote the count for target $10$ but then the probability for target $10-m$; I made it more explicit now by leaving the target $n$ variable and then substituting $n=10-m$. I hope it's clearer now? $\endgroup$
    – joriki
    Jul 1, 2016 at 16:24
  • $\begingroup$ Yes, thanks for the revision. $\endgroup$
    – Joffan
    Jul 1, 2016 at 18:55
1
$\begingroup$

max of 6 happens in the following ways where the order doesn't matter [6,4]; [6,3,1]; [6,2,2]; [6,2,1,1]; [6,1,1,1,1];

Let's use the [6,2,1,1] case as an example. The exact ordering 6211 happens with probability $\frac{1}{6^{4}}$. Then it's a matter of figuring out how many distinct orderings there are. But this is $\frac{4!}{2!1!1!} = 12$ and thus, the probability of [6,2,1,1] occurring in any order is $\frac{12}{6^{4}}$

You can do this similarly for all the cases.

Here's an (expensive) python simulator that records the number of occurrences of each distinct case. You can find empirical probabilities by dividing by your sim size (n). def sim(n): c = {} for i in range(n): t = [] while sum(t) < 10: t.append(random.randint(1,6)) if sum(t) == 10: if tuple(sorted(t)) not in c: c[tuple(sorted(t))] = 0 c[tuple(sorted(t))] += 1 return c

note that the case of ten $1s$ is a $1$ in $6^{10}$, so you might see one in $10^{8}$ sims.

$\endgroup$
3
  • $\begingroup$ So what would you say is the probability of loss (bust) - not hitting the ten target? $\endgroup$
    – Joffan
    Jul 1, 2016 at 6:54
  • $\begingroup$ One minus the sum of the probabilities of winning. $\endgroup$ Jul 1, 2016 at 6:56
  • 1
    $\begingroup$ and using the silly sim at 1000000 trials it looks like the probability of busting is about 71%. $\endgroup$ Jul 1, 2016 at 6:58
0
$\begingroup$

There are six ways to end the game: scores of 10 through 15. We only care about the cases of a 10, and the rest are bust.

Drawing this as a digraph, we see the number of ways reaching:

  1. 492
  2. 484
  3. 468
  4. 436
  5. 373, and
  6. 248

for a total of 2501 possible roll combinations giving an outcome of the game.

Therefore, the odds of winning are $$\frac{492}{2501}=0.19672311\dots$$

The total of prizes should also be balanced by how likely that prize is to be obtained given that we did win, and we can find those likelihoods using partitions.

Now, how many of our winning scores have partitions, using parts no larger than 6, with a maximum number of each of 1 through 6? There are 35, in fact (42 full partitions of 10, minus 7 partitions that require a part greater than 6).

Because these rolls are also ordered while partitions are not, we then have to count the total ways to achieve each partition.

For example, the partition $6+4$ can be achieved in two ways of rolling, but the partition $2+2+2+2+1+1$ can be done in 15 ways of rolling. Generally the number of ways of rolling is based on a product of the choice functions $$\binom{l_i}{p_i}$$ where $l_i$ is the number of parts total less the parts already placed, $p_i$ is the number of parts of that size.

By hand calculation, there are 492 ways to partition 10 using parts of sizes 1 through 6 (hey, we saw that number already! we must be on the right track). For a maximum part size, there are:

  1. 1 way;
  2. 88 ways;
  3. 185 ways;
  4. 127 ways;
  5. 63 ways; and
  6. 28 ways

to obtain a score of 10.

$\endgroup$
7
  • $\begingroup$ Some good observations, but I don't think the ratio of wins to losses in only dependent on the final throw - it also need to take into account the different possibilities of getting to the number that the final step starts from $\endgroup$
    – Joffan
    Jul 1, 2016 at 7:15
  • $\begingroup$ @Joffan Has this come closer to what you expect/want? $\endgroup$
    – Nij
    Jul 1, 2016 at 8:58
  • $\begingroup$ Dividing the number of ways to reach $10$ by the number of ways to reach $10$ to $15$ doesn't yield a probability because these ways are not equiprobable. Only results with the same number of rolls are equiprobable. $\endgroup$
    – joriki
    Jul 1, 2016 at 11:31
  • 1
    $\begingroup$ No. It doesn't matter what score you associate with the rolls. You're free to extend all the sequences by scores of zero to make them ten rolls long; but then you'd still have to count all those ways of extending them by zeros, and in the end you'd have to divide by $6^{10}=60466176$, not by $2501$. The probability of an event defined by a finite number of rolls in a game with a fair six-sided die can only have factors of $6$ in the denominator; $2501$ has prime factors other than $2$ or $3$. If this is still not clear, perhaps consider the target $2$ with $1$ or $2$ rolls to simplify. $\endgroup$
    – joriki
    Jul 1, 2016 at 15:30
  • 1
    $\begingroup$ @Joffan: This is because this calculation "rewards" the medium numbers $3$ and $4$ because they allow for more different combinations, but fails to "punish" them for requiring more rolls, which correspond to missing factors of $\frac16$ each. $\endgroup$
    – joriki
    Jul 1, 2016 at 15:52

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .