OFFSET
0,6
COMMENTS
There are various conventions for indexing the Narayana, the Eulerian numbers and the zig-zag Eulerian numbers. The one we use here requires that all corresponding polynomials have p(n, 0) = 1.
LINKS
Peter Luschny, Illustrating the polynomials.
EXAMPLE
Triangle starts:
[0] 1;
[1] 1;
[2] 1, 1;
[3] 1, 4, 4, 1;
[4] 1, 9, 25, 25, 9, 1;
[5] 1, 17, 97, 221, 221, 97, 17, 1;
[6] 1, 29, 291, 1229, 2476, 2476, 1229, 291, 29, 1;
MAPLE
R := proc(n) option remember; local F; if n = 0 then 1/(1 - q*x) else F := R(n-1);
simplify(p/(p - q)*(subs({p = q, q = p}, F) - subs(p = q, F))) fi end:
EZ := (n, x) -> ifelse(n < 3, 1, expand(simplify(subs({p = 1, q = 1}, R(n))*(1 - x)^(n + 1)) / x^2)):
nc := (n, k) -> `if`(n = 0, 0^n, binomial(n, k)^2*(n-k)/(n*(k+1))):
N := (n, x) -> local k; simplify(add(nc(n, k)*x^k, k = 0..n)):
NEZ := (n, x) -> expand(EZ(n, x) * N(n, x)):
Trow := n -> local k; if n < 2 then 1 elif n = 2 then 1, 1
else seq(coeff(NEZ(n, x), x, k), k = 0..2*n-3) fi: seq(print(Trow(n)), n = 0..6);
CROSSREFS
KEYWORD
nonn,tabf
AUTHOR
Peter Luschny, Jun 05 2024
STATUS
approved