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

A002412 Hexagonal pyramidal numbers, or greengrocer's numbers.

Original entry on oeis.org

0, 1, 7, 22, 50, 95, 161, 252, 372, 525, 715, 946, 1222, 1547, 1925, 2360, 2856, 3417, 4047, 4750, 5530, 6391, 7337, 8372, 9500, 10725, 12051, 13482, 15022, 16675, 18445, 20336, 22352, 24497, 26775, 29190, 31746, 34447, 37297, 40300
Offset: 0

Views

Author

Keywords

Comments

Binomial transform of (1, 6, 9, 4, 0, 0, 0, ...). - Gary W. Adamson, Oct 16 2007
a(n) is the sum of the maximum(m,n) over {(m,n): m,n in positive integers, m<=n}. - Geoffrey Critzer, Oct 11 2009
We obtain these numbers for d=2 in the identity n*(n*(d*n-d+2)/2)-sum(k*(d*k-d+2)/2, k=0..n-1) = n*(n+1)*(2*d*n-2*d+3)/6 (see Klaus Strassburger in Formula lines). - Bruno Berselli, Apr 21 2010, Nov 16 2010
q^a(n) is the Hankel transform of the q-Catalan numbers. - Paul Barry, Dec 15 2010
Row 1 of the convolution array A213835. - Clark Kimberling, Jul 04 2012
From Ant King, Oct 24 2012: (Start)
For n>0, the digital roots of this sequence A010888(A002412(n)) form the purely periodic 27-cycle {1,7,4,5,5,8,9,3,3,4,1,7,8,8,2,3,6,6,7,4,1,2,2,5,6,9,9}.
For n>0, the units' digits of this sequence A010879(A002412(n)) form the purely periodic 20-cycle {1,7,2,0,5,1,2,2,5,5,6,2,7,5,0,6,7,7,0,0}.
(End)
Partial sums of A000384. - Omar E. Pol, Jan 12 2013
Row sums of A094728. - J. M. Bergot, Jun 14 2013
Number of orbits of Aut(Z^7) as function of the infinity norm (n+1) of the representative integer lattice point of the orbit, when the cardinality of the orbit is equal to 40320. - Philippe A.J.G. Chevalier, Dec 28 2015
Coefficients in the hypergeometric series identity 1 - 7*(x - 1)/(3*x + 1) + 22*(x - 1)*(x - 2)/((3*x + 1)*(3*x + 2)) - 50*(x - 1)*(x - 2)*(x - 3)/((3*x + 1)*(3*x + 2)*(3*x + 3)) + ... = 0, valid for Re(x) > 1. Cf. A000326 and A002418. Column 3 of A103450. - Peter Bala, Mar 14 2019

Examples

			Let n=5, 2*n=10. Since 10 = 1 + 9 = 2 + 8 = 3 + 7 = 4 + 6 = 5 + 5, a(5) = 1*9 + 2*8 + 3*7 + 4*6 + 5*5 = 95. - _Vladimir Shevelev_, May 11 2012
		

References

  • A. H. Beiler, Recreations in the Theory of Numbers, Dover, NY, 1964, p. 194.
  • E. Deza and M. M. Deza, Figurate numbers, World Scientific Publishing (2012), page 93.
  • L. E. Dickson, History of the Theory of Numbers. Carnegie Institute Public. 256, Washington, DC, Vol. 1, 1919; Vol. 2, 1920; Vol. 3, 1923, see vol. 2, p. 2.
  • T. A. Gulliver, Sequences from Arrays of Integers, Int. Math. Journal, Vol. 1, No. 4, pp. 323-332, 2002.
  • I. Siap, Linear codes over F_2 + u*F_2 and their complete weight enumerators, in Codes and Designs (Ohio State, May 18, 2000), pp. 259-271. De Gruyter, 2002.
  • N. J. A. Sloane, A Handbook of Integer Sequences, Academic Press, 1973 (includes this sequence).
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

Bisection of A002623. Equals A000578(n) - A000330(n-1).
a(n) = A093561(n+2, 3), (4, 1)-Pascal column.
Cf. A220084 for a list of numbers of the form n*P(k,n)-(n-1)*P(k,n-1), where P(k,n) is the n-th k-gonal pyramidal number (see Adamson's formula).
Cf. similar sequences listed in A237616.
Orbits of Aut(Z^7) as function of the infinity norm A000579, A154286, A102860, A002412, A045943, A115067, A008585, A005843, A001477, A000217.

Programs

  • GAP
    List([0..40],n->n*(n+1)*(4*n-1)/6); # Muniru A Asiru, Mar 18 2019
    
  • Magma
    [n*(n+1)*(4*n-1)/6: n in [0..40]]; // Vincenzo Librandi, Nov 28 2015
    
  • Maple
    seq(sum(i*(2*k-i), i=1..k), k=0..100); # Wesley Ivan Hurt, Sep 25 2013
  • Mathematica
    Figurate[ ngon_, rank_, dim_] := Binomial[rank + dim - 2, dim - 1] ((rank - 1)*(ngon - 2) + dim)/dim; Table[ Figurate[6, r, 3], {r, 0, 40}] (* Robert G. Wilson v, Aug 22 2010 *)
    Table[n(n+1)(4n-1)/6, {n,0,40}] (* or *) LinearRecurrence[{4,-6,4,-1}, {0,1,7,22}, 40] (* Harvey P. Dale, Jul 16 2011 *)
  • Maxima
    A002412(n):=n*(n+1)*(4*n-1)/6$ makelist(A002412(n),n,0,20); /* Martin Ettl, Dec 12 2012 */
    
  • PARI
    v=vector(40,i,(i*(i+1))\2); s=0; print1(s","); forstep(i=1,40,2,s+=v[i]; print1(s","))
    
  • Python
    print([n*(n+1)*(4*n-1)//6 for n in range(40)]) # Michael S. Branicky, Mar 28 2022

Formula

a(n) = n(n + 1)(4n - 1)/6.
G.f.: x*(1+3*x)/(1-x)^4. - Simon Plouffe in his 1992 dissertation.
a(n) = n^3 - Sum_{i=1..n-1} i^2. - Klaus Strassburger (strass(AT)ddfi.uni-duesseldorf.de)
Partial sums of n odd-indexed triangular numbers, e.g., a(3) = t(1)+t(3)+t(5) = 1+6+15 = 22. - Jon Perry, Jul 23 2003
a(n) = Sum_{i=0..n-1} (n - i)*(n + i). - Jon Perry, Sep 26 2004
a(n) = n*A000292(n) - (n-1)*A000292(n-1) = n*binomial((n+2),3) - (n-1)*binomial((n+1),3); e.g., a(5) = 95 = 5*35 - 4*20. - Gary W. Adamson, Dec 28 2007
a(n) = Sum_{i=0..n} (2i^2 + 3i + 1), for n >= 0 (Omits the leading 0). - William A. Tedeschi, Aug 25 2010
a(n) = 4*a(n-1)-6*a(n-2)+4*a(n-3)-a(n-4), with a(0)=0, a(1)=1, a(2)=7, a(3)=22. - Harvey P. Dale, Jul 16 2011
a(n) = sum a*b, where the summing is over all unordered partitions 2*n = a+b. - Vladimir Shevelev, May 11 2012
From Ant King, Oct 24 2012: (Start)
a(n) = a(n-1) + n*(2*n-1).
a(n) = 3*a(n-1) - 3*a(n-2) + a(n-3) + 4.
a(n) = (n+1)*(2*A000384(n) + n)/6 = (4*n-1)*A000217(n)/3.
a(n) = A000292(n) + 3*A000292(n-1) = A002411(n) + A000292(n-1).
a(n) = binomial(n+2,3) + 3*binomial(n+1,3) = (4*n-1)*binomial(n+1,2)/3.
Sum_{n>=1} 1/a(n) = 6*(12*log(2)-2*Pi-1)/5 = 1.2414...
(End)
a(n) = Sum_{i=1..n} Sum_{j=1..n} max(i,j) = Sum_{i=1..n} i*(2*n-i). - Enrique Pérez Herrero, Jan 15 2013
a(n) = A005900(n+1) - A000326(n+1) = Octahedral - Pentagonal Numbers. - Richard R. Forberg, Aug 07 2013
a(n) = n*A000217(n) + Sum_{i=0..n-1} A000217(i). - Bruno Berselli, Dec 18 2013
a(n) = 2n * A000217(n) - A000330(n). - J. M. Bergot, Apr 05 2014
a(n) = A080851(4,n-1). - R. J. Mathar, Jul 28 2016
E.g.f.: x*(6 + 15*x + 4*x^2)*exp(x)/6. - Ilya Gutkovskiy, May 12 2017
Sum_{n>=1} (-1)^(n+1)/a(n) = 6*(1 + 2*sqrt(2)*Pi - 2*(3+sqrt(2))*log(2) + 4*sqrt(2)*log(2-sqrt(2)))/5. - Amiram Eldar, Jan 04 2022

A051662 House numbers: a(n) = (n+1)^3 + Sum_{i=1..n} i^2.

Original entry on oeis.org

1, 9, 32, 78, 155, 271, 434, 652, 933, 1285, 1716, 2234, 2847, 3563, 4390, 5336, 6409, 7617, 8968, 10470, 12131, 13959, 15962, 18148, 20525, 23101, 25884, 28882, 32103, 35555, 39246, 43184, 47377, 51833, 56560, 61566, 66859, 72447, 78338, 84540, 91061, 97909
Offset: 0

Views

Author

Klaus Strassburger (strass(AT)ddfi.uni-duesseldorf.de)

Keywords

Comments

Binomial transform of [1, 8, 15, 8, 0, 0, 0, ...]. - Gary W. Adamson, Nov 23 2007
Principal diagonal of the convolution array A213751. - Clark Kimberling, Jun 20 2012

Crossrefs

Cf. A000330, A220084 (for a list of numbers of the form n*P(k,n) - (n-1)*P(k,n-1), where P(k,n) is the n-th k-gonal pyramidal number).

Programs

  • Haskell
    - following Gary W. Adamson's comment.
    a051662 = sum . zipWith (*) [1, 8, 15, 8] . a007318_row
    -- Reinhard Zumkeller, Feb 19 2015
  • Maple
    a:=n->sum(k^2, k=1..n):seq(a(n)+sum(n^2, k=2..n), n=1...40); # Zerinvary Lajos, Jun 11 2008
  • Mathematica
    Table[(n+1)^3+Sum[i^2,{i,n}],{n,0,40}] (* or *) LinearRecurrence[ {4,-6,4,-1}, {1,9,32,78},40] (* Harvey P. Dale, Jun 23 2011 *)
  • Maxima
    A051662(n):=((8*n+21)*n+19)*n/6+1$ makelist(A051662(n),n,0,15); /* Martin Ettl, Dec 13 2012 */
    
  • PARI
    a(n)=((8*n+21)*n+19)*n/6+1 \\ Charles R Greathouse IV, Jun 23 2011
    

Formula

a(n) = (n+1)*(8*n^2 + 13*n + 6)/6.
a(n) = A000578(n+1) + A000330(n).
From Harvey P. Dale, Jun 23 2011: (Start)
a(n) = 4*a(n-1) - 6*a(n-2) + 4*a(n-3) - a(n-4), a(0)=1, a(1)=9, a(2)=32, a(3)=78.
G.f.: (1+5*x+2*x^2)/(x-1)^4. (End)
a(n) = (n+1)*A000330(n+1) - n*A000330(n). - Bruno Berselli, Dec 11 2012
a(n) = A023855(2*n) + A023855(2*n+1). - Luc Rousseau, Feb 24 2018
E.g.f.: exp(x)*(6 + 48*x + 45*x^2 + 8*x^3)/6. - Elmo R. Oliveira, Aug 06 2025

Extensions

Corrected by T. D. Noe, Nov 01 2006 and Nov 08 2006

A130748 Place n points on each of the three sides of a triangle, 3n points in all; a(n) = number of nondegenerate triangles that can be constructed using these points (plus the 3 original vertices) as vertices.

Original entry on oeis.org

17, 72, 190, 395, 711, 1162, 1772, 2565, 3565, 4796, 6282, 8047, 10115, 12510, 15256, 18377, 21897, 25840, 30230, 35091, 40447, 46322, 52740, 59725, 67301, 75492, 84322, 93815, 103995, 114886, 126512, 138897, 152065, 166040, 180846, 196507, 213047, 230490
Offset: 1

Views

Author

Denis Borris, Jul 12 2007

Keywords

Comments

Define b(1)=1 and b(n) = a(n-1) for n>1. Then (b(n)) is the principal diagonal of the convolution array A213833. - Clark Kimberling, Jul 04 2012

Examples

			5 points are put on each side of a triangle (n = 5); we then have 18 vertices to construct with: 5 * 3 + 3 originals. The number of total arrangements = combi(18,3) : combi[3(n+1),3]. But these include degenerates along the 3 sides: 7 points on each side, so combi(7,3) on each side : 3 * combi[n+2, 3] combi[18,3] - 3 * combi[7,3] = 816 - 105 = 711.
		

Crossrefs

Cf. A002414, A213833, A220084 (for a list of numbers of the form n*P(k,n)-(n-1)*P(k,n-1), where P(k,n) is the n-th k-gonal pyramidal number).
Cf. A260260 (comment). [Bruno Berselli, Jul 22 2015]

Programs

Formula

a(n) = C(3*(n+1),3) - 3*C(n+2,3) where n>0.
a(n) = (n+1)*A002414(n+1) - n*A002414(n). - Bruno Berselli, Dec 11 2012
a(n) = (8*n^3 + 15*n^2 + 9*n + 2)/2. - Charles R Greathouse IV, Feb 14 2013
From Elmo R. Oliveira, Aug 25 2025: (Start)
G.f.: x*(17 + 4*x + 4*x^2 - x^3)/(x-1)^4.
E.g.f.: -1 + exp(x)*(2 + 32*x + 39*x^2 + 8*x^3)/2.
a(n) = 4*a(n-1) - 6*a(n-2) + 4*a(n-3) - a(n-4) for n > 4. (End)

Extensions

More terms from Wesley Ivan Hurt, Jan 28 2014

A213772 Principal diagonal of the convolution array A213771.

Original entry on oeis.org

1, 11, 42, 106, 215, 381, 616, 932, 1341, 1855, 2486, 3246, 4147, 5201, 6420, 7816, 9401, 11187, 13186, 15410, 17871, 20581, 23552, 26796, 30325, 34151, 38286, 42742, 47531, 52665, 58156, 64016, 70257, 76891, 83930, 91386, 99271, 107597, 116376, 125620, 135341
Offset: 1

Views

Author

Clark Kimberling, Jul 04 2012

Keywords

Comments

Zhu Shijie gives in his Magnus Opus "Jade Mirror of the Four Unknowns" the problem: "The total number of apples in a pile in the form of a cone is 932, and the number of layers is an odd number." Zhu Shijie assumed the rational sequence s(k) = (k*(k+1)*(2*k+1)+k+1)/8 for the total number of apples in k layers, with n = (k+1)/2 is the solution 932 = a((15+1)/2) with k = 15. Zhu Shijie gave the solution polynomial: "Let the element tian be the number of layers. From the statement we have 7455 for the negative shi, 2 for the positive fang, 3 for the positive first lian, and 2 for the positive yu." This translates into the polynomial equation: 2*x^3 + 3*x^2 + 2*x - 7455 = 0. - Thomas Scheuerle, Feb 10 2025

References

  • Zhu Shijie, Jade Mirror of the Four Unknowns (Siyuan yujian), Book III Guo Duo Die Gang (Piles of Fruit), Problem number 7, (1303).

Crossrefs

Cf. A000326, A002411, A085473, A213771, A220084 (for a list of numbers of the form n*P(k,n) - (n-1)*P(k,n-1), where P(k,n) is the n-th k-gonal pyramidal number).
Cf. A260260 (comment). [Bruno Berselli, Jul 22 2015]

Programs

  • Mathematica
    (See A213771.)
    LinearRecurrence[{4,-6,4,-1},{1,11,42,106},70] (* Harvey P. Dale, Mar 29 2025 *)
  • PARI
    a(n) = (4*n^3-3*n^2+n)/2; \\ Altug Alkan, Dec 16 2017

Formula

a(n) = 4*a(n-1) - 6*a(n-2) + 4*a(n-3) - a(n-4).
G.f.: x*(1 + 7*x + 4*x^2)/(1 - x)^4.
a(n) = (4*n^2 - 3*n + 1)*n/2 = n*A002411(n) - (n-1)*A002411(n-1). - Bruno Berselli, Dec 11 2012
a(n) = n*A000326(n) + Sum_{i=0..n-1} A000326(i). - Bruno Berselli, Dec 18 2013
a(n) - a(n-1) = A085473(n-1). - R. J. Mathar, Mar 02 2025
E.g.f.: exp(x)*x*(1 + 4*x)*(2 + x)/2. - Elmo R. Oliveira, Aug 08 2025

A261720 Array of pyramidal (3-dimensional figurate numbers) read by antidiagonals.

Original entry on oeis.org

1, 1, 4, 1, 5, 10, 1, 6, 14, 20, 1, 7, 18, 30, 35, 1, 8, 22, 40, 55, 56, 1, 9, 26, 50, 75, 91, 84, 1, 10, 30, 60, 95, 126, 140, 120, 1, 11, 34, 70, 115, 161, 196, 204, 165, 1, 12, 38, 80, 135, 196, 252, 288, 285, 220, 1, 13, 42, 90, 155, 231, 308, 372, 405, 385, 286
Offset: 1

Views

Author

Gary W. Adamson, Aug 29 2015

Keywords

Comments

First few sequences in the array:
1, 4, 10, 20, 35, 56, 84, 120, 165, 220, ... A000292
1, 5, 14, 30, 55, 91, 140, 204, 285, 385, ... A000330
1, 6, 18, 40, 75, 126, 196, 288, 405, 550, ... A002411
1, 7, 22, 50, 95, 161, 252, 372, 525, 715, ... A002412
1, 8, 26, 60, 115, 196, 308, 456, 645, 880, ... A002413
1, 9, 30, 70, 135, 231, 364, 540, 765, 1045, ... A002414
1, 10, 34, 80, 155, 266, 420, 624, 885, 1210, ... A007584
...
The corresponding bases to rows are: Triangle, Square, Pentagon, Hexagon, Heptagon, Octagon, ...

Examples

			Row 2: (1, 5, 14, 30, 55, ...) = (1, 4, 10, 20, 35, ...) + (0, 1, 4, 10, 20, 35, ...).
(1, 7, 22, 50, ...) is the binomial transform of (1, 6, 9, 4, 0, 0, 0, ...) 3rd row in Pascal's triangle (1,4) followed by zeros. (1, 7, 22, 50, ...) is the third partial sum of (1, 4, 4, 4, ...).
		

References

  • Albert H. Beiler, "Recreations in the Theory of Numbers"; Dover, 1966, p. 194.

Crossrefs

Similar to A080851 but without row n=0.

Programs

  • Mathematica
    T[n_,k_]:=k(k+1)((k-1)n+3)/6; Flatten[Table[T[n-k+1,k],{n,11},{k,n}]] (* Stefano Spezia, Aug 15 2024 *)

Formula

T(n,k) = A080851(n,k).
Given: first sequence in the array is A000292: (1, 4, 10, 20, 35, ...) Subsequent rows are generated by adding (0, 1, 4, 10, 20, 35, ...) to the current row.
n-th row is the binomial transform of row 3 in Pascal's triangle (1,n) followed by zeros. Alternatively, begin with (1, 4, 10, 20, ...) being the binomial transform of (1, 3, 3, 1, 0, 0, 0, ...). Add (0, 1, 2, 1, 0, 0, 0, ...) to the latter to obtain the inverse binomial transform of the next row: (1, 5, 14, 30, 55,..); then repeat the operation.
The row starting (1, N, ...) is the 3rd partial sum of (1, (N-3), (N-3), (N-3), ...).
From Stefano Spezia, Aug 15 2024: (Start)
T(n,k) = k*(k + 1)*((k - 1)*n + 3)/6.
G.f. as array: x*y*(1 + x*(y - 1))/((1 - x)^2*(1 - y)^4).
E.g.f. as array: exp(y)*y*(exp(x)*(6 + 3*(1 + x)*y + x*y^2) - 3*(2 + y))/6. (End)

A213837 Principal diagonal of the convolution array A213836.

Original entry on oeis.org

1, 13, 52, 134, 275, 491, 798, 1212, 1749, 2425, 3256, 4258, 5447, 6839, 8450, 10296, 12393, 14757, 17404, 20350, 23611, 27203, 31142, 35444, 40125, 45201, 50688, 56602, 62959, 69775, 77066, 84848, 93137
Offset: 1

Views

Author

Clark Kimberling, Jul 04 2012

Keywords

Crossrefs

Cf. A000384, A002412, A213836, A220084 (for a list of numbers of the form n*P(k,n)-(n-1)*P(k,n-1), where P(k,n) is the n-th k-gonal pyramidal number).

Programs

  • Mathematica
    (See A213836.)
    LinearRecurrence[{4,-6,4,-1},{1,13,52,134},40] (* Harvey P. Dale, Aug 07 2025 *)

Formula

a(n) = n*(5 - 15*n + 16*n^2)/6.
a(n) = 4*a(n-1) - 6*a(n-2) + 4*a(n-3) - a(n-4).
G.f.: f(x)/g(x), where f(x) = x*(1 + 9*x + 6*x^2) and g(x) = (1-x)^4.
a(n) = n*A002412(n) - (n-1)*A002412(n-1). [Bruno Berselli, Dec 11 2012]
a(n) = n*A000384(n) + sum( A000384(i), i=0..n-1 ). [Bruno Berselli, Dec 18 2013]
Showing 1-6 of 6 results.