cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A293439 Number of odious exponents in the prime factorization of n.

This page as a plain text file.
%I A293439 #23 Nov 23 2023 12:14:05
%S A293439 0,1,1,1,1,2,1,0,1,2,1,2,1,2,2,1,1,2,1,2,2,2,1,1,1,2,0,2,1,3,1,0,2,2,
%T A293439 2,2,1,2,2,1,1,3,1,2,2,2,1,2,1,2,2,2,1,1,2,1,2,2,1,3,1,2,2,0,2,3,1,2,
%U A293439 2,3,1,1,1,2,2,2,2,3,1,2,1,2,1,3,2,2,2,1,1,3,2,2,2,2,2,1,1,2,2,2,1,3,1,1,3
%N A293439 Number of odious exponents in the prime factorization of n.
%H A293439 Antti Karttunen, <a href="/A293439/b293439.txt">Table of n, a(n) for n = 1..16384</a>
%H A293439 <a href="/index/Eu#epf">Index entries for sequences computed from exponents in factorization of n</a>.
%F A293439 Additive with a(p^e) = A010060(e).
%F A293439 a(n) = A007814(A293443(n)).
%F A293439 From _Amiram Eldar_, Sep 28 2023: (Start)
%F A293439 a(n) >= 0, with equality if and only if n is an exponentially evil number (A262675).
%F A293439 a(n) <= A001221(n), with equality if and only if n is an exponentially odious number (A270428).
%F A293439 Sum_{k=1..n} a(k) ~ n * (log(log(n)) + B + C), where B is Mertens's constant (A077761) and C = Sum_{p prime} f(1/p) = -0.12689613844142998028..., where f(x) = 1/2 - x - ((1-x)/2) * Product_{k>=0} (1-x^(2^k)). (End)
%e A293439 For n = 2 = 2^1, the only exponent 1 is odious (that is, has an odd Hamming weight and thus is included in A000069), so a(2) = 1.
%e A293439 For n = 24 = 2^3 * 3^1, the exponent 3 (with binary representation "11") is evil (has an even Hamming weight and thus is included in A001969), while the other exponent 1 is odious, so a(24) = 1.
%t A293439 a[n_] := Total@ ThueMorse[FactorInteger[n][[;; , 2]]]; a[1] = 0; Array[a, 100] (* _Amiram Eldar_, May 18 2023 *)
%o A293439 (PARI) A293439(n) = vecsum(apply(e -> (hammingweight(e)%2), factorint(n)[, 2]));
%o A293439 (Python)
%o A293439 from sympy import factorint
%o A293439 def A293439(n): return sum(1 for e in factorint(n).values() if e.bit_count()&1) # _Chai Wah Wu_, Nov 23 2023
%Y A293439 Cf. A000069, A010060, A077761, A262675, A293443.
%Y A293439 Cf. A270428 (numbers such that a(n) = A001221(n)).
%Y A293439 Differs from A144095 for the first time at n=24.
%K A293439 nonn,easy
%O A293439 1,6
%A A293439 _Antti Karttunen_, Nov 01 2017