American Mathematical Monthly 128 [128 Issue 2]

515 20 4MB

English Pages [94]

Report DMCA / Copyright

DOWNLOAD FILE

Polecaj historie

American Mathematical Monthly 128 [128 Issue 2]

Citation preview

Delicate Details of Filling Space Sonya Flaten, Paul D. Humke, Emily Olson, and Thong Vo Abstract. The purpose of this article is to take a fresh look at the problem of finding an arithmetic representation of Hilbert’s curve, building on the same initial observations as many have done previously. The approach we take is an iterated function view and this view leads in somewhat distinct directions. This is the first of what will be several papers on the subject and focuses on a basic approach to space-filling curves, but applied specifically to the Hilbert curve.

1. INTRODUCTION AND BRIEF HISTORY. In the late 19th century, the nature of “dimension” was thought to be rather intuitive so that no definition was needed. This changed quite abruptly in 1878 when Georg Cantor crisply proved that any two finite-dimensional manifolds have the same cardinality. In particular, there is a 1-to-1 mapping from the line segment [0, 1] onto the square [0, 1]2 . Shortly thereafter in [4], E. Netto showed there is no continuous bijection from [0, 1] onto the square [0, 1]2 , which calmed the waters a bit. However, in 1890 in [6], G. Peano proved there was a continuous function mapping [0, 1] onto the square, [0, 1]2 . This was followed by a small flock of these “space-filling” curves, each reporting to be simpler or perhaps more illustrative than the others. In his comprehensive book on space filling, [9], Hans Sagan relates this short but illuminating history of space-filling curves. In that book he repeats a paragraph he wrote in 1992, [8], where in reference to a comment by John Olmstad, [5], Sagan writes Apparently, no attempt at an arithmetic-analytic representation of the Hilbert curve has been made during the past 100 years in the belief that such an attempt would be very tedious.

Sagan, though, credits Borel, [1], with a solid first attempt and in both [8, 9] proceeds to make further significant inroads into such an arithmetization himself. Our purpose here is to build on the ideas of Hilbert’s space-filling curve to give a relatively complete arithmetization of that curve and in so doing show how any such space-filling curve can be arithmetically analyzed. 2. THE MEANING OF THE PICTURES. Many, but certainly not all, space-filling curves are presented via a sequence of pictures or diagrams and this is certainly true of the Peano and Hilbert functions; see Figures 1 and 3. Often, adding rigor to the diagrams is accomplished by using the diagrams to create a uniformly convergent sequence of single-variable functions fn : [0, 1] → [0, 1]2 so that the Range(fn ) is1 the nth diagram. Then, uniform convergence is used to show that the limit function, f , is continuous, while knowing that the nth diagram is contained in Range(fn ) is used to show that Range(f ) = [0, 1]2 . This program is fine and works, but is tedious and, without additional assumptions, does not entail a unique limit function. Moreover, this is not the way either Peano or Hilbert viewed things. Peano’s proof was more arithmetic and had its own issues. However, Hilbert’s view was very geometric and much in the style of symbolic dynamics. 1 or

at least contains doi.org/10.1080/00029890.2021.1845541 MSC: Primary 26A03

February 2021]

DETAILS OF FILLING SPACE

99

For Hilbert, the diagrams did not describe a sequence of single-variable functions so much as they directly described a continuous correspondence between subintervals of [0, 1] and contiguous subsquares of [0, 1]2 . The existence of a continuous limit function and a proof that that limit function is onto [0, 1]2 is a direct consequence of that correspondence. Hilbert’s geometric view was analyzed by Rose in the unpublished paper [7]. Specifically, Rose formalizes Hilbert’s ideas and argument by defining two critical terms and then proving a theorem. In the next section, we adopt Rose’s notation and examine the arithmetic generated by this approach as applied to the Hilbert function itself. In so doing, we refer to any horizontal segment in [0, 1]2 of the form  = {(x, m/2n ) : 0 ≤ x ≤ 1, and 0 ≤ m < 2n } to be a horizontal dyadic line segment of level n; vertical dyadic line segments of level n are defined similarly. In general, the term dyadic line segment will mean either horizontal or vertical and of no particular level. A level n dyadic subsquare of [0, 1]2 will mean a square of the form [m/2n , (m + 1)/2n ] × [k/2n , (k + 1)/2n ] where 0 ≤ m, k ≤ 2n − 1 and the term dyadic subsquare is used when referring to the generic case when level is not an issue. 3. SYMBOLIC DYNAMICS. In [7], Rose defines two useful conditions concerning a correspondence between subintervals of [0, 1] and dyadic subsquares of [0, 1]2 and subsequently proves a theorem that is useful for understanding the relationship between the Hilbert curve and other similarly defined curves. Definition (Adjacency condition [7]). Adjacent subintervals correspond to adjacent subsquares (with an edge in common). Definition (Nesting condition [7]). If at the nth partition, the subinterval Ink corresponds to a subsquare Qnk then at the (n + 1)st partition the 4 subintervals of Ink must correspond to the 4 subsquares of Qnk . In either case, adjacent means contiguous or intersecting but not overlapping. These definitions stress a correspondence between the domain and range, and become a key element in understanding the details of how the Hilbert curve behaves. Rose then proves the following theorem that we will make use of in the latter sections of the current article. Theorem 1 ([7, p. 2]). Any correspondence between the subintervals and subsquares that satisfies the adjacency and nesting conditions determines a unique continuous function f that maps I onto Q. The geometry here is quite analogous to Barnsley’s iterated function systems, but as we are primarily concerned with the nature of the function involved (Hilbert’s spacefilling curve) there is a bit more afoot. In the domain, things are simple. At each stage of an induction, we will be left to deal with 4n congruent, nonoverlapping intervals and at the nth stage we simply divide each of these intervals into 4 pieces (congruent and adjacent subintervals) labeling these left to right with the digits 0 to 3. Patterns in the range are determined by the Hilbert diagrams. For the first of these, see the left square in Figure 1. We have labeled the dyadic squares of the first stage (the right-hand picture in Figure 1) at the corners; this labeling is not just convenient, but proves instructive later on. So at the first inductive step of the construction, the labeled domain intervals are matched with the corresponding dyadic squares; see Figure 2. This will entail that the entire interval marked “0” will eventually be mapped to the entire square labeled S0 . 100

c THE MATHEMATICAL ASSOCIATION OF AMERICA 

[Monthly 128

Figure 1. The initial Hilbert diagram and the first numbering.

Translating this information using base 4 in the domain means that any number whose initial base 4 digit is a 0 will be Hilbert mapped to a point in the lower left subsquare of [0, 1]2 and so on. Figure 3 illustrates how to use the first two base 4 digits to narrow down the site of an eventual Hilbert image and includes a labeling of the second level dyadic squares.

Figure 2. Matching intervals to rectangles.

The second stage is pictured in Figure 3 followed by a more conclusive inductive description.

Figure 3. The second Hilbert diagram and numbering.

There are four patterns at play at this second stage and these turn out to be the only patterns used in constructing the Hilbert curve. The original pattern from Figure 1 will February 2021]

DETAILS OF FILLING SPACE

101

Table 1. The replacement patterns.

The square 0 is patterned with 1 is patterned with 2 is patterned with 3 is patterned with

in LD LL LD LD LR

in LL LD LL LL LU

in LR LU LR LR LD

in LU LR LU LU LL

be denoted by LD ; the reflection of LD about its main diagonal is denoted by LL , and about its off-diagonal by LR ; LU denotes LD reflected over both diagonals; see Figure 4. Note that each of these Hilbert patterns begins with a “0” in either the upper right or lower left corner and ends with a “3” labeling a neighboring square.

Figure 4. The four Hilbert patterns.

For notational purposes we let S∅ denote the unit square [0, 1]2 . The first stage of the Hilbert curve construction assigns the LD pattern to S∅ and assigns the digits {0, 1, 2, 3} the dyadic subsquares of level 1. These are then labeled as S0 , S1 , S2 , and S3 according to the LD assignation. The second inductive stage labels the dyadic subsquares of level 2 according to the replacement patterns above. So, for example, square S0 was part of an LD pattern so the dyadic subsquares of it are denoted by S00 , S01 , S02 , and S03 where the relative locations are determined by the LL pattern. Figure 3 illustrated this for all the level 2 dyadic squares. Suppose now that n ≥ 2 and every dyadic square of level n has been assigned a pattern LD , LL , LR , or LU and a subscript a1 a2 . . . an in which ai ∈ {0, 1, 2, 3} for i = 1, 2, . . . , n. Let S be any dyadic square of level n + 1. Then there is a unique dyadic square of level n, Sa1 a2 ...an , that contains S. By hypothesis, S has been assigned one of the four patterns, LD , LL , LR , or LU and this pattern is used to define an+1 and subsequently we write S = Sa1 a2 ...an ,an+1 . Once an+1 is established, the pattern assigned to S can be looked up in the list of replacement patterns, Table 1. Given a finite sequence of base 4 digits, A = a1 a2 . . . an , the subintervals of [0, 1] corresponding to SA is the closed interval of length 1/4n whose initial point is .a1 a2 . . . an and is denoted as IA . A relatively straightforward induction now shows that when ordered lexicographically, the dyadic squares of any given level satisfy the adjacency criterion. The nesting condition is also an easy byproduct of the construction. So at this point, it immediately follows from Theorem 1 that the Hilbert curve is as advertised, a continuous function of one variable that fills space. Moreover, the correspondence created between domain and range gives us the computational machinery to delve more deeply into the nature of the Hilbert curve. Specifically, this correspondence reveals that 1. For each finite base 4 sequence A = (a1 a2 . . . an ), H −1 (SA ) = IA . 102

c THE MATHEMATICAL ASSOCIATION OF AMERICA 

[Monthly 128

2. For each y ∈ [0, 1]2 there is a not necessarily unique sequence of base 4 digits, (a1 a2 . . . ), such that y = Sa1 ∩ Sa1 a2 ∩ · · · ∩ Sa1 a2 ...an ∩ · · · .

(1)

In this case, we say that y is addressed by the sequence (a1 a2 . . . ). 3. For each x ∈ [0, 1], x = .a1 a2 . . . an . . .4 when and only when H (x) = Sa1 ∩ Sa1 a2 ∩ · · · ∩ Sa1 a2 ...an ∩ · · · .

(2)

As base 4 is a natural notation for [0, 1] in this regard, throughout the sequel, all decimals will be assumed to be base 4 unless explicitly stated otherwise. We’ll have a closer look at (2) in the next two sections, but the numerical correspondence in (2) precisely reflects the geometric correspondence Hilbert refers to in his proof [2], and which E. H. Moore exuberantly refers to as “luminous to the geometric imagination” [3, p. 73]. Also see [9]. 4. WHO MAPS WHERE? “Who maps where?” is the question we wish to consider, and it will take up the majority of the following three sections to answer that question completely, though we have a few immediate observations to make. Observation 1 (The four corners). The function H is 1-to-1 at each of the four corners of [0, 1]2 . Moreover, H (0) = (0, 0), H (1/3) = (0, 1), H (2/3) = (1, 1), and H (1) = (1, 0). Proof. The proof is similar for each one of the equalities, so we’ll have a look at H −1 ((1, 1)) as an example. The location, (1, 1) begins in the level 1 dyadic subsquare, S2 , using the original LD pattern, and as such is in an LD pattern at the second stage as well and this continues. That is, (1, 1) = S2 ∩ S22 ∩ S222 ∩ · · · entailing that H (.222 . . .4 ) = (1, 1), and as there is no alternate base 4 representation of 2/3, H is 1-to-1 at that point. Observation 2. The Hilbert curve H is space filling on every subinterval [a, b] ⊂ [0, 1]. Proof. It follows from (1) that for every dyadic interval J ⊂ [0, 1], H (J ) is a dyadic square. This result now follows by noting that every interval is the union of dyadic intervals. Observation 3. If a point y ∈ [0, 1]2 lies on no dyadic line, then there is a unique x ∈ [0, 1] such that H (x) = y. That is, H is 1-to-1 at each range value not residing on a dyadic line. Proof. As with the proof of Observation 1, this follows directly from (1) since it is only on dyadic lines that there is any choice for the digits an . Where there is a choice, however, it is certainly possible for there to be several preimages of a y ∈ [0, 1]2 . It immediately follows from Observation 3 that H fails to be 1-to-1 on a topologically tiny subset of [0, 1] and to explain this we’ll need a definition or two. A set E is nowhere dense if E is dense in no open set and is of the first Baire category if E is

February 2021]

DETAILS OF FILLING SPACE

103

the countable union of nowhere dense sets. Sets that are complements of first category sets are termed residual and in complete metric spaces, for example, first category sets are topologically tiny. Here is the relevant theorem. Theorem 2. The Hilbert curve H is 1-to-1 on a residual subset of [0, 1]. Proof. There are but countably many dyadic line segments (horizontal or vertical) and we can enumerate them as {k : k = 1, 2, . . . }. If E = {x ∈ [0, 1] : H (x) is on no dyadic line segment}, then [0, 1]\E =

∞ 

H −1 (k ) .

(3)

k=1

Since H is space filling on every interval, H −1 (k ) is nowhere dense for every k = 1, 2, . . . . As a side note, since H is continuous and each k is closed, the set E described in Theorem 2 is itself a dense Gδ subset of [0, 1]. In the next section, we’ll delve into the nature of the sets H −1 (k ), the preimages of dyadic lines. 5. INITIAL DELICATE DETAILS. In this section, we take a close look at the preimages of the dyadic line segments, and at this point we already know something about what to expect. Observation 4. If  is a dyadic line segment in [0, 1]2 , then H −1 () is a compact and nowhere dense subset of [0, 1]. There is considerably more structure to these particular preimages than is described in Observation 4, however. In addition to being compact and nowhere dense, these preimages also have the property that they contain no isolated points. That is, the preimages of the dyadic line segments are all general Cantor sets, meaning they are compact, nowhere dense sets with no isolated points. The classic Cantor ternary set C3 can be described by recursively partitioning intervals into three congruent subintervals and deleting the center third. This geometric description leads immediately to the facts that C3 is both nowhere dense and of Lebesgue measure zero. And only a bit more effort yields that the fractal (Hausdorff) dimension of C3 is log 2/ log 3. Moreover, this recursive geometric description of C3 is mirrored by a simple arithmetic description using base 3 notation, C3 = {.d1 d2 . . .3 : dn = 0 or 2 for all n ∈ N}. The goal of Section 5 is to establish analogous descriptions for the sets H −1 () for dyadic line segments  ∈ [0, 1]2 and our findings are summarized in Theorem 3. The remainder of this section is devoted to proving Theorem 3. Theorem 3. If  is a dyadic line segment in [0, 1]2 , then H −1 () can be described by recursively partitioning intervals into four congruent subintervals and deleting two of the four quarters. In particular, H −1 () is nowhere dense and of Lebesgue measure zero. Moreover, the fractal dimension of H −1 () is log 2/ log 4 = 1/2. Although we’ll eventually consider individual dyadic line segments, we find it more useful first to consider the boundaries of individual dyadic subsquares. To that end, let 104

c THE MATHEMATICAL ASSOCIATION OF AMERICA 

[Monthly 128

S denote a fixed dyadic subsquare of level n. Then there is a unique finite sequence a1 a2 . . . an with S = Sa1 a2 ...an and a Hilbert pattern Li , where i = D, L, R, U that has been assigned to S. From within S, each edge (side) of S abuts exactly two dyadic subsquares and we encode an edge with S[0, 1], S[1, 2], S[2, 3], or S[0, 3] according to the pattern S has been assigned; see Figure 5 where S is shown as having been assigned the Hilbert pattern LL .

Figure 5. Labeling edges for an LL dyadic square.

Suppose, for example, that y ∈ S[0, 3]; that is, y is on the S[0, 3] edge of S. Then H −1 (y) intersects each of the following base 4 intervals on [0, 1], [.a1 a2 . . . an 0, .a1 a2 . . . an 1] and [.a1 a2 . . . an 3, .a1 a2 . . . an 3]

(4)

depending on whether y is on the lower or upper half of S[0, 3]. First, suppose y is on the upper half of S[0, 3], entailing that the (n + 1)st digit of y is “3.” The appropriate replacement pattern for the dyadic subsquare of S labeled “3” is LU , determined using Table 1 and illustrated in Figure 6. So the (n + 2)nd digit of y is either 2 or 3.

Figure 6. 3 is followed by 2 or 3, but 0 is followed by 0 or 1.

If, however, y is on the lower half of S[0, 3], then the (n + 1)st digit of y is “0.” Again using Table 1, the replacement pattern for the dyadic subsquare of S labeled “0” is LD , so in this case, the (n + 2)nd digit of y is either 0 or 1 again; see Figure 6. As it turns out, this is not as complicated as it first appears. The edges of any particular square are encoded identically and independently of the pattern of that square. Moreover, any dyadic square S is given via a finite sequence of n base 4 digits, and if February 2021]

DETAILS OF FILLING SPACE

105

y is on the boundary of S then a sequential code for y begins with that same sequence. The next term is determined using the side that contains y, while subsequent terms are determined by selecting from an established pattern of choices. Table 2 contains this recursively used information. Table 2. The replacement patterns.

Edge address [0, 1] [1, 2] [2, 3] [0, 3]

Edge digit choices {0, 1} {1, 2} {2, 3} {0, 3}

Next edge choices {0, 1}(0) = [0, 3] {0, 1}(1) = [0, 1] {1, 2}(1) = [1, 2] {1, 2}(2) = [1, 2] {2, 3}(2) = [2, 3] {2, 3}(3) = [0, 3] {0, 3}(0) = [0, 1] {0, 3}(3) = [2, 3]

Thus the set S[0, 3] consists of all points y ∈ [0, 1]2 with an address that begins with a1 a2 . . . an then continues with either a “0 ”or a “3.” Subsequent digits are recursively allowed via Table 2 and are enumerated as b1 , b2 , . . . . Figure 7 is a binary tree diagram illustrating the possible choices for these bn encoding locations on the left edge of Sa1 a2 ...an . Under the assumption that S is patterned with LL , the Hilbert pattern being used at a given level is also indicated in Figure 7; Table 2 though, is independent of the initial pattern of S.

Figure 7. The binary choice tree for the S[0, 3] edge of a dyadic square.

Theorem 4. If S = Sa1 a2 ...an is a dyadic square in [0, 1]2 , then a point y is on the boundary of S if and only if y has the address code (a1 a2 . . . an b1 b2 . . . ), where the bi are compatible with Table 2. The points on the S[1, 2] edge of a dyadic square are peculiar in that they never first arise in conjunction with another edge type. This is a direct result of the replacement patterns in Table 2, in that if T is a dyadic subsquare of a dyadic square, and an edge of T is contained in S[1, 2], then that edge is T [1, 2]. More is true, however, and that is the essence of the following corollary in which ∂(S) denotes the boundary of S. Corollary 1. Suppose that S = Sa1 a2 ...an is a dyadic square in [0, 1]2 and suppose T = Sa1 a2 ...an b1 b2 ...bk is a dyadic subsquare for which T [1, 2] ⊂ ∂(S). Then T [1, 2] ⊂ S[1, 2]. Proof. If k = 1, then T [1, 2] consists of edge choices {1, 2} and the sole edge address for S that includes that choice is S[1, 2]. The complete result now follows immediately by induction. 106

c THE MATHEMATICAL ASSOCIATION OF AMERICA 

[Monthly 128

Theorem 4 concerns range values of H , but, due to (2), it has a good deal to say about preimages as well. In particular, S = Sa1 a2 ...an is the image of the closed interval J of length 1/4n with a left endpoint of .a1 a2 . . . an . Moreover, J ∩ H −1 (S[0, 3]) = {.a1 a2 . . . an b1 b2 . . . : the bi satisfy Table 2}.

(5)

It follows from Theorem 5 that J ∩ H −1 (S[0, 3]) is described by recursively partitioning intervals into four congruent subintervals and, according to the rules in Table 2, deleting two of them. The description in (5) is the base 4 arithmetic for such a geometric description; see Figure 8 which illustrates the first three stages of the general Cantor set preimage of the set S[0, 3] of Figures 5–7. This interval J can also be thought of as the closure of H −1 (int(S)) where int(S) denotes the interior of S. Notation becomes complicated at the boundary; indeed, that is the point.

Figure 8. The interval J contains the general Cantor set H −1 (S[0, 3]).

The preimages of the other edges of S are similarly defined, but due to the recurring nature of {1, 2} in the second line of Table 2, the one that most resembles the classic Cantor ternary set is J ∩ H −1 (S[1, 2]) = {.a1 a2 . . . an b1 b2 · · · : bi = 1 or 2 for every i}. The basic geometric nature of such general Cantor sets is well established; all are nowhere dense, all are of measure zero. Moreover, the Hausdorff dimension of each can be computed using so-called box counting and is 1/2. Each of these observations follows directly from the fact that to compute the bi at any stage i > n one has exactly two choices out of four and these correspond to choosing exactly two of the primary base 4 digits at that stage. All of this is codified in Theorem 5. Theorem 5. Suppose S = Sa1 a2 ...an is a dyadic square in [0, 1]2 , J is the interval of length 1/4n whose initial point is .a1 a2 . . . an , and E is any of the four edges of S. Then C = J ∩ H −1 (E) is a general Cantor set of Hausdorff dimension 1/2 and H (C) = E. We conclude this discussion by returning to the original question concerning dyadic line segments. Let  ⊂ [0, 1]2 be a fixed dyadic line segment of level m so that  = {(a, k/2m ) : 0 ≤ a ≤ 1} or  = {(k/2m , b) : 0 ≤ b ≤ 1} where k is odd. For definiteness, we assume the former so that  is horizontal. Then there are 2m dyadic squares of the mth stage below  that contribute an edge to  and 2m dyadic squares above  that contribute an edge. Each of these 2 · 2m dyadic squares corresponds to its own base 4 subinterval of length 1/4m and although two such subintervals can intersect, they cannot overlap. Consequently, H −1 () is the union of 2 · 2m nonoverlapping general Cantor sets each of Hausdorff dimension 1/2; see Theorem 6. February 2021]

DETAILS OF FILLING SPACE

107

Theorem 6. Let  ⊂ [0, 1]2 be a fixed dyadic line segment of level m. Then there are nonoverlapping general Cantor sets {Ci : i = 1, 2, . . . , 2 · 2m }, each of Hausdorff dimension 1/2 such that H

−1

() =

m 2·2 

(Ci ).

k=1

In the following section we continue the “delicate” motif, by first observing that H is no more than 4-to-1 at any point in the domain. Moreover, we’ve already noted that H is 1-to-1 on the vast majority of points. But this leaves a good deal left unsaid, leaving room for Sections 6 and 7. 6. DYADIC LINES: A FIRST LOOK. In this section, we’ll take a closer look at the point-by-point nature of the Hilbert curve, building on the work in the previous sections. According to Observation 3, H is 1-to-1 at all points not lying on a dyadic line, and, of course, these amount to “most” of the points. The proof of the following lemma shows that the narrative regarding points that lie on exactly one dyadic line is similar. Theorem 7. The Hilbert function H is exactly 2-to-1 at points lying on exactly one dyadic line, except those on the boundary of [0, 1] at which H is 1-to-1. Proof. Suppose a point y ∈ [0, 1]2 lies on a dyadic line of level n > 0 and no previous level. Then there are exactly two neighboring dyadic squares, S = T , of level n that contain y on their boundaries. Suppose for instance that S = SA0 and T = SA1 . If m > n, then within each of these squares (S and T ) there is precisely one dyadic square of level m that contains y. Hence, y is addressed by the two sequences (A0b1 b2 . . . ) and (A1c1 c2 . . . )

(6)

and only these sequences. Moreover, using Observation 4, neither of these sequences “terminates” since y is not a corner of any one dyadic square. If x1 = .A0b1 b2 . . . and x2 = .A1c1 c2 . . . , it follows that x1 = x2 and y = H (x1 ) = H (x2 ). Other cases being entirely analogous, this completes the proof. The possibilities for the bi and ci in Theorem 7 are not unlimited as, for example, if the side of S1 that contains y is of type [0, 1], then the side of S2 cannot be of type [1, 2]. But more on this later; for now it’s sufficient to know that H is precisely 2-to-1 at points lying on precisely one dyadic line. Suppose then that y ∈ [0, 1]2 lies on the intersection of two dyadic lines of which the first is of level n and the second is of level m with n ≤ m. Lemma 1. If n = m > 0, then H is exactly 3-to-1 at y. Proof. In this case, y is the common corner of all four dyadic squares of level n, so using Observation 4 the sequences by which y can be addressed are 1. 2. 3. 4. 108

y y y y

= (a1 a2 . . . an−1 02), = (a1 a2 . . . an−1 13), = (a1 a2 . . . an−1 20), and = (a1 a2 . . . an−1 31). c THE MATHEMATICAL ASSOCIATION OF AMERICA 

[Monthly 128

Therefore, 1. 2. 3. 4.

H (.a1 a2 . . . an−1 02) = y, H (.a1 a2 . . . an−1 13) = y, H (.a1 a2 . . . an−1 20) = y, and H (.a1 a2 . . . an−1 31) = y.

However, since .a1 a2 . . . an−1 13 = .a1 a2 . . . an−1 20, H is precisely 3-to-1 at such points y. We use the next lemma in which m = n + 1 as an introduction to a more general analysis. Lemma 2. If m = n + 1 ≥ 2, then H may be 2-to-1, 3-to-1, or 4-to-1 at y depending on the configuration of the level m dyadic squares contiguous with y. Proof. Fix S, a dyadic square of level n with an address of A = (a1 a2 . . . an ). Suppose, for definiteness, that its configuration is LD . This is illustrated in Figure 9, where the m-level dyadic line segments inside S are dotted and we’ve shown the Hilbert configuration of the level m dyadic subsquares of S via the arrow diagrams.

Figure 9. The m = n + 1 case where n > 0.

It is the points labeled α, β, δ, and γ that are the focus of Lemma 2. As each of these four points is the confluence of four level m squares, each has four natural addresses; these are listed in Table 3. Four pairs of these addresses correspond to the same preimage, e.g., .A023 = .A030, and taking this into account we find that α and β are 3-to-1 points (i.e., |H −1 (α)| = |H −1 (β)| = 3) while γ is a 2-to-1 point and δ is a 4-to-1 point. Table 3. Addresses of m = n + 1 points.

Point α β γ δ

Address 1 A023 A232 A123 A012

February 2021]

Address 2 A030 A201 A130 A021

Address 3 A101 A303 A230 A312

DETAILS OF FILLING SPACE

Address 4 A132 A310 A210 A321 109

We analyze the general case where m ≥ n + 2 similarly, but with a slightly different perspective. Let α ∗ denote the intersection of a dyadic line of order m with a dyadic line of order n. For definiteness, we suppose that the order n dyadic line is horizontal. Then α ∗ is the center point of a square of side length 1/2m−1 , where the lower half is the top half of a dyadic square of order m − 1 and the top half is the lower half of a dyadic square of order m − 1. This is the situation with α (and β) in Figure 9 while the situation at points γ and δ is analogous, but where the order n dyadic line is vertical. The cardinality of H −1 (α ∗ ) is completely determined by the Hilbert configurations in these separate halves. To see this, let SA and SB respectively denote these particular upper and lower dyadic squares where A and B are base 4 sequences of length m − 1. Then α ∗ is the center point of the edge shared between SA and SB and since α ∗ is not a vertex of either, IA and IB do not overlap. This means that if H is i-to-1 at α ∗ within SA and j -to-1 at α ∗ within SB , then, overall, H is (i + j )-to-1 at α ∗ . In SA , the bottom edge can be any of SA [0, 1], SA [1, 2], SA [2, 3], or SA [0, 3] and in Table 4 we list the preimages of α. Table 4. Preimages of dyadic intersections, m ≥ n + 1.

α ∗ ∈ Side SA [0, 1] SA [1, 2] SA [2, 3] SA [0, 3]

Preimage 1 .A03 .A12 .A23 .A01

Preimage 2 = = = =

.A10 .A10 .A30 .A32

The point labeled α in Figure 9 is pictured in Figures 10 and 11 as α ∗ , but showing only the upper square SA in Figure 10 and the lower square SB in Figure 11. Viewed from within SA , α ∗ ∈ SA [0, 3] so there are two codes for α ∗ ; one of these terminates with 1 and the other with 2. Hence, this α ∗ is a 2-to-1 point from within SA or, in this case, from above.

Figure 10. Half is just enough.

Continuing this example, the analysis from within SB , or from below in this case, is similar; see Figure 11. In SB , α ∗ ∈ SB [2, 3] and although there again are two codes for α ∗ , the corresponding base 4 decimals are equal. That is, H is 1-to-1 at α ∗ from within SB . Consequently, α ∗ is a 3-to-1 point overall. The situation is not random, however, so not all potential matches occur. 110

c THE MATHEMATICAL ASSOCIATION OF AMERICA 

[Monthly 128

Figure 11. The bottom half. Table 5. The edge match patterns.

Initial match stage 1 1 1 1 2 2 2

The edge S[0, 1] = T [3, 2] S[0, 3] = T [3, 2] S[0, 1] = T [3, 0] S[1, 2] = T [2, 1] S[2, 3] = T [3, 2] S[0, 1] = T [1, 0] S[0, 3] = T [3, 0]

Parity of H at the center 2-to-1 3-to-1 3-to-1 4-to-1 2-to-1 2-to-1 4-to-1

Lemma 3. If S and T are dyadic squares of the same level n > 0 and share an edge, then if that edge is S[1, 2], then S[1, 2] = T [1, 2]. That is, a [1, 2] edge is only shared with another [1, 2] edge. Proof. This is true at the first stage of Hilbert patterning (Figure 2), where the [1, 2] edge is the top of the unit square. At the second stage, the top of the unit square is the union of two separate [1, 2] edges, but also the segment extending between (1/2, 0) and (1/2, 1/2). The lemma now follows inductively by noting that, for any specific Hilbert pattern LP at stage n, the subsquares labeled 1 and 2 are patterned by the same LP , while the 0 and 3 subsquares are patterned in such a way that their [1, 2] sides coincide, albeit in opposite order. The situation for the other edges is remarkably different and is described in the Table 5. Theoretically, there are 32 possible edge pairings since order is a consideration. That is, the notation S[0, 1] = T [2, 3] entails that these two edges are the same, but that the half marked “0” on S[0, 1] matches with the half marked “2” on T [2, 3]. Table 5 lists all the matches that actually occur for the Hilbert curve and all that can occur do occur by the 4th stage of construction. The second column of the table lists the overall parity of H at the center point of the edge. Lemma 4. Suppose S and T are dyadic squares of the same level n > 0 and share an edge. Then the only edge matches possible are found in Table 5 along with the parity of H at the center point of that edge. Moreover, these are the only edge matches exhibited by the Hilbert curve. Proof. As the replacement patterns rigidly follow Table 1, we can establish Lemma 4 by exhaustion; that is, we simply record all possibilities at each stage until no new edge matches occur. February 2021]

DETAILS OF FILLING SPACE

111

At the second stage there are four edge matches, namely the first four rows of Table 1. At the third stage, three more edge matches appear, but there are no new appearances at the fourth stage and hence no new appearances thereafter. At this point we know that the only points in [0, 1]2 that are not 1-to-1 points of H lie on dyadic lines, and on a dyadic line the only points that are not 2-to-1 points of H are intersections of dyadic lines of different orders. Those points are exactly midpoints of the edges found in Table 1. In the next section, we have something to say about such points. 7. 4-TO-1, 2-TO-1, AND 3-TO-1 ON THE DYADIC LINES. We begin with a search for the points in [0, 1]2 at which H is 4-to-1. Theorem 8. The only edges that contain 4-to-1 points of H are the edges in which S[1, 2] = T [2, 1], S[0, 3] = T [3, 0], or S[0, 1] = T [3, 2]. 1. Edges of the form S[1, 2] = T [2, 1]: All dyadic points are 4-to-1 points of H and all remaining points are 2-to-1 points of H . 2. Edges of the form S[0, 3] = T [3, 0] or S[0, 1] = T [3, 2]: Among the dyadic points, there are countable dense sets of 4-to-1 points of H and 2-to-1 points of H ; again all nondyadic points of such an edge are 2-to-1 points of H . Proof. We consider the two cases independently. First, suppose S[1, 2] = T [2, 1]. In the S dyadic square, the S[1, 2] edge is comprised of an edge of a subsquare labeled with a “1” at the next level, followed by an edge of a subsquare labeled by “2.” Hence, the midpoint of that edge is a 4-to-1 point of H . The order of these segments is determined by adjacency as in Figure 5. This information is summarized in Table 2 and illustrated by the pair of trees in Figure 12, where it is apparent that the pattern is doubly periodic at the very next level where [2, 1] on the second level of the left tree pairs with [1, 2] on the second level on the right tree. Hence, both new midpoints are again 4-to-1 points of H . As every dyadic point of S[1, 2] = T [2, 1] is such a midpoint, it follows inductively that every dyadic point of this edge is a 4-to-1 point of H . As we have already established that all nondyadic points on dyadic lines are 2-to-1 points, this completes the verification of this case. For the second case, suppose S[0, 3] = T [3, 0] or S[0, 1] = T [3, 2]. To begin, we use Table 2 to find the two tree diagrams associated with the matching S[0, 3] = T [3, 0]. From this it follows that the midpoint of the S[0, 3] = T [3, 0] edge is a 4to-1 point, and from the next level that both new second level midpoints are 2-to-1 points. On the third level there are four new midpoints; the first and the fourth are again 4-to-1 points, and the remaining two are 2-to-1 points of H . The final level verifies periodicity. This completes the proof. The following theorem can be proved using completely analogous ideas. Theorem 9. The 2-to-1 points and 3-to-1 points are both dense among the dyadic points on each edge of the remaining types S[0, 3] = T [1, 0], S[0, 3] = T [3, 2], S[2, 3] = T [3, 2], and S[0, 1] = T [1, 0]. 112

c THE MATHEMATICAL ASSOCIATION OF AMERICA 

[Monthly 128

Figure 12. Edge progeny trees.

8. CONCLUDING REMARKS. The program depicted here for the Hilbert curve can be carried out almost without alteration for any space-filling curve that is space filling on every interval. Moreover, for space-filling curves that are not space filling on every interval, there always is a core set on which the current analysis is directly applicable. Also, and in quite obvious ways, the program described here can be carried out for analogous hyperspace-filling curves H ∗ : R → Rn . The nature of such curves and a solution to the question as to the minimal N for which such curves can be at most N-to-1 are the subjects of future papers. ACKNOWLEDGMENTS. The research for this paper was begun during the fall term of 2018 as part of a Directed Undergraduate Research class taught at St. Olaf College by the second author. The authors thank the referees for their insightful suggestions.

REFERENCES ´ (1949). Elements de la Theorie des Ensembles. Paris: Albin Michel. [1] Borel, E. ¨ [2] Hilbert, D. (1891). Uber die stetige Abbildung einer Linie auf ein Fl¨achenst¨uck. Math. Ann. 38: 459– 460. doi.org/10.1007/978-3-662-38452-7 1 [3] Moore, E. H. (1900). On certain crinkly curves. Trans. Amer. Math. Soc. 1: 72–90. doi.org/10.2307/ 1986405 [4] Netto, E. (1879). Beitrag zur mannigfaltigkeitslehre. J. Reine Angew. Math. 86: 263–268. doi.org/ 10.1515/crll.1879.86.263 [5] Olmsted, J. M. H. (1959). Real Variables: An Introduction to the Theory of Functions. The AppletonCentury Mathematics Series. New York: Appleton-Century-Crofts, Inc. [6] Peano, G. (1890). Sur une corbe qui remplit toute une aire plane. Math. Ann. 36: 157–160. doi.org/ 10.1007/bf01199438 [7] Rose, N. J. (2001). Hilbert-type space-filling curves. researchgate.net/profile/Nicholas Rose/ publication/265074953 Hilbert-Type Space-Filling Curves/links/55d3f90e08aec1b0429f407a.pdf [8] Sagan, H. (1992). On the geometrization of the Peano curve and the arithmetization of the Hilbert curve. Internat. J. Math. Ed. Sci. Tech. 23(3): 403–411. doi.org/10.1080/0020739920230309 [9] Sagan, H. (2012). Space-Filling Curves. New York: Springer Science & Business Media.

SONYA FLATEN graduated summa cum laude from St. Olaf College in May, 2019 with a Bachelor of Arts in Mathematics. During her undergraduate career, she enjoyed taking courses in biology, chemistry, philosophy, and religion in addition to earning her mathematics degree. Sonya is currently pursuing a Doctor of Medicine degree at Creighton University. [email protected]

February 2021]

DETAILS OF FILLING SPACE

113

PAUL D. HUMKE received his Ph.D. from the University of Wisconsin at Milwaukee in 1972. He began his career at Western Illinois University and after nine years moved to St. Olaf College where he’s been ever since. During the past 19 years he’s served as a Visiting Professor of Mathematics at Washington and Lee University during the Winter and/or Spring terms. Department of Mathematics, Statistics and Computer Science, St. Olaf College, Northfield, MN 55057. [email protected]

EMILY OLSON graduated from St. Olaf College in May 2020, and is planning to attend graduate school for a Ph.D. in mathematics in Fall 2021. Department of Mathematics, Statistics and Computer Science, St. Olaf College, Northfield, MN 55057. [email protected]

THONG VO is currently a fourth year student at St. Olaf College majoring in mathematics and computer science. He plans to enter a Ph.D. program in mathematics or computer science or some combination thereof after graduating in 2021. Department of Mathematics, Statistics and Computer Science, St. Olaf College, Northfield, MN 55057. [email protected]

114

c THE MATHEMATICAL ASSOCIATION OF AMERICA 

[Monthly 128

Analysis of Series and Products. Part 1: The Euler–Maclaurin Formula Ian Thompson , Morris Davies, and Miren Karmele Urbikain Abstract. We explore the applications of the Euler–Maclaurin formula in analyzing functions expressed as infinite series and products. Three illustrative examples show the difficulties that may be encountered and the means by which these can be overcome.

1. INTRODUCTION. A seemingly elementary but rarely discussed problem in mathematics is the following: Given a function S(x) expressed as an infinite series, find the value of the limit lim S(x)

x→∞

(or perhaps the limit as x → 0). Better still, find an asymptotic expansion for S(x). Exact summation is rarely a practical option, as there are relatively few series for which closed-form expressions are known, and few tools for deriving such formulae. Moreover, the limit x → ∞ may not commute with the implicit limit as the number of terms tends to infinity. For example, if S(x) =

∞ 

e−j

2 /x 2

= lim

N→∞

j =1

N 

e−j

2 /x 2

,

(1)

j =1

what can we say about the behavior of S(x) as x → ∞? We would like something more insightful than “It diverges!” For this very simple case Jacobi’s imaginary transformation for theta functions [14, p. 476] gives the exact result √ ∞ √  1 x π 2 − +x π e−(j πx) , x > 0. (2) S(x) = 2 2 j =1 Jacobi first published this formula in 1828 [4], but he credits it to Poisson, who found it five years earlier [10, p. 420]. If x is large, then (2) can be used to approximate S(x) 2 as a linear function, with an error proportional to xe−(πx) . In contrast, (1) is useful for computation when x is small, but inefficient when x is large because many terms are needed in order to obtain an accurate result. In this article, we show how the Euler–Maclaurin formula can be used to analyze series that contain a large (or small) parameter. This approach works by relating the series to an integral, and before attempting a problem of this type, one should ask the following question: “If the summation symbol were to be replaced by an integral, could the integral be evaluated exactly?” It is likely that progress can be made if the answer is “Yes.” The same method can sometimes be applied to infinite products. Thus, if G(x) =

∞ 

g(j ; x),

j =1

doi.org/10.1080/00029890.2021.1845542 MSC: Primary 40A25 Supplemental data for this article can be accessed on the publisher’s website.

February 2021]

ANALYSIS OF SERIES & PRODUCTS, PART 1

115

where g(j ; x) > 0 for j ∈ N and g(j, x) → 1 as j → ∞, then taking logarithms yields ln G(x) =

∞ 

ln g(j ; x).

j =1

Therefore we may treat the product as a series, and take exponentials to obtain a final result. After reviewing the derivation of the Euler–Maclaurin formula in Section 2, we apply it to three examples in Section 3: first Poisson’s series (1), then a series with a summand containing an odd function, but with no symmetry about j = 0, and finally a more challenging example derived from an infinite product, featuring a logarithm in the summand. In each case, we obtain an asymptotic approximation that produces accurate results for parameter regimes in which the convergence of the original series is very slow. 2. THE EULER–MACLAURIN FORMULA. The Euler–Maclaurin formula is a standard result [5, Chapter 14], [11, Section 3.3], though its use in asymptotically expanding infinite series is somewhat obscure. Perhaps the first mathematician to apply it in this way was Niels Erik Nørlund, around 1924 [8, Chapter 4]. Today it is probably fair to class Nørlund’s idea as well known amongst those to whom it is well known.1 To see how the Euler–Maclaurin formula operates, it is useful to begin by reviewing a brief derivation, for which we largely follow [2]. Let n0 and n1 be integers with n1 > n0 , and consider the integral 

n1

n0

f (s; x) ds =

n1 −1  j +1  j =n0

f (s; x) ds.

j

For each term in the sum on the right-hand side, write f (s; x) = 1 × f (s; x) and integrate by parts, using the antiderivative  (3) 1 ds = s − j − 12 . In this way, we find that 

n1

n0

f (s; x) ds =

n1 −1



j +1   − s − j − 12 f (s; x) j

j =n0



j +1 

j

s−j −

1 2

  f (s; x) ds ,

and then by evaluating the boundary terms and rearranging, we obtain n1  j =n0

 f (j ; x) =

n1 n0

f (s; x) ds +

f (n0 ; x) + f (n1 ; x) 2 +

n1 −1  j +1   j =n0

j

s−j −

1 2

  f (s; x) ds. (4)

1 Credit for this excellent description, which applies to many of the more esoteric mathematical techniques, goes to the late Fritz Ursell [1].

116

c THE MATHEMATICAL ASSOCIATION OF AMERICA 

[Monthly 128

Figure 1. The functions P1 (s), P2 (s), and P3 (s) for −3 ≤ s ≤ 3.

Here and henceforth, the prime symbol indicates differentiation with respect to the first argument. Now the factor s − j − 12 is the periodic extension of the function P1 (s) = s − 12 from the interval [0, 1) to the real line, except at integer values for s where the former takes different values in adjacent terms. However, changing the value of an integrand at isolated points has no effect, so if we write P1 (s) = s − s − 12 ,

−∞ < s < ∞,

(5)

where · means “round down,” then the second sum in (4) can be evaluated to yield  n1  n1 n1  f (n0 ; x) + f (n1 ; x) + f (j ; x) = f (s; x) ds + P1 (s)f  (s; x) ds. (6) 2 n0 n0 j =n 0

This is the first order Euler–Maclaurin formula. Further formulae are obtained using integration by parts, differentiating f  and integrating P1 . The required antiderivatives are chosen to be continuous, so that boundary terms can only occur at s = n0 or s = n1 , and not at the intermediate points s = n0 + 1, n0 + 2, . . . , n1 − 1. We begin by writing  s Pj (s) = j Pj −1 (w) dw + cj , j = 2, 3, . . . , (7) 0

where the factor j multiplying the integral is included for later convenience. A consequence of this definition is that P2 is continuous, P3 is once differentiable, P4 is twice differentiable, and so on. Now P2 inherits the 1-periodicity of P1 , because  a+1 P2 (a + 1) − P2 (a) = 2 P1 (w) dw a

for any real number a, and the integral of P1 over one period is zero. (This can easily be deduced from the plot in Figure 1.) For 0 ≤ s < 1, we have  s   P2 (s) = 2 w − 12 dw + c2 = s 2 − s + c2 , 0

and values elsewhere are determined by periodic repetition. It follows that P2 (s) is bounded for s ∈ R, and since this property turns out to be useful, we will choose the February 2021]

ANALYSIS OF SERIES & PRODUCTS, PART 1

117

constants cj so that the functions P3 , P4 , . . . are also periodic (and therefore bounded). To achieve this, we simply need to ensure that the integral of each function over one period is zero, i.e.,  1 Pj (w) dw = 0, j = 1, 2, . . . . (8) 0

It then follows that c2 = 16 , and in general (using (7)), 

1



cj = −j

s

Pj −1 (w) dw ds. 0

0

The functions that evolve through this process are periodic extensions of the Bernoulli polynomials [9, §24]; indeed, Pj (s) = Bj (s − s ). Graphs of P1 (s), P2 (s), and P3 (s) are shown in Figure 1. Now P1 (s) is antisymmetric about s = 12 , which means P2 (s) is symmetric. It then follows that P3 (s) is antisymmetric except possibly for a constant vertical shift. However, (8) can only hold if the vertical shift is absent, so P3 ( 21 ) = 0 and P3 (0) = −P3 (1). By periodicity P3 (0) = P3 (1), and this is only possible if P3 (0) = c3 = 0. The alternating pattern of symmetry and antisymmetry continues throughout the sequence, meaning that c2j +1 = 0, P2j −1 (n + 12 ) = 0,

and

P2j +1 (n) = 0,

for all integers n and natural numbers j . In view of the last result, it is conventional to apply an even number of integrations by parts to the last term in (6). In this way, we arrive at the general Euler–Maclaurin formula n1  j =n0

 f (j ; x) =

n1 n0

f (s; x) ds + +

where

m  B2j (2j −1) f (n1 ; x) − f (2j −1) (n0 ; x) + m , (9) (2j )! j =1

 m =

f (n0 ; x) + f (n1 ; x) 2

n1 n0

P2m+1 (s) (2m+1) f (s; x) ds. (2m + 1)!

Here we have used the fact that P2j (n) = B2j , the 2j th Bernoulli number, for j ≥ 0 and any integer n [3, Section 9.6]. The usual strategy for employing (9) to asymptotically expand a series is to evaluate the integral on the right-hand side exactly, and prove that m is of smaller magnitude than the other terms. Often this last step can be achieved by making an appropriate substitution to remove the dependence upon x from f and then using the bound [6]

P2m+1 (s) 2

(10)

(2m + 1)! < (2π)2m+1 . 118

c THE MATHEMATICAL ASSOCIATION OF AMERICA 

[Monthly 128

If (as is often the case) f (s; x) = f (w) where w = s/x, then  n1 /x P2m+1 (xw) (2m+1) f (w) dw, m = x −2m (2m + 1)! n0 /x

(11)

and hence 1 |m | ≤ π(2πx)−2m



n1 /x

f (2m+1) (w) dw.

(12)

n0 /x

It is difficult to determine how the integral in (12) behaves as m increases, so the error is usually estimated by considering the next term that would appear in the finite series on the right-hand side of (9), if m were to be increased. However, there are situations in which this series disappears entirely. For example, if f (s; x) is symmetric about s = n0 (or n1 ), then all its odd derivatives will vanish at this point. Alternatively, if n0 and n1 are extended to ±∞, and the resulting series and integrals are convergent, then in most problems of practical interest f and its derivatives will vanish in these limits. Should the series disappear from the right-hand side of (9), m may be chosen arbitrarily, and the error caused by discarding m is then exponentially small. This phenomenon has previously been observed in [13] and (in the context of analyzing infinite series) [12]. 3. EXAMPLES. We now consider three example series. Each contains a positive parameter x, and converges rapidly when this is small. We will derive asymptotic approximations that provide accurate results for large x. The first two examples are relatively straightforward, and the last is much more difficult. Even summand. For our introductory example, we consider the series S(x) given in (1). We begin by setting f (s; x) = e−s

2 /x 2

.

Clearly, it will be easier to evaluate the relevant integral in (9) if we apply the Euler– Maclaurin formula starting at s = 0, rather than s = 1. In addition, since f (s; x) is an even function, we have f (2j −1) (0) = 0. Thus, substituting into (9), taking n0 = 0, and letting n1 → ∞, we find that ∞ 

e−j

2 /x 2

 =



e−s

2 /x 2

0

j =0

ds +

1 + m , 2

(13)

where 



m = 0

P2m+1 (s) (2m + 1)!



d ds

2m+1 e−s

2 /x 2

ds.

(14)

Evaluating the integral in (13) then yields the first two terms in (2). For (14), we may write w = s/x and then use (10) as in (11) and (12) to show that m = O(x −2m ). Since m may be chosen arbitrarily, it follows that the error committed in discarding this term is asymptotically smaller than any algebraic power of x. This is in agreement with Poisson’s result (which implies that m decreases exponentially as x → ∞), but we have not succeeded in making further progress towards (2) from (14). February 2021]

ANALYSIS OF SERIES & PRODUCTS, PART 1

119

A summand without symmetry. We now consider the series T (x) =

∞ 

e−j

3 /x 3

,

x > 0.

(15)

j =1

As before, the corresponding integral is easier to evaluate if its lower limit is zero; indeed the substitution w = s 3 /x 3 shows that  ∞   3 3 e−s /x ds = x 43 , x > 0, 0

where (·) represents the Gamma function [9, Chapter 5], and we have used the identity z(z) = (z + 1). Therefore we apply the Euler–Maclaurin formula with n0 = 0, rather than n0 = 1. Letting n1 → ∞ and writing f (s; x) = e−s

3 /x 3

in (9), we find that T (x) = x

4 3

1  B2j (2j −1) f (0; x) + m , − − 2 j =1 (2j )!

where 



m = 0

m

(16)

  P2m+1 (s) d 2m+1 −s 3 /x 3 e ds. (2m + 1)! ds

Next, we look to simplify the finite sum in (16), by finding an explicit value for the derivative. To achieve this, we write the exponential as a Maclaurin series and then differentiate repeatedly. In this way, we find that   ∞  (−1)p d k 3p (k) s f (s; x) = x 3p p! ds p=0 =

∞  (−1)p (3p)(3p − 1) · · · (3p − k + 1)s 3p−k , 3p p! x p= k/3

where · means “round up.” In the last line, the lower limit for the series is determined by noting that differentiating once eliminates one term, differentiating four times eliminates two terms, etc. A nonzero value at s = 0 can only occur if k is divisible by three, in which case f (k) (0; x) =

(−1)k/3 k! . x k (k/3)!

Therefore the summand in (16) evaluates to zero unless 2j − 1 = 6p − 3 (i.e., an odd multiple of 3) for some p ∈ N. We can perform further integrations by parts in the error term m , stopping at the last step before a nonzero boundary term occurs. However, a simpler approach is to base the error estimate on the first (nonzero) term omitted from the series; that is, T (x) = x

120

4 3

1 1 B6p−2 + + O(x −6r−3 ). 2 2 p=1 (2p − 1)!(3p − 1)x 6p−3 r



c THE MATHEMATICAL ASSOCIATION OF AMERICA 

(17)

[Monthly 128

This is an asymptotic representation of T ; the series will diverge if the upper limit r is extended to infinity. Nevertheless, very accurate results can be obtained using a finite number of terms. Generally, for a given x, the best available approximation occurs when r is chosen so that the terms included in the series decrease monotonically in magnitude, but subsequent terms do not [7, Chapter 1]. In the particular case of (17), the terms initially decrease fairly rapidly in magnitude, after which the summand remains small for a sequence of p values. For example, if x = 2.5, the magnitude of the terms decreases monotonically up to p = 6, at which point (17) yields T (2.5) ≈ 1.731915773, which has nine correct digits. Similar approximations may be obtained by taking r to have any value in the range 3, . . . , 9. Increasing the upper limit beyond r = 9 causes the approximation to deteriorate. A summand with a real singularity. As a more challenging example, we now consider a series that originates from the infinite product ∞   2 2 G(x) = 1 − e−j /x . j =1

Expressions of this type appear in the study of heat transfer through walls; see the supplemental material and references therein. Taking logarithms yields F (x) = ln G(x) =

∞   2 2 ln 1 − e−j /x ,

(18)

j =1

and we aim to determine the behavior of F (x) for large x. We begin by writing  2 2 f (s; x) = ln 1 − e−s /x . Although this is an even function, it is not defined at the origin, and this presents some problems. However, f (s; x) does have the property that odd-ordered derivatives vanish at s = 0, and we can take advantage of this as follows. We start with the first order Euler–Maclaurin formula (6), letting n1 → ∞ and setting n0 = 1; that is,  ∞  ∞ f (1; x) + F (x) = f (s; x) ds + P1 (s)f  (s; x) ds. (19) 2 1 1 As in the two previous examples, the first integral on the right-hand side is easier to evaluate if the lower limit is replaced by zero. Thus, expanding the logarithm as a Taylor series, we find that 

 ∞    1 ∞ −j s 2 /x 2 −s 2 /x 2 ds = − ln 1 − e e ds j 0 0 j =1 (20) √ x π 3 ζ 2 , = − 2 √ having used the substitution w = s j /x. Here, ζ (·) represents the Riemann zeta function [9, Chapter 25], that is ∞

ζ (x) =

February 2021]

∞  1 , x j j =1

x > 1.

ANALYSIS OF SERIES & PRODUCTS, PART 1

(21)

121

In view of (20), we rewrite (19) in the form √  ∞  1 x π 3 f (1; x) ζ 2 − + F (x) = − f (s; x) ds + P1 (s)f  (s; x) ds. 2 2 0 1

(22)

It is now desirable to “join” the remaining two integrals, but the singularity at the origin prevents integration by parts using (3). To overcome this, we introduce the regularized function    2 2 fˆ(s; x) = ln 1 − e−s /x − ln s 2 /x 2 . This has no singularity at the origin; in fact it is not difficult to show that fˆ(0; x) = 0. In addition, fˆ (s; x) → 0 as s → ∞, so we can replace f with fˆ in (22) provided we add the correction term    ∞  1  2 2 ln 1/x 2 P1 (s) +2 ds. (23) ln s /x ds + C=− 2 s 0 1 The first integral that appears here is elementary. For the second, we use (5) to obtain 

∞ 1

N  j +1  s−j − P1 (s) ds = lim N→∞ s s j =1 j

1 2

ds

  N     = lim N − j + 12 ln(j + 1) − ln j . N→∞

j =1

The above series can be made partially telescopic by rearranging the summand; thus      j + 12 ln(j + 1) − ln j = (j + 1) ln(j + 1) − j ln j − 12 ln(j + 1) + ln j , which leads us to  ∞ 1

P1 (s) ds = lim N − (N + 12 ) ln(N + 1) + ln(N!) . N→∞ s

Now Stirling’s series [9, equation 5.11.1] can be written in the form   ln(2π) + O(N −1 ), ln(N!) = N + 12 ln(N + 1) − (N + 1) + 2 and this shows that



∞ 1

ln(2π) P1 (s) ds = − 1. s 2

Returning to (23), we now find that C = ln(2πx) and then from (22), √  ∞  1 x π  3  fˆ(1; x)  ˆ F (x) = ln(2πx) − ζ 2 + + P1 (s)f (s; x) ds − fˆ(s; x) ds. 2 2 1 0 Integrating once by parts in the last term reduces this to √  ∞ x π 3 ζ 2 + P1 (s)fˆ (s; x) ds. F (x) = ln(2πx) − 2 0 122

c THE MATHEMATICAL ASSOCIATION OF AMERICA 

[Monthly 128

Having eliminated the singularity at the origin, the next step is to integrate by parts repeatedly. In this way, we find that √ x π 3 (24) ζ 2 + m , F (x) = ln(2πx) − 2 where





m = 0

P2m+1 (s) ˆ (2m+1) f (s; x) ds. (2m + 1)!

(25)

Note that, since fˆ is an even function, no boundary terms are produced in any step (in contrast to the derivation of (9)). However, integrating by parts an even number of times facilitates the use of (10) after making the substitution w = s/x. A slightly more complicated bound is required if even indices are permitted [6]. Ultimately, these are minor details; the end result is that m is asymptotically smaller than any algebraic power of x. This rapid decay can be observed with a simple numerical experiment, computing F (x) directly using (18) and approximating using (24) with m = 0. Three correct significant figures are obtained if x  0.68, six if x  1.3, and sixteen if x  3.2. 4. CONCLUDING REMARKS. We have demonstrated that the Euler–Maclaurin formula provides a simple but powerful means for finding asymptotic expansions of series and products that contain a large (or small) parameter. It takes some creativity to make this work with summands that possess real singularities (such as (18)), but ultimately the techniques used are all based on elementary calculus, and integration by parts in particular. However, we have not retrieved Poisson’s full result (2) by this approach. Indeed, it is not clear how information about the precise nature of m can be obtained from (14) or (25), if this is possible at all. Of course we would be delighted to hear from any readers who can find a way to derive (2) using the Euler–Maclaurin formula. In Part 2 of our article, we will explore an even more powerful approach to the same problem, capable of reproducing Poisson’s result and also a corresponding exact transformation for (18). REFERENCES [1] Abrahams, I. D., Martin, P. A. (2013). Fritz Joseph Ursell. 28 April 1923–11 May 2012. Biogr. Mems Fell. R. Soc. 59: 407–421. doi.org/10.1098/rsbm.2013.0005 [2] Apostol, T. M. (1999). An elementary view of Euler’s summation formula. Amer. Math. Monthly. 106(5): 409–418. doi.org/10.2307/2589145 [3] Gradshteyn, I. S., Ryzhik, I. M. (2007). Tables of Integrals, Series and Products, 7th ed. London: Elsevier Academic Press. [4] Jacobi, C. J. G. (1828). Suite des notices sur les fonctions elliptiques. J. Reine Angew. Math. 3: 303–310. doi.org/10.1515/crll.1828.3.303 [5] Knopp, K. (1990). Theory and Application of Infinite Series. New York: Dover. [6] Lehmer, D. H. (1940). On the maxima and minima of Bernoulli polynomials. Amer. Math. Monthly. 47(8): 533–538. doi.org/10.2307/2303833 [7] Murray, J. D. (1974). Asymptotic Analysis. Oxford, UK: Clarendon Press. [8] Nørlund, N. E. (1924). Vorlesungen u¨ ber Differenzenrechnung. Berlin: Springer-Verlag. [9] Olver, F. W. J., Lozier, D. W., Boisvert, R. F., Clark, C. W. (2010). NIST Handbook of Mathematical Functions. Cambridge, UK: Cambridge Univ. Press. [10] Poisson, S. (1823). Suite du m´emoire sur les int´egrales d´efinies et sur la sommation des s´eries. Somma´ Polytech. Math. 12(XIX): 404–509. tion des s´eries de quantit´es p´eriodiques. J. Ec. [11] Stoer, J., Bulirsch, R. (1992). Introduction to Numerical Analysis, 2nd ed. New York: Springer-Verlag. [12] Thompson, I., Linton, C. M. (2010). Euler–Maclaurin summation and Schl¨omilch series. Q. J. Mech. Appl. Math. 63(1): 39–56. doi.org/10.1093/qjmam/hbp022

February 2021]

ANALYSIS OF SERIES & PRODUCTS, PART 1

123

[13] Trefethen, L. N., Weideman, J. A. C. (2014). The exponentially convergent trapezoidal rule. SIAM Rev. 56(3): 385–458. doi.org/10.1137/130932132 [14] Whittaker, E. T., Watson, G. N. (1927). A Course of Modern Analysis, 4th ed. Cambridge, UK: Cambridge Univ. Press. IAN THOMPSON is a senior lecturer in mathematics at the University of Liverpool in the UK. He was awarded his undergraduate degree by the University of Newcastle Upon Tyne in 2000, and completed his Ph.D. in 2003 at the University of Manchester, under the supervision of Prof. I. D. Abrahams. His research interests include complex and Fourier analysis, modeling techniques for wave phenomena, and computational methods. Department of Mathematical Sciences, University of Liverpool, Liverpool L69 7ZL, UK [email protected]

MORRIS DAVIES retired from the University of Liverpool in 1995, but has continued his research in building heat transfer to the present day. During the 1960s he conducted an investigation into the thermal behavior of perhaps the first passive solar-heated building of modern times, designed in 1957 and built near Liverpool (53.4 degrees latitude). Formerly School of Architecture, University of Liverpool, Liverpool L69 7ZN, UK [email protected]

KARMELE URBIKAIN is a lecturer in heat transfer at the School of Engineering of Bilbao, University of the Basque Country (UPV/EHU). She graduated in industrial engineering and completed her Ph.D. in thermal engineering at the UPV/EHU. Her research interests include heat transfer through opaque and semitransparent elements and energy use in buildings. Department of Thermal Engineering, The University of the Basque Country, Alameda Urquijo, Bilbao, Spain [email protected]

ORCID Ian Thompson

124

http://orcid.org/0000-0001-5537-450X

c THE MATHEMATICAL ASSOCIATION OF AMERICA 

[Monthly 128

Length-Preserving Directions and Some Diophantine Equations Juan Tolosa

Abstract. We study directions along which the norms of vectors are preserved under a linear map. In particular, we find families of matrices for which these directions are determined by integer vectors. We consider the two-dimensional case in detail, and also discuss the extension to three-dimensional vector spaces.

1. INTRODUCTION. In the nice Webinar talk “Eigenpairs in Maple” of June 25, 2015 [3], Dr. Robert Lopez discussed how to use Maple to find eigenvalues and eigenvectors (eigenpairs) of a matrix A. An eigenvector of A is a (nonzero) vector whose direction is preserved under multiplication by A. By the end of the talk, Dr. Lopez, as an aside, asked the question, what about preserving the magnitude of the vector, rather than its direction? In other words, what about (nonzero) vectors v such that v = Av, where v is the usual Euclidean norm? He provided the example of   4 3 A= , −2 −3 regarded as a map from R2 to itself; it preserves the norms, but not the directions, of the vectors with integer coordinates v1 = 1, −1 and v2 = 17, −19. He clarified he had found such matrix by using Maple and “for-loops” to find matrices A for which the equation v = Av would have integer solutions. In this article, we explore this intriguing idea, obtain several families of such “nice” 2 × 2 matrices, then consider a few 3 × 3 examples, and discuss a couple of related quadratic Diophantine equations. To avoid repetition, when considering an equation involving a vector v, by a solution v we will consistently mean a nontrivial solution v  = 0. 2. GENERAL CONSIDERATIONS. A given n × n-matrix A with real entries generates a related linear map v  → Av of Rn into itself; we will use the same letter A to represent this map. We seek nonzero vectors v whose norm is preserved under this linear map; in other words, we seek (nonzero) solutions of the equation v = Av.

(1)

First of all, observe that, since λv = |λ| · v, the entire line generated by any nonzero solution of (1) will consist of vectors whose norm is preserved by A; we will call these lines the norm-preserving lines. Next, if A has eigenvalue 1, or −1, then the corresponding eigenspace will consist entirely of solutions of (1) as well. doi.org/10.1080/00029890.2021.1851564 MSC: Primary 15A18, Secondary 11D09; 15A06

February 2021]

LENGTH-PRESERVING DIRECTIONS

125

The interesting case, though, is when there are nonzero solutions of (1) that are not eigenvectors. This may happen even if A has an eigenvalue ±1. For example, the matrix   1 −8 A= 0 3 has eigenvalue 1 with eigenline determined by v = 1, 0, but also has another, noninvariant, norm-preserving line, determined by w = 9, 2. Along this line, the map A acts like a rotation. At the other end of the spectrum we have the case of an orthogonal matrix A, for which every line through the origin is norm-preserving. In the 2 × 2 case these are typically rotations, for which these lines are noninvariant; however, all lines are rotated by the same angle under A. In the general case this does not happen: each normpreserving line is usually rotated by a different angle. 3. THE 2 × 2 CASE. Let us discuss nonzero solutions of equation (1) for the case of a 2 × 2 real-valued matrix A. We will first obtain conditions for existence of such solutions, and next, find families of norm-preserving lines determined by integer vectors. Existence of a solution. Let us study solutions of equation (1) for a general realvalued 2 × 2-matrix   a b A= . c d Equation (1) is equivalent to v2 = Av2 , or (v, v) = (Av, Av), where (v, w) is the usual Euclidean inner product. The right-hand side becomes Av2 = (Av, Av) = (v, At Av) = (v, Bv), where At is the transpose of A, and B = At A. Thus, equation (1) is equivalent to (v, (B − I )v) = 0, where I is the identity matrix. Further, we have B = At A =



a 2 + c2 ab + cd

ab + cd b2 + d 2

(2)



 =

 m p , p n

where m = a 2 + c2 ,

(3)

n = b2 + d 2 ,

(4)

p = ab + cd,

(5)

so that if we denote v = x, y, then the quadratic form on the left-hand side of (2) is (x, y) = (m − 1)x 2 + 2pxy + (n − 1)y 2 ;

(6)

with this notation, (1) or, equivalently, (2), is in turn equivalent to (x, y) = 0. We now prove the following result. 126

c THE MATHEMATICAL ASSOCIATION OF AMERICA 

[Monthly 128

Theorem 1. Norm-preserving lines exist if and only if a 2 + b2 + c2 + d 2 ≥ 1 + det(A)2 .

(7)

We will provide two proofs of this fact, one analytic, and one geometric. First proof. Norm-preserving lines are determined by v = x, y, where (x, y) is a nontrivial solution of (x, y) = 0 and where (x, y) is given by (6). If n = 1, that is, if b2 + d 2 = 1, this equation becomes (m − 1)x 2 + 2pxy = x [(m − 1)x + 2py] = 0, which has the nontrivial solution v = 0, 1. Also, in this case condition (7) is satisfied, since a 2 + b2 + c2 + d 2 − 1 − det(A)2 = a 2 + c2 − det(A)2 = (a 2 + c2 ) − (ad − bc)2 , which is equal to (ab + cd)2 = p 2 under the assumption that n = b2 + d 2 = 1. This follows from the identity (a 2 + c2 ) − (ad − bc)2 − (ab + cd)2 = [1 − (b2 + d 2 )](a 2 + c2 ). Thus, in this case condition (7) holds. If n  = 1, a nontrivial solution of (m − 1)x 2 + 2pxy + (n − 1)y 2 = 0 must satisfy x  = 0. Dividing by x 2 and solving for yx , we obtain −p ± y = x

 p 2 − (m − 1)(n − 1) . n−1

(8)

A solution will exist if and only if the discriminant p 2 − (m − 1)(n − 1) is nonnegative. Further, p 2 − (m − 1)(n − 1) = (p 2 − mn) + m + n − 1, and mn − p 2 = det(B) = det(A)2 = (ad − bc)2 , which can also be checked directly using (3)–(5). Thus, there is a norm-preserving line if and only if m + n − 1 − det(A)2 = (a 2 + c2 ) + (b2 + d 2 ) − 1 − det(A)2 ≥ 0, which coincides with condition (7). Second proof. The eigenvalues λ1 and λ2 of the symmetric matrix B = At A are (real and) nonnegative; assume 0 ≤ λ1 ≤ λ2 . By the extreme properties of eigenvalues (see, for example, [1] or [4]), we have February 2021]

LENGTH-PRESERVING DIRECTIONS

127

λ1 = min Av2 = min (v, Bv) v=1

v=1

≤ max Av = max (v, Bv) = λ2 . 2

v=1

v=1

Therefore, there will exist norm-preserving lines v such that v = Av if and only if λ1 ≤ 1 ≤ λ2 . When the eigenvalues are strictly positive, this condition guarantees the intersection of the ellipse (v, Bv) = 1, for which the half-axes are 1 √ λ1

and

1 √ , λ2

with the unit circle v = 1 (see Figure 1).

Figure 1. Illustration of R. Lopez’s example.

The eigenvalues of B are found from the characteristic equation λ2 − tλ +  = 0,

(9)

where t = trace B

and

 = det B.

In terms of B, condition (7) reads as t ≥ 1 + . Notice that  = det(B) ≥ 0, so actually (7) implies t ≥ 1 +  ≥ 1 > 0. Solving (9) we find 1 2 t λ= ± t − 4. 2 2 Let us assume now that t ≥ 1 + . Then t 2 − 4 ≥ (1 + )2 − 4 = (1 − )2 , 128

c THE MATHEMATICAL ASSOCIATION OF AMERICA 

[Monthly 128

so that

√ t 2 − 4 ≥ |1 − |. For the largest eigenvalue λ1 we have λ1 ≥

1 1 (1 + ) + |1 − |. 2 2

Considering both cases 1 ≥  and  ≥ 1, we conclude that λ1 ≥ max{, 1}.

(10)

In particular, we have λ1 ≥ 1, as desired. Now let λ2 be the smallest eigenvalue. Since λ1 λ2 = , we have λ2 =

 , λ1

and condition (10) now implies that indeed λ2 ≤ 1. Thus, condition (7) guarantees the existence of norm-preserving lines. The converse is straightforward. Families of matrices with integer solutions.  a A= c

We want to find matrices  b d

with integer or rational entries, for which the norm-preserving lines are determined by vectors v with integer coordinates; we will call these integer solution lines.1 Recall that Av2 = (Av, Av) = (v, Bv), where



a 2 + c2 B=A A= ab + cd t

ab + cd b2 + d 2





 m p = , p n

so that the solutions of Av2 = v2 are given by v = x, y, where (x, y) is a (nontrivial) solution of (m − 1)x 2 + 2pxy + (n − 1)y 2 = 0.

(11)

If either m = 1 or n = 1, it is not hard to get families of solutions. For example, for the two-parameter family   3 b A = 54 , d 5 we get norm-preserving lines determined by v1 = 1, 0 and v2 = 5(1 − b2 − d 2 ), 2(3b + 4d). For the general case, let us assume that the entries of A are integers, and seek integer solutions of the Diophantine equation (11). Assuming n  = 1 and solving for y/x, √ Of√course, if, say, a norm-preserving line is determined by v = 1, 2, then it is also determined by v =  2, 2 2. The idea is that there exists a determining vector with integer coordinates. In the 2 × 2 case, this means we are interested in solution lines with rational slopes. 1

February 2021]

LENGTH-PRESERVING DIRECTIONS

129

as we did in (8), we conclude that there are integer solution lines if and only if the discriminant p2 − (m − 1)(n − 1) is a perfect square, say, k 2 . This leads to the new Diophantine equation p 2 − (m − 1)(n − 1) = k 2 , which can be rewritten as (m − 1)(n − 1) = p 2 − k 2 = (p + k)(p − k),

(12)

where m, n, p are given by (3)–(5). We will now find two-parameter families of solutions. To this end, let us set m − 1 = p + k, n − 1 = p − k, or (a 2 + c2 ) − 1 = p + k,

(13)

(b + d ) − 1 = p − k,

(14)

2

2

to which we will include the equation 2(ab + cd) = 2p,

(15)

stemming from the definition (5) of p. Adding (13) and (14), and subtracting (15), we get (a − b)2 + (c − d)2 = 2,

(16)

from which we conclude that |a − b| = 1

and

|c − d| = 1.

(17)

Next, subtracting (14) from (13), we obtain a 2 − b2 + c2 − d 2 = 2k, or (a − b)(a + b) + (c − d)(c + d) = 2k.

(18)

Considering all the possibilities in (17), we obtain the following four two-parameter families of matrices   a a±1 . c c±1 For each of them, we can use (18) to find the value of k. Incidentally, their transposes,   a c , a±1 c±1 also have integer solution lines. 130

c THE MATHEMATICAL ASSOCIATION OF AMERICA 

[Monthly 128

The example of Robert Lopez corresponds to the case a − b = 1 and c − d = 1, which leads to   a a−1 A= ; (19) c c−1 he chose the particular values a = 4 and c = −2. For the general solution of type (19), we find from (18) that k = a + c − 1. Substituting this value into (8), which now looks like −p ± k y = , x n−1 we conclude that the norm-preserving lines are determined by the vectors v1 = 1, −1 and v2 = (a − 1)2 + (c − 1)2 − 1, 1 − a 2 − c2 . The remaining cases can be discussed similarly.

Figure 2. Norm-preserving directions shown.

Figure 2 illustrates the case a = 2, c = −3; the two length-preserving lines are shown. The direction vectors are v1 = 1, −1 and v2 = 4, −3. As expected, the solution lines pass through the intersections of the ellipse Av = 1 with the unit circle. The corresponding picture for the matrix chosen by Robert Lopez was shown in Figure 1; the solutions lines are not depicted, since they are rather close to each other. If the ellipse is tangent to the unit circle, as for example when a = 3, c = −2, we get only one integer solution line. 4. THE 3 × 3 CASE. The 3 × 3 case is considerably more complicated, as well as more interesting. If A is a 3 × 3 real-valued matrix, also regarded as a linear map from R3 to itself, then in general Av2 = 1 is an ellipsoid, in terms of the coordinates of v = x, y, z. As in the 2 × 2 case, we have Av2 = (Av, Av) = (v, Bv), February 2021]

LENGTH-PRESERVING DIRECTIONS

131

where B = At A is a symmetric matrix with nonnegative eigenvalues. The equation for norm-preserving vectors, Av = v, or (v, Bv) = (v, v), is equivalent to the cone (v, (B − I )v) = 0,

(20)

where I is the identity matrix. As in the 2 × 2 case, if we denote the eigenvalues of B by 0 ≤ λ1 ≤ λ2 ≤ λ3 , then there is a solution of (20) if and only if λ 1 ≤ 1 ≤ λ3 ,

(21)

which guarantees a nonempty intersection of the ellipsoid (or degenerate ellipsoid) Bv2 = 1 with the unit sphere v2 = 1. If condition (21) is satisfied, then the cone determined by (20) will pass through this intersection of the ellipsoid and the unit sphere. As an illustration, for the matrix in Example 1 below, Figure 3(a) shows the ellipsoid Av2 = 1 and the unit sphere, and Figure 3(b) has the added solution cone Av = v; compare with Figure 2 for the 2 × 2 case.

Figure 3. Illustration for Example 1: (a) ellipsoid and sphere; (b) same, plus solution cone.

For the 3 × 3 case, however, it is considerably harder to find an expression for condition (21) directly in terms of the entries of A. Instead, we will limit ourselves to discussing several examples that exhibit the various possible outcomes regarding the existence of integer solution lines. Before giving examples, let us add another comment: unlike the 2 × 2 case, in the 3 × 3 case one cannot hope that in general all the lines in the cone (20) for a given matrix A with integer or rational coefficients will turn out to be integer solution lines. Examples 2 and 3 show that, however, we can still get infinitely many such lines. Example 1: No integer solution lines. Let us consider the symmetric matrix ⎛

132

1 ⎝ A= 1

1

1 2

1

1 2

1⎞ 2

1⎠ . 1

c THE MATHEMATICAL ASSOCIATION OF AMERICA 

(22)

[Monthly 128

The form Av2 = (Av, Av) = (v, Bv) will in this case have matrix ⎛9 4

B = At A = A2 = ⎝ 2 2

9 4

⎞ 2 2⎠

2

9 4

2

so that equation (20) will be 5 2 5 5 x + 4xy + 4xz + y 2 + 4yz + z2 = 0. 4 4 4

(23)

This equation has infinitely many real-valued solutions, which constitute the solution cone shown in Figure 3(b). We want to show, however, that there are no integer solution lines, that is, no nontrivial vectors v with integer coordinates such that Av = v. Indeed, (23) is a quadratic equation in z, which we can solve:  39x 2 + 48xy + 39y 2 8 . z = − (x + y) ± 5 5 Therefore, there will be integer solution lines if and only if the discriminant 39x 2 + 48xy + 39y 2 is a perfect square. We now prove this does not happen. Theorem 2. The Diophantine equation 39x 2 + 48xy + 39y 2 = u2

(24)

has no nontrivial solutions, that is, no nonzero integer solutions. Proof. Let x = 2a v and y = 2b w, with a, b nonnegative integers and v, w odd. We may assume that a ≤ b; otherwise, we interchange x and y. Then 39x 2 + 48xy + 39y 2 = 22a (39v 2 + 2b−a 48 vw + 22(b−a) 39 w2 ), and this will be a square if and only if the expression in parentheses is a square. But if b = a this expression is congruent to 2 mod 4, while if b > a this expression is congruent to 3 mod 4, so in either case this is impossible. Example 2: A dense set of integer solution lines. Consider the symmetric matrix ⎛ ⎞ 1 2 2 A = ⎝2 1 2⎠ . (25) 2 2 1 Here ⎛

⎞ 9 8 8 B = At A = A2 = ⎝8 9 8⎠ , 8 8 9 so that equation (20) will be 8x 2 + 16xy + 16xz + 8y 2 + 16yz + 8z2 = 0, February 2021]

LENGTH-PRESERVING DIRECTIONS

133

or (after dividing by 8) (x + y + z)2 = 0.

(26)

In our case, the cone degenerates into the plane x + y + z = 0. We can pick an integer basis, say v1 = 1, 0, −1 and v2 = 0, 1, −1, and obtain every integer normpreserving line as generated by αv1 + βv2 , with integer coefficients α, β such that α 2 + β 2 > 0. This constitutes a dense set of integer solution lines, among all possible solutions in the plane x + y + z = 0. The ellipsoid Av2 = 1 lies inside the unit sphere, and is tangent to it along the intersection of the sphere with the solution plane; Figure 4 depicts the situation.

Figure 4. Solution cone is degenerate.

Example 3: Infinitely many integer solution lines. Finally, let us consider an example when there are still infinitely many integer solution lines, yet we cannot guarantee they are dense in the cone of all solution lines. Consider the matrix ⎛

⎞ 1 2 3 A = ⎝2 1 1⎠ . 1 1 1

(27)

One eigenvalue of A is −1, with eigenvector =−1, 1, 0, which therefore provides one integer solution line. Are there any other such lines? The matrix B = At A is ⎛ ⎞ 6 5 6 B = ⎝5 6 8 ⎠ 6 8 11 and consequently equation (20) becomes 5x 2 + 10xy + 12xz + 5y 2 + 16yz + 10z2 = 0. Solving for x (which provides a slightly shorter answer than solving for z) yields  −20yz − 14z2 6 . x = −y − z ± 5 5 134

c THE MATHEMATICAL ASSOCIATION OF AMERICA 

[Monthly 128

We conclude that there will be integer solutions lines if and only if the discriminant −20yz − 14z2 is a perfect square.2 This leads to the Diophantine equation −20yz − 14z2 = u2 .

(28)

Let us find all integer solutions of (28). As remarked previously, if z = 0 we get back the eigenline corresponding to λ = −1, generated by −1, 1, 0, so let us assume z  = 0. If z is odd, then −20yz − 14z2 ≡ −14 ≡ 2

(mod 4),

and hence cannot be a square. Therefore z must be even, so z = 2a for some integer a. Substituting into (28), we get 8(−5ya − 7a 2 ) = u2 , whence u is divisible by 4. Letting u = 4b and dividing by 8, we obtain a(−5y − 7a) = 2b2 . Letting a = v 2 q, with q square-free, we obtain v 2 q(−5y − 7v 2 q) = 2b2 .

(29)

Denoting for a moment p = −5y − 7v 2 q, the above equation reads as v 2 pq = 2b2 ,

(30)

where q is square-free. This implies that pq is even. If p is even, so p = 2t for some integer t, then (30) becomes v 2 tq = b2 , and it follows that t = qr 2 for some integer r, so that p = 2qr 2 .

(31)

On the other hand, if p is odd, then we must have q = 2s, with s odd; hence (30) is now v 2 ps = b2 , whence p = sr 2 for some integer r, and therefore r 2 q p = sr 2 = r 2 = 2q , 2 2 and we get back expression (31) for p, if we allow r to be an integer or a half-integer. We conclude that −5y − 7v 2 q must be equal to 2qr 2 , for some integer or halfinteger r. Solving for y, we obtain q y = − (7v 2 + 2r 2 ), 5

(32)

where v, q, and 2r are arbitrary integers, subject only to the condition that y be an integer. Moreover, since rational coordinate vectors also determine integer solution lines, we can even drop this additional condition. To find the value of the other variables in terms of (v, q, r), we observe first that z = 2a = 2v 2 q, 2 Notice,

(33)

by the way, that by setting z = 0 we get back the eigenline determined by −1, 1, 0.

February 2021]

LENGTH-PRESERVING DIRECTIONS

135

and that, from (29), we get b = vqr, whence u = 4vqr.

(34)

(We have chosen only the “+” sign for b, since the “±” is recovered when computing the x-value; see (35).) Next, since 1 6 x = −y − z ± u, 5 5

(35)

we get x=

q (2r 2 − 5v 2 ± 4vr). 5

(36)

Equations (35), (32), and (33) provide the coordinates of all possible integer solution lines. Observing, however, that q is a common factor of all three coordinates, and that proportional vectors provide the same solutions, we may just set q = 1, replace r by r/2, and conclude that all solution lines of (28) are given by ⎧ 1 2 ⎪ ⎪ (r − 10v 2 ± 4vr) x= ⎪ ⎪ 10 ⎨ 1 y = − (14v 2 + r 2 ) ⎪ ⎪ 10 ⎪ ⎪ ⎩ z = 2v 2 , where v and r are arbitrary integers. For example, choosing (v, r) = (1, 4) we get the vectors   11 , −3, 2 ∼ 11, −15, 10 and 1, 3, −2; 5 and choosing (v, r) = (1, 1) we obtain   1 3 − , − , 2 ∼ 1, 3, −4 and 2 2



 13 3 − , − , 2 ∼ 13, 15, −20. 10 2

A general method. There is a method for obtaining infinitely many integer solution lines, which can be applied to a general 3 × 3 matrix with integer or rational coefficients; the drawback is that one must know (at least) one nontrivial solution. This is an idea by T. Piezas [5]. Namely, if we know one particular integer solution (y, z, u) = (m, n, p) of the Diophantine equation ay 2 + byz + cz2 = du2 , then a two-parameter family of solutions is given by y = (am + bn)s 2 + 2cnst − cmt 2 , z = −ans 2 + 2amst + (bm + cn)t 2 , u = p(as 2 + bst + ct 2 ), where s and t are arbitrary integers. 136

c THE MATHEMATICAL ASSOCIATION OF AMERICA 

[Monthly 128

For example, for the matrix ⎛

⎞ 1 2 3 A = ⎝3 4 5⎠ , 2 3 4 equation (20) for v = x, y, z is 13x 2 + 40xy + 52xz + 28y 2 + 76yz + 49z2 = 0, which solved with respect to x produces −20y x= − 2z ± 13



36y 2 + 52yz + 39z2 , 13

(37)

so to get integer solutions we need to solve the Diophantine equation 36y 2 + 52yz + 39z2 = u2 .

(38)

Setting z = 0, it is not hard to guess the particular solution (y, z, u) = (m, n, p) = (1, 0, 6). The corresponding two-parameter solution family looks like y = 36s 2 − 39t 2 z = 72st + 52t 2 u = 216s 2 + 312st + 234t 2 .

(39)

Each choice of (s, t) produces two integer solution lines v = x, y, z, using the two x-values provided by (37). For example, for (s, t) = (1, 1) we get   2402 , −3, 124 ∼ −2402, −39, 1612, and −302, −3, 124; − 13 and (s, t) = (1, 2) yields   4976 , −120, 352 ∼ −4976, −1560, 4576, − 13

and

−656, −120, 352.

5. QUESTIONS FOR FURTHER STUDY, APPLICATIONS. •





Unlike the case of eigenpairs, the solution lines to equation (1) are very much dependent on the chosen norm in Rn . It would be interesting to discuss similar solutions for other norms in Euclidean space. We have only grazed the case of a 3 × 3 matrix A. Can we find solvability conditions of (1) in terms of the coefficients of A, as we did in the 2 × 2 case? Can one find nontrivial families of integer matrices A for which (1) has integer solutions? Application to toral automorphisms. Many of the 2 × 2 integer matrices we studied, for example, the subfamily   q +1 q A= (40) q q −1 with q an integer, are symmetric and have determinant −1; therefore, they can be regarded also as linear automorphisms of the (flat) 2-torus, which possess very

February 2021]

LENGTH-PRESERVING DIRECTIONS

137

interesting dynamical properties; see, for example [2, p. 42]. Nontrivial such automorphisms have eigenvectors with irrational slopes; on the other hand, the integer solution lines of (40) bisect the eigendirections. We can therefore use integer arithmetic to compute iterates of vectors in the stable and in the unstable manifolds of such automorphisms. For example, the matrix   3 2 (41) A= 2 1 has integer solution lines generated by v1 = 1, −1 and v2 = −1, 3, and irrational eigenvalues √ √ λ1 = 2 + 5 and λ2 = 2 − 5. If we choose the equal-norm vectors v1 = 1, −1

and

1 1 v3 = √ v2 = √ −1, 3, 5 5

then u = v1 + v3 will be along the unstable direction of A, and w = v1 − v3 will be along the stable direction. Therefore, on the one hand √ An u = λn1 u = (1 + 5)n u, and on the other hand 1 An u = An v1 + √ An v2 . 5 For example,   1346269 832040 A u= u= 832040 514229   1 710647 = 514229 + √ 1149851, 317811 + √ , 5 5 √ provides a way to compute (2 + 5)10 u using only integer arithmetic. A similar calculation can be used for iterates of vectors in the stable direction. 10

ACKNOWLEDGMENTS. I am grateful to Dr. Robert Lopez for introducing the interesting idea of vectors whose norms are preserved by a linear map. I also wish to thank the Editorial Board member for valuable comments, corrections, and suggestions that were used to significantly improve the overall quality of the paper. This applies, especially, to a shorter and more conceptual proof of Theorem 2, and to a complete solution of the Diophantine equation (28).

ORCID Juan Tolosa

http://orcid.org/0000-0001-9785-8238

REFERENCES [1] Gel’fand, I. M. (1989). Lectures on Linear Algebra. New York: Dover Publications. [2] Katok, A., Hasselblatt, B. (1995). Introduction to the Modern Theory of Dynamical Systems. New York: Cambridge Univ. Press.

138

c THE MATHEMATICAL ASSOCIATION OF AMERICA 

[Monthly 128

[3] Lopez, R. (2015). Eigenpairs in Maple. www.maplesoft.com/webinars/recorded/featured.aspx?id=1181 [4] Shilov, G. E. (1977). Linear Algebra. New York: Dover Publications. [5] Weisstein, E. W. (2019). Diophantine equation—2nd powers. MathWorld—A Wolfram Web Resource. mathworld.wolfram.com/DiophantineEquation2ndPowers.html JUAN TOLOSA received his Ph.D. in mathematics from Patrice Lumumba University, Moscow, Russia. He taught at the Universidad de la Rep´ublica, Montevideo, Uruguay, at the Universidad Sim´on Bol´ıvar, Caracas, Venezuela, and held a visiting position at the University of California, Berkeley, before joining the faculty at Stockton University. Stockton University, 101 Vera King Farris Drive, Galloway, NJ 08205. [email protected]

100 Years Ago This Month in The American Mathematical Monthly Edited by Vadim Ponomarenko Dr. L. A. Pochhammer [of the eponymous symbol —Eds.], ordinary professor of mathematics at the University of Kiel for forty-three years, died on March 24, 1920, at the age of seventy-eight years. He was appointed extraordinary professor at Kiel in 1874, and was the author of a number of papers in Mathematische Annalen and Crelle’s Journal. —Excerpted from “Notes and News” (1921). 28(2): 97.

February 2021]

LENGTH-PRESERVING DIRECTIONS

139

Solution of an Odds Inversion Problem Robert K. Moniot Abstract. “From a bag containing red and blue balls, two are removed at random. The chances are 50-50 that they will differ in color. What were the possible numbers of balls initially in the bag?” This problem appeared in the National Museum of Mathematics’ Varsity Math puzzle, week 117. It is quite easy to solve, but what if we generalize to arbitrary odds? In this article, we characterize the solutions of the general case. We show that for most odds values that are at most 50-50, there is an infinite number of solutions, while for a certain well-defined class of odds below 50-50 and for any odds greater than 50-50, the number of solutions is zero or finite. We also explore some other interesting and surprising properties of this problem.

1. INTRODUCTION. Given a bag containing known numbers of red and blue balls, we can easily calculate the odds that two balls drawn at random will be different colors. But suppose we invert this problem, and ask what must be the numbers of balls of each color so that the odds are some chosen value between nil and certainty. This problem, for the special case of 50-50 odds, appeared in the Varsity Math puzzle feature of the National Museum of Mathematics in New York City [4]. The author of that puzzle is Dick Hess of the museum staff [1]. Here we solve the problem for arbitrary odds. 2. PRELIMINARIES. Let x and y be the number of red and blue balls, respectively, in the bag. The probability of drawing out two balls of different colors is a rational number, which we write as p/q in lowest terms. Then we have 2xy p = . q (x + y)(x + y − 1)

(1)

Our goal is to invert this equation to find integer values of x and y that will yield the given value p/q. Provided there are at least 2 balls in the bag, we can rearrange (1) as the quadratic Diophantine equation px 2 − 2(q − p)xy + py 2 − px − py = 0.

(2)

In order to be admissible as solutions to the original problem, solutions to this equation must satisfy x ≥ 0, y ≥ 0, and x + y ≥ 2. Symmetry. Equation (2) is symmetric in x and y, so given a solution (x, y), then (y, x) is also a solution. In what follows, we will often impose the condition that x ≤ y to ensure the solutions are distinct. Odds of 50-50. We can deal with the Varsity Math puzzle quickly. Setting p = 1 and q = 2 and rearranging, (2) becomes x 2 − 2xy + y 2 = y + x.

(3)

doi.org/10.1080/00029890.2021.1851572 MSC: 11D09 (c) 2021 The Author(s). Published with license by Taylor & Francis Group, LLC. This is an Open Access article distributed under the terms of the Creative Commons AttributionNonCommercial-NoDerivatives License (http://creativecommons.org/licenses/by-nc-nd/4.0), which permits non-commerial re-use, distribution, and reproduction in any medium, provided the original work is properly cited, and is not altered, transformed, or built upon in any way.

140

c THE MATHEMATICAL ASSOCIATION OF AMERICA 

[Monthly 128

The left-hand side is (y − x)2 . Let y − x = v; then y + x = v 2 . Solving and assuming x ≤ y, we obtain x=

v(v − 1) , 2

y=

v(v + 1) . 2

This shows that x and y are successive triangular numbers. Their sum, the total number of balls, is a square. The number of solutions is infinite, with a unique solution (up to ordering of x, y) corresponding to each integer value of v > 1. Trivial solutions. Transforming (1) to obtain (2) requires the denominator of the right-hand side of (1) to be nonzero. There are three solutions of (2) that violate this assumption, namely (x, y) = (0, 0), (0, 1), and (1, 0). They satisfy (2) for any values of p and q. These trivial solutions yield an undefined value 0/0 for the probability in (1). While these are not admissible as solutions to the problem (since there are not two balls to draw), they will prove useful in obtaining admissible solutions and in proving some results. If p = 0, the odds of drawing different-color balls are nil, which can only be the case if all the balls are the same color, i.e., x = 0 or y = 0, and the other color any integer greater than 1. Hereafter we will assume p > 0. Some examples. As a way of getting acquainted with the problem, we can find solutions of (2) by inserting various values of x and y into (1) and calculating the corresponding values of p/q. Here are some arbitrarily chosen examples from such a search using values of x and y less than 1000, and selecting ratios with p and q in single or double digits. In each case, all the distinct solutions found by the search are shown. 1/5 : 2/5 : 3/5 : 7/16 : 7/18 : 9/22 : 8/15 : 7/13 : 4/7 :

(1, 9) (1, 4) (2, 3) (310, 651) (2, 7) (3, 9) (2, 4) (6, 7) (3, 4)

(9, 72) (4, 12) (3, 3)

(72, 568) (12, 33)

(33, 88)

(88, 232)

(7, 21) (9, 24) (4, 6) (7, 7) (4, 4)

(21, 60) (50, 126) (7, 8)

(95, 266) (126, 315) (8, 8)

(266, 742) (315, 785)

(232, 609)

An interesting pattern in the solutions of (2) in the preceding table is that for a given p/q they often occur in sequences in which the larger number of balls in one solution reappears as the smaller number of balls in the next larger solution. The Varsity Math case exhibits this pattern continuing indefinitely, with solutions being successive triangular numbers. The ratio 2/5 is another example where the pattern continues indefinitely. The table above is too limited to show clearly that in many other cases these sequences form triplets of solutions. Here is an example: p/q = 5/11, for which the smallest nine admissible solutions of (2) are (7, 15) (184, 345) (3718, 6930)

(15, 30) (345, 645) (6930, 12915)

(30, 58) (645, 1204) (12915, 24067)

For some ratios, like this one, all solutions are members of triplets that follow this pattern. Below we shall see a reason for their appearance. But not all solutions appear in such triplets; for instance, for the ratio 9/22 the first two solutions form a doublet. February 2021]

ODDS INVERSION

141

It is also interesting to note that some ratios with small p and q do not appear in the results of this search, for instance, 7/17, 4/9, and 4/5. We shall see that there is a different reason for each of these three ratios’ nonappearance. A “recycling” recurrence. As noted in the previous section, often solutions for a given p/q occur in a sequence where a value in one solution reappears in the next. We can obtain a recurrence to generate the solutions in such sequences. Assuming that the probability of drawing different colors for (xi , yi ) is the same as for (xi+1 , yi+1 ) with xi+1 = yi and yi+1  = xi , inserting these into (1), and equating the two expressions for the odds (assuming all three numbers are nonzero), one obtains the recurrence xi+1 = yi ,

yi+1 =

yi (yi − 1) . xi

Because one of the values in one solution is re-used in the next, I call this the “recycling recurrence” to distinguish it from other recurrences that can be obtained for the solutions of (2). It is not guaranteed to yield integer values ad infinitum, and, in fact, except for certain special categories, the values it yields become fractional after a few iterations. For example, for the probability 7/18, the table above shows three solutions (2, 7), (7, 21), and (21, 60), but the next value given by the recycling recurrence is (60, 1180/7). If yi − 1 > xi then yi+1 > yi , meaning the recurrence advances to a larger solution. Swapping xi and yi runs the recurrence in reverse. A special case. There is a class of probability values for which solutions are readily found, namely when p = 1 or p = 2. One can easily verify by substitution into (1) that if p = 1, then the smallest solution is (1, 2q − 1), while if p = 2, the smallest solution is (1, q − 1). We can also show that for p = 1 or p = 2 the recycling recurrence always gives integer solutions. This requires that each x divide y(y − 1). But from (1), p(x + y)(x + y − 1) = 2qxy, and so whether p = 1 or p = 2, x must divide (x + y)(x + y − 1), which implies that it divides y(y − 1). And for p/q ≤ 1/2, the recycling recurrence continues to yield admissible solutions indefinitely. The proof is deferred to the next section. 3. GENERAL SOLUTION. Change of variables. For solving the general case, it is useful to make a change of variables. Let t = y + x and v = y − x. Then (2) becomes (q − 2p)t 2 + 2pt − qv 2 = 0.

(4)

The case p/q = 1/2 is the Varsity Math problem, (3), which we solved above. Otherwise, q − 2p  = 0, and we can eliminate the linear term by completing the square. Multiply (4) by q − 2p to make the coefficient of t square, and add p2 to both sides. This yields ((q − 2p)t)2 + 2p(q − 2p)t + p 2 − q(q − 2p)v 2 = p 2 , or ((q − 2p)t + p)2 − q(q − 2p)v 2 = p 2 .

(5)

Let u = (q − 2p)t + p 142

c THE MATHEMATICAL ASSOCIATION OF AMERICA 

[Monthly 128

and D = q(q − 2p). Then (5) becomes u2 − Dv 2 = p 2 .

(6)

Both u and v may be of either sign. Different signs of u yield distinct solutions (x, y), while v < 0 yields the same solution as for v > 0 except with the order of (x, y) reversed. We note that the trivial solution (x, y) = (0, 0) corresponds to (u, v) = (p, 0), while the other two trivial solutions (x, y) = (0, 1) and (1, 0) correspond to (u, v) = (q − p, ±1). These satisfy (6) for all values of p and q. Changing the sign of u yields three more solutions of (6), but we will see below that, except for a special class of probabilities, they do not yield admissible solutions of (2). Categorizing the solutions. The nature of (6) depends on the sign of D. If D > 0, i.e., p/q < 1/2, then the equation is a hyperbola, and may potentially have an infinite number of solutions. If D < 0, i.e., p/q > 1/2, it is an ellipse, and can have at most a finite number of solutions. The case D = 0 corresponds to p/q = 1/2, the Varsity Math case solved above. The change of variables to u, v breaks down in this case, and (4) is a parabola. (Since the transformation of variables from (2) to (4) and (6) is linear, all three equations are the same category of conic.) Recycling recurrence revisited. Above we noted that if y − 1 > x, the recycling recurrence yields a larger solution, but this does not guarantee that it will continue to do so. We can now see that if (2) is elliptical, solutions generated by this recurrence cannot increase indefinitely, since they must all fall on the finite ellipse. Only if the equation is parabolic or hyperbolic can solutions increase indefinitely. We can show that in fact they do. From (1), for 1 ≤ x ≤ y, the requirement that p/q ≤ 1/2 corresponds to  √ 1 1 + 1 + 8x . (7) y≥x+ 2 The radical is greater than 1, which ensures that y − 1 > x, as required for the next solution to be larger. And since the recycling recurrence preserves p/q, the next solution will also satisfy (7), guaranteeing that the increase will continue. Combining this result with the fact shown earlier that, for p = 1 or p = 2, the recycling recurrence always yields integers, we conclude that the recurrence generates admissible solutions, starting from the smallest nontrivial solution, ad infinitum if p = 1 or p = 2 and p/q ≤ 1/2. For p > 2 the proof that the iterates of the recycling recurrence are integer does not hold. I do not have a proof that in this case the recycling recurrence iterates always become fractional after a few steps, but I have not observed any examples having more than just a few successive integer iterates. Elliptical case. When p/q > 1/2, D < 0 and the equation is an ellipse, so the solution space is bounded. We now look at ways to find solutions when they exist, and also at ways to rule out the existence of solutions. Character of the ellipse. The ellipse (6) is a unit circle for p/q = 1, and elongates as p/q approaches 1/2 from above. This is shown in Figure 1. February 2021]

ODDS INVERSION

143

Figure 1. Family of ellipses defined by (2) for ratios of the form p/(2p − 1).

Direct search. Searching by testing all values of v turns out to be surprisingly efficient up to fairly large solution sizes. In (6), the maximum value of v occurs when u = 0, so |v| ≤ √

p/q p . =√ 2p/q − 1 q(2p − q)

Supposing the probability is quite close to 1/2, let p/q = 1/2 + ; then asymptotically for small , 1 vmax ≈ √ , 2 2 so vmax grows only as  −1/2 . For instance, if p = 106 + 1 and q = 2 × 106 , then  = 5 × 10−7 , and the maximum number of balls is approximately 106 but the number of values of v to search is only 500. Solutions involving even 1012 balls are in range for a modest personal computer to find in a few minutes of computing time. Cases that always have solutions. There is a class of probability ratios in the elliptical regime, namely those of the form p/(2p − 1), for which solutions always exist. As mentioned earlier, the trivial solutions in (x, y)-space convert to (u, v) = (p, 0) and (q − p, ±1). But −u also satisfies (6). Negating u in these three trivial solutions and mapping back to (x, y)-space yields three other points at the opposite end of the ellipse, furthest from the origin, symmetric counterparts to the three trivial solutions around the origin. The point furthest from the origin has x = y = p/(2p − q), which is integer and positive if and only if q = 2p − 1, in which case the three solutions are (p, p), (p − 1, p), and (p, p − 1). Other solutions may also exist for ratios of this form, for example for the ratio 8/15 in the table above. Bounds on p and q. We can rule out the existence of solutions for p/q ratios in the elliptical regime in which p or q individually exceed bounds calculated as follows. 144

c THE MATHEMATICAL ASSOCIATION OF AMERICA 

[Monthly 128

In (1), the factor of 2 in the numerator always divides the denominator, so we have p ≤ xy and q ≤ 12 (x + y)(x + y − 1). (Cancellation of common factors may reduce p and q further.) These expressions are maximized at the far end of the ellipse, where x = y = p/(2p − q). Thus we have bounds z2 z , q≤ 2 (2z − 1) (2z − 1)2 where z = p/q. Ratios in lowest terms violating these inequalities can be excluded a priori. For example, there cannot be a solution for p/q = 200/381 because p exceeds the bound of 110 for this ratio. p≤

Exhaustive enumeration. It was noted earlier that as p/q increases towards 1, the ellipse (2) shrinks. This means that for p/q above a chosen threshold, one can enumerate all solutions. For instance, the probability ratio for (x, y) = (5, 5) is p/q = 5/9. For probabilities greater than or equal to this, all solutions must have x and y at most 5. Calculating the probabilities given by (1) for all pairs of integers 1 ≤ x ≤ y ≤ 5 and excluding those below the threshold, we find the complete set of solutions: 5/9 : 4/7 : 3/5 : 2/3 : 1/1 :

(4, 5), (3, 4), (2, 3), (1, 2), (1, 1)

(5, 5) (4, 4) (3, 3) (2, 2)

No other probabilities p/q ≥ 5/9 give solutions. The paucity of solutions for p/q > 1/2 reflects the fact that it is harder to make it likely that the balls differ in color than that they be the same. This result provides the explanation for the absence of 4/5 from the search results described in the “Some examples” section. It exceeds 5/9 and is not in the above list. Hyperbolic case. When p/q < 1/2, D > 0 and (6) is a hyperbola. In this case, u < 0 yields negative x, y. Since admissible x, y must be positive, u must be as well. A family of hyperbolic cases with q = 2p + 1 is plotted in Figure 2. As the ratios decrease, the asymptotes move closer to the coordinate axes and the two branches approach each other near the origin, the curves becoming identical with the coordinate axes when p/q = 0. As the ratios increase towards 1/2, the hyperbola narrows and the two branches move apart, becoming a parabola at p/q = 1/2. Solving the hyperbolic case completely is fairly complicated. We will limit ourselves to showing that there can be at most a finite number of solutions if D is square, and that for all cases where D is nonsquare, the number of admissible solutions is infinite. We will also find the explanation for the occurrence of triplets of solutions related by the recycling recurrence. Case where D is square. If D is square, then the left side of (6) factors, and we have √ √ (8) (u − Dv)(u + Dv) = p 2 , √ where D is an integer by assumption. This equation represents a factorization of p 2 . The method of solution is therefore to obtain the list of divisors di of p 2 , i = 1, . . . , n. For each di , equate one of the factors in (8) to di and the other to p 2 /di . This gives two linear equations in the two unknowns u, v. It suffices to search only 1 ≤ di ≤ p. Solutions that do not yield admissible values of x, y are discarded. The total number of solutions for any given probability value is finite, at most n/2 , and there may be no solutions other than the trivial ones. February 2021]

ODDS INVERSION

145

Figure 2. Family of hyperbolas defined by (2) for ratios of the form p/(2p + 1).

This is the explanation for the absence of 4/9 from the search results as mentioned in the section “Some examples.” For this case D = 9 is a square, and none of the solutions found by solving (8) turn out to be admissible. For p/q = 12/25, D = 25, and p 2 has 15 divisors, but there is only one distinct admissible solution (9, 16). Case where D is nonsquare. We can show that for D > 0 nonsquare, an infinite number of solutions of (2) always exists. Dividing (6) by p 2 and setting r = u/p and s = v/p transforms the equation into r 2 − Ds 2 = 1.

(9)

This is the well-known Pell equation, and for D > 0 nonsquare, it always has an infinite number of integer solutions. These can be found using the method of continued fractions [2]. However, because the mapping from u to t involves division by q − 2p and the mapping from (t, v) to (x, y) involves division by 2, it is not in general guaranteed that the solutions to (9) will yield admissible solutions to the original problem. In fact, in many cases, the smallest Pell solutions do not yield admissible (x, y). But we can show that the next larger solution will always be admissible. As an example, for p/q = 4/11, D = 33 and solving the Pell equation (9) yields, as the first nontrivial solution, (r, s) = (23, 4) which implies (u, v) = (92, 16). This yields the inadmissible t = 88/3. The next larger solution of (9) is (r, s) = (1057, 184), giving (u, v) = (4228, 736), (t, v) = (1408, 736), and the admissible (x, y) = (336, 1072). To show that admissible (x, y) always occurs for the second solution, we need to develop a recurrence for the solutions of (6). Let (r, s) be the fundamental solution to the Pell equation (9), defined as the solution for which r and s are positive and minimal. All positive solutions of (9) are then given (see [2]) by equating rational and irrational parts on each side of √ √ (rn + sn D) = (r + s D)n , n ∈ N. (10) 146

c THE MATHEMATICAL ASSOCIATION OF AMERICA 

[Monthly 128

From this it follows that if (u, v) is a solution of (6), then (u , v ) satisfying √ √ √ u + v D = (u + v D)(r + s D) is also a solution. This leads to the recurrence un+1 = run + Dsvn ,

vn+1 = sun + rvn .

(11)

I will call (11) the “Pell recurrence” since it is derived from the Pell equation, although it can also be used on solutions that were not obtained from the Pell equation. Now suppose (xn , yn ) is an integer solution of (2). Transforming it to (un , vn ) and applying two iterations of (11) yields, after simplication, un+2 = (r 2 + Ds 2 ) [p + (q − 2p)(xn + yn )] − 2Drs(xn − yn ), vn+2 = 2rs [p + (q − 2p)(xn + yn )] − (r 2 + Ds 2 )(xn − yn ). Transforming this back to (xn+2 , yn+2 ) yields expressions with a term q − 2p in the denominator. Substituting r 2 = 1 + Ds 2 and using D = q(q − 2p) provides the necessary factor to cancel that term, and we obtain xn+2 = xn + s 2 q [p + 2(q − 2p)xn ] + rs [p(2(xn + yn ) − 1) − 2qxn ] , yn+2 = yn + s 2 q [p + 2(q − 2p)yn ] − rs [p(2(xn + yn ) − 1) − 2qyn ] . Both of these expressions are integer in form. It is clear from (11) that starting with all quantities positive gives un+2 also positive, ensuring that xn+2 and yn+2 are positive. Therefore they are admissible solutions of (2). Observe that inserting (u1 , v1 ) = (p, 0), corresponding to the trivial solution (x1 , y1 ) = (0, 0), into the Pell recurrence yields (u2 , v2 ) = (pr, ps), which is the first nontrivial solution given by the Pell equation. Since the trivial solution is integer, the second solution from the Pell iteration will be admissible. Continuing the recurrence therefore will yield infinitely many admissible solutions of (2), on at least every other iteration. We can now see the reason for the nonappearance of a solution for the case p/q = 7/17 mentioned in the section “Some examples.” For this ratio D = 51, which is nonsquare, so this example does indeed have admissible solutions, but the smallest solution is (x, y) = (1380, 3381), which is simply outside of the region x < 1000, y < 1000 used for our search. Trivial solutions generate solutions related by recycling recurrence. For all probabilities p/q < 1/2 and D nonsquare, there are always triplets of solutions related by the recycling recurrence. An example, p/q = 5/11, was shown earlier. For ratios having p = 1 or p = 2, successive sets of triplets are contiguous, i.e., the recycling recurrence takes the last member of one triplet to the first member of the next, forming an unbroken recycling sequence. But for p > 2 the triplets are isolated from one another as in this example. These triplets turn out to be produced from the three trivial solutions by the Pell recurrence (11), and there are infinitely many of them as we shall now see. As seen in the previous section, applying the Pell recurrence to the trivial solution (x, y) = (0, 0) yields solutions corresponding to those obtained from the solutions of the Pell equation. The other two trivial solutions (x, y) = (0, 1) and (1, 0) correspond to (u, v) = (q − p, ±1). These are not divisible by p if p > 1, and so do not map to solutions of the Pell equation. Although these trivial solutions are not themselves admissible, applying the Pell recurrence to them yields other solutions that are admissible. The three solutions generated this way from the trivial solutions form a February 2021]

ODDS INVERSION

147

recycling triplet. The proof of that fact is lengthy and is omitted. The solution arising from (x1 , y1 ) = (1, 0) is the smallest member of the triplet, that from (0, 0) is the middle member, and the one from (0, 1) is the largest. The three solutions obtained this way from the trivial solutions are not necessarily integer. But above we showed that starting with integer (x1 , y1 ) yields integer solutions at least on every other iteration of the Pell recurrence. The trivial solutions are integer. Hence as the Pell recurrence is applied repeatedly to obtain further triplets, integer solutions will be generated without limit. Furthermore, it can be shown that if any two solutions of (2) are related by the recycling recurrence, then the solutions obtained from them via the Pell recurrence are also related by the recycling recurrence. As an example, we obtain the solutions for the case p/q = 5/11. Here D = 11, and the solution to the Pell equation (9) is (r, s) = (10, 3). Inserting the solutions (u, v) = (6, −1), (5, 0), and (6, 1), corresponding to the trivial solutions (x, y) = (1, 0), (0, 0), and (0, 1), respectively, into the Pell recurrence (10) yields (u, v) = (27, 8), (50, 15), and (93, 28), respectively. These map to (x, y) = (7, 15), (15, 30), and (30, 58) as in the first row of the table for this example in the section “Some examples.” Repeating the Pell recurrence generates the next rows. Completeness of solutions. For hyperbolic cases with p = 1, (6) is the Pell equation, for which all positive solutions are generated by (10). For p = 2, [2] provides a similar recurrence that also generates all solutions. It can be shown that in both cases, the method described earlier of applying the recycling recurrence to the starting solutions (1, 2q − 1) or (1, q − 1), respectively, generates the same solutions. For p > 2 we saw that solutions can be generated by applying the Pell recurrence to the three trivial solutions. However, this method is, in general, not complete. For instance, in the section “Some examples,” the case 9/22 has a pair of solutions (3, 9) and (9, 24) that are not part of a recycling triplet. These therefore cannot be generated from the trivial solutions via the Pell recurrence. Hua [2] and Nagell [3], among others, provide methods that are capable of finding all solutions of (6) for the hyperbolic case. The interested reader is referred to those. 4. CONCLUSION. The problem of finding x and y to yield a given probability in (1) has turned into the problem of solving the Diophantine equation (6), which is closely related to the well-studied Pell equation (9). We presented some methods for finding solutions, or for ruling them out. Results. For probability ratios p/q > 1/2, there are at most finitely many solutions of (2) for each case. For many ratios in this range, there are no solutions. The density of ratios for which there are solutions decreases dramatically as the ratios increase toward 1: only five ratios in the range 5/9 to 1 yield solutions. This reflects the fact that it is difficult to arrange for the two balls to be highly likely to differ in color unless the number of balls is very small. For probability ratios p/q < 1/2 having D = q(q − 2p) square, the number of solutions is finite, and many cases have no solution. This does not seem to have a physical explanation, but simply reflects the constraints of having a finite number of factors of p2 to work with. For probability ratios p/q ≤ 1/2, and having D nonsquare, there are always an infinite number of solutions. This reflects the fact that the balls are likely to be the same color if the number of balls of one color is much smaller than the other, which can be achieved in many ways. Furthermore, there are always “recycling” triplets of solutions, i.e., triplets in which a number in one member of the triplet reappears in another 148

c THE MATHEMATICAL ASSOCIATION OF AMERICA 

[Monthly 128

member. These triplets arise from the three trivial solutions of (2) via a recurrence based on the solution of the Pell equation. Open questions. The problem is essentially solved, but there remain some interesting questions that could be pursued. Are there only singlets, doublets, and triplets, but not quadruplets? In all hyperbolic cases with nonsquare D and p > 2, admissible solutions occur in doublets and triplets of solutions that are related to each other via the recycling relationship, as well as singlets that have no such relationship to another solution. I have not encountered any examples with larger tuples, but I do not have a proof that three is the maximum. These relationships are preserved in successive generations of the Pell recurrence. That is, singlets give rise to singlets, doublets to doublets, and triplets to triplets. Therefore, it would suffice to prove the hypothesis for the smallest solutions. Are there more special cases? While exploring this problem, I discovered some special cases that have predictable solutions. For instance, we saw above that probability ratios of the form p/(2p − 1) (elliptical regime) always have solutions at the opposite end of the ellipse from the trivial solutions, namely at (p, p) and (p − 1, p). If furthermore p = 2k 2 , where k is any positive integer, then there are solutions near the middle part of the ellipse as well, of the form (k 2 , k 2 ± k). If p = (k 2 − 1)(k 2 − 4)/4 where k is an integer greater than 2, and q = 2p + 1 (hyperbolic regime), then p and q are relatively prime integers, and there is always a solution (k(k − 1)/2 − 1, k(k + 1)/2 − 1). Interestingly, the two values are successive triangular numbers less 1, an echo of the Varsity Math solutions. There is also a pair of solutions in each of which one value equals p, namely (p − k 2 + 4, p) and (p, p + k 2 − 1). For instance, for k = 4, p/q = 45/91, for which (2) has solutions (5, 9), (33, 45), and (45, 60). No doubt there are other families of special cases waiting to be discovered. ACKNOWLEDGMENTS. The author thanks the National Museum of Mathematics for their Varsity Math puzzles, and Dick Hess in particular for creating the puzzle that was the starting point for this work.

ORCID Robert K. Moniot

http://orcid.org/0000-0002-8702-777X

REFERENCES [1] Hess, D. (2018). Private communication. [2] Hua, L. (1982). Introduction to Number Theory. (Shiu, P., trans.) Berlin-Heidelberg-New York: SpringerVerlag. [3] Nagell, T. (1964). Introduction to Number Theory, 2nd ed. New York: Chelsea Publishing Co. [4] National Museum of Mathematics in New York City (2017). Varsity Math, Week 117. momath.org/home/ varsity-math/varsity-math-week-117/ ROBERT K. MONIOT received his Ph.D. in physics from the University of California, Berkeley, and subsequently a M.S. in computer science from New York University. He received the Mathematical Association of America’s Trevor Evans Award in 2008. Department of Computer & Information Science, Fordham University, New York City, NY 10023 [email protected]

February 2021]

ODDS INVERSION

149

A Cauchy–Schwarz Type Inequality for Differences Theorem. Let u1 , u2 , . . . , un and w1 , w2 , . . . , wn be real numbers satisfying ui ≥ wi ≥ 0 for i = 1, 2, . . . , n. Then  2  n 2  n n       2 2 ui − wi ≤ ui − wi . i=1

i=1

i=1

Proof. Let a, b be real numbers with a ≥ b ≥ 0. We can verify the algebraic identity (a 2 − b2 )(u2i − wi2 ) + (bui − awi )2 = (aui − bwi )2 . Since (bui − awi )2 ≥ 0, in fact (a 2 − b2 )(u2i − wi2 ) ≤ (aui − bwi )2 . Since a ≥ b ≥ 0 and ui ≥ wi ≥ 0, we may take square roots, getting

 a 2 − b2 u2i − wi2 ≤ aui − bwi .

We now sum over i = 1, 2, . . . , n and set a =

n 

ui , b =

i=1



a 2 − b2

n 

wi . This gives

i=1

n   u2i − wi2 ≤ a 2 − b2 . i=1

—Submitted by Reza Farhadian , Lorestan University and Vadim Ponomarenko, San Diego State University ORCID Reza Farhadian

http://orcid.org/0000-0003-4027-9838

doi.org/10.1080/00029890.2021.1845554 MSC: Primary 26D15

150

c THE MATHEMATICAL ASSOCIATION OF AMERICA 

[Monthly 128

(Re)constructing Code Loops Ben Nagy and David Michael Roberts

Abstract. The Moufang loop named for Richard Parker is a central extension of the extended binary Golay code. It the prototypical example of a general class of nonassociative structures known today as code loops, which have been studied from a number of different algebraic and combinatorial perspectives. This expository article aims to highlight an experimental approach to computing in code loops, by a combination of a small amount of precomputed information and making use of the rich identities that code loops’ twisted cocycles satisfy. As a byproduct we demonstrate that one can reconstruct the multiplication in Parker’s loop from a mere fragment of its twisted cocycle. We also give relatively large subspaces of the Golay code over which Parker’s loop splits as a direct product.

1. INTRODUCTION. Associativity is one of the standard axioms for groups, along with inverses and the identity element. At first it can be difficult to imagine what algebraic structures could be like that are not associative. However, we are all familiar with 2 2 the nonassociative operation of exponentiation: (23 )  = 2(3 ) , for example. But exponentiation is an ill-behaved binary operation, with neither (a two-sided) inverse nor identity element, hence very much unlike a group. One class of nonassociative structures as close to being a group as possible are Moufang loops, which are more or less “groups without full associativity,” having an identity element and two-sided inverses. This article is concerned with a special class of Moufang loops now known as code loops, which have curious connections to sporadic finite simple groups [4], [9, §7]. In particular, we consider in detail a Moufang loop P , introduced by Richard Parker, in unpublished work in the early 1980s, as the exemplar of a class of loops later shown to be equivalent to code loops [8]. An early example of a code loop, though not identified as such, appeared in Coxeter’s work on integral octonions [6] (see, e.g., [9, §2] for details), but the most striking appearance was the use of Parker’s loop P as part of John Conway’s construction of the Monster sporadic simple group [4]. A general study of loops of this type was subsequently made by Robert Griess [8], who named them, based on the fact that they can be built from doubly even binary codes. For example, Parker’s loop P is then constructed by starting with the famous extended Golay code. Griess also proved the existence of code loops by an algorithmic construction, which we adopt below. (More recent approaches will be discussed in Section 6.) The data required to describe a code loop is a function θ : C × C → F2 , where F2 = {0, 1} is the field with two elements, and C ⊂ (F2 )n is a doubly-even binary code—a subspace with a particular property that we recall below. The function θ must then satisfy a number of identities that use this property. For the sake of terminology, we refer to the elements of F2 as bits, and θ is called a twisted cocycle. Note, however, that both Conway’s and Griess’s treatment of Parker’s loop is rather implicit, merely using the properties of θ, not examining its structure. The point of the present article is to give a concrete and efficient approach to code loops in general, and Parker’s loop in particular—the latter especially so, given its use in constructing the Monster group. doi.org/10.1080/00029890.2021.1852047 MSC: Primary 20N05, Secondary 20B40; 20G10 Supplemental data for this article can be accessed on the publisher’s website.

February 2021]

RECONSTRUCTING CODE LOOPS

151

Recall that the elements (or words) in a code C , being vectors, can be combined by addition—this is a group operation and hence associative. The elements of a code loop consist of a pair: a code word and one extra bit. The extra bit, together with θ, twists the addition so that the binary operation  in the code loop is a nonassociative operation: (x  y)  z  = x  (y  z) in general. While addition of words in a code is performed by coordinate-wise addition in F2 (that is, bitwise XOR), the algebraic operation in a code loop is not easily described in such an explicit way—unless one has complete knowledge of the function θ. It is the computation and presentation of such twisted cocycles that will mainly concern us in this article, using Griess’s method [8, proof of Theorem 10]. As a result, we will observe some curious features of Parker’s loop, obtained via experimentation and, it seems, previously unknown. The function θ can be thought of as a table of bits, or even as a square image built from black and white pixels, with rows and columns indexed by elements of C . One of the main results given here is that θ can be reconstructed from a much smaller subset of its values. If dim C = 2k, then while θ is a table of (22k )2 values, we need only store roughly 22k values, and the rest can be reconstructed from equation (6) in Lemma 2. For Parker’s loop this means that instead of storing a multiplication table with approximately 67 million entries, one only need store a 128 × 128 table of bits. This table, given in Figure 3, exhibits several structural regularities that simplify matters further. We begin the article with a treatment that (re)constructs a small nonabelian finite group using a cocycle on a 2-dimensional F2 -vector space. This will exhibit the technique we will use to construct code loops, in the setting of undergraduate algebra. 2. EXTENSIONS AND COCYCLES. Recall that the quaternion group Q8 , usually introduced in a first course in group theory, is the multiplicative group consisting of the positive and negative basis quaternions: Q8 = {1, i, j, k, −1, −i, −j, −k}. The elements of Q8 satisfy the identities i 2 = j 2 = k 2 = −1,

ij = k.

There is a surjective group homomorphism π : Q8 → F2 × F2 =: V4 (the Klein 4-group), sending i to (1, 0) and j to (0, 1), and the kernel of π is the subgroup ({1, −1}, ×)  (F2 , +). Moreover, this kernel is the center of Q8 , the set of all elements that commute with every other element of the group. This makes Q8 an example of a central extension: F2 → Q8 → V4 . Now Q8 is a nonabelian group, but both F2 and V4 are abelian. One might think that it shouldn’t be possible to reconstruct Q8 from the latter two groups, but it is! That is, if we are given some extra information that uses only the two abelian groups. There is a function s : V4 → Q8 , called a section, defined by (0, 0)  → 1

(1, 0)  → i

(0, 1)  → j

(1, 1)  → k.

This almost looks like a group homomorphism, but it is not, as (1, 0) + (1, 0) = (0, 0) in V , but s(1, 0)s(1, 0) = i 2  = 1 = s(0, 0) in Q8 . We can actually measure the failure of s to be a group homomorphism by considering the two-variable function d : V4 × V4 → F2 152

c THE MATHEMATICAL ASSOCIATION OF AMERICA 

[Monthly 128

defined by (−1)d(v,w) = s(v)s(w)s(v + w)−1 . This function is called a cocycle, or more properly a 2-cocycle (for a treatment of the general theory, see, e.g., [1], and Chapter IV in particular). It is a nice exercise to see that s(v)s(w)s(v + w)−1 is always ±1, so that this definition makes sense. The values of d(v, w) are given as v\w 00 10 01 11

00 0 0 0 0

10 0 1 0 1

01 0 1 1 0

11 0 0 1 1

where we write 00 for (0, 0), 10 for (1, 0), and so on. Clearly, if s were a homomorphism, d would be the zero function. One can check that d satisfies the cocycle identities d(v, w) − d(u + v, w) + d(u, v + w) − d(u, v) = 0

(1)

for all triples u, v, w ∈ V4 . It is also immediate from the definition that d(0, 0) = 0. An alternative visualization is given in Figure 1.

Figure 1. A 4 × 4 array giving the values of the cocycle d : V4 × V4 → F2 , with white = 0, black = 1. The order of the row/column labels is 00, 10, 01, 11.

The reason for this somewhat mysterious construction is that we can build a bijection of sets using s and the group isomorphism F2  {1, −1}, namely the composite φ : F2 × V4  ({1} × V4 ) ∪ ({−1} × V4 ) → {1, i, j, k} ∪ {−1, −i, −j, −k} = Q8 . Now, if we define a new product operation using the cocycle d on the underlying set of F2 × V4 by (s, v) ∗d (t, w) := (s + t + d(v, w), v + w), then the cocycle identities ensure that this is in fact associative and further, a group operation. Finally, φ can be checked to be a homomorphism for multiplication in Q8 and for ∗d , hence is a group isomorphism. Thus we can reconstruct, at least up to isomorphism, the nonabelian group Q8 from the two abelian groups V4 and F2 , together with the cocycle d : V4 × V4 → F2 . If we didn’t know about the group structure of Q8 already, we could construct it from scratch using d. We can also build loops (particularly code loops) in the same way, which we will now outline. February 2021]

RECONSTRUCTING CODE LOOPS

153

3. TWISTED COCYCLES AND LOOPS. The construction in the previous section is a fairly typical case of reconstructing a central extension from a cocycle (although in general one does not even need the analog of the group V4 to be abelian). However, we wish to go one step further, and construct a structure with a nonassociative product from a pair of abelian groups: the group F2 and additive group of a vector space V over F2 . Instead of a cocycle, we use a twisted cocycle: a function α : V × V → F2 like d that, instead of (1), satisfies α(v, w) − α(u + v, w) + α(u, v + w) − α(u, v) = f (u, v, w) for a nonzero twisting function f : V × V × V → F2 . We will assume that α satisfies α(0, v) = α(v, 0) = 0 for all v ∈ V , a property that holds for the cocycle d in the previous section. The “twisted cocycle” terminology comes from geometry, where they appear in other guises; another term used is factor set. From a twisted cocycle α the set F2 × V can be given a binary operation ∗α : (s, v) ∗α (t, w) := (s + t + α(v, w), v + w).

(2)

We denote the product F2 × V of sets equipped with this binary operation by F2 ×α V . If the twisting function f is zero, then α is a cocycle, ∗α is an associative operation, and F2 ×α V is a group. Definition 1. A loop is a set L with a binary operation  : L × L → L, a unit element e ∈ L such that e  x = x  e = x for all x ∈ L, and such that for each z ∈ L, the functions rz (x) = x  z and z (x) = z  x are bijections L → L. A homomorphism of loops is a function preserving multiplication and the unit element. The conditions on rx and x mean that every element x ∈ L has a left inverse xL−1 and a right inverse xR−1 for the operation , and these are unique—but may be different in general. The following is a worthwhile exercise using the twisting function and the assumption that α(0, v) = α(v, 0) = 0. Lemma 1. The operation ∗α makes F2 ×α V into a loop, with identity element (0, 0). The projection function π : F2 ×α V → V is a surjective homomorphism of loops, with kernel F2 × {0}. Groups are examples of loops, but they are, in a sense, the uninteresting case. Arbitrary loops are quite badly behaved: even apart from the product being nonassociative, left and right inverses may not coincide, and associativity can fail for iterated products of a single element. But there is a special case introduced by Ruth Moufang [13], with better algebraic properties, while still permitting nonassociativity. Definition 2. A Moufang loop is a loop (L, ) satisfying the identity x  (y  (x  z)) = ((x  y)  x)  z for all choices of elements x, y, z ∈ L. The most famous example of a Moufang loop is probably the set of nonzero octonions under multiplication, although there are many less-known finite examples. A key property of a Moufang loop L is that any subloop x, y < L generated by a pair of elements x, y is in fact a group. By a subloop of L we mean a subset containing e that is closed under the operation . As a corollary, powers of a single element are 154

c THE MATHEMATICAL ASSOCIATION OF AMERICA 

[Monthly 128

well-defined, and do not require extra bracketing: x  (x  x) = (x  x)  x =: x 3 , for example. Additionally, the left and right inverses always agree in a Moufang loop, so that for each x ∈ L there is a unique x −1 such that x  x −1 = x −1  x = e. Code loops, defined below as a special case of the construction of F ×α V , are examples of Moufang loops. Example 1. Let V = (F2 )3 . The 16-element Moufang loop M := M16 (C2 × C4 ) of [2, Theorem 2] is isomorphic to F2 ×μ V , where μ : V × V → F2 is the twisted cocycle given by the 8 × 8 array of bits in Figure 2.

Figure 2. Twisted cocycle for the Moufang loop M of Example 1; white = 0, black = 1. The order of the row/column labels is 000, 100, 010, 110, 001, 101, 011, 111.

Notice that the first four columns/rows correspond to the subgroup U ⊂ V generated by 100 and 010, and that the restriction of μ to U × U is identically zero (i.e., white).  This means that the restriction M U < M—the subloop of M whose elements are mapped to U by M  F2 ×μ V → V —is isomorphic to the direct product F2 × U , using the definition (2) of the product, and in particular is a group. 4. CODES AND CODE LOOPS. To describe the twisting function f for our code loops, we need to know about some extra operations that exist on vector spaces over the field F2 . For W an n-dimensional vector space over F2 and vectors v, w ∈ W , there is a vector v & w ∈ W given by v & w := (v1 w1 , v2 w2 , . . . , vn wn ). If we think of such vectors as binary strings, then this operation is bitwise AND (hence the notation). Note that if we take a code C ⊂ (F2 )n , then C is not guaranteed to be closed under this operation. The other operation takes a vector v ∈ W and returns its weight: the sum, as an integer, of its entries: |v| := v1 + · · · + vn . Equivalently, it is the number of nonzero entries in v. The twisting function for a code loop is then a combination of these two, namely f (u, v, w) := |u & v & w|. However, as alluded to above, we are going to ask that further identities hold. For these identities to make sense we need to start with a code with the special property of being doubly even. Definition 3. A code C ⊂ (F2 )n is doubly even if for every word v ∈ C , |v| is divisible by 4. February 2021]

RECONSTRUCTING CODE LOOPS

155

Example 2. The Hamming (8,4) code is the subspace H ⊂ (F2 )8 spanned by the four row vectors 10000111 01001011 00101101 00011110 and is doubly even. A more substantial example of a doubly even code is the following. Example 3. The (extended binary) Golay code G ⊂ (F2 )24 is the span of the following (row) vectors, denoted b1 , . . . , b6 (left) and b7 , . . . , b12 (right): 000110000000010110100011 101001111101101111110001 000100000000100100111110 010000000010000110101101 000000000010010101010111 100000000000100111110001

101001011100111001111111 100000011100001001001100 000001000000111001001110 100000001000111000111000 100000000100101000010111 011011000001111011111111

This basis is different from the more usual ones (e.g., [5, Figure 3.4]), which can be taken as the rows of a 12 × 24 matrix whose left half is the 12 × 12 identity matrix. Our basis, however, allows us to demonstrate some interesting properties. The inclusion/exclusion formula applied to counting nonzero entries allows us to show that, for all v and w in any doubly even code C , |v + w| + |v & w| = |v| + |w| − |v & w| . In other words: |v & w| = 12 (|v| + |w| − |v + w|), which implies that |v & w| is divisible by 2. Thus for words v, w in a doubly even code, both 14 |v| and 12 |v & w| are integers. Definition 4 (Griess [8]). Let C be a doubly even code. A code cocycle1 is a function θ : C × C → F2 satisfying the identities θ(v, w) − θ(u + v, w) + θ(u, v + w) − θ(u, v) = |u & v & w| θ(v, w) + θ(w, v) = θ(v, v) = 14 |v|

1 |v 2

& w|

(mod 2);

(mod 2).

(mod 2);

(3) (4) (5)

A code loop is then a loop arising as F2 ×θ C (up to isomorphism) for some code cocycle θ. Example 4. Define C := span{b10 , b11 , b12 }, using the basis vectors from Example 3. μ Then the composite function C × C  (F2 )3 × (F2 )3 − → F2 , using the twisted cocycle μ in Figure 2, is a code cocycle. This makes the loop M from Example 1 a code loop. There is a notion of what it means for two twisted cocycles to be equivalent, and equivalent twisted cocycles give isomorphic loops. As part of [8, Theorem 10], Griess proves that all code cocycles for a given doubly even code are equivalent, and hence give isomorphic code loops. 1 Griess

156

uses the alternative term “factor set.”

c THE MATHEMATICAL ASSOCIATION OF AMERICA 

[Monthly 128

5. GRIESS’S ALGORITHM AND ITS OUTPUT. The algorithm that Griess describes in the proof of [8, Theorem 10] to construct code cocycles for a code C takes as input an ordered basis {b0 , . . . , bk−1 } for C . A code cocycle is then built up inductively over larger and larger subspaces Vi = span{b0 , . . . , bi }. However, the description by Griess is more of an outline, using steps like “determine the cocycle on such-and-such subset using identity X,” where X refers to one of (3), (4), (5) in [8], or corollaries of these. We have reconstructed the process in detail in Algorithm 1. We implemented Algorithm 1 in the language Go [14], together with diagnostic tests, for instance to verify the Moufang property. The output of the algorithm is a code cocycle, encoded as a matrix of ones and zeros, and can be displayed as an array of black and white pixels. There are steps where an arbitrary choice of a single bit is allowed; we consistently took this bit to be 0. For the Golay code this image consists of slightly over 16 million pixels. As a combinatorial object, a code cocycle θ : G × G → F2 constructed from Algorithm 1 using the basis in Example 3 can be too large and unwieldy to examine for any interesting structure. Moreover, to calculate with Parker’s loop P := F2 ×θ G one needs to know all 16 million or so values of θ. It is thus desirable to have a method that will calculate values of θ by a method shorter than Algorithm 1. Lemma 2. Let C be a doubly even code and θ a code cocycle on it. Given C = V ⊕ W a decomposition into complementary subspaces, then for v1 , v2 ∈ V and w1 , w2 ∈ W , θ(v1 + w1 , v2 + w2 ) = θ(v1 , v2 ) + θ(w1 , w2 ) + θ(v1 , w1 )

(6)

+ θ(w2 , v2 ) + θ(v1 + v2 , w1 + w2 ) + 12 |v2 & (w1 + w2 )| + |v1 & v2 & (w1 + w2 )| + |w1 & w2 & v2 | + |v1 & w1 & (v2 + w2 )|

(mod 2) .

Proof. We apply the identity (3) three times and then the identity (4) once: θ(v1 + w1 , v2 + w2 ) = θ(v1 , w1 ) + θ(v1 , v2 + w1 + w2 ) + θ(w1 , v2 + w2 ) + |v1 & w1 & (v2 + w2 )|  = θ(v1 , w1 ) + θ(v1 , v2 ) + θ(v1 + v2 , w1 + w2 ))  + θ(v2 , w1 + w2 ) + |v1 & v2 & (w1 + w2 )|  + θ(w1 , w2 ) + θ(w1 + w2 , v2 ) + θ(w2 , v2 )  + |w1 & w2 & v2 | + |v1 & w1 & (v2 + w2 )|  = θ(v1 , w1 ) + θ(v1 , v2 ) + θ(v1 + v2 , w1 + w2 ))  + |v1 & v2 & (w1 + w2 )|   + θ(w1 , w2 ) + θ(w2 , v2 ) + |w1 & w2 & v2 | + |v1 & w1 & (v2 + w2 )| + 12 |v2 & (w1 + w2 )|. Observe that in Lemma 2, on the right-hand side of (6), the code cocycle θ is only ever evaluated on vectors from the subset V ∪ W ⊂ C . This means we can throw away the rest of the array and still reconstruct arbitrary values of θ using (6). If we assume February 2021]

RECONSTRUCTING CODE LOOPS

157

that C is 2k-dimensional, and that V and W are both k-dimensional, then the domain of the restricted θ has (2k + 2k − 1)2 = 22(k+1) − 2k+2 + 1 = O((2k )2 ) elements. Compared to the full domain of θ, which has 22k × 22k = (2k )4 elements, this is roughly a square-root saving. However, one heuristic for choosing the subspaces V and W is to aim for a reduction in the apparent randomness of the plot of the restricted code cocycle, or equivalently, less-granular structural repetition. This is true, even if the size of V ∪ W is not minimized by choosing V and W to have dimension (dim C )/2 (or as close as possible). Now it should be clear why the Golay code basis in Example 3 was partitioned into two lists of six vectors: we can reconstruct all 16 777 216 values of the resulting code cycle θ, and hence the multiplication in Parker’s loop, from a mere 214 − 28 + 1 = 16 129 values. The span of the left column of vectors in Example 3 is the subspace V ⊂ G , and the span of the right column of vectors is W ⊂ G . The top left quadrant of Figure 3 then contains the restriction of θ to V × V , and the bottom right quadrant the restriction to W × W . The off-diagonal quadrants contain the values of θ restricted to  V × W and W × V . From Figure 3 and formula (2) we can  of Parker’s loop is a direct product (hence is a group), as P see that the restriction V   θ V ×V is identically zero. Moreover, the restriction of P W is isomorphic to the direct product (F2 )3 × M, where M is the Moufang loop from Example 1. This is because what was a single pixel in Figure 2 is now an 8 × 8 block of pixels in the lower right quadrant of Figure 3.

Figure 3. The restriction of the code cocycle θ for Parker’s loop to (V ∪ W )2 . A machine-readable version is available in [14] or as an online supplement to this article. The order of the row/column labels is 0, b1 , b2 , b1 + b2 , b3 , b3 + b1 , . . . , b1 + · · · + b6 , b7 , b8 , b7 + b8 , . . . , b7 + · · · + b12 .

6. DISCUSSION AND COMPARISON. Parker’s loop P is an algebraic structure that has spawned a small industry trying to understand and construct code loops in 158

c THE MATHEMATICAL ASSOCIATION OF AMERICA 

[Monthly 128

general, as they form a class of Moufang loops that are relatively easy to describe. Parker’s original treatment of this class of Moufang loops used vector spaces V over F2 equipped with a function V → F2 satisfying certain conditions analogous to those in Definition 4 (see [8, Definition 13]). Aside from Parker’s approach and the description by Griess using code cocycles, there was an unpublished thesis [11], characterizations as loops with specified commutators and associators [3], an iterative construction using centrally twisted products [10], and a construction using groups with triality [15]. The LOOPS library [16] for the software package GAP [7] contains all the code loops of order 64 and below, although “the package is intended primarily for quasigroups and loops of small order, say up to 1000.” Even the more recent [17], which classifies code loops up to order 512 in order to add them to the LOOPS package, falls short of the 8192 elements of Parker’s loop; the authors say “our work suggests that it will be difficult to extend the classification of code loops beyond order 512.” In principle, there is nothing stopping the construction of P in LOOPS, but it will essentially be stored as a multiplication table, which would comprise 67 108 864 entries, each of which is a 13-bit element label. The paper [12] describes an algebraic formula for a code cocycle that will build Parker’s loop, as a combination of the recipe in the proof of Proposition 6.6 and the generating function in Proposition 9.2 appearing there. This formula is a polynomial with 330 cubic terms and 12 quadratic terms in 24 variables, being coefficients of basis vectors of G . To compare, combined with the small amount of data in Figure 3 together with a labeling of rows/columns by words of the Golay code, Lemma 2 only requires eight terms, of which four are cubic and the rest come from the 16 129 stored values of θ (the term θ(v1 , v2 ) in (6) vanishes identically, for P ). Since large-scale computation in large code loops (for instance in a package like LOOPS) requires optimizing the binary operation, we have found a space/time trade-off that vastly improves on existing approaches. In addition to computational savings, the ability to visually explore the structure of code loops during experimentation more generally is a novel advance—the recognition of (F2 )3 × M inside P was purely by inspection of the picture of the code cocyle then consulting the (short) list of Moufang loops of small order in [2]. Discovery of the basis in Example 3 occurred by walking through the spaces of bases of subcodes and working with the heuristic that more regularity in the appearance of the code cocycle is better. Additionally, our software flagged when subloops thus considered were in fact associative, and hence a group, leading to the discovery of the relatively large elementary subgroups (F2 )7 < P and (F2 )6 < (F2 )3 × M < P . Finally, one can also remark that because of the identity (4), one can replace the formula in Lemma 2 by one that is only ever evaluated on V 2 , W 2 , or V × W , with just one more term. This allows the reconstruction the top right quadrant of Figure 3 from the bottom left quadrant. Thus one can describe Parker’s loop as being generated by the subloops (F2 )7 and (F2 )3 × M, with relations coming from the information contained in the bottom left quadrant of Figure 3, and the formulas (4) and (6). The apparent structure in that bottom left quadrant is intriguing, and perhaps indicative of further simplifications; this will be left to future work.

February 2021]

RECONSTRUCTING CODE LOOPS

159

Data: Basis B = {b0 , b1 , . . . , bk−1 } for the code C Result: Code cocycle θ : C × C → F2 , encoded as a square array of elements from F2 , with rows and columns indexed by C // Initialize forall the c1 , c2 ∈ C do θ (c1 , c2 ) ← 0 end θ (b0 , b0 ) ← 14 |b0 | forall the 1 ≤ i ≤ length(B) do Define Vi := span{b0 , . . . , bi−1 } // (D1) define theta on {bi} x Vi then deduce on Vi x {bi} forall the v ∈ Vi do if v  = 0 then θ (bi , v) ← random // In practice, random = 0 θ (v, bi ) ← 12 |v & bi | + θ (bi , v) else // θ (bi , v) is already set to 0 θ (v, bi ) ← 12 |v & bi | end end // (D2) deduce theta on {bi} x Wi and Wi x {bi} forall the v ∈ Vi do θ (bi , bi + v) ← 14 |bi | + θ (bi , v) θ (bi + v, bi ) ← 12 |bi & (bi + v)| + 14 |bi | + θ(bi , v) end // (D3) deduce theta on Wi x Wi forall the v1 ∈ Vi do forall the v2 ∈ Vi do w ← bi + v2 a ← θ (v1 , bi ) b ← θ (v1 , bi + w) c ← θ (w, bi ) r ← 12 |v1 & w| + a + b + c θ (w, bi + v1 ) ← r end end // (D4) deduce theta on Wi x Vi and Vi x Wi forall the v1 ∈ Vi do forall the v2 ∈ Vi do w ← bi + v2 a ← θ (w, v1 + w) θ (w, v1 ) ← 14 |w| + a θ (v1 , w) ← 12 |v1 & w| + 14 |w| + a end end end

Algorithm 1: Reverse-engineered from proof of [8, Theorem 10].

ACKNOWLEDGMENTS. DMR is supported by the Australian Research Council’s Discovery Projects scheme (project number DP180100383), funded by the Australian Government. The authors thank an anonymous referee for providing Coxeter’s example and clarifying the details of Parker’s construction.

160

c THE MATHEMATICAL ASSOCIATION OF AMERICA 

[Monthly 128

ORCID Ben Nagy http://orcid.org/0000-0002-5214-7595 David Michael Roberts http://orcid.org/0000-0002-3478-0522 REFERENCES [1] Brown, K. (1994). Cohomology of Groups. Graduate Texts in Mathematics, Vol. 87. New York: Springer-Verlag. [2] Chein, O. (1974). Moufang loops of small order. I. Trans. Amer. Math. Soc. 188: 31–51. doi.org/ 10.2307/1996765 [3] Chein, O., Goodaire, E. G. (1990). Moufang loops with a unique nonidentity commutator (associator, square). J. Algebra. 130(2): 369–384. doi.org/10.1016/0021-8693(90)90087-5 [4] Conway, J. H. (1985). A simple construction for the Fischer–Griess monster group. Invent. Math. 79(3): 513–540. doi.org/10.1007/BF01388521 [5] Conway, J. H., Sloane, N. J. A. (1999). Sphere Packings, Lattices and Groups, 3rd ed. Grundlehren der Mathematischen Wissenschaften, Vol. 290. New York: Springer-Verlag. [6] Coxeter, H. S. M. (1946). Integral Cayley numbers. Duke Math. J. 13: 561–578. [7] The GAP Group. (2019). GAP—Groups, algorithms, and programming, version 4.10.2. www.gapsystem.org [8] Griess, Jr., R. L. (1986). Code loops. J. Algebra. 100(1): 224–234. doi.org/10.1016/0021-8693 (86)90075-X [9] Griess, Jr., R. L. (1987). Sporadic groups, code loops and nonvanishing cohomology. J. Pure Appl. Algebra. 44(1–3): 191–214. doi.org/10.1016/0022-4049(87)90024-7 [10] Hsu, T. (2000). Explicit constructions of code loops as centrally twisted products. Math. Proc. Cambridge Philos. Soc. 128(2): 223–232. doi.org/10.1017/S030500419900403X [11] Johnson, P. M. (1988). Gamma spaces and loops of nilpotence class two. Ph.D. thesis. University of Illinois at Chicago, Chicago, IL. [12] Morier-Genoud, S., Ovsienko, V. (2011). A series of algebras generalizing the octonions and Hurwitz– Radon identity. Comm. Math. Phys. 306(1): 83–118. doi.org/10.1007/s00220-011-1279-9 [13] Moufang, R. (1935). Zur Struktur von Alternativk¨orpern. Math. Ann. 110(1): 416–430. doi.org/ 10.1007/BF01448037 [14] Nagy, B., Roberts, D. M. (2019). codeloops library. github.com/bnagy/codeloops/releases/tag/v1.0.0 [15] Nagy, G. P. (2008). Direct construction of code loops. Discrete Math. 308(23): 5349–5357. doi.org/10.1016/j.disc.2007.09.056 [16] Nagy, G., Vojtˇechovsk´y, P. (2018). LOOPS—a GAP package, version 3.4.1. gap-packages.github. io/loops/ [17] O’Brien, E. A., Vojtˇechovsk´y, P. (2017). Code loops in dimension at most 8. J. Algebra. 473: 607–626. doi.org/10.1016/j.jalgebra.2016.11.006 BEN NAGY is an M.Phil. candidate at the University of Adelaide, researching computational stylistics for Latin poetry. Department of Classics, Archaeology & Ancient History, The University of Adelaide, Adelaide, SA 5005, Australia [email protected]

DAVID MICHAEL ROBERTS is a mathematician specializing in category theory, geometry and a hodgepodge of other random topics. School of Mathematical Sciences, The University of Adelaide, Adelaide, SA 5005, Australia [email protected]

February 2021]

RECONSTRUCTING CODE LOOPS

161

Exponential Inequalities and Corollaries Theorem. If a > 1 and 0 ≤ x < y, then a

x+y 2

ln a ≤

ay + ax ay − ax ≤ ln a. y−x 2

  Proof. The function f (t) = a t is increasing and convex. For any s ∈ 0, y−x 2 ,  y x+y x+y x+y a 2 dt ≤ a 2 − a x+s ≤ a y−s − a 2 by Jensen’s inequality. Therefore x  y x+y y x a t dt, which implies that (y − x)a 2 ≤ a ln−a . a x

In addition, since the function a t is convex,

ay − ax (a y + a x ) (y − x) < . ln a 2

Corollary 1. If 0 ≤ a0 < a1 < · · · < an , then n−1 

(ak+1 − ak ) e

ak+1 +ak 2

< e an − e a0
sin(β  ) > 0 .

(1)

Taking the reciprocal version of the right portion of (1) and multiplying, we obtain sin(α  ) sin(α) < , sin(β) sin(β  ) which contradicts the nonlinear portion of the hypothesis. Next, a similar argument excludes the possibility α > α  . So α = α  and hence β = β  . 3. DASHED HOPES. We now consider an abstract equilateral triangle W (in the cloud). Draw W with one side close to horizontal at the top and subtend angles of γ + 60◦ to the left and right vertices of this nearly horizontal side. Form left and right triangles with the subtended angles, so that the new far angles are β and α and the new angles at the lower vertex of W are α + 60◦ and β + 60◦ , as in Figure 2. Since α + β + γ = 60◦ , this is clearly possible.

Figure 2. An abstract triangle.

Now introduce a horizontal line segment connecting the bottom vertices of the two dashed triangles. We define angles β  and α  associated with β and α by this new segment, as illustrated in Figure 3, with the label W removed to reduce clutter. Gazing around the top vertex of the newly formed triangle, we see that the top angle, added to α + 60◦ , β + 60◦ , and 60◦ , must total 360◦ . Since α + β + γ = 60◦ , the top angle must be γ + 120◦ . Thus the labels β  , α  are definitional, and γ + 120◦ is consequential. Lemma 2. In Figure 3, α + β = α + β . 164

c THE MATHEMATICAL ASSOCIATION OF AMERICA 

(2) [Monthly 128

Figure 3. Equality of angle sums.

Proof. Adding interior angles in the lowest triangle in Figure 3 we have α  + β  + γ + 120◦ = 180◦ . Since α, β, γ are trisected editions of the interior angles of our native triangle, we have α + β + γ = 60◦ . Combining the last two equations we have α + β = α  + β  . We now sleepily label with Z’s the 3 sides of the abstract equilateral triangle. In the lowest triangle of Figure 3, we label with X the side opposite α  and we label with Y the side opposite β  , obtaining Figure 4.

Figure 4. Equality of angle pairs.

Lemma 3. The corresponding companion angles introduced by the lowest triangle are equal. That is, α = α ;

β = β .

Proof. By the law of sines in the upper-left dashed triangle of Figure 4, sin(β) sin(γ + 60◦ ) = . Z X By the law of sines in the upper-right dashed triangle of Figure 4, sin(γ + 60◦ ) sin(α) = . Z Y February 2021]

NOTES

165

Dividing the last two equations, we obtain sin(α)/ sin(β) = X/Y . Making a direct law of sines argument for α  , β  using the lowest triangle, we obtain sin(α) X sin(α  ) = = . sin(β) Y sin(β  )

(3)

In (2), we established that α + β = α  + β  . This, together with (3) and Lemma 1 completes the proof.

Theorem. The Morley trisector triangle is equilateral. Proof. We have shown that the lowest triangle in Figure 4 is similar to the lowest triangle in the native Morley trisector diagram. Let’s call this triangle an outer triangle. With the same ideas we can construct two additional “outer” triangles, emanating from the other two vertices of the abstract equilateral triangle W , as in Figure 5.

Figure 5. Return of the native triangle.

The three outer triangles “surround” the abstract equilateral triangle W (in a friendly way). Their longest sides form a large triangle with angles 3α, 3β, 3γ . These angles are trisected by our dashed lines and the large triangle is similar to our native triangle ABC. The dilatation (zoom) factor that sends our constructed large triangle to the native triangle ABC also sends the three constructed outer triangles to corresponding triangles in the original Morley picture, and identifies our abstract equilateral triangle W with the native Morley triangle T , which, hence, is also equilateral. 4. REFLECTIONS. We contend that the proof above is trig-light. For the law of sines emanates from basic geometry, as does the monotonicity of the sine function over acute angles. In contrast, see [5] for a (justifiably) trig-heavy proof of an analog of Morley’s theorem. This is not to disparage trig-heavy arguments, which can be surprisingly beautiful [7]. Commentary on mathematical surprise and beauty, in the context of Morley’s theorem, is given in G.-C. Rota’s book [14]. The law of sines, while less ancient than Euclid, is said to be implicit in Ptolemy’s work [6, p. 44] and salient in the work of the 13th century mathematician Mohammed al-Tusi. Interestingly, the MathSciNet review of [6] points to al-Tusi’s result that a pair 166

c THE MATHEMATICAL ASSOCIATION OF AMERICA 

[Monthly 128

of angles may be determined from their sum and the ratio of their sines. Our nonlinear Lemma 1 is a nondeterministic uniqueness variant. Proofs of the Morley trisector theorem abound in the literature. See, for instance, [4, pp. 23–25] and [2, 3, 10–12, 15]. For some time, it was thought to be a difficult theorem to prove. (See, e.g., [2, 3].) Then a plethora of “easy” proofs emerged, and the trend continues. Yet, this theorem still does not appear in Proofs from the Book [1]. Then again, neither does the far more senior Pythagorean theorem, which has several hundred proofs [9]. Now, the 6th edition of [1] has six “Book” proofs of the infinitude of the primes. Is there a Book proof of the Morley trisector theorem? Perhaps the case of the Pythagorean theorem should be settled first. ACKNOWLEDGMENTS. We thank the referees and editors for helpful comments and suggestions. We also thank the authors of LATEX codes for the Morley trisector diagram [8, 13]. Our diagrams are based on their posted source material.

ORCID Eric L. Grinberg

http://orcid.org/0000-0002-6037-4245

REFERENCES [1] Aigner, M., Ziegler, G. (2018). Proofs from the Book, 6th ed. (Hofmann, K. H., illust.) Berlin: SpringerVerlag. [2] Connes, A. (1998). A new proof of Morley’s theorem. In: Les Relations entre les Math´ematiques et la ´ Physique Th´eorique. Bures-sur-Yvette: Institut des Hautes Etudes Scientifiques, pp. 43–46. [3] Conway, J. H. (2014). On Morley’s trisector theorem. Math. Intelligencer. 36(3): 3. [4] Coxeter, H. S. M. (1969). Introduction to Geometry. Toronto: Wiley. [5] Demir, H. (1965). A theorem analogous to Morley’s theorem. Math. Mag. 38(4): 228–230. [6] Gonz´alez-Velasco, E. A. (2011). Journey Through Mathematics: Creative Episodes in Its History. New York: Springer. [7] Kowalski, T. (2016). The sine of a single degree. College Math. J. 47(5): 322–332. [8] Lefebvre, A. (2010). tkz-2d LATEX illustration for Morley Trisector diagram. texample.net/tikz/ examples/morleys-triangle/ [9] Loomis, E. S. (1968). The Pythagorean Proposition. Washington, DC: National Council of Teachers of Mathematics. [10] Morley, F. (1900). On the metric geometry of the plane n-line. Trans. Amer. Math. Soc. 1(2): 97–115. [11] Newman, D. J. (1996). The Morley miracle. Math. Intelligencer. 18(1): 31–32. [12] Oakley, C. O., Baker, J. C. (1978). The Morley trisector theorem. Amer. Math. Monthly. 85(9): 737–745. [13] Port to euclide of original Arnaud Lefebvre diagram for Morley Trisector diagram. (2011). tex. stackexchange.com/questions/28795/migrating-from-tkz-2d-to-tkz-euclide [14] Rota, G.-C. (1997). Indiscrete Thoughts. Basel: Birkh¨auser. [15] Smyth, M. R. (2015). Morley’s theorem: A walk in the park. Math. Intelligencer. 37(3): 60. Department of Mathematics, University of Massachusetts Boston, Boston, MA 02125 [email protected] Department of Mathematics, University of New Hampshire, Durham, NH 03824 [email protected]

February 2021]

NOTES

167

On the Automorphism Group of Direct Products of Groups with Finite Exponent Dorin Andrica, Sorin R˘adulescu, and George C. T¸urcas¸

Abstract. We study the direct product of the automorphism groups of a finite number of groups. This is always isomorphic to a subgroup of the automorphism group of the direct product of the initial groups and we provide various sufficient criteria for when the latter subgroup is actually the whole group.

1. INTRODUCTION. Group theory is fundamental in the study of symmetries of objects and configurations. From this point of view, the symmetries of a group G itself are encoded in the automorphism group Aut(G) of G. Thus the automorphisms Aut(G), where G is a group, are of great interest in the study of the theory of groups. We refer to the recent monograph [6] for an excellent presentation of this study for finite groups. In the note [4, Lemma 2.1], the following result is proved: If G1 × G2 is the direct product of finite groups G1 and G2 in which the orders of G1 and G2 are relatively prime positive integers, then Aut(G1 × G2 )  Aut (G1 ) × Aut (G2 ).

(1)

The result above was used by the authors of [1] to describe the automorphism group of a finite abelian group. In the same article, it is mentioned that this result follows from Theorems 3.2 and 3.6 of [2]. It can be shown, using strong induction, that the natural generalization of (1) holds  for any finite number of finite groups G1 , G2 , . . . , Gm with the property gcd |Gi |, |Gj | = 1, for every 1 ≤ i < j ≤ m. Let us note that the aforementioned results are proved under the hypothesis that the groups Gi are finite. These can be extended to infinite groups that satisfy chain conditions on normal subgroups using the theory of normal group endomorphisms. A broad generalization of this theory can be found in [5]. It is natural to ask if the isomorphism (1) remains true for some other classes of infinite groups. Our main result gives an answer in the case of a special class of torsion groups (see next section for the precise definition). We remark that general torsion groups do not satisfy the aforementioned chain conditions on normal subgroups. Although ideas from [2] or [5, Sections 7 and 8] are adaptable to achieve the results in this note, we hope that the readers will benefit from our choice of a direct, more computational, and self-contained presentation. m  Aut(Gi ) is isomorWe note that for any groups G1 , G2 , . . . , Gm , the group phic to a subgroup of Aut( elements of

m  i=1

m  i=1

i=1

Gi ). To explain this, we start by pointing out that

Aut(Gi ) are just m-tuples (φ1 , . . . , φm ), where φi ∈ Aut(Gi ) for

doi.org/10.1080/00029890.2021.1851565 MSC: Primary 20F28, Secondary 20E36

168

c THE MATHEMATICAL ASSOCIATION OF AMERICA 

[Monthly 128

every i = 1, . . . , m. On the other hand, elements of Aut( u = (u1 , . . . , um ), where ui :

m  i=1

m  i=1

Gi ) are of the form

Gi → Gi are group homomorphisms for every i =

1, . . . , m. We now consider the natural map f :

m 

Aut(Gi ) → Aut(

i=1

m 

Gi )

i=1

defined by f (φ1 , . . . , φm )(x1 , . . . , xm ) = (φ1 (x1 ), . . . , φm (xm )),

(2)

where φi ∈ Aut Gi and xi ∈ Gi for all i = 1, . . . , m. It can be easily verified that f is a well-defined group homomorphism. Moreover, f m  Gi , is injective. Indeed, if f (φ1 , . . . , φm ) = 1mi=1 Gi , the identity automorphism on i=1

then (φ1 (x1 ), . . . , φm (xm )) = (x1 , . . . , xm ) for all xi ∈ Gi and all i = 1, . . . , m. Then φi = 1Gi , the identity automorphism on Gi for every i = 1, . . . , m. We just proved that f has trivial kernel; hence it is injective. We therefore have m 

Aut(Gi )  Im f ≤ Aut(

i=1

m 

Gi ).

(3)

i=1

 Now consider u = (u1 , . . . , um ), u = (u1 , . . . , um ) ∈ Aut( m i=1 Gi ), with u ◦ u = u ◦ u = 1Aut(mi=1 Gi ) , that is, u is the inverse of u. For a fixed index j , define the endomorphisms φj , φ j : Gj → Gj , where φj (xj ) = uj (e1 , . . . , xj , . . . , em ) and φ j (xj ) = uj (e1 , . . . , xj , . . . , em ), where ei is the neutral element of the group Gi , i = 1, . . . , m. The following auxiliary result provides sufficient conditions for φj and φ j to be automorphisms of the group Gj with φj−1 = φ j . Lemma 1. If the relations uk (e1 , . . . , xj , . . . , em ) = uk (e1 , . . . , xj , . . . , em ) = ek

(4)

hold for every k = 1, . . . , m with k  = j , then φj−1 , φ j ∈ Aut Gj and φj−1 = φ j . Proof. Writing the condition u ◦ u = 1Aut(mi=1 Gi ) in terms of the components of u and u and using the hypothesis (4), it follows that for every xj ∈ Gj , we have (φj ◦ φ j )(xj ) = uj (e1 , . . . , φ j (xj ), . . . , em ) = uj (e1 , . . . , uj (e1 , . . . , xj , . . . , em ), . . . , em ) = xj , that is, φj ◦ φ j = 1Gj . Similarly, we prove that φ j ◦ φj = 1Gj , and the conclusion follows. In this note, we exhibit sufficient conditions on the groups G 1 ,mG2 , . . . , Gm to derive that the homomorphism f is surjective, i.e., the groups i=1 Aut(Gi ) and  G ) are isomorphic. Our first result generalizes the one for finite groups Aut( m i i=1 mentioned at the beginning of this note, but it also applies to some large classes of infinite groups. February 2021]

NOTES

169

2. THE EXPONENT OF A GROUP. Recall that a group G is a torsion group if every element x ∈ G has finite order. A simple example of an infinite such group is (Z/2Z[X], +), the additive group of polynomials with coefficients in Z/2Z, the ring of residue classes modulo 2. Clearly, every nonzero element has order 2. Let G be a group with the neutral element e and let n ≥ 1 a positive integer. We say that G has exponent n if n is the smallest positive integer such that x n = e for every x ∈ G. We write μ(G) for the exponent of G. If for a given group G there is no such positive integer n, the convention is to set μ(G) = ∞. The group G is of finite exponent if we have μ(G) < ∞. For brevity, in this case we will write that G is an fe-group. Clearly, if G is an fe-group then it is a torsion group. The converse of this implication is not true. In this respect, an example is given by the Pr¨ufer p-group Z(p∞ ) =

∞ 

Z(p k ),

k=1

where p is a prime and Z(p k ) is the group of the p k th roots of unity. The group Z(p ∞ ) is a torsion group with μ(Z(p ∞ )) = ∞. The proofs of the following properties constitute easy but instructive exercises. We encourage the interested reader to prove them. 1. If G is an fe-group and H is a subgroup of G, then μ(H ) | μ(G). 2. If G is a finite group, then μ(G) | |G|, where |G| is the order of G. 3. The exponent of a finite group is equal to the product of the exponents of its Sylow subgroups. 4. If G1 is a group, G2 is an fe-group, and f : G1 → G2 is an injective homomorphism, then G1 is an fe-group and μ(G1 ) | μ(G2 ). 5. If G1 is an fe-group, G2 is a group, and f : G1 → G2 is a surjective homomorphism, then G2 is an fe-group and μ(G2 ) | μ(G1 ). 6. Let G be an fe-group and p be a prime such that p | μ(G). Then there is x ∈ G with σ (x) = p. 7. If G is a finite group, then Aut(G) is finite and μ(G/Z(G)) | μ(Aut(G)), where Z(G) is the center of G.  Gi is an fe-group and 8. If {Gi }i∈I is a finite family of fe-groups, then i∈I    μ Gi = lcm{μ(Gi ) : i ∈ I }. i∈I

Theorem 1. Let G be a finite group. We then have

 (1) If p1 , . . . , pr are the prime factors of |G|, then ri=1 pi divides μ(G); (2) |G| divides μ(G) log2 |G| , where · : R → Z is the floor function.

Proof. (1) If p is a prime dividing |G|, it follows from Cauchy’s theorem that there exists an element g ∈ G that has order p. It is then obvious that p | μ(G).   α β (2) Let us consider the prime factorizations |G| = ri=1 pi i and μ(G) = ri=1 pi i , where 1 ≤ βi ≤ αi are integers, for all i ∈ {1, . . . , r}. It is enough to show that the inequality αi ≤ βi · α1 log2 (p1 ) + · · · + αr log2 (pr ) holds for every i. But it is easy to see that, for each i, βi α1 log2 (p1 ) + · · · + αr log2 (pr ) ≥ αi log2 (pi ) ≥ αi and the conclusion follows. Computing the exponent of some concrete groups is a difficult and challenging problem. Let us begin this discussion with the following list of remarks: 170

c THE MATHEMATICAL ASSOCIATION OF AMERICA 

[Monthly 128

1. Groups of exponent 1 are trivial and groups of exponent 2 are abelian. 2. Groups of exponent 3 are not necessarily abelian, as the Heisenberg group over the field F3 shows. This is the multiplicative group of 3 × 3 upper-triangular matrices, whose elements belong to F3 and whose diagonal entries are all equal to 1. 3. In the case of finite cyclic groups, it is easy to see that the exponent of the group is equal to its order. By the fundamental theorem of finite abelian groups, we know that any such group G can be written as a direct product of cyclic subgroups. From this we can derive that, if G is finite abelian, then μ(G) = |G| if and only if G is cyclic. In particular, μ(Z/nZ) = n, where Z/nZ denotes the additive group of integers mod n. 4. Let U (Z/nZ) be the multiplicative group of integers mod n. The group U (Z/nZ) consists of residue classes k modulo n such that gcd(k, n) = 1. The order of the group U (Z/nZ) is ϕ(n), where ϕ is the Euler totient function. A famous theorem of Gauss determines the structure of the group U (Z/p m Z), where p is a prime and m is a positive integer. We have U (Z/p m Z)  Z/ϕ(p m )Z = Z/p m−1 (p − 1)Z if p ≥ 3 and U (Z/2m Z)  Z/2Z × Z/2m−2 Z. Applying property 3, we obtain ⎧ ⎨ p k−1 (p − 1), if p is an odd prime, k 2k−2 , if p = 2 and k ≥ 3, μ(U (Z/p Z)) = ⎩ 2k−1 , if p = 2 and k ∈ {1, 2}.  α If n = ri=1 pi i is the prime factorization of the positive integer n, then by using property 8 of the exponent, we see that μ(U (Z/nZ)) = lcm{μ(U (Z/p αi Z)) : i = 1, . . . , r}. 3. SUFFICIENT CONDITIONS FOR (1). Our main result is the following:   Theorem 2. Let G1 , G2 , . . . , Gm be fe-groups. If gcd μ(Gi ), μ(Gj ) = 1 for every 1 ≤ i < j ≤ n, then Aut(

m  i=1

Gi ) 

m 

Aut(Gi ).

i=1

Proof. We first remark that the result for general m follows easily via strong induction, if one proves that the same holds for m = 2. We have already seen that the group homomorphism f defined by (2) is injective. To prove that f is an isomorphism, it remains to show that it is surjective. Let us first denote μ(Gi ) by mi for all i = 1, 2. Since m1 , m2 are coprime, there are integers a1 , a2 such that a1 m1 + a2 m2 = 1. Any element u ∈ Aut(G1 × G2 ) is of the form u = (u1 , u2 ) where ui : G1 × G2 → Gi are group homomorphisms for i = 1, 2. We have that a m

a m

u1 (x1 , x2 ) = u1 (x1 , x2 )1−a1 m1 = u1 (x1 , x2 )a2 m2 = u1 (x1 2 2 , x2 2 2 ) a m

1−a1 m1

= u1 (x1 2 2 , e2 ) = u1 (x1

, e2 ) = u1 (x1 , e2 ),

for all xi ∈ Gi , i = 1, 2; hence u1 (e1 , x2 ) = u1 (e1 , e2 ) = e1 , for all x2 ∈ G2 . In a similar way, we can deduce the relations u1 (e1 , x2 ) = u1 (e1 , e2 ) = e1 , for all x2 ∈ G2 . We also have u2 (x1 , x2 ) = u2 (e1 , x2 ), u2 (x1 , e2 ) = e2 , u2 (x1 , e2 ) = e2 for all xi ∈ Gi , i = 1, 2, where u = (u1 , u2 ) is the inverse of u. From Lemma 1 it follows that φ1 ∈ Aut G1 , where φ1 (x1 ) = u1 (x1 , e2 ), and φ2 ∈ Aut G2 , where φ2 (x2 ) = u2 (e, x2 ). We observe that f (φ1 , φ2 )(x1 , x2 ) = (φ1 (x1 ), φ2 (x2 )) = (u1 (x1 , e2 ), u2 (e1 , x2 ) = (u1 (x1 , x2 ), u2 (x1 , x2 ) = u(x1 , x2 ), for every xi ∈ Gi , i = 1, 2, and hence f is surjective. February 2021]

NOTES

171

Remark. Using property (1) in Theorem 1, it follows that if the    groups G1 , . .. , Gm are finite, then the hypotheses gcd |Gi |, |Gj | = 1 and gcd μ(Gi ), μ(Gj ) = 1, 1 ≤ i < j ≤ m, are equivalent. A natural question one can ask is whether there are examples of groups G1 and G2 such that not both of them have finite exponent, but for which the relation (1) holds. In the following theorem, we provide a sufficient criterion for the relation (1) to hold and we obtain as a corollary an affirmative answer to this question. Theorem 3. Let n ≥ 2 be an integer and G1 , G2 groups with the following properties: 1. If x ∈ G1 is such that x n = e1 , then x = e1 ; 2. Every normal subgroup H of finite index of G1 satisfies gcd(n, [G1 : H ]) = 1; 3. G2 is cyclic of order n. Then the relation (1) holds and the map f defined by (2) is an isomorphism. Proof. It is sufficient to prove that f is surjective. Let u = (u1 , u2 ) ∈ Aut(G1 × G2 ) and let u = (u1 , u2 ) be its inverse. If we choose a generator a ∈ G2 , then for every x1 ∈ G1 and for every k = 1, . . . , n, the following relations hold: u1 (x1 , a k ) = u1 (x1 , e2 ) · u1 (e1 , a k ) = u1 (x1 , e2 ) · u1 (e1 , a)k . Taking k = n in the last equality we obtain u1 (x1 , e2 ) = u1 (x1 , e2 ) · u1 (e1 , a)n ; hence u1 (e1 , a)n = e1 . Our hypothesis implies that u1 (e1 , a) = e1 , that is, for every x2 ∈ G2 we have u1 (e1 , x2 ) = e1 . In similar way, we can prove the relation u1 (e1 , x2 ) = e1 , x2 ∈ G2 . From Lemma 1, it follows that the map φ1 : G1 → G1 defined by φ1 (x1 ) = u1 (x1 , e2 ), for all x1 ∈ G1 , is an automorphism of G1 . We have that u2 (x1 , x2 ) = u2 (x1 , e2 )u2 (e1 , x2 ) for all (x1 , x2 ) ∈ G1 × G2 . Let us define the group homomorphism φ : G1 → G2 by φ(x1 ) = u2 (x1 , e2 ) for all x1 ∈ G1 and denote ker(φ) by H . The subgroup H is normal in G1 and from the relation G1 /H  φ(G1 ), it follows that it has finite index in G1 and its index [G1 : H ] divides n. From the second hypothesis, it follows that [G1 : H ] = 1 and hence φ(x1 ) = e2 for every x1 ∈ G1 , that is, we have u2 (x1 , e2 ) = e2 for every x1 ∈ G1 . Similarly, we can prove the relation u2 (x1 , e2 ) = e2 for every x1 ∈ G1 . Considering the group endomorphism φ2 : G2 → G2 , defined by φ2 (x2 ) = u2 (e1 , x2 ) for all x2 ∈ G2 , from Lemma 1 we have φ2 ∈ Aut(G2 ). With the same computation as in the proof of Theorem 2, we obtain that f (φ1 , φ2 ) = (u1 , u2 ) = u and hence f is bijective. The conclusion follows. To emphasize the utility of Theorem 3 we present the following two groups that satisfy the first two hypotheses, hence can play the role of G1 . Let us fix a prime number p that is coprime to n = |G2 |. It is well known that the aforementioned Pr¨ufer p-group Z(p ∞ ) has only finite proper subgroups. The only finite index subgroup is Z(p ∞ ) and its index is 1; hence condition 2 is verified. On the other hand, condition 1 is obviously satisfied if p does not divide n. The second example is a bit more sophisticated. Let G1 = Zp = lim Z/p k Z be ← − the projective limit of the finite cyclic groups Z/p k Z as k goes to infinity. The reader familiar with p-adics might recognize this group as the unit ball (or the ring of integers) inside the p-adic numbers Qp . We refer to the excellent book [3], where in the chapter titled “Profinite Groups” the interested reader can find proofs of all of the theoretical 172

c THE MATHEMATICAL ASSOCIATION OF AMERICA 

[Monthly 128

results we mention further in this note. The group Zp is profinite, abelian, and all its nontrivial elements have infinite order. A result in the theory of profinite groups tells us that every finite index subgroup N of Zp is open, i.e., it contains p k Zp for some large integer k ≥ 0. In particular, [Zp : N] must divide [Zp : p k Zp ] = p k . We therefore showed that we can choose G1 = Zp in the theorem above. One can observe a certain similarity between the multiplicative group Z(p ∞ ) and the additive group Zp . However, they are not isomorphic. The first one is a torsion group, which can be realized as a direct limit lim Z/p k Z, where the homomorphisms − → Z/p k Z → Z/p k+1 Z are induced by multiplication by p. On the other hand, in the additive group Zp every element has infinite order. We note the following known relations between Z(p ∞ ) and Zp . The first group is isomorphic to the quotient Qp /Zp . The automorphism groups of Z(p ∞ ) and Zp are both isomorphic to U (Zp ), the group of multiplicative units in the ring Zp . Theorem 3 applied in turn with G1 = Z(p ∞ ) and G1 = Zp gives Aut(Z(p ∞ ) × Z/nZ)  U (Zp ) × U (Z/nZ)  Aut(Zp × Z/nZ). ACKNOWLEDGMENTS. We are indebted to the editors and referees for their careful reading and for many helpful remarks on an earlier version of this manuscript. The third author is supported by Bitdefender through a postdoctoral fellowship at IMAR.

ORCID George C. T¸urcas¸

http://orcid.org/0000-0002-2739-5917

REFERENCES [1] Bidwell, J. N. S., Curran M. J. (2010). Automorphisms of finite abelian groups. Math. Proc. R. Ir. Acad. 110A(1): 57–71. doi.org/10.3318/PRIA.2010.110.1.57 [2] Bidwell J. N. S., Curran M. J., McCaughan D. J. (2006). Automorphisms of direct products of finite groups. Arch. Math. 86: 481–489. doi.org/10.1007/s00013-005-1547-z [3] Cassels, J. W. S., Fr¨ohlich, A. (2010). Algebraic Number Theory. London: London Mathematical Society. [4] Hillar, C. J., Rhea, D. L. (2007). Automorphisms of finite Abelian groups. Amer. Math. Monthly. 114(10): 917–923. doi.org/10.1080/00029890.2007.11920485 [5] Keilberg, M., Schauenburg, P. (2016). On tensor factorizations of Hopf algebras. Algebra Number Theory. 10(1): 61–87. doi.org/10.2140/ant.2016.10.61 [6] Passi, I. B. S., Singh, M., Yadav, M. K. (2018). Automorphisms of Finite Groups. Singapore: Springer. Faculty of Mathematics and Computer Sciences, “Babes¸-Bolyai” University, Str. Kogalniceanu No. 1, 405300 Cluj-Napoca, Romania [email protected] Institute of Mathematical Statistics and Applied Mathematics, Calea 13 Septembrie No. 13, 050711 Bucharest, Romania [email protected] Faculty of Mathematics and Computer Sciences, “Babes¸-Bolyai” University, Str. Kogalniceanu No. 1, 405300 Cluj-Napoca, Romania and Institute of Mathematics “Simion Stoilow” of the Romanian Academy, PO Box 1-764, RO-014700 Bucharest, Romania [email protected]

February 2021]

NOTES

173

Positive Rational Numbers of the Form ϕ(m2)/ϕ(n2) Hongjian Li, Pingzhi Yuan, and Hairong Bai

Abstract. In this note, we show that each positive rational number can be written uniquely as ϕ(m2 )/ϕ(n2 ), where m, n ∈ N, with some natural restrictions on gcd(m, n).

Let N be the set of all positive integers and ϕ Euler’s totient function. Let n=

s 

α

pi i ,

p1 < p2 < · · · < ps primes, αi ∈ N,

i=1

be the standard factorization of a positive integer n and rad(n) = known that (see, e.g., [1, p. 20]) ϕ(n) = ϕ(

s  i=1

α

pi i ) =

s 

s i=1

pi . It is well

α −1

(pi − 1)pi i .

(1)

i=1

Let r=

s 

α

pi i ,

p1 < p2 < · · · < ps , αi ∈ Z\{0},

i=1

be the standard factorization of a positive rational number r, where p1 < p2 < · · · < ps are primes. Let P (r) = ps denote the maximal prime factor of r, and let vpi (r) = αi , the pi -valuation of r. Sun [3] proposed many challenging conjectures concerning representations of positive rational numbers. Recently, D. Krachun and Z. Sun [2] proved that any positive rational number can be written in the form ϕ(m2 )/ϕ(n2 ), where m, n ∈ N, with vp (m)  = vp (n) for every prime p|mn. For example, let r = 19/47; we have 19 × 46 19ϕ(232 ) 5ϕ(192 × 232 ) ϕ(32 × 52 × 192 × 232 ) 19 = = = = 47 ϕ(472 ) 11ϕ(472 ) 9ϕ(112 × 472 ) 4ϕ(34 × 112 × 472 ) = Here

ϕ(22 × 32 × 52 × 192 × 232 ) ϕ(131102 ) ϕ(393302 ) = = . ϕ(24 × 34 × 112 × 472 ) ϕ(186122 ) ϕ(558362 )

ϕ(131102 ) ϕ(186122 )

is a representation of r = 19/47 with gcd(13110, 18612) = 6, which 2

) is square-free, while for the representation ϕ(39330 of r = 19/47 in [2], we have ϕ(558362 ) gcd(393300, 55836) = 18, which is not square-free. The main purpose of this note is to establish the following result.

doi.org/10.1080/00029890.2021.1850142 MSC: Primary 11A25, Secondary 11D85

174

c THE MATHEMATICAL ASSOCIATION OF AMERICA 

[Monthly 128

2

) Theorem 1. Any positive rational number can be written uniquely as ϕ(m , where ϕ(n2 ) m, n ∈ N, such that vp (m)  = vp (n) for every prime p|mn and gcd(m, n) is squarefree.

Proof. Note that ϕ(mp) = pϕ(m) for any prime p with p|m. Hence ϕ(m21 ) ϕ(m2 ) = , ϕ(n2 ) ϕ(n21 ) m n rad(gcd(m, n)), n1 = gcd(m,n) rad(gcd(m, n)); thus where m1 = gcd(m,n) gcd(m1 , n1 ) = rad(gcd(m, n)) is square-free. Therefore, by the proof of the main 2) result of [2], we have that each positive rational number can be written as ϕ(m , ϕ(n2 ) where m, n ∈ N such that vp (m)  = vp (n) for every prime p|mn and gcd(m, n) is square-free. Now we will prove the uniqueness. Let r be a positive rational number and let

r=

ϕ(m2 ) , ϕ(n2 )

(2)

where m, n are positive integers such that vp (m)  = vp (n) for every prime p|mn and gcd(m, n) is square-free. We will show that m and n are uniquely determined by r. We prove this by induction on P (r). Let p = P (mn). Then we have ⎧ ⎪   ⎨2vp (m) − 2vp (n), if vp (m) > 0 and vp (n) > 0, ϕ(m2 ) = (3) vp 2vp (m) − 1, if vp (n) = 0, ⎪ ϕ(n2 ) ⎩−2v (n) + 1, if vp (m) = 0. p Since vp (m)  = vp (n) for every prime p|mn, by (2) and (3) we have P (r) = P (mn). Now we come to the base step of the induction on P (r), where P (r) = 2. For any nonzero integer c and any representation of 2c =

ϕ(m2 ) , ϕ(n2 )

where m, n are positive integers such that vp (m)  = vp (n) for every prime p|mn and gcd(m, n) is square-free, we show that m and n are uniquely determined by c. We have that m = 2x and n = 2y for x, y ∈ N ∪ {0}, and min{x, y} ∈ {0, 1} since gcd(m, n) is square-free. For simplicity, we assume that c > 0. It follows from (3) and min{x, y} ∈ {0, 1} that (x, y) = (c/2 + 1, 1) when c is even and (x, y) = ((c + 1)/2, 0) when c is odd. Therefore m and n are uniquely determined by r = 2c , i.e., such representation of 2c is unique. This proves the result for P (r) = 2. Now let p be an odd prime and assume that the result holds for P (r) < p. Let r be a positive rational number with P (r) = p. For the representation (2) of r, we have P (mn) = p, min{vp (m), vp (n)} ∈ {0, 1}, and vp (m)  = vp (n). If vp (r) > 0 and even, then vp (m) = vp (r)/2 + 1 and vp (n) = 1 by (3) and min{vp (m), vp (n)} ∈ {0, 1}. (The case where vp (r) < 0 is similar and we omit the details.) Hence vp (m) and vp (n) are uniquely determined by vp (r). Let r0 = r/p vp (r) . ϕ(m2 )

Then we have r0 = ϕ(n21) , where m1 = m/p vp (m) , n1 = n/p vp (n) . It is easy to check 1 that m1 and n1 are positive integers such that vq (m1 )  = vq (n1 ) for every prime q|m1 n1 February 2021]

NOTES

175

and gcd(m1 , n1 ) is square-free. Since P (r0 ) < P (r) = p, by the induction hypothesis m1 and n1 are uniquely determined by r0 . Therefore such representation of r is unique. If vp (r) > 0 and odd, then vp (m) = (vp (r) + 1)/2 and vp (n) = 0 by (3) and min{vp (m), vp (n)} ∈ {0, 1}. (The case where vp (r) < 0 is similar, and we omit the details.) Hence vp (m) and vp (n) are uniquely determined by vp (r). In this case, we let r0 = r/p vp (r) (p − 1). Then we have r0 =

ϕ(m21 ) , ϕ(n21 )

where m1 = m/p vp (m) and n1 = n. Note that m1 and n1 are positive integers such that vq (m1 )  = vq (n1 ) for every prime q|m1 n1 and gcd(m1 , n1 ) is square-free. Since P (r0 ) < P (r) = p, by the induction hypothesis m1 and n1 are uniquely determined by r0 . Therefore such representation of r is also unique. In view of the remarks above, we have proved that the representation (2) of r is unique. This completes the proof. Theorem 1 improves the main result of D. Krachun and Z. Sun in [2]. As a consequence of Theorem 1, we have Corollary 1. Let r be a positive rational number and r =

ϕ(m20 ) ϕ(n20 )

the unique represen2

) tation of r as in Theorem 1. Then for any representation of r = ϕ(m , m, n ∈ N, we ϕ(n2 ) have m = m0 d and n = n0 d, where d is a positive integer such that p| gcd(m0 , n0 ) or p  |m0 n0 for every prime divisor p of d. In particular, if ϕ(m2 ) = ϕ(n2 ), m, n ∈ N, then m = n.

ACKNOWLEDGMENTS. We would like to thank the referees for carefully reading our paper and for giving such constructive comments which substantially helped improve the quality of the paper. The second author was supported by NSF of China (No. 11671153) and NSF of Guangdong Province (No. 2016A030313850).

REFERENCES [1] Ireland, K., Rosen, M. (1990). A Classical Introduction to Modern Number Theory, 2nd ed. New York: Springer-Verlag. [2] Krachun, D., Sun, Z. (2020). Each positive rational number has the form ϕ(m2 )/ϕ(n2 ). Amer. Math. Monthly. 127(9): 847–849. [3] Sun, Z. (2017). Conjectures on representations involving primes. In: Nathanson, M., ed. Combinatorial and Additive Number Theory II. Springer Proceedings in Mathematics and Statistics, Vol. 220. Cham: Springer, pp. 279–310. School of Mathematical Science, South China Normal University, Guangzhou 510631, China [email protected] School of Mathematical Science, South China Normal University, Guangzhou 510631, China [email protected] School of Mathematical Science, South China Normal University, Guangzhou 510631, China [email protected]

176

c THE MATHEMATICAL ASSOCIATION OF AMERICA 

[Monthly 128

The Natural Logarithm Modulo 2 Here, a (mod b) is the least positive element of the set {s : s = a − bk, k ∈ Z}. For example, −4.5 (mod 2.2) is 2.1. Some interesting identities can be obtained when a is replaced by a function and the result is integrated; see for instance [1, pp. 109– 111]. We establish such an identity now. Theorem. Let log(·) denote the natural logarithm. Then 

1

log(x) (mod 2) dx = coth(1).

0

Proof. We proceed by splitting our integral root-wise; consider the adjacent open intervals In = (e−2n−2 , e−2n ) where n = 0, 1, 2 . . . . At endpoints, log(x) differs by exactly 2, so an appeal to concavity implies that our integrand is continuous on each In . The points in [0, 1] not in any In form a countable set, so it suffices to integrate over all In . It is easily checked that the derivative of our integrand is x −1 on In , meaning log(x) (mod 2) on In is a vertical shift of log(x). This shift is the subtraction of the greatest even integer less than log(x) on In , which would be −2n − 2. Because −2n − 2 < log(x) < 0 on In , we consider the area under the curve y = log(x) and above the line y = −2n − 2 on In to proceed. Put d(n) = (2n + 2)(e−2n − e−2n−2 ), the area of the region from which we must exclude the unsigned integral of log(x) on In . Then 

1

log(x) (mod 2) dx =

0

∞   k=0

=

∞  



 d(k) +

log(x) dx Ik

e−2k−2 + e−2k



k=0

=

e2 + 1 = coth(1). e2 − 1

REFERENCE [1] Havil, J. (2003). Gamma: Exploring Euler’s Constant. Princeton, NJ: Princeton Univ. Press.

—Submitted by Matthew A. Niemiro doi.org/10.1080/00029890.2021.1851131 MSC: Primary 26A06, Secondary 11A07

February 2021]

177

PROBLEMS AND SOLUTIONS Edited by Daniel H. Ullman, Daniel J. Velleman, and Douglas B. West with the collaboration of Paul Bracken, Ezra A. Brown, Zachary Franco, L´aszl´o Lipt´ak, Rick Luttmann, Hosam Mahmoud, Frank B. Miles, Lenhard Ng, Kenneth Stolarsky, Richard Stong, Stan Wagon, Lawrence Washington, and Li Zhou.

Proposed problems should be submitted online at americanmathematicalmonthly.submittable.com/submit. Proposed solutions to the problems below should be submitted by June 30, 2021, via the same link. More detailed instructions are available online. Proposed problems must not be under consideration concurrently at any other journal nor be posted to the internet before the deadline date for solutions. An asterisk (*) after the number of a problem or a part of a problem indicates that no solution is currently available.

PROBLEMS 12230. Proposed by David Callan, University of Wisconsin, Madison, WI. Let [n] = {1, . . . , n}. Given a permutation (π1 , . . . , πn ) of [n], a right-left minimum occurs at position i if πj > πi whenever j > i, and a small ascent occurs at position i if πi+1 = πi + 1. Let An,k denote the set of permutations π of [n] with π1 = k that do not have right-left minima at consecutive positions, and let Bn,k denote the set of permutations π of [n] with π1 = k that have no small ascents. (a) Prove |An,k | = |Bn,k | for 1 ≤ k ≤ n. (b) Prove |An,j | = |An,k | for 2 ≤ j < k ≤ n. 12231. Proposed by George Apostolopoulos, Messolonghi, Greece. For an acute triangle ABC with circumradius R and inradius r, prove       B −C C−A R A−B + sec + sec ≤ + 1. sec 2 2 2 r 12232. Proposed by Se´an Stewart, Bomaderry, Australia. Prove 

1 0

 0

1



1 1 dx dy = √ 4π x(1 − x) y(1 − y) 1 − xy







e−t t −3/4 dt

4 .

0

12233. Proposed by C. R. Pranesachar, Indian Institute of Science, Bengaluru, India. Let n and k be positive integers with 1 ≤ k ≤ (n + 1)/2. For 1 ≤ r ≤ n, let h(r) be the number of k-element subsets of {1, . . . , n} that do not contain consecutive elements but that do contain r. For example, with n = 7 and k = 3, the string h(1), . . . , h(7) is 6, 3, 4, 4, 4, 3, 6. Prove (a) h(r) = h(r + 1) when r ∈ {k, . . . , n − k}. (b) h(k − 1) = h(k) ± 1. (c) h(r) > h(r + 2) when r ∈ {1, . . . , k − 2} and r is odd. (d) h(r) < h(r + 2) when r ∈ {1, . . . , k − 2} and r is even. doi.org/10.1080/00029890.2021.1853446

178

c THE MATHEMATICAL ASSOCIATION OF AMERICA 

[Monthly 128

12234. Proposed by Nicolai Osipov, Siberian Federal University, Krasnoyarsk, Russia. Let p be an odd prime, and let Ax 2 + Bxy + Cy 2 be a quadratic form with A, B, and C in Z such that B 2 − 4AC is neither a multiple of p nor a perfect square modulo p. Prove that  (Ax 2 + Bxy + Cy 2 ) 0