login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

A055450
Path-counting array T; each step of a path is (1 right) or (1 up) to a point below line y=x, else (1 right and 1 up) or (1 up) to a point on the line y=x, else (1 left) or (1 up) to a point above line y=x. T(i,j)=number of paths to point (i-j,j), for 1<=j<=i, i >= 1.
8
1, 1, 3, 1, 2, 10, 1, 3, 7, 36, 1, 4, 5, 26, 137, 1, 5, 9, 19, 101, 543, 1, 6, 14, 14, 75, 406, 2219, 1, 7, 20, 28, 56, 305, 1676, 9285, 1, 8, 27, 48, 42, 230, 1270, 7066, 39587, 1, 9, 35, 75, 90, 174, 965, 5390, 30302, 171369, 1, 10, 44, 110, 165, 132, 735, 4120, 23236, 131782, 751236
OFFSET
0,3
FORMULA
Initial values: T(i, 0)=1 for i >= 0. Recurrence: if 1 <= j < i/2, then T(i, j) = T(i-1, j-1) + T(i-1, j), if j = i/2 then T(2j, j) = T(2j-2, j-1) + T(2j-1, j-1), otherwise T(2j-k, j) = T(2j-k+1, j) + T(2j-k-1, j-1) for j=k, k+1, k+2, ..., for k=1, 2, 3, ...
T(2n, n) = A000108(n) for n >= 0 (Catalan numbers).
T(n, n) = A002212(n+1).
T(n, n-1) = A045868(n).
T(n, k) = A030237(n-k+1, k) for n >= 1, 0 <= k < n/2.
From G. C. Greubel, Jan 29 2024: (Start)
T(n, k) = (n-2*k+2)*binomial(n+1, k)/(n-k+2) for 0 <= k < n/2, otherwise Catalan(n-k +1)*Hypergeometric2F1([n-2*k, (3+2*(n-k))/2], [3+n-k], -4).
Sum_{k=0..n} T(n, k) = A055451(n). (End)
EXAMPLE
Triangle begins as:
1;
1, 3;
1, 2, 10;
1, 3, 7, 36;
1, 4, 5, 26, 137;
1, 5, 9, 19, 101, 543;
1, 6, 14, 14, 75, 406, 2219;
1, 7, 20, 28, 56, 305, 1676, 9285;
1, 8, 27, 48, 42, 230, 1270, 7066, 39587;
...
T(4,4) defined as T(5,4)+T(3,3) when k=4, T(5,4) already defined when k=3.
MATHEMATICA
T[n_, 0]:= 1; T[n_, k_]:= T[n, k]= If[1<=k<n/2, T[n-1, k-1] + T[n-1, k], If[k==n/2, T[n-2, k-1] + T[n-1, k-1], T[n+1, k] + T[n-1, k-1] ]];
Table[T[n, k], {n, 0, 15}, {k, 0, n}]//Flatten (* G. C. Greubel, Jan 29 2024 *)
T[n_, k_]:= If[k<n/2, (n-2*k+2)*Binomial[n+1, k]/(n-k+2), CatalanNumber[ n-k+1]*Hypergeometric2F1[n-2*k, (3+2*(n-k))/2, 3+n-k, -4]];
Table[T[n, k], {n, 0, 15}, {k, 0, n}]//Flatten (* G. C. Greubel, Jan 29 2024 *)
PROG
(Magma)
B:=Binomial; G:=Gamma; F:=Factorial;
p:= func< n, k, j | B(n-2*k+j-1, j)*G(n-k+j+3/2)/(F(j)*G(n-k+3/2)*B(n-k+j+2, j)) >;
A030237:= func< n, k | (n-k+1)*Binomial(n+k, k)/(n+1) >;
function T(n, k) // T = A055450
if k lt n/2 then return A030237(n-k+1, k);
else return Round(Catalan(n-k+1)*(&+[p(n, k, j)*(-4)^j: j in [0..n]]));
end if;
end function;
[T(n, k): k in [0..n], n in [0..13]]; // G. C. Greubel, Jan 29 2024
(SageMath)
def A030237(n, k): return (n-k+1)*binomial(n+k, k)/(n+1)
def T(n, k): # T = A055450
if k<n/2: return A030237(n-k+1, k)
else: return round(catalan_number(n-k+1)*hypergeometric([n-2*k, (3+2*(n-k))/2], [3+n-k], -4))
flatten([[T(n, k) for k in range(n+1)] for n in range(13)]) # G. C. Greubel, Jan 29 2024
KEYWORD
nonn,tabl
AUTHOR
Clark Kimberling, May 18 2000
STATUS
approved