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.

A226432 The number of simple permutations of length n in a particular geometric grid class.

Original entry on oeis.org

1, 2, 0, 2, 3, 7, 13, 25, 46, 84, 151, 269, 475, 833, 1452, 2518, 4347, 7475, 12809, 21881, 37274, 63336, 107375, 181657, 306743, 517057, 870168, 1462250, 2453811, 4112479, 6884101, 11510809, 19226950, 32084028, 53489287, 89097893, 148290067, 246615425, 409835844, 680609086
Offset: 1

Views

Author

Jay Pantone, Jun 06 2013

Keywords

Comments

This geometric grid class is given by the array [[0,0,1,0],[0,0,0,1],[0,1,-1,0],[1,0,0,-1]]. A picture is given in the LINKS section.
The sequence of all permutations in this class is given by A226431.

Programs

  • Mathematica
    Join[{1, 2}, LinearRecurrence[{2, 1, -2, -1}, {0, 2, 3, 7}, 40]] (* Jean-François Alcover, Jul 21 2018 *)
  • PARI
    x='x+O('x^66); Vec(x+2*x^2+(x^4*(1-x)*(2+x))/((1-x-x^2)^2) ) \\ Joerg Arndt, Jun 19 2013

Formula

G.f.: x+2*x^2+ x^4*(1-x)*(2+x)/(1-x-x^2)^2 (corrected, Joerg Arndt, Jun 26 2013)
a(n) = A191830(n+2)-A000045(n+2), n>=4. - R. J. Mathar, Aug 31 2013

A226430 The number of simple permutations of length n which avoid 1243 and 2431.

Original entry on oeis.org

1, 2, 0, 2, 4, 10, 21, 44, 89, 178, 352, 692, 1355, 2648, 5171, 10100, 19744, 38646, 75761, 148772, 292653, 576678, 1138240, 2250152, 4454679, 8830640, 17525991, 34820264, 69244864, 137815978, 274487517, 547035452, 1090790465, 2176043098, 4342753696, 8669805020, 17313228899
Offset: 1

Views

Author

Jay Pantone, Jun 06 2013

Keywords

Crossrefs

The number of all permutations which avoid 1243 and 2431 is A165534.

Programs

  • Mathematica
    Join[{1, 2}, LinearRecurrence[{4, -3, -4, 3, 2}, {0, 2, 4, 10, 21}, 40]] (* Jean-François Alcover, Jul 22 2018 *)
  • PARI
    x='x+O('x^66); Vec((x-2*x^2-5*x^3+12*x^4+x^5-8*x^6-3*x^7)/((1-2*x)*(1-x-x^2)^2)) \\ Joerg Arndt, Jun 19 2013

Formula

G.f.: (x-2*x^2-5*x^3+12*x^4+x^5-8*x^6-3*x^7)/((1-2*x)*(1-x-x^2)^2).
a(n) = -2*A000045(n+1) +A191830(n+2) +2^(n-3), n>2. - R. J. Mathar, Dec 06 2013

A336014 Irregular triangle read by rows: T(n,1) = T(n,2) = T(n,3*n-2) = T(n,3*n-1) = n for n >= 1 and T(n,k) = T(n-1,k-2) + T(n-1,k-1) for n > 1, 3 <= k <= 3*(n-1).

Original entry on oeis.org

1, 1, 2, 2, 2, 2, 2, 3, 3, 4, 4, 4, 4, 3, 3, 4, 4, 6, 7, 8, 8, 8, 7, 6, 4, 4, 5, 5, 8, 10, 13, 15, 16, 16, 15, 13, 10, 8, 5, 5, 6, 6, 10, 13, 18, 23, 28, 31, 32, 31, 28, 23, 18, 13, 10, 6, 6, 7, 7, 12, 16, 23, 31, 41, 51, 59, 63, 63, 59, 51, 41, 31, 23, 16, 12, 7, 7
Offset: 1

Views

Author

Lechoslaw Ratajczak, Jul 04 2020

Keywords

Comments

The number of terms in row n is 3*n-1 = A016789(n-1).
The sum of row n is equal to 2*A094002(n-1) = 2*A188589(n).
Fibonacci(n) = T(n+k,n) - T(n+k-1,n) for n >= 1, k = 1,2,3,...
The elements b(k) of the main diagonal, superdiagonal 1 and all subdiagonals have the recursive formula: b(k) = 2*b(k-1) + b(k-2) - 2*b(k-3) - b(k-4) for k > 4.

Examples

			Triangle begins:
n\k 1  2  3  4  5  6  7  8  9 10 11 12 13 14 15 16 17 18 19 20...
1   1  1
2   2  2  2  2  2
3   3  3  4  4  4  4  3  3
4   4  4  6  7  8  8  8  7  6  4  4
5   5  5  8 10 13 15 16 16 15 13 10  8  5  5
6   6  6 10 13 18 23 28 31 32 31 28 23 18 13 10  6  6
7   7  7 12 16 23 31 41 51 59 63 63 59 51 41 31 23 16 12  7  7
...
		

Crossrefs

Superdiagonal 1 is A029907 for n >= 1.
The main diagonal is A208354 for n >= 1.
Subdiagonal 1 is A102702(n-1) for n >= 1.
Subdiagonal 2 is A206268(n+2) for n >= 1 (conjectured).
Subdiagonal 3 is A191830(n+3) for n >= 1.

Formula

T(n,k) = T(n,3*k-n) for 1 <= k <= 3*n-1.
T(n,k) = Sum_{u=2*(n-k)+3..2*n-k+1} ceiling(u/2)*A065941(k-2,u-2*(n-k)-3) for n >= 3, 3 <= k <= n.
T(n,k) = Sum_{m1=1..k-n} A208354(m1)*binomial(n-m1-1, k-n-m1) + Sum_{m2=1..2*n-k} A208354(m2)*binomial(n-m2-1, 2*n-k-m2) for n >= 2, n+1 <= k <= 2*n-1.
T(n,k) = Sum_{u=2*(k-2*n)+3..k-n+1} ceiling(u/2)*A065941(3*n-k-2,u-2*(k-2*n)-3) for n>= 3, 2*n <= k <= 3*(n-1).
T(n,k) = A208354(k) + (n-k)*Fibonacci(k) for n >= 3, 3 <= k <= n.
T(n,k) = A029907(k-1) + (n-k+1)*Fibonacci(k) for n >= 2, 3 <= k <= n+1.
Showing 1-3 of 3 results.