A321048 Number of permutations of [n] with no fixed points where the maximal displacement of an element equals two.
0, 2, 3, 6, 12, 24, 44, 84, 159, 300, 564, 1064, 2004, 3774, 7107, 13386, 25208, 47472, 89400, 168360, 317055, 597080, 1124424, 2117520, 3987720, 7509690, 14142275, 26632782, 50154948, 94451976, 177872292, 334969724, 630816159, 1187955204, 2237161404
Offset: 2
Links
- Alois P. Heinz, Table of n, a(n) for n = 2..2000
- Index entries for linear recurrences with constant coefficients, signature (2,0,0,0,-2,1).
Formula
G.f.: (x-2)*x^3/((x-1)*(x+1)*(x^4-2*x^3+x^2-2*x+1)).
a(n) = 2*a(n-1) - 2*a(n-5) + a(n-6). - Wesley Ivan Hurt, May 17 2023