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 #12 Sep 08 2022 08:45:28
%S 1,1,2,1,4,5,1,6,15,11,1,8,30,44,26,1,10,50,110,130,59,1,12,75,220,
%T 390,354,137,1,14,105,385,910,1239,959,314,1,16,140,616,1820,3304,
%U 3836,2512,725,1,18,180,924,3276,7434,11508,11304,6525,1667,1,20,225,1320,5460,14868,28770,37680,32625,16670,3842
%N Triangle read by rows: T(n,k) = a(k)*binomial(n,k) (0 <= k <= n), where a(0)=1, a(1)=2, a(k) = a(k-1) + 3*a(k-2) for k >= 2 (a(k) = A006138(k)).
%C Sum of entries in row n = A006190(n+1).
%H G. C. Greubel, <a href="/A124959/b124959.txt">Rows n = 0..100 of triangle, flattened</a>
%e First few rows of the triangle:
%e 1;
%e 1, 2;
%e 1, 4, 5;
%e 1, 6, 15, 11;
%e 1, 8, 30, 44, 26;
%e 1, 10, 50, 110, 130, 59;
%e ...
%p a:=proc(n) if n=0 then 1 elif n=1 then 2 else a(n-1)+3*a(n-2) fi end: T:=(n,k)->a(k)*binomial(n,k): for n from 0 to 10 do seq(T(n,k),k=0..n) od; # yields sequence in triangular form
%t T[n_, k_]:= T[n, k]= Simplify[(I*Sqrt[3])^(k-1)*Binomial[n,k]*(I*Sqrt[3]* ChebyshevU[k, 1/(2*I*Sqrt[3])] + ChebyshevU[k-1, 1/(2*I*Sqrt[3])])];
%t Table[T[n, k], {n,0,12}, {k,0,n}]//Flatten (* _G. C. Greubel_, Nov 19 2019 *)
%o (PARI)
%o b(k) = if(k<2, k+1, b(k-1) + 3*b(k-2));
%o T(n,k) = binomial(n,k)*b(k);
%o for(n=0,10, for(k=0,n, print1(T(n,k), ", "))) \\ _G. C. Greubel_, Nov 19 2019
%o (Magma)
%o function b(k)
%o if k lt 2 then return k+1;
%o else return b(k-1) + 3*b(k-2);
%o end if;
%o return b;
%o end function;
%o [Binomial(n,k)*b(k): k in [0..n], n in [0..12]]; // _G. C. Greubel_, Nov 19 2019
%o (Sage)
%o @CachedFunction
%o def b(k):
%o if (k<2): return k+1
%o else: return b(k-1) + 3*b(k-2)
%o [[binomial(n, k)*b(k) for k in (0..n)] for n in (0..12)] # _G. C. Greubel_, Nov 19 2019
%Y Cf. A006138, A006190.
%K nonn,tabl
%O 0,3
%A _Gary W. Adamson_, Nov 13 2006
%E Edited by _N. J. A. Sloane_, Dec 03 2006