%I #21 Jan 07 2024 02:16:21
%S 1,1,1,1,5,1,1,6,6,1,1,7,12,7,1,1,8,19,19,8,1,1,9,27,38,27,9,1,1,10,
%T 36,65,65,36,10,1,1,11,46,101,130,101,46,11,1,1,12,57,147,231,231,147,
%U 57,12,1,1,13,69,204,378,462,378,204,69,13,1,1,14,82,273,582,840,840,582,273,82,14,1
%N Elements in the 5-Pascal triangle (by row).
%H G. C. Greubel, <a href="/A028313/b028313.txt">Rows n = 0..50 of the triangle, flattened</a>
%F From _Ralf Stephan_, Jan 31 2005: (Start)
%F T(n, k) = C(n, k) + 3*C(n-2, k-1), with T(0, k) = T(1, k) = 1.
%F G.f.: (1 + 3*x^2*y)/(1 - x*(1+y)). (End)
%F From _G. C. Greubel_, Jan 05 2024: (Start)
%F T(n, n-k) = T(n, k).
%F T(n, n-1) = n + 3*(1 - [n=1]) = A178915(n+3), n >= 1.
%F T(n, n-2) = A051936(n+2), n >= 2.
%F T(n, n-3) = A051937(n+1), n >= 3.
%F T(2*n, n) = A028322(n).
%F Sum_{k=0..n} T(n, k) = A005009(n-2) - (3/4)*[n=0] - (3/2)*[n=1].
%F Sum_{k=0..n} (-1)^k * T(n, k) = A000007(n) - 3*[n=2].
%F Sum_{k=0..floor(n/2)} T(n-k, k) = A022112(n-2) + 3*([n=0] - [n=1]).
%F Sum_{k=0..floor(n/2)} (-1)^k * T(n-k, k) = 4*A010892(n) - 3*([n=0] + [n=1]). (End)
%e Triangle begins as:
%e 1;
%e 1, 1;
%e 1, 5, 1;
%e 1, 6, 6, 1;
%e 1, 7, 12, 7, 1;
%e 1, 8, 19, 19, 8, 1;
%e 1, 9, 27, 38, 27, 9, 1;
%e 1, 10, 36, 65, 65, 36, 10, 1;
%e 1, 11, 46, 101, 130, 101, 46, 11, 1;
%e 1, 12, 57, 147, 231, 231, 147, 57, 12, 1;
%t Table[If[n<2, 1, Binomial[n,k] +3*Binomial[n-2,k-1]], {n,0,12}, {k,0,n}]//Flatten (* _G. C. Greubel_, Jan 05 2024 *)
%o (Magma) [n le 1 select 1 else Binomial(n,k) +3*Binomial(n-2,k-1): k in [0..n], n in [0..12]]; // _G. C. Greubel_, Jan 05 2024
%o (SageMath)
%o def A028313(n,k): return 1 if n<2 else binomial(n,k) + 3*binomial(n-2,k-1)
%o flatten([[A028313(n,k) for k in range(n+1)] for n in range(13)]) # _G. C. Greubel_, Jan 05 2024
%Y Cf. A000007, A005009, A010892, A022112, A028275, A028314, A028315.
%Y Cf. A028316, A028317, A028318, A028319, A028320, A028321, A028322.
%Y Cf. A028323, A028324, A028325, A029653, A051472, A051936, A051937.
%Y Cf. A178915.
%K nonn,tabl
%O 0,5
%A _Mohammad K. Azarian_
%E More terms from Sam Alexander (pink2001x(AT)hotmail.com)