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.

A344855 Number T(n,k) of permutations of [n] having k cycles of the form (c1, c2, ..., c_m) where c1 = min_{i>=1} c_i and c_j = min_{i>=j} c_i or c_j = max_{i>=j} c_i; triangle T(n,k), n>=0, 0<=k<=n, read by rows.

Original entry on oeis.org

1, 0, 1, 0, 1, 1, 0, 2, 3, 1, 0, 4, 11, 6, 1, 0, 8, 40, 35, 10, 1, 0, 16, 148, 195, 85, 15, 1, 0, 32, 560, 1078, 665, 175, 21, 1, 0, 64, 2160, 5992, 5033, 1820, 322, 28, 1, 0, 128, 8448, 33632, 37632, 17913, 4284, 546, 36, 1, 0, 256, 33344, 190800, 280760, 171465, 52941, 9030, 870, 45, 1
Offset: 0

Views

Author

Alois P. Heinz, May 30 2021

Keywords

Comments

The sequence of column k satisfies a linear recurrence with constant coefficients of order k*(k+1)/2 = A000217(k).

Examples

			T(4,1) = 4: (1234), (1243), (1423), (1432).
Triangle T(n,k) begins:
  1;
  0,  1;
  0,  1,    1;
  0,  2,    3,    1;
  0,  4,   11,    6,    1;
  0,  8,   40,   35,   10,    1;
  0, 16,  148,  195,   85,   15,   1;
  0, 32,  560, 1078,  665,  175,  21,  1;
  0, 64, 2160, 5992, 5033, 1820, 322, 28, 1;
  ...
		

Crossrefs

Row sums give A187251.
Main diagonal gives A000012, lower diagonal gives A000217, second lower diagonal gives A000914.
T(n+1,n) gives A000217.
T(n+2,n) gives A000914.
T(2n,n) gives A345342.

Programs

  • Maple
    b:= proc(n) option remember; `if`(n=0, 1, add(expand(x*
          b(n-j)*binomial(n-1, j-1)*ceil(2^(j-2))), j=1..n))
        end:
    T:= n-> (p-> seq(coeff(p, x, i), i=0..n))(b(n)):
    seq(T(n), n=0..12);
  • Mathematica
    b[n_] := b[n] = If[n == 0, 1, Sum[Expand[x*b[n-j]*
         Binomial[n-1, j-1]*Ceiling[2^(j-2)]], {j, n}]];
    T[n_] := CoefficientList[b[n], x];
    Table[T[n], {n, 0, 12}] // Flatten (* Jean-François Alcover, Aug 23 2021, after Alois P. Heinz *)

Formula

Sum_{k=1..n} k * T(n,k) = A345341(n).
For fixed k, T(n,k) ~ (2*k)^n / (4^k * k!). - Vaclav Kotesovec, Jul 15 2021

A211602 Number of binary increasing trees with n nodes and "min-path" of length 3.

Original entry on oeis.org

0, 1, 3, 7, 20, 70, 287, 1356, 7248
Offset: 2

Views

Author

N. J. A. Sloane, May 11 2012

Keywords

Crossrefs

A diagonal of A186366.

A344445 Number of cycle-up-down permutations of [2n] having n cycles.

Original entry on oeis.org

1, 1, 7, 105, 2345, 69405, 2559667, 113073961, 5820788545, 342176336073, 22616620648895, 1660292619682697, 134029227728536985, 11800452870718122325, 1125324001129006580475, 115551341953019187183225, 12711056625162235880359425, 1491325482312555276046069905
Offset: 0

Views

Author

Alois P. Heinz, May 19 2021

Keywords

Comments

For the definition of cycle-up-down permutations see A186366.

Examples

			a(2) = 7: (1)(243), (143)(2), (142)(3), (132)(4), (12)(34), (13)(24), (14)(23).
		

Crossrefs

Programs

  • Maple
    b:= proc(u, o) option remember; `if`(u+o=0, 1,
          add(b(o-1+j, u-j), j=1..u))
        end:
    g:= proc(n) option remember; expand(`if`(n=0, 1,
          add(g(n-j)*binomial(n-1, j-1)*x*b(j-1, 0), j=1..n)))
        end:
    a:= n-> coeff(g(2*n), x, n):
    seq(a(n), n=0..18);
  • Mathematica
    Join[{1}, Table[Sum[2^(2*n - 2*j + 1) * StirlingS1[2*j,n] * Sum[(-1)^k * k^(2*n) / ((j+k)!*(j-k)!), {k, 0, j}], {j, Floor[n/2], n}], {n, 1, 20}]] (* Vaclav Kotesovec, May 22 2021 *)

Formula

a(n) = (2n)! * [x^(2n) y^n] 1/(1-sin(x))^y.
a(n) = A186366(2n,n).
a(n) ~ c * d^n * (n-1)!, where d = 7.3270710411718682766548233722838416956334898839746535623751... and c = 0.14278148012337362269164226210064788025688590260058738... - Vaclav Kotesovec, May 22 2021

A344532 Number of cycle-up-down permutations of [n^2] having n cycles.

Original entry on oeis.org

1, 1, 7, 14698, 51629528080, 914192102910317528125, 199979553262025879510473132453855232, 1131253316618666789979709230473744963049785439771172168, 309491168658231587025767619097898747214052900521443034546657433273562730332160
Offset: 0

Views

Author

Alois P. Heinz, May 22 2021

Keywords

Comments

For the definition of cycle-up-down permutations see A186366.

Examples

			a(2) = 7: (1)(243), (143)(2), (142)(3), (132)(4), (12)(34), (13)(24), (14)(23).
		

Crossrefs

Programs

  • Maple
    b:= proc(u, o) option remember; `if`(u+o=0, 1,
          add(b(o-1+j, u-j), j=1..u))
        end:
    g:= proc(n) option remember; expand(`if`(n=0, 1,
          add(g(n-j)*binomial(n-1, j-1)*x*b(j-1, 0), j=1..n)))
        end:
    a:= n-> coeff(g(n^2), x, n):
    seq(a(n), n=0..9);
  • Mathematica
    b[u_, o_] := b[u, o] = If[u+o == 0, 1, Sum[b[o-1+j, u-j], {j, 1, u}]];
    g[n_] := g[n] = Expand[If[n == 0, 1,
         Sum[g[n-j]*Binomial[n-1, j-1]*x*b[j-1, 0], {j, 1, n}]]];
    a[n_] := Coefficient[g[n^2], x, n];
    a /@ Range[0, 9] (* Jean-François Alcover, Jun 10 2021, after Alois P. Heinz *)

Formula

a(n) = (n^2)! * [x^(n^2) y^n] 1/(1-sin(x))^y.
a(n) = A186366(n^2,n).

A186367 Number of cycles in all cycle-up-down permutations of {1,2,...,n}. A permutation is said to be cycle-up-down if it is a product of up-down cycles. A cycle (b(1), b(2), ...) is said to be up-down if, when written with its smallest element in the first position, it satisfies b(1)b(3)<... .

Original entry on oeis.org

1, 3, 10, 38, 165, 812, 4478, 27408, 184529, 1356256, 10809786, 92892928, 856329253, 8430600960, 88292571934, 980197173248, 11499036105537, 142147625652224, 1846872283846922, 25161923756064768, 358706981125488581, 5340498034862030848
Offset: 1

Views

Author

Emeric Deutsch, Feb 28 2011

Keywords

Examples

			a(3) = 10 because the cycle-up-down permutations (1)(2)(3), (12)(3), (13)(2), (1)(23), and (132), have a total of 3+2+2+2+1=10 cycles.
		

Crossrefs

Cf. A186366.

Programs

  • Maple
    g := -ln(1-sin(z))/(1-sin(z)): gser := series(g, z = 0, 25): seq(factorial(n)*coeff(gser, z, n), n = 1 .. 22);
  • Mathematica
    Rest[CoefficientList[Series[-Log[1-Sin[x]]/(1-Sin[x]), {x, 0, 20}], x]* Range[0, 20]!] (* Vaclav Kotesovec, Oct 02 2013 *)
  • PARI
    x='x+O('x^30); Vec(serlaplace(-log(1-sin(x))/(1-sin(x)))) \\ G. C. Greubel, Aug 30 2018

Formula

E.g.f.: -log(1-sin(z)) / (1-sin(z)).
a(n) = Sum_{k=1..n} k*A186366(n,k).
a(n) ~ n!*n*2^(n+3)/Pi^(n+2)*(2*log(n/Pi) + 2*gamma + 3*log(2) - 2), where gamma is the Euler-Mascheroni constant (A001620). - Vaclav Kotesovec, Oct 02 2013

A212258 Number of binary increasing trees with n nodes and "min-path" of length 4.

Original entry on oeis.org

0, 0, 1, 6, 25, 105, 490, 2548, 14698, 93420, 649715, 4912776, 40154387, 352937312, 3320636540, 33305992320, 354819046132, 4001699525376, 47637151241125, 596958623741440, 7855611484697773, 108314507544748032, 1561635447992241230, 23498865431367684096
Offset: 2

Views

Author

N. J. A. Sloane, May 11 2012

Keywords

Crossrefs

A diagonal of A186366.

Extensions

More terms from Alois P. Heinz, Apr 03 2014

A212259 Number of binary increasing trees with n nodes and "min-path" of length 5.

Original entry on oeis.org

0, 0, 0, 1, 10, 65, 385, 2345, 15204, 105880, 793210, 6382860, 55020966, 506505272, 4963812035, 51629528080, 568303728360, 6602266433920, 80751432154868, 1037402030622720, 13968636570706370, 196748236140538368, 2893482720437769317, 44355269272024284160
Offset: 2

Views

Author

N. J. A. Sloane, May 11 2012

Keywords

Crossrefs

A diagonal of A186366.

Extensions

More terms from Alois P. Heinz, Apr 03 2014
Showing 1-7 of 7 results.