# Hill verses Hamming

It’s easy to imagine the 19th century Philadelphia wool dealer Frank J. Primrose as a happy man. I envision him shearing sheep during the day, while in the evening he brings his wife flowers and plays games with his little children until bedtime. However, in 1887 Frank J. Primrose was not a happy man. This is because in June of that year, he had telegraphed his agent in Kansas instructions to buy a certain amount of wool. However, the telegraph operator made a single mistake in transmitting his message and Primrose unintentionally bought far more wool than he could possibly sell. Ordinarily, such a small error has little consequence, because errors can often be detected from the context of the message. However, this was an unusual case and the mistake cost him about a half-million dollars in today’s money. He promptly sued and his case eventually made its way to the Supreme Court. The famous 1894 United States Supreme Court case Primrose v. Western Union Telegraph Company decided that the telegraph company was not liable for the error in transmission of a message.

Thus was born the need for error-correcting codes.

## Introduction

Lester Hill is most famously known for the Hill cipher, frequently taught in linear algebra courses today. We describe this cryptosystem in more detail in one of the sections below, but here is the rough idea. In this system, developed and published in the 1920’s, we take a $k\times k$ matrix K, composed of integers between 0 and 25, and encipher plaintext p by $p\longmapsto c=Kp$, where the arithmetical operations are performed mod 26. Here K is the key, which should be known only to the sender and the intended receiver, and c is the ciphertext transmitted to the receiver.

On the other hand, Richard Hamming is known for the Hamming codes, also frequently taught in a linear algebra course. This will be describes in more detail in one of the sections below, be here is the basic idea. In this scheme, developed in the 1940’s, we take a $k\times k$ matrix G over a finite field F, constructed in a very particular way, and encode a message m by $m\longmapsto c=mG$, where the arithmetical operations are performed in F. The matrix G is called the generator matrix and c is the codeword transmitted to the receiver.

Here, in a nutshell, is the mystery at the heart of this post.

These schemes of Hill and Hamming, while algebraically very similar, have quite different aims. One is intended for secure communication, the other for reliable communication. However, in an unpublished paper [H5], Hill developed a hybrid encryption/error-detection scheme, what we shall call “Hill codes” (described in more detail below).

Why wasn’t Hill’s result published and therefore Hill, more than Hamming, known as a pioneer of error-correcting codes?

Perhaps Hill himself hinted at the answer. In an overly optimistic statement, Hill wrote (italics mine):

Further problems connected with checking operations in finite fields will be treated in another paper. Machines may be devised to render almost quite automatic the evaluation of checking elements $c_1,\dots,c_q$ according to any proposed reference matrix of the general type described in Section 7, whatever the finite field in which the operations are effected. Such machines would enable us to dispense entirely with tables of any sort, and checks could be determined with great speed. But before checking machines could be seriously planned, the following problem — which is one, incidentally, of considerable interest from the standpoint of pure number theory — would require solution.

– Lester Hill, [H5]

By my interpretation, this suggests Hill wanted to answer the question below before moving on. As simple looking as it is, this problem is still, as far as I know, unsolved at the time of this writing.

Question 1 (Hill’s Problem):
Given k and q, find the largest r such that there exists a $k\times r$ van der Monde matrix with the property that every square submatrix is non-singular.

Indeed, this is closely related to the following related question from MacWilliams-Sloane [MS77], also still unsolved at this time. (Since Cauchy matrices do give a large family of matrices with the desired property, I’m guessing Hill was not aware of them.)

Question 2: Research Problem (11.1d)
Given k and q, find the largest r such that there exists a $k\times r$ matrix having entries in GF(q) with the property that every square submatrix is non-singular.

In this post, after brief biographies, an even more brief description of the Hill cipher and Hamming codes is given, with examples. Finally, we reference previous blog posts where the above-mentioned unpublished paper, in which Hill discovered error-correcting codes, is discussed in more detail.

## Short biographies

Who is Hill? Recent short biographies have been published by C. Christensen and his co-authors. Modified slightly from [C14] and [CJT12] is the following information.

Lester Sanders Hill was born on January 19, 1890 in New York. He graduated from Columbia University in 1911 with a B. A. in Mathematics and earned his Master’s Degree in 1913. He taught mathematics for a few years at Montana University, then at Princeton University. He served in the United States Navy Reserves during World War I. After the WWI, he taught at the University of Maine and then at Yale, from which he earned his Ph.D. in mathematics in 1926. His Ph.D. advisor is not definitely known at this writing but I think a reasonable guess is Wallace Alvin Wilson.

In 1927, he accepted a position with the faculty of Hunter College in New York City, and he remained there, with one exception, until his resignation in 1960 due to illness. The one exception was for teaching at the G.I. University in Biarritz in 1946, during which time he may have been reactivated as a Naval Reserves officer. Hill died January 9, 1961.

Thanks to an interview that David Kahn had with Hill’s widow reported in [C14], we know that Hill loved to read detective stories, to tell jokes and, while not shy, enjoyed small gatherings as opposed to large parties.

Who is Hamming? His life is much better known and details can be readily found in several sources.

Richard Wesley Hamming was born on February 11, 1915, in Chicago. Hamming earned a B.S. in mathematics from the University of Chicago in 1937, a masters from the University of Nebraska in 1939, and a PhD in mathematics (with a thesis on differential equations)
from the University of Illinois at Urbana-Champaign in 1942. In April 1945 he joined the Manhattan Project at the Los Alamos Laboratory, then left to join the Bell Telephone Laboratories in 1946. In 1976, he retired from Bell Labs and moved to the Naval Postgraduate School in Monterey, California, where he worked as an Adjunct Professor
and senior lecturer in computer science until his death on January 7, 1998.

## Hill’s cipher

The Hill cipher is a polygraphic cipher invented by Lester S. Hill in 1920’s. Hill and his colleague Wisner from Hunter College filed a patent for a telegraphic device encryption and error-detection device which was roughly based on ideas arising from the Hill cipher. It appears nothing concrete became of their efforts to market the device to the military, banks or the telegraph company (see Christensen, Joyner and Torres [CJT12] for more details). Incidently, Standage’s excellent book [St98] tells the amusing story of the telegraph company’s failed attempt to add a relatively simplistic error-detection to telegraph codes during that time period.

Some books state that the Hill cipher never saw any practical use in the real world. However, research by historians F. L. Bauer and David Kahn uncovered the fact that the Hill cipher saw some use during World War II encrypting three-letter groups of radio call signs [C14]. Perhaps insignificant, at least compared to the practical value of Hamming codes, none-the-less, it was a real-world use.

The following discussion assumes an elementary knowledge of matrices. First, each letter is first encoded as a number, namely

$A \leftrightarrow 0, B \leftrightarrow 1, \dots, Z \leftrightarrow 25$. The subset of the integers $\{0, 1, \dots , 25\}$ will be denoted by Z/26Z. This is closed under addition and multiplication (mod 26), and sums and products (mod 26) satisfy the usual associative and distributive properties. For R = Z/26Z, let GL(k,R) denote the set of invertible matrix transformations $T:R^k\to R^k$ (that is, one-to-one and onto linear functions).

## The construction

Suppose your message m consists of n capital letters, with no spaces. This may be regarded an n-tuple M with elements in R = Z/26Z. Identify the message M as a sequence of column vectors ${\bf p}\in R^k$. A key in the Hill cipher is a $k\times k$ matrix K, all of whose entries are in R, such that the matrix K is invertible. It is important to keep K and k secret.

The encryption is performed by computing ${\bf c} = K{\bf p},$ and rewriting the resulting vector as a string over the same alphabet. Decryption is performed similarly by computing ${\bf p} = K^{-1} {\bf c}.$.

Example 1: Suppose m is the message “BWGN”. Transcoding into numbers, the plaintext is rewritten $p_0=1, p_1=22, p_2=6, p_3=13$. Suppose the key is
$K=\left(\begin{array}{rr} 1 & 3 \\ 5 & 12 \end{array}\right).$
Using Hill’s encryption above gives $c_0=7,c_1=3,c_2=24,c_3=3$. (Verification is left to the reader as an exercise.)

Security concerns: For example, this cipher is linear and can be broken by a known plaintext attack.

Hamming codes

Richard Hamming is a pioneer of coding theory, introducing the binary
Hamming codes in the late 1940’s. In the days when an computer error could crash the computer and force the programmer to retype his punch cards, Hamming, out of frustration, designed a system whereby the computer could automatically correct certain errors. The family of codes named after him can easily correct one error.

## Hill’s unpublished paper

While he was a student at Yale, Hill published three papers in Telegraph and Telephone Age [H1], [H2], [H3]. In these papers Hill described a mathematical method for checking the accuracy of telegraph communications. There is some overlap with these papers and [H5], so it seems likely to me that Hill’s unpublished paper [H5] dates from this time (that is, during his later years at Yale or early years at Hunter).

In [H5], Hill describes a family of linear block codes over a finite field and an algorithm for error-detection (which can be easily extended to error-correction). In it, he states the construction of what I’ll call the “Hill codes,” (defined below), gives numerous computational examples, and concludes by recording Hill’s Problem (stated above as Question 1). It is quite possibly Hill’s best work.

Here is how Hill describes his set-up.

Our problem is to provide convenient and practical accuracy checks upon
a sequence of n elements $f_1, f_2, \dots, f_r$ in a finite algebraic
field F. We send, in place of the simple sequence $f_1, f_2, \dots, f_r$, the amplified sequence $f_1, f_2, \dots, f_r, c_1, c_2, \dots, c_k$
consisting of the “operand” sequence and the “checking” sequence.

– Lester Hill, [H5]

Then Hill continues as follows. Let F=GF(p) denote the finite field having p elements, where $p>2$ is a prime number. The checking sequence contains k elements of F as follows:
$c_j = \sum_{i=1}^r a_{i}^jf_i,$
for $j = 1, 2, \dots, k$. The checks are to be determined by means of a
fixed matrix
$A = \left( \begin{array}{cccc} a_{1} & a_{2} & \dots & a_{r} \\ a_{1}^2 & a_{2}^2 & \dots & a_{r}^2 \\ \vdots & & & \vdots \\ a_{1}^k & a_{2}^k & \dots & a_{r}^k \\ \end{array} \right)$
of elements of F, the matrix having been constructed according to the criteria in Hill’s Problem above. In other words, if the operand sequence (i.e., the message) is the vector ${\bf f} = (f_1, f_2, \dots, f_r)$, then the amplified sequence (or codeword in the Hill code) to be transmitted is

${\bf c} = {\bf f}G,$
where $G = \left( I_r, A \right)$ and where $I_r$ denotes the
$r\times r$ identity matrix. The Hill code is the row space of G.

We conclude with one more open question.

Question 3:
What is the minimum distance of a Hill code?

The minimum distance of any Hamming code is 3.

Do all sufficiently long Hill codes have minimum distance greater than 3?

## Summary

Most books today (for example, the excellent MAA publication written by Thompson [T83]) date the origins of the theory of error-correcting codes to the late 1940s, due to Richard Hamming. However, this paper argues that the actual birth is in the 1920s due to Lester Hill. Topics discussed include why Hill’s discoveries weren’t publicly known until relatively recently, what Hill actually did that trumps Hamming, and some open (mathematical) questions connected with Hill’s work.

For more details, see these previous blog posts.

Acknowledgements: Many thanks to Chris Christensen and Alexander Barg for
helpful and encouraging conversations. I’d like to explicitly credit Chris Christensen, as well as historian David Kahn, for the original discoveries of the source material.

## Bibliography

[C14] C. Christensen, Lester Hill revisited, Cryptologia 38(2014)293-332.

[CJT12] ——, D. Joyner and J. Torres, Lester Hill’s error-detecting codes, Cryptologia 36(2012)88-103.

[H1] L. Hill, A novel checking method for telegraphic sequences, Telegraph and
Telephone Age (October 1, 1926), 456 – 460.

[H2] ——, The role of prime numbers in the checking of telegraphic communications, I, Telegraph and Telephone Age (April 1, 1927), 151 – 154.

[H3] ——, The role of prime numbers in the checking of telegraphic
communications, II, Telegraph and Telephone Age (July, 16, 1927), 323 – 324.

[H4] ——, Lester S. Hill to Lloyd B. Wilson, November 21, 1925. Letter.

[H5] ——, Checking the accuracy of transmittal of telegraphic communications by means of operations in finite algebraic fields, undated and unpublished notes, 40 pages.
(hill-error-checking-notes-unpublished)

[MS77] F. MacWilliams and N. Sloane, The Theory of Error-Correcting Codes, North-Holland, 1977.

[Sh] A. Shokrollahi, On cyclic MDS codes, in Coding Theory and Cryptography: From Enigma and Geheimschreiber to Quantum Theory, (ed. D. Joyner), Springer-Verlag, 2000.

[St98] T. Standage, The Victorian Internet, Walker & Company, 1998.

[T83] T. Thompson, From Error-Correcting Codes Through Sphere Packings to Simple Groups, Mathematical Association of America, 1983.

# Lester Hill’s “The checking of the accuracy …” – finally completed

I’ve finally finished LaTeXing Lester Hill’s manuscript. You can download the pdf here: hill-error-checking-notes-unpublished. Just ask if you want a copy of the latex source.

This post is to simply state Hill’s conclusion. It gives a clue as to why the paper was never published. If I had to guess, I’d say it was because he could not solve the problem he stated in that section.

As far as I know it is still unsolved.

Here is Hill’s Conclusion section:

Further problems connected with checking operations in finite fields will be treated in another paper. Machines may be devised to render almost quite automatic the evaluation of checking elements $c_1,c_2,\dots,c_q$ according to any proposed reference matrix of the general type described in Section 7, whatever the finite field in which the operations are effected. Such machines would enable us to dispense entirely with tables of any sort, and checks could be determined with great speed. But before checking machines could be seriously planned, the following problem — which is one, incidentally, of considerable interest from the standpoint of pure number theory — would require solution:

To construct, for a given finite field $F$ with $\Gamma$ elements, and for the checking therein of $n$-element sequence $f_1,f_2,\dots,f_n$, a reference matrix

$\left( \begin{array}{cccc} a_1 & a_2 & \dots & a_{n} \\ a_1^2 & a_2^2 & \dots & a_{n}^2 \\ \vdots & & & \vdots \\ a_1^q & a_2^q & \dots & a_{n}^q \\ \end{array} \right)$

without a vanishing determinant of any order, in which the integer $q$ is the greatest possible. Corresponding to any $F$, and any $n$ — provided that $n$ is less than $\Gamma$ — there is a definite maximum $q$. This maximum should be ascertained, and the reference matrix therefore constructed.

We are not able to communicate a solution of this general problem.

(signed) Lester S. Hill

# Lester Hill’s “The checking of the accuracy …”, part 14

Backstory: Lester Saunders Hill wrote unpublished notes, about 40 pages long, probably in the mid- to late 1920s. They were titled “The checking of the accuracy of transmittal of telegraphic communications by means of operations in finite algebraic fields”. In the 1960s this manuscript was given to David Kahn by Hill’s widow. The notes were typewritten, but mathematical symbols, tables, insertions, and some footnotes were often handwritten. I thank Chris Christensen, the National Cryptologic Museum, and NSA’s David Kahn Collection, for their help in obtaining these notes. Many thanks also to Rene Stein of the NSA Cryptologic Museum library and David Kahn for permission to publish this transcription. Comments by transcriber will look like this: [This is a comment. – wdj]. I used Sage (www.sagemath.org) to generate the tables in LaTeX.

Here is just the 15th section of his paper. I hope to post more later. (Part 14 is here.)

Lemma concerning reference matrices

The general reference matrix of Section 3 was:

$Q = \left( \begin{array}{cccc} k_{11} & k_{12} & \dots & k_{1n} \\ k_{21} & k_{22} & \dots & k_{2n} \\ \vdots & & & \vdots \\ k_{q1} & k_{q2} & \dots & k_{qn} \\ \end{array} \right)$
the $k_{ij}$ being elements of any given finite algebraic field $F$, and $q$ being less than or equal to $n$.

This matrix contains determinants of order $r$ with $r=1,2,\dots, q$ — determinants of first order ($r=1$) being single elements of the matrix.

We recall that if $f_1$, $f_2, \dots, f_{s}$ is an $s$ element operand
sequence in $F$, a $t$-element check based upon the matrix $Q$ is:

$c_j = \sum_{i=1}^{s} k_{ji} f_i,\ \ \ \ \ \ \ (j = 1, 2, \dots, t).$
it being understood that $s\leq n$, $t\leq q$.

Let $Q$ contain no vanishing determinant of any order: Let $c_1$, $c_2, \dots, c_{t}$ be a $t$-element check, $t\leq q$, on the operand sequence $f_1$, $f_2$, \dots, $f_{s}$, $s\leq n$. Let $v$ be a positive integer less than or equal to $s+t$. If, in the transmittal of the sequence

$f_1, f_2, \dots, f_{s}, c_1, c_2, \dots, c_{t},$
errors occur in $v$ of its $s+t$ elements, whatever the distribution of the errors, the presence of error will certainly be disclosed, or will enjoy only a $1$-in-$(\Gamma-1)^t$ chance of escaping disclosure, according as $v$ is, or is not, less than $t+1$. In this statement, $\Gamma$ denotes the total number of elements in the field $F$.

proof:
Case 1:
Let all $v$ errors fall among the $c_1, c_2, \dots, c_{t}$. The presence of error is evidently certain to be disclosed.

Case 2:
Let all $v$ errors fall among the $f_1, f_2, \dots, f_{s}$.

(2.1): Let $v\leq t$. There is no loss of generality of we assume [This assumption implies $v\leq s$. – wdj] the $v$ errors are $\epsilon_1$, $\epsilon_2, \dots, \epsilon_v$, affecting $f_1, f_2, \dots, f_{v}$. The errors cannot escape disclosure. For, to do so, they would have to satisfy the system of homogeneous linear equations:

$\sum_{i=1}^{v} k_{ji} \epsilon_i,\ \ \ \ \ \ \ (j = 1, 2, \dots, t).$
in which the matrix of coefficients $k_{ji}$ contains no vanishing determinant of any order, and which, therefore admits no solution other than $\epsilon_i=0$ ($i = 1, 2, \dots, v$).

For this treatment of the errors, compare Sections 4, 5.

Case 3:
Let $z$ errors fall among the $f_i$ and $w=v-z$ errors fall among the $c_j$. Without loss in generality, we may assume that the errors are $\epsilon_1$, $\epsilon_2, \dots, \epsilon_z$, affecting $f_1, f_2, \dots, f_{z}$, and $\delta_{j_1}$, $\delta_{j_2}, \dots, \delta_{j_w}$, affecting $c_{j_1}$, $c_{j_2}, \dots, c_{j_w}$.

(3.1): Let $z+w\leq t$. Writing $t=v+h=z+w+h$, where $h$ denotes a non-negative integer which may or may not be zero, we have $t-w = z+h$. Hence $z+h$ of the $c_j$ are transmitted without error.

If the presence of error is to escape disclosure, we see, therefore, that the $z$ errors $\epsilon_i$ must satisfy the system of at least $z$ homogeneous linear equations:

$\sum_{i=1}^{z} k_{r_m,i} \epsilon_i,\ \ \ \ \ \ \ (m = 1, 2, \dots, z+h),$
where the indices $r_m$ denote a set of $z+h$ integers selected from $1, 2, \dots, t$. But the matrix of coefficients in this system contains no vanishing determinant, so that the only solution would be $\epsilon_i=0$ ($i = 1, 2, \dots, z$).

For details in this treatment of errors, see Section \ref{sec:5}.

(3.2): Let $z+w> t$. Then $w = t-(z-h)$, where $h$ denotes a positive integer. Assuming that the presence of error is to escape detection, we see, therefore, that the $v$ errors must satisfy $t$ linear equations as follows:

($\alpha$) a system of $z-h$ equations involving only the errors $\epsilon_i$, ($i = 1, 2, \dots, z$), and homogeneous in these $z$ errors;

($\beta$) a system of $w$ equations involving all $v$ errors.

Since the matrix of the coefficients in the system ($\alpha$) contains no vanishing determinant, we can solve this system for $z-h$ of the $\epsilon_i$ as rational functions of the remaining $h$ of the $\epsilon_i$.

The system ($\beta$) determines all errors affecting the $c_j$ — that is, all the errors $\delta_{j_i}$ — as polynomial functions of the $\epsilon_i$, ($i = 1, 2, \dots, z$).

Hence, all told, $(z-h)+w$ errors are determined as rational functions of the remaining $h$ errors. In other words, $v-t$ errors determine the other $t$ errors.

An accidental error can assume any one of $\Gamma -1$ values, there being $\Gamma$ elements in the finite field $F$. Hence the chance that the errors will check up, and thus escape disclosure, is only $1$-in-$(\Gamma-1)^t$.
QED

# Lester Hill’s “The checking of the accuracy …”, part 13

Backstory: Lester Saunders Hill wrote unpublished notes, about 40 pages long, probably in the mid- to late 1920s. They were titled “The checking of the accuracy of transmittal of telegraphic communications by means of operations in finite algebraic fields”. In the 1960s this manuscript was given to David Kahn by Hill’s widow. The notes were typewritten, but mathematical symbols, tables, insertions, and some footnotes were often handwritten. I thank Chris Christensen, the National Cryptologic Museum, and NSA’s David Kahn Collection, for their help in obtaining these notes. Many thanks also to Rene Stein of the NSA Cryptologic Museum library and David Kahn for permission to publish this transcription. Comments by transcriber will look like this: [This is a comment. – wdj]. I used Sage (www.sagemath.org) to generate the tables in LaTeX.

Here is just the 14th section of his paper. I hope to post more later. (Part 13 is here.)

Illustration of checking in the field $F_{101}$

We wish to provide checks upon arbitrary sequences $f_1$, $f_2$, …, $f_n$ of elements of any given finite algebraic field. Operations in the field $F_{101}$ can be used to illustrate all the essential points arising in this connection.

Example 1: Check of Type A upon a sequence $f_1$, $f_2$, …, $f_{10}$. Suppose that we wish, in a certain message, to transmit the numerical sequence

$38460000600800000299.$
The origin and significance of this sequence in the following form, in which it appears as a sequence of ten elements of $F_{101}$:

$\begin{array}{cccccccccc} 38 & 46 & 00 & 00 & 60 & 08 & 00 & 00 & 02 & 99\\ f_1 & f_2 & f_3 & f_4 & f_5 & f_6 & f_7 & f_8 & f_9 & f_{10}\\ \end{array}$
A five-element check ($q=5$) is obtained by the simple tabulation which follows. We use Table 4, noting that in each of the nine rows, the one-hundred columns are shown in four sections, there being twenty-five columns in each section.

For the first element, 38, in the operand sequence $f_i$, place ruler under the proper section of row 1 of the Table. In row 1, read: 13 in column 38, 39 in column 13, 16 in column 39, 48 in column 16, 43 in column 48. Start a tabulation:

$13\quad 39\quad 16 \quad 48 \quad 43.$
For the second element, 46, in the operand sequence, place ruler under the proper section of row 2 of the Table. In row 2, read: 83 in column 46, 29 in column 83, 15 in column 29, 60 in column 15, 38 in column 60. Continue the tabulation:

$13\quad 39\quad 16 \quad 48 \quad 43\\ 83\quad 29\quad 15 \quad 60 \quad 38$
Since the third and fourth elements of the operand sequence are equal to zero, skip them entirely. For the fifth element, 60, read in row 5 of the Table: 76 in column 60, 2 in column 76, 16 in column 2, 27 in column 16, 14 in column 27. Continue the tabulation:

$13\quad 39\quad 16 \quad 48 \quad 43\\ 83\quad 29\quad 15 \quad 60 \quad 38\\ 76\quad 2\quad 16 \quad 27 \quad 14$

Proceed in this manner to the ninth element, 2, inclusive of the operand sequence. There being no tenth row in the Table, simply add the tenth element, 99, of the operand sequence in each vertical column of the tabulation. The full tabulation is:

$\begin{array}{rrrrrl} 13 & 39 & 16 & 48 & 43 & \\ 83 & 29 & 15 & 60 & 38 & \\ 76 & 2 & 16 & 27 & 14 & \\ 99 & 51 & 63 & 60 & 86 & \\ 84 & 94 & 9 & 75 & 19 & \\ \hline 454 & 314 & 218 & 369 & 299 & sum\ in\ ZZ\\ 50 & 11 & 16 & 66 & 97 & sum\ in\ F_{101}\\ \end{array}$
The five-element check is therefore:

$c_1 = 50, c_2 = 11, c_3 = 16, c_4 = 66, c_5 = 97.$
We transmit telegraphically the sequence of fifteen elements of $F_{101}$:

$38 \quad 46\quad 00\quad 00 \quad 60\quad 08 \quad 00 \quad 00\quad 02\quad 99\quad 50 \quad 11\quad 16 \quad 66 \quad 97.$
A discussion of possible errors will be given in another section. we simply note here that the $c_j$’s, as determined in the above tabulation, are:

$c_1 = \sum_{i=1}^{10} a_i f_i,\quad c_2 = \sum_{i=1}^{10} a_i^2 f_i,\quad \dots, c_5 = \sum_{i=1}^{10} a_i^5 f_i.$
If only a one-element check had been desired, we should have taken $c_1=50$, and a one-column tabulation would have sufficed. If a two-element check had been desired, we should have taken $c_1=50$, $c_2=11$ and a two-column tabulation would have sufficed. Etc.

If the operand sequence $f_i$ contains less than $10$ elements, the procedure, to determine check of Type A, is obvious. A $q$-element check upon $f_1$, $f_2$, \dots, $f_{n}$, with $n<10$, is as stated:

$c_j = \sum_{i=1}^{10} a_i^j f_i,\ \ \ \ \ \ \ j = 1, 2, \dots, q,$
with $q=1,2,3,4,5$. The manner of its evaluation, by means of Table 4, is clear.

Example 2: Check of Type B upon a sequence $f_1$, $f_2$, … , $f_{8}$.

Suppose that we desire a five-element check upon the numerical sequence $6500000000001794$ – that is, upon

$\begin{array}{cccccccc} 65 & 00 & 00 & 00 & 00 & 00 & 17 & 94\\ f_1 & f_2 & f_3 & f_4 & f_5 & f_6 & f_7 & f_8 \\ \end{array}$
We wish to evaluate $c_j = \sum_{i=1}^{8} b_i^j f_i,\ \ \ \ \ \ \ (j = 1, 2, \dots, 5)$. The tabulation is as follows:

$\begin{array}{rrrrrl} 94 & 80 & 38 & 13 & 39 & row\ 1,\ Table\ 4,\ read:\ 94\ in\ column\ 65,\ etc. \\ 90 & 19 & 59 & 45 & 60 &row\ 7,\ read:\ 90\ in\ column\ 17,\ etc. \\ 94 & 94 & 94 & 94 & 94 & \\ \hline 278 & 193 & 191 & 152 & 193 & sum\ in\ ZZ\\ 76 & 92 & 90 & 51 & 92 & sum\ in\ F_{101}\\ c_1 & c_2 & c_3 & c_4 & c_5 & \\ \end{array}$

Example 3: Check of Type A upon the same operand sequence as in Example 2.

We wish to evaluate $c_j = \sum_{i=1}^{8} a_i^j f_i,\ \ \ \ \ \ \ (j = 1, 2, \dots, 5)$. The tabulation is as follows:

$\begin{array}{rrrrrl} 94 & 80 & 38 & 13 & 39 & \\ 90 & 19 & 59 & 45 & 60 & \\ 97 & 41 & 9 & 34 & 5 &row\ 8,\ Table\ 4,\ read:\ 97\ in\ col.\ 94,\ etc. \\ \hline 281 & 140 & 106 & 92 & 104 & sum\ in\ ZZ\\ 79 & 39 & 5 & 92 & 3 & sum\ in\ F_{101}\\ c_1 & c_2 & c_3 & c_4 & c_5 & \\ \end{array}$

Example 4: Check of Type A and B upon the operand sequence

$\begin{array}{ccccccc} 00 & 65 & 00 & 00 & 00 & 17 & 94\\ f_1 & f_2 & f_3 & f_4 & f_5 & f_6 & f_7 \\ \end{array}$
We wish to evaluate

$c_j = \sum_{i=1}^{7} a_i^j f_i= \sum_{i=1}^{7} b_i^j f_i,\ \ \ \ \ \ \ (j = 1, 2, \dots, 5).$
The tabulation is as follows:

$\begin{array}{rrrrrl} 58 & 30 & 19 & 76 & 1 & row\ 2,\ Table\ 4,\ read:\ 58\ in\ col.\ 65,\ etc. \\ 21 & 20 & 96 & 77 & 6 &row\ 6,\ read:\ 21\ in\ col.\ 17,\ etc. \\ 58 & 10 & 47 & 29 & 5 &row\ 7,\ read:\ 58\ in\ col.\ 94,\ etc. \\ \hline 137 & 60 & 162 & 182 & 12 & sum\ in\ ZZ\\ 36 & 60 & 61 & 81 & 12 & sum\ in\ F_{101}\\ c_1 & c_2 & c_3 & c_4 & c_5 & \\ \end{array}$

Questions of rigor will be discussed in a subsequent section. It may be noted here, however, that our checks make very
nice discriminations. Thus, although the operand sequence in Examples 3 and 4 are closely similar, the checking sequences are widely different.

It will now be apparent to those who are acquainted with the problems of code communication that we are in a position to furnish powerful and economical checks on message sequences in any conceivable telegraphic system. We have only to partition messages into groups of not more than ten, or not more that eight, elements each — according to any
definite prearrangement — and to check each group with a $q$-check, $q=1,2,3,4,5$ (as may be arranged), of Type A or of Type B. If it is desired to work with longer groups, we have only to enlarge Table 4. The limitations introduced in this paper may be largely overcome, or removed, by suitable amplification of the Table employed.

# Lester Hill’s “The checking of the accuracy …”, part 12

Backstory: Lester Saunders Hill wrote unpublished notes, about 40 pages long, probably in the mid- to late 1920s. They were titled “The checking of the accuracy of transmittal of telegraphic communications by means of operations in finite algebraic fields”. In the 1960s this manuscript was given to David Kahn by Hill’s widow. The notes were typewritten, but mathematical symbols, tables, insertions, and some footnotes were often handwritten. I thank Chris Christensen, the National Cryptologic Museum, and NSA’s David Kahn Collection, for their help in obtaining these notes. Many thanks also to Rene Stein of the NSA Cryptologic Museum library and David Kahn for permission to publish this transcription. Comments by transcriber will look like this: [This is a comment. – wdj]. I used Sage (www.sagemath.org) to generate the tables in LaTeX.

Here is just the 13th section of his paper. I hope to post more later. (Part 12 is here.)

Reference matrices and table

We now turn our attention to the construction of reference matrices for checking in the field $F_{101}$. Our object is merely to give an account of problems arising. Hence the purposes of this paper will be served if we choose small illustrative matrices.

With

$a_1 = 3, \ a_2 = 4, \ a_3 = 5, \ a_4 = 6, \ a_5 = 8, \ a_6 = 25, \ a_7 = 35, \ a_8 = 15, \ a_9 = 42, \ a_{10} = 1,$

consider the reference matrix:

$A = \left( \begin{array}{cccc} a_1 & a_2 & \dots & a_{10} \\ a_1^2 & a_2^2 & \dots & a_{10}^2 \\ \vdots & & & \vdots \\ a_1^5 & a_2^5 & \dots & a_{10}^5 \\ \end{array} \right) = \left(\begin{array}{rrrrrrrrrr} 3 & 4 & 5 & 6 & 8 & 25 & 35 & 15 & 42 & 1 \\ 9 & 16 & 25 & 36 & 64 & 19 & 13 & 23 & 47 & 1 \\ 27 & 64 & 24 & 14 & 7 & 71 & 51 & 42 & 55 & 1 \\ 81 & 54 & 19 & 84 & 56 & 58 & 68 & 24 & 88 & 1 \\ 41 & 14 & 95 & 100 & 44 & 36 & 57 & 57 & 60 & 1 \end{array}\right) .$

A $q$-element check, $q\leq 5$, on the sequence $f_1, f_2, \dots, f_n$ of $n$ elements in $F_{101}$, $n\leq 10$, is given by

$c_j = \sum_{i=1}^n a_i^j f_i,\ \ \ \ \ (j=1,2,\dots, q).$
This check, being based upon the matrix $A$, will be called a check of “type $A$”.

With

$b_1 = 3, \ b_2 = 4, \ b_3 = 5, \ b_4 = 6, \ b_5 = 8, \ b_6 = 25, \ b_7 = 35, \ b_8 = 1, \$
consider the matrix:

$B = \left( \begin{array}{cccc} b_1 & b_2 & \dots & b_{8} \\ b_1^2 & b_2^2 & \dots & b_{8}^2 \\ \vdots & & & \vdots \\ b_1^5 & b_2^5 & \dots & b_{8}^5 \\ \end{array} \right) = \left(\begin{array}{rrrrrrrrrr} 3 & 4 & 5 & 6 & 8 & 25 & 35 & 1 \\ 9 & 16 & 25 & 36 & 64 & 19 & 13 & 1 \\ 27 & 64 & 24 & 14 & 7 & 71 & 51 & 1 \\ 81 & 54 & 19 & 84 & 56 & 58 & 68 & 1 \\ 41 & 14 & 95 & 100 & 44 & 36 & 57 & 1 \end{array}\right)$
which is evidently a submatrix of $latex A$. We can obtain a $latex q$-element check, $latex q\leq 5$, on the sequence $latex f_1, f_2, \dots, f_n$, $latex n\leq 8$, taking

$c_j = \sum_{i=1}^n b_i^j f_i,\ \ \ \ \ (j=1,2,\dots, q).$
This check will be called a check of “type $latex B$”, since it is based upon the matrix $latex B$.

Table 4 below enables us to evaluate easily the checks of types A and B. Table 4 contains nine rows of one hundred columns each. [Note: I have omitted all but the first $14$ columns, for brevity. – wdj.] The $i$th row shows the products of all non-zero elements of $F_{101}$ by $a_i$ ($i=1,2,\dots, 9$), where the $a_i$‘s are given above.

$\begin{array}{r|rrrrrrrrrrrrrrrrrrrrrrrr} & 1 & 2 & 3 & 4 & 5 & 6 & 7 & 8 & 9 & 10 & 11 & 12 & 13 & 14 \\ \hline 1 & 3 & 6 & 9 & 12 & 15 & 18 & 21 & 24 & 27 & 30 & 33 & 36 & 39 & 42 \\ 2 & 4 & 8 & 12 & 16 & 20 & 24 & 28 & 32 & 36 & 40 & 44 & 48 & 52 & 56 \\ 3 & 5 & 10 & 15 & 20 & 25 & 30 & 35 & 40 & 45 & 50 & 55 & 60 & 65 & 70 \\ 4 & 6 & 12 & 18 & 24 & 30 & 36 & 42 & 48 & 54 & 60 & 66 & 72 & 78 & 84 \\ 5 & 8 & 16 & 24 & 32 & 40 & 48 & 56 & 64 & 72 & 80 & 88 & 96 & 3 & 11 \\ 6 & 25 & 50 & 75 & 100 & 24 & 49 & 74 & 99 & 23 & 48 & 73 & 98 & 22 & 47 \\ 7 & 35 & 70 & 4 & 39 & 74 & 8 & 43 & 78 & 12 & 47 & 82 & 16 & 51 & 86 \\ 8 & 15 & 30 & 45 & 60 & 75 & 90 & 4 & 19 & 34 & 49 & 64 & 79 & 94 & 8 \\ 9 & 42 & 84 & 25 & 67 & 8 & 50 & 92 & 33 & 75 & 16 & 58 & 100 & 41 & 83 \\ \end{array}$
Caption: A table of products with the $a_i$‘s.

Table 4 can be replaced by a highly convenient mechanical device, which greatly facilitates the rapid determination of the $c_j$‘s. But we are here only concerned with the mathematical description of checking operations, and not with devices to affect their practical application.

# A curious conjecture about self-reciprocal polynomials

Let $p$ be a polynomial
$p(z) = a_0 + a_1z+\dots + a_nz^n\ \ \ \ \ \ a_i\in {\bf C},$
and let $p^*$ denote the reciprocal polynomial
$p^*(z) = a_n + a_{n-1}z+\dots + a_0z^n=z^np(1/z).$
We say $p$ is self-reciprocal if $p=p^*$. For example,
$1+2z+3z^2+2z^3+z^4$
and
$1+2z+3z^2+3z^3+2z^4+z^5$
are self-reciprocal. Suppose
$p(z) = a_0 + a_1z+\dots + a_dz^d+a_{d+1}z^{d+1}+a_dz^{d}+\dots +a_{1}z^{2d+1}+a_0z^{2d+2},\ \ \ \ \ \ a_i\in {\bf C},$
or
$p(z) = a_0 + a_1z+\dots + a_dz^d+a_{d+1}z^{d+1}+a_{d+1}z^{d+2}+a_dz^{d+3}+\dots +a_{1}z^{2d+2}+a_0z^{2d+3},\ \ \ \ \ \ a_i\in {\bf C},$

The question is this: for which increasing sequences $a_0 do the polynomial roots $p(z)=0$ lie on the unit circle $|z|=1$?

Some examples:

This represents, when $d=1$ and $a_0=1$ and $a_1=1.1$ the largest $a_{d+1}$ which has this roots property is as in the plot.

This represents, when $d=1$ and $a_0=1$ and $a_1=1.2$ the largest $a_{d+1}$ which has this roots property is as in the plot.

This represents, when $d=1$ and $a_0=1$ and $a_1=1.3$ the largest $a_{d+1}$ which has this roots property is as in the plot.

This represents, when $d=1$ and $a_0=1$ and $a_1=1.4$ the largest $a_{d+1}$ which has this roots property is as in the plot.

This represents, when $d=1$ and $a_0=1$ and $a_1=1.5$ the largest $a_{d+1}$ which has this roots property is as in the plot.

Conjecture 1: Let $s:{\bf Z}_{>0}\to {\bf R}_{>0}$ be a ”slowly increasing” function.

1. Odd degree case.
If $g(z)= a_0 + a_1z + \dots + a_dz^d$, where $a_i=s(i)$, then the roots of $p(z)=g(z)+z^{d+1}g^*(z)$ all lie on the unit circle.
2. Even degree case.
The roots of
$p(z)=a_0 + a_1z + \dots + a_{d-1}z^{d-1} + a_{d}z^{d} + a_{d-1}z^{d+1} + \dots + a_{1}z^{2d-1}+a_0z^{2d}$
all lie on the unit circle.

The next conjecture gives an idea as to how fast a “slowly increasing” function can grow.

Conjecture 2:* Consider the even degree case only. The polynomial
$p(z)=a_0 + a_1z + \dots + a_{d-1}z^{d-1} + a_{d}z^{d} + a_{d-1}z^{d+1} + \dots + a_{1}z^{2d-1}+a_0z^{2d}$,
with $a_0=1$ and all $a_i>0$, is symmetric increasing if and only if it can be written as a product of quadratics of the form $x^2-2\cos(\theta)x+1$, where all but one of the factors satisfy $2\pi/4\leq \theta\leq 4\pi/3$. One of the factors can be of the form $x^2+\alpha x+1$, for some $\alpha \geq 0$.

* It was pointed out to me by Els Withers that this conjecture is false.

# Lester Hill’s “The checking of the accuracy …”, part 11

The field $F_{101}$

All essential points connected with the checking of telegraphic sequences by the methods proposed in this paper may be fully illustrated in one finite field. For our purposes, perhaps the most useful field is $F_{101}$, to which we shall confine our attention in the following sections. The elements of the field $F_{101}$ are the one hundred and one marks\footnote{Hill actually uses the symbol $X$ in place of $100$.} $0$, $1$, $2$, $\dots$, $100$. The operations of addition and multiplication are effected as explained in a previous example; and are abbreviated as suggested. To determine sums and products, we regard the marks of the field momentarily as integers of elementary arithmetic. Thus we have

$\sum_1^n f_i = f_h,\ \ \ \ \ \ (\prod_1^n f_i = f_k),$

the $f_i$ being $n$ marks of $F_{101}$, distinct or not, if, when the $f_i$ are momentarily regarded as integers of elementary arithmetic, the congruence

$\sum_1^n f_i \equiv f_h \pmod{101},\ \ \ \ \ \ (\prod_1^n f_i \equiv f_k \pmod{101}),$

holds. It will not be possible to provide a full multiplication table for the field $F_{101}$. But the following special table will be found convenient.

$\begin{array}{r|rrr} x & x^2 & 1/x & -x\\ 1 & 1 & 1 & 100 \\ 2 & 4 & 51 & 99 \\ 3 & 9 & 34 & 98 \\ 4 & 16 & 76 & 97 \\ 5 & 25 & 81 & 96 \\ 6 & 36 & 17 & 95 \\ 7 & 49 & 29 & 94 \\ 8 & 64 & 38 & 93 \\ 9 & 81 & 45 & 92 \\ 10 & 100 & 91 & 91 \\ 11 & 20 & 46 & 90 \\ 12 & 43 & 59 & 89 \\ 13 & 68 & 70 & 88 \\ 14 & 95 & 65 & 87 \\ 15 & 23 & 27 & 86 \\ 16 & 54 & 19 & 85 \\ 17 & 87 & 6 & 84 \\ 18 & 21 & 73 & 83 \\ 19 & 58 & 16 & 82 \\ 20 & 97 & 96 & 81 \\ 21 & 37 & 77 & 80 \\ 22 & 80 & 23 & 79 \\ 23 & 24 & 22 & 78 \\ 24 & 71 & 80 & 77 \\ 25 & 19 & 97 & 76 \\ 26 & 70 & 35 & 75 \\ 27 & 22 & 15 & 74 \\ 28 & 77 & 83 & 73 \\ 29 & 33 & 7 & 72 \\ 30 & 92 & 64 & 71 \\ 31 & 52 & 88 & 70 \\ 32 & 14 & 60 & 69 \\ 33 & 79 & 49 & 68 \\ \end{array}$

$\begin{array}{r|rrr} x & x^2 & 1/x & -x\\ 34 & 45 & 3 & 67 \\ 35 & 13 & 26 & 66 \\ 36 & 84 & 87 & 65 \\ 37 & 56 & 71 & 64 \\ 38 & 30 & 8 & 63 \\ 39 & 6 & 57 & 62 \\ 40 & 85 & 48 & 61 \\ 41 & 65 & 69 & 60 \\ 42 & 47 & 89 & 59 \\ 43 & 31 & 47 & 58 \\ 44 & 17 & 62 & 57 \\ 45 & 5 & 9 & 56 \\ 46 & 96 & 11 & 55 \\ 47 & 88 & 43 & 54 \\ 48 & 82 & 40 & 53 \\ 49 & 78 & 33 & 52 \\ 50 & 76 & 99 & 51 \\ 51 & 76 & 2 & 50 \\ 52 & 78 & 68 & 49 \\ 53 & 82 & 61 & 48 \\ 54 & 88 & 58 & 47 \\ 55 & 96 & 90 & 46 \\ 56 & 5 & 92 & 45 \\ 57 & 17 & 39 & 44 \\ 58 & 31 & 54 & 43 \\ 59 & 47 & 12 & 42 \\ 60 & 65 & 32 & 41 \\ 61 & 85 & 53 & 40 \\ 62 & 6 & 44 & 39 \\ 63 & 30 & 93 & 38 \\ 64 & 56 & 30 & 37 \\ 65 & 84 & 14 & 36 \\ 66 & 13 & 75 & 35 \\ \end{array}$

$\begin{array}{r|rrr} x & x^2 & 1/x & -x\\ 67 & 45 & 98 & 34 \\ 68 & 79 & 52 & 33 \\ 69 & 14 & 41 & 32 \\ 70 & 52 & 13 & 31 \\ 71 & 92 & 37 & 30 \\ 72 & 33 & 94 & 29 \\ 73 & 77 & 18 & 28 \\ 74 & 22 & 86 & 27 \\ 75 & 70 & 66 & 26 \\ 76 & 19 & 4 & 25 \\ 77 & 71 & 21 & 24 \\ 78 & 24 & 79 & 23 \\ 79 & 80 & 78 & 22 \\ 80 & 37 & 24 & 21 \\ 81 & 97 & 5 & 20 \\ 82 & 58 & 85 & 19 \\ 83 & 21 & 28 & 18 \\ 84 & 87 & 95 & 17 \\ 85 & 54 & 82 & 16 \\ 86 & 23 & 74 & 15 \\ 87 & 95 & 36 & 14 \\ 88 & 68 & 31 & 13 \\ 89 & 43 & 42 & 12 \\ 90 & 20 & 55 & 11 \\ 91 & 100 & 10 & 10 \\ 92 & 81 & 56 & 9 \\ 93 & 64 & 63 & 8 \\ 94 & 49 & 72 & 7 \\ 95 & 36 & 84 & 6 \\ 96 & 25 & 20 & 5 \\ 97 & 16 & 25 & 4 \\ 98 & 9 & 67 & 3 \\ 99 & 4 & 50 & 2 \\ 100 & 1 & 100 & 1 \end{array}$

Squares, reciprocals, negatives

Using the scheme of reciprocals shown in this Table, we may easily perform an rational operations in $F_{101}$.

Example:

Suppose, for example, that we wish to solve the system of equations:

$36x-79y=52,\ \ \ 90x+85y = 98.$

They may be written

$x-79y/36 = 13/9,\ \ \ \ x+17y/18 = 49/45$

and the fractions are quickly evaluated. Thus: $-79/36 = 96$. Determining the fractions in this manner, we write the two equations in the form:

$x+96y=80,\ \ \ \ x+29y=37,$

whence $y=73$ and $x=41$

The modulus $101$ is very convenient to work with. The residue, modulo $101$, of any integer is immediately obvious, at sight of the integer, and is therefore obtained without computation.