OFFSET
1,1
LINKS
Charles R Greathouse IV, Table of n, a(n) for n = 1..10000
EXAMPLE
13 = 2^2 + 3^2, 2^4 + 3^4 = 97 is prime.
MATHEMATICA
nn = 40; t = {}; Do[c = a^2 + b^2; If[c < nn^2 && PrimeQ[c] && PrimeQ[a^4 + b^4], AppendTo[t, c]], {a, nn}, {b, a}]; Sort[t] (* T. D. Noe, Apr 22 2012 *)
Take[#[[1]]^2+#[[2]]^2&/@Select[Tuples[Range[40], 2], AllTrue[{#[[1]]^2+ #[[2]]^2, #[[1]]^4+#[[2]]^4}, PrimeQ]&]//Union, 60] (* Harvey P. Dale, Jun 25 2018 *)
PROG
(PARI) list(lim)=my(v=List(), t); lim\=1; for(x=1, sqrtint(lim), for(y=1, min(sqrtint(lim-x^2), x), if(isprime(t=x^2+y^2)&&isprime(x^4+y^4), listput(v, t)))); vecsort(Vec(v), , 8) \\ Charles R Greathouse IV, Apr 22 2012
CROSSREFS
KEYWORD
nonn
AUTHOR
Thomas Ordowski, Apr 20 2012
STATUS
approved