OFFSET
1,2
COMMENTS
Sequence A002314 gives the minimal integer square root of -1 modulo p(n),where p(n) = n-th prime of form 4k+1.
EXAMPLE
for n=1, k = A002314(1) = 2 => a(1) = 1, because 2^2+1 = 5 and (2+1)^2+1 = 2*5 ;
for n=2, k = A002314(2) = 5 => a(2) = 3, because 5^2+1 = 2*13 and (5+3)^2+1 = 5*13 ;
for n=3, k = A002314(3) = 4 => a(3) = 9, because 4^2+1 = 17 and (4+9)^2+1 = 2*5*17;
for n=4, k = A002314(4)= 12 => a(4)= 5, because 12^2+1
= 5*29 and (12+5)^2+1 = 2*5*29, and 29 divides
GCD(5*29, 2*5*29)=145.
MAPLE
with(numtheory):T:=array(1..90):j:=1:for i from 1 to 250 do:x:=4*i+1:if type(x, prime)=true
then T[j]:=x:j:=j+1:else fi:od:for p from 1 to j do:u:=T[p]:id:=0: for m from
1 to 1000 while(id=0) do: z:=m^2+1:for d from 1 to u while(id=0) do: z1:=(m+d)^2+1:zz:=
gcd(z, z1):if irem(zz, u)=0 then id:=1:printf(`%d, `, d):else fi:od:od:od:
CROSSREFS
KEYWORD
nonn
AUTHOR
Michel Lagneau, Feb 27 2011
STATUS
approved