Rolling with Advantage and Disadvantage
Rolling with Advantage and Disadvantage
How does probability change when you roll with advantage (or disadvantage)?
Disadvantage
When you roll with disadvantage, you roll two dice, usually d20s, and take the lower number. Say you need to roll a \(20\). If you roll with disadvantage, the only way to achieve that \(20\) is for both dice to roll a \(20\). Let’s say our two dice consist of a red die and a blue die. We will let
- \(A\): roll a \(20\) on the blue die.
- \(B\): roll a \(20\) on the red die.
To get my \(20\) with disadvantage, I need \(A\) and \(B\) to occur at the same time.
Let’s take a step back for a moment and think about rolling two d4s. What is the probability that both dice roll a \(4\)? (For a visual of all possible rolls, see A Gentle Introduction to Probability Using Dice) From the table, we can see that there are (4 sides \(\times\) 4 sides) 16 possible combinations of rolls and 1 of them satisfy our condition: (4,4). Then \[P(\text{roll 4 on red AND roll 4 on blue}) = \frac{1 \text{ way}}{16 \text{ possible combinations of rolls}} = 1/16\] Something else interesting is happening here. Note that \[P(\text{roll a 4}) = \frac{1 \text{ way}}{4 \text{ possible rolls}} = 1/4\] and that \[P(\text{roll 4 on red AND roll 4 on blue}) = 1/16 = (1/4)\times(1/4)\] It turns out this is not a coincidence! Dice rolls are what we call independent, meaning that each time I roll a die, it has no impact on other rolls of that (or any other) die.
Multiplication rule for two independent events. For two independent events, let’s call them \(A\) and \(B\), \[P(A \text{ and } B) = P(A)\times P(B).\]
Now return your attention to rolling a 20 (on a d20) with disadvantage. Recall
- \(A\): roll a \(20\) on the blue die.
- \(B\): roll a \(20\) on the red die.
The two dice roll independently, so \[P(A \text{ and } B) = P(A)\times P(B) = \frac{1}{20}\times \frac{1}{20} = \frac{1}{400} =0.0025\] There is a 0.25% (one quarter of one percent!) chance of rolling two 20s.
In general, an average roll of a d20 is 10.5 (this is the mean and
the median). We can use order statistics to find the average roll with
disadvantage, similar to the approach used in this post)… or
we can simulate it using R
:
nrep <- 10000000
roll.dis <- numeric(length=nrep)
for(i in 1:nrep){
roll.dis[i] <- min(sample(1:20, size=2, replace=TRUE))
}
mean(roll.dis)
We set the number of repetitions (nrep
) to be 10
million. Then, we create a variable to store all 10 million rolls with
disadvantage (roll.dis
). The next line starts a loop that
runs 10 million times - the function sample
represents the
two rolls of the d20 and the min
function takes the smaller
of the two. Finally, we exit the loop and take the average of the 10
million simulated rolls with disadvantage.
Running the simulation, we find that the average roll with disadvantage is 7.18, significantly lower than our usual average of 10.5! Even worse, the median roll with disadvantage is a 6!
Advantage
When you roll with advantage, you roll your two dice - usually d20s - and take the higher number. (You may also roll the same die twice, but this is equivalent to rolling two different dice! We will talk about rolling two dice for the sake of consistency.) Suppose again you need to roll a \(20\). Now, you need the blue die to roll a \(20\) or the red die to roll a \(20\).
Note: In statistics, when we say “or” we are using what is called an inclusive or. This means A or B or both. If I asked “Do you want pizza or tacos?” and you said “Yes”, that would be a perfectly valid response. You’re allowed to want both! Treat yourself!
Consider again rolling two d4s, the first red and the second blue. If I need to get a \(4\) but I have advantage, I will be happy with any combination of rolls that includes a \(4\). (See A Gentle Introduction to Probability Using Dice). There are seven such combinations: \((1, 4)\), \((2, 4)\), \((3, 4)\), \((4, 4)\), \((4, 1)\), \((4, 2)\), and \((4, 1)\) so the probability of getting a 4 on red or a 4 on blue is \[P(\text{roll 4 on red OR roll 4 on blue}) = \frac{7 \text{ ways}}{16 \text{ possible combinations of rolls}} = 7/16.\]
Naturally, we get another trick for this one. The probability of getting a \(4\) on red is \(1/4\), which is the same as the probability of a \(4\) on blue. We might be tempted to try adding these probabilities, but if we do this, we end up double counting the roll \((4,4)\).
Here’s another way to think about this: Consider a standard 52 card deck. Let \(A\) be the event that a card drawn is a diamond and let \(B\) be the event it is a face card. Then \(P(A) = 13/52\) and \(P(B) = 12/52\). If we add these, we double count the Jack of Diamonds, Queen of Diamonds, and King of Diamonds. So we need to account for that: \[\frac{13}{52} + \frac{12}{52} - \frac{3}{52}.\]
For our d4 with advantage, this translates to \[\frac{1}{4} + \frac{1}{4} - \frac{1}{16} = \frac{7}{16}.\] What is this “double counting” we are taking into account? How do we figure this out quickly? It turns out, if we add two probabilities, of say \(A\) and \(B\), we always double count \((A \text{ and } B)\).
Addition rule for two events. For events \(A\) and \(B\), \[P(A \text{ or } B) = P(A) + P(B) - P(A \text{ and } B).\] So let’s return to rolling two d20s with advantage. Again let
- \(A\): roll a \(20\) on the blue die.
- \(B\): roll a \(20\) on the red die.
The probability of getting a 20 with advantage, \(P(\text{roll a } 20 \text{ on blue OR roll a } 20 \text{ on red})\) is \[P(A \text{ or } B) = \frac{1}{20} + \frac{1}{20} - \frac{1}{400} = \frac{39}{400} = 0.0975\] where we found \(P(A \text{ or } B)\) in the subsection on disadvantage. There is a 9.75% chance of rolling a 20 with advantage.
What about an average roll with advantage? This is going to be really similar to how we thought about average rolls with disadvantage:
nrep <- 10000000
roll.adv <- numeric(length=nrep)
for(i in 1:nrep){
roll.adv[i] <- max(sample(1:20, size=2, replace=TRUE))
}
mean(roll.adv)
We set the number of repetitions (nrep
) to be 10
million. Then, we create a variable to store all 10 million rolls with
advantage (roll.adv
). The next line starts a loop that runs
10 million times - the function sample
represents the two
rolls of the d20 and the max
function takes the larger of
the two. Finally, we exit the loop and take the average of the 10
million simulated rolls with advantage.
Running the simulation, we find that the average roll with advantage is 13.83. Our median is is even higher, coming in at 15, significantly better than that 10.5 average we get rolling straight.