%I #30 May 25 2023 07:29:03
%S 1,2,2,4,6,4,8,16,16,8,16,40,52,40,16,32,96,152,152,96,32,64,224,416,
%T 504,416,224,64,128,512,1088,1536,1536,1088,512,128,256,1152,2752,
%U 4416,5136,4416,2752,1152,256,512,2560,6784,12160,16032,16032,12160,6784,2560,512
%N Triangle read by rows: T(n,k) is coefficient of z^n*w^k in 1/(1 - 2*z - 2*w + 2*z*w) read by rows in order 00, 10, 01, 20, 11, 02, ...
%C Pascal-like triangle: start with 1 at top; every subsequent entry is the sum of everything above you, plus 1.
%H G. C. Greubel, <a href="/A059474/b059474.txt">Rows n = 0..50 of the triangle, flattened</a>
%F G.f.: 1/(1 - 2*z - 2*w + 2*z*w).
%F T(n, k) = Sum_{j=0..n} (-1)^j*2^(n + k - j)*C(n, j)*C(n + k - j, n).
%F T(n, 0) = T(n, n) = A000079(n).
%F T(2*n, n) = A084773(n).
%F T(n, k) = 2^n*binomial(n, k)*hypergeom([-k, k - n], [-n], 1/2). - _Peter Luschny_, Nov 26 2021
%F From _G. C. Greubel_, May 21 2023: (Start)
%F T(n, n-k) = T(n, k).
%F Sum_{k=0..n} T(n, k) = A007070(n).
%F Sum_{k=0..n} (-1)^k * T(n, k) = A077957(n).
%F T(n, 1) = A057711(n+1) = 2*A001792(n) - [n=0].
%F T(n, 2) = 4*A049611(n-1). (End)
%e Triangle begins as:
%e n\k [0] [1] [2] [3] [4] [5] [6] ...
%e [0] 1;
%e [1] 2, 2;
%e [2] 4, 6, 4;
%e [3] 8, 16, 16, 8;
%e [4] 16, 40, 52, 40, 16;
%e [5] 32, 96, 152, 152, 96, 32;
%e [6] 64, 224, 416, 504, 416, 224, 64;
%e ...
%p read transforms; SERIES2(1/(1-2*z-2*w+2*z*w),x,y,12): SERIES2TOLIST(%,x,y,12);
%p # Alternative
%p T := (n, k) -> 2^n*binomial(n, k)*hypergeom([-k, -n + k], [-n], 1/2):
%p for n from 0 to 10 do seq(simplify(T(n, k)), k = 0 .. n) end do; # _Peter Luschny_, Nov 26 2021
%t Table[(-1)^k*2^n*JacobiP[k, -n-1,0,0], {n,0,12}, {k,0,n}]//Flatten (* _G. C. Greubel_, Oct 04 2017; May 21 2023 *)
%o (Magma)
%o A059474:= func< n,k | (&+[(-1)^j*2^(n-j)*Binomial(n-k,j)*Binomial(n-j,n-k): j in [0..n-k]]) >;
%o [A059474(n,k): k in [0..n], n in [0..12]]; // _G. C. Greubel_, May 21 2023
%o (SageMath)
%o def A059474(n,k): return 2^n*binomial(n, k)*simplify(hypergeometric([-k, k-n], [-n], 1/2))
%o flatten([[A059474(n,k) for k in range(n+1)] for n in range(13)]) # _G. C. Greubel_, May 21 2023
%Y Cf. A000079, A001792, A007070, A057711, A077957, A084773.
%Y See A059576 for a similar triangle.
%K nonn,tabl,easy
%O 0,2
%A _N. J. A. Sloane_, Feb 03, 2001; revised Jun 12 2005