A290489 Upper ends of record gaps between numbers that are either prime or twice a prime.
3, 10, 53, 191, 478, 538, 1082, 1277, 1346, 2498, 3299, 5147, 12889, 20849, 28277, 31454, 338098, 520526, 546461, 1050706, 1761289, 1965077, 3467038, 6085103, 27348949, 27915898, 111108917, 113652593, 230126531, 231902434, 327764249, 438981203, 581755523, 1837981759, 2489382911
Offset: 1
Keywords
Examples
a(3) = 53 because the next number that is a prime or twice a prime after 47 is 53, and that is a record gap of size 6.
Links
- Giovanni Resta, Table of n, a(n) for n = 1..40
Programs
-
Mathematica
p = op = 2; r = 0; Reap[While[p < 10^6, p++; If[PrimeQ[p] || PrimeQ[p/2], g = p - op; If[g > r, Sow@p; r = g]; op = p]]][[2, 1]] (* Giovanni Resta, Aug 04 2017 *)
Extensions
a(17)-a(35) from Giovanni Resta, Aug 04 2017
Comments