A282043 Let p = n-th prime == 7 mod 8; a(n) = sum of quadratic nonresidues mod p.
Keywords
Links
- Aebi, Christian, and Grant Cairns. Sums of Quadratic residues and nonresidues, arXiv preprint arXiv:1512.00896 (2015).
Programs
-
Maple
with(numtheory): Ql:=[]; Qu:=[]; Q:=[]; Nl:=[]; Nu:=[]; N:=[]; for i1 from 1 to 300 do p:=ithprime(i1); if (p mod 8) = 7 then ql:=0; qu:=0; q:=0; nl:=0; nu:=0; n:=0; for j from 1 to p-1 do if legendre(j,p)=1 then q:=q+j; if j
-
Mathematica
sqnr[p_] := Select[Range[p-1], JacobiSymbol[#, p] != 1&] // Total; sqnr /@ Select[Prime[Range[200]], Mod[#, 8] == 7&] (* Jean-François Alcover, Aug 30 2018 *)
Comments