OFFSET
1,2
LINKS
Seiichi Manyama, Table of n, a(n) for n = 1..386
FORMULA
a(n) = Sum_{k=1..n} k^n * binomial(floor(n/k)+1,2).
a(n) = [x^n] (1/(1-x)) * Sum_{k>=1} k^n * x^k/(1 - x^k)^2.
a(n) ~ c * n^n, where c = 1/(1 - 1/exp(1)) = A185393. - Vaclav Kotesovec, Aug 07 2022
MATHEMATICA
a[n_] := Sum[k * DivisorSigma[n - 1, k], {k, 1, n}]; Array[a, 18] (* Amiram Eldar, Jul 28 2022 *)
PROG
(PARI) a(n) = sum(k=1, n, k*sigma(k, n-1));
(PARI) a(n) = sum(k=1, n, k^n*binomial(n\k+1, 2));
(Python)
from math import isqrt
from sympy import bernoulli
def A356129(n): return ((s:=isqrt(n))*(s+1)*(bernoulli(n+1)-bernoulli(n+1, s+1))+sum(k**n*(n+1)*(q:=n//k)*(q+1)+(k*(bernoulli(n+1, q+1)-bernoulli(n+1))<<1) for k in range(1, s+1)))//(n+1)>>1 # Chai Wah Wu, Oct 24 2023
CROSSREFS
KEYWORD
nonn
AUTHOR
Seiichi Manyama, Jul 27 2022
STATUS
approved