OFFSET
1,2
LINKS
Seiichi Manyama, Table of n, a(n) for n = 1..386
FORMULA
a(n) = Sum_{k=1..n} Sum_{d|k} d^d.
G.f.: (1/(1-x)) * Sum_{k>0} (k * x)^k/(1 - x^k).
PROG
(PARI) a(n) = sum(k=1, n, n\k*k^k);
(PARI) a(n) = sum(k=1, n, sumdiv(k, d, d^d));
(PARI) my(N=20, x='x+O('x^N)); Vec(sum(k=1, N, (k*x)^k/(1-x^k))/(1-x))
(Python)
def A355887(n): return n*(1+n**(n-1))+sum(k**k*(n//k) for k in range(2, n)) if n>1 else 1 # Chai Wah Wu, Jul 21 2022
CROSSREFS
KEYWORD
nonn
AUTHOR
Seiichi Manyama, Jul 20 2022
STATUS
approved