login
Number of length n arrays of permutations of 0..n-1 with each element moved by -3 to 3 places and the median of every three consecutive elements nondecreasing.
1

%I #8 Jan 02 2019 07:24:06

%S 1,2,6,16,41,108,280,729,1908,4969,12950,33796,88112,229740,599191,

%T 1562470,4074372,10625188,27707446,72253034,188417568,491341657,

%U 1281284446,3341248089,8713071846,22721332009,59251115518,154510913809

%N Number of length n arrays of permutations of 0..n-1 with each element moved by -3 to 3 places and the median of every three consecutive elements nondecreasing.

%H R. H. Hardin, <a href="/A263592/b263592.txt">Table of n, a(n) for n = 1..210</a>

%F Empirical: a(n) = a(n-1) + a(n-2) + 7*a(n-3) + 2*a(n-4) + 4*a(n-5) - a(n-7) - a(n-8).

%F Empirical g.f.: x*(1 + x + 3*x^2 + x^3 + 3*x^4 + x^5 - x^6 - x^7) / (1 - x - x^2 - 7*x^3 - 2*x^4 - 4*x^5 + x^7 + x^8). - _Colin Barker_, Jan 02 2019

%e Some solutions for n=6:

%e ..2....1....0....1....3....0....1....1....1....0....0....2....0....1....0....0

%e ..0....0....1....0....1....1....0....0....0....1....3....0....4....0....1....1

%e ..3....2....5....4....0....3....3....5....2....2....2....4....1....3....2....2

%e ..5....3....2....3....5....5....5....2....4....4....1....3....2....5....4....5

%e ..1....4....3....2....4....4....4....3....5....5....4....1....3....2....3....4

%e ..4....5....4....5....2....2....2....4....3....3....5....5....5....4....5....3

%Y Column 3 of A263597.

%K nonn

%O 1,2

%A _R. H. Hardin_, Oct 22 2015