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

A369321 T(n,k) is the number of length-n weak ascent sequences (prefixed with a zero) with k weak ascents, triangle read by rows.

Original entry on oeis.org

1, 0, 1, 0, 0, 2, 0, 0, 1, 5, 0, 0, 0, 9, 14, 0, 0, 0, 5, 59, 42, 0, 0, 0, 1, 92, 342, 132, 0, 0, 0, 0, 75, 1073, 1863, 429, 0, 0, 0, 0, 35, 1882, 10145, 9794, 1430, 0, 0, 0, 0, 9, 2131, 31345, 84977, 50380, 4862, 0, 0, 0, 0, 1, 1661, 64395, 417220, 658423, 255606, 16796
Offset: 0

Views

Author

Joerg Arndt, Jan 20 2024

Keywords

Comments

A weak ascent sequence is a sequence [d(1), d(2), ..., d(n)] where d(1)=0, d(k)>=0, and d(k) <= 1 + asc([d(1), d(2), ..., d(k-1)]) and asc(.) counts the weak ascents d(j) >= d(j-1) of its argument.

Examples

			1,
0, 1,
0, 0, 2,
0, 0, 1, 5,
0, 0, 0, 9, 14,
0, 0, 0, 5, 59,   42,
0, 0, 0, 1, 92,  342,    132,
0, 0, 0, 0, 75, 1073,   1863,     429,
0, 0, 0, 0, 35, 1882,  10145,    9794,     1430,
0, 0, 0, 0,  9, 2131,  31345,   84977,    50380,     4862,
0, 0, 0, 0,  1, 1661,  64395,  417220,   658423,   255606,    16796,
0, 0, 0, 0,  0,  912,  95477, 1370141,  4818426,  4835924,  1285453,   58786,
0, 0, 0, 0,  0,  350, 107002, 3291589, 23507705, 50477693, 34184279, 6428798, 208012,
...
		

Crossrefs

Cf. A000108 (main diagonal), A336070 (row sums), A369322 (column sums).
T(2n,n) gives A373115.
Cf. A137251.

Programs

  • Maple
    b:= proc(n, i, t) option remember; expand(`if`(n=0, 1, add(
          b(n-1, j, t+`if`(j>=i, 1, 0))*`if`(j>=i, x, 1), j=0..t+1)))
        end:
    T:= (n, k)-> coeff(b(n, -1$2), x, k):
    seq(seq(T(n, k), k=0..n), n=0..10);  # Alois P. Heinz, Jan 23 2024
  • Mathematica
    b[n_, i_, t_] := b[n, i, t] = Expand[If[n == 0, 1, Sum[
       b[n - 1, j, t + If[j >= i, 1, 0]]*If[j >= i, x, 1], {j, 0, t + 1}]]];
    T[n_, k_] := Coefficient[b[n, -1, -1], x, k];
    Table[Table[T[n, k], {k, 0, n}], {n, 0, 10}] // Flatten (* Jean-François Alcover, May 24 2024, after Alois P. Heinz *)
  • PARI
    \\ see formula (5) on page 18 of the Benyi/Claesson/Dukes reference
    N=40;
    M=matrix(N, N, r, c, -1);  \\ memoization
    a(n, k)=
    {
        if ( n==0 && k==0, return(1) );
        if ( k==0, return(0) );
        if ( n==0, return(0) );
        if ( M[n, k] != -1 , return( M[n, k] ) );
        my( s );
        s = sum( i=0, n, sum( j=0, k-1,
             (-1)^j * binomial(k-j, i) * binomial(i, j) * a( n-i, k-j-1 )) );
        M[n, k] = s;
        return( s );
    }
    \\ for (n=0, N, print1( sum(k=1, n, a(n, k)), ", "); ); \\ A336070
    for (n=0, N, for(k=0, n, print1(a(n, k), ", "); ); print(); );
    \\ Joerg Arndt, Jan 20 2024

Formula

T(n,n) = A000108(n) (number of length-n weak ascent sequences with maximal number of weak ascents).

A357141 Number of n X n triangular matrices with nonnegative integer entries and without zero rows or columns such that sum of all entries is equal to 2n.

Original entry on oeis.org

1, 1, 6, 71, 1433, 44443, 1968580, 118159971, 9240555677, 913352224942, 111374887418013, 16428282185046946, 2883740893056526715, 594152447495864629867, 142006380268368661423424, 38973735372090120549251580, 12174162204364698538764222978, 4294569227671480526607187583713
Offset: 0

Views

Author

Alois P. Heinz, Sep 14 2022

Keywords

Crossrefs

Cf. A137251.

Formula

a(n) = A137251(2n,n).

A022494 Number of connected regular linearized chord diagrams of degree n.

Original entry on oeis.org

1, 1, 1, 2, 5, 16, 63, 293, 1561, 9321, 61436, 442134, 3446077, 28905485, 259585900, 2485120780, 25267283367, 271949606805, 3089330120711, 36943477086287, 463943009361687, 6105064699310785, 84011389289865102
Offset: 0

Views

Author

Alexander Stoimenow (stoimeno(AT)math.toronto.edu)

Keywords

Crossrefs

Cf. A137251.

Programs

  • PARI
    A137251_seq(N) = {
      my(x='x + O('x^(N+1)), t='t+O('t^(N+2)), q=1-x, z=1/t-1, p=vector(N+1));
      p[1]=1; for (n=1, #p-1, p[n+1] = p[n] * (1-q^n)/(1+z*q^n));
      apply(p->Vecrev(p), Vec((apply(p->Pol(p,'t), vecsum(p)/(1+z))-'t)/'t^2));
    };
    A022494_seq(N) = {
      my(s = 't+'t^2*'x*Ser(apply(v->Polrev(v,'t), A137251_seq(N))),
         r = Ser(vector(N+1, n, subst(polcoeff(s, n-1, 't), 'x, 'u + O('u^(N+1)))),'t));
      Vec(1+subst(Pol(t/serreverse(r) - 1,'t),'t,1));
    };
    A022494_seq(22) \\ Gheorghe Coserea, Nov 01 2017
Previous Showing 11-13 of 13 results.