Numbers that never make a prime
Worth reading first: Which infinitudes are proved · The sieve that cannot finish.
Many sequences of whole numbers look as if they should contain infinitely many primes, and almost nothing can be proved about any of them. Which infinitudes are proved is a short list. Nobody knows that is prime infinitely often, or that there are infinitely many primes of the form , and for that one the evidence points the other way. Take the form with odd. For a fixed , as runs through 1, 2, 3, …, the numbers grow quickly, and a number near has about one chance in of being prime. Since diverges, a fixed might be expected to produce infinitely many primes. For nearly every that is what seems to happen.
So it is a real surprise that Wacław Sierpiński proved in 1960 that there are infinitely many odd for which is never prime, not for any . Such a is called a Sierpiński number. The smallest known is 78,557, found by John Selfridge in 1962. Its proof of compositeness has nothing to do with the size of the numbers and it is short enough to draw.
Seven primes on a schedule
Choose a prime , and look at modulo as grows. Since the powers of two go round a cycle modulo , of length equal to the order of 2 modulo , the values repeat. For and , the order is 2, and 3 divides the number when is even. That takes care of half the exponents. For , the order is 4, and 5 divides it when . For , the order is 3, and 7 divides it when . Then 13 when , 19 when , 37 when and 73 when .
Those seven conditions, in the seven rows of the figure, cover every whole number , as the bottom row shows. Every falls in at least one, and the pattern repeats every 36 steps, since 36 is the least common multiple of the orders. So for every , the number has one of those seven primes as a factor, and since the number is larger than 73, it is composite. Every one of infinitely many numbers has a small known factor, identified by nothing more than its exponent modulo 36.
The largest of those seven primes is 73 and the schedule has period 36, so the whole proof is a finite check. There is a second kind of Sierpiński number too, such as , with a different covering.
Six primes are enough here: 3, 5, 7, 13, 17 and 241, with period 24. Given one covering, infinitely many Sierpiński numbers follow at once. If a has a covering with primes , then any that is congruent to modulo all those primes and modulo 2 has the same covering, and an arithmetic progression of such numbers exists by the Chinese remainder theorem. That is exactly Sierpiński’s proof: choose primes dividing for a set of small , and build a covering from their orders. It uses the seven factors of the first few Fermat numbers, and it leads directly to a large explicit example.
Sierpiński’s own example
The original construction shows where such coverings come from, and it uses numbers already familiar for another reason. The Fermat numbers are 3, 5, 17, 257, 65,537, and then . Every whole number has a highest power of two dividing it, . If , then modulo . If then modulo 641 as well. If , then modulo 6,700,417. So the classes by highest power of two make a covering, and every belongs to exactly one of them.
So choose by the method of several dials: modulo each of 3, 5, 17, 257, 65,537 and 641, and modulo 6,700,417. Then for each , the number is modulo one of the seven primes. The smallest such odd is a number of 20 digits, about , and a direct test of the seven congruences at every to 4,096 confirms the covering. Compared with 78,557 it is enormous. Selfridge’s example shows how much smaller a covering can be when the primes are chosen with care: he uses periods that divide 36 and that overlap efficiently, and not the rigid scheme of powers of two.
It is a pretty coincidence that the failure of the Fermat numbers to stay prime is what makes this construction possible. Euler’s discovery that 641 divides , which ended a famous conjecture about those numbers, gives the last two primes that the argument needs. If had been prime the covering would have needed more care: its single large prime would have had to handle the class , and with no other prime available the class would have had nothing left to cover it. It would then have been necessary to continue through the Fermat numbers for ever.
Why most are not like this
For almost all , nothing resists. The search here tests every odd below 2,000 up to , using strong probable-prime tests, and most values of produce a prime immediately. Only 8 of the 1,000 values of go past : 47, 383, 881, 1,201, 1,643, 1,699, 1,727 and 1,741. They are not special. In the published tables, 47 gives a prime at , and 383 at , the slowest of all small cases. Among the ones that succeed within the tested range, 257 takes the longest here, at .
So the distribution of the first prime is very wide, and that is just what a chance model predicts. For a given the primes are thinly spread, as the next figure shows, and there are always some whose first success comes unusually late. Telling apart a that is merely late from one with a hidden obstruction is the whole difficulty.
The single sequence with gives primes at the exponents 1, 2, 5, 6, 8, 12, 18, 30, 36, 41, 66, 189, 201, 209, 276, 353, 408 and 438. On a logarithmic scale in , the staircase has a steady slope with long gaps, such as the jump from 66 to 189. That is the signature of a heuristic count , which grows like : a Poisson process in the variable . Each of the classical questions about such forms is similar in that nothing here has been proved. No specific is known to give infinitely many primes. The infinitude is in this sense a statistical prediction, of a kind that the patterns primes are allowed to make discusses for other families, where only local obstructions are allowed to stop primes appearing. Hardy and Littlewood’s conjectures and the Bateman–Horn formula have that form, and a covering is a local obstruction spread out over many primes.
Covering systems
The mechanism is more general than this application, and Paul Erdős deserves the credit for it. A covering system is a finite list of arithmetic progressions that together contain every integer. The simplest one with distinct moduli has five members.
The classes 0 mod 2, 0 mod 3, 1 mod 4, 5 mod 6 and 7 mod 12 cover the integers. Their densities add up to , so there is some overlap, which is unavoidable. It is impossible for a covering with distinct moduli to have density exactly 1, in a short proof with roots of unity that goes back to Mirsky, Newman and others. Erdős invented the idea in 1950 to settle a question of Alphonse de Polignac.
Polignac had guessed in 1849 that every odd number is the sum of a prime and a power of two. He claimed to have checked this up to three million, but 127 is already a counterexample, as subtracting 1, 2, 4, 8, 16, 32 or 64 from it leaves a composite number.
Nikolai Romanoff proved in 1934 that a positive proportion of odd numbers do have the form. The computation here gives a share of 0.929 at 200,000. The list of those that do not begins 127, 149, 251, 331, 337, 373, 509, 599, 701, 757, 809. What Erdős proved is that infinitely many do not, and in fact a whole arithmetic progression does not. Build a covering with moduli equal to orders of 2 modulo various primes. Then choose an so that, for each power , is divisible by the prime assigned to ’s class. So is composite for every , and is not a prime plus a power of two. It is the same trick as Sierpiński’s a decade before him, with subtraction in place of multiplication. Ronald Graham used it in 1964 for a third purpose, to find a Fibonacci-like sequence, with coprime starting values, that contains no primes at all. Its starting values have 34 digits each, and they come from a covering by the periods of the Fibonacci numbers modulo primes.
There is also the mirror image of the Sierpiński problem, the Riesel numbers with always composite, for which the smallest known is 509,203, and there are numbers called Brier numbers that are both. All of them work through coverings.
Sixty years of search
If a covering is the only known obstruction, is it possible that no below 78,557 has one? That is Selfridge’s conjecture: 78,557 is the smallest Sierpiński number. To prove it, one must show that each smaller odd gives at least one prime. For most of them, that was easy. By the 1990s the list of those without a known prime had come down to 17.
So began a distributed project, called Seventeen or Bust, in 2002. It eliminated eleven of them in five years. The primes it found are among the largest ever known, of the special form a Proth test can decide. Then PrimeGrid continued the search, and in 2016 it found , a number with about 9.4 million digits, the record for a non-Mersenne prime at the time. Five candidates remain: 21,181, 22,699, 24,737, 55,459 and 67,607. Each has been tested past million or so, without success, and chance alone predicts that each will eventually succeed. But the chance model also predicts that it could take many times longer than all the work done so far.
The Proth test used in this search is a good example of how far a special form helps. To prove a number of this size is prime, it is enough to check a single power: . That is the order argument in the Lucas test specialised to numbers where is almost entirely a power of two, so nothing has to be factored. That is also why the primes of this form are almost the only numbers of this size for which primality can be proved at all.
What would count as a surprise
Sequences that do have an obstruction are not always covered in this simple way. The statement that every Sierpiński number has a covering has not been proved, and it might not be true. Michael Filaseta and collaborators have studied the possibility of for which every term is composite without any covering at all. There is a strange and specific candidate: for a perfect fourth power and , the term is with , and this has an algebraic factorisation . So a partial covering by small primes on most residues, together with an algebraic factorisation on the rest, can also yield a sequence of only composites, and it would not be a covering in the strict sense. Izotov and others have given specific examples of this kind. Whether anything still stranger can happen is not known.
And nothing has been proved about any of the numbers that do not have a covering. For a given such as 3, the theorem that there are infinitely many primes of the form is beyond any current method. So here is a rather odd situation: the “negative” results are simple and exact, and the “positive” ones are heuristic. The sieve methods discussed in the sieve that cannot finish cannot help, because they work for sequences of positive density, and this sequence is exponentially thin. It is similar to the question in when Euclid’s number is itself prime, where the numbers also grow far too quickly for any method except looking.
What is proved, tested and quoted
The coverings of 78,557 and 271,129 were verified exactly. Both can be checked by hand from the seven or six congruences, and they are complete proofs. The primality tests in the first-prime search are strong probable-prime tests to five bases, so strictly these are probable primes. For these sizes a false positive is extremely unlikely. The first-prime table shows only what happens up to , and the eight unresolved values were left unresolved here, though published results have settled them. The count for agrees with the published list up to the range shown.
The statements about the resolved cases and the remaining five are quoted from the Seventeen or Bust and PrimeGrid projects. Those computations took many years of many computers, and they were not recomputed. The density heuristic is not a theorem. The share of odd numbers of the form is an exact count, up to 200,000. Romanoff’s theorem says only that it stays above a positive constant, and the value of the limit, which has been estimated at about 0.43 or so of all integers, is not settled.
Still open: five numbers, and the covering problem
Is 78,557 the smallest Sierpiński number? Five primes would settle it, and they could be found tomorrow or not in this century. Finding one is purely a matter of machine time, with no room left for clever mathematics, but the time needed grows much faster than any search can keep up with, since each test of a number with near 50 million takes days.
The covering systems themselves have provided the more interesting open mathematics recently. Erdős asked in 1950 whether the smallest modulus in a distinct covering can be made as large as desired. For decades constructions pushed it up, reaching 42 by 2014. In 2015 Bob Hough proved that the answer is no: every distinct covering has a least modulus below . Paul Balister, Béla Bollobás, Robert Morris, Julian Sahasrabudhe and Marius Tiba brought this down to 616,000 in 2018, with a new method. The companion question, whether all the moduli can be odd, posed by Erdős and Selfridge, is still open. Hough and Pace Nielsen showed that a distinct covering must use a modulus divisible by 2 or by 3, but not that it must use an even one. The schedule of the opening figure has both factors in its period, and a negative answer would say that this is no accident.
An obstruction that is a timetable
is composite for every because seven primes divide it on a timetable of period 36 that covers every step. That is a finite proof about infinitely many numbers, and it is much the strongest statement known about any such sequence. For a typical , all the evidence, from the first few hundred steps to the largest primes yet found, says primes keep appearing, and nothing has ever been proved about that. Five smaller values of remain to be resolved.
It is striking how easily a sequence can be proved to contain no primes, and how impossible it has been to show that any sequence of this kind contains infinitely many. The proof of the negative is a table that could be written on a card, and the positive statement is still out of reach of all known methods.
Shares its objects with
Essays that name at least two of the same things, and that neither author linked.
- A walk on Gaussian primes stopped by a moat — both name conjecture, exhaustive search, primes
- Euclid's proof run as a machine — both name exhaustive search, primality test, primes
- How often two generates every remainder — both name conjecture, order of an element, primes
- A box with every face diagonal whole — both name conjecture, exhaustive search
- A chain of tetrahedra saves more — both name conjecture, exhaustive search
- A constant that holds the primes — both name exhaustive search, primes
Named objects
A dashed tag is an object no other essay names yet.
CongruenceConjectureCoveringExhaustive searchOrder of an elementPrimality testPrimes