login
A088212
Smallest k>1 such that n+k^2 is prime.
2
2, 3, 2, 3, 6, 5, 2, 3, 2, 3, 6, 5, 2, 3, 2, 5, 6, 5, 2, 3, 4, 3, 6, 7, 2, 9, 2, 3, 12, 7, 4, 3, 2, 3, 6, 5, 2, 3, 2, 7, 24, 5, 2, 3, 4, 5, 6, 5, 2, 3, 4, 3, 6, 5, 2, 9, 2, 3, 18, 7, 6, 3, 2, 3, 6, 25, 2, 9, 2, 3, 6, 5, 4, 3, 2, 5, 6, 5, 2, 3, 4, 5, 12, 5, 2, 9, 4, 3, 12, 7, 4, 3, 2, 3, 6, 19, 2, 3, 2, 3, 6, 5, 2
OFFSET
1,1
COMMENTS
Conjecture: all integers >1 eventually appear. Among first 300000 terms, first absent integers are 113, 119, 122, 124, 127, 130, 134, 136, 137, 139, 140, 142, 143, 145, 146, 148, 149, 151, 152, 154, 155, 157, 158, 160, 161, 163, 164, 166, 167, 169, 170, 172, 173, 175, 176, 178, 179, 181, 182, 184, 185, 186, 187, 188, 190, 191, 193, 194, 196, 197, 199, 200. - Zak Seidov, Jun 06 2013
EXAMPLE
n=1: 1+2^2=5; n=5: 5+6^2=41.
MATHEMATICA
k[n_]:=Module[{k=2}, While[!PrimeQ[n+k^2], k++]; k]; Array[k, 110] (* Harvey P. Dale, Aug 19 2011 *)
CROSSREFS
Cf. A088213.
Sequence in context: A235669 A118088 A298211 * A085208 A332553 A257302
KEYWORD
easy,nonn
AUTHOR
Zak Seidov, Sep 23 2003
STATUS
approved