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 16 results. Next

A036073 Triangle of coefficients arising in calculation of A002872 and A002874 (sorting numbers).

Original entry on oeis.org

1, 2, 1, 5, 1, 6, 15, 1, 11, 30, 52, 1, 20, 80, 150, 203, 1, 37, 210, 525, 780, 877, 1, 70, 560, 1785, 3395, 4263, 4140, 1, 135, 1526, 6125, 14140, 22288, 24556, 21147, 1, 264, 4240, 21420, 58842, 109998, 150402, 149040, 115975, 1, 521, 11970, 76385, 248115
Offset: 0

Views

Author

Keywords

Comments

For connection to A002872, A002874, and other columns of A162663, see the formula in A162663. - Andrey Zabolotskiy, Oct 25 2017

Examples

			Triangle begins:
  1;
  .  2;
  .  1,  5;
  .  1,  6,  15;
  .  1, 11,  30,  52;
  .  1, 20,  80, 150, 203;
  .  1, 37, 210, 525, 780, 877;
  ...
		

References

  • T. S. Motzkin, Sorting numbers for cylinders and other classification numbers, in Combinatorics, Proc. Symp. Pure Math. 19, AMS, 1971, pp. 167-176.

Crossrefs

Row sums give A001861.
Diagonal gives A000110(n+1) - Alois P. Heinz, Mar 27 2013
Cf. A162663.

Programs

  • Maple
    egf:= exp(exp(x*y)+y*(exp(x)-1)-1):
    T:= (n, k)-> n!*coeff(series(coeff(series(egf, y, k+1)
                    , y, k), x, n+1), x, n):
    seq(seq(T(n, k), k=min(n, 1)..n), n=0..10);  # Alois P. Heinz, Mar 28 2013
  • PARI
    T(n, k) = { my(y = 'y + 'y*O('y^k), x = 'x + 'x*O('x^n); ); n!*polcoeff(polcoeff(exp(exp(x*y)+y*(exp(x)-1)-1), n, 'x), k, 'y); }
    for(n=0,10,for(k=0,n,print1(T(n,k),", "));print()); /* print triangle */
    \\ Michel Marcus, Mar 27 2013
    
  • PARI
    listpols(n)= {my(z = t + t*O(t^n)); zp = exp(exp(z)-1+(exp(p*z)-1)/p); for (i=0, n, print(i!*polcoeff(zp, i, t)););} \\ Michel Marcus, Mar 27 2013

Formula

E.g.f.: exp(exp(x*y)+y*(exp(x)-1)-1).

Extensions

Edited by Vladeta Jovovic, Sep 17 2003
Name corrected by Andrey Zabolotskiy, Oct 22 2017

A002872 Number of partitions of {1..2n} that are invariant under a permutation consisting of n 2-cycles.

Original entry on oeis.org

1, 2, 7, 31, 164, 999, 6841, 51790, 428131, 3827967, 36738144, 376118747, 4086419601, 46910207114, 566845074703, 7186474088735, 95318816501420, 1319330556537631, 19013488408858761, 284724852032757686, 4422344774431494155, 71125541977466879231
Offset: 0

Views

Author

Keywords

Comments

Previous name was: Sorting numbers.
a(n) = number of symmetric partitions of the set {-n,...,-1,1,...,n}. A partition of {-n,...,-1,1,...,n} into nonempty subsets X_1,...,X_k is 'symmetric' if for each i, -X_i=X_j for some j. a(n) = S_B(n,1)+...+S_B(n,n) where S_B(n,k) is as in A085483. a(n) is the n-th Bell number of 'type B'. - James East, Aug 18 2003
Column 2 of A162663. - Franklin T. Adams-Watters, Jul 09 2009
a(n) is equal to the sum of all expressions of the form p(1^n)[st(lambda)] for partitions lambda of order less than or equal to n, where p(1^n)[st(lambda)] denotes the coefficient of the irreducible character basis element indexed by the partition lambda in the expansion of the power sum basis element indexed by the partition (1^n). - John M. Campbell, Sep 16 2017
Number of achiral color patterns in a row or loop of length 2n. Two color patterns are equivalent if the colors are permuted. - Robert A. Russell, Apr 24 2018
Stirling transform of A005425 per Knuth reference. - Robert A. Russell, Apr 28 2018

Examples

			For a(2)=7, the row patterns are AAAA, AABB, ABAB, ABBA, ABBC, ABCA, and ABCD.  The loop patterns are AAAA, AAAB, AABB, AABC, ABAB, ABAC, and ABCD. - _Robert A. Russell_, Apr 24 2018
		

References

  • D. E. Knuth, The Art of Computer Programming, vol. 4A, Combinatorial Algorithms, Section 7.2.1.5 (p. 765). - Robert A. Russell, Apr 28 2018
  • 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

u[n,j] is A162663.
Row sums of A293181.
Column k=2 of A306024.
Cf. A005425.

Programs

  • Maple
    a:= proc(n) option remember; `if`(n=0, 1, add((1+
          2^(j-1))*binomial(n-1, j-1)*a(n-j), j=1..n))
        end:
    seq(a(n), n=0..30);  # Alois P. Heinz, Oct 29 2015
  • Mathematica
    u[0,j_]:=1;u[k_,j_]:=u[k,j]=Sum[Binomial[k-1,i-1]Plus@@(u[k-i,j]#^(i-1)&/@Divisors[j]),{i,k}]; Table[u[n,2],{n,0,12}] (* Wouter Meeussen, Dec 06 2008 *)
    mx = 16; p = 2; Range[0, mx]! CoefficientList[ Series[ Exp[ (Exp[p*x] - p - 1)/p + Exp[x]], {x, 0, mx}], x] (* Robert G. Wilson v, Dec 12 2012 *)
    Aeven[m_, k_] := Aeven[m, k] = If[m>0, k Aeven[m-1, k] + Aeven[m-1, k-1]
      + Aeven[m-1, k-2], Boole[m==0 && k==0]]
    Table[Sum[Aeven[m, k], {k, 0, 2m}], {m, 0, 30}] (* Robert A. Russell, Apr 24 2018 *)
    x[n_] := x[n] = If[n<2, n+1, 2x[n-1] + (n-1)x[n-2]]; (* A005425 *)
    Table[Sum[StirlingS2[n, k] x[k], {k, 0, n}], {n, 0, 20}] (* Robert A. Russell, Apr 28 2018, from Knuth reference *)
    Table[Sum[Binomial[n,k] * 2^k * BellB[k, 1/2] * BellB[n-k], {k, 0, n}], {n, 0, 20}] (* Vaclav Kotesovec, Jun 29 2022 *)

Formula

E.g.f.: e^( (e^(2x) - 3)/2 + e^x ).
a(n) = A080107(2n) for all n. - Jörgen Backelin, Jan 13 2016
From Robert A. Russell, Apr 24 2018: (Start)
Aeven(n,k) = [n>0]*(k*Aeven(n-1,k)+Aeven(n-1,k-1)+Aeven(n-1,k-2))
+ [n==0]*[k==0]
a(n) = Sum_{k=0..2n} Aeven(n,k). (End)
a(n) = Sum_{k=0..n} Stirling2(n, k)*A005425(k). (from Knuth reference) - Robert A. Russell, Apr 28 2018
a(n) ~ exp(exp(2*r)/2 + exp(r) - 3/2 - n) * (n/r)^(n + 1/2) / sqrt((1 + 2*r)*exp(2*r) + (1 + r)*exp(r)), where r = LambertW(2*n)/2 - 1/(1 + 2/LambertW(2*n) + n^(1/2) * (1 + LambertW(2*n)) * (2/LambertW(2*n))^(3/2)). - Vaclav Kotesovec, Jul 03 2022
a(n) ~ (2*n/LambertW(2*n))^n * exp(n/LambertW(2*n) + (2*n/LambertW(2*n))^(1/2) - n - 7/4) / sqrt(1 + LambertW(2*n)). - Vaclav Kotesovec, Jul 10 2022

Extensions

Edited by Franklin T. Adams-Watters, Jul 09 2009

A162663 Table by antidiagonals, T(n,k) is the number of partitions of {1..(nk)} that are invariant under a permutation consisting of n k-cycles.

Original entry on oeis.org

1, 1, 1, 1, 2, 2, 1, 2, 7, 5, 1, 3, 8, 31, 15, 1, 2, 16, 42, 164, 52, 1, 4, 10, 111, 268, 999, 203, 1, 2, 28, 70, 931, 1994, 6841, 877, 1, 4, 12, 258, 602, 9066, 16852, 51790, 4140, 1, 3, 31, 106, 2892, 6078, 99925, 158778, 428131, 21147, 1, 4, 22, 329, 1144, 37778, 70402, 1224579, 1644732, 3827967, 115975
Offset: 0

Views

Author

Keywords

Comments

The upper left corner of the array is T(0,1).
Without loss of generality, the permutation can be taken to be (1 2 ... k) (k+1 k+2 ... 2k) ... ((n-1)k+1 (n-1)k+2 ... nk).
Note that it is the partition that is invariant, not the individual parts. Thus for n=k=2 with permutation (1 2)(3 4), the partition 1,3|2,4 is counted; it maps to 2,4|1,3, which is the same partition.

Examples

			The table starts:
   1,   1,   1,   1,   1
   1,   2,   2,   3,   2
   2,   7,   8,  16,  10
   5,  31,  42, 111,  70
  15, 164, 268, 931, 602
		

Crossrefs

Programs

  • Maple
    with(numtheory):
    A:= proc(n, k) option remember; `if`(n=0, 1, add(binomial(n-1, j-1)
           *add(d^(j-1), d=divisors(k))*A(n-j, k), j=1..n))
        end:
    seq(seq(A(n, 1+d-n), n=0..d), d=0..12);  # Alois P. Heinz, Oct 29 2015
  • Mathematica
    max = 11; ClearAll[col]; col[k_] := col[k] =  CoefficientList[ Series[ Exp[ Sum[ (Exp[d*x] - 1)/d, {d, Divisors[k]}]], {x, 0, max}], x]*Range[0, max]!; t[n_, k_] := col[k][[n]]; Flatten[ Table[ t[n-k+1, k], {n, 1, max}, {k, n, 1, -1}] ] (* Jean-François Alcover, Aug 08 2012, after e.g.f. *)
  • PARI
    amat(n,m)=local(r);r=matrix(n,m,i,j,1);for(k=1,n-1,for(j=1,m,r[k+1,j]=sum (i=1,k,binomial(k-1,i-1)*sumdiv(j,d,r[k-i+1,j]*d^(i-1)))));r
    acol(n,k)=local(fn);fn=exp(sumdiv(k,d,(exp(d*x+x*O(x^n))-1)/d));vector(n+ 1,i,polcoeff(fn,i-1)*(i-1)!)

Formula

E.g.f. for column k: exp(Sum_{d|k} (exp(d*x) - 1) / d).
Equivalently, column k is the exponential transform of a(n) = Sum_{d|k} d^(n-1); this represents a set of n k-cycles, each repeating the same d elements (parts), but starting in different places.
T(n,k) = Sum_{P a partition of n} SP(P) * Product_( (sigma_{i-1}(k))^(P(i)-1) ), where SP is A036040 or A080575, and P(i) is the number of parts in P of size i.
T(n,k) = Sum_{j=0..n-1} A036073(n,j)*k^(n-1-j). - Andrey Zabolotskiy, Oct 22 2017

Extensions

Offset set to 0 by Alois P. Heinz, Oct 29 2015

A002875 Sorting numbers (see Motzkin article for details).

Original entry on oeis.org

1, 2, 4, 24, 128, 880, 7440
Offset: 0

Views

Author

Keywords

Comments

How is the sequence defined (see the links in A000262)? Also more terms would be welcome.
Based on the Motzkin article, where this sequence appears in the last row of the table on p. 173, one would expect that this sequence is the same as A294202. However, they seem to be unrelated. So the true definition of this sequence is a mystery. - Andrew Howroyd and Andrey Zabolotskiy, Oct 25 2017

References

  • 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

A036074 Expansion of e.g.f. exp((exp(p*x) - p - 1)/p + exp(x)) for p=4.

Original entry on oeis.org

1, 2, 9, 55, 412, 3619, 36333, 408888, 5080907, 68914023, 1011165446, 15935379409, 268125052373, 4792458452162, 90605469012877, 1805135197261131, 37775862401203916, 827992670793489263
Offset: 0

Views

Author

Keywords

References

  • T. S. Motzkin, Sorting numbers for cylinders and other classification numbers, in Combinatorics, Proc. Symp. Pure Math. 19, AMS, 1971, pp. 167-176.
  • T. S. Motzkin, Sorting numbers ...: for a link to an annotated scanned version of this paper see A000262.

Crossrefs

Programs

  • Mathematica
    mx = 16; p = 4; Range[0, mx]! CoefficientList[ Series[ Exp[ (Exp[p*x] - p - 1)/p + Exp[x]], {x, 0, mx}], x] (* Robert G. Wilson v, Dec 12 2012 *)
    Table[Sum[Binomial[n,k] * 4^k * BellB[k, 1/4] * BellB[n-k], {k, 0, n}], {n, 0, 20}] (* Vaclav Kotesovec, Jun 29 2022 *)
  • Maxima
    a(n):=sum(sum(binomial(m,i)*sum(binomial(i,j)*(1/4)^j*(3*j+i)^n,j,0,i)*(-5/4)^(m-i),i,0,m)/m!,m,1,n); /* Vladimir Kruchinin, Sep 14 2010 */

Formula

a(n) = sum(sum(binomial(m,i)*sum(binomial(i,j)*(1/4)^j*(3*j+i)^n,j,0,i)*(-5/4)^(m-i),i,0,m)/m!,m,1,n), n > 0. - Vladimir Kruchinin, Sep 14 2010
a(n) ~ exp(exp(p*r)/p + exp(r) - 1 - 1/p - n) * (n/r)^(n + 1/2) / sqrt((1 + p*r)*exp(p*r) + (1 + r)*exp(r)), where r = LambertW(p*n)/p - 1/(1 + p/LambertW(p*n) + n^(1 - 1/p) * (1 + LambertW(p*n)) * (p/LambertW(p*n))^(2 - 1/p)) for p=4. - Vaclav Kotesovec, Jul 03 2022
a(n) ~ (4*n/LambertW(4*n))^n * exp(n/LambertW(4*n) + (4*n/LambertW(4*n))^(1/4) - n - 5/4) / sqrt(1 + LambertW(4*n)). - Vaclav Kotesovec, Jul 10 2022

Extensions

Edited by N. J. A. Sloane, Jul 11 2008 at the suggestion of Franklin T. Adams-Watters

A084708 Number of set partitions up to rotations and reflections.

Original entry on oeis.org

1, 2, 3, 7, 12, 37, 93, 354, 1350, 6351, 31950, 179307, 1071265, 6845581, 46162583, 327731950, 2437753740, 18948599220, 153498350745, 1293123243928, 11306475314467, 102425554299516, 959826755336242, 9290811905391501
Offset: 1

Views

Author

Wouter Meeussen, Jul 02 2003

Keywords

Comments

Combines the symmetry operations of A080107 and A084423.
Equivalently, number of n-bead bracelets using any number of unlabeled (interchangable) colors. - Andrew Howroyd, Sep 25 2017

Examples

			SetPartitions[6] is the first to decompose differently from A084423: 4 cycles of length 1, 2 of 2, 9 of 3, 16 of 6, 6 of 12.
a(7) = 1 + A056357(7) + A056358(7) + A056359(7) + A056360(7) + A056361(7) + 1 = 1 + 8 + 31 + 33 + 16 + 3 + 1 = 93.
		

Crossrefs

Programs

  • Mathematica
    <A080107 *); Table[{Length[ # ], First[ # ]}&/@ Split[Sort[Length/@Split[Sort[First[Sort[Flatten[ {#, Map[Sort, (#/. i_Integer:>w+1-i), 2]}& @(NestList[Sort[Sort/@(#/. i_Integer :> Mod[i+1, w, 1])]&, #, w]), 1]]]&/@SetPartitions[w]]]]], {w, 1, 10}]
    u[0,j_]:=1;u[k_,j_]:=u[k,j]=Sum[Binomial[k-1,i-1]Plus@@(u[k-i,j]#^(i-1)&/@Divisors[j]),{i,k}]; a[n_]:=1/n*Plus@@(EulerPhi[ # ]u[Quotient[n,# ],# ]&/@Divisors[n]); Table[a[n]/2+If[EvenQ[n],u[n/2,2],Sum[Binomial[n/2-1/2,k] u[k,2], {k,0,n/2-1/2}]]/2,{n,40}] (* Wouter Meeussen, Dec 06 2008 *)

Formula

a(n) = (A080107(n)+A084423(n))/2. - Wouter Meeussen and Vladeta Jovovic, Nov 28 2008

Extensions

a(12) from Vladeta Jovovic, Jul 15 2007
More terms from Vladeta Jovovic's formula given in Mathematica line. - Wouter Meeussen, Dec 06 2008

A036075 The number of partitions of {1..5n} that are invariant under a permutation consisting of n 5-cycles.

Original entry on oeis.org

1, 2, 10, 70, 602, 6078, 70402, 917830, 13253002, 209350350, 3584098770, 66012131222, 1300004931162, 27232369503902, 604103160535330, 14136908333006822, 347827448896896554, 8971450949011952494
Offset: 0

Views

Author

Keywords

Comments

Original name: Sorting numbers.

Crossrefs

u[n,j] generates for j=1, A000110 Bell numbers; j=2, A002872; j=3, A002874; j=4, A141003 (Mathar); j=5, this sequence; j=6, A141004 (Mathar); j=7, A036077. - Wouter Meeussen, Dec 06 2008
Column 5 of A162663.

Programs

  • Mathematica
    u[0,j_]:=1;u[k_,j_]:=u[k,j]=Sum[Binomial[k-1,i-1]Plus@@(u[k-i,j]#^(i-1)&/@Divisors[j]),{i,k}]; Table[u[n,5],{n,0,12}] (* Wouter Meeussen, Dec 06 2008 *)
    mx = 16; p = 5; Range[0, mx]! CoefficientList[ Series[ Exp[ (Exp[p*x] - p - 1)/p + Exp[x]], {x, 0, mx}], x] (* Robert G. Wilson v, Dec 12 2012 *)
    Table[Sum[Binomial[n,k] * 5^k * BellB[k, 1/5] * BellB[n-k], {k, 0, n}], {n, 0, 20}] (* Vaclav Kotesovec, Jun 29 2022 *)

Formula

E.g.f.: exp((exp(p*x)-p-1)/p+exp(x)) for p=5.
a(n) ~ exp(exp(p*r)/p + exp(r) - 1 - 1/p - n) * (n/r)^(n + 1/2) / sqrt((1 + p*r)*exp(p*r) + (1 + r)*exp(r)), where r = LambertW(p*n)/p - 1/(1 + p/LambertW(p*n) + n^(1 - 1/p) * (1 + LambertW(p*n)) * (p/LambertW(p*n))^(2 - 1/p)) for p=5. - Vaclav Kotesovec, Jul 03 2022
a(n) ~ (5*n/LambertW(5*n))^n * exp(n/LambertW(5*n) + (5*n/LambertW(5*n))^(1/5) - n - 6/5) / sqrt(1 + LambertW(5*n)). - Vaclav Kotesovec, Jul 10 2022

Extensions

New name from Danny Rorabaugh, Oct 24 2015

A036077 The number of partitions of {1..7n} that are invariant under a permutation consisting of n 7-cycles.

Original entry on oeis.org

1, 2, 12, 106, 1144, 14434, 209736, 3451290, 63194936, 1269555762, 27700698344, 651497885482, 16414347638936, 440651469115394, 12546081858835528, 377328994871025210, 11946046637611280120
Offset: 0

Views

Author

Keywords

Comments

Original name: Sorting numbers.

Crossrefs

u[n,j] generates for j=1, A000110; j=2, A002872; j=3, A002874; j=4, A141003; j=5, A036075; j=6, A141004; j=7, this sequence. - Wouter Meeussen, Dec 06 2008
Column 7 of A162663.

Programs

  • Mathematica
    u[0,j_]:=1;u[k_,j_]:=u[k,j]=Sum[Binomial[k-1,i-1]Plus@@(u[k-i,j]#^(i-1)&/@Divisors[j]),{i,k}]; Table[u[n,7],{n,0,12}] (* Wouter Meeussen, Dec 06 2008 *)
    mx = 16; p = 7; Range[0, mx]! CoefficientList[ Series[ Exp[ (Exp[p*x] - p - 1)/p + Exp[x]], {x, 0, mx}], x] (* Robert G. Wilson v, Dec 12 2012 *)
    Table[Sum[Binomial[n,k] * 7^k * BellB[k, 1/7] * BellB[n-k], {k, 0, n}], {n, 0, 20}] (* Vaclav Kotesovec, Jun 29 2022 *)

Formula

E.g.f.: exp((exp(p*x)-p-1)/p+exp(x)) for p=7.
a(n) ~ exp(exp(p*r)/p + exp(r) - 1 - 1/p - n) * (n/r)^(n + 1/2) / sqrt((1 + p*r)*exp(p*r) + (1 + r)*exp(r)), where r = LambertW(p*n)/p - 1/(1 + p/LambertW(p*n) + n^(1 - 1/p) * (1 + LambertW(p*n)) * (p/LambertW(p*n))^(2 - 1/p)) for p=7. - Vaclav Kotesovec, Jul 03 2022
a(n) ~ (7*n/LambertW(7*n))^n * exp(n/LambertW(7*n) + (7*n/LambertW(7*n))^(1/7) - n - 8/7) / sqrt(1 + LambertW(7*n)). - Vaclav Kotesovec, Jul 10 2022

Extensions

New name from Danny Rorabaugh, Oct 24 2015

A141004 Expansion of e.g.f. exp(Sum_{d|6} (exp(d*x)-1)/d).

Original entry on oeis.org

1, 4, 28, 258, 2892, 37778, 560124, 9256010, 168182044, 3325057826, 70934634236, 1621828212826, 39517131361884, 1021237022557682, 27877344103738940, 800976143703407210, 24148078430008534428, 761815206361252780098, 25087729474993723079548
Offset: 0

Views

Author

R. J. Mathar, Jul 11 2008

Keywords

Crossrefs

u[n,j] generates for j=1, A000110 Bell numbers; j=2, A002872 "Sorting numbers"; j=3, A002874 "Sorting numbers"; j=4, A141003 (Mathar); j=5, A036075 "Sorting numbers"; j=6, A141004 (Mathar); j=7, A036077 "Sorting numbers". - Wouter Meeussen, Dec 06 2008
Column k=6 of A162663.

Programs

  • Mathematica
    u[0,j_]:=1;u[k_,j_]:=u[k,j]=Sum[Binomial[k-1,i-1]Plus@@(u[k-i,j]#^(i-1)&/@Divisors[j]),{i,k}]; Table[u[n,6],{n,0,18}] (* Wouter Meeussen, Dec 06 2008 *)

A294201 Irregular triangle read by rows: T(n,k) is the number of k-partitions of {1..3n} that are invariant under a permutation consisting of n 3-cycles (1 <= k <= 3n).

Original entry on oeis.org

1, 0, 1, 1, 1, 3, 2, 0, 1, 1, 3, 10, 12, 3, 9, 3, 0, 1, 1, 7, 33, 59, 30, 67, 42, 6, 18, 4, 0, 1, 1, 15, 106, 270, 216, 465, 420, 120, 235, 100, 10, 30, 5, 0, 1, 1, 31, 333, 1187, 1365, 3112, 3675, 1596, 2700, 1655, 330, 605, 195, 15, 45, 6, 0, 1
Offset: 1

Views

Author

Andrew Howroyd, Oct 24 2017

Keywords

Comments

T(n,k) = coefficient of x^k for A(3,n)(x) in Gilbert and Riordan's article. - Robert A. Russell, Jun 13 2018

Examples

			Triangle begins:
  1,  0,   1;
  1,  1,   3,   2,   0,   1;
  1,  3,  10,  12,   3,   9,   3,   0,   1;
  1,  7,  33,  59,  30,  67,  42,   6,  18,   4,  0,  1;
  1, 15, 106, 270, 216, 465, 420, 120, 235, 100, 10, 30, 5, 0, 1;
  ...
Case n=2: Without loss of generality the permutation of two 3-cycles can be taken as (123)(456). The second row is [1, 1, 3, 2, 0, 1] because the set partitions that are invariant under this permutation in increasing order of number of parts are {{1, 2, 3, 4, 5, 6}}; {{1, 2, 3}, {4, 5, 6}}; {{1, 4}, {2, 5}, {3, 6}}, {{1, 5}, {2, 6}, {3, 4}}, {{1, 6}, {2, 4}, {3, 5}}; {{1, 2, 3}, {4}, {5}, {6}}, {{1}, {2}, {3}, {4, 5, 6}}, {{1}, {2}, {3}, {4}, {5}, {6}}.
		

Crossrefs

Row sums are A002874.
Column k=3 gives A053156.
Maximum row values are A294202.
Unrelated to A002875.

Programs

  • Maple
    T:= proc(n, k) option remember; `if`([n, k]=[0, 0], 1, 0)+
         `if`(n>0 and k>0, k*T(n-1, k)+T(n-1, k-1)+T(n-1, k-3), 0)
        end:
    seq(seq(T(n, k), k=1..3*n), n=1..8);  # Alois P. Heinz, Sep 20 2019
  • Mathematica
    T[n_, k_] := T[n,k] = If[n>0 && k>0, k T[n-1,k] + T[n-1,k-1] + T[n-1,k-3], Boole[n==0 && k==0]] (* modification of Gilbert & Riordan recursion *)
    Table[T[n, k], {n,1,10}, {k,1,3n}] // Flatten (* Robert A. Russell, Jun 13 2018 *)
  • PARI
    \\ see A056391 for Polya enumeration functions
    T(n,k)={my(ci=PermCycleIndex(CylinderPerms(3,n)[2])); StructsByCycleIndex(ci,k) - if(k>1,StructsByCycleIndex(ci,k-1))}
    for (n=1, 6, for(k=1, 3*n, print1(T(n,k), ", ")); print);
    
  • PARI
    G(n)={Vec(-1+serlaplace(exp(sumdiv(3, d, y^d*(exp(d*x + O(x*x^n))-1)/d))))}
    { my(A=G(6)); for(n=1, #A, print(Vecrev(A[n]/y))) } \\ Andrew Howroyd, Sep 20 2019

Formula

T(n,k) = [n==0 & k==0] + [n>0 & k>0] * (k*T(n-1,k) + T(n-1,k-1) + T(n-1,k-3)). - Robert A. Russell, Jun 13 2018
T(n,k) = n!*[x^n*y^k] exp(Sum_{d|3} y^d*(exp(d*x) - 1)/d). - Andrew Howroyd, Sep 20 2019
Showing 1-10 of 16 results. Next