OFFSET
1,4
COMMENTS
Difference between the sum of the odd nontrivial divisors of n and the sum of the even nontrivial divisors of n.
FORMULA
G.f.: Sum_{k>=2} (-1)^(k + 1) * k * x^(2*k) / (1 - x^k).
MATHEMATICA
Table[DivisorSum[n, (-1)^(# + 1) # &, 1 < # < n &], {n, 1, 76}]
nmax = 76; CoefficientList[Series[Sum[(-1)^(k + 1) k x^(2 k)/(1 - x^k), {k, 2, nmax}], {x, 0, nmax}], x] // Rest
PROG
(PARI) a(n) = sumdiv(n, d, if ((d>1) && (d<n), (-1)^(d + 1)*d)); \\ Michel Marcus, May 20 2020
CROSSREFS
KEYWORD
sign
AUTHOR
Ilya Gutkovskiy, May 19 2020
STATUS
approved