login
A274121
The gap prime(n+1) - prime(n) occurs for the a(n)-th time.
8
1, 1, 2, 1, 3, 2, 4, 3, 1, 5, 2, 4, 6, 5, 3, 4, 7, 5, 6, 8, 6, 7, 7, 1, 8, 9, 9, 10, 10, 1, 11, 8, 11, 1, 12, 9, 10, 12, 11, 12, 13, 2, 14, 13, 15, 1, 2, 14, 16, 15, 13, 17, 3, 14, 15, 16, 18, 17, 16, 19, 4, 2, 17, 20, 18, 3, 18, 5, 21, 19, 19, 2, 20, 21, 20, 22, 3, 21, 4, 6, 22, 7, 23, 23, 22, 24, 5, 23, 24, 24, 3, 6
OFFSET
1,3
COMMENTS
Terms of this sequence grow without bound; any even number occurs in this sequence. Zhang proved that there are infinitely many primes 4680 apart from each other (see link "Bounded gaps between primes").
For a conjectured count of gap n below x, see link Polignac's conjecture.
Polignac's conjecture states that "For any positive even number n, there are infinitely many prime gaps of size n.". By this conjecture, every positive apppears infinitely many times in this sequence (see link "Polignac's conjecture").
FORMULA
a(primepi(A000230(n))) = 1.
a(primepi(A001359(n))) = n.
a(primepi(A029710(n))) = n.
EXAMPLE
(p, g) denotes a prime p and the gap up to the next prime. So p + g is the next prime after p. These pairs start (2, 1), (3, 2), (5, 2), (7, 4), (11, 2). From here we see that:
- the gap after the first prime, 1 occurs for the first time, so a(1) = 1.
- the gap after the second prime, 2, occurs for the first time, so a(2) = 1.
- the gap after the third prime, 2, occurs for the second time, so a(3) = 2.
- the gap after the fourth prime, 4, occurs for the first time, so a(4) = 1.
- the gap after the fifth prime, 2, occurs for the third time, so a(5) = 3.
PROG
(PARI) \\ See link by name "PARI program" for an extended version with comments.
upto(n) = {my(gapcount=List(), freqgap = List([1])); n = max(n, 3); forprime(i=3, n,
g = nextprime(i+1) - i; for(i=#gapcount+1, g\2, listput(gapcount, 0)); gapcount[g\2]++; listput(freqgap, gapcount[g\2])); freqgap} \\ David A. Corneth, Jun 28 2016
CROSSREFS
KEYWORD
nonn
AUTHOR
David A. Corneth, Jun 10 2016
STATUS
approved