cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A156996 Triangle T(n, k) = coefficients of p(n,x), where p(n,x) = Sum_{j=0..n} (2*n*(n-j)!/(2*n-j)) * binomial(2*n-j, j) * (x-1)^j and p(0,x) = 1, read by rows.

This page as a plain text file.
%I A156996 #17 Sep 08 2022 08:45:41
%S A156996 1,-1,2,0,0,2,1,0,3,2,2,8,4,8,2,13,30,40,20,15,2,80,192,210,152,60,24,
%T A156996 2,579,1344,1477,994,469,140,35,2,4738,10800,11672,7888,3660,1232,280,
%U A156996 48,2,43387,97434,104256,70152,32958,11268,2856,504,63,2,439792,976000,1036050,695760,328920,115056,30300,6000,840,80,2
%N A156996 Triangle T(n, k) = coefficients of p(n,x), where p(n,x) = Sum_{j=0..n} (2*n*(n-j)!/(2*n-j)) * binomial(2*n-j, j) * (x-1)^j and p(0,x) = 1, read by rows.
%D A156996 J. Riordan, An Introduction to Combinatorial Analysis, Wiley, 1958, pp. 197-199
%H A156996 G. C. Greubel, <a href="/A156996/b156996.txt">Rows n = 0..50 of the triangle, flattened</a>
%H A156996 I. Kaplansky and J. Riordan, <a href="/A000166/a000166_1.pdf">The problème des ménages</a>, Scripta Math. 12, (1946), 113-124. [Scan of annotated copy]
%H A156996 Anthony C. Robin, <a href="http://www.jstor.org/stable/40378205">90.72 Circular Wife Swapping</a>, The Mathematical Gazette, Vol. 90, No. 519 (Nov., 2006), pp. 471-478.
%H A156996 L. Takacs, <a href="http://dx.doi.org/10.1016/S0012-365X(81)80024-6">On the probleme des menages</a>, Discr. Math. 36 (3) (1981) 289-297, Table 1.
%F A156996 T(n, k) = coefficients of p(n,x), where p(n,x) = Sum_{j=0..n} (2*n*(n-j)!/(2*n-j)) * binomial(2*n-j, j) * (x-1)^j and p(0,x) = 1.
%F A156996 Sum_{k=0..n} T(n, k) = n!.
%F A156996 From _G. C. Greubel_, May 14 2021: (Start)
%F A156996 T(n, 0) = A000179(n).
%F A156996 T(n, k) = Sum_{j=k..n} (-1)^(j+k)*(2*n*(n-j)!/(2*n-j))*binomial(j, k)*binomial(2*n-j, j), with T(0, k) = 1. (End)
%e A156996 Triangle begins as:
%e A156996        1;
%e A156996       -1,      2;
%e A156996        0,      0,       2;
%e A156996        1,      0,       3,      2;
%e A156996        2,      8,       4,      8,      2;
%e A156996       13,     30,      40,     20,     15,      2;
%e A156996       80,    192,     210,    152,     60,     24,     2;
%e A156996      579,   1344,    1477,    994,    469,    140,    35,    2;
%e A156996     4738,  10800,   11672,   7888,   3660,   1232,   280,   48,   2;
%e A156996    43387,  97434,  104256,  70152,  32958,  11268,  2856,  504,  63,  2;
%e A156996   439792, 976000, 1036050, 695760, 328920, 115056, 30300, 6000, 840, 80, 2;
%t A156996 (* first program *)
%t A156996 Table[CoefficientList[If[n==0, 1, Sum[Binomial[2*n-k, k]*(n-k)!*(2*n/(2*n-k))*(x- 1)^k, {k,0,n}]], x], {n,0,12}]//Flatten
%t A156996 (* Second program *)
%t A156996 T[n_, k_]:= If[n==0, 1, Sum[(-1)^(j-k)*(2*n*(n-j)!/(2*n-j))*Binomial[j, k]*Binomial[2*n-j, j], {j,k,n}]];
%t A156996 Table[T[n, k], {n,0,12}, {k,0,n}]//Flatten (* _G. C. Greubel_, May 14 2021 *)
%o A156996 (Magma)
%o A156996 A156996:= func< n,k | n eq 0 select 1 else (&+[(-1)^(j-k)*(2*n*Factorial(n-j)/(2*n-j))*Binomial(j, k)*Binomial(2*n-j, j): j in [k..n]]) >;
%o A156996 [A156996(n,k): k in [0..n], n in [0..12]]; // _G. C. Greubel_, May 14 2021
%o A156996 (Sage)
%o A156996 def A156996(n,k): return 1 if (n==0) else sum( (-1)^(j-k)*(2*n*factorial(n-j)/(2*n-j))*binomial(j, k)*binomial(2*n-j, j) for j in (k..n) )
%o A156996 flatten([[A156996(n,k) for k in (0..n)] for n in (0..12)]) # _G. C. Greubel_, May 14 2021
%Y A156996 Cf. A000179, A094314, A156995.
%K A156996 sign,tabl
%O A156996 0,3
%A A156996 _Roger L. Bagula_, Feb 20 2009
%E A156996 Edited by _G. C. Greubel_, May 14 2021