login
This site is supported by donations to The OEIS Foundation.

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A218579 Triangle read by rows: T(n,k) is the number of ascent sequences of length n with last zero at position k-1. 6
1, 1, 1, 2, 1, 2, 5, 2, 3, 5, 15, 5, 8, 10, 15, 53, 15, 26, 32, 38, 53, 217, 53, 99, 122, 142, 164, 217, 1014, 217, 433, 537, 619, 704, 797, 1014, 5335, 1014, 2143, 2683, 3069, 3464, 3876, 4321, 5335, 31240, 5335, 11854, 15015, 17063, 19140, 21294, 23522, 25905, 31240 (list; table; graph; refs; listen; history; text; internal format)
OFFSET

1,4

COMMENTS

Row sums are A022493.

First column and the diagonal is A022493(n-1).

LINKS

Alois P. Heinz, Rows n = 1..100, flattened

EXAMPLE

Triangle starts:

[ 1]      1;

[ 2]      1,    1;

[ 3]      2,    1,     2;

[ 4]      5,    2,     3,     5;

[ 5]     15,    5,     8,    10,    15;

[ 6]     53,   15,    26,    32,    38,    53;

[ 7]    217,   53,    99,   122,   142,   164,   217;

[ 8]   1014,  217,   433,   537,   619,   704,   797,  1014;

[ 9]   5335, 1014,  2143,  2683,  3069,  3464,  3876,  4321,  5335;

[10]  31240, 5335, 11854, 15015, 17063, 19140, 21294, 23522, 25905, 31240;

...

MAPLE

b:= proc(n, i, t, k) option remember; `if`(n=0, 1,

      add(b(n-1, j, t+`if`(j>i, 1, 0), max(-1, k-1)),

             j=`if`(k>=0, 0, 1)..`if`(k=0, 0, t+1)))

    end:

T:= (n, k)-> b(n-1, 0, 0, k-2):

seq(seq(T(n, k), k=1..n), n=1..10);  # Alois P. Heinz, Nov 16 2012

MATHEMATICA

b[n_, i_, t_, k_] := b[n, i, t, k] = If[n == 0, 1, Sum[b[n-1, j, t + If[j>i, 1, 0], Max[-1, k-1]], {j, If[k >= 0, 0, 1], If[k == 0, 0, t+1]}]]; T[n_, k_] := b[n-1, 0, 0, k-2]; Table[Table[T[n, k], {k, 1, n}], {n, 1, 10}] // Flatten (* Jean-Fran├žois Alcover, Feb 18 2015, after Alois P. Heinz *)

CROSSREFS

Cf. A022493 (number of ascent sequences).

Cf. A218580 (ascent sequences with first occurrence of the maximal value at position k-1), A218581 (ascent sequences with last occurrence of the maximal value at position k-1).

Cf. A137251 (ascent sequences with k ascents), A218577 (ascent sequences with maximal element k), A175579 (ascent sequences with k zeros).

Sequence in context: A144155 A109631 A095149 * A182436 A064192 A284553

Adjacent sequences:  A218576 A218577 A218578 * A218580 A218581 A218582

KEYWORD

nonn,tabl

AUTHOR

Joerg Arndt, Nov 03 2012

STATUS

approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recent | More pages
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy .

Last modified May 23 01:01 EDT 2017. Contains 286908 sequences.