The OEIS mourns the passing of Jim Simons and is grateful to the Simons Foundation for its support of research in many branches of science, including the OEIS.
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!)
A359469 a(n) = A353459(n) mod 2. 3
0, 0, 0, 1, 0, 0, 0, 1, 1, 0, 0, 1, 0, 0, 0, 1, 0, 1, 0, 1, 0, 0, 0, 1, 1, 0, 1, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 1, 1, 0, 0, 1, 1, 1, 0, 1, 0, 1, 0, 1, 0, 0, 0, 1, 0, 0, 1, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 1, 1, 0, 0, 1, 0, 0, 0, 1, 0, 1, 0, 1, 0, 0, 0, 1, 0, 1, 1, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 1, 1, 0, 0, 1, 1 (list; graph; refs; listen; history; text; internal format)
OFFSET
1
LINKS
FORMULA
For all n >= 1, a(n) = a(A003961(n)) = a(A348717(n)).
PROG
(PARI)
A353457(n) = { my(f=factor(n)); prod(i=1, #f~, if(!(primepi(f[i, 1])%2), 1, if(f[i, 2]==1, -1, 0))); };
A353458(n) = { my(f=factor(n)); prod(i=1, #f~, if(primepi(f[i, 1])%2, 1, if(f[i, 2]==1, -1, 0))); };
A353459(n) = (A353457(n)+A353458(n));
A359469(n) = (A353459(n)%2);
(Python)
from functools import reduce
from operator import iand
from sympy import factorint, primepi
def A359469(n):
f = [(primepi(p)&1, int(e==1)) for p, e in factorint(n).items()]
return reduce(iand, (e for p, e in f if not p), 1)^reduce(iand, (e for p, e in f if p), 1) # Chai Wah Wu, Jan 06 2023
CROSSREFS
Characteristic function of A359470.
Differs from A359466 and A359467 for the first time at n=100, as here a(100) = 1.
Sequence in context: A345952 A359466 A359467 * A107078 A341613 A163533
KEYWORD
nonn
AUTHOR
Antti Karttunen, Jan 04 2023
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 May 13 02:41 EDT 2024. Contains 372497 sequences. (Running on oeis4.)