OFFSET
1,1
LINKS
Robert Israel, Table of n, a(n) for n = 1..10000
EXAMPLE
a(1)=41 since p=41 is the least prime of the form 4k+1 for which p-(floor(sqrt(p)))^2 is not a square, but 2p-(floor(sqrt(2p)))^2 is a square (for p=41 it is 1).
MAPLE
filter:= proc(p)
if not isprime(p) then return false fi;
if issqr(p-floor(sqrt(p))^2) then return false fi;
issqr(2*p-floor(sqrt(2*p))^2)
end proc:
select(filter, [seq(p, p=1..10000, 4)]); # Robert Israel, Dec 04 2018
MATHEMATICA
sQ[n_] := IntegerQ[Sqrt[n - (Floor[Sqrt[n]])^2]]; aQ[n_] := Mod[n, 4] == 1 && PrimeQ[n] && !sQ[n] && sQ[2n]; Select[Range[2200], aQ] (* Amiram Eldar, Dec 04 2018 *)
CROSSREFS
KEYWORD
nonn
AUTHOR
Vladimir Shevelev, Sep 29 2008
STATUS
approved