cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A350124 a(n) = Sum_{k=1..n} k^2 * floor(n/k)^3.

Original entry on oeis.org

1, 12, 40, 121, 207, 473, 649, 1142, 1611, 2401, 2853, 4647, 5285, 6879, 8759, 11452, 12558, 16739, 18127, 23353, 27129, 31171, 33219, 43573, 47524, 53210, 59538, 69996, 73274, 89694, 93446, 107195, 116731, 126545, 137505, 164580, 169946, 182244, 195644, 225454
Offset: 1

Views

Author

Seiichi Manyama, Dec 15 2021

Keywords

Crossrefs

Programs

  • Mathematica
    Accumulate[Table[DivisorSigma[2, k] - 3*k*DivisorSigma[1, k] + 3*k^2*DivisorSigma[0, k], {k, 1, 50}]] (* Vaclav Kotesovec, Dec 17 2021 *)
  • PARI
    a(n) = sum(k=1, n, k^2*(n\k)^3);
    
  • PARI
    a(n) = sum(k=1, n, k^2*sumdiv(k, d, (d^3-(d-1)^3)/d^2));
    
  • PARI
    my(N=66, x='x+O('x^N)); Vec(sum(k=1, N, (k^3-(k-1)^3)*x^k*(1+x^k)/(1-x^k)^3)/(1-x))
    
  • Python
    from math import isqrt
    def A350124(n): return (-(s:=isqrt(n))**4*(s+1)*(2*s+1) + sum((q:=n//k)*(k*(3*(k-1))+q*(k*(9*(k-1))+q*(k*(12*k-6)+2)+3)+1) for k in range(1,s+1)))//6 # Chai Wah Wu, Oct 21 2023

Formula

a(n) = Sum_{k=1..n} k^2 * Sum_{d|k} (d^3 - (d - 1)^3)/d^2.
G.f.: (1/(1 - x)) * Sum_{k>=1} (k^3 - (k - 1)^3) * x^k * (1 + x^k)/(1 - x^k)^3.
From Vaclav Kotesovec, Aug 03 2022: (Start)
a(n) = A064602(n) - 3*A143128(n) + 3*A319085(n).
a(n) ~ n^3 * (log(n) + 2*gamma + (zeta(3) - 1)/3 - Pi^2/6), where gamma is the Euler-Mascheroni constant A001620. (End)