login
a(n) = omega(n) * (-1)^mu(n), where mu is the Moebius function.
2

%I #32 Oct 05 2024 09:09:42

%S 0,-1,-1,1,-1,-2,-1,1,1,-2,-1,2,-1,-2,-2,1,-1,2,-1,2,-2,-2,-1,2,1,-2,

%T 1,2,-1,-3,-1,1,-2,-2,-2,2,-1,-2,-2,2,-1,-3,-1,2,2,-2,-1,2,1,2,-2,2,

%U -1,2,-2,2,-2,-2,-1,3,-1,-2,2,1,-2,-3,-1,2,-2,-3,-1,2,-1,-2,2,2,-2,-3,-1,2,1

%N a(n) = omega(n) * (-1)^mu(n), where mu is the Moebius function.

%C Numbers k such that: a(k) < -1: A120944; a(k) = -1: A000040, a(k) > -1: A162966; a(k) = +1: A246547; a(k) > +1: A126706.

%H Daniel Forgues, <a href="/A158210/b158210.txt">Table of n, a(n) for n = 1..10000</a>

%F a(n) = omega(n) * (-1)^mu(n), where mu is the Moebius function.

%F a(n) = A001221(n) * (-1)^A008683(n).

%F a(mn) = [|a(m)| + |a(n)|] * max(sign[a(n)], sign[a(m)]), gcd(m,n) = 1, m > 1, n > 1.

%F Sum_{k=1..n} a(k) = (1-2/zeta(2)) * n * log(log(n)) + O(n). - _Amiram Eldar_, Oct 05 2024

%t Table[(-1)^MoebiusMu[n]*PrimeNu[n], {n, 81}] (* _L. Edson Jeffery_, Dec 08 2014 *)

%o (PARI) a(n) = {my(f= factor(n)); omega(f) * (-1)^moebius(f);} \\ _Amiram Eldar_, Oct 05 2024

%Y Cf. A001221 (omega), A008683 (mu).

%Y Cf. A120944, A000040, A162966, A246547, A126706, A013661.

%K sign

%O 1,6

%A _Daniel Forgues_, Mar 14 2009

%E Edited by _Joerg Arndt_, Feb 12 2024