OFFSET
1,2
LINKS
Amiram Eldar, Table of n, a(n) for n = 1..10000
FORMULA
G.f.: Sum_{k>=0} x^(2^k) * (1 + x^(2^k)) / (1 - x^(2^k))^3.
G.f.: (1/3) * Sum_{k>=1} J_2(2*k) * x^k / (1 - x^k), where J_2() is the Jordan function (A007434).
Dirichlet g.f.: zeta(s-2) / (1 - 2^(-s)).
a(2*n) = a(n) + 4*n^2, a(2*n+1) = (2*n + 1)^2.
a(n) = Sum_{d|n} A209229(n/d) * d^2.
Product_{n>=1} (1 + x^n)^a(n) = g.f. for A023871.
Sum_{k=1..n} a(k) ~ 8*n^3/21. - Vaclav Kotesovec, Oct 15 2019
Multiplicative with a(2^e) = (4^(e+1)-1)/3, and a(p^e) = p^(2*e) for an odd prime p. - Amiram Eldar, Oct 25 2020
MATHEMATICA
nmax = 55; CoefficientList[Series[Sum[x^(2^k) (1 + x^(2^k))/(1 - x^(2^k))^3, {k, 0, Floor[Log[2, nmax]] + 1}], {x, 0, nmax}], x] // Rest
a[n_] := If[EvenQ[n], a[n/2] + n^2, n^2]; Table[a[n], {n, 1, 55}]
Table[DivisorSum[n, Boole[IntegerQ[Log[2, n/#]]] #^2 &], {n, 1, 55}]
f[p_, e_] := If[p == 2, (4^(e + 1) - 1)/3, p^(2*e)]; a[1] = 1; a[n_] := Times @@ (f @@@ FactorInteger[n]); Array[a, 100] (* Amiram Eldar, Oct 25 2020 *)
PROG
(Magma) [n eq 1 select 1 else IsOdd(n) select n^2 else Self(n div 2)+n^2 :n in [1..55]]; // Marius A. Burtea, Oct 15 2019
CROSSREFS
KEYWORD
nonn,mult,easy
AUTHOR
Ilya Gutkovskiy, Oct 14 2019
STATUS
approved