%I #17 Jul 29 2024 09:49:40
%S 1,2,6,18,54,162,486,1394,3991,11593,33772,98320,286072,831952,
%T 2418664,7030816,20441944,59441521,172843609,502580846,1461344622,
%U 4249102850,12354982862,35924300898,104456501102,303726483778,883140022543
%N Number of permutations satisfying i-2<=p(i)<=i+6, i=1..n.
%H R. H. Hardin, <a href="/A072853/b072853.txt">Table of n, a(n) for n=1..400</a>
%H Vladimir Baltic, <a href="http://pefmath.etf.rs/vol4num1/AADM-Vol4-No1-119-135.pdf">On the number of certain types of strongly restricted permutations</a>, Applicable Analysis and Discrete Mathematics Vol. 4, No 1 (April, 2010), 119-135
%H <a href="/index/Rec#order_28">Index entries for linear recurrences with constant coefficients</a>, signature (1, 2, 4, 8, 14, 26, 44, 56, -11, -19, -28, -28, 0, -8, -20, -20, 0, 5, 11, 10, 0, 0, 2, 2, 0, 0, -1, -1).
%F Recurrence: a(n)= a(n - 1) + 2*a(n - 2) + 4*a(n - 3) + 8*a(n - 4) + 14*a(n - 5) + 26*a(n - 6) + 44*a(n - 7) + 56*a(n - 8) - 11*a(n - 9) - 19*a(n - 10) - 28*a(n - 11) - 28*a(n - 12) - 8*a(n - 14) - 20*a(n - 15) - 20*a(n - 16) + 5*a(n - 18) + 11*a(n - 19) + 10*a(n - 20) + 2*a(n - 23) + 2*a(n - 24) - a(n - 27) - a(n - 28).
%F G.f.: - (x^20 + x^18 - 2*x^16 - 2*x^14 - 6*x^12 - 2*x^11 - 4*x^10 - 4*x^9 + 12*x^8 + 2*x^7 + 8*x^6 + 6*x^5 + 4*x^4 + 2*x^3 + x^2 - 1)/(x^28 + x^27 - 2*x^24 - 2*x^23 - 10*x^20 - 11*x^19 - 5*x^18 + 20*x^16 + 20*x^15 + 8*x^14 + 28*x^12 + 28*x^11 + 19*x^10 + 11*x^9 - 56*x^8 - 44*x^7 - 26*x^6 - 14*x^5 - 8*x^4 - 4*x^3 - 2*x^2 - x + 1).
%Y Cf. A002524..A002529, A072827, A072850..A072856, A079955..A080014.
%K nonn
%O 1,2
%A _Vladimir Baltic_, Jul 25 2002