login
A374130
a(n) = 1 if bitwise-XOR of the exponents of primes in the prime factorization of n is equal to 1, otherwise 0.
3
0, 1, 1, 0, 1, 0, 1, 0, 0, 0, 1, 0, 1, 0, 0, 0, 1, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 1, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 1, 1, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0, 1, 0, 0, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 1, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 1, 1, 1, 0, 1, 0, 1, 1, 1, 1, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0
OFFSET
1
FORMULA
a(n) = [A268387(n) = 1], where [ ] is the Iverson bracket.
For k in A268390, a(A059897(n,k)) = a(n).
MATHEMATICA
A374130[n_] := If[n == 1, 0, Boole[BitXor @@ FactorInteger[n][[All, 2]] == 1]];
Array[A374130, 100] (* Paolo Xausa, Jul 16 2024 *)
PROG
(PARI)
A268387(n) = { my(f=factor(n), b=0); for(k=1, #f~, b = bitxor(b, f[k, 2]); ); b; }; \\ From A268387
A374130(n) = (1==A268387(n));
CROSSREFS
Characteristic function of A374595.
Differs from A252233 first at n=72, where a(72) = 1, while A252233(72) = 0.
Differs from A374466 first at n=128, where a(128) = 0, while A374466(128) = 1.
Sequence in context: A010051 A358751 A252233 * A374466 A283991 A353499
KEYWORD
nonn
AUTHOR
Antti Karttunen and Peter Munn, Jul 14 2024
STATUS
approved