OFFSET
1,2
LINKS
Paul D. Hanna, Table of n, a(n) for n = 1..1000
FORMULA
G.f.: Sum_{n>=1} a(n)*x^n/n = log(F(x)), where F(x) is the g.f. of A117210 and satisfies: (1+x) = Product_{n>=1} F(x^n).
a(n) = A023900(n) if n (mod 4) = 1 or 3, a(n) = 3*A023900(n) if n (mod 4) = 2, a(n) = -A023900(n) if n (mod 4) = 0, where A023900 is the Dirichlet inverse of Euler totient function.
From Stuart Clary, Apr 15 2006: (Start)
G.f.: A(x) = sum_{k>=1} mu(k) k x^k/(1 + x^k) where mu(k) is the Möbius function, A008683.
G.f.: A(x) is x times the logarithmic derivative of A117210(x).
a(n) = sum_{d|n} (-1)^(n/d - 1) mu(d) d.
(End)
Dirichlet convolution of A055615 and A062157, so the Dirichlet g.f. is the product zeta(s)*(1-2^(1-s))/zeta(s-1). - R. J. Mathar, Feb 07 2011
Multiplicative with a(2) = -3, a(2^e) = 1 for e >= 2, and a(p^e) = 1 - p for an odd prime p. - Amiram Eldar, Aug 31 2023
EXAMPLE
For n=6, Sum_{d|6} a(d)/d = a(1)/1 + a(2)/2 + a(3)/3 + a(6)/6 = 1/1 - 3/2 - 2/3 + 6/6 = -1/6.
MATHEMATICA
nmax = 72; Drop[ CoefficientList[ Series[ Sum[ MoebiusMu[k] k x^k/(1 + x^k), {k, 1, nmax} ], {x, 0, nmax} ], x ], 1 ] (* Stuart Clary, Apr 15 2006 *)
f[p_, e_] := 1 - p; f[2, e_] := If[e == 1, -3, 1]; a[1] = 1; a[n_] := Times @@ f @@@ FactorInteger[n]; Array[a, 100] (* Amiram Eldar, Aug 31 2023 *)
PROG
(PARI) a(n)=sumdiv(n, d, d*moebius(d))*[1, 3, 1, -1][(n-1)%4+1]
CROSSREFS
KEYWORD
sign,easy,mult
AUTHOR
Paul D. Hanna, Mar 03 2006
STATUS
approved