I’ve been asked in- and off-blog to compute the probability of getting three-of-a-kind or better when throwing 3, 4, 5, or 6 dice. (That is, I only care about scoring combinations other than singleton 1s and 5s.) This is straightforward, so I just give the answers for anyone interested (after the jump).
1. Three-of-a-kind or better
(The answers for 3, 4, and 5 dice are copied from a recent comment.)
With 3 dice, there are 6 possible three-of-a-kinds out of 216 possible throws. The odds are 35:1 against (2.78%).
With 4 dice, there are 6 possible four-of-a-kinds and (4)(6)(5)=120 possible three-of-a-kinds out of 1296 possible throws. The odds of three-or-more-of-a-kind are 65:7 against (9.72%).
With 5 dice, there are 6 possible five-of-a-kinds, (5)(6)(5)=150 possible four-of-a-kinds, and (10)(6)(5)(5)=1500 possible three-of-a-kinds out of 7776 possible throws. The odds of three-or-more-of-a-kind are 85:23 against (21.30%).
With 6 dice, there are 6 possible six-of-a-kinds, (6)(6)(5)=180 possible five-of-a-kinds, (15)(6)(5)(5)=2250 possible four-of-a-kinds, (20)(6)[(5)(5)(5)-5]=14400 possible three-of-a-kinds, and (15)(20)=300 possible double three-of-a-kinds. We should probably also include the 6!=720 straights and the (20)(90)=1800 possible three-pairs. This is a total of 19656 “good” throws out of a total of 46656. The odds are 125:91 (which lies between 4:3 and 5:4) against (42.13%).
Ultimately I’d like to use these numbers (and the ones from the previous FARKLE post, and a few others that aren’t much harder to generate) to formulate an “optimal strategy” for playing FARKLE. But before we can do that, we have to nail down what it would mean to play a game of chance “well”. (It turns out it’s not so obvious and clear cut as you might think!)
To do this, we’ll need a basic concept from probability and statistics, the expected value or expectation. If we have a universe of possible outcomes, each of which has a certain “value”, then the expected value is a sort of weighted average of these values.
Example 1. I roll a fair, ordinary 6-sided die. This die has six sides, each of which comes up with probability 1/6. The expected number of dots to come up is (1/6)1+(1/6)2+(1/6)3+(1/6)4+(1/6)5+(1/6)6=3.5.
Example 2. I roll a fair, ordinary 6-sided die. This time, if I roll the side with dots, I get points (at whatever game I’m playing). The expected number of points to come up is (1/6)1+(1/6)4+(1/6)9+(1/6)16+(1/6)25+(1/6)36=15.1667.
Example 3. I roll a 6-sided die, but the die is loaded so that the side with six pips comes up half the time, and the other five sides are equally likely. The expected number of dots to come up is (1/10)1+(1/10)2+(1/10)3+(1/10)4+(1/10)5+(1/2)6=4.5.
Simple concept, relatively easy to work with and apply.
Note that the expectation is not necessarily the most likely outcome. So expected value doesn’t mean “value I expect” or “predicted value”. In the case of flipping ten coins, it so happens that the expected number of heads is 5, which is also the most likely number of heads, but this phenomenon is not universal. If you choose a number between 0 and 10 which each outcome equally likely, the exxpected value is 5 even though all the other numbers are just as likely as 5. More drastically, if you roll a fair 6-sided die, then the expected value of the throw is , which is not even possible.
It’s used very frequently in applications, particularly financial applications, because it is very often the most convenient to work with. But, the expectation is not necessarily the only number that matters when evaluating the relative merits of something.
Good ol’ FARKLE provides a good illustration of this phenomenon.
3. Back on task: FARKLE
So where are we on the bigger task of finding an “optimal strategy” for FARKLE?
Well, using the point values of each of the various scoring combinations and the probabilities of each combination occuring with a certain number of dice (many of these numbers have already been given in this blog), it would be pretty straightforward to answer the following.
1) In any situation, what should I do (what to hold/reroll and when to stop) in order to maximize the expected score on a given term.
The only real trick is to think about how to properly value the opportunity to reroll all six dice.
A slightly more sophisticated question, then, is
2) In any situation, what should I do (what to hold/reroll and when to stop) in order to maximize the expected score over a ten-turn period? (In other words, how do I maximize the expected value of my score for FARKLE simple?)
The reason problems 1 and 2 are different is that there is a 500 point penalty for farkling three times in a row. Solving this problem is a bit more tedious but still quite feasible.
It turns out, though, that this probably isn’t what we actually want to know! It’s easy to assume that since a high score is a good thing, maximizing expected score is the goal. But no! If you’re actually playing this game, you’re probably trying to get a score high enough to top the high score list, or beat a particular friend, os something like that. So the problem we actually want to solve is the following.
3) Given a certain target score, in any situation, what should I do (what to hold/reroll and when to stop) in order to maximize the probability that I will get a score higher than my target?
Why isn’t that the same as problem 2? Because if I want 9000 points, then a final score of 8950 is no better that a score of 100 in my eyes. To get a chance at a high score, it may be necessary to make risky choices that will give very low scores if they fail.
This is easiest to see in an example. The all-time high score in my friend group, which I am trying most fervently to beat, is Maura’s unbelievable 13950. Imagine I had a cheat option where I could just score 1350 points for a turn instead of rolling normally. Now, the expected value of a well-played FARKLE turn is far below 1350, so from a problem 1 or 2 point of view, I should always use this option. My average score would be MUCH higher that way. But my chances of beating that elusive 13950 would be zero.
So far we’ve been talking about the solitaire FARKLE variation. What about the classic version, where the goal is to get to 10000 points before your opponent? Can we solve this problem?
4) In any situation, what should I do (what to hold/reroll and when to stop) in order to maximize the probabiity of winning FARKLE original?
To do this and do it rigorously is seems intractable (mathematicians’ jargon for hopelessly hard). What makes it hard is how to factor in information about the opponent’s score. We can probably use this to our advantage, at least in principle (we could take more risks when it is comparatively safer to do so). Much easier, and probably just as useful, is to simplify the problem by ignoring the opponent and just playing to finish as fast as possible.
5) In any situation, what should I do (what to hold/reroll and when to stop) in order to minimize the expected number of turns it will take to get to 10000?
Notice that problem 5 is NOT, in general, equivalent to problem 1! It might seem that trying to get as many points as possible each turn is the same as trying to get to a certain total as fast as possible, but this is not true. Let this serve as a final lesson of how misleading intuition can be. To make this exaggeratedly clear, imagine a variation on FARKLE in which there is the option, instead of taking a normal turn, to take a one in a million chance at getting a trillion points. From an expected-score-per-turn point of view, this is a great option — it yields an expected score of a million points! But from a expected-time-to-finish point of view, it’s terrible; the expected number of times to finish is a thousand turns.