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

A238803 Number of ballot sequences of length 2n with exactly n fixed points.

Original entry on oeis.org

1, 1, 3, 9, 29, 99, 357, 1351, 5343, 21993, 93923, 414969, 1892277, 8887291, 42912261, 212676951, 1080355463, 5617772049, 29868493827, 162204146857, 898874710797, 5078665886931, 29232738375653, 171294038649639, 1021117638212079, 6188701520663929
Offset: 0

Views

Author

Joerg Arndt and Alois P. Heinz, Mar 05 2014

Keywords

Comments

The fixed points are in the positions 1,2,...,n.
Also the number of standard Young tableaux with 2n cells where n is the length of the maximal consecutive sequence 1,2,...,k in the first column. An alternate definition uses the first row.
All terms are odd because the counted structures come in pairs with exactly one exception.
Except for a(0), first differences of A005425. - Ivan N. Ianakiev, Sep 01 2019

Examples

			For n=3 we have the following a(3) = 9 ballot sequences: [1,2,3,1,1,1], [1,2,3,1,2,3], [1,2,3,1,1,2], [1,2,3,1,2,1], [1,2,3,1,4,1], [1,2,3,1,4,2], [1,2,3,1,1,4], [1,2,3,1,2,4], [1,2,3,1,4,5].
Their corresponding tableaux are:
: 1456  14 : 145  146 : 146  14 : 145  14 : 14 :
: 2     25 : 26   25  : 2    26 : 2    25 : 2  :
: 3     36 : 3    3   : 3    3  : 3    3  : 3  :
:          :          : 5    5  : 6    6  : 5  :
:          :          :         :         : 6  :
		

Crossrefs

Programs

  • Maple
    a:= proc(n) option remember; `if`(n<2, 1,
          ((2*n-1) *a(n-1) +n*(n-2) *a(n-2)) / (n-1))
        end:
    seq(a(n), n=0..35);
  • Mathematica
    RecurrenceTable[{a[0]==a[1]==1,a[n]==((2n-1)a[n-1]+n(n-2)a[n-2])/(n-1)},a,{n,30}] (* Harvey P. Dale, Jun 25 2014 *)

Formula

a(n) = ((2*n-1)*a(n-1)+n*(n-2)*a(n-2))/(n-1) for n>1, a(0) = a(1) = 1.
a(n) = A238802(2*n,n).
a(n) = Sum_{k=0..n} C(n-1,k) * A000085(n-k).
a(n) ~ exp(2*sqrt(n)-n/2-1) * n^(n/2) / sqrt(2) * (1 - 1/(6*sqrt(n))). - Vaclav Kotesovec, Mar 07 2014

A238977 Number of ballot sequences of length n with exactly 2 fixed points.

Original entry on oeis.org

0, 0, 1, 1, 3, 8, 24, 74, 246, 848, 3088, 11644, 45844, 186336, 784928, 3403128, 15212744, 69802944, 328988096, 1587831568, 7848954928, 39651793024, 204691645824, 1078028406176, 5790745961568, 31687186373888, 176575788105984, 1001061518465984, 5771865641210176
Offset: 0

Views

Author

Joerg Arndt and Alois P. Heinz, Mar 07 2014

Keywords

Comments

The fixed points are in the first 2 positions.
Also the number of standard Young tableaux with n cells such that the first column contains 1 and 2, but not 3. An alternate definition uses the first row.

Examples

			a(2) = 1: [1,2].
a(3) = 1: [1,2,1].
a(4) = 3: [1,2,1,1], [1,2,1,2], [1,2,1,3].
a(5) = 8: [1,2,1,1,1], [1,2,1,1,2], [1,2,1,1,3], [1,2,1,2,1], [1,2,1,2,3], [1,2,1,3,1], [1,2,1,3,2], [1,2,1,3,4].
		

Crossrefs

Column k=2 of A238802.

Programs

  • Maple
    a:= proc(n) option remember; `if`(n<3, n*(n-1)/2,
          ((3*n^2+3*n-33)*a(n-1) +(n-4)*(10*n^2-27*n-6)*a(n-2)
          +(n-4)*(n-5)*(7*n-18)*a(n-3)) / (10*n^2-64*n+105))
        end:
    seq(a(n), n=0..40);
  • Mathematica
    b[n_, l_List] := b[n, l] = If[n <= 0, 1, b[n - 1, Append[l, 1]] + Sum[If[i == 1 || l[[i - 1]] > l[[i]], b[n - 1, ReplacePart[l, i -> l[[i]] + 1]], 0], {i, 1, Length[l]}]]; a[n_] := b[n - 3, {2, 1}]; a[0] = a[1] = 0; Table[Print["a(", n, ") = ", an = a[n]]; an, {n, 0, 40}] (* Jean-François Alcover, Feb 06 2015, after Maple *)

Formula

See Maple program.
a(n) ~ sqrt(2)/6 * exp(sqrt(n)-n/2-1/4) * n^(n/2) * (1 + 7/(24*sqrt(n))). - Vaclav Kotesovec, Mar 07 2014
Recurrence (for n>=4): (n-3)*(n^2 - 6*n + 11)*a(n) = (n^3 - 9*n^2 + 32*n - 39)*a(n-1) + (n-4)*(n-2)*(n^2 - 4*n + 6)*a(n-2). - Vaclav Kotesovec, Mar 08 2014
From Peter Bala, Oct 05 2021: (Start)
a(n) = (1/3)*( A000085(n) - A000085(n-3) ) for n >= 3.
a(n) = (1/3)*Sum_{k = 0..floor(n/2)} (1 - binomial(n-2*k,3)/binomial(n,3))* binomial(n,2*k) * (2*k)!/(2^k*k!) for n >= 3.
Conjecture: a(n+3) == 1 (mod n) iff n is coprime to 2 and 3, that is, iff n is a term of A007310. (End)

A238978 Number of ballot sequences of length n with exactly 3 fixed points.

Original entry on oeis.org

0, 0, 0, 1, 1, 3, 9, 28, 93, 321, 1168, 4404, 17328, 70408, 296436, 1284768, 5740804, 26332788, 124066608, 598625296, 2958281328, 14941136784, 77111251408, 406028059968, 2180584156176, 11930067296848, 66468429865344, 376770132276288, 2172036623279488
Offset: 0

Views

Author

Joerg Arndt and Alois P. Heinz, Mar 07 2014

Keywords

Comments

The fixed points are in the first 3 positions.
Also the number of standard Young tableaux with n cells such that the first column contains 1, 2, and 3, but not 4. An alternate definition uses the first row.

Examples

			a(3) = 1: [1,2,3].
a(4) = 1: [1,2,3,1].
a(5) = 3: [1,2,3,1,1], [1,2,3,1,2], [1,2,3,1,4].
a(6) = 9: [1,2,3,1,1,1], [1,2,3,1,1,2], [1,2,3,1,1,4], [1,2,3,1,2,1], [1,2,3,1,2,3], [1,2,3,1,2,4], [1,2,3,1,4,1], [1,2,3,1,4,2], [1,2,3,1,4,5].
		

Crossrefs

Column k=3 of A238802.

Programs

  • Maple
    a:= proc(n) option remember; `if`(n<4, n*(n-1)*(n-2)/6,
          ((4*n^3-54*n^2+216*n-254) *a(n-1)
           +(n-5)*(3*n^3-31*n^2+84*n-30) *a(n-2)
           -(n-5)*(n-6)*(n^2-3*n-8) *a(n-3)) /
          ((n-3)*(3*n^2-33*n+86)))
        end:
    seq(a(n), n=0..40);
  • Mathematica
    b[n_, l_List] := b[n, l] = If[n <= 0, 1, b[n - 1, Append[l, 1]] + Sum[If[i == 1 || l[[i - 1]] > l[[i]], b[n - 1, ReplacePart[l, i -> l[[i]] + 1]], 0], {i, 1, Length[l]}]]; a[n_] := If[n == 3, 1, b[n - 4, {2, 1, 1}]]; a[n_ /; n < 3] = 0; Table[Print["a(", n, ") = ", an = a[n]]; an, {n, 0, 40}] (* Jean-François Alcover, Feb 06 2015, after Maple *)

Formula

See Maple program.
a(n) ~ sqrt(2)/16 * exp(sqrt(n)-n/2-1/4) * n^(n/2) * (1 + 7/(24*sqrt(n))). - Vaclav Kotesovec, Mar 07 2014
Recurrence (for n>=5): (n-4)*(n^3 - 10*n^2 + 27*n - 26)*a(n) = (n^4 - 14*n^3 + 67*n^2 - 150*n + 152)*a(n-1) + (n-5)*(n-3)*(n^3 - 7*n^2 + 10*n - 8)*a(n-2). - Vaclav Kotesovec, Mar 08 2014

A238979 Number of ballot sequences of length n with exactly 4 fixed points.

Original entry on oeis.org

0, 0, 0, 0, 1, 1, 3, 9, 29, 98, 350, 1302, 5062, 20380, 85108, 366444, 1627836, 7430360, 34855016, 167546408, 825185448, 4155400720, 21388745008, 112355110672, 602103194448, 3287743832352, 18285157048544, 103480813034336, 595671084096608, 3485006638408128
Offset: 0

Views

Author

Joerg Arndt and Alois P. Heinz, Mar 07 2014

Keywords

Comments

The fixed points are in the first 4 positions.
Also the number of standard Young tableaux with n cells such that the first column contains 1, 2, 3, and 4, but not 5. An alternate definition uses the first row.
Conjecture: Generally, for fixed k is column k of A238802 asymptotic to sqrt(2)/(2*(k+1)*(k-1)!) * exp(sqrt(n)-n/2-1/4) * n^(n/2) * (1 + 7/(24*sqrt(n))), holds for all k<=10. - Vaclav Kotesovec, Mar 08 2014

Examples

			a(4) = 1: [1,2,3,4].
a(5) = 1: [1,2,3,4,1].
a(6) = 3: [1,2,3,4,1,1], [1,2,3,4,1,2], [1,2,3,4,1,5].
a(7) = 9: [1,2,3,4,1,1,1], [1,2,3,4,1,1,2], [1,2,3,4,1,1,5], [1,2,3,4,1,2,1], [1,2,3,4,1,2,3], [1,2,3,4,1,2,5], [1,2,3,4,1,5,1], [1,2,3,4,1,5,2], [1,2,3,4,1,5,6].
		

Crossrefs

Column k=4 of A238802.

Programs

  • Maple
    b:= proc(n) option remember; `if`(n<3, [1$2, 3][n+1],
          ((11-n)*b(n-1) +(n^3+4*n^2-15)*b(n-2)
           +(n-1)*(n-3)*(n+7)*b(n-3))/((n-1)*(n+1)))
        end:
    a:= n-> `if`(n<4, 0, b(n-4)):
    seq(a(n), n=0..40);
  • Mathematica
    b[n_, l_List] := b[n, l] = If[n <= 0, 1, b[n - 1, Append[l, 1]] + Sum[If[i == 1 || l[[i - 1]] > l[[i]], b[n - 1, ReplacePart[l, i -> l[[i]] + 1]], 0], {i, 1, Length[l]}]]; a[n_] := If[n == 4, 1, b[n - 5, {2, 1, 1, 1}]]; a[n_ /; n < 4] = 0; Table[Print["a(", n, ") = ", an = a[n]]; an, {n, 0, 40}] (* Jean-François Alcover, Feb 06 2015, after Maple *)

Formula

See Maple program.
a(n) ~ sqrt(2)/60 * exp(sqrt(n)-n/2-1/4) * n^(n/2) * (1 + 7/(24*sqrt(n))). - Vaclav Kotesovec, Mar 07 2014
Recurrence (for n>=6): (n-5)*(n^4 - 15*n^3 + 65*n^2 - 45*n + 54)*a(n) = (n^5 - 20*n^4 + 125*n^3 - 145*n^2 - 651*n + 810)*a(n-1) + (n-6)*(n-4)*(n^4 - 11*n^3 + 26*n^2 + 44*n + 60)*a(n-2). - Vaclav Kotesovec, Mar 08 2014

A239116 Number of ballot sequences of length n with exactly 5 fixed points.

Original entry on oeis.org

0, 0, 0, 0, 0, 1, 1, 3, 9, 29, 99, 356, 1343, 5279, 21584, 91324, 399456, 1799568, 8343404, 39702144, 193768604, 967992476, 4946617328, 25817913584, 137549830384, 747137750064, 4135349698416, 23301072909248, 133591802704944, 778722128953904, 4613070010373504
Offset: 0

Views

Author

Joerg Arndt and Alois P. Heinz, Mar 10 2014

Keywords

Comments

The fixed points are in the first 5 positions.
Also the number of standard Young tableaux with n cells such that the first column contains 1, 2, ..., 5, but not 6. An alternate definition uses the first row.

Examples

			a(5) = 1: [1,2,3,4,5].
a(6) = 1: [1,2,3,4,5,1].
a(7) = 3: [1,2,3,4,5,1,1], [1,2,3,4,5,1,2], [1,2,3,4,5,1,6].
a(8) = 9: [1,2,3,4,5,1,1,1], [1,2,3,4,5,1,1,2], [1,2,3,4,5,1,1,6], [1,2,3,4,5,1,2,1], [1,2,3,4,5,1,2,3], [1,2,3,4,5,1,2,6], [1,2,3,4,5,1,6,1], [1,2,3,4,5,1,6,2], [1,2,3,4,5,1,6,7].
		

Crossrefs

Column k=5 of A238802.

Programs

  • Maple
    a:= proc(n) option remember; `if`(n<6, [0$5, 1][n+1],
          ((952098*n^4 -28186656*n^3 +321186690*n^2 -1739275812*n
           +3721544280)*a(n-1) +(n-7)*(451397*n^4 -9536389*n^3
           +64448100*n^2 -229993164*n +534842280)*a(n-2)
           -(n-7)*(n-8)*(500701*n^3 -9933473*n^2 +95681400*n
           -319342500)*a(n-3))/
           ((n-5)*(451397*n^3-9487085*n^2+55580742*n-95239584)))
        end:
    seq(a(n), n=0..40);
  • Mathematica
    b[n_, l_List] := b[n, l] = If[n <= 0, 1, b[n - 1, Append[l, 1]] + Sum[If[i == 1 || l[[i - 1]] > l[[i]], b[n - 1, ReplacePart[l, i -> l[[i]] + 1]], 0], {i, 1, Length[l]}]]; a[n_] := If[n == 5, 1, b[n - 6, {2, 1, 1, 1, 1}]]; a[n_ /; n < 5] = 0; Table[ Print["a(", n, ") = ", an = a[n]]; an, {n, 0, 40}] (* Jean-François Alcover, Feb 06 2015, after Maple *)

Formula

See Maple program.
Recurrence (for n>=7): (n-6)*(n^5 - 21*n^4 + 157*n^3 - 699*n^2 + 3298*n - 13680)*a(n) = (n^6 - 27*n^5 + 235*n^4 - 537*n^3 - 1964*n^2 - 2316*n + 54720)*a(n-1) + (n-7)*(n-5)*(n^5 - 16*n^4 + 83*n^3 - 344*n^2 + 2292*n - 10944)*a(n-2). - Vaclav Kotesovec, Mar 11 2014
a(n) ~ sqrt(2)/288 * exp(sqrt(n)-n/2-1/4) * n^(n/2) * (1 + 7/(24*sqrt(n))). - Vaclav Kotesovec, Mar 11 2014

A239117 Number of ballot sequences of length n with exactly 6 fixed points.

Original entry on oeis.org

0, 0, 0, 0, 0, 0, 1, 1, 3, 9, 29, 99, 357, 1350, 5334, 21912, 93352, 410988, 1866492, 8720924, 41866020, 206085480, 1039120104, 5358418224, 28235017104, 151838491408, 832730775888, 4652886489840, 26470731088016, 153207256585824, 901628675631456, 5391563546317056
Offset: 0

Views

Author

Joerg Arndt and Alois P. Heinz, Mar 10 2014

Keywords

Comments

The fixed points are in the first 6 positions.
Also the number of standard Young tableaux with n cells such that the first column contains 1, 2, ..., 6, but not 7. An alternate definition uses the first row.

Examples

			a(6) = 1: [1,2,3,4,5,6].
a(7) = 1: [1,2,3,4,5,6,1].
a(8) = 3: [1,2,3,4,5,6,1,1], [1,2,3,4,5,6,1,2], [1,2,3,4,5,6,1,7].
a(9) = 9: [1,2,3,4,5,6,1,1,1], [1,2,3,4,5,6,1,1,2], [1,2,3,4,5,6,1,1,7], [1,2,3,4,5,6,1,2,1], [1,2,3,4,5,6,1,2,3], [1,2,3,4,5,6,1,2,7], [1,2,3,4,5,6,1,7,1], [1,2,3,4,5,6,1,7,2], [1,2,3,4,5,6,1,7,8].
		

Crossrefs

Column k=6 of A238802.

Programs

  • Maple
    b:= proc(n) option remember; `if`(n<3, [1,1,3][n+1],
          ((114*n^3 -68193*n^2 +266129*n -764878)*b(n-1)
           +(2513*n^4 +25106*n^3 +330108*n^2 -382379*n +208440)*b(n-2)
           +(n-3)*(2399*n^3 +95128*n^2 +269793*n +65880)*b(n-3))/
           (2513*n^3+10142*n^2+201063*n-630958))
        end:
    a:=n-> `if`(n<6, 0, b(n-6)):
    seq(a(n), n=0..40);
  • Mathematica
    b[n_, l_List] := b[n, l] = If[n <= 0, 1, b[n - 1, Append[l, 1]] + Sum[If[i == 1 || l[[i - 1]] > l[[i]], b[n - 1, ReplacePart[l, i -> l[[i]] + 1]], 0], {i, 1, Length[l]}]]; a[n_] := If[n == 6, 1, b[n - 7, {2, 1, 1, 1, 1, 1}]]; a[n_ /; n < 6] = 0; Table[ Print["a(", n, ") = ", an = a[n]]; an, {n, 0, 40}] (* Jean-François Alcover, Feb 06 2015, after Maple *)

Formula

See Maple program.
Recurrence (for n>=8): (n-7)*(n^6 - 28*n^5 + 350*n^4 - 3850*n^3 + 37569*n^2 - 201082*n + 556800)*a(n) = (n^7 - 35*n^6 + 441*n^5 - 3220*n^4 + 31444*n^3 - 314265*n^2 + 1921954*n - 5066880)*a(n-1) + (n-8)*(n-6)*(n^6 - 22*n^5 + 225*n^4 - 2710*n^3 + 27854*n^2 - 136228*n + 389760)*a(n-2). - Vaclav Kotesovec, Mar 11 2014
a(n) ~ sqrt(2)/1680 * exp(sqrt(n)-n/2-1/4) * n^(n/2) * (1+7/(24*sqrt(n))). - Vaclav Kotesovec, Mar 11 2014

A239118 Number of ballot sequences of length n with exactly 7 fixed points.

Original entry on oeis.org

0, 0, 0, 0, 0, 0, 0, 1, 1, 3, 9, 29, 99, 357, 1351, 5342, 21983, 93823, 414198, 1886424, 8846390, 42628782, 210773592, 1067599984, 5533263752, 29307314408, 158484944416, 874103230896, 4913196556800, 28120097476640, 163770757573776, 969858742317600
Offset: 0

Views

Author

Joerg Arndt and Alois P. Heinz, Mar 10 2014

Keywords

Comments

The fixed points are in the first 7 positions.
Also the number of standard Young tableaux with n cells such that the first column contains 1, 2, ..., 7, but not 8. An alternate definition uses the first row.

Examples

			a(7) = 1: [1,2,3,4,5,6,7].
a(8) = 1: [1,2,3,4,5,6,7,1].
a(9) = 3: [1,2,3,4,5,6,7,1,1], [1,2,3,4,5,6,7,1,2], [1,2,3,4,5,6,7,1,8].
a(10) = 9: [1,2,3,4,5,6,7,1,1,1], [1,2,3,4,5,6,7,1,1,2], [1,2,3,4,5,6,7,1,1,8], [1,2,3,4,5,6,7,1,2,1], [1,2,3,4,5,6,7,1,2,3], [1,2,3,4,5,6,7,1,2,8], [1,2,3,4,5,6,7,1,8,1], [1,2,3,4,5,6,7,1,8,2], [1,2,3,4,5,6,7,1,8,9].
		

Crossrefs

Column k=7 of A238802.

Programs

  • Maple
    b:= proc(n) option remember; `if`(n<4, [1, 1, 3, 9][n+1],
          ((41*n^2 +82925*n -562776)*b(n-1)
           +(174*n^3 +63287*n^2 -447840*n +352440) *b(n-2)
           +(133*n^3 -81472*n^2 +363510*n -267096) *b(n-3)
           -(n-4)*(30661*n^2 -93002*n -90720) *b(n-4))/
           (174*n^2+31449*n-246768))
        end:
    a:=n-> `if`(n<7, 0, b(n-7)):
    seq(a(n), n=0..40);
  • Mathematica
    b[n_, l_List] := b[n, l] = If[n <= 0, 1, b[n - 1, Append[l, 1]] + Sum[If[i == 1 || l[[i - 1]] > l[[i]], b[n - 1, ReplacePart[l, i -> l[[i]] + 1]], 0], {i, 1, Length[l]}]]; a[n_] := If[n == 7, 1, b[n - 8, {2, 1, 1, 1, 1, 1, 1}]]; a[n_ /; n < 7] = 0; Table[ Print["a(", n, ") = ", an = a[n]]; an, {n, 0, 40}] (* Jean-François Alcover, Feb 06 2015, after Maple *)

Formula

See Maple program.
Recurrence (for n>=9): (n-8)*(n^7 - 36*n^6 + 706*n^5 - 13080*n^4 + 177169*n^3 - 1264884*n^2 + 3776364*n - 9605520)*a(n) = (n^8 - 44*n^7 + 802*n^6 - 12104*n^5 + 206449*n^4 - 2516636*n^3 + 16735788*n^2 - 68051376*n + 170709120)*a(n-1) + (n-9)*(n-7)*(n^7 - 29*n^6 + 511*n^5 - 10055*n^4 + 131224*n^3 - 805316*n^2 + 1729104*n - 6929280)*a(n-2). - Vaclav Kotesovec, Mar 11 2014
a(n) ~ sqrt(2)/11520 * exp(sqrt(n)-n/2-1/4) * n^(n/2) * (1+7/(24*sqrt(n))). - Vaclav Kotesovec, Mar 11 2014

A239119 Number of ballot sequences of length n with exactly 8 fixed points.

Original entry on oeis.org

0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 3, 9, 29, 99, 357, 1351, 5343, 21992, 93912, 414848, 1891264, 8878972, 42849860, 212214460, 1077052284, 5594301872, 29704267536, 161055535088, 890880956848, 5022885935600, 28843306388880, 168562494708400, 1001888980299056
Offset: 0

Views

Author

Joerg Arndt and Alois P. Heinz, Mar 10 2014

Keywords

Comments

The fixed points are in the first 8 positions.
Also the number of standard Young tableaux with n cells such that the first column contains 1, 2, ..., 8, but not 9. An alternate definition uses the first row.
Conjecture: Generally, for fixed k is column k of A238802 asymptotic to sqrt(2)/(2*(k+1)*(k-1)!) * exp(sqrt(n)-n/2-1/4) * n^(n/2) * (1 + 7/(24*sqrt(n))), (holds for all k<=10). - Vaclav Kotesovec, Mar 11 2014

Examples

			a(8) = 1: [1,2,3,4,5,6,7,8].
a(9) = 1: [1,2,3,4,5,6,7,8,1].
a(10) = 3: [1,2,3,4,5,6,7,8,1,1], [1,2,3,4,5,6,7,8,1,2], [1,2,3,4,5,6,7,8,1,9].
a(11) = 9: [1,2,3,4,5,6,7,8,1,1,1], [1,2,3,4,5,6,7,8,1,1,2], [1,2,3,4,5,6,7,8,1,1,9], [1,2,3,4,5,6,7,8,1,2,1], [1,2,3,4,5,6,7,8,1,2,3], [1,2,3,4,5,6,7,8,1,2,9], [1,2,3,4,5,6,7,8,1,9,1], [1,2,3,4,5,6,7,8,1,9,2], [1,2,3,4,5,6,7,8,1,9,10].
		

Crossrefs

Column k=8 of A238802.

Programs

  • Maple
    b:= proc(n) option remember; `if`(n<3, [1, 1, 3][n+1],
          ((78*n^4 -18395*n^3 -71700*n^2 +536111*n -6824556)*b(n-1)
           +(203*n^5 +3335*n^4 +113400*n^3 +811949*n^2 -2733405*n
           +5461380)*b(n-2) +(n-3)*(125*n^4 +21309*n^3 +273479*n^2
           +556667*n +1829700)*b(n-3)) /
           (203*n^4+1789*n^3+80693*n^2+377071*n-3156156))
        end:
    a:=n-> `if`(n<8, 0, b(n-8)):
    seq(a(n), n=0..40);
  • Mathematica
    b[n_, l_List] := b[n, l] = If[n <= 0, 1, b[n - 1, Append[l, 1]] + Sum[If[i == 1 || l[[i - 1]] > l[[i]], b[n - 1, ReplacePart[l, i -> l[[i]] + 1]], 0], {i, 1, Length[l]}]]; a[n_] := If[n == 8, 1, b[n - 9, {2, 1, 1, 1, 1, 1, 1, 1}]]; a[n_ /; n < 8] = 0; Table[ Print["a(", n, ") = ", an = a[n]]; an, {n, 0, 40}] (* Jean-François Alcover, Feb 06 2015, after Maple *)

Formula

See Maple program.
Recurrence (for n>=10): (n-9)*(n^8 - 45*n^7 + 1302*n^6 - 34146*n^5 + 562989*n^4 - 4387005*n^3 + 7242668*n^2 + 80535276*n + 148594320)*a(n) = (n^9 - 54*n^8 + 1392*n^7 - 33705*n^6 + 734286*n^5 - 9696141*n^4 + 60317333*n^3 - 48716460*n^2 - 234532332*n - 4007057040)*a(n-1) + (n-10)*(n-8)*(n^8 - 37*n^7 + 1015*n^6 - 27223*n^5 + 410284*n^4 - 2451988*n^3 - 2863260*n^2 + 83948328*n + 232515360)*a(n-2). - Vaclav Kotesovec, Mar 11 2014
a(n) ~ sqrt(2)/90720 * exp(sqrt(n)-n/2-1/4) * n^(n/2) * (1+7/(24*sqrt(n))). - Vaclav Kotesovec, Mar 11 2014
Showing 1-8 of 8 results.