login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A165918 a(n) = number of squarefree quadratic non-residues of n. 1
0, 0, 1, 2, 2, 2, 3, 5, 4, 3, 4, 7, 5, 5, 7, 10, 7, 8, 6, 11, 10, 8, 10, 15, 10, 8, 11, 15, 10, 12, 12, 18, 15, 11, 15, 21, 13, 13, 19, 25, 16, 19, 14, 25, 24, 17, 19, 29, 19, 18, 21, 28, 17, 22, 25, 33, 25, 18, 19, 35, 21, 22, 32, 34, 28, 29, 20, 36, 33, 31, 29, 44, 26, 23 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,4
LINKS
PROG
(PARI) squares(n) = {local(s = Set()); for (j=1, n, s = setunion(s, Set(j^2 % n)); ); return (s); }
qnonr(n) = {local(s = Set()); sq = squares(n); for (j=0, n-1, if (length(setintersect(Set(j), sq))==0, s = setunion(s, Set(j))); ); return (s); }
a(n) = {s = Set(); qnr = qnonr(n); for (j=1, #qnr, if (issquarefree(eval(qnr[j])), s = setunion(s, Set(qnr[j]))); ); return (#s); } \\ Michel Marcus, Jul 23 2013
CROSSREFS
Cf. A165916.
Sequence in context: A082408 A270566 A182534 * A114639 A071867 A126337
KEYWORD
nonn
AUTHOR
EXTENSIONS
a(1) added by Christopher Hunt Gribble, Oct 05 2009
STATUS
approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 25 03:15 EDT 2024. Contains 371964 sequences. (Running on oeis4.)