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

A263776 Triangle read by rows: T(n,k) (n>=0, 0<=k<=A002620(n-1)) is the number of permutations of [n] with k nestings.

Original entry on oeis.org

1, 1, 2, 5, 1, 14, 8, 2, 42, 45, 25, 7, 1, 132, 220, 198, 112, 44, 12, 2, 429, 1001, 1274, 1092, 700, 352, 140, 42, 9, 1, 1430, 4368, 7280, 8400, 7460, 5392, 3262, 1664, 716, 256, 74, 16, 2, 4862, 18564, 38556, 56100, 63648, 59670, 47802, 33338, 20466, 11115
Offset: 0

Views

Author

Christian Stump, Oct 26 2015

Keywords

Comments

Row sums give A000142.
First column gives A000108.
Also the number of permutations of [n] with k crossings (see Corteel, Proposition 4).
Also the number of permutations of [n] with exactly k (possibly overlapping) occurrences of the generalized pattern 13-2 (alternatively: 2-13, 2-31, or 31-2). - Alois P. Heinz, Nov 14 2015

Examples

			Triangle begins:
0 :   1;
1 :   1;
2 :   2;
3 :   5,    1;
4 :  14,    8,    2;
5 :  42,   45,   25,    7,   1;
6 : 132,  220,  198,  112,  44,  12,   2;
7 : 429, 1001, 1274, 1092, 700, 352, 140, 42, 9, 1;
...
		

Crossrefs

Programs

  • Maple
    b:= proc(u, o) option remember;
          `if`(u+o=0, 1, add(b(u-j, o+j-1), j=1..u)+
           add(expand(b(u+j-1, o-j)*x^(j-1)), j=1..o))
        end:
    T:= n-> (p-> seq(coeff(p, x, i), i=0..degree(p)))(b(n, 0)):
    seq(T(n), n=0..10);  # Alois P. Heinz, Nov 14 2015
  • Mathematica
    b[u_, o_] := b[u, o] = If[u+o == 0, 1, Sum[b[u-j, o+j-1], {j, 1, u}] + Sum[Expand[b[u+j-1, o-j]*x^(j-1)], {j, 1, o}]]; T[n_] := Function[p, Table[Coefficient[p, x, i], {i, 0, Exponent[p, x]}]][b[n, 0]]; Table[ T[n], {n, 0, 10}] // Flatten (* Jean-François Alcover, Jan 31 2016, after Alois P. Heinz *)

Formula

Sum_{k>0} k * T(n,k) = A001754(n).
T(n,n) = A287328(n). - Alois P. Heinz, Aug 31 2017

Extensions

More terms from Alois P. Heinz, Oct 26 2015

A120816 Number of permutations of length n with exactly 8 occurrences of the pattern 2-13.

Original entry on oeis.org

9, 716, 20466, 365996, 4939341, 55098294, 535240680, 4680045630, 37665984798, 283492037268, 2018852205700, 13724440760376, 89682252682256, 566388685336800, 3472428372731880, 20740959695100150, 121059468257664984
Offset: 7

Views

Author

Robert Parviainen (robertp(AT)ms.unimelb.edu.au), Jul 06 2006

Keywords

References

  • R. Parviainen, Lattice path enumeration of permutations with k occurrences of the pattern 2-13, preprint, 2006.
  • Robert Parviainen, Lattice Path Enumeration of Permutations with k Occurrences of the Pattern 2-13, Journal of Integer Sequences, Vol. 9 (2006), Article 06.3.2.

Crossrefs

Column k=8 of A263776.

Formula

a(n) = (-7983360 - 12956832n + 10475400n^2 + 3647724n^3 - 416326n^4 - 249417n^5 - 19971n^6 + 2646n^7 + 576n^8 + 39n^9 + n^10)/(40320(n+8)(n+9)(n+10))Binomial[2n, n-7]; generating function = x^7 C^15(29 - 65536C + 499576C^2 - 1679496C^3 + 3298054C^4 - 4270444C^5 + 3911698C^6 - 2671744C^7 + 1439239C^8 - 659504C^9 + 279446C^10 - 112922C^11 + 41165C^12 - 12362C^13 + 2816C^14 - 448C^15 + 44C^16 - 2C^17)/(2-C)^15, where C=(1-Sqrt[1-4x])/(2x) is the Catalan function.

A120814 Number of permutations of length n with exactly 6 occurrences of the pattern 2-13.

Original entry on oeis.org

0, 0, 0, 0, 0, 2, 140, 3262, 47802, 535990, 5038418, 41781432, 315447990, 2214289350, 14664659100, 92612930280, 562220244768, 3301016862024, 18836205435208, 104862661271840, 571336322754792, 3054404571541092, 16056744308319000
Offset: 1

Views

Author

Robert Parviainen (robertp(AT)ms.unimelb.edu.au), Jul 06 2006

Keywords

References

  • R. Parviainen, Lattice path enumeration of permutations with k occurrences of the pattern 2-13, preprint, 2006.
  • Robert Parviainen, Lattice Path Enumeration of Permutations with k Occurrences of the Pattern 2-13, Journal of Integer Sequences, Vol. 9 (2006), Article 06.3.2.

Crossrefs

Formula

a(n) = (20160 + 44448n + 548n^2 - 4196n^3 - 565n^4 + 67n^5 + 17n^6 + n^7)/(720(n+7)(n+6))binomial[2n, n-6]; generating function = x^6 C^13 (-42 + 4054C - 18354C^2 + 36038C^3 - 40660C^4 + 30080C^5 - 16090C^6 + 6914C^7 - 2604C^8 + 840C^9 - 202C^10 + 30C^11 - 2C^12)/(2-C)^11, where C=(1-Sqrt[1-4x])/(2x) is the Catalan function.
Showing 1-3 of 3 results.