F Things You (Probably) Didn’t Know About Hexadecimal

Hexadecimal, or base 16,1 has been used as a computer language for decades. But much that has been written about the development of the term hexadecimal and the associated number system itself is incorrect. In this short article, we delve into the history of the term, the number system, and its notation in order to offer a more complete (and accurate!) story of hexadecimal and to dispel some of the myths that have emerged along the way. So here are F, or fifteen, things you (probably) didn’t know about hexadecimal:

Inspiration for the choice by the National Bureau of Standards of A-F as the six extra digits may have come from Joseph Bowden's Special Topics in Theoretical Arithmetic (1936), in which he suggested that [5, p. 50]4 [i]f we wish to employ a base larger than ten, we may instead of using new symbols, use letters for the extra digits. Thus with 2 5 for base we may count as follows: 1By "base 16" we mean the positional number system using 16 as its base. We thus exclude the practice of dividing whole quantities into sixteen fractional parts without position. Such practices are recorded, for example, in Tamil literature and ancient Rome. On these, see [19] and [23, p. 336]. 2The Merriam-Webster dictionary likewise gives 1954 as the year hexadecimal was first used, presumably for the same reason. 3The agency's name was changed to the National Institute of Standards and Technology in 1988. 4Note the omission of I, J, and O from the alphabetical sequence. 5In 1903, Bowden [4, p. 26] cited page 9 from Pierce's book, on which sexidenal features prominently. Unfortunately, in doing so, Bowden perpetuated Pierce's error: The i in sexidenal is an interfix, i.e., a short sound (usually a vowel), having no meaning, inserted between word parts in a compound word to aid pronunciation. Graeco-Latin borrowings abound in interfixes, but there are some words, sex ("six") being one of them, that properly compound without an interfix. English doesn't really have interfixes, but it has somewhat similar phenomena, such as a becoming an before a vowel and the way that some people pronounce drawing as if it were spelt drawring. 1, 2, 3, 4, 5, 6, 7, 8, 9, A, B, C, D, E, F, G, H, K, L, M, N, P, Q, R, S, T, U, V, W, X, Y, 10.
Bowden also considered the merits of base 16, which he referred to as sexidenal, a term he appears to have drawn from Robert Morris Pierce, who used it in 1898.5 For the six extra digits of his sexidenal system, Pierce [17, p. 9] chose the lowercase Latin letters a, b, c, d, e, f. With the aim of providing information that could support an attempt to switch public use away from the decimal system, he showed how standard arithmetic operations worked in bases 8, 10, 12, and 16.

4
In The Art of Computer Programming, Donald Knuth [8, p. 202] notes that today's prevalent term for base 16, hexadecimal, is "a mixture of Greek and Latin stems,"6 namely the Greek ἕξ (héx, "six") and the Latin decem ("ten"). That's like hybridizing English and German roots to make sixzehn or sechsteen. Of course, the result may still be understood, and some hybrids (such as television) have become ubiquitous, but Greek and Latin roots are generally best kept separate, since combining their vocabularies increases the prevalence of homographs (i.e., unrelated words with the same spelling), which makes it that much harder to work out what a coinage means; for example, it is only by assuming their separation that you can be assured that pedology is the study (λόγος · lógos) of soil (πέδον · pédon), not feet (pedes).

5
Knuth [8, p. 202] also claims that "more proper terms would be 'senidenary' or 'sedecimal' or even 'sexadecimal.'" However, Knuth is mistaken about the aptness of sexadecimal, which is in fact a corruption of the correct term sexdecimal. That spurious a probably derives from the misdivision of sexagesimal (a term used to refer to base 60; literally "relating to sixty") as sexa-gesimal. 7 The corrupted term sexadecimal first appeared in 1895 in William Dwight Whitney's The Century Dictionary [24, p. 5535].8 Unfortunately, the corruption has by now taken root: in a book on the etymology of mathematical terms, Schwartzman [18, pp. 5, 105] wrongly takes sexadecimal to be an etymologically correct alternative for hexadecimal.

6
According to Knuth [8,p. 201], the first person to use base 16 was the Swedish-American engineer John William Nystrom (1825Nystrom ( -1885. This is incorrect, as we shall see. But Nystrom was at least a very vocal proponent of base 16, which he outlined in great detail in a book published in 1862 and in a series of articles published a year later.9 He proposed replacing the familiar decimal system with a base-16 system he called tonal. The name has nothing to do with music; rather, in Nystrom's system the number 10 (that is, 16 in decimal) is arbitrarily named ton. In fact, Nystrom [14, pp. 16-17] coined new names for all numbers expressed in his tonal system; for example, 0 is noll, 9 is ko, 100 is san, 1,000 is mill, 1,000,000 is sanbong, etc. For tonal notation, he suggested [14, p. 15] the following symbols: 10 Nystrom was so enamored of his tonal system that he not only suggested new units of weights and measures but also devised a clock dial that divided the day into sixteen hours. He even proposed dividing the year into 16 months of approximately 23 days apiece, each month having its own novel name (Anuary, Debrian, and Timander were the first three).11 Aside from the number 16 allowing for more convenient binary divisions (i.e., divisions by 2) than the number 10, Nystrom [14, p. 23] also favored base 16 over base 10 because the former requires "a less number of figures in expressing a high number." 7 However, in 1867, W. B. Taylor, of the United States Patent Office, reviewed Nystrom's proposal and reached the conclusion that base 16 was not significantly more economical than base 10, as Nystrom had claimed. Taylor [22, p. 120] demonstrated that when it came to expressing very large numbers, such as "the number of grains of sand required to constitute a globe as large as our earth," around 659 quintillion,12 the senidenary system (Taylor's preferred term for base 16) was scarcely more convenient than the decimal, for whereas decimal would require 33 digits to express such a large number, the senidenary would still require 28: "a reduction quite insignificant," in Taylor's opinion. Having won no support for his tonal system, Nystrom later abandoned his efforts to promote it, instead recommending public adoption of the duodenal (i.e., duodecimal, or base-12) system [16, pp. 307-331].

8
Nystrom did not claim base 16 as his own invention. He wrote that King Charles XII of Sweden (1682-1718) had considered introducing the base-16 system in Sweden, but his objection to the consequent requirement for new symbols for the extra digits led him to prefer the octal (base-8) system instead [15, pp. 263-264]. However, Nystrom provided no evidence for his assertion, and it is undermined by an eyewitness account by Emanuel Swedenborg (1668-1772) that describes Charles XII's interest in octal and even base 64, but not base 16 [21]. 7In the originating Latin sexagesimus ("sixtieth"), -agesimus is the "-tieth" part; accordingly, a Latin sexadecim is like an English sixtiteen. 8The entry's etymology notes that the word is "Prop. *sexdecimal," the asterisk indicating that the form is unattested (to that lexicographer's incomplete knowledge). 9Nystrom [14, p. 3]   Nystrom was at least correct about his not being the inventor of base 16, even if he wasn't right about who had got there before him. Almost two decades earlier, in 1845, the English schoolmaster and mathematician Thomas Wright Hill (1763-1851) proposed a base-16 numeration system in a paper read at a meeting of the British Association for the Advancement of Science in Cambridge, England. The paper was posthumously published as "A system of numerical nomenclature and notation, grounded on the principles of abstract utility" [7, pp. 63-85]. Hill referred to his base-16 system as sexdecimal. The Latin word for sixteen is sedecim (which gives English sedecimal), but it can also be spelled sexdecim, so Hill's choice of term is etymologically sound.
A Hill [7, p. 69] drew his inspiration from the divergent use of the term stone in the county of Yorkshire, England, to refer to a weight of 16 pounds, rather than to one of 14 pounds, as elsewhere in Britain. Hill noted that the Yorkshire practice allowed for more convenient bisections, which suggested that benefits could be reaped by adopting base 16 more broadly. Rather than identify sixteen distinct digits for his sexdecimal notation, Hill [7, p. 78] came up with nine elements that could be combined to form any positive or negative value in sexdecimal: From these elements, Hill generated distinctive names for all positive and negative sexdecimal values; for example, dĭn = +1, dĭkōn = +16 (because the ĭ, or 1, is in the 16's place, with the k before the ō acting as a place separator), dĭdōkōn = +256 (because the ĭ, or 1, is in the 256's place, with the d and k before each ō acting as place separators), kĭn = −1, kĭkōn = −16, etc., where ō can be preceded by either d or k, depending on one's preference for pronunciation, since 0 is unaffected by + or −.

B
Hill [7, p. 74] believed that the sexdecimal system was not one that had theretofore found any supporters, stating, "This number [i.e., 16] has not hitherto been publicly recommended, as far as my knowledge extends." Hill was right that sexdecimal had not been publicly recommended before, but that does not mean he was the first to conceive it. In fact, base 16 was invented in the seventeenth century by the polymath Gottfried Wilhelm Leibniz (1646-1716), who is well known for a number of other mathematical innovations, such as the calculus and the binary system. Initially, Leibniz's term for base 16 was sedecimal. In his first writing on base 16, Leibniz [9] worked out how to convert the decimal number 1679, representing the year of his invention, into sedecimal numeration.

C
Leibniz experimented with different forms of notation for sedecimal. In his first writing on the subject [9], he used the Roman letters m, n, p, q, r, and s for the six extra digits, before abandoning them in favor of the six Aretinian syllables ut, re, mi, fa, sol, and la,13 abbreviated by Leibniz to u, r, m, f, s, and ℓ. By combining these syllables with the German words for numbers, he created an entirely new set of terms for values expressed in sedecimal. For example, utzehn, a combination of the syllable ut, standing for ten, and the German word zehn, which traditionally meant ten, but was repurposed by Leibniz to stand for sixteen, was Leibniz's term for the decimal number 26 expressed in sedecimal (1u, in Leibniz's notation).

D
Leibniz [10] also experimented with different forms of notation for base 16. In another early writing, in which he termed the number system sedenary,14 he stacked dots and dashes, using a dot for each 0 bit and a dash for each 1 bit, with the most significant bit at the top and the least significant bit at the bottom: 13These evolved into the sol-fa, which Julie Andrews recites in the song "Do-Re-Mi" in The Sound of Music. 14In the course of reading this brief article, you could not have failed to notice the peculiar profusion of names for base 16. We have cited eight, and it is likely that other forms have also seen use. We have already given reasons why hexadecimal, sexadecimal, and sexidenal are objectionable, while tonal is entirely idiosyncratic. But what about the other four -sedecimal, sexdecimal, sedenary, and senidenary? Is each as good as the others? Or is there some reasoned basis on which one may be preferred? Sedecimal and sexdecimal each derives from one of two spellings of the Latin word for the cardinal numeral sixteen, with the English suffix -al added to form an adjective; they are equally valid, but the forms without x are more common, both in English and in Latin. Sedenary and senidenary ultimately derive, respectively, from sedeni and senideni, both Latin distributive numerals whose meaning would most naturally be expressed in English by a phrase such as "sixteen at a time" or "in sixteens." Of those two classes of adjectives, those derived from distributive numerals are preferable to those derived from cardinal numerals because the distributives' sense better fits a system in which the quantity expressed by each successive position increases by the multiple of the base (in this case, by 16 at a time), and also because those adjectives intermediately derive from preformed Latin adjectives, which end in -arius (in this case, sedenarius and senidenarius). Finally, there's not much to choose between the equally irreproachable sedenary and senidenary; it is only worth noting that senideni preexisted sedeni.
Leibniz's dot-and-dash notation is reminiscent of that used in the ancient Mayan (base-20, or vicenary) number system, which aside from a special "shell" character for zero, uses only two symbols, a dot (for 1) and a bar (for 5), with stacks of dots and bars used to form numbers up to 19 and a vertical positional system to represent even higher numbers [3, p. 764]. However, there is no evidence that Leibniz had any knowledge of the Maya, so the similarity is surely a coincidence.

E
In 1682 or thereabouts, Leibniz [11] sketched out another form of sedenary notation on the back of an envelope. This time he starts with a concave-up semicircle to denote 0 and a concave-down semicircle to denote 1, and he then modifies these characters to create the remaining digits: Inferring from his descriptions (or instructions), Leibniz based each digit on Roman letters, either single or joinedup, with some of them being "bicaudate," that is, extended by a tail (cauda in Latin) on either side, and others "antecaudate," that is, extended by a tail on the left-hand side alone.

F
In what was probably his last writing on base-16 numeration, Leibniz [12] drew a table featuring the decimal numbers 0 to 40 represented in every base from 2 to 16. In this table, Leibniz used the lowercase Latin letters a, b, c, d, e, and f for the six extra digits of his sedenary character set, the first and only time he did so. This anticipated rather than influenced the modern convention of using A, B, C, D, E, and F for the six extra digits, since Leibniz's writings on sedenary are only now starting to be published [20].