login
A239076
Number of self-inverse permutations p on [n] with displacement of elements restricted by 4: |p(i)-i| <= 4.
2
1, 1, 2, 4, 10, 26, 66, 158, 376, 891, 2137, 5140, 12376, 29756, 71468, 171596, 412084, 989800, 2377717, 5711705, 13720054, 32955996, 79161006, 190147558, 456743814, 1097123162, 2635347280, 6330234855, 15205529809, 36524416280, 87733426944, 210739993784
OFFSET
0,3
COMMENTS
Column k=4 of A238888.
LINKS
Joerg Arndt and Alois P. Heinz, Table of n, a(n) for n = 0..1000
FORMULA
G.f.: -(x+1)*(x^7 -x^6+2*x^5 -x^4 +x^3 +x-1) / (x^16 +x^15 +2*x^14 +x^13 +x^12 +2*x^11 +x^10 +3*x^9 -4*x^8 -5*x^7 -9*x^6 -6*x^5 -x^4 -x^3 -2*x^2 -x+1).
MAPLE
gf:= -(x+1)*(x^7 -x^6+2*x^5 -x^4 +x^3 +x-1) / (x^16 +x^15 +2*x^14 +x^13 +x^12 +2*x^11 +x^10 +3*x^9 -4*x^8 -5*x^7 -9*x^6 -6*x^5 -x^4 -x^3 -2*x^2 -x+1):
a:= n-> coeff(series(gf, x, n+1), x, n):
seq(a(n), n=0..40);
MATHEMATICA
CoefficientList[Series[-(x + 1) (x^7 - x^6 + 2 x^5 - x^4 + x^3 + x - 1)/(x^16 + x^15 + 2 x^14 + x^13 + x^12 + 2 x^11 + x^10 + 3 x^9 - 4 x^8 - 5 x^7 - 9 x^6 - 6 x^5 - x^4 - x^3 - 2 x^2 - x + 1), {x, 0, 50}], x] (* Vincenzo Librandi, Mar 12 2014 *)
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Joerg Arndt and Alois P. Heinz, Mar 10 2014
STATUS
approved