login
A257613
Triangle read by rows: T(n,k) = t(n-k, k); t(n,m) = f(m)*t(n-1,m) + f(n)*t(n,m-1), where f(x) = 2*x + 4.
7
1, 4, 4, 16, 48, 16, 64, 416, 416, 64, 256, 3136, 6656, 3136, 256, 1024, 21888, 84608, 84608, 21888, 1024, 4096, 145664, 939520, 1692160, 939520, 145664, 4096, 16384, 939520, 9555456, 28195840, 28195840, 9555456, 939520, 16384, 65536, 5932032, 91475968, 415734784, 676700160, 415734784, 91475968, 5932032, 65536
OFFSET
0,2
FORMULA
T(n,k) = t(n-k, k); t(0,0) = 1, t(n,m) = 0 if n < 0 or m < 0, else t(n,m) = f(m)*t(n-1,m) + f(n)*t(n,m-1), where f(x) = 2*x + 4.
Sum_{k=0..n} T(n, k) = A051580(n).
T(n, k) = (a*k + b)*T(n-1, k) + (a*(n-k) + b)*T(n-1, k-1), with T(n, 0) = 1, a = 2, and b = 4. - G. C. Greubel, Mar 20 2022
EXAMPLE
Triangle begins as:
1;
4, 4;
16, 48, 16;
64, 416, 416, 64;
256, 3136, 6656, 3136, 256;
1024, 21888, 84608, 84608, 21888, 1024;
4096, 145664, 939520, 1692160, 939520, 145664, 4096;
16384, 939520, 9555456, 28195840, 28195840, 9555456, 939520, 16384;
MATHEMATICA
T[n_, k_, a_, b_]:= T[n, k, a, b]= If[k<0 || k>n, 0, If[n==0, 1, (a*(n-k)+b)*T[n-1, k-1, a, b] + (a*k+b)*T[n-1, k, a, b]]];
Table[T[n, k, 2, 4], {n, 0, 12}, {k, 0, n}]//Flatten (* G. C. Greubel, Mar 20 2022 *)
PROG
(PARI) f(x) = 2*x + 4;
T(n, k) = t(n-k, k);
t(n, m) = if (!n && !m, 1, if (n < 0 || m < 0, 0, f(m)*t(n-1, m) + f(n)*t(n, m-1)));
tabl(nn) = for (n=0, nn, for (k=0, n, print1(T(n, k), ", "); ); print(); ); \\ Michel Marcus, May 06 2015
(Sage)
def T(n, k, a, b): # A257613
if (k<0 or k>n): return 0
elif (n==0): return 1
else: return (a*k+b)*T(n-1, k, a, b) + (a*(n-k)+b)*T(n-1, k-1, a, b)
flatten([[T(n, k, 2, 4) for k in (0..n)] for n in (0..12)]) # G. C. Greubel, Mar 20 2022
CROSSREFS
Cf. A051580 (row sums), A060187, A257609, A257611, A257615.
Similar sequences listed in A256890.
Sequence in context: A257606 A219398 A222104 * A223202 A298448 A222144
KEYWORD
nonn,tabl
AUTHOR
Dale Gerdemann, May 06 2015
STATUS
approved