OFFSET
1,2
FORMULA
G.f.: Sum_{k>=1} 3^(k-1) * x^k/(1 - 3^(k-1) * x^k).
G.f.: Sum_{k>=1} x^k/(1 - (3 * x)^k).
MATHEMATICA
a[n_] := DivisorSum[n, 3^(n-#) &]; Array[a, 28] (* Amiram Eldar, Aug 23 2023 *)
PROG
(PARI) a(n) = sumdiv(n, d, 3^(n-d));
(PARI) my(N=30, x='x+O('x^N)); Vec(sum(k=1, N, 3^(k-1)*x^k/(1-3^(k-1)*x^k)))
(PARI) my(N=30, x='x+O('x^N)); Vec(sum(k=1, N, x^k/(1-(3*x)^k)))
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Seiichi Manyama, Dec 20 2022
STATUS
approved