login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

A065043
Characteristic function of the numbers with an even number of prime factors (counted with multiplicity): a(n) = 1 if n = A028260(k) for some k then 1 else 0.
46
1, 0, 0, 1, 0, 1, 0, 0, 1, 1, 0, 0, 0, 1, 1, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 0, 1, 1, 1, 0, 0, 0, 0, 0, 1, 0, 0, 1, 0, 1, 0, 0, 1, 1, 1, 1, 1, 0, 1, 0, 1, 0, 1, 1, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 1, 0, 0, 0, 1, 1, 0, 1, 1, 1, 1, 1, 0, 1, 1, 0, 1, 1, 1, 1, 0, 0, 0, 1, 0, 0, 0, 1, 0
OFFSET
1,1
FORMULA
a(n) = 1 - A001222(n) mod 2.
a(n) = A007421(n) - 1.
a(n) = 1 - A066829(n).
a(A028260(k)) = 1 and a(A026424(k)) = 0 for all k.
Dirichlet g.f.: (zeta(s)^2 + zeta(2*s))/(2*zeta(s)). - Enrique Pérez Herrero, Jul 06 2012
a(n) = (A008836(n) + 1)/2. - Enrique Pérez Herrero, Jul 07 2012
a(n) = A001222(2n) mod 2. - Wesley Ivan Hurt, Jun 22 2013
G.f.: Sum_{n>=1} a(n)*x^n/(1 - x^n) = Sum_{n>=1} x^(n^2)/(1 - x^n). - Ilya Gutkovskiy, Apr 25 2017
From Antti Karttunen, Dec 01 2022: (Start)
For x, y >= 1, a(x*y) = 1 - abs(a(x)-a(y)).
a(n) = a(A046523(n)) = A356163(A003961(n)).
a(n) = A000035(A356163(n)+A347102(n)).
a(n) = A010052(n) + A353669(n).
a(n) = A353555(n) + A353557(n).
a(n) = A358750(n) + A358752(n).
a(n) = A353374(n) + A358775(n).
a(n) >= A356170(n).
(End)
MAPLE
A065043 := proc(n)
if type(numtheory[bigomega](n), 'even') then
1;
else
0;
end if;
end proc: # R. J. Mathar, Jun 26 2013
MATHEMATICA
Table[(LiouvilleLambda[n]+1)/2, {n, 1, 20}] (* Enrique Pérez Herrero, Jul 07 2012 *)
PROG
(PARI) { for (n=1, 1000, a=1 - bigomega(n)%2; write("b065043.txt", n, " ", a) ) } \\ Harry J. Smith, Oct 04 2009
(PARI) A065043(n) = (1 - (bigomega(n)%2)); \\ Antti Karttunen, Apr 19 2022
(Python)
from operator import ixor
from functools import reduce
from sympy import factorint
def A065043(n): return (reduce(ixor, factorint(n).values(), 0)&1)^1 # Chai Wah Wu, Jan 01 2023
CROSSREFS
Characteristic function of A028260 (positions of 1's). Cf. also A026424 (positions of 0's) and A320655.
One less than A007421.
Cf. also A066829, A353374.
Sequence in context: A267598 A194681 A359764 * A189298 A288375 A121559
KEYWORD
nonn
AUTHOR
Reinhard Zumkeller, Nov 05 2001
EXTENSIONS
Corrected by Charles R Greathouse IV, Sep 02 2009
STATUS
approved