OFFSET
1,2
REFERENCES
N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).
LINKS
Vincenzo Librandi, Table of n, a(n) for n = 1..1000
Eric Weisstein's World of Mathematics, Near-Square Prime
MATHEMATICA
lst={}; Do[If[PrimeQ[n^2+4], Print[n]; AppendTo[lst, n]], {n, 10^5}]; lst (* Vladimir Joseph Stephan Orlovsky, Aug 21 2008 *)
Select[Range[0, 400], PrimeQ[#^2 + 4] &] (* Vincenzo Librandi, Sep 25 2012 *)
PROG
(Magma) [n: n in [0..400] | IsPrime(n^2+4)]; // Vincenzo Librandi, Nov 18 2010
(PARI) select(n->isprime(n^2+4), vector(500, n, 2*n-1)) \\ Charles R Greathouse IV, Sep 25 2012
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
STATUS
approved