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

A001400 Number of partitions of n into at most 4 parts.

Original entry on oeis.org

1, 1, 2, 3, 5, 6, 9, 11, 15, 18, 23, 27, 34, 39, 47, 54, 64, 72, 84, 94, 108, 120, 136, 150, 169, 185, 206, 225, 249, 270, 297, 321, 351, 378, 411, 441, 478, 511, 551, 588, 632, 672, 720, 764, 816, 864, 920, 972, 1033, 1089, 1154, 1215, 1285, 1350, 1425, 1495
Offset: 0

Views

Author

Keywords

Comments

Molien series for 4-dimensional representation of S_4 [Nebe, Rains, Sloane, Chap. 7].
Also number of pure 2-complexes on 4 nodes with n multiple 2-simplexes. - Vladeta Jovovic, Dec 27 1999
Also number of different integer triangles with perimeter <= n+3. Also number of different scalene integer triangles with perimeter <= n+9. - Reinhard Zumkeller, May 12 2002
a(n) is the coefficient of q^n in the expansion of (m choose 4)_q as m goes to infinity. - Y. Kelly Itakura (yitkr(AT)mta.ca), Aug 21 2002
Also number of partitions of n into parts <= 4. a(n) = A026820(n,4), for n > 3. - Reinhard Zumkeller, Jan 21 2010
Number of different distributions of n+10 identical balls in 4 boxes as x,y,z,p where 0 < x < y < z < p. - Ece Uslu and Esin Becenen, Jan 11 2016
Number of partitions of 5n+8 or 5n+12 into 4 parts (+-) 3 mod 5. a(4) = 5 partitions of 28: [7,7,7,7], [12,7,7,2], [12,12,2,2], [17,7,2,2], [22,2,2,2]. a(3) = 3 partitions of 27: [8,8,8,3], [13,8,3,3], [18,3,3,3]. - Richard Turk, Feb 24 2016
a(n) is the total number of non-isomorphic geodetic graphs of diameter n homeomorphic to a complete graph K4. - Carlos Enrique Frasser, May 24 2018

Examples

			(4 choose 4)_q = 1, (5 choose 4)_q = q^4 + q^3 + q^2 + q + 1, (6 choose 4)_q = q^8 + q^7 + 2*q^6 + 2*q^5 + 3*q^4 + 2*q^3 + 2*q^2 + q + 1, (7 choose 4) = q^12 + q^11 + 2*q^10 + 3*q^9 + 4*q^8 + 4*q^7 + 5*q^6 + 4*q^5 + 4*q^4 + 3*q^3 + 2*q^2 + q + 1 so the coefficient of q^0 converges to 1, q^1 to 1, q^2 to 2 and so on.
G.f. = 1 + x + 2*x^2 + 3*x^3 + 5*x^4 + 6*x^5 + 9*x^6 + 11*x^7 + ...
a(4) = 5, i.e., {1,2,3,8}, {1,2,4,7}, {1,2,5,6}, {2,3,4,5}, {1,3,4,6}. Number of different distributions of 14 identical balls in 4 boxes as x,y,z,p where 0 < x < y < z < p. - _Ece Uslu_, Esin Becenen, Jan 11 2016
		

References

  • L. Comtet, Advanced Combinatorics, Reidel, 1974, p. 115, row m=4 of Q(m,n) table; p. 120, P(n,4).
  • H. Gupta et al., Tables of Partitions. Royal Society Mathematical Tables, Vol. 4, Cambridge Univ. Press, 1958, p. 2.
  • G. H. Hardy and E. M. Wright, An Introduction to the Theory of Numbers. 3rd ed., Oxford Univ. Press, 1954, p. 275.
  • D. E. Knuth, The Art of Computer Programming, vol. 4, Fascicle 3, Generating All Combinations and Partitions, Addison-Wesley, 2005, Section 7.2.1.4., p. 56, exercise 31.
  • 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

Essentially same as A026810. Partial sums of A005044.
a(n) = A008284(n+4, 4), n >= 0.
First differences of A002621.

Programs

  • Haskell
    a001400 n = a001400_list !! n
    a001400_list = scanl1 (+) a005044_list -- Reinhard Zumkeller, Feb 28 2013
  • Magma
    K:=Rationals(); M:=MatrixAlgebra(K,4); q1:=DiagonalMatrix(M,[1,-1,1,-1]); p1:=DiagonalMatrix(M,[1,1,-1,-1]); q2:=DiagonalMatrix(M,[1,1,1,-1]); h:=M![1,1,1,1, 1,1,-1,-1, 1,-1,1,-1, 1,-1,-1,1]/2; G:=MatrixGroup<4,K|q1,q2,h>; MolienSeries(G);
    
  • Maple
    A001400 := n->if n mod 2 = 0 then round(n^2*(n+3)/144); else round((n-1)^2*(n+5)/144); fi;
    with(combstruct):ZL5:=[S,{S=Set(Cycle(Z,card<5))}, unlabeled]:seq(count(ZL5,size=n),n=0..55); # Zerinvary Lajos, Sep 24 2007
    A001400:=-(-z**8+z**9+2*z**4-z**7-1-z)/(z**2+1)/(z**2+z+1)/(z+1)**2/(z-1)**4; # [conjectured by Simon Plouffe in his 1992 dissertation; gives sequence except for an initial 1]
    B:=[S,{S = Set(Sequence(Z,1 <= card),card <=4)},unlabelled]: seq(combstruct[count](B, size=n), n=0..55); # Zerinvary Lajos, Mar 21 2009
  • Mathematica
    CoefficientList[ Series[ 1/((1 - x)*(1 - x^2)*(1 - x^3)*(1 - x^4)), {x, 0, 65} ], x ]
    LinearRecurrence[{1, 1, 0, 0, -2, 0, 0, 1, 1, -1}, {1, 1, 2, 3, 5, 6, 9, 11, 15, 18}, 80] (* Vladimir Joseph Stephan Orlovsky, Feb 17 2012 *)
    a[n_] := Sum[Floor[(n - j - 3*k + 2)/2], {j, 0, Floor[n/4]}, {k, j, Floor[(n - j)/3]}]; Table[a[n], {n, 0, 55}] (* L. Edson Jeffery, Jul 31 2014 *)
    a[ n_] := With[{m = n + 5}, Round[ (2 m^3 - 3 m (5 + 3 (-1)^m)) / 288]]; (* Michael Somos, Dec 29 2014 *)
    a[ n_] := With[{m = Abs[n + 5] - 5}, Sign[n + 5] Length[ IntegerPartitions[ m, 4]]]; (* Michael Somos, Dec 29 2014 *)
    a[ n_] := With[{m = Abs[n + 5] - 5}, Sign[n + 5] SeriesCoefficient[ 1 / ((1 - x) (1 - x^2) (1 - x^3) (1 - x^4)), {x, 0, m}]]; (* Michael Somos, Dec 29 2014 *)
    Table[Length@IntegerPartitions[n, 4], {n, 0, 55}] (* Robert Price, Aug 18 2020 *)
  • PARI
    a(n) = round(((n+4)^3 + 3*(n+4)^2 -9*(n+4)*((n+4)% 2))/144) \\ Washington Bomfim, Jul 03 2012
    
  • PARI
    {a(n) = n+=5; round( (2*n^3 - 3*n*(5 + 3*(-1)^n)) / 288)}; \\ Michael Somos, Dec 29 2014
    
  • PARI
    a(n) = #partitions(n,,4); \\ Ruud H.G. van Tol, Jun 02 2024
    

Formula

G.f.: 1/((1-x)*(1-x^2)*(1-x^3)*(1-x^4)).
a(n) = 1 + (a(n-2) + a(n-3) + a(n-4)) - (a(n-5) + a(n-6) + a(n-7)) + a(n-9). - Norman J. Meluch (norm(AT)iss.gm.com), Mar 09 2000
P(n, 4) = (1/288)*(2*n^3 + 6*n^2 - 9*n - 13 + (9*n+9)*pcr{1, -1}(2, n) - 32*pcr{1, -1, 0}(3, n) - 36*pcr{1, 0, -1, 0}(4, n)) (see Comtet).
Let c(n) = Sum_{i=0..floor(n/3)} (1 + ceiling((n-3*i-1)/2)), then a(n) = Sum_{i=0..floor(n/4)} (1 + ceiling((n-4*i-1)/2) + c(n-4*i-3)). - Jon Perry, Jun 27 2003
Euler transform of finite sequence [1, 1, 1, 1].
(n choose 4)_q = (q^n-1)*(q^(n-1)-1)*(q^(n-2)-1)*(q^(n-3)-1)/((q^4-1)*(q^3-1)*(q^2-1)*(q-1)).
a(n) = round(((n+4)^3 + 3*(n+4)^2 - 9*(n+4)*((n+4) mod 2))/144). - Washington Bomfim, Jul 03 2012
a(n) = a(n-1) + a(n-2) - 2*a(n-5) + a(n-8) + a(n-9) - a(n-10). - David Neil McGrath, Sep 12 2014
a(n) = -a(-10-n) for all n in Z. - Michael Somos, Dec 29 2014
a(n) - a(n+1) - a(n+3) + a(n+4) = 0 if n is odd, else floor(n/4) + 2 for all n in Z. - Michael Somos, Dec 29 2014
a(n) = n^3/144 + n^2/24 - 7*n/144 + 1 + floor(n/4)/4 + floor(n/3)/3 + (n+5)*floor(n/2)/8 + floor((n+1)/4)/4. - Vaclav Kotesovec, Aug 18 2015
a(n) = a(n-4) + A001399(n). - Ece Uslu, Esin Becenen, Jan 11 2016, corrected Sep 25 2020
a(6*n) - a(6*n+1) - a(6*n+4) + a(6*n+5) = n+1. - Richard Turk, Apr 19 2016
a(n) = a(n-1) + A005044(n+3) for n>0, i.e., first differences is A005044. - Yuchun Ji, Oct 12 2020
From Vladimír Modrák and Zuzana Soltysova, Dec 09 2020: (Start)
a(n) = round((n + 3)^2/12) + Sum_{i=0..floor(n/4)} round((n - 4*i - 1)^2/12).
a(n) = floor(((n + 3)^2 + 4)/12) + Sum_{i=0..floor(n/4)} floor(((n - 4*i - 1)^2 + 4)/12). (End)
a(n) - a(n-3) = A008642(n). - R. J. Mathar, Jun 23 2021
a(n) - a(n-2) = A025767(n). - R. J. Mathar, Jun 23 2021
a(n) = round((2*n^3 + 30*n^2 + 135*n + 175)/288 + (-1)^n*(n+5)/32). - Dave Neary, Oct 28 2021
From Vladimír Modrák, Jul 13 2022: (Start)
a(n) = Sum_{j=0..floor(n/4)} Sum_{i=0..floor(n/3)} ceiling((max(0,n + 1 - 3*i - 4*j))/2).
a(n) = Sum_{i=0..floor(n/4)} floor(((n + 3 - 4*i)^2 + 4)/12). (End)
a(n) = floor(((n+4)^2*(n+7) - 9*(n+4)*(n mod 2) + 32)/144). - Vladimír Modrák, Mar 23 2025

A117485 Expansion of x^9/((1-x)*(1-x^2)*(1-x^3))^2.

Original entry on oeis.org

1, 2, 5, 10, 18, 30, 49, 74, 110, 158, 221, 302, 407, 536, 698, 896, 1136, 1424, 1770, 2176, 2656, 3216, 3866, 4616, 5481, 6466, 7591, 8866, 10306, 11926, 13747, 15778, 18046, 20566, 23359, 26446, 29855, 33600, 37716, 42224, 47152, 52528, 58388, 64752, 71664
Offset: 9

Views

Author

Alford Arnold, Mar 22 2006

Keywords

Comments

Molien series for S_3 X S_3, cf. A001399.
From Gus Wiseman, Apr 06 2019: (Start)
Also the number of integer partitions of n with Durfee square of length 3. The Heinz numbers of these partitions are given by A307386. For example, the a(9) = 1 through a(13) = 18 partitions are:
(333) (433) (443) (444) (544)
(3331) (533) (543) (553)
(3332) (633) (643)
(4331) (3333) (733)
(33311) (4332) (4333)
(4431) (4432)
(5331) (4441)
(33321) (5332)
(43311) (5431)
(333111) (6331)
(33322)
(33331)
(43321)
(44311)
(53311)
(333211)
(433111)
(3331111)
(End)

Examples

			As a cross-check, row sixteen of A115994 yields p(16) = 16 + 140 + 74 + 1.
		

Crossrefs

Column k=3 of A115994.
Cf. A000027 (for k=1), A006918 (for k=2), A117488, A117489, A001399, A117486.

Programs

  • Magma
    n:=3; G:=SymmetricGroup(n); H:=DirectProduct(G,G); MolienSeries(H); // N. J. A. Sloane, Mar 10 2007
    
  • Maple
    with(combstruct):ZL:=[st, {st=Prod(left, right), left=Set(U, card=r), right=Set(U, card=r), U=Sequence(Z, card>=1)}, unlabeled]: subs(r=3, stack): seq(count(subs(r=3, ZL), size=m), m=6..50) ; # Zerinvary Lajos, Jan 02 2008
  • Mathematica
    CoefficientList[Series[1/((1-x)(1-x^2)(1-x^3))^2,{x,0,50}],x] (* Harvey P. Dale, Oct 09 2011 *)
    durf[ptn_]:=Length[Select[Range[Length[ptn]],ptn[[#]]>=#&]];
    Table[Length[Select[IntegerPartitions[n],durf[#]==3&]],{n,0,30}] (* Gus Wiseman, Apr 06 2019 *)
  • PARI
    Vec(x^9 / ((1 - x)^6*(1 + x)^2*(1 + x + x^2)^2) + O(x^60)) \\ Colin Barker, Dec 12 2019
    
  • PARI
    a(n) = floor((3*n^5 - 45*n^4 + 200*n^3 - 180*n^2 - 363*n + 1600)/12960 + n/27*(n%3==0) - n/32*(n%2==0)) \\ Hoang Xuan Thanh, Jul 17 2025

Formula

a(n) = 2*a(n-1) + a(n-2) - 2*a(n-3) - 3*a(n-4) + 6*a(n-6) - 3*a(n-8) - 2*a(n-9) + a(n-10) + 2*a(n-11) - a(n-12) for n>20. - Colin Barker, Dec 12 2019
From Hoang Xuan Thanh, May 17 2025: (Start)
a(n+3) = Sum_{x+2*y+3*z=n} x*y*z.
a(n+3) = n*(n^2-1)*(3*n^2-67)/12960 - floor((n+1)/3)/27 + [n mod 2 = 0]*n/32 + [n mod 3 = 0]*n/27 where [] is the Iverson bracket. (End)

Extensions

Entry revised by N. J. A. Sloane, Mar 10 2007

A117487 G.f.: 1/((1-x)*(1-x^2)*(1-x^3)*(1-x^4)*(1-x^5))^2.

Original entry on oeis.org

1, 2, 5, 10, 20, 36, 63, 104, 169, 264, 405, 604, 888, 1278, 1815, 2536, 3502, 4772, 6437, 8586, 11352, 14866, 19315, 24890, 31851, 40466, 51089, 64092, 79952, 99172, 122386, 150264, 183639, 223394, 270605, 326422, 392225, 469490, 559970, 665542, 788412
Offset: 1

Views

Author

Alford Arnold, Mar 22 2006

Keywords

Comments

Molien series for S_5 X S_5, cf. A001401.
Molien series for S_k X S_k approaches A000712 as k increases.
Column 5 of table A115994.
Note that a(5) is 20, the scalar product of (1 1 2 3 5) and (5 3 2 1 1 ). a(6) is 36, the scalar product of (1 1 2 3 5 7) and (7 5 3 2 1 1 ).

Crossrefs

Programs

  • Magma
    n:=5; G:=SymmetricGroup(n); H:=DirectProduct(G,G); MolienSeries(H); // N. J. A. Sloane
    
  • Maple
    # adapted from A115994 kmax := 120 : qmax := kmax/2 : g:=sum(t^k*q^(k^2)/product((1-q^j)^2, j=1..k), k=1..kmax): gser:=series(g, q=0, qmax): for n from 25 to qmax-1 do P :=coeff(gser, q^n) : printf("%a,",coeff(P, t^5)); od: # R. J. Mathar, Apr 07 2006
  • Mathematica
    CoefficientList[Series[1/(Product[(1-x^j), {j,5}])^2, {x,0,45}], x] (* G. C. Greubel, Jan 01 2020 *)
  • PARI
    my(x='x+O('x^45)); Vec( 1/(prod(j=1,5, 1-x^j))^2 ) \\ G. C. Greubel, Jan 01 2020
    
  • Sage
    def A117487_list(prec):
        P. = PowerSeriesRing(ZZ, prec)
        return P( 1/(product(1-x^j for j in (1..5)))^2 ).list()
    A117487_list(45) # G. C. Greubel, Jan 01 2020

Extensions

More terms from R. J. Mathar, Apr 07 2006
Entry revised by N. J. A. Sloane, Mar 10 2007

A330642 a(n) is the number of partitions of n with Durfee square of size <= 4.

Original entry on oeis.org

1, 1, 2, 3, 5, 7, 11, 15, 22, 30, 42, 56, 77, 101, 135, 176, 231, 297, 385, 490, 627, 792, 1002, 1255, 1575, 1957, 2434, 3005, 3708, 4545, 5568, 6779, 8245, 9974, 12046, 14478, 17372, 20747, 24732, 29360, 34782, 41045, 48337, 56716, 66410, 77498, 90247, 104763, 121366, 140181, 161590, 185755
Offset: 0

Views

Author

Omar E. Pol, Dec 24 2019

Keywords

Crossrefs

Programs

  • PARI
    seq(n) = Vec(sum(k=0, 4, x^(k^2)/prod(j=1, k, 1 - x^j)^2) + O(x*x^n)) \\ Andrew Howroyd, Dec 27 2024

Formula

a(n) = A000041(n), 0 <= n <= 24.
a(n) = A330641(n), 0 <= n <= 15.
a(n) = A330641(n) + A117486(n-16), n >= 16.
a(n) = n + A006918(n-3) + A117485(n) + A117486(n-16), n >= 16.
From Colin Barker, Jan 01 2020: (Start)
G.f.: (1 - x - x^2 + 3*x^5 - x^7 - 2*x^8 - 2*x^9 + 3*x^10 + x^11 + x^12 - x^13 - 2*x^14 + x^15 + x^17 - x^19 + x^20) / ((1 - x)^8*(1 + x)^4*(1 + x^2)^2*(1 + x + x^2)^2).
a(n) = 2*a(n-1) + a(n-2) - 2*a(n-3) - a(n-4) - 4*a(n-5) + 4*a(n-6) + 4*a(n-7) + 2*a(n-8) - 10*a(n-10) + 2*a(n-12) + 4*a(n-13) + 4*a(n-14) - 4*a(n-15) - a(n-16) - 2*a(n-17) + a(n-18) + 2*a(n-19) - a(n-20) for n>20.
(End)
G.f.: Sum_{k=0..4} x^(k^2)/(Product_{j=1..k} (1 - x^j))^2. - Andrew Howroyd, Dec 27 2024

A330643 a(n) is the number of partitions of n with Durfee square of size <= 5.

Original entry on oeis.org

1, 1, 2, 3, 5, 7, 11, 15, 22, 30, 42, 56, 77, 101, 135, 176, 231, 297, 385, 490, 627, 792, 1002, 1255, 1575, 1958, 2436, 3010, 3718, 4565, 5604, 6842, 8349, 10143, 12310, 14883, 17976, 21635, 26010, 31175, 37318, 44547, 53109, 63153, 74996, 88850, 105113, 124078, 146256, 172032, 202056, 236844
Offset: 0

Views

Author

Omar E. Pol, Dec 24 2019

Keywords

Crossrefs

Programs

  • PARI
    seq(n) = Vec(sum(k=0, 5, x^(k^2)/prod(j=1, k, 1 - x^j)^2) + O(x*x^n)) \\ Andrew Howroyd, Dec 27 2024

Formula

a(n) = A000041(n), 0 <= n <= 35.
a(n) = A330642(n), 0 <= n <= 24.
a(n) = A330642(n) + A117487(n-24), n >= 25.
a(n) = n + A006918(n-3) + A117485(n) + A117486(n-16) + A117487(n-24), n >= 25.
G.f.: Sum_{k=0..5} x^(k^2)/(Product_{j=1..k} (1 - x^j))^2. - Andrew Howroyd, Dec 27 2024

A160647 Self-convolution of sequence A001402.

Original entry on oeis.org

1, 2, 5, 10, 20, 36, 65, 108, 179, 284, 445, 676, 1017, 1492, 2168, 3094, 4372, 6088, 8406, 11462, 15509, 20770, 27614, 36390, 47646, 61898, 79939, 102538, 130808, 165864, 209272, 262598, 328008, 407700, 504607, 621760, 763123, 932788, 1136047
Offset: 1

Views

Author

Alford Arnold, May 27 2009

Keywords

Examples

			a(8) = 108 because the eighth antidiagonal of the associated array is 14 11 14 15 15 14 11 14 and sums to 108.
		

Crossrefs

Cf. A117566.
Sixth in a list of sequences related to numeric partitions; earlier sequences are A000027, A006918, A117485, A117486, and A117487.

Programs

  • Maple
    A160647 := proc(n) coeftayl( convert(1/mul((1-x^j)^2,j=1..6),parfrac,x),x=0,n) ; end: seq(A160647(n),n=0..45) ; # R. J. Mathar, Jun 16 2009

Extensions

More terms from R. J. Mathar, Jun 16 2009

A364842 Table read by antidiagonals: row n gives the Euler transform of the sequence (2,...,2,0,0,...) that contains n 2s followed by 0s.

Original entry on oeis.org

1, 1, 2, 1, 2, 3, 1, 2, 5, 4, 1, 2, 5, 8, 5, 1, 2, 5, 10, 14, 6, 1, 2, 5, 10, 18, 20, 7, 1, 2, 5, 10, 20, 30, 30, 8, 1, 2, 5, 10, 20, 34, 49, 40, 9, 1, 2, 5, 10, 20, 36, 59, 74, 55, 10, 1, 2, 5, 10, 20, 36, 63, 94, 110, 70, 11, 1, 2, 5, 10, 20, 36, 65, 104, 149, 158, 91, 12
Offset: 1

Views

Author

Peter Kagey, Nov 09 2023

Keywords

Examples

			Table begins:
  | 0 1 2  3  4  5  6   7   8   9  10
--+----------------------------------
1 | 1 2 3  4  5  6  7   8   9  10  11
2 | 1 2 5  8 14 20 30  40  55  70  91
3 | 1 2 5 10 18 30 49  74 110 158 221
4 | 1 2 5 10 20 34 59  94 149 224 334
5 | 1 2 5 10 20 36 63 104 169 264 405
6 | 1 2 5 10 20 36 65 108 179 284 445
7 | 1 2 5 10 20 36 65 110 183 294 465
8 | 1 2 5 10 20 36 65 110 185 298 475
9 | 1 2 5 10 20 36 65 110 185 300 479
		

Crossrefs

Cf. A000027 (row 1), A006918 (row 2), A117485 (row 3), A117486 ( row 4), A117487 (row 5), A160647 (row 6), A000712 (main diagonal).
Analogous for initial 1s sequence A008284.
Cf. A115994.

Programs

  • Mathematica
    Seed[i_, n_] := ConstantArray[2, i]~Join~ConstantArray[0, n - i];
    A364842Table[n_] := Table[Seed[i, n] // EulerTransform, {i, 1, n}]
    (*EulerTransform is defined in A005195*)
Showing 1-7 of 7 results.