OFFSET
0,4
LINKS
Reinhard Zumkeller, Rows n = 0..125 of triangle, flattened
FORMULA
Riordan array ((1+x+sqrt(1-6*x+x^2))/(4*x), (1-x-sqrt(1-6*x+x^2))/2).
Sum_{k=0..n} T(n,k) = A010683(n).
Sum_{k=0..floor(n/2)} T(n-k, k) = A186828(n).
R(n,k) = k*Sum_{i=0..n-k} (A001003(i)/(n-i))*Sum_{m=0..n-k-i} binomial(n-i,m)*binomial(2*(n-i)-m-k-1, n-i-1), k>0, R(n,0) = A001003(n). - Vladimir Kruchinin, Mar 09 2011
Sum_{k=0..n} (-1)^k*T(n, k) = A239204(n-2). - G. C. Greubel, Mar 11 2023
EXAMPLE
Triangle begins
1;
1, 1;
3, 3, 1;
11, 11, 5, 1;
45, 45, 23, 7, 1;
197, 197, 107, 39, 9, 1;
903, 903, 509, 205, 59, 11, 1;
4279, 4279, 2473, 1061, 347, 83, 13, 1;
20793, 20793, 12235, 5483, 1949, 541, 111, 15, 1;
103049, 103049, 61463, 28435, 10717, 3285, 795, 143, 17, 1;
518859, 518859, 312761, 148249, 58351, 19199, 5197, 1117, 179, 19, 1;
Production matrix of this triangle begins
1, 1;
2, 2, 1;
2, 2, 2, 1;
2, 2, 2, 2, 1;
2, 2, 2, 2, 2, 1;
2, 2, 2, 2, 2, 2, 1;
2, 2, 2, 2, 2, 2, 2, 1;
2, 2, 2, 2, 2, 2, 2, 2, 1;
2, 2, 2, 2, 2, 2, 2, 2, 2, 1;
For instance, 107=1*45+2*23+2*7+2*1.
MATHEMATICA
t[_, 0]=1; t[p_, p_]:= t[p, p]= t[p, p-1]; t[p_, q_]:= t[p, q]= t[p, q -1] + t[p-1, q] + t[p-1, q-1];
Table[t[p, q], {p, 0, 10}, {q, p, 0, -1}]//Flatten (* Jean-François Alcover, Jul 16 2019 *)
PROG
(Haskell)
a186826 n k = a186826_tabl !! n !! k
a186826_row n = a186826_tabl !! n
a186826_tabl = map reverse a144944_tabl
-- Reinhard Zumkeller, May 11 2013
(SageMath)
@CachedFunction
def t(n, k):
if (k<0 or k>n): return 0
elif (k==0): return 1
elif (k<n-1): return t(n, k-1) + t(n-1, k) + t(n-1, k-1)
else: return -t(n, n-2)
def A186826(n, k): return t(n+2, n-k)
flatten([[A186826(n, k) for k in range(n+1)] for n in range(13)]) # G. C. Greubel, Mar 11 2023
CROSSREFS
KEYWORD
AUTHOR
Paul Barry, Feb 27 2011
STATUS
approved