OFFSET
1,1
COMMENTS
Primes which are less than some previous term: 7, 19, 43, 47, 83, 103, 107, 113, ...
In the first 10000 terms the range of the differences between primepi(a(i)) and (i+1) is from -39 to 78.
In the first 10000 terms the range of the differences between a(i) and the (i+1)th prime is from -416 to 912.
Conjecture: Every odd prime eventually appears; a(n) ~ prime(n).
LINKS
Robert G. Wilson v, Table of n, a(n) for n = 1..10000
EXAMPLE
a(3)=11 because 3 + 5 + 7 = 15 is composite and 3 + 5 + 11 = 19 is prime.
MATHEMATICA
f[s_List] := Block[{p = s[[-2]] + s[[-1]], q = 7}, While[ !PrimeQ[p + q] || MemberQ[s, q], q = NextPrime[q]]; Append[s, q]]; Nest[f, {3, 5}, 56] (* Robert G. Wilson v, Mar 19 2012 *)
CROSSREFS
KEYWORD
nonn
AUTHOR
Amarnath Murthy, Aug 10 2002
EXTENSIONS
More terms from Sascha Kurz, Jan 28 2003
STATUS
approved