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-10 of 65 results. Next

A000567 Octagonal numbers: n*(3*n-2). Also called star numbers.

Original entry on oeis.org

0, 1, 8, 21, 40, 65, 96, 133, 176, 225, 280, 341, 408, 481, 560, 645, 736, 833, 936, 1045, 1160, 1281, 1408, 1541, 1680, 1825, 1976, 2133, 2296, 2465, 2640, 2821, 3008, 3201, 3400, 3605, 3816, 4033, 4256, 4485, 4720, 4961, 5208, 5461
Offset: 0

Views

Author

Keywords

Comments

From Floor van Lamoen, Jul 21 2001: (Start)
Write 1,2,3,4,... in a hexagonal spiral around 0; then a(n) is the sequence found by reading the line from 0 in the direction 0,1,....
The spiral begins:
.
85--84--83--82--81--80
/ \
86 56--55--54--53--52 79
/ / \ \
87 57 33--32--31--30 51 78
/ / / \ \ \
88 58 34 16--15--14 29 50 77
/ / / / \ \ \ \
89 59 35 17 5---4 13 28 49 76
/ / / / / \ \ \ \ \
90 60 36 18 6 0 3 12 27 48 75
/ / / / / / / / / / /
91 61 37 19 7 1---2 11 26 47 74
\ \ \ \ \ . / / / /
92 62 38 20 8---9--10 25 46 73
\ \ \ \ . / / /
93 63 39 21--22--23--24 45 72
\ \ \ . / /
94 64 40--41--42--43--44 71
\ \ . /
95 65--66--67--68--69--70
\ .
96
.
(End)
From Lekraj Beedassy, Oct 02 2003: (Start)
Also the number of distinct three-cell blocks that may be removed out of A000217(n+1) square cells arranged in a stepping triangular array of side (n+1). A 5-layer triangular array of square cells, for instance, has vertices outlined thus:
x x
x x x
x x x x
x x x x x
x x x x x x
x x x x x x (End)
First derivative at n of A045991. - Ross La Haye, Oct 23 2004
Starting from n=1, the sequence corresponds to the Wiener index of K_{n,n} (the complete bipartite graph wherein each independent set has n vertices). - Kailasam Viswanathan Iyer, Mar 11 2009
Number of divisors of 24^(n-1) for n > 0 (cf A009968). - J. Lowell, Aug 30 2008
a(n) = A001399(6n-5), number of partitions of 6*n - 5 into parts < 4. For example a(2)=8 and partitions of 6*2 - 5 = 7 into parts < 4 are: [1,1,1,1,1,1,1], [1,1,1,1,1,2],[1,1,1,1,3], [1,1,1,2,2], [1,1,2,3], [1,2,2,2], [1,3,3], [2,2,3]. - Adi Dani, Jun 07 2011
Also, sequence found by reading the line from 0 in the direction 0, 8, ..., and the parallel line from 1 in the direction 1, 21, ..., in the square spiral whose vertices are the generalized octagonal numbers A001082. - Omar E. Pol, Sep 10 2011
Partial sums give A002414. - Omar E. Pol, Jan 12 2013
Generate a Pythagorean triple using Euclid's formula with (n, n-1) to give A,B,C. a(n) = B + (A + C)/2. - J. M. Bergot, Jul 13 2013
The number of active (ON, black) cells in n-th stage of growth of two-dimensional cellular automaton defined by "Rule 773", based on the 5-celled von Neumann neighborhood. - Robert Price, May 23 2016
For n >= 1, the continued fraction expansion of sqrt(27*a(n)) is [9n-4; {1, 2n-2, 3, 2n-2, 1, 18n-8}]. For n=1, this collapses to [5; {5, 10}]. - Magus K. Chu, Oct 10 2022
a(n)*a(n+1) + 1 = (3n^2 + n - 1)^2. In general, a(n)*a(n+k) + k^2 = (3n^2 + (3k-2)n - k)^2. - Charlie Marion, May 23 2023

References

  • Albert H. Beiler, Recreations in the Theory of Numbers, Dover, NY, 1964, p. 189.
  • John H. Conway and Richard K. Guy, The Book of Numbers, New York: Springer-Verlag, 1996. See p. 38.
  • E. Deza and M. M. Deza, Figurate numbers, World Scientific Publishing (2012), page 6.
  • 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. 1.
  • 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).
  • James J. Tattersall, Elementary Number Theory in Nine Chapters, Cambridge University Press, 1999, pages 19-20.
  • David Wells, The Penguin Dictionary of Curious and Interesting Numbers. Penguin Books, NY, 1986, Revised edition 1987. See p. 123.

Crossrefs

Cf. A014641, A014642, A014793, A014794, A001835, A016777, A045944, A093563 ((6, 1) Pascal, column m=2). A016921 (differences).
Cf. A005408 (the odd numbers).

Programs

  • GAP
    List([0..50], n -> n*(3*n-2)); # G. C. Greubel, Nov 15 2018
    
  • Haskell
    a000567 n = n * (3 * n - 2)  -- Reinhard Zumkeller, Dec 20 2012
    
  • Magma
    [n*(3*n-2) : n in [0..50]]; // Wesley Ivan Hurt, Oct 10 2021
  • Maple
    A000567 := proc(n)
        n*(3*n-2) ;
    end proc:
    seq(A000567(n), n=1..50) ;
  • Mathematica
    Table[n (3 n - 2), {n, 0, 50}] (* Harvey P. Dale, May 06 2012 *)
    Table[PolygonalNumber[RegularPolygon[8], n], {n, 0, 43}] (* Arkadiusz Wesolowski, Aug 27 2016 *)
    PolygonalNumber[8, Range[0, 20]] (* Eric W. Weisstein, Sep 07 2017 *)
    LinearRecurrence[{3, -3, 1}, {1, 8, 21}, {0, 20}] (* Eric W. Weisstein, Sep 07 2017 *)
  • PARI
    a(n)=n*(3*n-2) \\ Charles R Greathouse IV, Jun 10 2011
    
  • PARI
    vector(50, n, n--; n*(3*n-2)) \\ G. C. Greubel, Nov 15 2018
    
  • Python
    # Intended to compute the initial segment of the sequence, not isolated terms.
    def aList():
         x, y = 1, 1
         yield 0
         while True:
             yield x
             x, y = x + y + 6, y + 6
    A000567 = aList()
    print([next(A000567) for i in range(49)]) # Peter Luschny, Aug 04 2019
    
  • Python
    [n*(3*n-2) for n in range(50)] # Gennady Eremin, Mar 10 2022
    
  • Sage
    [n*(3*n-2) for n in range(50)] # G. C. Greubel, Nov 15 2018
    

Formula

a(n) = n*(3*n-2).
a(n) = (3n-2)*(3n-1)*(3n)/((3n-1) + (3n-2) + (3n)), i.e., (the product of three consecutive numbers)/(their sum). a(1) = 1*2*3/(1+2+3), a(2) = 4*5*6/(4+5+6), etc. - Amarnath Murthy, Aug 29 2002
E.g.f.: exp(x)*(x+3*x^2). - Paul Barry, Jul 23 2003
G.f.: x*(1+5*x)/(1-x)^3. Simon Plouffe in his 1992 dissertation
a(n) = Sum_{k=1..n} (5*n - 4*k). - Paul Barry, Sep 06 2005
a(n) = n + 6*A000217(n-1). - Floor van Lamoen, Oct 14 2005
a(n) = C(n+1,2) + 5*C(n,2).
Starting (1, 8, 21, 40, 65, ...) = binomial transform of [1, 7, 6, 0, 0, 0, ...]. - Gary W. Adamson, Apr 30 2008
a(n) = 3*a(n-1) - 3*a(n-2) + a(n-3), a(0)=0, a(1)=1, a(2)=8. - Jaume Oliver Lafont, Dec 02 2008
a(n) = A000578(n) - A007531(n). - Reinhard Zumkeller, Sep 18 2009
a(n) = a(n-1) + 6*n - 5 (with a(0)=0). - Vincenzo Librandi, Nov 20 2010
a(n) = 2*a(n-1) - a(n-2) + 6. - Ant King, Sep 01 2011
a(n) = A000217(n) + 5*A000217(n-1). - Vincenzo Librandi, Nov 20 2010
a(n) = (A185212(n) - 1) / 4. - Reinhard Zumkeller, Dec 20 2012
a(n) = A174709(6n). - Philippe Deléham, Mar 26 2013
a(n) = (2*n-1)^2 - (n-1)^2. - Ivan N. Ianakiev, Apr 10 2013
a(6*a(n) + 16*n + 1) = a(6*a(n) + 16*n) + a(6*n + 1). - Vladimir Shevelev, Jan 24 2014
a(0) = 0, a(n) = Sum_{k=0..n-1} A005408(A051162(n-1,k)), n >= 1. - L. Edson Jeffery, Jul 28 2014
Sum_{n>=1} 1/a(n) = (sqrt(3)*Pi + 9*log(3))/12 = 1.2774090575596367311949534921... . - Vaclav Kotesovec, Apr 27 2016
From Ilya Gutkovskiy, Jul 29 2016: (Start)
Inverse binomial transform of A084857.
Sum_{n>=1} (-1)^(n+1)/a(n) = Pi/(2*sqrt(3)) = A093766. (End)
a(n) = n * A016777(n-1) = A053755(n) - A000290(n+1). - Bruce J. Nicholson, Aug 10 2017
Product_{n>=2} (1 - 1/a(n)) = 3/4. - Amiram Eldar, Jan 21 2021
P(4k+4,n) = ((k+1)*n - k)^2 - (k*n - k)^2 where P(m,n) is the n-th m-gonal number (a generalization of the Apr 10 2013 formula, a(n) = (2*n-1)^2 - (n-1)^2). - Charlie Marion, Oct 07 2021
From Leo Tavares, Oct 31 2021: (Start)
a(n) = A000290(n) + 4*A000217(n-1). See Square Rays illustration.
a(n) = A000290(n) + A046092(n-1)
a(n) = A000384(n) + 2*A000217(n-1). See Twin Rectangular Rays illustration.
a(n) = A000384(n) + A002378(n-1)
a(n) = A003154(n) - A045944(n-1). See Star Rows illustration. (End)

Extensions

Incorrect example removed by Joerg Arndt, Mar 11 2010

A011379 a(n) = n^2*(n+1).

Original entry on oeis.org

0, 2, 12, 36, 80, 150, 252, 392, 576, 810, 1100, 1452, 1872, 2366, 2940, 3600, 4352, 5202, 6156, 7220, 8400, 9702, 11132, 12696, 14400, 16250, 18252, 20412, 22736, 25230, 27900, 30752, 33792, 37026, 40460, 44100, 47952, 52022, 56316, 60840
Offset: 0

Views

Author

Glen Burch (gburch(AT)erols.com), Felice Russo

Keywords

Comments

(1) a(n) = sum of second string of n triangular numbers - sum of first n triangular numbers, or the 2n-th partial sum of triangular numbers (A000217) - the n-th partial sum of triangular numbers (A000217). The same for natural numbers gives squares. (2) a(n) = (n-th triangular number)*(the n-th even number) = n(n+1)/2 * (2n). - Amarnath Murthy, Nov 05 2002
Let M(n) be the n X n matrix m(i,j)=1/(i+j+x), let P(n,x) = (Product_{i=0..n-1} i!^2)/det(M(n)). Then P(n,x) is a polynomial with integer coefficients of degree n^2 and a(n) is the coefficient of x^(n^2-1). - Benoit Cloitre, Jan 15 2003
Y values of solutions of the equation: (X-Y)^3-X*Y=0. X values are a(n)=n*(n+1)^2 (see A045991) - Mohamed Bouhamida, May 09 2006
a(2d-1) is the number of self-avoiding walk of length 3 in the d-dimensional hypercubic lattice. - Michael Somos, Sep 06 2006
a(n) mod 10 is periodic 5: repeat [0, 2, 2, 6, 0]. - Mohamed Bouhamida, Sep 05 2009
This sequence is related to A005449 by a(n) = n*A005449(n)-sum(A005449(i), i=0..n-1), and this is the case d=3 in the identity n^2*(d*n+d-2)/2 - Sum_{k=0..n-1} k*(d*k+d-2)/2 = n*(n+d)*(2*d*n+d-3)/6. - Bruno Berselli, Nov 18 2010
Using (n, n+1) to generate a primitive Pythagorean triangle, the sides will be 2*n+1, 2*(n^2+n), and 2*n^2+2*n+1. Inscribing the largest rectangle with integral sides will have sides of length n and n^2+n. Side n is collinear to side 2*n+1 of the triangle and side n^2+n is collinear to side 2*(n^2+n) of the triangle. The areas of theses rectangles are a(n). - J. M. Bergot, Sep 22 2011
a(n+1) is the sum of n-th row of the triangle in A195437. - Reinhard Zumkeller, Nov 23 2011
Partial sums of A049450. - Omar E. Pol, Jan 12 2013
From Jon Perry, May 11 2013: (Start)
Define a 'stable brick triangle' as:
-----
| c |
---------
| a | | b |
----------
with a, b, c > 0 and c <= a + b. This can be visualized as two bricks with a third brick on top. The third brick can only be as strong as a+b, otherwise the wall collapses - for example, (1,2,4) is unstable.
a(n) gives the number of stable brick triangles that can be formed if the two supporting bricks are 1 <= a <= n and 1 <= b <= n: a(n) = Sum_{a=1..n} Sum_{b=1..n} Sum_c 1 = n^3 + n^2 as given in the Adamchuk formula.
So for i=j=n=2 we have 4:
1 2 3 4
2 2 2 2 2 2 2 2
For example, n=2 gives 2 from [a=1,b=1], 3 from both [a=1,b=2] and [a=2,b=1] and 4 from [a=2,b=2] so a(2) = 2 + 3 + 3 + 4 = 12. (End)
Define the infinite square array m(n,k) by m(n,k) = (n-k)^2 if n >= k >= 0 and by m(n,k) = (k+n)*(k-n) if 0 <= n <= k. This contains A120070 below the diagonal. Then a(n) = Sum_{k=0..n} m(n,k) + Sum_{r=0..n} m(r,n), the "hook sum" of the terms to the left of m(n,n) and above m(n,n) with irrelevant (vanishing) terms on the diagonal. - J. M. Bergot, Aug 16 2013
a(n) is the sum of all pairs with repetition drawn from the set of odd numbers 2*n-3. This is similar to A027480 but using the odd integers instead. Example using n=3 gives the odd numbers 1,3,5: 1+1, 1+3, 1+5, 3+3, 3+5,5+5 having a total of 36=a(3). - J. M. Bergot, Apr 05 2016
a(n) is the first Zagreb index of the complete graph K[n+1]. The first Zagreb index of a simple connected graph is the sum of the squared degrees of its vertices. Alternately, it is the sum of the degree sums d(i)+d(j) over all edges ij of the graph. - Emeric Deutsch, Nov 07 2016
a(n-2) is the maximum sigma irregularity over all trees with n vertices. The extremal graphs are stars. (The sigma irregularity of a graph is the sum of squares of the differences between the degrees over all edges of the graph.) - Allan Bickle, Jun 14 2023

Examples

			a(3) = 3^2+3^3 = 36.
		

References

  • L. B. W. Jolley, "Summation of Series", Dover Publications, 1961, pp. 50, 64.

Crossrefs

Cf. A011379, A181617, A270205 (sigma irregularities of maximal k-degenerate graphs).

Programs

Formula

a(n) = 2*A002411(n).
a(n) = Sum_{j=1..n} (Sum_{i=1..n} (i+j)), row sums of A126890 skipping numbers in the first column. - Alexander Adamchuk, Oct 12 2004
Sum_{n>0} 1/a(n) = (Pi^2 - 6)/6 = 0.6449340... [Jolley eq 272] - Gary W. Adamson, Dec 22 2006
a(n) = 2*n*binomial(n+1,2) = 2*n*A000217(n). - Arkadiusz Wesolowski, Feb 10 2012
G.f.: 2*x*(1 + 2*x)/(1 - x)^4. - Arkadiusz Wesolowski, Feb 11 2012
a(n) = A000330(n) + A002412(n) = A000292(n) + A002413(n). - Omar E. Pol, Jan 11 2013
a(n) = A245334(n+1,2), n > 0. - Reinhard Zumkeller, Aug 31 2014
Sum_{n>=1} 1/a(n) = A013661-1. - R. J. Mathar, Oct 18 2019 [corrected by Jason Yuen, Aug 04 2024]
Sum_{n>=1} (-1)^(n+1)/a(n) = 1 + Pi^2/12 - 2*log(2). - Amiram Eldar, Jul 04 2020
E.g.f.: exp(x)*x*(2 + 4*x + x^2). - Stefano Spezia, May 20 2021
a(n) = n*A002378(n) = A000578(n) + A000290(n). - J.S. Seneschal, Jun 18 2024

A006002 a(n) = n*(n+1)^2/2.

Original entry on oeis.org

0, 2, 9, 24, 50, 90, 147, 224, 324, 450, 605, 792, 1014, 1274, 1575, 1920, 2312, 2754, 3249, 3800, 4410, 5082, 5819, 6624, 7500, 8450, 9477, 10584, 11774, 13050, 14415, 15872, 17424, 19074, 20825, 22680, 24642, 26714, 28899, 31200, 33620, 36162, 38829, 41624
Offset: 0

Views

Author

Keywords

Comments

a(n) is the largest number that is not the sum of distinct numbers of form kn+1, k >= 0. - David W. Wilson, Dec 11 1999
Sum of the nontriangular numbers between successive triangular numbers. 1, (2), 3, (4, 5), 6, (7, 8, 9), 10, (11, 12, 13, 14), 15, ... Sum of the terms in brackets. Or sum of n consecutive integers beginning with T(n) + 1, where T(n) = n(n+1)/2. - Amarnath Murthy, Aug 27 2005
Apparently this is also the splittance (as defined by Hammer & Simeone, 1977) of the Kneser graphs of the form K(n+3,2). - Felix Goldberg (felixg(AT)tx.technion.ac.il), Jul 13 2009
Row sums of triangle A159797. - Omar E. Pol, Jul 24 2009
The same results occur when one plots the points (1,3), (3,6), (6,10), (10,15), and so on, for all the triangular numbers and finds the area beneath. Take three consecutive triangular numbers and label them a, b, c; the area created is simply (b-a)*(b+c)/2. Thus for 6,10,15 the area beneath the line defined by the points (6,10) and (10,15) is (10-6)*(10+15)/2 = 50. - J. M. Bergot, Jun 28 2011
Let P = ab where a and b are nonequal prime numbers > 1. Let Q be the product of all divisors of P^n. Q can be expressed as P^k, where k = n*(n+1)^2/2. This follows from the fact that all divisors are of the form a^i*b^j, for i,j from 0 to n. An example is given below. In the more general case, where P is the product of m nonequal prime numbers, k = n*(n+1)^m/2. When m=3, the sequence is the same as A092364. - James A. Raymond & Douglas Raymond, Dec 04 2011
For n > 0: sum of n-th row in A014132, seen as a triangle read by rows. - Reinhard Zumkeller, Dec 12 2012
Partial sums of A005449. - Omar E. Pol, Jan 12 2013
a(n) is the sum of x (or y) coordinates for an n X n square lattice in the upper right quadrant of Z^2 whose corner points are (0, 0), (0, n), (n, 0), and (n, n). - Joseph Wheat, Feb 03 2018
a(n) is the number of permutations of [n+2] that contain exactly 2 elements which are not left-to-right minimal. E.g., the 9 permutations comprising a(2) are 2134, 2143, 3124, 3142, 4123, 4132, 2314, 2413, 3412. - Andy Niedermaier, May 07 2022

Examples

			Let P^n=6^2. The product of the divisors of 36 = 10077796 = 6^9, i.e., for n=2, k=9. - _James A. Raymond_ & Douglas Raymond, Dec 04 2011
		

References

  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

Cf. A002411: -a(-1-n).
Cf. A000914 (partial sums), A005449 (first differences).
Cf. similar sequences of the type n*(n+1)*(n+k)/2 listed in A267370.
A bisection of A330298.

Programs

Formula

G.f.: x*(x + 2)/(1 - x)^4. - Michael Somos, Jan 30 2004
a(n) = (n + 1) * binomial(n+1, 2). - Zerinvary Lajos, Jan 10 2006
a(n) = A035006(n+1)/4. - Johannes W. Meijer, Feb 04 2010
a(n) = 2*binomial(n+1, 2) + 3*binomial(n+1, 3). - Gary Detlefs, Jun 06 2010
a(n) = 4*a(n-1) - 6*a(n-2) + 4*a(n-3) - a(n-4). - Harvey P. Dale, Aug 14 2012
a(n) = A000292(n) + A000330(n). - Omar E. Pol, Jan 11 2013
a(n) = A045991(n+1)/2. - J. M. Bergot, Aug 10 2013
a(n) = Sum_{j=1..n} Sum_{i=1..j} (2*j - i + 1). - Wesley Ivan Hurt, Nov 17 2014
a(n) = Sum_{i=0..n} n*(n - i) + i. - Bruno Berselli, Jan 13 2016
a(n) = t(n, A000217(n)), where t(h,k) = A000217(h) + h*k. - Bruno Berselli, Feb 28 2017
Sum_{n>0} 1/a(n) = 4 - Pi^2/3. - Jaume Oliver Lafont, Jul 11 2017 [corrected by Amiram Eldar, Jan 28 2022]
E.g.f.: exp(x)*x*(4 + 5*x + x^2)/2. - Stefano Spezia, May 21 2021
Sum_{n>=1} (-1)^(n+1)/a(n) = Pi^2/6 + 4*log(2) - 4. - Amiram Eldar, Jan 28 2022
From J.S. Seneschal, Jun 27 2024: (Start)
a(n) = (A002378(n)^2/2)/n = (n+1)/2 * A002378(n).
a(n) = A027480(n) - A000217(n). (End)

A049451 Twice second pentagonal numbers.

Original entry on oeis.org

0, 4, 14, 30, 52, 80, 114, 154, 200, 252, 310, 374, 444, 520, 602, 690, 784, 884, 990, 1102, 1220, 1344, 1474, 1610, 1752, 1900, 2054, 2214, 2380, 2552, 2730, 2914, 3104, 3300, 3502, 3710, 3924, 4144, 4370, 4602, 4840, 5084, 5334, 5590, 5852, 6120, 6394, 6674, 6960, 7252, 7550, 7854
Offset: 0

Views

Author

Joe Keane (jgk(AT)jgk.org)

Keywords

Comments

From Floor van Lamoen, Jul 21 2001: (Start)
Write 1,2,3,4,... in a hexagonal spiral around 0, then a(n) is the sequence found by reading the line from 0 in the direction 0,4,... . The spiral begins:
.
52
. \
33--32--31--30 51
/ . \ \
34 16--15--14 29 50
/ / . \ \ \
35 17 5---4 13 28 49
/ / / . \ \ \ \
36 18 6 0 3 12 27 48
/ / / / / / / /
37 19 7 1---2 11 26 47
\ \ \ / / /
38 20 8---9--10 25 46
\ \ / /
39 21--22--23--24 45
\ /
40--41--42--43--44
(End)
Number of edges in the join of the complete bipartite graph of order 2n and the cycle graph of order n, K_n,n * C_n. - Roberto E. Martinez II, Jan 07 2002
The average of the first n elements starting from a(1) is equal to (n+1)^2. - Mario Catalani (mario.catalani(AT)unito.it), Apr 10 2003
If Y is a 4-subset of an n-set X then, for n >= 4, a(n-4) is the number of (n-4)-subsets of X having either one element or two elements in common with Y. - Milan Janjic, Dec 28 2007
With offset 1: the maximum possible sum of numbers in an N x N standard Minesweeper grid. - Dmitry Kamenetsky, Dec 14 2008
a(n) = A001399(6*n-2), number of partitions of 6*n-2 into parts < 4. For example a(2)=14 where the partitions of 6*2-2=10 into parts < 4 are [1,1,1,1,1,1,1,1,1,1], [1,1,1,1,1,1,1,1,2], [1,1,1,1,1,1,1,3], [1,1,1,1,1,1,2,2], [1,1,1,1,1,2,3], [1,1,1,1,2,2,2], [1,1,1,1,3,3], [1,1,1,2,2,3], [1,1,2,2,2,2], [1,1,2,3,3], [1,2,2,2,3], [2,2,2,2,2], [1,3,3,3], [2,2,3,3]. - Adi Dani, Jun 07 2011
A003056 is the following array A read by antidiagonals:
0, 1, 2, 3, 4, 5, ...
1, 2, 3, 4, 5, 6, ...
2, 3, 4, 5, 6, 7, ...
3, 4, 5, 6, 7, 8, ...
4, 5, 6, 7, 8, 9, ...
5, 6, 7, 8, 9, 10, ...
and a(n) is the hook sum Sum_{k=0..n} A(n,k) + Sum_{r=0..n-1} A(r,n). - R. J. Mathar, Jun 30 2013
a(n)*Pi is the total length of 3 points circle center spiral after n rotations. The spiral length at each rotation (L(n)) is A016957. The spiral length ratio rounded down [floor(L(n)/L(1))] is A001651. See illustration in links. - Kival Ngaokrajang, Dec 27 2013
Partial sums give A114364. - Leo Tavares, Feb 25 2022
For n >= 1, the continued fraction expansion of sqrt(27*a(n)) is [9n+1; {2, 2n-1, 1, 4, 1, 2n-1, 2, 18n+2}]. - Magus K. Chu, Oct 13 2022

Examples

			From _Dmitry Kamenetsky_, Dec 14 2008, with slight rewording by Raymond Martineau (mart0258(AT)yahoo.com), Dec 16 2008: (Start)
For an N x N Minesweeper grid the highest sum of numbers is (N-1)(3*N-2). This is achieved by filling every second row with mines (shown as 'X'). For example, when N=5 the best grids are:
.
  X X X X X
  4 6 6 6 4
  X X X X X
  4 6 6 6 4
  X X X X X
.
  and
.
  2 3 3 3 2
  X X X X X
  4 6 6 6 4
  X X X X X
  2 3 3 3 2
.
each giving a total of 52. (End)
		

References

  • L. B. W. Jolley, Summation of Series, Dover Publications, 1961, p. 12.

Crossrefs

Similar sequences are listed in A316466.

Programs

Formula

a(n) = n*(3*n+1).
G.f.: 2*x*(2+x)/(1-x)^3.
Sum_{i=1..n} a(i) = A045991(n+1). - Gary W. Adamson, Dec 20 2006
a(n) = 2*A005449(n). - Omar E. Pol, Dec 18 2008
a(n) = a(n-1) + 6*n -2, n > 0. - Vincenzo Librandi, Aug 06 2010
a(n) = A100104(n+1) - A100104(n). - Reinhard Zumkeller, Jul 07 2012
a(n) = 3*a(n-1) - 3*a(n-2) + a(n-3) with a(0) = 0, a(1) = 4, a(2) = 14. - Philippe Deléham, Mar 26 2013
a(n) = A174709(6*n+3). - Philippe Deléham, Mar 26 2013
a(n) = (24/(n+2)!)*Sum_{j=0..n} (-1)^(n-j)*binomial(n,j)*j^(n+2). - Bruno Berselli, Jun 04 2013 - after the similar formula of Vladimir Kruchinin in A002411
a(n) = A002061(n+1) + A056220(n). - Bruce J. Nicholson, Sep 21 2017
a(n) = Sum_{i = 2..5} P(i,n), where P(i,m) = m*((i-2)*m-(i-4))/2. - Bruno Berselli, Jul 04 2018
E.g.f.: x*(4 + 3*x)*exp(x). - G. C. Greubel, Sep 01 2019
a(n) = A003215(n) - A005408(n). - Leo Tavares, Feb 25 2022
From Amiram Eldar, Feb 27 2022: (Start)
Sum_{n>=1} 1/a(n) = 3 - Pi/(2*sqrt(3)) - 3*log(3)/2.
Sum_{n>=1} (-1)^(n+1)/a(n) = Pi/sqrt(3) + 2*log(2) - 3. (End)
a(n) = A001105(n) + A002378(n). - Torlach Rush, Jul 11 2022

A015237 a(n) = (2*n - 1)*n^2.

Original entry on oeis.org

0, 1, 12, 45, 112, 225, 396, 637, 960, 1377, 1900, 2541, 3312, 4225, 5292, 6525, 7936, 9537, 11340, 13357, 15600, 18081, 20812, 23805, 27072, 30625, 34476, 38637, 43120, 47937, 53100, 58621, 64512
Offset: 0

Views

Author

Keywords

Comments

Structured hexagonal prism numbers. - James A. Record (james.record(AT)gmail.com), Nov 07 2004
Number of divisors of 60^(n-1) for n>0. - J. Lowell, Aug 30 2008
The sum of the 2*n+1 numbers between n*(n+1) and (n+1)*(n+2) gives a(n+1). - J. M. Bergot, Apr 17 2013
Partial sums of A080859. - J. M. Bergot, Jul 03 2013
a(n) = number of 2 X 2 matrices having all elements in {0..n} with determinant = permanent. - Indranil Ghosh, Dec 26 2016
Number of additions and multiplications needed to multiply two n X n matrices naively. - Charles R Greathouse IV, Jan 19 2018

Crossrefs

Cf. A100177 (structured prisms); A100145 (more on structured numbers).
Cf. A000578, A045991, A000384, A080859 (first diffs), A103220 (partial sums).
Cf. similar sequences, with the formula (k*n-k+2)*n^2/2, listed in A262000.

Programs

Formula

a(n) = A000578(n) + A045991(n). - Zerinvary Lajos, Jun 11 2008
a(n) = A199771(2*n-1) for n > 0. - Reinhard Zumkeller, Nov 23 2011
G.f.: x*(1+8*x+3*x^2)/(1-x)^4. - Colin Barker, Jun 08 2012
a(n) = 3*a(n-1) - 3*a(n-2) + a(n-3) + 12, a(0)=1, a(1)=1, a(2)=12. - G. C. Greubel, Jul 31 2015
E.g.f.: x*(2*x^2 + 5*x + 1)*exp(x). - G. C. Greubel, Jul 31 2015
a(n) = Sum_{i=0..n-1} n*(4*i+1) for n>0. - Bruno Berselli, Sep 08 2015
Sum_{n>=1} 1/a(n) = 4*log(2) - Pi^2/6. - Vaclav Kotesovec, Oct 04 2016
a(n) = Sum_{i=n^2-n+1..n^2+n-1} i. - Wesley Ivan Hurt, Dec 27 2016
From Peter Bala, Jan 30 2019: (Start)
Let a(n,x) = Product_{k = 0..n} (x - k)/(x + k). Then for positive integer x we have (2*x - 1)*x^2 = Sum_{n >= 0} ((n+1)^5 + n^5)*a(n,x) and (2*x - 1)*x = Sum_{n >= 0} ((n+1)^4 - n^4)*a(n,x). Both identities are also valid for complex x in the half-plane Re(x) > 2. See the Bala link in A036970. Cf. A272378. (End)
Sum_{n>=1} (-1)^(n+1)/a(n) = Pi - Pi^2/12 - 2*log(2). - Amiram Eldar, Jul 12 2020

A368515 Irregular triangular array T, read by rows: T(n,k) = number of sums |x-y|+|y-z| = k, where x,y,z are in {1,2,...,n} and x != y.

Original entry on oeis.org

2, 2, 4, 8, 4, 2, 6, 14, 14, 8, 4, 2, 8, 20, 24, 22, 12, 8, 4, 2, 10, 26, 34, 36, 30, 18, 12, 8, 4, 2, 12, 32, 44, 50, 48, 40, 24, 18, 12, 8, 4, 2, 14, 38, 54, 64, 66, 62, 50, 32, 24, 18, 12, 8, 4, 2, 16, 44, 64, 78, 84, 84, 76, 62, 40, 32, 24, 18, 12, 8, 4
Offset: 1

Views

Author

Clark Kimberling, Dec 31 2023

Keywords

Comments

Row n consists of 2n even positive integers.

Examples

			First six rows:
  2    2
  4    8   4     2
  6   14   14    8    4   2
  8   20   24   22   12   8     4    2
 10   26   34   36   30   18   12    8    4   2
 12   32   44   50   48   40   24   18   12   8   4   2
For n=2, there are 4 triples (x,y,z) having x != y:
  121:  |x-y| + |y-z| = 2
  122:  |x-y| + |y-z| = 1
  211:  |x-y| + |y-z| = 1
  212:  |x-y| + |y-z| = 2,
so that row 2 of the array is (2,2), representing two 1s and two 2s.
		

Crossrefs

Cf. A045991 (row sums), A007590 (limiting reverse row), A368434, A368437, A368516, A368517, A368518, A368519, A368520, A368521, A368522.

Programs

  • Mathematica
    t1[n_] := t1[n] = Tuples[Range[n], 3];
    t[n_] := t[n] = Select[t1[n], #[[1]] != #[[2]] &];
    a[n_, k_] :=   Select[t[n], Abs[#[[1]] - #[[2]]] + Abs[#[[2]] - #[[3]]] == k &];
    u = Table[Length[a[n, k]], {n, 2, 15}, {k, 1, 2 n - 2}];
    v = Flatten[u]; (* sequence *)
    Column[Table[Length[a[n, k]], {n, 2, 15}, {k, 1, 2 n - 2}]]  (* array *)

A028724 a(n) = (1/2)*floor(n/2)*floor((n-1)/2)*floor((n-2)/2).

Original entry on oeis.org

0, 0, 0, 0, 1, 2, 6, 9, 18, 24, 40, 50, 75, 90, 126, 147, 196, 224, 288, 324, 405, 450, 550, 605, 726, 792, 936, 1014, 1183, 1274, 1470, 1575, 1800, 1920, 2176, 2312, 2601, 2754, 3078, 3249, 3610, 3800, 4200, 4410, 4851, 5082, 5566, 5819, 6348, 6624, 7200
Offset: 0

Views

Author

Keywords

Comments

Number of symmetric Dyck paths of semilength n and having four peaks. E.g., a(5)=2 because we have UU*DU*DU*DU*DD and U*DUU*DU*DDU*D, where U=(1,1), D=(1,-1) and * indicates peaks. - Emeric Deutsch, Jan 12 2004
Starting with "1" = triangle A171608 * the triangular numbers. - Gary W. Adamson, Dec 12 2009
Integer solutions of (x + y)^3 = (x - y)^2. If x = a(2*n + 2) then y = -a(2*n + 1). y and x may be interchanged. - Thomas Scheuerle, Mar 22 2023
2*a(n+3) interleaves the positive integers of A011379 and A045991. - J.S. Seneschal, Mar 31 2025

Examples

			a(7) = 9 since the 9 tuples [x, y, z, w] in {[4, 3, 2, 2] [4, 3, 3, 2] [4, 3, 3, 3] [4, 3, 4, 2] [4, 3, 4, 3] [5, 2, 2, 2] [5, 2, 3, 2] [5, 2, 4, 2] [5, 2, 5, 2]} are all the solutions of 7 = x + y, x >= max(y, z), min(y, z) >= w >= 2.
		

References

  • P. A. MacMahon, Combinatory Analysis, Cambridge Univ. Press, London and New York, Vol. 1, 1915 and Vol. 2, 1916; see vol. 2, p 185, Article 433.

Crossrefs

Programs

  • Magma
    [((-1)^n*(3 -3*n +n^2) -(3 -11*n +9*n^2 -2*n^3))/32: n in [0..60]]; // G. C. Greubel, Apr 08 2022
    
  • Maple
    A028724:=n->(1/2)*floor(n/2)*floor((n-1)/2)*floor((n-2)/2);
    seq(A028724(k), k=0..100); # Wesley Ivan Hurt, Nov 01 2013
  • Mathematica
    Table[(1/2)*Floor[n/2]*Floor[(n-1)/2]*Floor[(n-2)/2], {n,0,100}] (* Wesley Ivan Hurt, Nov 01 2013 *)
    Table[(11n-3-9n^2+2n^3+(-1)^n(3-3n+n^2))/32,{n,0,60}] (* Benedict W. J. Irwin, Sep 27 2016 *)
    CoefficientList[Series[x^4 (1 + x + x^2)/(x - 1)^4/(x + 1)^3, {x, 0, 60}], x] (* Michael De Vlieger, Sep 27 2016 *)
  • PARI
    {a(n) = (n\2) * ((n-1)\2) * (n\2-1) / 2} /* Michael Somos, Jan 27 2008 */
    
  • PARI
    {a(n) = if( n<0, n=-1-n; -1, n-=4; 1) * polcoeff( (1 - x^3) / (1 - x)^2 / (1 - x^2)^3 + x*O(x^n), n)} /* Michael Somos, Jan 27 2008 */
    
  • PARI
    first(n) = Vec(x^4*(1+x+x^2)/(x-1)^4/(x+1)^3 + O(x^(n)), -n) \\ Iain Fox, Nov 18 2017
    
  • SageMath
    [(1/2)*(n//2)*((n-1)//2)*((n-2)//2) for n in (0..60)] # G. C. Greubel, Apr 08 2022

Formula

G.f.: x^4*(1+x+x^2)/((1-x)^4*(1+x)^3). - Ralf Stephan, Jun 22 2003
Number of tuples [x, y, z, w] of integers such that n = x + y, x >= max(y, z), min(y, z) >= w >= 2. - Michael Somos, Jan 27 2008
Euler transform of length 3 sequence [2, 3, -1]. - Michael Somos, Jan 27 2008
a(3-n) = -a(n). - Michael Somos, Jan 27 2008
a(n) = (-3 + 11*n - 9*n^2 + 2*n^3 + (-1)^n*(3 - 3*n + n^2))/32. - Benedict W. J. Irwin, Sep 27 2016
a(n) = Sum_{i=1..floor((n-1)/2)} i * ( floor((n-1)/2) mod (n-i-1) ). - Wesley Ivan Hurt, Nov 17 2017
E.g.f.: (1/32)*( (3 + 2*x + x^2)*exp(-x) - (1-x)*(3 - x + 2*x^2)*exp(x) ). - G. C. Greubel, Apr 08 2022
From Amiram Eldar, Apr 16 2023: (Start)
Sum_{n>=4} 1/a(n) = 2.
Sum_{n>=4} (-1)^n/a(n) = 2*Pi^2/3 - 6. (End)

A284823 Array read by antidiagonals: T(n,k) = number of primitive (aperiodic) palindromes of length n using a maximum of k different symbols (n >= 1, k >= 1).

Original entry on oeis.org

1, 2, 0, 3, 0, 0, 4, 0, 2, 0, 5, 0, 6, 2, 0, 6, 0, 12, 6, 6, 0, 7, 0, 20, 12, 24, 4, 0, 8, 0, 30, 20, 60, 18, 14, 0, 9, 0, 42, 30, 120, 48, 78, 12, 0, 10, 0, 56, 42, 210, 100, 252, 72, 28, 0, 11, 0, 72, 56, 336, 180, 620, 240, 234, 24, 0, 12, 0, 90, 72, 504, 294, 1290, 600, 1008, 216, 62
Offset: 1

Views

Author

Andrew Howroyd, Apr 03 2017

Keywords

Examples

			Table starts:
1  2   3    4    5    6     7     8     9    10 ...
0  0   0    0    0    0     0     0     0     0 ...
0  2   6   12   20   30    42    56    72    90 ...
0  2   6   12   20   30    42    56    72    90 ...
0  6  24   60  120  210   336   504   720   990 ...
0  4  18   48  100  180   294   448   648   900 ...
0 14  78  252  620 1290  2394  4088  6552  9990 ...
0 12  72  240  600 1260  2352  4032  6480  9900 ...
0 28 234 1008 3100 7740 16758 32704 58968 99900 ...
0 24 216  960 3000 7560 16464 32256 58320 99000 ...
...
Row 4 includes palindromes of the form abba but excludes those of the form aaaa, so T(4,k) is k*(k-1).
Row 6 includes palindromes of the forms aabbaa, abbbba, abccba but excludes those of the forms aaaaaa, abaaba, so T(6,k) is 2*k*(k-1) + k*(k-1)*(k-2).
		

References

  • M. R. Nester (1999). Mathematical investigations of some plant interaction designs. PhD Thesis. University of Queensland, Brisbane, Australia. [See A056391 for pdf file of Chap. 2]

Crossrefs

Columns 2-6 are A056458, A056459, A056460, A056461, A056462.
Rows 5-10 are A007531(k+1), A045991, A058895, A047928(k-1), A135497, A133754.

Programs

  • Mathematica
    T[n_, k_] := DivisorSum[n, MoebiusMu[n/#]*k^Ceiling[#/2]&]; Table[T[n-k+1, k], {n, 1, 12}, {k, n, 1, -1}] // Flatten (* Jean-François Alcover, Jun 05 2017 *)
  • PARI
    a(n,k) = sumdiv(n, d, moebius(n/d) * k^(ceil(d/2)));
    for(n=1, 10, for(k=1, 10, print1( a(n,k),", ");); print();)

Formula

T(n,k) = Sum_{d | n} mu(n/d) * k^(ceiling(d/2)).

A052149 Number of nonsquare rectangles on an n X n board.

Original entry on oeis.org

0, 4, 22, 70, 170, 350, 644, 1092, 1740, 2640, 3850, 5434, 7462, 10010, 13160, 17000, 21624, 27132, 33630, 41230, 50050, 60214, 71852, 85100, 100100, 117000, 135954, 157122, 180670, 206770, 235600, 267344, 302192, 340340, 381990, 427350, 476634
Offset: 1

Views

Author

Ronald Arms (ron.arms(AT)stanfordalumni.org), Jan 23 2000

Keywords

Comments

Partial sums of A045991 (n^3-n^2). - Jeremy Gardiner, Jun 30 2013

Examples

			a(10) = 10 * 9 * 11 * 32 / 12 = 2640.
a(5) = 170 and the sum from 1 to 5 is 15, giving 1*(15-1)=14, 2*(15-2)=26, 2*(15-3)=36, 4*(15-4)=44 and 5*(15-5)=50; adding 14+26+36+44+50=170. Do the same for each n and get a(n). - _J. M. Bergot_, Oct 31 2014
		

Crossrefs

Programs

  • Magma
    I:=[0, 4, 22, 70, 170]; [n le 5 select I[n] else 5*Self(n-1)-10*Self(n-2)+10*Self(n-3)-5*Self(n-4)+Self(n-5): n in [1..45]]; // Vincenzo Librandi, Apr 28 2012
    
  • Maple
    a:=n->sum(j^3-j^2, j=0..n): seq(a(n), n=1..37); # Zerinvary Lajos, May 08 2008
  • Mathematica
    CoefficientList[Series[2*x*(2+x)/(1-5*x+10*x^2-10*x^3+ 5*x^4-x^5), {x,0,50}], x] (* Vincenzo Librandi, Apr 28 2012 *)
    LinearRecurrence[{5,-10,10,-5,1},{0,4,22,70,170},40] (* Harvey P. Dale, Jul 30 2019 *)
  • PARI
    a(n) = sum(k=1,n,(k-1)*k^2) \\ Michel Marcus, Nov 09 2012

Formula

a(n) = n*(n-1)*(n+1)*(3*n+2)/12.
G.f.: 2*x^2*(2+x)/(1-5*x+10*x^2-10*x^3+5*x^4-x^5). - Colin Barker, Jan 04 2012
a(n) = 5*a(n-1) - 10*a(n-2) + 10*a(n-3) - 5*a(n-4) + a(n-5). - Vincenzo Librandi, Apr 28 2012
a(n) = A033487(n-1) - A007290(n+1) starting at n=1. - J. M. Bergot, Jun 04 2012
a(n) = Sum_{k=1..n} (k-1)*k^2. - Michel Marcus, Nov 09 2012
a(n) = A000537(n) - A000330(n) = 2*A000914(n-1). - Luciano Ancora, Mar 16 2015
From Amiram Eldar, Jan 10 2022: (Start)
Sum_{n>=2} 1/a(n) = 81*log(3)/5 - 9*sqrt(3)*Pi/5 - 192/25.
Sum_{n>=2} (-1)^n/a(n) = 18*sqrt(3)*Pi/5 - 48*log(2)/5 - 318/25. (End)

A135177 a(n) = p^2*(p-1), where p = prime(n).

Original entry on oeis.org

4, 18, 100, 294, 1210, 2028, 4624, 6498, 11638, 23548, 28830, 49284, 67240, 77658, 101614, 146068, 201898, 223260, 296274, 352870, 383688, 486798, 564898, 697048, 903264, 1020100, 1082118, 1213594, 1283148, 1430128, 2032254, 2230930
Offset: 1

Views

Author

Omar E. Pol, Nov 25 2007

Keywords

Examples

			a(4) = 294 because the 4th prime number is 7, 7^2 = 49, 7-1 = 6 and 49 * 6 = 294.
		

Crossrefs

Cf. A001248 (p^2), A030078 (p^3), A045991 (n^2 * (n-1)), A065414, A065483, A138416 (terms halved), A152441.
Column 4 of A379010.

Programs

Formula

a(n) = p^3 - p^2 = A030078(n) - A001248(n).
a(n) = A000010(prime(n)^3). - R. J. Mathar, Oct 15 2017
Sum_{n>=1} 1/a(n) = A152441. - Amiram Eldar, Nov 09 2020
From Amiram Eldar, Nov 22 2022: (Start)
Product_{n>=1} (1 + 1/a(n)) = A065483.
Product_{n>=1} (1 - 1/a(n)) = A065414. (End)
a(n) = 2*A138416(n). - Antti Karttunen, Dec 14 2024
Showing 1-10 of 65 results. Next