The secrets of the number 42

How a perfectly banal number caught the attention of science fiction enthusiasts, geeks … then mathematicians.

Humanicus
16 min readOct 19, 2020

Everyone has a fascination with unresolved cases, such as the death of Minister Robert Boulin or the disappearance of Xavier Dupont de Ligonnès. This remains true even if originally there was only one joke, as in the science fiction novel The Hitchhiker’s Guide to the Galaxy, which appeared in English in 1979. Douglas Adams, its author, mentions in the final part of this work that the answer to the big question about life, the universe, and everything is 42 (“The answer to the ultimate question of life, the universe and everything is 42”).

This first novel in a series of five is about an ultra-powerful computer which, while computing over 7.5 million years, ends up answering “42” to those who ask him about the ultimate question about life, the universe, and everything in between. The characters realize that, unfortunately, the answer given at the end of the first story is not very helpful, as the question was not phrased clearly and precisely enough. The computer then replies that to find the correct wording of the question, the answer to which is 42, it will have to build a new version of itself and that will take time. This new version of the computer is Earth … and to know the rest, you will need to read the books of Adams.

This choice by the author of the number 42 has become a central element of geek culture. He is the source of a multitude of jokes and winks exchanged between insiders. If, for example, you ask your search engine what the answer to the “big question about life, the universe and the rest” is, it will most likely answer: “42”. This is for example the case for Google, for Qwant, for Wolfram Alpha, specializing in mathematical calculation problems, but also for the Cleverbot dialogue assistant.

Private computer schools known as “42 schools” were created in 2013 and their name was clearly chosen in reference to the novels of Douglas Adams. The development abroad of new “campus 42” is planned at a rate of ten per year. The number 42 also appears in different forms in the movie Spider-Man: New Generation. You will find a multitude of other intentional occurrences and allusions to 42 listed, for example in Wikipedia’s article “The Big Question on Life, Universe and the Rest”.

More bizarrely, but this time it was coincidences the meaning of which it would be futile to seek, it was noted, among many other things, that:

  • in ancient Egypt, during the judgment of the soul, the dead person had to declare before 42 judges that they had not committed 42 sins [see Wikipedia article “Judgment of the soul (ancient Egypt)”];
  • the distance to be covered in a marathon is 42.195 kilometers because this is the distance that the Greek messenger Philippides traveled in 490 BCE between Marathon and Athens to announce the victory against the Persians. The fact that at that time the kilometer was not defined should only increase our astonishment;
  • there would have been 42 ancient Tibetan emperors. Nyatri Tsenpo, who reigned around 127 BCE, was the first, and Langdarma, who reigned from 836 to 842, the last (see Wikipedia’s “List of emperors of Tibet” article);
  • the Gutenberg Bible, the first book printed in Europe, has 42 lines of text per column and is also called “Latin Bible with forty-two lines”;

Douglas Adams story

Here is an excerpt from chapter 27 of Douglas Adams’s novel, The Hitchhiker’s Guide to the Galaxy, where the famous number 42 appears, which has become a fetish for geeks and more generally for computer scientists around the world:

-Are you ready to provide it to us? insisted Debilglos.

-Yes.

-Now ?

-Now, confirmed Deep Thoughts.

-They both wet their parched lips.

-Although, added Deep Thoughts, I don’t think you like her.

-Not important ! said Schnocdlu. We must know it. Now !

-Now ? Deep Thoughts insisted.

-Yes ! Now…

-“Okay,” said the computer, which fell silent again.

-The two men could no longer keep still. The tension was absolutely unbearable.

-She’s not going to please you, observed Deep Thoughts.

-Tell us anyway!

-Okay, Deep Thoughts said. The answer to the big question …

-Yes…!

-Of Life, of the Universe, and of the Remainder …, continued Deep Thoughts.

-Yes…!

-It’s…, Deep Thoughts said, pausing.

-Yes… !?

-It is…

-Yes… !!!…?

-“Forty-two,” said Deep Thoughts, with infinite calm and majesty.

An arbitrary choice

He was of course asked whether the use of 42 in the Douglas Adams novel had any special meaning in his mind. His answer is clear: “It was a joke. It had to be an ordinary and a rather small number, and I chose this one. Binary representations, base 13, Tibetan monks are just nonsense. I sat down at my desk, looked in the backyard, and thought ’42 will go’ and wrote it down.”

The evocation of base 2 comes from what 42 is written in the binary system 101010, which is quite simple and has also resulted in some geeks having a party on October 10, 2010 (10–10- 10). The mention of base 13 in his answer can be explained in a more indirect way. On several occasions, the novel mentions that 42 would be the answer to the question “how much is 6 times 9?”. Of course, this is absurd, since 6 × 9 = 54 … but precisely, in base 13, the number that is written 42 is equal to 4 × 13 + 2 = 54.

Next to the occurrences introduced voluntarily by computer scientists for fun, and the inevitable encounters with the number 42 when we look everywhere in history or in the world, we can still wonder if 42 is a particular number of the strict point of view of mathematics.

Mathematically singular?

Here is a list of some mathematical properties of 42.

• 42 is the sum of the first three powers of 2 odd exponents (2¹ + 2³+ 2⁵ = 42). The sequence a(n) of sums of odd powers of 2 is the sequence A020988 from Neil Sloane’s encyclopedia of digital sequences (https://oeis.org). In base 2, its n-th element is written 1010 … 10, with “10” repeated n times, and its formula is a(n) = (2/3) (4 — 1). As n increases, the frequency of these numbers tends towards zero, which means that the numbers that belong to this list, therefore 42 itself, are exceptionally rare.

• 42 is the sum of the first two powers of 6 with a non-zero exponent (6¹ + 6² = 42). The sequence b(n) of sums of powers of 6 is the sequence A105281 from Sloane’s encyclopedia. It is defined by the formulas b(0) = 0, b (n) = 6b(n — 1)+6. The frequency of these numbers also tends from 0 to infinity.

• 42 is a Catalan number. Catalan numbers were mentioned, under another name, for the first time by Leonhard Euler, who wanted to know the number of different ways to cut into several triangles a convex polygon with n sides by joining vertices by line segments. The start of the sequence (A000108 at Neil Sloane) is 1, 1, 2, 5, 14, 42, 132, … The formula c(n)=(2n)! / (N! (N+1)! ) gives the n-th term of this sequence of numbers whose density, like those of the two preceding ones, is zero at infinity.

The numbers in the c(n) sequence are named in honor of the Franco-Belgian mathematician Eugène Charles Catalan (1814–1894), who discovered that c(n) is the number of ways to arrange n pairs of parentheses while respecting the Usual rules for writing parentheses: a parenthesis is never closed before it has been opened, and parenthesis can only be closed when all those opened since it was opened are themselves closed.

For example, c(3)=5 because the possible arrangements of 3 pairs of parentheses are: ((())); () () (); (()) (); (() ()); () (()).

The number c(n) is also the number of binary trees bearing n + 1 leaves. It is also the number of ascending paths on a grid located under the first diagonal. This property makes it possible to understand the definition by induction of the terms of the Catalan sequence, c(0) = 1 and c(n + 1) = Σ c(k) c(n — k), the sum relating to the k ranging from 0 to n. Indeed, to count the number of paths going up to the abscissa n + 1, we consider an intermediate point, as low as possible, which touches the diagonal; those before (strictly below the diagonal) give c(n — k), those after (below in the broad sense of the diagonal) give c(k).

Catalan numbers are extremely
rare, much more than prime numbers: only fourteen of these numbers are inferior
to 1 billion. Their sequel begins with:

1, 1, 2, 5, 14, 42, 132, 429, 1,430, 4,862, 16,796, 58,786, 208,012, 742,900, 2,674,440, 9,694,845, 35,357,670, 129,644,790, 477 638 700, 1 767 263 190, 6 564 120 420, 24 466 267 020, 91 482 563 640, 343 059 613 650, 1 289 904 147 324, 4 861 946 401 452, 18 367 353 072 152, 69 533 550 916 004, 263 747 951 750 360, …

The number 42 is the Catalan number c(5). In particular, this means that there are 42 ways to place 5 pairs of parentheses correctly (a): a pair never closes until it has been opened, and never closes before all those open since it has been opened. been open are themselves closed.

This also means that if we give ourselves a grid of side 5 and that, by following the sides of the squares of the checkerboard, we want to join the lower-left corner to the upper right corner without cutting the diagonal and without ever going down again. , there are 42 ways to do this (b).

Likewise, the number of 6-leaf binary trees is 42 (c ), the number of ways to pave the side of a 5-step staircase with rectangles is 42 (d), and the number of ways to cut out a heptagon regular in several triangles by joining vertices is 42 (e).

  • 42 is a “practical” number, which means that any integer between 1 and itself is the sum of some of its (distinct) divisors. The first practical numbers are 1, 2, 4, 6, 8, 12, 16, 18, 20, 24, 28, 30, 32, 36, 40, 42, 48, 54, 56, 60, 64, 66, 72 (continuation A005153 by Neil Sloane). We do not know any simple formula giving the n-th term of this sequence, and the limiting frequency of its terms seems positive this time.

This is all fun, but it is wrong to say that 42 is really outstanding mathematically. The numbers 41 or 43, for example, also belong to many series. To explore these questions, use the link https://en.wikipedia.org/wiki/42_(number), replacing 42 with the number you are interested in.

The problem of knowing which numbers are more particularly interesting or more particularly uninteresting has been studied, starting from the suites listed by Neil Sloane in his encyclopedia. Besides a theoretical link with the complexity of Kolmogorov (the interesting numbers are those with at least a brief description), it has been shown a specific cultural effect for the numbers retained by the encyclopedia of Neil Sloane, which is, therefore, something else. than an encyclopedia based on pure mathematical objectivity (see the bibliography).

From the number 42 to the problem of the sums of three cubes!

Computer scientists and mathematicians know the appeal of the number 42 and have always thought that it was a simple game that could just as easily have been played with another number. There is still a recent news item that kept them amused. The number 42 actually gave a lot more trouble than any other number below 100 in the 3 cube problem.

The 3 cube problem is stated as follows:

What are the integers n that can be written as a sum of three cubes of integers, n = a³ + b³ + c³? And, when it does, how do you find a, b and c?

The difficulty, even on a practical level in carrying out calculations, arises from the fact that, for a given n, the space of triples to be explored involves negative integers. This space is therefore infinite, which is not the case when we are interested in sums of squares: in such a sum of squares giving n, each square has an absolute value less than ℘∠n. Moreover, for sums of squares, we know perfectly well what is possible and impossible.

The sums of squares

We only know since September 2019 that the number 42 is the sum of three cubes. The sums of cubes are difficult to master because of the negative integers. In contrast, the sums of squares
whole numbers, which have interested mathematicians since ancient times, are now well known. Here are the results of them.

Sums of two squares

- An odd prime number is the sum of two squares of integers if and only if it is of the form 4k + 1. The sum decomposition of two squares is then unique. Examples: 5 = 1² + 2², 13 = 2² + 3², 17 = 1² + 4².

- An integer n is the sum of two squares if and only if each of its prime factors of the form 4k + 3 occurs with an even exponent in the prime factorization of n.

Example: 45 = 3²5 = 6² + 3².

The prime factorization of 45 involves 3, which is of the form 4k + 3, with an even exponent. The number 45, therefore, satisfies the condition of the theorem and is effectively written as the sum of two squares
(see Fermat’s two-square theorem).

Sum of three squares

- All integers except those of the form 3n and 8n + 7 are sums of three squares
(see three-square theorem).

Sums of four squares

Any integer is the sum of four squares. This magnificent theorem was demonstrated in 1770 by Lagrange and demonstrated again in 1772 by Euler.
(see Lagrange’s Four Squares Theorem).

In the case of cubes, we find very large unexpected solutions, like the one for 156, discovered in 2007:

156 = 26577110807569³ + (- 18161093358005)³ + (- 23381515025762)³.

The first thing to note for anyone interested in sums of three cubes is that for some values ​​of the integer n, the equation n = a³ + b³ + c³ has no solution. This is the case for all integers n of the form 9m + 4 and 9m + 5 (for example 4, 5, 13, 14, 22, 23). The proof of this statement is quite simple. We use the “modulo 9” calculation, which amounts to assuming that 9 = 0 and only handling numbers between 0 and 8 or between — 4 and + 4.

We note first that:

0³ = 0 (mod 9);
1³ = 1 (mod 9);
2³ = 8 = — 1 (mod 9);
3³= 27 = 0 (mod 9);
4³ = 64 = 1 (mod 9);
5³ = (- 4)³ = — 64 = — 1 (mod 9);
6³ = (-3)³ = 0 (mod 9);
7³ = (- 2)³ = 1 (mod 9);
8³ = (- 1) ³ = –1 (mod 9).

In other words: modulo 9, the cube of an integer is worth either — 1 (= 8), or 0, or 1. However, the addition of three numbers chosen from 0, 1 and — 1 gives:

0 = 0 + 0 + 0 = 0 + 1 + (- 1);
1 = 1 + 0 + 0 = 1 + 1 + (- 1);
2 = 1 + 1 + 0; 3 = 1 + 1 + 1;
6 = — 3 = (- 1) + (- 1) + (- 1);
7 = — 2 = (- 1) + (- 1) + 0;
8 = — 1 = (- 1) + 0 + 0 = 1 + (- 1) + (- 1).

We never get 4 or 5 (= — 4). This means that the sums of three cubes are never numbers of the form 9m + 4 or 9m + 5. We will say that n = 9m + 4 and n = 9m + 5 are forbidden values.

The search for solutions, in practice

To illustrate how difficult the search for solutions to the equation n=a³+b³+c³ is, let’s show what happens for n = 1 and n = 2.

For n = 1, there are the obvious solution 1³+1³+(-1)³=1.

Are there others? Yes :

9³ + (- 6)³ + (- 8)³ = 729 + (- 216) + (- 512) = 1.

This is not the only one, because in 1936, the German mathematician Kurt Mahler proposed endless solutions. For all integer p:

(9p⁴)³+ (3p — 9p⁴)³+ (1–9p³)³= 1.

We prove the result using the remarkable identity:
(A + B)³ = A³ + 3A²B + 3 AB² + B³.

An infinite set of solutions is also known for n = 2; it was discovered in 1908 by a certain A. S. Werebrusov. For all integer p:

(6p³ + 1)³+ (1–6p³)³+ (- 6p2)³= 2.

By multiplying each term of these equalities by the cube of an integer, , we deduce that there is also an infinity of solutions for any cube of an integer and any double of the cube of an integer.

For 16 for example, which is double the cube of 2, we have: 14³ + (- 10)³+ (- 12)³= 16

Let us also indicate that for n = 3, in August 2019 only two solutions were known:

1³ + 1³ + 1³ = 3 and 4³ + 4³ + (- 5)³= 3.

The question then naturally comes to mind: are there solutions for all the non-forbidden values ​​of n?

Computers at work

To answer, we started by taking the sequence of non-prohibited values ​​1, 2, 3, 6, 7, 8, 9, 10, 11, 12, 15, 16, … (A060464 by Neil Sloane) by studying them one by one. If none of those studied turns out to be impossible, we will have reasons to conjecture that for any integer n which is not of the form n = 9m + 4 or n = 9m + 5, there are solutions to the equation n = A³ + b³ + c³.

The research carried out, depending on the power of the computers or computer networks used, has yielded an increasing number of results. They are the ones who will again lead us to the famous and intriguing number 42.

In 2009, Andrea-Stephan Elsenhans and Jörg Jahnel, using a method proposed by Noam Elkies in 2000, explored all triplets a, b, c of integers with an absolute value less than 1014 to find the solutions for n between 1 and 1000. Their article concluded that the question of the existence of a solution for numbers less than 1000 remained open only for 33, 42, 74, 114, 165, 390, 579, 627, 633, 732, 795, 906, 921, and 975.

For integers, less than 100, only three puzzles remained: 33, 42, and 74.

In 2016, Sander Huisman explored a bit further and found a solution for
74:(–284650292555885)³+(66229832190556)³+(283450105697727)³.

Then only 33 and 42 remained for n less than 100. In March 2019, Andrew Booker settled the case of 33: (8866128975287528)³ + (- 8778405442862239)³ + (- 2736111468807040)³. Therefore, the Douglas Adams number was the last positive integer, less than 100, for which it was not known whether it could be written as a sum of three cubes of integers.

If the answer had been no, there would have been a really serious mathematical reason for giving importance to 42; it would have been the first number possibly sum of three cubes that would not have been. Computers struggled, but this brief hope failed.

At the beginning of September 2019, 42 was the smallest positive integer and the only one less than 100 for which it was not known whether it was the sum of three cubes of integers.

Andrew Booker, University of Bristol, England, and Andrew Sutherland, MIT, USA, used the Charity Engine calculation system to conduct a massive exploration calculation equivalent to over 1 million hours calculation of a current desktop computer. A solution was found:

42 = (- 80 538 738 812 075 974)³ + 80 435 758 145 817 515³ + 12 602 123 297 335 631³.

The Charity Engine calculation system coordinates more than 500,000 personal machines of volunteers. It makes them work during the times when they are not in use, which allows them to perform huge calculations at a lower cost. Charity Engine is based on a UC Berkeley program and managed by the Worldwide Computer Company.

The residual home computing power of the project computers is sold to universities and businesses. Profits are donated to charities or used to organize periodic raffles to reward network participants. Unbought computing power is allocated to various IT projects.

The same method also led to the discovery of an unexpected expression of 3 as the sum of three cubes:

3 = (- 472 715 493 453 327 032)³ + (- 569 936 821 113 563 493 509)³ + 569 936 821 221 962 380 720³.

The only integers less than 1000 that are now unknown whether they are the sum of three cubes are 114, 390, 579, 627, 633, 732, 921, and 975.

The answer came in September 2019. It was the result of a staggering calculation coordinated by Andrew Booker and Andrew Sutherland. Computers participating in the Charity Engine network of personal computers computing for the equivalent of over 1 million hours found that:

42 = (- 80538738812075974)³ +
80435758145817515³ + 12602123297335631³

The cases of the integers 165, 795, and 906 were also recently resolved. So only the cases of 114, 390, 579, 627, 633, 732, 921, and 975 remain to be settled for integers less than 1000.

The conjecture that there are solutions for all n which are not of the form 9m+4 or 9m+5, therefore, seems to be confirmed. In 1992, Roger Heath-Brown came up with a stronger conjecture stating that for all possible n, there are endless ways to write them as the sum of three cubes. The work is therefore far from over.

The difficulty of the problem appears enormous, which suggests that the problem “n is it a sum of three cubes?” Could be undecidable. In other words, it could be that no algorithm, however clever, is able to deal with all possible cases. This is the case with program termination, Alan Turing had shown in 1936 that no single algorithm can handle them all. But here we are in a purely numerical realm that is very easy to state, and so if we could prove such undecidability, it would be a novelty.

The number 42 was difficult, but it was only a step!

--

--

Humanicus

Please follow me since now we need 100 min follower on medium