OFFSET
1,2
LINKS
Winston de Greef, Table of n, a(n) for n = 1..10000
FORMULA
MATHEMATICA
f[2, e_] := 2^e; f[p_, e_] := If[Mod[p, 4] == 1, (p^(e + 1) - 1)/(p - 1), (p^(e + 1) + (-1)^e)/(p + 1)]; s[1] = 1; s[n_] := Times @@ f @@@ FactorInteger[n]; Accumulate @ Array[s, 50] (* Amiram Eldar, Dec 18 2021 *)
PROG
(PARI) a(n) = sum(k=1, n, sumdiv(k, d, kronecker(-4, k/d)*d));
(PARI) my(N=66, x='x+O('x^N)); Vec(sum(k=1, N, k*x^k/(1+x^(2*k)))/(1-x))
CROSSREFS
KEYWORD
nonn
AUTHOR
Seiichi Manyama, Dec 18 2021
STATUS
approved