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

A322384 Number T(n,k) of entries in the k-th cycles of all permutations of [n] when cycles are ordered by decreasing lengths (and increasing smallest elements); triangle T(n,k), n>=1, 1<=k<=n, read by rows.

Original entry on oeis.org

1, 3, 1, 13, 4, 1, 67, 21, 7, 1, 411, 131, 46, 11, 1, 2911, 950, 341, 101, 16, 1, 23563, 7694, 2871, 932, 197, 22, 1, 213543, 70343, 26797, 9185, 2311, 351, 29, 1, 2149927, 709015, 275353, 98317, 27568, 5119, 583, 37, 1, 23759791, 7867174, 3090544, 1141614, 343909, 73639, 10366, 916, 46, 1
Offset: 1

Views

Author

Alois P. Heinz, Dec 05 2018

Keywords

Examples

			The 6 permutations of {1,2,3} are:
  (1)     (2) (3)
  (1,2)   (3)
  (1,3)   (2)
  (2,3)   (1)
  (1,2,3)
  (1,3,2)
so there are 13 elements in the first cycles, 4 in the second cycles and only 1 in the third cycles.
Triangle T(n,k) begins:
       1;
       3,     1;
      13,     4,     1;
      67,    21,     7,    1;
     411,   131,    46,   11,    1;
    2911,   950,   341,  101,   16,   1;
   23563,  7694,  2871,  932,  197,  22,  1;
  213543, 70343, 26797, 9185, 2311, 351, 29, 1;
  ...
		

Crossrefs

Row sums give A001563.
T(2n,n) gives A332928.

Programs

  • Maple
    b:= proc(n, l) option remember; `if`(n=0, add(l[-i]*
          x^i, i=1..nops(l)), add(binomial(n-1, j-1)*
          b(n-j, sort([l[], j]))*(j-1)!, j=1..n))
        end:
    T:= n-> (p-> (seq(coeff(p, x, i), i=1..n)))(b(n, [])):
    seq(T(n), n=1..12);
  • Mathematica
    b[n_, l_] := b[n, l] = If[n == 0, Sum[l[[-i]]*x^i, {i, 1, Length[l]}], Sum[Binomial[n-1, j-1]*b[n-j, Sort[Append[l, j]]]*(j-1)!, {j, 1, n}]];
    T[n_] := CoefficientList[b[n, {}], x] // Rest;
    Array[T, 12] // Flatten  (* Jean-François Alcover, Feb 26 2020, after Alois P. Heinz *)

A350273 Irregular triangle read by rows: T(n,k) is the number of n-permutations whose fourth-longest cycle has length exactly k; n >= 0, 0 <= k <= floor(n/4).

Original entry on oeis.org

1, 1, 2, 6, 23, 1, 109, 11, 619, 101, 4108, 932, 31240, 8975, 105, 268028, 91387, 3465, 2562156, 991674, 74970, 27011016, 11514394, 1391390, 311378616, 143188574, 24188010, 246400, 3897004032, 1905067958, 412136010, 12812800, 52626496896, 27059601596, 7053834788, 438357920
Offset: 0

Views

Author

Steven Finch, Dec 22 2021

Keywords

Comments

If the permutation has no fourth cycle, then its fourth-longest cycle is defined to have length 0.

Examples

			Triangle begins:
[0]      1;
[1]      1;
[2]      2;
[3]      6;
[4]     23,     1;
[5]    109,    11;
[6]    619,   101;
[7]   4108,   932;
[8]  31240,  8975,  105;
[9] 268028, 91387, 3465;
    ...
		

Crossrefs

Programs

  • Maple
    b:= proc(n, l) option remember; `if`(n=0, x^l[1], add((j-1)!*
          b(n-j, sort([l[], j])[2..5])*binomial(n-1, j-1), j=1..n))
        end:
    T:= n-> (p-> seq(coeff(p, x, i), i=0..degree(p)))(b(n, [0$4])):
    seq(T(n), n=0..14);  # Alois P. Heinz, Dec 22 2021
  • Mathematica
    b[n_, l_] := b[n, l] = If[n == 0, x^l[[1]], Sum[(j - 1)!*b[n - j, Sort[ Append[l, j]][[2 ;; 5]]]*Binomial[n - 1, j - 1], {j, 1, n}]];
    T[n_] := With[{p = b[n, {0, 0, 0, 0}]}, Table[Coefficient[p, x, i], {i, 0, Exponent[p, x]}]];
    Table[T[n], {n, 0, 14}] // Flatten (* Jean-François Alcover, Dec 29 2021, after Alois P. Heinz *)

Formula

Sum_{k=0..floor(n/4)} k * T(n,k) = A332853(n) for n >= 4.

Extensions

More terms from Alois P. Heinz, Dec 22 2021
Showing 1-2 of 2 results.