Prime gap

Difference between two successive prime numbers From Wikipedia, the free encyclopedia

A prime gap is the difference between two successive prime numbers. The -th prime gap, denoted or is the difference between the th and the -th prime numbers, i.e.,

For example, since the first few primes are 2, 3, 5, 7, 11..., we have , , . The sequence of prime gaps has been extensively studied; however, many questions and conjectures remain unanswered.

The first 60 prime gaps are:

1, 2, 2, 4, 2, 4, 2, 4, 6, 2, 6, 4, 2, 4, 6, 6, 2, 6, 4, 2, 6, 4, 6, 8, 4, 2, 4, 2, 4, 14, 4, 6, 2, 10, 2, 6, 6, 4, 6, 6, 2, 10, 2, 4, 2, 12, 12, 4, 2, 4, 6, 2, 10, 6, 6, 6, 2, 6, 4, 2, ... (sequence A001223 in the OEIS).

By the definition of every prime can be written as

Simple observations

The first, smallest, and only odd prime gap is the gap of size 1 between 2, the only even prime number, and 3, the first odd prime. All other prime gaps are even. There is only one pair of consecutive gaps having length 2: the gaps and between the primes 3, 5, and 7.

For any integer , the factorial is the product of all positive integers up to and including . Then in the sequence

the first term is divisible by 2, the second term is divisible by 3, and so on. Thus, this is a sequence of n − 1 consecutive composite integers, and it must belong to a gap between primes having length at least . It follows that there are gaps between primes that are arbitrarily large, that is, for any integer , there is an integer with .

However, prime gaps of numbers can occur at numbers much smaller than . For instance, the first prime gap of size larger than 14 occurs between the primes 523 and 541, while 15! is the vastly larger number 1307674368000.

The average gap between primes increases as the natural logarithm of these primes, and therefore the ratio of the prime gap to the primes involved decreases (and is asymptotically zero). This is a consequence of the prime number theorem. From a heuristic view, we expect the probability that the ratio of the length of the gap to the natural logarithm is greater than or equal to a fixed positive number to be ; consequently the ratio can be arbitrarily large. Indeed, the ratio of the gap to the number of digits of the integers involved does increase without bound. This is a consequence of a result by Westzynthius.[1]

In the opposite direction, the twin prime conjecture posits that for infinitely many integers .

Numerical results

Usually the ratio is called the merit of the gap . Informally, the merit of a gap can be thought of as the ratio of the size of the gap compared to the average prime gap sizes in the vicinity of

The largest known prime gap with identified probable prime gap ends has length 16045848, with 385713-digit probable primes and merit M = 18.067, found by Andreas Höglund in March 2024.[2] The largest known prime gap with identified proven primes as gap ends has length 1113106 and merit 25.90, with 18662-digit primes found by P. Cami, M. Jansen and J. K. Andersen.[3][4]

As of September 2022, the largest known merit value and first with merit over 40, as discovered by the Gapcoin network, is 41.93878373 with the 87-digit prime 2​9​3​7​0​3​2​3​4​0​6​8​0​2​2​5​9​0​1​5​8​7​2​3​7​6​6​1​0​4​4​1​9​4​6​3​4​2​5​7​0​9​0​7​5​5​7​4​8​1​1​7​6​2​0​9​8​5​8​8​7​9​8​2​1​7​8​9​5​7​2​8​8​5​8​6​7​6​7​2​8​1​4​3​2​2​7. The prime gap between it and the next prime is 8350.[5][6]

More information Merit, gn ...
Largest known merit values (as of October 2020)[5][7][8][9]
MeritgndigitspnDateDiscoverer
41.938784835087see above2017Gapcoin
39.620154159001753483347771 × 409#/30 − 70162017Dana Jacobsen
38.06696018306209650094367 × 491#/2310 − 89362017Dana Jacobsen
38.04789335308404100054841 × 953#/210 − 96702020Seth Troisi
37.824126838297512950801 × 229#/5610 − 41382018Dana Jacobsen
Close

The Cramér–Shanks–Granville ratio is the ratio .[5] If we discard anomalously high values of the ratio for the primes 2, 3, 7, then the greatest known value of this ratio is 0.9206386 for the prime 1693182318746371. For comparison, the gap discovered by the Gapcoin network (whis Merit 41.938784), will only receive a value of 0.205879136 in this index. Other record terms can be found at OEIS: A111943.

We say that is a maximal gap, if for all . As of January 2026, the largest known maximal prime gap has length 1724, found by Martin Raab, using code by Brian Kehrig. It is the 84th maximal prime gap, and it occurs after the prime 68068810283234182907.[10] Other record (maximal) gap sizes can be found in OEIS: A005250, with the corresponding primes in OEIS: A002386, and the values of in OEIS: A005669. The sequence of maximal gaps up to the -th prime is conjectured to have about terms.[11]

More information #, gn ...
The 84 known maximal prime gaps
Gaps 1 to 28
#gnpnn
1121
2232
3474
46239
588924
61411330
71852399
820887154
9221,129189
10341,327217
11369,5511,183
124415,6831,831
135219,6092,225
147231,3973,385
1586155,92114,357
1696360,65330,802
17112370,26131,545
18114492,11340,933
191181,349,533103,520
201321,357,201104,071
211482,010,733149,689
221544,652,353325,852
2318017,051,7071,094,421
2421020,831,3231,319,945
2522047,326,6932,850,174
26222122,164,7476,957,876
27234189,695,65910,539,432
28248191,912,78310,655,462
Gaps 29 to 56
#gnpnn
29250387,096,13320,684,332
30282436,273,00923,163,298
312881,294,268,49164,955,634
322921,453,168,14172,507,380
333202,300,942,549112,228,683
343363,842,610,773182,837,804
353544,302,407,359203,615,628
3638210,726,904,659486,570,087
3738420,678,048,297910,774,004
3839422,367,084,959981,765,347
3945625,056,082,0871,094,330,259
4046442,652,618,3431,820,471,368
41468127,976,334,6715,217,031,687
42474182,226,896,2397,322,882,472
43486241,160,624,1439,583,057,667
44490297,501,075,79911,723,859,927
45500303,371,455,24111,945,986,786
46514304,599,508,53711,992,433,550
47516416,608,695,82116,202,238,656
48532461,690,510,01117,883,926,781
49534614,487,453,52323,541,455,083
50540738,832,927,92728,106,444,830
515821,346,294,310,74950,070,452,577
525881,408,695,493,60952,302,956,123
536021,968,188,556,46172,178,455,400
546522,614,941,710,59994,906,079,600
556747,177,162,611,713251,265,078,335
5671613,829,048,559,701473,258,870,471
Gaps 57 to 84
#gnpnn
5776619,581,334,192,423662,221,289,043
5877842,842,283,925,3511,411,461,642,343
5980490,874,329,411,4932,921,439,731,020
60806171,231,342,420,5215,394,763,455,325
61906218,209,405,436,5436,822,667,965,940
629161,189,459,969,825,48335,315,870,460,455
639241,686,994,940,955,80349,573,167,413,483
641,1321,693,182,318,746,37149,749,629,143,526
651,18443,841,547,845,541,0591,175,661,926,421,598
661,19855,350,776,431,903,2431,475,067,052,906,945
671,22080,873,624,627,234,8492,133,658,100,875,638
681,224203,986,478,517,455,9895,253,374,014,230,870
691,248218,034,721,194,214,2735,605,544,222,945,291
701,272305,405,826,521,087,8697,784,313,111,002,702
711,328352,521,223,451,364,3238,952,449,214,971,382
721,356401,429,925,999,153,70710,160,960,128,667,332
731,370418,032,645,936,712,12710,570,355,884,548,334
741,442804,212,830,686,677,66920,004,097,201,301,079
751,4761,425,172,824,437,699,41134,952,141,021,660,495
761,4885,733,241,593,241,196,731135,962,332,505,694,894
771,5106,787,988,999,657,777,797160,332,893,561,542,066
781,52615,570,628,755,536,096,243360,701,908,268,316,580
791,53017,678,654,157,568,189,057408,333,670,434,942,092
801,55018,361,375,334,787,046,697423,731,791,997,205,041
811,55218,470,057,946,260,698,231426,181,820,436,140,029
821,57218,571,673,432,051,830,099428,472,240,920,394,477
831,67620,733,746,510,561,442,863477,141,032,543,986,017
841,72468,068,810,283,234,182,9071,524,717,378,371,224,128
Close

Further results

Upper bounds

Bertrand's postulate, proven in 1852, states that there is always a prime number between and , so in particular , which means .

The prime number theorem, proven in 1896, says that the average length of the gap between a prime and the next prime will asymptotically approach , the natural logarithm of , for sufficiently large primes. The actual length of the gap might be much more or less than this. However, one can deduce from the prime number theorem that the gaps get arbitrarily smaller in proportion to the primes: the quotient

In other words (by definition of a limit), for every , there is a number such that for all ,

.

Hoheisel (1930) was the first to show[12] a sublinear dependence; that there exists a constant such that

hence showing that

for sufficiently large .

Hoheisel obtained the possible value 32999/33000 for . This was improved to 249/250 by Heilbronn,[13] and to , for any , by Chudakov.[14]

A major improvement is due to Ingham,[15] who showed that for some positive constant c,

if then for any

Here, O refers to the big O notation, ζ denotes the Riemann zeta function and π the prime-counting function. Knowing that any c > 1/6 is admissible, one obtains that θ may be any number greater than 5/8.

Since 5/8+ε < 2/3, and the gap between consecutive cubes is of the order of , it follows that there is always a prime number between n3 and (n + 1)3, if n is sufficiently large.[16] In 2016, Dudek gave an explicit version of Ingham's result: there are primes between consecutive cubes for all .[17]

The Lindelöf hypothesis would imply that Ingham's formula holds for c any positive number: but even this would not be enough to imply that there is a prime number between n2 and (n + 1)2 for n sufficiently large (see Legendre's conjecture). To verify this, a stronger result such as Cramér's conjecture would be needed.

Huxley in 1972 showed that one may choose θ = 7/12 = 0.583.[18]

A result, due to Baker, Harman and Pintz in 2001, shows that θ may be taken to be 0.525.[19]

The above describes limits on all gaps; another area of interest is the minimum gap size. The twin prime conjecture asserts that there are always more gaps of size 2, but remains unproven. In 2005, Daniel Goldston, János Pintz and Cem Yıldırım proved that

and 2 years later improved this[20] to

In 2013, Yitang Zhang proved that

meaning that there are infinitely many gaps that do not exceed 70 million.[21] A Polymath Project collaborative effort to optimize Zhang's bound managed to lower the bound to 4680 on July 20, 2013.[22] In November 2013, James Maynard introduced a new refinement of the GPY sieve, allowing him to reduce the bound to 600 and also show that the gaps between primes m apart are bounded for all m. That is, for any m there exists a bound Δm such that pn+mpnΔm for infinitely many n.[23] Using Maynard's ideas, the Polymath project improved the bound to 246;[22][24] assuming the Elliott–Halberstam conjecture and its generalized form, the bound has been reduced to 12 and 6, respectively.[22]

Lower bounds

In 1931, Erik Westzynthius proved that maximal prime gaps grow more than logarithmically. That is,[1]

In 1938, Robert Rankin proved the existence of a constant c > 0 such that the inequality

holds for infinitely many values of n, improving the results of Westzynthius and Paul Erdős. He later showed that one can take any constant c < eγ, where γ is the Euler–Mascheroni constant. The value of the constant c was improved in 1997 to any value less than 2eγ.[25]

Paul Erdős offered a $10,000 prize for a proof or disproof that the constant c in the above inequality may be taken arbitrarily large.[26] This was proved to be correct in 2014 by Ford–Green–Konyagin–Tao and, independently, James Maynard.[27][28]

The result was further improved to

for infinitely many values of n by Ford–Green–Konyagin–Maynard–Tao.[29]

In the spirit of Erdős' original prize, Terence Tao offered US$10,000 for a proof that c may be taken arbitrarily large in this inequality.[30]

Lower bounds for chains of primes have also been determined.[31]

Conjectures about gaps between primes

As described above, the best proven bound on gap sizes is gnpn0.525 (for n sufficiently large; we do not worry about 5 − 3 > 30.525 or 29 − 23 > 230.525), but it is observed that even maximal gaps are significantly smaller than that, leading to a plethora of unproven conjectures.

The first group hypothesize that the exponent can be reduced to θ = 0.5.

Both Legendre's conjecture that there always exists a prime between consecutive perfect squares and Andrica's conjecture that the difference of square roots of consecutive primes is bounded by 1[32] imply that

Oppermann's conjecture makes the stronger claim that, for sufficiently large n (probably n ≥ 31),

All of these remain unproved. Harald Cramér came close, proving[33] that the Riemann hypothesis implies the gap gn satisfies

using the big O notation. (In fact this result needs only the weaker Lindelöf hypothesis, if one can tolerate an infinitesimally larger exponent.[34])

Dudek also proved an explicit version of Cramer's result (also assuming Riemann hypothesis) for all n ≥ 2, that is

Prime gap function

In the same article, Cramér conjectured that the gaps are far smaller. Roughly speaking, Cramér's conjecture states that

a polylogarithmic growth rate slower than any exponent θ > 0.

Cramér's model, under which he made the conjecture, was oversimplified (assuming some events are statistically independent when they are dependent) and thus not very accurate (see Cramér's conjecture), but after further investigations, new heuristics were found which became strong evidence that the conjecture is true.

As this matches the observed growth rate of prime gaps, there are a number of similar conjectures. Firoozbakht's conjecture is slightly stronger, stating that pn1/n is a strictly decreasing function of n, i.e.,

If this conjecture were true, then gn < (log pn)2 − log pn − 1 for all n ≥ 10.[35][36] It implies a strong form of Cramér's conjecture but is inconsistent with the heuristics of Granville and Pintz,[37][38][39] which suggest that gn > (2 − ϵ)eγ(log pn)2 > (1.1229 − ϵ)(log pn)2 infinitely often for any ϵ > 0, where γ denotes the Euler–Mascheroni constant.

Polignac's conjecture states that every positive even number k occurs as a prime gap infinitely often. The case k = 2 is the twin prime conjecture. The conjecture has not yet been proven or disproven for any specific value of k, but the improvements on Zhang's result discussed above prove that it is true for at least one (currently unknown) value of k  246.

As an arithmetic function

The gap gn between the nth and (n +1)th prime numbers is an example of an arithmetic function. In this context it is usually denoted dn and called the prime difference function.[32] The function is neither multiplicative nor additive.

See also

References

Further reading

Related Articles

Wikiwand AI