OFFSET
0,1
COMMENTS
Equivalently, a(n) is the smallest prime p = prime(k) such that there is a polynomial f of degree at most 2 such that f(j) = prime(j) for k <= j <= k + n.
Any sequence of at most 2 terms is considered to be a degenerate arithmetic progression, so a(n) = 2 (the smallest prime) for n <= 2.
EXAMPLE
The three prime gaps following the prime 17 are 2, 4, and 6, which are in arithmetic progression. This is not true for any smaller prime, so a(3) = 17.
The eight prime gaps following the prime 19641263 are 20, 18, 16, 14, 12, 10, 8, and 6, which are in arithmetic progression. This is not true for any smaller prime, so a(8) = 19641263.
CROSSREFS
KEYWORD
nonn,more
AUTHOR
Pontus von Brömssen, Nov 23 2021
EXTENSIONS
a(12)-a(13) from Martin Ehrenstein, Dec 05 2021
STATUS
approved