## Sunday, December 4, 2016

### Dice Notation

What our group sees as the essentials of dice notation.

Here are examples of dice notation: d4, d6, d8, d10, d12, and d20.

The notation refers to a die, but more often a roll of a die. The rules might say that a weapon causes d8 of damage, which is equivalent to saying it does 1–8 hit points of damage.

The notation has been extended in a couple of ways: 3d6 means to roll three 6-sided dice and sum them, generating a number in the range 3–18. 1d4+1 means to roll one 4-sided die and add one to it, generating a number in the range 2–5.

## The Introduction of Dice Notation

The notation isn't used in the original box set or the Monster Manual.

The Players Handbook (June 1978) was the first TSR publication to use it. Jon Peterson suggests the PHB was written as if players were already familiar with the notation, but the occurrences I've found are used in a parenthetical manner. For example, consider this spell description:
A fireball is an explosive burst of flame, which detonates with a low roar, and delivers damage proportionate to the level of the magic-user who cast it, i.e. 1 six-sided die (d6) for each level of experience of the spell caster. Exception: Magic fireball wands deliver 6 die fireballs (6d6), magic staves with this capability deliver 8 die fireballs, and scroll spells of this type deliver a fireball of from 5 to 10 dice (d6 + 4) of damage.
The November 1978 printing of the Holmes rulebook appends the following text:
In some places the reader will note an abbreviated notation for the type of die has been used. The first number is the number of dice used, the letter "d" appears, and the last number is the type of dice used. Thus, "2d4" would mean that two 4-sided dice would be thrown (or one 4-sided would be thrown twice); "3d12" would indicate that three 12-sided dice are used, and so on.
The blurb suggests that dice notation is used elsewhere in the Holmes rulebook, but it isn't!

The Dungeon Masters Guide (August 1979) also explains the notation:
Before any further discussion takes place, let us define the accepted abbreviations for the various dice. A die is symbolized by "d", and its number of sides is shown immediately thereafter. A six-sided die is therefore "d6", d8 is an eight-sided die, and so on. Two four-sided dice are expressed by 2d4, five eight-side dice are 5d8, etc. Any additions to or subtractions from the die or dice are expressed after the identification, thus: d8 + 8 means a linear number grouping between 9 and 16, while 3d6 - 2 means a bell-shaped progression from 1 to 16, with the greatest probability group in the middle (8, 9). This latter progression has the same median numbers as 2d6, but it has higher and lower ends and a greater probability of a median number than if 2d12 were used. When percentage dice are to be used, this is indicated by d%.
As Jon Peterson has discussed, essentially the same notation, albeit with a capital D, was being used in the fanzines for several years before TSR embraced it. It appears, amazingly, in the first issue of Alarums & Excursions from 1975.

## The Old Notation Isn't Good Enough

Looking through the older texts, you can see a couple of different ways for specifying dice rolls: "5 + 1", "3-8 sided", and "2–24".

This notation is inferior in various ways. The first doesn't make clear which die to use: a 5d6+1 roll is intended. Of course, ambiguity can sometimes be advantageous. The way hit dice are specified in the Monster Manual might have made the book more appealing to players still using d6 hit dice for monsters.

The third example, range notation, looks like a concise way to specify rolls, but it also can be ambiguous. For example, 3–12 can be either d10+2 or 3d4. The first method is uniform, whereas the second starts to approximate a bell curve.  If you roll it the first way, the chance of getting a 3 is 10%; if you roll it the second way the chance of getting a 3 is 1 in 64 or about 1.6%.

3–12 is the smallest range which can be ambiguous, and it is used in the PHB! A bardiche inflicts 3–12 hit points of damage on large opponents.

## The New Notation Isn't Good Enough

On p. 10 the DMG explains dice notation and on the following page it describes a method for rolling attribute scores which can't be expressed with that dice notation: rolling 4d6 and dropping the lowest die!

The site roll20.net has some notation for this. The roll can be written as 4d6d1 to indicate the lowest die is dropped, or 4d6k3 to indicate the highest three dice are kept.

There is alternate notation which make it explicit that the lowest die is dropped: 4d6dl1 and the highest three dice are kept: 4d6kh3.  One could call for the highest die to be dropped: 4d6dh1 or the lowest three dice are kept: 4d6kl3.

The lowercase L seems like an opportunity for confusion with a numeral one, so we just use 4d6kh3 for a 3d6 with negative skew and 4d6dh1 for a 3d6 with positive skew.

## Code

We don't like laptops, ipads, or even phones at the table. Nevertheless it was convenient to implement a command line tool which understands dice notation—including the "keep high" and "drop high" extensions:

$roll 6d6 16$ for i in \$(seq 1 6); do roll 4d6kh3; done
14
8
7
14
15
10


The code is on GitHub.

## Factor Rolls

One can use the dice to generate other ranges of integers:

1–2  ⌈d6/3⌉
1–3  ⌈d6/2⌉
1–5  ⌈d20/4⌉
1–10 ⌈d20/2⌉


In case the notation on the right is not clear, one rolls the indicated die, divides by the following number, and then rounds up. The most practical notation is d2, d3, d5, d10. I'm not aware of a standard term for this type of roll; we've been calling them factor rolls.

## Product Rolls

Percentile dice are an example of what we've been calling a product roll. We could use two d6 to create a d36, for example. This is not multiplication, but more like working with base 6 numbers. The percentile dice make the process easier by using zeros and distinguishing the tens die from the ones die. One formula for getting a range 1–36 is

6×(d6 - 1) + d6

Dice of different colors are needed for a product roll. Our convention is to use a white die for the ones die. If dice of different colors are not available, a single roll is not possible; roll the most significant die first.

The dice do not have to have the same number of faces. If you wanted the use the 30 sided dice gaming tables published by the armory, you could generate d30 rolls with a d6 and a d10.

If factor rolls and product rolls are allowed, then the only numbers we cannot generate are ones containing a prime larger than 5 as a factor.

## Re-rolling

Thus there is no way to generate d7 uniformly using a single roll. One could roll a d8 and re-roll if the result is 8.  Simply writing d7 is the best notation.

Seven sided dice have been manufactured. One design is a pentagonal prism, and another "is based on spacing points as equally as possible on a sphere and then cutting planar slices perpendicular to those directions."  It would be interesting to test these dice and see whether the distribution is uniform.