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.

Previous Showing 11-18 of 18 results.

A008971 Triangle read by rows: T(n,k) is the number of permutations of [n] with k increasing runs of length at least 2.

Original entry on oeis.org

1, 1, 1, 1, 1, 5, 1, 18, 5, 1, 58, 61, 1, 179, 479, 61, 1, 543, 3111, 1385, 1, 1636, 18270, 19028, 1385, 1, 4916, 101166, 206276, 50521, 1, 14757, 540242, 1949762, 1073517, 50521, 1, 44281, 2819266, 16889786, 17460701, 2702765, 1, 132854, 14494859
Offset: 0

Views

Author

Keywords

Comments

Row n has 1+floor(n/2) terms.
T(n,k) is also the number of permutations of [n] with k "exterior peaks" where we count peaks in the usual way, but add a peak at the beginning if the permutation begins with a descent, e.g. 213 has one exterior peak. T(3,1) = 5 since all permutations of [3] have an exterior peak except 123. This is also the definition for peaks of signed permutations, where we assume that a signed permutation always begins with a zero. - Kyle Petersen, Jan 14 2005
From Petros Hadjicostas, Aug 09 2019: (Start)
In their book, David and Barton (1962) use the notation T_{N,v*}^* for this array, where N is the length of the permutation and v* is the so-called "number of runs up" in the permutation. In modern terminology, a "run up" in a permutation is an increasing run of length >= 2. See their discussion on p. 154 of their book and see p. 163 for the definition of T_{N,v*}^*.
They do not consider as "runs up" single elements b_i in a permutation b = (b_1, b_2, ..., b_n) even if they satisfy b_{i-1} > b_i > b_{i+1} (with b_{n-1} > b_n when i = n and b_1 > b_2 when i = 1). (The command Runs[b] for permutation b in Mathematica, using the package Combinatorica`, will generate not only the "runs up" of b but also the single elements in the permutation b that satisfy one of the above inequalities. For example, Runs[{3,2,1}] gives the set of runs {{3}, {2}, {1}}, none of which is a "run up".)
So, here n = N and k = v*. On p. 163 of their book they give the recurrence shown below in the FORMULA section from Charalambides' (2002) book: T(n+1, k) = (2*k + 1) * T(n,k) + (n - 2*k + 2) * T(n, k-1) for n >= 0 and 1 <= k <= floor(n/2) + 1. The values of T_{N,v*}^* = T(n, k) appear in Table 10.5 (p. 163) of their book.
Since the complement of a permutation (b_1, b_2, ..., b_n) is (n+1-b_1, n+1-b_2, ..., n+1-b_n), it is clear that the current array T(n, k) is also the number of permutations of [n] with k decreasing runs of length >= 2 (i.e., the number of permutations of [n] with k "runs down" according to David and Barton (1962)).
Note that the number of permutations of [n] with k runs of length >= 2 that are either increasing or decreasing (i.e., the number of permutations of [n] that contain k "runs up" and "runs down" in total) is given by array A059427. One half of array A059427 is given in Table 10.4 (p. 159) in David and Barton (1962)--see also array A008970.
A run that is either a "run up" or "run down" (i.e., an ascending or a descending run of length >= 2) is called "séquence" by André (19th century) and Comtet (1974). See the references for sequence A000708 or for array A059427. (Again, recall that David and Barton do not consider single numbers as either a "run up" or a "run down".)
Morley (1897) proved that in a permutation of [n], #("runs up") + #("runs down") + #(monotonic triplets of adjacent numbers in the permutation) = n - 1. (His definition of a run is highly non-standard!) See the example below.
The number Q(n,k) of circular permutations of [n] that contain k runs that are either "runs up" or "runs down" (that is, k ascending or descending runs of length >= 2) is given by array A008303. More precisely, Q(n+1, 2*(k+1)) = A008303(n, k) for n >= 1 and 0 <= k <= ceiling(n/2)-1. In addition, Q(n, s) = 0 when either s is odd, or n <= 1, or s > n. Also, Q_{n,2} = 2^(n-2) for n >= 2.
The numbers in array A008303 appear in Table 10.6 (p. 163) in David and Barton (1962).
(End)

Examples

			Triangle T(n,k) (with rows n >= 0 and columns k >= 0) starts as follows:
  1;
  1;
  1,   1;
  1,   5;
  1,  18,       5;
  1,  58,      61;
  1, 179,     479,     61;
  1, 543,    3111,   1385;
  1, 1636,  18270,  19028,  1385;
  1, 4916, 101166, 206276, 50521;
  ...
Example: T(3,1) = 5 because all permutations of [3] with the exception of 321 have one increasing run of length at least 2.
From _Peter Bala_, Jan 23 2016: (Start)
Row 6: cos(x)^7*(d/dx)^6(1/cos(x)) = sin(x)^6 + 179*sin(x)^4 + 479*sin(x)^2 + 61.
Equivalently, (sqrt(1 - x^2))^7*D^6(1/sqrt(1 - x^2)) = x^6 + 179*x^4 + 479*x^2 + 61, where D = sqrt(1 - x^2)*d/dx. (End)
From _Petros Hadjicostas_, Aug 09 2019: (Start)
Consider the permutations of [4]. We list the increasing runs of length at least 2 (= "runs up"), the decreasing runs of length at least 2 (= "runs down"), and the monotonic triplets of adjacent numbers in the permutation (which we abbreviate to MTAN for simplicity). The sum of the numbers of these three should be n-1 (see Morley (1897) but notice that his use of the word "run" is highly non-standard).
1234 -> "runs up" = {1234}, "runs down" = {}, MTAN = {123, 234}.
1243 -> "runs up" = {124}, "runs down" = {43}, MTAN = {124}.
1324 -> "runs up" = {13, 24}, "runs down" = {32}, MTAN = {}.
1342 -> "runs up" = {134}, "runs down" = {42}, MTAN = {134}.
1423 -> "runs up" = {14, 23}, "runs down" = {42}, MTAN = {}.
1432 -> "runs up" = {14}, "runs down" = {432}, MTAN = {432}.
2134 -> "runs up" = {134}, "runs down" = {21}, MTAN = {134}.
2143 -> "runs up" = {14}, "runs down" = {21, 43}, MTAN = {}.
2314 -> "runs up" = {23, 14}, "runs down" = {31}, MTAN = {}.
2341 -> "runs up" = {234}, "runs down" = {41}, MTAN = {234}.
2413 -> "runs up" = {24, 13}, "runs down" = {41}, MTAN = {}.
2431 -> "runs up" = {24}, "runs down" = {431}, MTAN = {431}.
3124 -> "runs up" = {124}, "runs down" = {31}, MTAN = {124}.
3142 -> "runs up" = {14}, "runs down" = {31, 42}, MTAN = {}.
3214 -> "runs up" = {14}, "runs down" = {321}, MTAN = {321}.
3241 -> "runs up" = {24}, "runs down" = {32, 41}, MTAN = {}.
3412 -> "runs up" = {34, 12}, "runs down" = {41}, MTAN = {}.
3421 -> "runs up" = {34}, "runs down" = {421}, MTAN = {421}.
4123 -> "runs up" = {123}, "runs down" = {41}, MTAN = {123}.
4132 -> "runs up" = {13}, "runs down" = {41, 32}, MTAN = {}.
4213 -> "runs up" = {13}, "runs down" = {421}, MTAN = {421}.
4231 -> "runs up" = {23}, "runs down" = {42, 31}, MTAN = {}.
4312 -> "runs up" = {12}, "runs down" = {431}, MTAN = {431}.
4321 -> "runs up" = {}, "runs down" = {4321}, MTAN = {432, 321}.
If we let k = number of increasing runs of length >= 2 (= number of "runs up") in a permutation of [4], then (from above) the possible values of k are 0, 1, 2, and we have T(n=4, k=0) = 1, T(n=4, k=1) = 18, and T(n=4, k=2) = 5.
If we let k = number of decreasing runs of length >= 2 (= number of "runs down") in a permutation of [4], then again the possible values of k are 0, 1, 2, and we have T(n=4, k=0) = 1, T(n=4, k=1) = 18, and T(n=4, k=2) = 5.
Finally, note that if b_i, b_{i+1}, b_{i+2} is an increasing triplet of adjacent numbers in permutation b, then n+1-b_i, n+1-b_{i+1}, n+1-b_{i+2} is a decreasing triplet of adjacent numbers in the complement of b, and vice versa. For example, 4213 is the complement of 1342. Their set of monotonic triplets of adjacent numbers are {421} and {134}, respectively, and we have 4 + 1 = 2 + 3 = 1 + 4 = 5.
(End)
		

References

  • Ch. A. Charalambides, Enumerative Combinatorics, Chapman & Hall/CRC, Boca Raton, Florida, 2002.
  • F. N. David and D. E. Barton, Combinatorial Chance, Charles Griffin, 1962; see Table 10.5, p. 163.
  • F. N. David, M. G. Kendall and D. E. Barton, Symmetric Function and Allied Tables, Cambridge, 1966, p. 260.

Crossrefs

A160486 is a sub-triangle.
A000340, A000363, A000507 equal the second, third and fourth left hand columns.
T(2n,n) gives A000364.

Programs

  • Maple
    G:=sqrt(1-t)/(sqrt(1-t)*cosh(x*sqrt(1-t))-sinh(x*sqrt(1-t))): Gser:=simplify(series(G,x=0,15)): for n from 0 to 14 do P[n]:=sort(expand(n!*coeff(Gser,x,n))) od: seq(seq(coeff(t*P[n],t^k),k=1..1+floor(n/2)),n=0..14); # edited by Johannes W. Meijer, May 15 2009
    # second Maple program:
    T:= proc(n, k) option remember; `if`(k=0, 1, `if`(k>iquo(n, 2), 0,
          (2*k+1)*T(n-1, k) +(n+1-2*k)*T(n-1, k-1)))
        end:
    seq(seq(T(n, k), k=0..n/2), n=0..14); # Alois P. Heinz, Oct 16 2013
  • Mathematica
    t[n_, 0] = 1; t[n_, k_] /; k > Floor[n/2] = 0;
    t[n_ , k_ ] /; k <= Floor[n/2] := t[n, k] = (2 k + 1) t[n - 1, k] + (n - 2 k + 1) t[n - 1, k - 1];
    Flatten[Table[t[n, k], {n, 0, 12}, {k, 0, Floor[n/2]}]][[1 ;; 45]] (* Jean-François Alcover, May 30 2011, after given formula *)

Formula

E.g.f.: G(t,x) = sum(T(n,k) t^k x^n/n!, 0<=k<=floor(n/2), n>=0) = sqrt(1-t)/(sqrt(1-t)*cosh(x*sqrt(1-t))-sinh(x*sqrt(1-t))) (Ira M. Gessel).
T(n+1,k) = (2*k+1)*T(n,k) + (n-2*k+2)*T(n,k-1) (see p. 542 of the Charalambides reference or p. 163 in the David and Barton book).
G.f.: T(0)/(1-x), where T(k) = 1 - y*x^2*(k+1)^2/(y*x^2*(k+1)^2 - (1 -x -2*x*k)*(1 -3*x -2*x*k)/T(k+1) ); (continued fraction). - Sergei N. Gladkovskii, Nov 08 2013
From Peter Bala, Jan 23 2016: (Start)
cos(x)^(n+1)*(d/dx)^n(1/cos(x)) = Sum_{k = 0..floor(n/2)} T(n,k)*sin(x)^(n-2*k).
Equivalently, let D be the differential operator sqrt(1 - x^2)*d/dx. Then sqrt(1 - x^2)^(n+1)*D^n(1/sqrt(1 - x^2)) = Sum_{k = 0..floor(n/2)} T(n,k)*x^(n-2*k). (End)

Extensions

Edited by Emeric Deutsch and Ira M. Gessel, Aug 28 2004
Crossrefs added by Johannes W. Meijer, May 24 2009

A094503 Triangle read by rows: coefficients d(n,k) of Andre polynomials D(x,n) = Sum_{k>0} d(n,k)*x^k.

Original entry on oeis.org

1, 1, 1, 1, 1, 4, 1, 11, 4, 1, 26, 34, 1, 57, 180, 34, 1, 120, 768, 496, 1, 247, 2904, 4288, 496, 1, 502, 10194, 28768, 11056, 1, 1013, 34096, 166042, 141584, 11056, 1, 2036, 110392, 868744, 1372088, 349504, 1, 4083, 349500, 4247720, 11204160, 6213288
Offset: 1

Views

Author

Philippe Deléham, Jun 09 2004

Keywords

Comments

a(n,k) is the number of increasing 0-1-2 trees on [n] with k leaves. An increasing 0-1-2 tree on [n] is an unordered tree on [n], rooted at 1, in which each vertex has <= 2 children and the labels increase along each path from the root. Example: a(4,2)=4 counts the trees with edges as follows, {1->2->3,1->4}, {1->2->4,1->3}, {1->2->4,2->3}, {1->3->4,1->2}. - David Callan, Oct 24 2004

Examples

			Triangle begins:
  1
  1
  1  1
  1  4
  1 11   4
  1 26  34
  1 57 180 34
  ...
From _Peter Bala_, Jun 26 2012: (Start)
Recurrence equation: T(6,3) = 3*T(5,3) + 2*T(5,2) = 3*4 + 2*11 = 34.
n = 4: the 5 weighted non-plane increasing 0-1-2 trees on 4 vertices are
.........................................................
..4......................................................
..|......................................................
..3............4............4.............3.......3...4..
..|.........../............/............./.........\./...
..2......2...3........3...2.........4...2........(t)2....
..|.......\./..........\./...........\./............|....
..1.....(t)1.........(t)1..........(t)1.............1....
.........................................................
Hence row polynomial R(4,t) = (1 + 4*t)*t.
(End)
		

Crossrefs

Programs

  • Maple
    A094503:=proc(n,k) options remember: if(n=1 and k=1) then RETURN(1) elif(1<=k and k<=floor((n+1)/2) and n>=1) then RETURN(k*A094503(n-1,k)+(n+2-2*k)*A094503(n-1,k-1)) else RETURN(0) fi: end; seq(seq(A094503(n,k),k=1..floor((n+1)/2)),n=1..14);
  • Mathematica
    t[1, 1] = 1; t[n_, k_] /; Not[1 <= k <= (n+1)/2] = 0; t[n_, k_] := t[n, k] = k*t[n-1, k] + (n+2-2*k)*t[n-1, k-1]; Table[t[n, k], {n, 0, 13}, {k, 1, (n + 1)/2}] // Flatten (* Jean-François Alcover, Nov 22 2012, after Maple *)
  • Sage
    def p(n) :
        s = var('s'); u = sqrt(s^2-2)
        egf = u*x-2*ln((exp(u*x)*(1-s/u)+s/u+1)/2)
        return factorial(n+2)*egf.series(x,n+4).coefficient(x,n+2)
    def A094503_row(n) : return [p(n).coefficient(s,n-2*i) for i in (0..n//2)]
    for n in (0..6): print(A094503_row(n)) # Peter Luschny, Jul 01 2012

Formula

D(1, n) = A000111(n), Euler or up/down numbers. D(1/2, n) = A000142(n)*(1/2)^n. D(1/4, n) = A080795(n)*(1/4)^n.
From Peter Bala, Jun 26 2012: (Start):
Recurrence equation: T(n,k) = k*T(n-1,k) + (n+2-2*k)*T(n-1,k-1) for n >= 1 and 1 <= k <= floor((n+1)/2).
Let r(t) = sqrt(1-2*t) and w(t) = (1-r(t))/(1+r(t)). The e.g.f. is F(t,z) = r(t)*(1 + w(t)*exp(r(t)*z))/(1 - w(t)*exp(r(t)*z)) = 1 + t*z + t*z^2/2! + (t+t^2)*z^3/3! + (t+4*t^2)*z^4/4! + ... (Foata and Han, 2001, section 7).
Note that (F(2*t,z) - 1)/(2*t) is the e.g.f. for A101280.
The modified e.g.f. A(t,z) := (F(t,z) - 1)/t = z + z^2/2! + (1+t)*z^3/3! + (1+4*t)*z^4/4! + ... satisfies the autonomous partial differential equation dA/dz = 1 + A + 1/2*t*A^2 with A(t,0) = 1. It follows that the inverse function A(t,z)^(-1) may be expressed as an integral: A(t,z)^(-1) = Integral_{x = 0..z} 1/(1+x+1/2*t*x^2) dx.
Applying [Dominici, Theorem 4.1] to invert the integral gives the following method for calculating the row polynomials R(n,t) of the table: let f(t,x) = 1+x+1/2*t*x^2 and let D be the operator f(t,x)*d/dx. Then R(n+1,t) = t*D^n(f(t,x)) evaluated at x = 0.
By Bergeron et al., Theorem 1, the shifted row polynomial 1/t*R(n,t) is the generating function for rooted non-plane increasing 0-1-2 trees on n vertices, where the vertices of outdegree 2 have weight t and all other vertices have weight 1. An example is given below.
1/(2*t)*(1+t)^(n+1)*R(n,2*t/(1+t)^2) = the n-th Eulerian polynomial of A008292. For example, n = 5 gives 1/(2*t)*(1+t)^6*R(5,2*t/(1+t)^2) = 1 + 26*t + 66*t^2 + 26*t^3 + t^4.
A000142(n) = 2^n*R(n,1/2); A080795(n) = 4^n*R(n,1/4);
A000670(n) = 3/4*3^n*R(n,4/9); A004123(n+1) = 5/6*5^n*R(n,12/25).
(End)
There is a second family of polynomials which also matches the data and is different from the André polynomials as defined by Foata and Han (2001), formula 3.5. Let u = sqrt(s^2-2) and F(s,x) = u*x-2*log((exp(u*x)*(1-s/u)+s/u+1)/2), then for n>=0 the sequence of polynomials p_{n}(s) = (n+2)!*[x^(n+2)]F(s,x) starts 1, s, s^2+1, s^3+4*s, s^4+11*s^2+4, s^5+26*s^3+34*s, s^6+57*s^4+180*s^2+34, ... and the nonzero coefficients of these polynomials in descending order coincide with the sequence a(n). p_{n}(0) is an aerated version of the reduced tangent numbers, p_{2*n}(0) = A002105(n+1) for n>=0. In contrast, the André polynomials vanish at t=0 except for n=0. - Peter Luschny, Jul 01 2012
T(n,k) = A008303(n,k)/2^(n-k). - Ammar Khatab, Aug 17 2024

A101280 Triangle T(n,k) (n >= 1, 0 <= k <= floor((n-1)/2)) read by rows, where T(n,k) = (k+1)T(n-1,k) + (2n-4k)T(n-1,k-1).

Original entry on oeis.org

1, 1, 1, 2, 1, 8, 1, 22, 16, 1, 52, 136, 1, 114, 720, 272, 1, 240, 3072, 3968, 1, 494, 11616, 34304, 7936, 1, 1004, 40776, 230144, 176896, 1, 2026, 136384, 1328336, 2265344, 353792, 1, 4072, 441568, 6949952, 21953408, 11184128, 1, 8166, 1398000, 33981760
Offset: 1

Views

Author

Don Knuth, Jan 28 2005

Keywords

Comments

Row n has ceiling(n/2) terms.
The paper by Shapiro et al. explains why T(n,k) is the number of permutations of n elements having k peaks and with the further property that every rise (ascent) is immediately followed by a peak. [That is, the permutation p_1 ... p_n has the further property that (j > 1 and p_{j-1} < p_j) implies (j < n and p_j > p_{j+1}).] For example, the T(4,1)=8 permutations in the case n=4, k=1 are 1423, 2143, 2431, 3142, 3241, 3421, 4231, 4132.
A more elegant way to state this property: T(n,k) is the number of permutations of n objects with k descents such that every descent is a peak. The eight examples for n=4 and k=1 are now 1243, 1324, 1342, 1423, 2314, 2341, 2413, 3412.
The rows of this triangle are the gamma vectors of the n-dimensional (type A) permutohedra (Postnikov et al., p. 31). Cf. A055151 and A089627. - Peter Bala, Oct 28 2008

Examples

			Triangle begins:
  1;
  1,
  1,   2;
  1,   8,
  1,  22,  16;
  1,  52, 136,
  1, 114, 720, 272;
  ...
From _Peter Bala_, Jun 26 2012: (Start)
n = 4: the 9 weighted plane increasing 0-1-2 trees on 4 vertices are
..................................................................
..4...............................................................
..|...............................................................
..3..........4...4...............4...4...............3...3........
..|........./.....\............./.....\............./.....\.......
..2....2...3.......3...2...3...2.......2...3...4...2.......2...4..
..|.....\./.........\./.....\./.........\./.....\./.........\./...
..1...(t)1........(t)1....(t)1........(t)1....(t)1........(t)1....
..................................................................
..3...4...4...3...................................................
...\./.....\./....................................................
.(t)2....(t)2.....................................................
....|.......|.....................................................
....1.......1.....................................................
Hence R(4,t) = 1 + 8*t.
(End)
		

References

  • D. Foata and V. Strehl, "Euler numbers and variations of permutations", in Colloquio Internazionale sulle Teorie Combinatorie, Rome, September 1973, (Atti dei Convegni Lincei 17, Rome, 1976), 129.
  • Guoniu Han, Frédéric Jouhet, Jiang Zeng, Two new triangles of q-integers via q-Eulerian polynomials of type A and B, Ramanujan J (2013) 31:115-127, DOI 10.1007/s11139-012-9389-3
  • T. K. Petersen, Eulerian Numbers, Birkhauser, 2015, Chapter 4.

Crossrefs

The numbers 2^{n-1-k} T(n, k) form the array shown in A008303.
Cf. A055151, A089627. - Peter Bala, Oct 28 2008
Cf. A008292, A094503, A080635 (row sums).

Programs

  • Maple
    T:=proc(n,k) if k<0 then 0 elif n=1 and k=0 then 1 elif k>floor((n-1)/2) then 0 else (k+1)*T(n-1,k)+(2*n-4*k)*T(n-1,k-1) fi end: for n from 1 to 13 do seq(T(n,k),k=0..floor((n-1)/2)) od; # yields sequence in triangular form # Emeric Deutsch, Aug 06 2005
  • Mathematica
    t[, k?Negative] = 0; t[1, 0] = 1; t[n_, k_] /; k > (n-1)/2 = 0; t[n_, k_] := t[n, k] = (k+1)*t[n-1, k] + (2*n-4*k)*t[n-1, k-1]; Table[t[n, k], {n, 1, 13}, {k, 0, (n-1)/2}] // Flatten (* Jean-François Alcover, Nov 22 2012 *)

Formula

G.f.: Sum_{n>=1, k>=0} T(n, k) t^k z^n/n! = C(t)(2-C(t))/(exp^(-z sqrt(1-4t)) + 1 - C(t)) - C(t), where the sum on k is actually finite, running up to ceiling(n/2) - 1; here C(t) = (1 - sqrt(1-4t))/2t is the generating function for the Catalan numbers (A000108).
Sum_{k} Eulerian(n, k) x^k = Sum_{k} T(n, k) x^k (1+x)^(n-1-2k). E.g., 1 + 11x + 11x^2 + x^3 = (1+x)^3 + 8x(1+x).
From Peter Bala, Jun 26 2012: (Start)
T(n,k) = 2^k*A094503(n,k+1).
Let r(t) = sqrt(1 - 2*t) and w(t) = (1 - r(t))/(1 + r(t)). Define F(t,z) = r(t)*(1 + w(t)*exp(r(t)*z))/(1 - w(t)*exp(r(t)*z)) = 1 + t*z + t*z^2/2! + (t+t^2)*z^3/3! + (t+4*t^2)*z^4/4! + ...; F(t,z) is the e.g.f. for A094503. The e.g.f. for the present table is A(t,z) := (F(2*t,z) - 1)/(2*t) = z + z^2/2! + (1+2*t)*z^3/3! + (1+8*t)*z^4/4! + ....
The e.g.f. A(t,z) satisfies the autonomous partial differential equation dA/dz = 1 + A + t*A^2 with A(t,0) = 0. It follows that the inverse function A(t,z)^(-1) may be expressed as an integral: A(t,z)^(-1) = int {x = 0..z} 1/(1+x+t*x^2) dx.
Applying [Dominici, Theorem 4.1] to invert the integral gives the following method for calculating the row polynomials R(n,t) of the table: let f(t,x) = 1+x+t*x^2 and let D be the operator f(t,x)*d/dx. Then R(n+1,t) = D^n(f(t,x)) evaluated at x = 0.
By Bergeron et al., Theorem 1, the row polynomial R(n,t) is the generating function for rooted plane increasing 0-1-2 trees on n vertices, where the vertices of outdegree 2 have weight t and all other vertices have weight 1. An example is given below.
Row sums A080635.
(End)

Extensions

More terms from Emeric Deutsch, Aug 06 2005

A179709 Number of permutations of 1..n having exactly 6 maxima.

Original entry on oeis.org

0, 353792, 22368256, 795300864, 21016670208, 460858269696, 8885192097792, 155964390375424, 2550316668551168, 39471306959486976, 584901762421358592, 8369943835924758528, 116424418353082269696, 1582198544942090944512, 21092268709406041964544
Offset: 10

Views

Author

R. H. Hardin, Jul 25 2010

Keywords

Comments

a(n) = A130662(n-1)*512.

Crossrefs

Column k=5 of A008303.

Formula

G.f.: -512*x^11* (2090188800*x^10 -5075343360*x^9 +5480510976*x^8 -3456747648*x^7 +1407037152*x^6 -385459712*x^5 +71872912*x^4 -8997896*x^3 +723346*x^2 -33704*x+691) / ((12*x-1) *(10*x-1)^2 *(8*x-1)^3 *(6*x-1)^4 *(4*x-1)^5 *(2*x-1)^6). - Alois P. Heinz, Oct 01 2013

Extensions

a(17)-a(24) from Alois P. Heinz, Oct 01 2013

A179710 Number of permutations of 1..n having exactly 7 maxima.

Original entry on oeis.org

0, 22368256, 1903757312, 89702612992, 3099269660672, 87815735738368, 2165206642589696, 48165109676113920, 990081991141490688, 19125263737773096960, 351453130688070942720, 6201012431516898164736, 105800556580541665640448, 1755407285349861864505344
Offset: 12

Views

Author

R. H. Hardin, Jul 25 2010

Keywords

Comments

a(n) = 2048 * A130663(n-1).

Crossrefs

Column k=6 of A008303.

Formula

G.f.: -2048*x^13* (264868724736000*x^15 -891839368396800*x^14 +1387289679298560*x^13 -1320505755697152*x^12 +859006229078016*x^11 -404049277108224*x^10 +141829511625984*x^9 -37804275799552*x^8 +7710418349056*x^7 -1202843456128*x^6 +142319143104*x^5 -12540195936*x^4 +796479552*x^3 -34424192*x^2 +905327*x -10922) / ((14*x-1) *(12*x-1)^2 *(10*x-1)^3 *(8*x-1)^4 *(6*x-1)^5 *(4*x-1)^6 *(2*x-1)^7). - Alois P. Heinz, Oct 01 2013

Extensions

a(18)-a(25) from Alois P. Heinz, Oct 01 2013

A303564 Number T(n,k) of derangements of [n] having exactly k peaks; triangle T(n,k), n>=0, 0<=k<=max(0,floor((n-1)/2)), read by rows.

Original entry on oeis.org

1, 0, 1, 1, 1, 3, 6, 5, 33, 6, 11, 152, 102, 21, 663, 1068, 102, 43, 2778, 9060, 2952, 85, 11413, 68250, 50796, 2952, 171, 46332, 477978, 679368, 131112, 341, 186867, 3192192, 7824834, 3349224, 131112, 683, 750878, 20648088, 81751824, 64791576, 8271792
Offset: 0

Views

Author

Alois P. Heinz, Apr 26 2018

Keywords

Examples

			T(5,0) = 5: 51234, 53124, 53214, 54123, 54213.
T(5,1) = 33: 21453, 21534, 23451, 23514, 24513, 24531, 25134, 25413, 25431, 31254, 31452, 31524, 34512, 34521, 35124, 35214, 35412, 35421, 41253, 41523, 41532, 43152, 43251, 43512, 43521, 45123, 45213, 51423, 51432, 53412, 53421, 54132, 54231.
T(5,2) = 6: 23154, 24153, 34152, 34251, 45132, 45231.
Triangle T(n,k) begins:
    1;
    0;
    1;
    1,      1;
    3,      6;
    5,     33,        6;
   11,    152,      102;
   21,    663,     1068,      102;
   43,   2778,     9060,     2952;
   85,  11413,    68250,    50796,     2952;
  171,  46332,   477978,   679368,   131112;
  341, 186867,  3192192,  7824834,  3349224,  131112;
  683, 750878, 20648088, 81751824, 64791576, 8271792;
		

Crossrefs

Columns k=0-1 give: A001045(n-1) for n>0, A301272.
Row sums give A000166.
Cf. A008303 (the same for permutations), A004526, A129815, A129817, A162979, A162980, A216963, A303648 (the same for involutions).

Programs

  • Maple
    b:= proc(s, i, j) option remember; expand(`if`(s={}, 1, add(
          `if`(k=nops(s), 0, b(s minus {k}, `if`(j>k, 0, j), k)*
          `if`(i>0 and j>0 and ik, x, 1)), k=s)))
        end:
    T:= n-> (p-> seq(coeff(p, x, i), i=0..max(0, degree(p))))(b({$1..n}, 0$2)):
    seq(T(n), n=0..12);
  • Mathematica
    b[s_, i_, j_] := b[s, i, j] = Expand[If[s == {}, 1, Sum[If[k == Length[s], 0, b[s ~Complement~ {k}, If[j > k, 0, j], k]*If[i > 0 && j > 0 && i < j && j > k, x, 1]], {k, s}]]];
    T[n_] := Function[p, Table[Coefficient[p, x, i], {i, 0, Max[0, Exponent[p, x]]}]][b[Range[n], 0, 0]];
    Table[T[n], {n, 0, 12}] // Flatten (* Jean-François Alcover, May 31 2018, from Maple *)

Formula

T(2*n+1,n) = A129815(2*n+1) = A129817(2*n+1) = A162979(2*n+1,0) = A162980(2*n+1,0).

A179708 Number of permutations of 1..n having exactly 5 maxima.

Original entry on oeis.org

0, 7936, 353792, 9061376, 175627264, 2868264960, 41731645440, 559148810240, 7048869314560, 84842998005760, 985278548541440, 11124607890751488, 122829335169859584, 1332091026832097280, 14238886515777208320, 150420440721496473600, 1573853022795658690560
Offset: 8

Views

Author

R. H. Hardin, Jul 25 2010

Keywords

Comments

Number of permutations of length n with exactly four valleys.

Crossrefs

Column k=4 of A008303.

Formula

G.f.: 256*x^9*(31 - 788*x + 8096*x^2 - 43132*x^3 + 126072*x^4 - 192672*x^5 + 120960*x^6)/ ((1-2*x)^5*(1-4*x)^4*(1-6*x)^3*(1-8*x)^2*(1-10*x)). - Ray Chandler, Dec 06 2011

Extensions

More terms from Ray Chandler, Dec 06 2011

A303648 Number T(n,k) of involutions of [n] having exactly k peaks; triangle T(n,k), n>=0, 0<=k<=max(0,floor((n-1)/2)), read by rows.

Original entry on oeis.org

1, 1, 2, 3, 1, 4, 6, 5, 18, 3, 6, 44, 26, 7, 91, 123, 11, 8, 172, 448, 136, 9, 300, 1348, 912, 51, 10, 496, 3600, 4552, 838, 11, 781, 8704, 18476, 7441, 283, 12, 1186, 19584, 65324, 48116, 5930, 13, 1742, 41379, 206556, 250375, 66606, 1833, 14, 2492, 83210, 600456, 1120042, 536908, 47358
Offset: 0

Views

Author

Alois P. Heinz, Apr 27 2018

Keywords

Examples

			T(5,0) = 5: 12345, 21345, 32145, 43215, 54321.
T(5,1) = 18: 12354, 12435, 12543, 13245, 14325, 14523, 15432, 21354, 21435, 21543, 32154, 34125, 42315, 42513, 45312, 52341, 52431, 53241.
T(5,2) = 3: 13254, 15342, 35142.
Triangle T(n,k) begins:
   1;
   1;
   2;
   3,    1;
   4,    6;
   5,   18,     3;
   6,   44,    26;
   7,   91,   123,     11;
   8,  172,   448,    136;
   9,  300,  1348,    912,     51;
  10,  496,  3600,   4552,    838;
  11,  781,  8704,  18476,   7441,   283;
  12, 1186, 19584,  65324,  48116,  5930;
  13, 1742, 41379, 206556, 250375, 66606, 1833;
		

Crossrefs

Row sums give A000085.
Columns k=0-1 give: A028310, A303649.
Cf. A008303 (the same for permutations), A072187, A303564 (the same for derangements).

Formula

T(2n+1,n) = A072187(n+1).
Previous Showing 11-18 of 18 results.