OFFSET
1,1
COMMENTS
Corresponding primes in A108657.
LINKS
Harvey P. Dale, Table of n, a(n) for n = 1..1000
EXAMPLE
a(1)=2, a(2)=3 and a(3)=2 because 2*3^2+3*3+2=29 is aprime; a(4)=3, a(5)=2 and a(6)=7 because 3*6^2+2*6+7=127 is a prime.
MATHEMATICA
a=2; b=3; s={a, b}; Do[c=Prime[PrimePi[a*n^2+b*n]+1]-a*n^2-b*n; AppendTo[s, c]; a=b; b=c, {n, 3, 200}]; A108656=s
nxt[{n_, a_, b_}]:=Module[{c=a(n+1)^2+b(n+1)}, {n+1, b, NextPrime[c]-c}]; Join[{2}, Transpose[NestList[nxt, {2, 2, 3}, 100]][[3]]] (* Harvey P. Dale, Dec 17 2013 *)
CROSSREFS
KEYWORD
nonn
AUTHOR
Zak Seidov, Jun 14 2005
STATUS
approved