A Perfect (Math) Mystery

Camila Machado
11 min readFeb 5, 2024

The mystery behind odd perfect numbers is one of the oldest unsolved problems in math. New insights can come from taking Descartes's steps and studying the perfect number’s cousin: spoof numbers.

Illustration: Camila Machado

You would imagine that if the mathematicians called something perfect it would mean that there is no problem with it. But actually, perfect numbers have perplexed and tormented the best mathematicians in history for thousands of years. The science writer Martin Gardner once said “One would be hard put to find a set of whole numbers with a more fascinating history and more elegant properties surrounded by greater depths of mystery — and more totally useless — than the perfect numbers.” So, what's the deal with these seemingly "useless" numbers that have held the attention of mathematicians since Ancient Greece?

Back in 500 BC, Pythagoras and his followers noticed that the number 6 had a special property. The divisors of 6 are 1, 2, 3, and 6. If we sum these divisors we get 1+2+3+6 = 12, which is twice the number 6. Ok…but, is this really special? Let’s check a few others: 7 is prime, which means its divisors are only 1 and 7, so 1+7 = 8 < 2*7. What about 8? Here we have 1+2+4+8 = 15 < 2*8. And 12? 1+2+3+4+6+12 = 28 > 2*12. So, some give too little, others too much…Mathematicians came up with a classification: if the sum of the divisors of a number is 2*N we call it a perfect number (or p.n.), if it is less than 2*N, a deficient number, and if it is more than 2*N, an abundant number.

Early Conjectures and Mystical Numbers

The thing is that perfect numbers are quite rare and hard to find. The ancient Greeks knew just the first four: 6, 28, 496, and 8128. It’s a small list, but to learn more we can ask: what do they have in common? We can see that they end with 6, 8, 6, 8, maybe this pattern will follow for the next ones. Also, they are all even. Does it mean odd perfect numbers don’t exist? These observations (among others) were actually made by Nicomachus of Gerasa, an ancient Greek philosopher, around 100 AD in his book “Introduction to Arithmetic”. But he didn’t provide any proof for them. Turns out that one is false. The other kept Descartes, Euler, and many other mathematicians busy, but until today we still have no answer.

In the course of history, these numbers also got a mystical status. Ancient Greeks equated the perfect number 6 with marriage, health, and beauty. In the first century, Philo of Alexandria wrote in the book “On the Creation” that the world was created in 6 days and the moon orbits in 28 days because 6 and 28 are perfect numbers. Centuries later, this idea appeared again in the book “City of God” by Saint Augustine. Hrotsvit von Gandersheim considered the first German female poet, born in the 10th century, also talked about perfect numbers in her play “Sapientia”. In the 12th century Rabbi Josef b. Jehuda Ankin suggested that it was essential to study the perfect numbers to heal the human soul.

Perfect and Primes

The first recorded result about perfect numbers appeared in Euclid’s Elements. To talk about it, we first need to see what’s the link between perfect numbers and primes. Remember we tested 7? 1+7=8, which means 7 is not perfect. But what about other prime numbers? The only divisors of any prime are 1 and the number itself. So, if a prime number p is perfect then 1+p=2p. This is true only for p=1, but by definition, prime numbers are bigger than 1. The conclusion: prime numbers can’t be perfect.

Turns out there is a relation between primes and perfect numbers, it is just not that simple… Euclids wrote: “If as many numbers as we please beginning from a unit be set out continuously in double proportion until the sum of all becomes a prime, and if the sum multiplied into the last make some number, the product will be perfect.”

Ok…but, what does it mean? Let’s start with “beginning from a unit be set out continuously in double proportion”: 1+2. This sum gives 3, which is prime, so we stop there (“until the sum of all becomes a prime”). Now, the last number of the sequence is 2. Using Euclids’s rule we multiply: (1+2)*2=3*2=6. What a surprise, 6 is perfect! The next would be (1+2+4)*4=7*4=28 , (1+2+4+8+16)*16=31*16=496, (1+2+4+8+16+32+64)*64=127*64=8128…

There is a more modern way to state Euclids’ findings. For example, take the sum until 16=2⁴. We can write it as (1+2¹+2²+2³+2⁴). It sounds weird but bear with me: let’s multiply it by 1 but write 1 as (2–1): (2–1)*(1+2¹+2²+2³+2⁴) = 2+2²+2³+2⁴+2⁵-1–2–2²-2²-2⁴ = 2⁵ -1. This is an example of a (finite) geometric series. They have this property that we can re-sum and write it more simply. Now Euclids’ rule is just: (1+2+4+8+16)*16=(2⁵-1)*2⁴=496. Or, in general: if (2^k-1) is prime then (2^k -1)2^(k-1) is a perfect number.

A few important things here: this formula will give only even numbers and it doesn’t say if we can get all even perfect numbers in this way. Also, for large k, checking if (2^k -1) is a hard task: the history is full of trials and errors.

Between the 11th and 12th centuries, the Arab mathematicians followed the ancient Greek steps. Ibn al-Haytham, considered a pioneer in the scientific method, after more than a thousand years, partially proved that Euclid’s formula gives all even perfect numbers. Ismail ibn Ibrahim ibn Fallus wrote a list with 10 perfect numbers, although only the first seven were correct. Around 1500, at the beginning of the Renaissance, mathematicians in Europe started to also work on the topic. Since the results of the Arab mathematicians were unknown to them, they rediscovered the 5,6 and 7th p.n. The 7th p.n. was pointed out by Cataldi in 1603: (2¹⁹-1)2¹⁸=137438691328. At this point, it was clear that Nicomachus conjecture about the alternating 6,8 was false.

Descartes tried, without success, to prove that Euclids’ rules give all even p.n.’s. He also said “As for me, I judge that one can find real odd perfect numbers”, but failed to find any. Around 1630, Fermat also started working on the topic. He discussed the work in letters to Mersenne and Frenicle de Bessy. In one of those letters, he stated what is today known as “Fermat’s Little Theorem”. It provides an effective way to find prime numbers and till today, is one of the most important theorems in number theory. Mersenne was also interested in the p.n.’s. In 1644, he published a book in which he claimed that for some primes p, the number (2^p-1) would also be prime, and consequently, by Euclids’ rule, (2^p-1)2^(p-1) is perfect. Primes of the form Mp=(2^p-1) became known as Mersenne primes.

Then Euler came to the picture. He proved what Descartes and other mathematicians failed to: that indeed, Euclids’ rules give all even p.n. So, Euclid’s rule was upgraded to the Euler-Euclid Theorem. Now, with the definition of Mersenne prime Mp=(2^p-1), this means that we can write all even p.n. as Mp*2^(p-1). So, the task of finding p.n. turn out to be a search for Mersenne primes. Euler also found the first new even p.n. in 125 years. He also tried to look at the odd p.n problem, but he couldn’t prove or disprove that they exist. Instead, he proved an assertion made by Descartes. If an odd perfect number exists it must have a very specific form: N = product of distinct odd primes to some even power, except by one “special prime”. But the Nicomachus conjecture was still unsolved…Euler said, “Whether…there are any odd perfect numbers is a most difficult question.”

Now, Mersenne primes are as rare as the perfect numbers. They soon became huge numbers, and at this time there was no computer to help. Mersenne tried to guess but got a few wrong. He even admitted to not checking it: “..to tell if a given number of 15 to 20 digits is prime, or not, all time would not suffice for the test.” One of these was M_67 = 2⁶⁷-1. More than 200 years later, Edouard Lucas showed that this number is not prime, but he could not find its factorization, or in other words, which are the divisors of M_67.

Other 27 years passed and in a memorable talk, Frank Nelson Cole presented that 2⁶⁷-1 was a product of two specific numbers. Without speaking anything, he entered the room and wrote on the blackboard: 2⁶⁷-1 = 147,573,952,589,676,412,927. He walked to the other side of the blackboard and multiplied 193,707,721 × 761,838,257,287, getting the same number. He came back to his seat, and the audience applauded. Later on, he said that he spent 3 years of Sundays working on this.

Computers take over

In the 50’s, mathematicians started using computers to take over this task. Alan Turing searched for primes with the Manchester Mark 1 without success. But in 52, the SWAC (Standard Western Automatic Computer) was the world’s fastest computer when started operating and found the 13th to the 17th Mersenne primes (and consequently the corresponding perfect numbers) with a program written by Raphael M. Robinson. Today 51 Mersenne numbers were found (although the last 3 still need further confirmation). The thing is that even with the super-computers today, finding the next one is getting harder and harder.

We are dealing with unimaginable orders of magnitude for those numbers. The exponent of the 51st is 82,589,933. So we are talking about a perfect number of the size (2⁸²⁵⁸⁹⁹³³¹-1)*2⁸²⁵⁸⁹⁹³². This number has 23 million digits. An A4 page fits around 1800 characters. So we would need to print more than 12 thousand pages to write this single number!

This is a hard task for a single computer or a single person….
In 1996, George Woltman founded the GIMPS or the Great Internet Mersenne Prime Search, one of the first large-scale volunteer computing projects. This means that anyone with a computer and internet connection can volunteer their computer power to help in the search for Mersenne primes. The project was so successful that already found 17 of those numbers. Actually, you can sign up right now and also help with the search. Their page lists many good reasons to do it such as your name will be in history together with the greatest mathematicians’ minds and well…you can also get $150000 for finding the first hundred- million-digit prime and even $250000 for the first billion-digit prime. But be aware: it is still not proven if infinite even perfect numbers exist. Another perfect mystery…

This is…odd?

Talking about mysteries, so far, we have seen just even perfect numbers. Where are the odds? In 1888, James Joseph Sylvester came back to this question, which had been not much explored since Euler. Sylvester worked on a “web of conditions” for the existence of o.p.n.’s. To give some examples, he proved that no odd perfect number is divisible by 105, that if it exists it must have at least six distinct primes, and if it is not divisible by 3 then it must have eight distinct primes. But how does this help?

Proving that something doesn’t exist is often harder than proving that it exists. These conditions are squeezing the “space” where the o.p.n.’s are allowed to exist. There is also the hope that if two conditions are incompatible with each other, this would mean that no number can satisfy both at the same time and the conclusion would be that this number doesn’t exist.

Sylvester once said: “..the existence of any one such [odd perfect number] — its escape, so to say, from the complex web of conditions which hem it in on all sides — would be little short of a miracle.” And inspired by his work, since then mathematicians have been extending this web. Mathematicians found ingenious ways of getting information about these odd numbers, without even knowing if they exist. For example, since the 70’s they have been putting lower bounds for the odd perfect numbers. The latest result, by Pascal Ochem and Michael Rao, published in 2012, showed that if the odd perfect number exists it must be greater than 10¹⁵⁰⁰.

This is quite a big number…And with the number of conditions growing, it feels unlikely that odd perfect numbers exist. Carl Promerance, a mathematician at Dartmouth College, tried to make the “feels unlikely” a bit more mathematical. He gave an argument that, based on the probability that certain conditions are satisfied, the chance of o.p.n’s existence is really small. Now, this is not a proof. This is what it is called a heuristic argument, meaning it is still speculative and non-rigorous. At the end of the day, 10¹⁵⁰⁰ is nothing compared to infinite numbers and after thousands of years, we still don’t have a clear answer.

Even after all of this, perfect numbers keep inspiring and intriguing mathematicians in our generation. Pace Nielsen, from BYU University, found out about perfect numbers during a high school math competition and got inspired to study number theory. Nielsen expanded the web of conditions started by Sylvester and now come up with a different approach to attack this problem.

Spoof!

To understand Nielsen’s approach we need to look back to Descartes. Let’s define the function sigma(N) which is simply the sum of N divisors.
So, sigma(N)=2N means that N is perfect. Euler proved that sigma(N1 x N2) = sigma(N1)*sigma(N2) if N1 and N2 don’t have the same prime in their decomposition. This property makes things easier when dealing with large numbers. Instead of finding the divisors one by one and writing sigma(21)=1+3+7+21=32, we can write sigma(21)=sigma(3*7)=sigma(3)*sigma(7) =(1+3)(1+7)=4*8=32. When trying to find an odd p.n, Descartes ended up looking at 198585576189: sigma(198585576189) = sigma(32*72*112*132*220211)=….*(1+220211)=2*(198585576189). Wow, it looks perfect… But there is a catch: we wrote 1+220211 but 220211 is not prime.

This is called a Descartes number (or a spoof number), which means it is an odd number that would be perfect if one of the composite factors were prime. After Descartes found the first spoof, it took 361 years for the second spoof to appear. It was a result of Voight, a mathematician from Dartmouth College. His trick was to allow negative numbers: -22.017.975.903 =(34*72*112*192*(-127)). The minus sign is really crucial. Using the Euler multiplication rule appears a factor (1-127) instead of the usual (1+127) and we get that the negative spoof is perfect. But by definition, an odd perfect number would have just positive numbers. This is a generalization of Descartes’s original spoof.

After Voight, Nielsen and a BYU team started to search for more spoofs. 3 years of computational searches led the team to find 21 new spoofs, published in May of 2022. Spoofs are a bigger group, a generalization of odd perfect numbers. So any property that they have, odd perfect numbers also share. The hope is also to find properties that would contradict conditions already established for o.p.n. For example, Sylvester proved that any o.p.n. is not divisible by 105. If spoofs must be divisible by 105, this would mean that the only way these facts coexist is if odd perfect numbers don’t exist. Some mathematicians are skeptical about this road, but the truth is that solving one of the oldest mysteries of mathematics will probably require some creativity.

Place your Bet…

The beauty of the perfect numbers is that they allowed an ongoing conversation between the greatest minds for thousands of years. Sometimes only things with a direct application are seen as useful. But this is a history about human curiosity and all that we learned along the way staring at this apparently silly problem. How many mathematicians were inspired by it? How many results in other areas were born from the attempt to solve it? Maybe we need to wait a few more thousands of years to know if the odd perfect numbers exist. But maybe not.

--

--

Camila Machado

Physicist and Illustrator with far too many interests. She/They