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.
%I A355947 #67 Oct 25 2023 09:30:20 %S A355947 0,1,5,12,25,39,65,87,124,161,210,249,328,377,450,531,630,698,825,903, %T A355947 1047,1169,1295,1393,1609,1740,1893,2056,2269,2400,2679,2822,3070, %U A355947 3277,3486,3709,4082,4260,4498,4748,5136,5336,5744,5956,6312,6686,6984,7218,7772 %N A355947 a(n) = Sum_{k=1..n} (n+1-k)*floor(n/k). %C A355947 In the sum, the divisors are k = 1..n and the multipliers are the reverse n+1-k = n .. 1. %C A355947 From _Thomas Scheuerle_, Jul 21 2022: (Start) %C A355947 Without the floor operation a(n) would be A027457(n+1)/A099946(n+1) = (H(n+1) - 1)*(n^2+n), where H(n) is the n-th harmonic number. %C A355947 What is lim_{n->oo} ((A027457(n+1)/A099946(n+1) - a(n))/(n^2+n))? It appears to be close to 0.2452... . (End) %C A355947 This limit is equal to Pi^2/12 - gamma = 0.24525136852258... - _Vaclav Kotesovec_, Jul 23 2022 %H A355947 Seiichi Manyama, <a href="/A355947/b355947.txt">Table of n, a(n) for n = 0..10000</a> %F A355947 From _Vaclav Kotesovec_, Jul 23 2022: (Start) %F A355947 For n > 0, a(n) = (n+1)*A006218(n) - A024916(n). %F A355947 a(n) ~ n*(n+1)*(log(n) + 2*gamma - 1) - n^2*Pi^2/12, where gamma is the Euler-Mascheroni constant A001620. (End) %F A355947 (1/(1-x)^2) * Sum_{k>0} x^k * (k - (k-1)*x - x^k)/(1-x^k)^2. - _Seiichi Manyama_, Jul 24 2022 %e A355947 For n=5, the sum is formed: %e A355947 k = 1..n: 1 2 3 4 5 %e A355947 floor(n/k): 5 2 1 1 1 %e A355947 n+1-k = n..1: 5 4 3 2 1 %e A355947 floor(n/k)*(n+1-k): 25 8 3 2 1 %e A355947 __________________ %e A355947 a(5) = 25 + 8 + 3 + 2 + 1 = 39 %t A355947 a[n_] := Sum[(n+1-k) * Floor[n/k], {k, 1, n}]; Array[a, 50, 0] (* _Amiram Eldar_, Jul 22 2022 *) %o A355947 (PARI) a(n) = sum(k=1, n, (n+1-k)*floor(n/k)) \\ _Rémy Sigrist_, Jul 21 2022 %o A355947 (PARI) my(N=50, x='x+O('x^N)); concat(0, Vec(sum(k=1, N, x^k*(k-(k-1)*x-x^k)/(1-x^k)^2)/(1-x)^2)) \\ _Seiichi Manyama_, Jul 24 2022 %o A355947 (Python) %o A355947 from math import isqrt %o A355947 def A355947(n): return (s:=isqrt(n))**2*(s-(n<<1)-1)+sum((q:=n//k)*((n<<2)-(k<<1)-q+3) for k in range(1,s+1))>>1 # _Chai Wah Wu_, Oct 24 2023 %Y A355947 Cf. A006218, A024916, A027457, A099946, A143274. %K A355947 nonn,easy %O A355947 0,3 %A A355947 _Tamas Sandor Nagy_, Jul 21 2022 %E A355947 More terms from _Rémy Sigrist_, Jul 21 2022