OFFSET
1,1
COMMENTS
The integer square root of an integer x >= 0 can be defined as floor(sqrt(x)) and the remainder of this as x - (floor(sqrt(x)))^2.
LINKS
Robert Israel, Table of n, a(n) for n = 1..10000
Wikipedia, Integer square root
MAPLE
map(p -> select(isprime, [$p^2+1..(p+1)^2-1]), [seq(ithprime(i), i=1..10)]); # Robert Israel, Jun 08 2018
MATHEMATICA
f[n_]:=PrimeQ[IntegerPart[Sqrt[n]]]; lst={}; Do[p=Prime[n]; If[f[p], AppendTo[lst, p]], {n, 6!}]; lst (* Vladimir Joseph Stephan Orlovsky, Dec 12 2009 *)
Select[Prime[Range[200]], PrimeQ[IntegerPart[Sqrt[#]]]&] (* Harvey P. Dale, Jun 23 2016 *)
PROG
(PARI) { forprime(p=2, 2000, isr = sqrtint(p); if (isprime(isr), print1(p, ", ") ) ) }
CROSSREFS
KEYWORD
nonn
AUTHOR
Harry J. Smith, Dec 07 2007
STATUS
approved