OFFSET
1,1
LINKS
Robert Israel, Table of n, a(n) for n = 1..10000
MAPLE
p:= 1: q:= 2:
res:= NULL: count:= 0:
while count < 100 do
p:= q; q:= nextprime(p);
m:= p^3 + q^2;
if isprime(m-1) and isprime(m+1) then
count:= count+1; res:= res, p;
fi
od:
res; # Robert Israel, Apr 02 2018
MATHEMATICA
a={}; Do[p1=Prime[n]; p2=Prime[n+1]; pp=p1^3+p2^2; If[PrimeQ[pp-1]&&PrimeQ[pp+1], AppendTo[a, p1]], {n, 16^3}]; Print[a];
CROSSREFS
KEYWORD
nonn
AUTHOR
Vladimir Joseph Stephan Orlovsky, May 15 2008
STATUS
approved