OFFSET
1,1
COMMENTS
Each cluster of candidates is about e (2.71828...) times as large as the previous one.
EXAMPLE
The average of prime(4) = 7 and prime(6) = 13 is 10, which is divisible by 5, so 5 is a term of the sequence.
MATHEMATICA
a = 0; b = 1; c = 2; Do[ c = Prime[ n + 1 ]; If[ IntegerQ[ (a + c)/(2n) ], Print[ n ] ]; a = b; b = c, {n, 1, 2 10^9} ]
Select[Range[2, 41000], Mod[(Prime[#-1]+Prime[#+1])/2, #]==0&] (* The program generates the first 10 terms of the sequence. *) (* Harvey P. Dale, Feb 21 2026 *)
CROSSREFS
KEYWORD
nonn
AUTHOR
Robert G. Wilson v, Jan 20 2002
STATUS
approved
