OFFSET
0,6
COMMENTS
A pattern is a finite sequence covering an initial interval of positive integers. Patterns are counted by A000670.
LINKS
Andrew Howroyd, Table of n, a(n) for n = 0..1325 (rows 0..50)
FORMULA
T(n,k) = k! * A351641(n,k).
EXAMPLE
Triangle begins:
1,
0, 1;
0, 1, 2;
0, 1, 4, 6;
0, 1, 10, 18, 24;
0, 1, 16, 72, 96, 120;
0, 1, 34, 168, 528, 600, 720;
...
The T(3,1) = 1 pattern is 111.
The T(3,2) = 4 patterns are 112, 122, 211, 221.
The T(3,3) = 6 patterns are 123, 132, 213, 231, 312, 321.
PROG
(PARI) \\ here LahI is A111596 as row polynomials.
LahI(n, y)={sum(k=1, n, y^k*(-1)^(n-k)*(n!/k!)*binomial(n-1, k-1))}
S(n)={my(p=prod(k=1, n, 1 + y*x^k + O(x*x^n))); 1 + sum(i=1, (sqrtint(8*n+1)-1)\2, polcoef(p, i, y)*LahI(i, y))}
R(q)={[subst(serlaplace(p), y, 1) | p<-Vec(q)]}
T(n)={my(q=S(n), v=concat([1], sum(k=1, n, R(q^k-1)*sum(r=k, n, y^r*binomial(r, k)*(-1)^(r-k)) ))); [Vecrev(p) | p<-v]}
{ my(A=T(10)); for(n=1, #A, print(A[n])) }
CROSSREFS
KEYWORD
nonn,tabl
AUTHOR
Andrew Howroyd, Feb 15 2022
STATUS
approved