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.

Showing 1-2 of 2 results.

A366967 a(n) = Sum_{k=2..n} binomial(k,2) * floor(n/k).

Original entry on oeis.org

0, 1, 4, 11, 21, 40, 61, 96, 135, 191, 246, 337, 415, 528, 646, 801, 937, 1145, 1316, 1568, 1802, 2089, 2342, 2737, 3047, 3451, 3841, 4338, 4744, 5358, 5823, 6474, 7060, 7758, 8384, 9294, 9960, 10835, 11657, 12717, 13537, 14739, 15642, 16881, 18025, 19314, 20395
Offset: 1

Views

Author

Seiichi Manyama, Oct 30 2023

Keywords

Crossrefs

Partial sums of A069153.

Programs

  • PARI
    a(n) = sum(k=2, n, binomial(k, 2)*(n\k));
    
  • Python
    from math import isqrt
    def A366967(n): return ((s:=isqrt(n))**2*(1-s**2)+sum((q:=n//k)*(3*k*(k-1)+q**2-1) for k in range(1,s+1)))//6 # Chai Wah Wu, Oct 30 2023

Formula

G.f.: 1/(1-x) * Sum_{k>=1} x^(2*k)/(1-x^k)^3 = 1/(1-x) * Sum_{k>=2} binomial(k,2) * x^k/(1-x^k).
a(n) = (A064602(n)-A024916(n))/2. - Chai Wah Wu, Oct 30 2023

A356100 a(n) = Sum_{k=1..n} (k - 1)^n * floor(n/k).

Original entry on oeis.org

0, 1, 9, 99, 1301, 20581, 376891, 7914216, 186905206, 4915451602, 142368695176, 4506118905870, 154720069309364, 5729167232515112, 227585086051159866, 9654819212943764500, 435659280972794395356, 20836049921760968809231, 1052864549462731148832219
Offset: 1

Views

Author

Seiichi Manyama, Jul 26 2022

Keywords

Crossrefs

Programs

  • Mathematica
    Table[Sum[(k-1)^n Floor[n/k],{k,n}],{n,20}] (* Harvey P. Dale, Dec 14 2024 *)
  • PARI
    a(n) = sum(k=1, n, (k-1)^n*(n\k));
    
  • PARI
    a(n) = sum(k=1, n, sigma(k, n)-(n\k)^n);
    
  • PARI
    a(n) = sum(k=1, n, sumdiv(k, d, (d-1)^n));
    
  • Python
    def A356100(n): return sum((k-1)**n*(n//k) for k in range(2,n+1)) # Chai Wah Wu, Jul 26 2022

Formula

a(n) = A319194(n) - A332469(n).
a(n) = Sum_{k=1..n} Sum_{d|k} (d - 1)^n.
a(n) = [x^n] (1/(1-x)) * Sum_{k>=1} (k - 1)^n * x^k/(1 - x^k).
Showing 1-2 of 2 results.