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”).
%I #22 Sep 08 2022 08:45:01
%S 1,1,1,1,2,1,1,5,3,1,1,11,9,4,1,1,23,24,14,5,1,1,47,60,43,20,6,1,1,95,
%T 144,122,69,27,7,1,1,191,336,328,217,103,35,8,1,1,383,768,848,640,354,
%U 146,44,9,1,1,767,1728,2128,1800,1131,543,199,54,10,1
%N Triangle T read by rows: T(i,j) = R(i-j,j), where R(i,0) = R(0,i) = 1 for i >= 0, R(i,j) = Sum_{h=0..i-1} Sum_{m=0..j} R(h,m) for i >= 1, j >= 1.
%H G. C. Greubel, <a href="/A055818/b055818.txt">Rows n = 0..100 of triangle, flattened</a>
%H Clark Kimberling, <a href="https://www.fq.math.ca/Scanned/40-4/kimberling.pdf">Path-counting and Fibonacci numbers</a>, Fib. Quart. 40 (4) (2002) 328-338, Example 3B.
%e Rows begins as:
%e 1;
%e 1, 1;
%e 1, 2, 1;
%e 1, 5, 3, 1;
%e 1, 11, 9, 4, 1;
%e ...
%p T:= proc(i, j) option remember;
%p if i=0 or j=0 then 1
%p else add(add(T(h,m), m=0..j), h=0..i-1)
%p fi; end:
%p seq(seq(T(n-k, k), k=0..n), n=0..12); # _G. C. Greubel_, Jan 21 2020
%t T[i_, j_]:= T[i, j]= If[i==0 || j==0, 1, Sum[T[h, m], {h,0,i-1}, {m,0,j}]]; Table[T[n-k, k], {n,0,12}, {k,0,n}]//Flatten (* _G. C. Greubel_, Jan 21 2020 *)
%o (PARI) T(i,j) = if(i==0 || j==0, 1, sum(h=0,i-1, sum(m=0,j, T(h,m) )));
%o for(n=0,12, for(k=0, n, print1(T(n-k,k), ", "))) \\ _G. C. Greubel_, Jan 21 2020
%o (Magma)
%o function T(i,j)
%o if i eq 0 or j eq 0 then return 1;
%o else return (&+[(&+[T(h,m): m in [0..j]]): h in [0..i-1]]);
%o end if; return T; end function;
%o [T(n-k,k): k in [0..n], n in [0..12]]; // _G. C. Greubel_, Jan 21 2020
%o (Sage)
%o @CachedFunction
%o def T(i, j):
%o if (i==0 or j==0): return 1
%o else: return sum(sum(T(h,m) for m in (0..j)) for h in (0..i-1))
%o [[T(n-k, k) for k in (0..n)] for n in (0..12)] # _G. C. Greubel_, Jan 21 2020
%o (GAP)
%o T:= function(i,j)
%o if i=0 or j=0 then return 1;
%o else return Sum([0..i-1], h-> Sum([0..j], m-> T(h,m) ));
%o fi; end;
%o Flat(List([0..12], n-> List([0..n], k-> T(n-k,k) ))); # _G. C. Greubel_, Jan 21 2020
%Y Cf. A055819, A055820, A055821, A055822, A055823, A055824, A055825, A055826, A055827, A055828, A055829.
%K nonn,tabl
%O 0,5
%A _Clark Kimberling_, May 28 2000