Secrets of Succession
In Atlanta I met a man with an unusual hobby. Neil Sloane collects numbers. Not individual numbers, that would be silly, but families of numbers in ordered lists called sequences. For example, the natural numbers are a sequence, which can be defined by saying that the nth term in the sequence is n:
1, 2, 3, 4, 5, 6, 7…
Sloane started his collection in 1963, as a graduate student at Cornell, where he first wrote the sequences on cards. It made perfect sense for someone who liked ordered lists to make an ordered list of them. By 1973 he had reached 2400 sequences, which he published in a book entitled A Handbook of Integer Sequences. By the mid nineties he was up to 5500. Only with the invention of the internet, however, did the collection find its ideal medium. Sloane’s list blossomed into the On-Line Encyclopedia of Integer Sequences, a compendium that now has more than 160,000 entries, and expands by about 10,000 a year.
On first acquaintance, Sloane appears a typical indoors type. He is slight, bald and wears thick, square glasses. Yet he is also sinewy and tough, carrying himself with a Zen-like poise – a benefit of his other passion, which is rock-climbing. Sloane likes the challenges of ascending geological formations just as much as he likes ascending numerical ones. In Sloane’s opinion, the similarity between studying sequences and rock-climbing is that they both demand shrewd puzzle-solving skills. I’d say there’s another parallel: sequences encourage the number equivalent of mountaineering – whenever you reach term n the natural inclination is to find term n + 1. The desire to reach the next term is like the desire to climb higher and higher peaks; although mountaineers, of course, are restricted by geography, while sequences will often carry on for ever and ever.
Like a record collector who stacks the old favourites by the colourful rarities, Sloane embraces the common as well as the bizarre for his Encyclopedia. His collection contains, for example, the sequence below, the ‘zero sequence’, which consists of only 0s. (Each sequence in the Encylopedia. Byn> is given a reference number prefixed by the letter A. The zero sequence was the fourth sequence Sloane collected, and hence is known as A4.)
(A4) 0, 0, 0, 0, 0…
As the simplest-possible unending sequence, it is the least dynamic in the collection, although it does have a certain nihilistic charm.
Maintaining the On-Line Encyclopedia is a full-time job for Sloane, which he does in addition to his real job as a mathematician at AT&T Labs in New Jersey. But he no longer needs to spend time rooting around for new sequences. With the Encyclopedia’s success, he is constantly receiving submissions. They come from professional mathematicians and, in larger numbers, numerically obsessed lay-people. Sloane has only one criterion for letting a sequence join the club: it must be ‘well defined and interesting’. The former just means that each term in the sequence can be described, either algebraically or rhetorically. The latter is a matter of his judgement, although his tendency is to accept if he’s ever unsure. Being well defined and interesting, however, does not mean there is something mathematical going on. History, folklore and quirkiness are all fair game.
Among the sequences included in the Encyclopedia is the ancient sequence:
(A100000) 3, 6, 4, 8, 10, 5, 5, 7
The sequence numbers are the translation into digits of marks made on one of the oldest-known mathematical objects: the Ishango bone, a 22,000-year-old artefact found in what is now the Democratic Republic of the Congo. The monkey bone was initially thought to be a tally stick, but it has since been suggested that the pattern of 3, followed by its double, then 4, followed by its double, then 10, followed by its half, indicates more sophisticated arithmetical reasoning. There’s also a hateful sequence in the collection:
(A51003) 666, 1666, 2666, 3666, 4666, 5666, 6660, 6661…
This sequence is also known as the Beastly numbers, since they are the numbers containing the string 666 in their decimal expansion.
On a lighter note, here’s a nursery sequence:
(A38674) 2, 2, 4, 4, 2, 6, 6, 2, 8, 8, 16
These are the numbers from the Latin American children’s song ‘La Farolera’: ‘Dos y dos son quatro, cuatro y dos son seis. Seis y dos son ocho, y ocho dieciseis.’
But perhaps the most classic sequence of all is the prime numbers:
(A40) 2, 3, 5, 7, 11, 13, 17, 19, 23, 29, 31, 37…
Prime numbers are the natural numbers greater than 1 that are divisible only by themselves and 1. They are simple to describe but the sequence exhibits some rather spectacular, and sometimes mysterious, qualities. First, as Euclid proved, there is an infinite number of them. Think of a number, any number, and you will always be able to find a prime number higher than that number. Second, every natural number above 1 can be written as a unique product of imes. In other words, every number is equal to a unique set of prime numbers multiplied by each other. For example, 221 is 13×17. The next number, 222, is 2×3×37. The one after that, 223, is prime, so produced only by 223×1, and 224 is 2×2×2×2 × 2 × 7. We could carry on for ever and each number could be winnowed down to a product of primes in only one possible way. For example, a billion is 2×2 × 2 × 2 × 2 × 2 × 2 × 2 × 2 × 5 × 5 × 5 × 5 × 5 × 5 × 5 × 5 × 5. This characteristic of numbers is known as the fundamental theorem of arithmetic, and is why primes are considered the indivisible building blocks of the natural number system.
Primes are also building blocks when we add them together. Every even number bigger than 2 is the sum of two primes:
4 = 2 + 2
6 = 3 + 3
8 = 5 + 3
10 = 5 + 5
12 = 5 + 7
…
222 = 199 + 23
224 = 211 + 13
…
This proposition, that every even number is the sum of two primes, is known as the Goldbach Conjecture, named after the Prussian mathematician Christian Goldbach, who corresponded with Leonhard Euler about it. Euler was ‘entirely certain’ that the conjecture was true. In almost 300 years of looking and trying, no one has found an even number that is not the sum of two primes, but so far no one has actually been able to prove that the conjecture is true. It is one of the oldest and most famous unsolved problems in mathematics. In 2000, so confident were they that a proof was still beyond the limits of mathematical knowledge that the publishers of the mathematical detective story Uncle Petros and Goldbach’s Conjecture offered a $1,000,000 prize for anyone who could solve it. No one did.
The Goldbach Conjecture is not the only unresolved issue regarding the primes. Another focus of study is how they seem to be scattered unpredictably along the number line, with no obvious pattern to the sequence. In fact, the search for the harmonies that underpin the distribution of the primes is one of the richest areas of enquiry in number theory, and it has led to many deep results and suppositions.
For all their pre-eminence, however, the primes do not have exclusive claim among the sequences to holding special secrets of mathematical order (or disorder). All sequences contribute in some way to a greater appreciation of how numbers behave. Sloane’s On-Line Encyclopedia of Integer Sequences can also be considered a compendium of patterns, a Domesday Book of mathematical DNA, a directory of the underlying numerical order of the world. It might have sprung from Neil Sloane’s personal obsession, but the project has become a truly important scientific resource.
Sloane compares the Encyclopedia to a maths equivalent of the FBI fingerprint database. ‘When you go to a crime scene and you take a fingerprint, you then check it against the file of fingerprints to identify the suspect,’ he said. ‘It’s the same thing with the Encyclopedia. Mathematicians will come up with a sequence of numbers that occurs naturally in their work, and then they look it up in the database – and it’s lovely for them if they find it there already.’ The database’s usefulness is not restricted to pure mathematics. Engineers, chemists, physicists and astronomers have also looked up, and found, sequences in the Encyclopedia, making unexpected connections and gaining mathematical insights into their own fields. For anyone who is working in an area that spews out unfathomable number sequences that they hope to make some sense of, the database is a goldmine.
Through the Encyclopedia, Sloane sees a lot of new mathematical ideas, and he also spends time inventing his own. In 1973 he came up with the concept of the ‘persistence’ of a number. This is the number of steps that it takes to get to a single digit by multiplying all the digits of the preceding number to obtain a second number, then multiplying all the digits of that number to get a third number, and so on until you get down to a single digit. For example:
88
8 × 8 = 64
6 × 4 = 24
2 × 4 = 8
So, according to Sloane’s system, 88 has persistence 3, since it takes three steps to get to a single digit. It would seem likely that the bigger a number is, the bigger its persistence. For example, 679 has persistence 5:
679
378
168
48
32
6
Likewise, if we worked it out here, we would find that 277777788888899 has persistence 11. Yet here’s the thing: Sloane has never discovered a number that has a persistence greater than 11, even after checking every number all the way up to 10233, which is 1 followed by 233 zeros. In other words, whatever 233-digit number you choose, if you follow the steps of multiplying all the digits together according to the rules for persistence, you will get to a single-digit number in 11 steps or fewer.
This is splendidly counter-intuitive. It would seem to follow that if you have a number with 200 or so digits consisting of lots of high digits, say 8s and 9s, then the product of these individual digits would be sufficiently large that it would take well over 11 steps to reduce to a single digit. Large numbers, however, collapse under their own weight. This is because if a zero ever appears in the number, the product of all the digits is zero. If there are no zeros in the number to start with, a zero will always appear by the eleventh step, unless the number has already been reduced to a single digit by then. In persistence Sloane found a wonderfully efficient giant-killer.
Not stopping there, Sloane has compiled the sequence in which the nth term is the smallest number with persistence n. (We are considering only numbers with at least two digits.) The first such term is 10, since:
10
0 and 10 is the smallest two-digit number that reduces in one step.
The second term is 25, since:
25
10
0 and 25 is the smallest number that reduces in two steps.
The third term is 39, since:
39
27
14
4 and 39 is the smallest number that reduces in three steps.
The full list is:
(A3001) 10, 25, 39, 77, 679, 6788, 68889, 2677889, 26888999, 3778888999, 277777788888899
I find this list of numbers strangely fascinating. There is a distinct order to them, yet they also are a bit of an asymmetric jumble. Persistence is sort of like a sausage machine that produces only 11 very curiously shaped sausages.
Sloane’s good friend Princeton professor John Horton Conway also likes to amuse himself by coming up with offbeat mathematical concepts. In 2007 he invented the concept of a powertrain. For any number written abcd…, its powertrain is abcd…In the case of numbers where there is an odd number of digits, the last digit has no exponent, so abcde goes to abcde. Take 3462. It reduces to 3462 = 81 × 36 = 2916. Reapply the powertrain until only a single digit is left:
3462
2916
2916 = 512 × 1 = 512
512 = 10
10 = 1
Conway wanted to know if there were any indestructible digits – numbers that did not reduce to a single digit under the powertrain. He could find only one:
2592
2592 = 32 × 81 = 2592
Not one to sit idly by, Neil Sloane took up the chase and uncovered a second:*
24547284284866560000000000
Sloane is now confident that there are no other indestructible digits.
Consider that for a moment: Conway’s powertrain is such a lethal machine that it annihilates every number in the universe apart from 2592 and 24547284284866560000000000 – two seemingly unrelated, fixed points in the never-ending expanse of numbers. ‘The result is spectacular,’ said Sloane. Big numbers die frly quickly under the powertrain calculation for the same reason that they do under persistence – a zero appears and the whole thing reduces to naught. I asked Sloane if the robustness of the two numbers to survive the powertrain might have any application in the real world. He didn’t think so. ‘It is just amusing. Nothing wrong with that. You have to have fun.’
And Sloane does have fun. He has studied so many sequences that he’s developed his own number aesthetics. One of his favourite sequences was devised by the Colombian mathematician Bernardo Recamán Santos, called the Recamán sequence:
(A5132) 0, 1, 3, 6, 2, 7, 13, 20, 12, 21, 11, 22, 10, 23, 9, 24, 8, 25, 43, 62, 42, 63, 41, 18, 42, 17, 43, 16, 44, 15, 45…
Look at the numbers and try to see a pattern. Follow them carefully. They jump around neurotically. It’s all messed up: one up here, one down there, one over there.
In fact, though, the numbers are generated using the following simple rule: ‘subtract if you can, otherwise add’. To get the nth term, we take the previous term and either add or subtract n from it. The rule is that subtraction must be used unless that results in either a negative number or in a number that is already in the sequence. Here’s how the first eight terms are calculated.
And so on.
This rather plodding process takes the integers and calculates answers that look totally haphazard. But a way to see the pattern that emerges is to plot the sequence as a graph, as shown below. The horizontal axis is the position of the terms, so the nth term is at n, and the vertical axis is the value of the terms. The graph of the first thousand terms of the Recamán sequence is probably unlike any other graph you have seen. It is like the spray of a garden sprinkler, or a child trying to join up dots. (The thick lines in the graph are clumps of dots, since the scale is so big.) ‘It is interesting to see how much order you can bring into chaos,’ Sloane remarked. ‘The Recamán sequence is right on the borderline between chaos and beautiful maths and that’s why it is so fascinating.’
The clash between order and disorder in the Recamán sequence can also be appreciated musically. The Encyclopedia has a function that allows you to listen to any sequence as musical notes. Imagine a piano keyboard with 88 keys, which comprise a spread of just under eight octaves. The number 1 makes the piano play its lowest note, the number 2 makes it play the second-lowest note, and so on all the way up to 88, which commands the highest note. When the notes run out, you start at the bottom again, so 89 is back to the first key. The natural numbers 1, 2, 3, 4, 5…sound like a rising scale set on an endless loop. The music created by the Recamán sequence, however, is chilling. It sounds like the soundtrack of a horror movie. It is dissonant, but it does not sound random. You can hear noticeable patterns, as if there is a human hand mysteriously present behind the cacophony.
The Recamán sequence.
The question that interests mathematicians about Recamán is whether the sequence contains every number. After 1025 terms of the sequence the smallest missing number is 852,655. Sloane suspects that every number will eventually appear, including 852,655, but this remains unproved. It’s not hard to understand why Sloane finds Recamán so compelling.
Another favourite of Sloane’s is Gijswijt’s sequence,* because, unlike many sequences that grow gloriously fast, Gijswijt’s increases at a mind-bogglingly dawdling pace. It’s a wonderful metaphor for never giving up:
(A90822) 1, 1, 2, 1, 1, 2, 2, 2, 3, 1, 1, 2, 1, 1, 2, 2, 2, 3, 2, 1, 1, 2…
The first time that a 3 appears is in the ninth position. A 4 appears for the first time in the 221st position. You would search until hell almost freezes over for the first time 5 rears its head, which occurs at about position 10100000000000000000000000.
This is an extremely large number. By comparison, the universe contains only 1080 elementary particles. Eventually, 6 pops up too, at a distance so far away that its position can only be conveniently described as a power of a power of a power of power:
The other numbers will also eventually appear, although – it must be stressed – with no sense of urgency. ‘The land is dying, even the oceans are dying,’ said Sloane with poetic flourish, ‘but one can take refuge in the abstract beauty of sequences like Dion Gijswijt’s A090822.’
As well as paying serious attention to prime numbers, the Greeks were even more enthralled by what they called perfect numbers. Consider the number 6: the numbers that divide it – its factors – are 1, 2 and 3. If you add 1, 2 and 3, voilà, you get 6 again. A perfect number is any number, like 6, that is equal to the sum of its factors. (Strictly speaking, 6 is also a factor of 6, but in discussions of perfection it only makes sense to include the factors of a number less than the given number.) After six, the next perfect number is 28 because the numbers that divide it are 1, 2, 4, 7 and 14, the sum of which is 28. Not only the Greeks, but Jews and Christians too attached cosmological significance to such numerical perfection. The ninth-century Benedictine theologian Rabanus Maurus wrote, ‘Six is not perfect because God has created the world in 6 days; rather, God has perfected the world in 6 days because the number was perfect.’
The practice of adding the factors of a number leads to the most whimsical concepts in maths. Two numbers are amicable if the sum of the factors of the first number equals the second number, and if the sum of the factors of the second number equals the first. For example, the factors of 220 are 1, 2, 4, 5, 10, 11, 20, 22, 44, 55 and 110. Added they equal 284. The factors of 284 are 1, 2, 4, 71 and 142. Together they make 220. Sweet! The Pythagoreans saw 220 and 284 as symbols of friendship. During the Middle Ages talismans with these numbers were made, to promote love. One Arab wrote that he tried to test the erotic effect of eatg something labelled with the number 284, while a partner was eating something labelled 220. It was only in 1636 that Pierre de Fermat discovered the second set of amicable numbers: 17,296 and 18,416. Because of the advent of computer processing, more than 11 million amicable pairs are now known. The largest pair has more than 24,000 digits each, which makes them tricky to write on a slice of baklava.
In 1918 the French mathematician Paul Poulet coined the term sociable for a new type of numerical friendship. The five numbers listed below are sociable because if you add up the factors of the first one, you get the second. If you add up the factors of the second, you get the third. If you add up the factors of the third, you get the fourth, the factors of the fourth give you the fifth, and the factors of the fifth get you back to where you started: they add up to the first:
12,496
14,288
15,472
14,536
14,264
Poulet discovered only two chains of sociable numbers – the five numbers above and a less exclusive gang of 28 numbers beginning with 14,316. The next set of sociable numbers was discovered by Henri Cohen, but not until 1969. He found nine sociable chains of just four numbers each, of which the chain with the lowest values is 1,264,460, 1,547,860, 1,727,636 and 1,305,184. Currently, 175 chains of sociable numbers are known, and almost all are chains of four numbers. None are chains of three (particularly poetic, since we all know that three’s a crowd, and a group of four is much more sociable). The longest chain remains Poulet’s 28, which is curious, as 28 is also a perfect number.
It was the Greeks who worked out an unexpected link between perfect numbers and prime numbers, which led to many further numerical adventures. Consider the sequence of doubles starting at 1:
(A79) 1, 2, 4, 8, 16…
In The Elements, Euclid showed that whenever the sum of doubles is a prime number, then you can create a perfect number by multiplying the sum by the highest double that you added. This sounds like a mouthful, so let’s start adding doubles to see what he means:
1 + 2 = 3. 3 is prime, so, we multiply 3 with the highest double, which is 2. 3 × 2 = 6, and 6 is a perfect number.
1 + 2 + 4 = 7. Again, 7 is prime. So we multiply 7 by 4 to get another perfect number: 28.
1 + 2 + 4 + 8 = 15. This is not prime. No perfect numbers here.
1 + 2 + 4 + 8 + 16 = 31. This is prime, and 31×16 = 496, which is perfect.
1 + 2 + 4 + 8 + 16 + 32 = 63. This is not prime.
1 + 2 + 4 + 8 + 16 + 32 + 64 = 127. This is prime and 127×64 = 8, which is perfect.
1 + 2 + 4 + 8 + 16 + 32 + 64 + 128 = 255. This is not prime.
Euclid’s proof was, of course, done through geometry. He did not write it out in terms of numbers, instead using line segments. If he’d had the luxury of modern algebraic notation, he would have noticed that he could express the sum of doubles 1 + 2 + 4 +…as the sum of powers of two, 20 + 21 + 22 +…(Any number to the power 0 is always 1, by convention, and any number to the power 1 is itself.) It then becomes clear that any sum of doubles is equal to the next-largest double minus 1. For example:
1 + 2 = 3 = 4 – 1
or
20 + 21 = 22 – 1
1 + 2 + 4 = 7 = 8 – 1
or
20 + 21 + 22 = 23 – 1
This can be generalized according to the formula: 20 + 21 + 22 +…+ 2n–1 = 2n – 1, in other words that the sum of the first n terms of the doubling sequence starting at 1 is equal to 2n – 1.
So, using Euclid’s original declaration that ‘whenever the sum of doubles is a prime number, the product of the sum multiplied by the highest double is a perfect number’, and adding modern algebraic notation, we can arrive at the much more concise statement:
Whenever 2n – 1 is prime, then (2n – 1)×2n–1is a perfect number.
For civilizations that prized perfect numbers, Euclid’s proof was terrific news. If perfect numbers could be generated whenever 2n – 1 was prime, all that needed to be done in order to find new perfect numbers was to find new primes that were written 2n – 1. The hunt for perfect numbers was reduced to the hunt for a certain type of prime.
Mathematical interest in prime numbers written 2n – 1 might have originated because of their link to perfect numbers, but by the seventeenth century the primes had became objects of fascination in their own right. In the same way that some mathematicians were obsessed with finding pi to more and more decimal places, others were preoccupied with finding higher and higher primes. The activities are similar but opposite: whereas finding digits in pi is about trying to see smaller and smaller objects, pursuing primes is about reaching towards the sky. They are missions that have been undertaken as much for the romance of the journey, as for the possible uses of the numbers discovered along the way.
In the quest for primes, the ‘2n – 1’ generating method took on a life of its own. It wan’t going to produce primes for every value of n, but for the low numbers the success rate was pretty good. As we saw above, when n = 2, 3, 5 and 7 then 2n – 1 is prime.
The mathematician most fixated on using 2n – 1 to generate primes was the French friar Marin Mersenne. In 1644 he made the sweeping claim that he knew all the values of n up to 257 such that 2n – 1 is prime. He claimed they were:
(A109461) 2, 3, 5, 7, 13, 17, 19, 31, 67, 127, 257
Mersenne was an able mathematician, but his list was largely based on guesswork. The number 2257 – 1 is 78 digits long, far too big for the human mind to check whether it is prime or not. Mersenne realized that his numbers were stabs in the dark. He said of the list: ‘all time would not suffice to determine whether they are prime’.
Time did suffice, though, as it often does in the case of maths. In 1876, two and a half centuries after Mersenne wrote his list, the French number theorist Edouard Lucas devised a method that was able to check whether numbers written 2n – 1 are prime, and he found that Mersenne was wrong about 67 and that he had left out 61, 89 and 107.
Amazingly, however, Mersenne had been right about 127. Lucas used his method to prove that 2127 – 1, or 170,141,183,460,469,231, 731,687,303,715,884,105,727, was prime. This was the highest-known prime number until the computer age. Lucas, however, was unable to determine if 2257 – 1 was prime or not; the number was simply too large to work on with pencil and paper.
Despite its patches of error, Mersenne’s list immortalized him; and now a prime that can be written in the form 2n – 1 is known as a Mersenne prime.
The proof of whether 2257 – 1 is prime would take until 1952 to be proven, using the Lucas method, but with a big assist. A team of scientists gathered one day that year at the Institute for Numerical Analysis in Los Angeles to watch a 24ft scroll of tape be inserted into an early digital computer called the SWAC. Simply putting in the tape took several minutes. The operator then input the number to be tested: 257. In a fraction of a second came the result. Computer said no: 2257 – 1 is not prime.
On the same evening in 1952 on which it was discovered that 2257 – 1 is not prime, new potential Mersenne numbers were inserted into the machine. The SWAC rejected the first 42 as not prime. Then, at 10 p.m., came a result. Computer said yes! It announced that 2521 – 1 is prime. The number was the highest Mersenne prime identified in 75 years, making the corresponding perfect number, 2520 (2521 – 1), only the thirteenth discovered in almost twice as many centuries. But the number 2521 – 1 had only two hours to enjoy its status as top of the pile. Shortly before midnight the SWAC confirmed that 2607 – 1 was also prime. Over the next few months, SWAC worked to the limit of its capacities, finding three more primes. Between 1957 and 1996 another 17 Mersenne primes were discovered.
Since 1952, the largest-known prime number has always been a Mersenne prime (apart from a three-year interlude between 1989 and 1992 when the largest prime was (391581×2216193p>) – 1, which is a related type of prime). Among all the primes that exist, and we know there is an infinite number of them, Mersenne primes dominate the table of highest discovered primes because they give prime-hunters a target to aim for. The best technique for finding high primes is to look for Mersenne primes, in other words, to put the number 2n – 1 into a computer for higher and higher values of n and use the Lucas-Lehmer test, an improved version of Edouard Lucas’s method mentioned earlier, to see if it is prime.
Mersenne primes also have an aesthetic loveliness. For example, in binary notation any number 2n is written as 1 followed by n zeros. For example, 22 = 4, which in binary notation is written 100, and 25 = 32, which is written 100000. Since all Mersenne primes are 1 less than 2n, all binary expansions of Mersenne primes are strings of digits that contain only 1s.
The most influential prime-hunter of modern times was inspired in his mission by the markings on an envelope. When George Woltman was a boy, in the 1960s, his father showed him a postmark with the expression 211213 – 1, then the most recently calculated prime number. ‘I was amazed that a number so large could be proven prime,’ he remembered.
Woltman was later responsible for writing some software that has made an enormous contribution to the quest for primes. All projects that involved massive number-crunching used to be carried out on ‘supercomputers’, access to which was limited. Since the 1990s, however, many big tasks have been salami-sliced by dividing up the work among thousands of smaller machines connected to each other by the internet. In 1996 Woltman wrote a piece of software that users can download for free and that, once installed, allocates a small part of the uninvestigated number line where your machine can look for primes. The software uses the processor only when your computer is otherwise idle. While you are fast asleep, your machine is busy churning through numbers on the frontier of science. The Great Internet Mersenne Prime Search, or GIMPS, currently links about 75,000 computers. Some of these are in academic institutions, some are in businesses and some are personal laptops. GIMPS was one of the first ‘distributed computing’ projects and has been one of the most successful. (The largest similar project, Seti@home, is deciphering cosmic noise for signs of extraterrestrial life. It claims three million users but, so far, has discovered nothing.) Only a few months after GIMPS went online a 29-year-old French programmer netted the 35th Mersenne prime: 21398269 – 1. Since then, GIMPS has revealed another 11 Mersenne primes, which is an average of about one a year. We are living in a golden age of high prime numbers.
The current record for largest prime is held by the 45th Mersenne prime: 243112609 – 1, which is a number almost 13 million digits long, found in 2008 by a computer connected to GIMPS at the University of California, Los Angeles. The 46th and 47th Mersennes found were actually smaller than the 45th. This happened because computers are working at different speeds on different sections of the number line at the same time, so it is possible that primes in higher sections will be discovered before primes in lower ones.
GIMPS’s message of mass voluntary cooperation for scientific advancement has made it an icon of the liberal web. Woltman has unintentionally turned the search for primes into a quasi-political pursuit. As a mark of the symbolic importance of the project, the Electronic Frontier Foundation, a digital-rights campaign group, has since 1999 offered money for each prime whose digits reach the next order of magnitude. The 45th Mersenne prime was the first to hit ten million digits and the prize money won was $100,000. The EFF is offering $150,000 for the first prime with 100 million digits, and $250,000 for the first prime with a billion digits. If you plot the largest-known primes discovered since 1952 on a graph with a logarithmic scale against the time of discovery, they fall on what is almost a straight line. As well as showing how the growth of processing power has advanced remarkably consistently over time, the line also allows us to estimate when the first billion-digit prime will be discovered. I’d put money on it being found by 2025. Writing out this number in type where each digit is a millimetre would stretch further than from Paris to Los Angeles.
Digits in highest-known prime by year of discovery.
With an infinite number of primes (whether there is an infinite number of Mersenne primes, however, is not yet known), the search for higher and higher primes is a never-ending task. Whatever prime number we reach, no matter how large, there will always be a prime number even larger taunting us for our lack of ambition.
Endlessness is probably the most profound and challenging idea of basic maths. The mind finds it difficult to cope with the idea of something going on for ever. What, for example, would happen if we start counting 1, 2, 3, 4, 5…and never stop? I remember asking this seemingly simple question as a child, and receiving no straightforward answer. The default response from parents and schoolteachers was that we get to ‘infinity’ but this answer essentially just restates the question. Infinity is simply defined as being the number that we get to when we start counting and never stop.
Nevertheless, we are told from a relatively early age to treat infinity like a number, a weird number, but a number all the same. We are shown the symbol for infinity, the endless loop 8 (called a ‘lemniscate’), and taught its peculiar arithmetic. Add any finite number to infinity and we get infinity. Subtract any finite number from infinity and we get infinity. Multiply or divide infinity by a finite number, as long as it isn’t zero, and the result is also infinity. The ease with which we are told that infinity is a number disguises more than 2000 years of struggling to come to terms with its mysteries.
The first person to showcase the trouble with infinity was the Greek philosopher Zeno of Elea, who lived in the fifth century bc. In one of his famous paradoxes, he described a theoretical race between Achilles and a tortoise. Achilles is faster than the tortoise, so the tortoise is given a head start. The famous warrior starts at a point A and his reptile challenger is ahead of him at a point B. Once the race starts, Achilles zooms forward and soon reaches point B, but by the time he gets there, the tortoise has already advanced to point C. Achilles then ploughs on to point C. But once again, when he reaches this point, the tortoise has shuffled forward to point D. Achilles must reach D, of course, but when he does, the tortoise is already at E. Zeno argued that the game of catch-up must carry on for ever and, therefore, that swift Achilles is never able to overtake his slower four-footed rival. The athlete is much faster than the tortoise, but he cannot beat him in a race.
Like this one, all of Zeno’s paradoxes draw apparently absurd conclusions by dissecting continuous motion into discrete events. Before Achilles can reach the tortoise, he must complete an infinite number of these discrete dashes. The paradox stems from the assumption that it is impossible to complete an infinite number of dashes in a finite amount of time.
The Greeks, though, didn’t have the depth of mathematical understanding of infinity to see that this assumption is a fallacy. It is possible to complete an infinite number of dashes in a finite amount of time. The crucial requirement is that the dashes are getting shorter and taking less time, and that both distance and time are approaching zero. Although this is a necessary condition, it’s not sufficient; the dashes also need to be shrinking at a fast enough rate.
Achilles and the tortoise.
This is what is happening with Achilles and
the tortoise. For example, say that Achilles is running at twice
the speed of the tortoise and that B is 1m ahead of A. When
Achilles reaches B, the turtle has moved m to C. When Achilles reaches
C, the turtle has moved another
m to D. And so on. The total
distance in metres that Achilles is running before he reaches the
tortoise is:
If it takes Achilles one second to complete each of these intervals then it will take him for ever to complete the distance. But this is not the case. Assuming constant speed, it will take him a second to go a metre, it will take half a second to go half a metre, a quarter of a second to go quarter of a metre, and so on. So, the time in seconds it takes him to reach the tortoise is described by the same addition:
When both time and distance are described by the halving sequence they simultaneously converge at a fixed, finite value. In the above case, at 2 seconds and 2 metres. So, it turns out that Achilles can overtake the tortoise after all.
Not all of Zeno’s paradoxes, however, are solved by the maths of infinite series. In the ‘dichotomy paradox’ a runner is going from A to B. In this case, we’ll call the first point that the runner passes after leaving A point C. For the runner to get to C, however, he must have passed the point that is halfway to C. So C cannot be the first point he passes. It follows that there can be no ‘first point’ that the runner passes, since there will always be a point that he must pass before it. If there is no first point that the runner passes, Zeno argued, the runner cannot ever leave A.
According to lore, to refute this paradox Diogenes the Cynic silently stood up and walked from A to B, thereby demonstrating that such motion was possible. But Zeno’s dichotomy paradox cannot be dismissed so easily. In two and a half thousand years of scholarly head-scratching, no one has been able to solve the riddle totally. Part of the confusion is that a continuous line is not perfectly represented by a sequence of an infinite number of points, or an infinite number of smll intervals. Likewise, the unbroken passage of time is not perfectly represented by an infinite number of discrete moments. The concepts of continuity and discreteness are not entirely reconcilable.
The decimal system throws up an excellent example of a Zeno-inspired paradox. What is the largest number less than 1? It is not 0.9, since 0.99 is larger and still less than 1. It is not 0.99 since 0.999 is larger still and also less than 1. The only possible candidate is the recurring decimal 0.9999…where the ‘…’ means that the nines go on for ever. Yet this is where we come to the paradox. It cannot be 0.9999…since the number 0.9999…is identical to 1!
Think of it this way. If 0.9999…is a different number from 1, then there must be space between them on the number line. So it must be possible to squeeze a number in the gap that is larger than 0.9999…and smaller than 1. Yet what number could this be? You cannot get closer to 1 than 0.9999…. So, if 0.9999…and 1 cannot be different, they must be the same. Counter-intuitive though it is, 0.9999…= 1.
So what is the largest number less than one? The only satisfactory conclusion to the paradox is that the largest number less than 1 doesn’t exist. (Likewise, there is no largest number less than 2, or less than 3, or indeed less than any number at all.)
The paradox of Achilles’ race against the tortoise was resolved by writing the durations of his dashes as a sum with an infinite amount of terms, which is also known as an infinite series. Whenever the terms of a sequence are added together it is called a series. There are both finite and infinite series. For example, if you add up the sequence of the first five natural numbers, you get the finite series:
1 + 2 + 3 + 4 + 5 = 15
Obviously we can work out this sum in our heads, but when a series has many more terms, the challenge is to find a shortcut. One famous example was worked out by the German mathematician Carl Friedrich Gauss when he was a young boy. As the story goes, a schoolteacher is said to have asked him to calculate the sum of the series of the first hundred natural numbers:
1 + 2 + 3 +…+ 98 + 99 + 100
To the teacher’s disbelief, Gauss replied almost instantly: ‘5050.’ The prodigy had worked out the following formula. If you pair off numbers judiciously, by taking the first with the last, the second with the second-last, and so on, then the series can be rewritten as:
(1 + 100) + (2 + 99) + (3 + 98) +…+ (50 + 51)
which is:
101 + 101 + 101 + 101 +…+ 101
There are fifty terms, each with a value 101,
so the sum is 50×101 = 5050. We can generalize this to get the
result that for any number n, the sum of the first n numbers is n + 1 added times in a row, which is
. In the
above case n is 100, so
the sum s
= 5050.
When you add up the terms in a finite series you always get a finite number, that’s obvious. However, when you add up the terms of an infinite series there are two possible scenarios. The limit, which is the number that the sum approaches as more and more terms are added, is either a finite number or it is infinite. If the limit is finite, the series is called convergent. If not, the series is called divergent.
For example, we have already seen that the series
is convergent, and converges on 2. We have also seen that there are many infinite series that converge on pi.
On the other hand, the series
1 + 2 + 3 + 4 + 5 +…
is divergent, heading off towards infinity.
The Greeks may have been wary of infinity, but by the seventeenth century mathematicians were happy to take it on. An understanding of infinite series was required for Isaac Newton to invent calculus, which was one of the most significant developments in mathematics.
When I studied maths one of my favourite exercises was being presented with an infinite series and being asked to work out whether it converged or diverged. I always found it incredible that the difference between convergence and divergence was so brutal – the difference between a finite number and infinity is infinity – and yet the elements that decided which path the series took often seemed so insignificant.
Take a look at the harmonic series:
The nominator of every term is one, and the denominators are the natural numbers. The harmonic series looks like it should converge. Each term in the series gets smaller and smaller, so you would think that the sum of all the terms would be bounded by a fixed amount. But, bizarrely, the harmonic series is divergent, a decelerating but unstoppable snail. After 100 terms of the series, the total has only just passed 5. After 15,092,688,622,113,788,323,693,563,264,538, 101,449,859,497 terms, the total exceeds 100 for the first time. Yet this stubborn snail will continue its bid for freedom, past any distance you care to mark out. The series will eventually reach a million, then a billion, going further and further towards infinity. (The proof is included as an appendix.)
The harmonic series appears when we consider the maths of stacking Jenga blocks. Say you have two blocks and want to position them one on top of the other so that the top one has the largest possible overhang, but doesn’t topple over. The way to do this is to place the top block exactly halfway across the one underneath, as demonstrated opposite (A). In this way, the centre of gravity of the top block falls on the edge of the bottom brick.
If we had three blocks, what would be their positions so the combined overhang was as large as possible without toppling? The solution is for the top one to be placed halfway along the middle one, and for the middle one to be a quarter of the way along the bottom one, as in the diagram opposite (B).
Continuing for more and more blocks, the general pattern is that, in order to guarantee the maximum combined overhang, the top one must be halfway along the second one, which must be a quarter along the third one, which must be a sixth along the fourth one, which must be an eighth along the fifth one, and so on. This gives us a leaning tower of bricks that looks like C on the page opposite.
How to stack Jenga blocks with maximum overhang so that they don’t topple.
The total overhang of this tower, which is the sum of all the individual overhangs, is the following series:
Which can be rewritten as:
Which is half of the harmonic series, if we carry on for an infinite number of terms.
Now, since we know that the harmonic series increases to infinity, we also know that the harmonic series divided by two increases to infinity, because infinity divided by two is infinity. Rephrased in the context of stacking Jenga blocks, this means that it is theoretically possible to create a freestanding overhang of any length we want. If the harmonic series divided by two will eventually exceed any number we want, provided we include enough terms, then the overhang of the leaning tower of blocks will eventually exceed any length we want, provided we stack enough blocks. Although theoretically possible, however, the practicalities of constructing a tower with a large overhang are daunting. In order to achieve an overhang of 50 blocks, we would need a tower of 15×1042 blocks – which would be much higher than the distance from here to the edge of the observable universe.
The delights of the harmonic series are profuse, so let’s have some more fun with it. Consider the harmonic series excluding every term that has a 9 in it, which is also an infinite series. In other words, we are extracting the following terms:
So, the depleted series looks like:
Recall that the harmonic series adds up to infinity, so one might think that the harmonic series with no 9s also adds up to a pretty high number. Wrong. It adds up to just under 23.
By filtering out 9 we have tamed infinity: we have slaughtered the beast of eternity and all that is left is a shrivelled carcass of about 23.
This result appears remarkable, but by looking a little closer we can understand it completely. Eliminating a 9 gets rid of only one of the first 10 terms of the harmonic series. But it gets rid of 19 of the first 100 terms, and 271 of the first thousand. By the time the numbers are very large, sayrhang are100 digits, the vast majority of numbers contain a 9. As it turns out, thinning the harmonic series by taking out the terms with a 9 removes almost all of it.
Customizing the harmonic series gets more intriguing than this, though. The decision to extract 9s was arbitrary. If I had extracted all the terms containing 8 from the harmonic series, the remaining terms would also converge to a finite number. As it would if I extracted only the terms with a 7, or indeed with any single digit. In fact, we do not even need to limit ourselves to single digits. Remove all terms including any number, and the thinned-out harmonic series is convergent. This works with, say, 9 or 42 or 666 or 314159, and the same reasoning applies.
I’ll use the example of 666. Between 1 and 1000 the number 666 occurs once. Between 1 and 10,000 it occurs 20 times, and between 1 and 100,000 it occurs 300 times. In other words, the percentage occurrence of 666 is 0.1 percent in the first 1000 numbers, 0.2 percent in the first 10,000 and 0.3 percent in the first 100,000. As you consider larger and larger numbers, the string of digits 666 is proportionately more and more common. It will eventually be the case that almost all numbers have a 666 in them. So, almost all terms in the harmonic series will eventually have a 666 in them. Exclude them from the harmonic series and the depleted series converges.
In 2008 Thomas Schmelzer and Robert Baillie calculated that the harmonic series without any term containing the number 314159 adds up to a little over 2.3 million. It is a large number, but a long, long way from infinity.
A corollary of this result is that the harmonic series with only the terms including 314159 must add up to infinity. In other words, the series:
adds up to infinity. Even though it starts with a tiny number and the terms get only tinier, the sum of the terms will eventually surpass any number you want. The reason, again, is because once numbers get very large, almost every number has a 314159 in it. Almost all unit fractions contain a 314159.
Let’s take a look at one last infinite series, one that brings us back to the mysteries of the primes. The prime harmonic series is the series of unit fractions where the denominators are the prime numbers:
The primes get scarcer as numbers get higher, so one might expect that this series doesn’t have the momentum to add up to infinity. Yet, unbelievably, it does. Counter-intuitive and spectacular, the result makes us realize the power and importance of the primes. They can be seen not only as the building blocks of natural numbers, but also as the building blocks of infinity.