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.

Showing 1-7 of 7 results.

A000271 Sums of ménage numbers.

Original entry on oeis.org

1, 0, 0, 1, 3, 16, 96, 675, 5413, 48800, 488592, 5379333, 64595975, 840192288, 11767626752, 176574062535, 2825965531593, 48052401132800, 865108807357216, 16439727718351881, 328839946389605643, 6906458590966507696
Offset: 0

Views

Author

Keywords

Comments

Permanent of the (0,1)-matrix having (i,j)-th entry equal to 0 iff this is on the diagonal or the first upper-diagonal. - Simone Severini, Oct 14 2004
Equivalently, number of permutations p of {1,2,...,n} such that p(i)-i not in {0,1}. - Andrew Howroyd, Sep 19 2017
From Vladimir Shevelev, Jun 21 2015: (Start)
Let 2*n!*V(n)=A137886(n) be the number of ways of seating n married couples at 2*n chairs arranged side-by-side in a straight line, men and women in alternate positions, so that no husband is next to his wife.
It is known [Riordan, Ch. 8, Th. 1, t=0] that, if 2*n!*U(n) is a solution of an analogous problem at a circular table, then U(n) = V(n) - V(n-1), n>=3, where U(n) = A000179(n). Thus V(n) = Sum_{i=3,...,n} A000179(i), n>=1, and comparing the initial conditions, we conclude that a(n) = V(n), n>=1. This gives a combinatorial interpretation for 2*n!*a(n).
(End)

Examples

			G.f. = 1 + x^3 + 3*x^4 + 16*x^5 + 96*x^6 + 675*x^7 + 5413*x^8 + ...
		

References

  • W. Ahrens, Mathematische Unterhaltungen und Spiele. Teubner, Leipzig, Vol. 1, 3rd ed., 1921; Vol. 2, 2nd ed., 1918. See Vol. 2, p. 79.
  • J. Riordan, An Introduction to Combinatorial Analysis, Wiley, 1958, p. 198.
  • N. J. A. Sloane, A Handbook of Integer Sequences, Academic Press, 1973 (includes this sequence).
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).
  • H. M. Taylor, A problem on arrangements, Mess. Math., 32 (1902), 60ff.

Crossrefs

Cf. A000179, A000904, A001883, A137886, A292574. A diagonal of A058057.

Programs

  • Magma
    [ &+[(-1)^(n-k)*Binomial(n+k, 2*k)*Factorial(k): k in [0..n]]: n in [0..21]]; // Bruno Berselli, Apr 11 2011
    
  • Maple
    V := proc(n) local k; add( binomial(2*n-k,k)*(n-k)!*(x-1)^k, k=0..n); end; W := proc(r,s) coeff( V(r),x,s ); end; A000271 := n->W(n-2,0);
  • Mathematica
    Table[Sum[(-1)^(n - k) k! Binomial[n + k, 2 k], {k, 0, n}], {n, 0, 22}] (* Jean-François Alcover, Apr 11 2011, after Paul Barry *)
    RecurrenceTable[{a[0] == 1, a[1] == a[2] == 0, a[n] == (n - 1) a[n - 2] + (n - 1) a[n - 1] +  a[n - 3]}, a, {n, 30}] (* Harvey P. Dale, Jun 01 2012 *)
    Table[(-1)^n HypergeometricPFQ[{1, -n, n + 1}, {1/2}, 1/4], {n, 20}] (* Michael Somos, May 28 2014 *)
  • PARI
    a(n) = if(n, round( 2*exp(-2)*(besselk(n+1,2) + besselk(n,2)) ), 1) \\ Charles R Greathouse IV, May 11 2016

Formula

a(n) = (n - 1) a(n - 2) + (n - 1) a(n - 1) + a(n - 3).
From Paul Barry, Feb 08 2009: (Start)
G.f.: 1/(1+x-x/(1+x-x/(1+x-2x/(1+x-2x/(1+x-3x/(1+x-3x/(1+x-4x/(1+... (continued fraction);
a(n) = Sum_{k=0..n} binomial(2n-k,k)*(n-k)!*(-1)^k. (End)
a(n) = (-1)^n*hypergeom([1, -n, n+1],[1/2],1/4). - Mark van Hoeij, Nov 12 2009
a(n) = round( 2*exp(-2)*(BesselK(1+n,2) + BesselK(n,2)) ) for n>0. - Mark van Hoeij, Nov 12 2009
a(n) = Sum_{k=0..n} (-1)^(n-k)*binomial(n+k,2*k)*k!. - Paul Barry, Jun 23 2010
G.f.: Sum_{n>=0} n!*x^n/(1+x)^(2*n+1). - Ira M. Gessel, Jan 15 2013
a(n) ~ exp(-2)*n!. - Vaclav Kotesovec, Mar 10 2014
a(-1 - n) = -a(n) for all n in Z. - Michael Somos, May 28 2014
a(n) = Sum_{i=3..n} A000179(i), n>=1. - Vladimir Shevelev, Jun 21 2015
0 = a(n)*(-a(n+2) - a(n+3)) + a(n+1)*(+a(n+1) + 2*a(n+2) + a(n+3) - a(n+4)) + a(n+2)*(+a(n+2) + 2*a(n+3) - a(n+4)) + a(n+3)*(+a(n+3)) for all n in Z. - Michael Somos, Oct 16 2016

Extensions

More terms from James Sellers, Aug 21 2000
More terms from Simone Severini, Oct 14 2004

A000426 Coefficients of ménage hit polynomials.

Original entry on oeis.org

0, 1, 1, 1, 8, 35, 211, 1459, 11584, 103605, 1030805, 11291237, 135015896, 1749915271, 24435107047, 365696282855, 5839492221440, 99096354764009, 1780930394412009, 33789956266629001, 674939337282352360, 14157377139256183723, 311135096550816014651
Offset: 1

Views

Author

Keywords

References

  • J. Riordan, An Introduction to Combinatorial Analysis, Wiley, 1958, p. 198.
  • N. J. A. Sloane, A Handbook of Integer Sequences, Academic Press, 1973 (includes this sequence).
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).
  • H. M. Taylor, A problem on arrangements, Mess. Math., 32 (1902), 60ff.

Crossrefs

Cf. A000179, A000271. A diagonal of A058057.

Programs

  • Magma
    [0] cat [&+[(-1)^k*Factorial(2*n-k-1)*Factorial(n-k) / (Factorial(2*n-2*k)*Factorial(k-2)): k in [2..n]]: n in [2..25]]; // Vincenzo Librandi, Jun 11 2019
  • Mathematica
    Table[Sum[(-1)^k*(2*n-k-1)!*(n-k)!/((2*n-2*k)!*(k-2)!),{k,2,n}],{n,1,20}] (* Vaclav Kotesovec, Oct 26 2012 *)

Formula

a(n) = Sum_{k=2..n} (-1)^k*(2n-k-1)!*(n-k)!/((2n-2k)!*(k-2)!).
a(n) = A000033(n)/n.
a(n) = ((2*n-5)*a(n-1) + (5*n-11)*a(n-2) + (5*n-14)*a(n-3) + (2*n-5)*a(n-4) + 2*a(n-5))/2 for n >= 6.
Shorter recurrence: (14*n-67)*a(n) = (14*n^2-95*n+137)*a(n-1) + (14*n^2-105*n+180)*a(n-2) - 24*a(n-4) + (57-10*n)*a(n-3). - Vaclav Kotesovec, Oct 26 2012
a(n) ~ 2/e^2*(n-1)!. - Vaclav Kotesovec, Oct 26 2012
a(n) = round((exp(-2)*(8*BesselK(n,2) - (4*n-10)*BesselK(n-1,2)))) for n > 6. - Mark van Hoeij, Jun 09 2019
a(n)+2*a(n+p)+a(n+2*p) is divisible by p for any prime p. - Mark van Hoeij, Jun 13 2019

Extensions

Edited by David W. Wilson, Dec 27 2007

A000222 Coefficients of ménage hit polynomials.

Original entry on oeis.org

0, 0, 1, 3, 6, 38, 213, 1479, 11692, 104364, 1036809, 11344859, 135548466, 1755739218, 24504637741, 366596136399, 5852040379224, 99283915922264, 1783921946910417, 33840669046326579, 675849838112277598, 14174636583759324798
Offset: 0

Views

Author

Keywords

References

  • J. Riordan, An Introduction to Combinatorial Analysis, Wiley, 1958, p. 198.
  • N. J. A. Sloane, A Handbook of Integer Sequences, Academic Press, 1973 (includes this sequence).
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

A diagonal of A058057.

Programs

  • Mathematica
    max = 30; f[x_, y_] := Sum[n!*((x*y)^n/(1+x*(y-1))^(2*n+1)), {n, 0, max}]; t = MapIndexed[Take[#1, First[#2]]&, CoefficientList[Series[f[x, y], {x, 0, max}, {y, 0, max}], {x, y}]] ; a[0] = a[1] = 0; a[n_] := t[[n+1, n-1]]; Table[a[n], {n, 0, max}] (* Jean-François Alcover, Mar 11 2014, after Vladeta Jovovic *)

Formula

a(n) ~ 2/exp(2) * n!. - Vaclav Kotesovec, Sep 06 2014
a(n)+2*a(n+p)+a(n+2*p) is divisible by p for any prime p. - Mark van Hoeij, Jun 13 2019

A000386 Coefficients of ménage hit polynomials.

Original entry on oeis.org

0, 0, 0, 1, 6, 20, 134, 915, 7324, 65784, 657180, 7223637, 86637650, 1125842556, 15757002706, 236298742375, 3780061394232, 64251145312880, 1156374220457784, 21968796934412649, 439337048505773790, 9225384943965382564, 202945418255342821470
Offset: 0

Views

Author

Keywords

References

  • J. Riordan, An Introduction to Combinatorial Analysis, Wiley, 1958, p. 198.
  • N. J. A. Sloane, A Handbook of Integer Sequences, Academic Press, 1973 (includes this sequence).
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

A diagonal of A058057.

Programs

  • Mathematica
    max = 22; f[x_, y_] := Sum[n!*((x*y)^n/(1+x*(y-1))^(2*n+1)), {n, 0, max}]; t = MapIndexed[Take[#1, #2[[1]]]&, CoefficientList[Series[f[x, y], {x, 0, max}, {y, 0, max}], {x, y}]]; a[n_] := If[n<3, 0, t[[n+1, n-2]]]; Table[ a[n], {n, 0, max}] (* Jean-François Alcover, Feb 08 2016, after Vladeta Jovovic in A058057 *)

A000450 Coefficients of ménage hit polynomials.

Original entry on oeis.org

1, 10, 50, 385, 3130, 28764, 291900, 3249210, 39367395, 515874470, 7270929806, 109691447395, 1763782644020, 30114243100760, 544123405603800, 10373304279494964, 208092476689208805, 4381794437494059810, 96635643877147885450, 2227562535558247510885
Offset: 4

Views

Author

Keywords

References

  • J. Riordan, An Introduction to Combinatorial Analysis, Wiley, 1958, p. 198.
  • N. J. A. Sloane, A Handbook of Integer Sequences, Academic Press, 1973 (includes this sequence).
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

A diagonal of A058057.

Programs

  • Mathematica
    max = 23; f[x_, y_] := Sum[n!*((x*y)^n/(1 + x*(y-1))^(2*n+1)), {n, 0, max} ]; t = MapIndexed[Take[#1, #2[[1]]]&, CoefficientList[Series[f[x, y], {x, 0, max}, {y, 0, max}], {x, y}]]; a[n_] := t[[n+1, n-3]]; Table[a[n], {n, 4, max}] (* Jean-François Alcover, Feb 08 2016, after Vladeta Jovovic in A058057 *)

A058085 Coefficients of ménage hit polynomials.

Original entry on oeis.org

1, 15, 105, 952, 9090, 95382, 1087842, 13434840, 178777899, 2551800461, 38906449491, 631240265424, 10861179600740, 197569486825452, 3788783963810532, 76401913920275280, 1616286241420420437, 35794282853874086955, 828206562646486747645
Offset: 5

Views

Author

N. J. A. Sloane, Dec 02 2000

Keywords

References

  • J. Riordan, An Introduction to Combinatorial Analysis, Wiley, 1958, p. 198.

Crossrefs

A diagonal of A058057.

A058086 Coefficients of ménage hit polynomials.

Original entry on oeis.org

1, 21, 196, 2100, 23310, 277662, 3541188, 48323988, 703842951, 10911044795, 179505659256, 3125293564568, 57431191568268, 1111135121304012, 22580910916230360, 480992394437882040, 10717471923433878141, 249346024282594457841
Offset: 6

Views

Author

N. J. A. Sloane, Dec 02 2000

Keywords

References

  • J. Riordan, An Introduction to Combinatorial Analysis, Wiley, 1958, p. 198.

Crossrefs

A diagonal of A058057.
Showing 1-7 of 7 results.