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-4 of 4 results.

A143128 a(n) = Sum_{k=1..n} k*sigma(k).

Original entry on oeis.org

1, 7, 19, 47, 77, 149, 205, 325, 442, 622, 754, 1090, 1272, 1608, 1968, 2464, 2770, 3472, 3852, 4692, 5364, 6156, 6708, 8148, 8923, 10015, 11095, 12663, 13533, 15693, 16685, 18701, 20285, 22121, 23801, 27077, 28483, 30763, 32947, 36547
Offset: 1

Views

Author

Gary W. Adamson, Jul 26 2008

Keywords

Comments

Partial sums of A064987. - Omar E. Pol, Jul 04 2014
a(n) is also the volume after n-th step of the symmetric staircase described in A244580 (see also A237593). - Omar E. Pol, Jul 31 2018
In general, for j >= 1 and m >= 0, Sum_{k=1..n} k^m * sigma_j(k) ~ n^(j+m+1) * zeta(j+1) / (j+m+1). - Daniel Suteu, Nov 21 2018

Examples

			a(4) = 47 = (1 + 6 + 12 + 28) where A064987 = (1, 6, 12, 28, 30, ...).
a(4) = 47 = sum of row 4 terms of triangle A110662 = (15 + 14 + 11 + 7).
		

Crossrefs

Programs

  • Magma
    [(&+[k*DivisorSigma(1,k): k in [1..n]]): n in [1..50]]; // G. C. Greubel, Nov 21 2018
    
  • Maple
    with(numtheory): a:=proc(n) options operator, arrow: sum(k*sigma(k), k=1..n) end proc: seq(a(n),n=1..40); # Emeric Deutsch, Aug 12 2008
  • Mathematica
    Table[Sum[i*DivisorSigma[1, i], {i, n}], {n, 50}] (* Wesley Ivan Hurt, Jul 06 2014 *)
  • PARI
    a(n)=sum(k=1,n,k*sigma(k)) \\ Charles R Greathouse IV, Apr 27 2015
    
  • PARI
    f(n) = n*(n+1)*(2*n+1)/6; \\ A000330
    g(n) = n*(n+1)/2; \\ A000217
    a(n) = sum(k=1, sqrtint(n), k * f(n\k) + k^2 * g(n\k)) - f(sqrtint(n)) * g(sqrtint(n)); \\ Daniel Suteu, Nov 26 2020
    
  • Python
    def A143128(n): return sum(k**2*(m:=n//k)*(m+1)>>1 for k in range(1,n+1)) # Chai Wah Wu, Oct 20 2023
    
  • Python
    from math import isqrt
    def A143128(n): return ((-((s:=isqrt(n))*(s+1))**2*(2*s+1)>>1) + sum((q:=n//k)*(q+1)*k*(3*k+2*q+1) for k in range(1,s+1)))//6 # Chai Wah Wu, Oct 21 2023
  • Sage
    [sum(k*sigma(k,1) for k in (1..n)) for n in (1..50)] # G. C. Greubel, Nov 21 2018
    

Formula

Sum {k=1..n} k*sigma(k), where sigma(n) = A000203: (1, 3, 4, 7, 6, 12, ...) and n*sigma(n) = A064987: (1, 6, 12, 28, ...). Equals row sums of triangle A110662. - Emeric Deutsch, Aug 12 2008
a(n) ~ n^3 * Pi^2/18. - Charles R Greathouse IV, Jun 19 2012
G.f.: x*f'(x)/(1 - x), where f(x) = Sum_{k>=1} k*x^k/(1 - x^k). - Ilya Gutkovskiy, Apr 13 2017
a(n) = Sum_{k=1..n} k^2/2 * floor(n/k) * floor(1 + n/k). - Daniel Suteu, May 29 2018
a(n) = A256533(n) - A175254(n-1), n >= 2. - Omar E. Pol, Jul 31 2018
a(n) = Sum_{k=1..s} (k*A000330(floor(n/k)) + k^2*A000217(floor(n/k))) - A000330(s)*A000217(s), where s = floor(sqrt(n)). - Daniel Suteu, Nov 26 2020
a(n) = Sum_{k=1..n} Sum_{i=1..floor(n/k)} i*k^2. - Wesley Ivan Hurt, Nov 26 2020

Extensions

Corrected and extended by Emeric Deutsch, Aug 12 2008

A259179 Number of Dyck paths described in A237593 that contain the point (n,n) in the diagram of the symmetric representation of sigma.

Original entry on oeis.org

1, 2, 2, 0, 2, 1, 3, 0, 3, 0, 1, 2, 2, 0, 4, 0, 1, 3, 0, 2, 0, 2, 3, 0, 1, 4, 0, 2, 0, 3, 0, 3, 0, 1, 1, 4, 0, 2, 0, 4, 0, 3, 0, 1, 2, 0, 4, 0, 2, 0, 0, 5, 0, 3, 0, 1, 3, 0, 4, 0, 2, 0, 1, 0, 5, 0, 2, 1, 0, 1, 4, 0, 4, 0, 2, 0, 2, 0, 5, 0, 3, 0, 0, 0, 1, 5, 0, 2, 2, 0, 2, 0, 3, 0, 5, 0, 3, 0, 1, 0, 0, 6
Offset: 1

Views

Author

Omar E. Pol, Aug 11 2015

Keywords

Comments

Since the diagram of the symmetric representation of sigma is also the top view of the stepped pyramid described in A245092, and the diagram is also the top view of the staircase described in A244580, so we have that a(n) is also the height difference (or length of the vertical line segment) at the point (n,n) in the main diagonal of the mentioned structures.
a(n) is the number of occurrences of n in A240542. - Omar E. Pol, Dec 09 2016
Nonzero terms give A280919, the first differences of A071562. - Omar E. Pol, Apr 17 2018
Also first differences of A244367. Where records occur gives A279286. - Omar E. Pol, Apr 20 2020

Examples

			Illustration of initial terms:
--------------------------------------------------------
                           Diagram with 15 Dyck paths
n   A000203(n)  a(n)         to evaluate a(1)..a(10)
--------------------------------------------------------
.                         _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
1        1        1      |_| | | | | | | | | | | | | | |
2        3        2      |_ _|_| | | | | | | | | | | | |
3        4        2      |_ _|  _|_| | | | | | | | | | |
4        7        0      |_ _ _|    _|_| | | | | | | | |
5        6        2      |_ _ _|  _|  _ _|_| | | | | | |
6       12        1      |_ _ _ _|  _| |  _ _|_| | | | |
7        8        3      |_ _ _ _| |_ _|_|    _ _|_| | |
8       15        0      |_ _ _ _ _|  _|     |  _ _ _|_|
9       13        3      |_ _ _ _ _| |      _|_| |
10      18        0      |_ _ _ _ _ _|  _ _|    _|
.                        |_ _ _ _ _ _| |  _|  _|
.                        |_ _ _ _ _ _ _| |_ _|
.                        |_ _ _ _ _ _ _| |
.                        |_ _ _ _ _ _ _ _|
.                        |_ _ _ _ _ _ _ _|
.
For n = 3 there are two Dyck paths that contain the point (3,3) so a(3) = 2.
For n = 4 there are no Dyck paths that contain the point (4,4) so a(4) = 0.
		

Crossrefs

Programs

  • Mathematica
    a240542[n_] := Sum[(-1)^(k+1)Ceiling[(n+1)/k - (k+1)/2], {k, 1, Floor[(Sqrt[8n+1]-1)/2]}]
    a259179[n_] := Module[{t=Table[0, n], k=1, d=1}, While[d<=n, t[[d]]+=1; d=a240542[++k]]; t] (* a(1..n) *)
    a259179[102] (* Hartmut F. W. Hoft, Aug 06 2020 *)

Extensions

More terms from Omar E. Pol, Dec 09 2016

A256532 Product of n and the sum of remainders of n mod k, for k = 1, 2, 3, ..., n.

Original entry on oeis.org

0, 0, 3, 4, 20, 18, 56, 64, 108, 130, 242, 204, 364, 434, 540, 576, 867, 846, 1216, 1220, 1470, 1694, 2254, 2040, 2575, 2912, 3375, 3472, 4379, 4140, 5177, 5344, 6072, 6698, 7630, 7128, 8621, 9424, 10491, 10320, 12177, 11928, 13975, 14432, 15255, 16468, 18941, 17952, 20286, 21000, 22899, 23608, 26765, 26568, 29095
Offset: 1

Views

Author

Omar E. Pol, May 03 2015

Keywords

Comments

a(n) is also the volume (or the total number of unit cubes) of a polycube which is a right prism whose base is the symmetric representation of A004125(n).
Note that the union of this right prism and the irregular staircase after n-th stage described in A244580 and the irregular stepped pyramid after (n-1)-th stage described in A245092, form a hexahedron (or cube) of side length n. This comment is represented by the third formula.

Examples

			a(5) = 20 because 5 * (0 + 1 + 2 + 1) = 5 * 4 = 20.
a(6) = 18 because 6 * (0 + 0 + 0 + 2 + 1) = 6 * 3 = 18.
a(7) = 56 because 7 * (0 + 1 + 1 + 3 + 2 + 1) = 7 * 8 = 56.
		

Crossrefs

Programs

  • Mathematica
    Table[n*Sum[Mod[n,i],{i,2,n-1}],{n,55}] (* Ivan N. Ianakiev, May 04 2015 *)
  • PARI
    vector(50, n, n*sum(k=1, n, n % k)) \\ Michel Marcus, May 05 2015
    
  • Python
    def A256532(n):
        s=0
        for k in range(1,n+1):
            s+=n%k
        return s*n # Indranil Ghosh, Feb 13 2017
    
  • Python
    from math import isqrt
    def A256532(n): return n**3+n*((s:=isqrt(n))**2*(s+1)-sum((q:=n//k)*((k<<1)+q+1) for k in range(1,s+1))>>1) # Chai Wah Wu, Oct 22 2023

Formula

a(n) = n * A004125(n).
a(n) = n^3 - A256533(n).
a(n) = n^3 - A143128(n) - A175254(n-1), n > 1.

A332264 Partial sums of A334136.

Original entry on oeis.org

0, 3, 11, 32, 56, 116, 164, 269, 373, 535, 655, 963, 1131, 1443, 1779, 2244, 2532, 3195, 3555, 4353, 4993, 5749, 6277, 7657, 8401, 9451, 10491, 12003, 12843, 14931, 15891, 17844, 19380, 21162, 22794, 25979, 27347, 29567, 31695, 35205, 36885, 40821, 42669, 46281, 49713, 52953, 55161, 60989, 63725, 68282
Offset: 1

Views

Author

Omar E. Pol, Apr 19 2020

Keywords

Comments

a(n) is also the volume after n-th step of the symmetric staircase described in A244580 except the volume of the base level.

Examples

			For n = 4 the volume of the first four levels of the symmetric staircase described in A244580 is 47, since the structure contains 47 cubes. The volume of the base level is 15, since the base of the structure contains 15 cubes, so a(4) = 47 - 15 = 32.
		

Crossrefs

Programs

  • PARI
    a(n) = sum(k=1, n, (k-1)*sigma(k)); \\ Michel Marcus, Apr 19 2020
    
  • Python
    from math import isqrt
    def A332264(n): return (((s:=isqrt(n))**2*(s+1)*(6-(s+1)*((s<<1)+1))>>1)+sum((q:=n//k)*(k*(q+1)*(3*k+(q<<1)+1)-3*((k<<1)+q+1)) for k in range(1,s+1)))//6 # Chai Wah Wu, Oct 25 2023

Formula

a(n) = A143128(n) - A024916(n).
a(n) = A256533(n) - A175254(n). - Omar E. Pol, Apr 29 2020
Showing 1-4 of 4 results.