# Greetings from The On-Line Encyclopedia of Integer Sequences! http://oeis.org/ Search: id:a026789 Showing 1-1 of 1 %I A026789 #11 Feb 10 2022 09:18:27 %S A026789 1,3,8,19,45,103,239,545,1262,2887,6700,15397,35848,82757,193320, %T A026789 448175,1050217,2443963,5743267,13410053,31593029,73984575,174689181, %U A026789 410141597,970289011,2283205051,5410611863,12756825609,30274963923 %N A026789 a(n) = Sum_{i=0..n} Sum_{j=0..n} T(i,j), T given by A026780. %H A026789 G. C. Greubel, Table of n, a(n) for n = 0..1000 %p A026789 T:= proc(n,k) option remember; %p A026789 if n<0 then 0; %p A026789 elif k=0 or k =n then 1; %p A026789 elif k <= n/2 then %p A026789 procname(n-1,k-1)+procname(n-2,k-1)+procname(n-1,k) ; %p A026789 else %p A026789 procname(n-1,k-1)+procname(n-1,k) ; %p A026789 fi ; %p A026789 end proc: %p A026789 seq( add(add(T(j,k), k=0..n), j=0..n), n=0..30); # _G. C. Greubel_, Nov 02 2019 %t A026789 T[n_, k_]:= T[n, k]= If[n<0, 0, If[k==0 || k==n, 1, If[k<=n/2, T[n-1, k-1] + T[n-2, k-1] + T[n-1, k], T[n-1, k-1] + T[n-1, k] ]]]; %t A026789 Table[Sum[T[j, k], {k, 0, n}, {j, 0, n}], {n,0,30}] (* _G. C. Greubel_, Nov 02 2019 *) %o A026789 (Sage) %o A026789 @CachedFunction %o A026789 def T(n, k): %o A026789 if (n<0): return 0 %o A026789 elif (k==0 or k==n): return 1 %o A026789 elif (k<=n/2): return T(n-1,k-1) + T(n-2,k-1) + T(n-1,k) %o A026789 else: return T(n-1,k-1) + T(n-1,k) %o A026789 [sum( sum( T(j,k) for k in (0..n)) for j in (0..n)) for n in (0..30)] # _G. C. Greubel_, Nov 02 2019 %Y A026789 Partial sums of A026787. %Y A026789 Cf. A026780, A026781, A026782, A026783, A026784, A026785, A026786, A026788, A026790. %K A026789 nonn %O A026789 0,2 %A A026789 _Clark Kimberling_ # Content is available under The OEIS End-User License Agreement: http://oeis.org/LICENSE