login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A332794 a(n) = Sum_{d|n} (-1)^(d + 1) * d * phi(n/d). 3

%I #32 Jan 22 2024 08:18:25

%S 1,-1,5,-4,9,-5,13,-12,21,-9,21,-20,25,-13,45,-32,33,-21,37,-36,65,

%T -21,45,-60,65,-25,81,-52,57,-45,61,-80,105,-33,117,-84,73,-37,125,

%U -108,81,-65,85,-84,189,-45,93,-160,133,-65,165,-100,105,-81,189

%N a(n) = Sum_{d|n} (-1)^(d + 1) * d * phi(n/d).

%H Olivier Bordelles, <a href="https://cs.uwaterloo.ca/journals/JIS/VOL18/Bordelles/bord21.html">A Multidimensional Cesaro Type Identity and Applications</a>, J. Int. Seq. 18 (2015) # 15.3.7.

%F G.f.: Sum_{k>=1} phi(k) * x^k / (1 + x^k)^2.

%F Dirichlet g.f.: zeta(s-1)^2 * (1 - 2^(2 - s)) / zeta(s).

%F a(n) = Sum_{k=1..n} gcd(n, k) if n odd, Sum_{k=1..n} (-1)^(k + 1) * gcd(n, k) if n even.

%F From _Amiram Eldar_, Nov 04 2022: (Start)

%F Multiplicative with a(2^e) = -e*2^(e-1), and a(p^e) = (e*(p-1) + p)*p^(e-1) for p > 2.

%F Sum_{k=1..n} a(k) ~ c * n^2, where c = 3*log(2)/Pi^2 = 0.210691... . (End)

%F a(2*n) = - Sum_{k = 1..n} gcd(2*k, n) = - A344372(n); a(2*n+1) = A018804(2*n+1). - _Peter Bala_, Jan 11 2024

%F a(n) = Sum_{k = 1..n} (-1)^(1 + gcd(k, n)) * gcd(k, n) (follows from an identity of Cesàro. See, for example, Bordelles, Lemma 1). - _Peter Bala_, Jan 16 2024

%t a[n_] := Sum[(-1)^(d + 1) d EulerPhi[n/d], {d, Divisors[n]}]; Table[a[n], {n, 1, 55}]

%t nmax = 55; CoefficientList[Series[Sum[EulerPhi[k] x^k/(1 + x^k)^2, {k, 1, nmax}], {x, 0, nmax}], x] // Rest

%t a[n_] := If[OddQ[n], Sum[GCD[n, k], {k, 1, n}], Sum[(-1)^(k + 1) GCD[n, k], {k, 1, n}]]; Table[a[n], {n, 1, 55}]

%t f[p_, e_] := (e*(p-1) + p)*p^(e-1); f[2, e_] := -e*2^(e-1); a[1] = 1; a[n_] := Times @@ f @@@ FactorInteger[n]; Array[a, 100] (* _Amiram Eldar_, Nov 04 2022 *)

%o (PARI) a(n) = sumdiv(n, d, (-1)^(d+1)*d*eulerphi(n/d)); \\ _Michel Marcus_, Feb 24 2020

%Y Cf. A000010, A018804, A078747, A143520, A181983, A193356, A199084, A344372, A368929.

%K sign,mult,easy

%O 1,3

%A _Ilya Gutkovskiy_, Feb 24 2020

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 24 18:17 EDT 2024. Contains 371962 sequences. (Running on oeis4.)