OFFSET
0,2
COMMENTS
T(n,k) is the number of (2*k)-step closed paths (from origin to origin) in 2-dimensional lattice, using steps (t_1,t_2) (|t_1| + |t_2| = 2*n+1).
T(n,k) is the constant term in the expansion of (Sum_{j=0..2*n+1} (x^j + 1/x^j)*(y^(2*n+1-j) + 1/y^(2*n+1-j)) - x^(2*n+1) - 1/x^(2*n+1) - y^(2*n+1) - 1/y^(2*n+1))^(2*k).
LINKS
Seiichi Manyama, Antidiagonals n = 0..50, flattened
Wikipedia, Taxicab geometry.
FORMULA
See the second code written in PARI.
EXAMPLE
Square array begins:
1, 4, 36, 400, 4900, ...
1, 12, 588, 49440, 5187980, ...
1, 20, 2100, 423440, 117234740, ...
1, 28, 4956, 1751680, 907687900, ...
1, 36, 9540, 5101200, 4190017860, ...
PROG
(PARI) {T(n, k) = polcoef(polcoef((sum(j=0, 2*n+1, (x^j+1/x^j)*(y^(2*n+1-j)+1/y^(2*n+1-j)))-x^(2*n+1)-1/x^(2*n+1)-y^(2*n+1)-1/y^(2*n+1))^(2*k), 0), 0)}
(PARI) f(n) = (x^(2*n+2)-1/x^(2*n+2))/(x-1/x);
T(n, k) = sum(j=0, 2*k, (-1)^j*binomial(2*k, j)*polcoef(f(n)^j*f(n-1)^(2*k-j), 0)^2)
CROSSREFS
KEYWORD
AUTHOR
Seiichi Manyama, Nov 03 2019
STATUS
approved