login
Number of length-n 0..5 arrays with no repeated value differing from the previous repeated value by other than one.
1

%I #8 Jan 23 2019 19:59:56

%S 6,36,210,1210,6890,38878,217714,1211476,6705102,36939610,202696070,

%T 1108372980,6042240154,32850033316,178168192702,964256946776,

%U 5208585411106,28086302736278,151213240334794,812960203889834

%N Number of length-n 0..5 arrays with no repeated value differing from the previous repeated value by other than one.

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

%F Empirical: a(n) = 17*a(n-1) - 92*a(n-2) + 96*a(n-3) + 493*a(n-4) - 533*a(n-5) - 1521*a(n-6) - 695*a(n-7).

%F Empirical g.f.: 2*x*(3 - 33*x + 75*x^2 + 188*x^3 - 387*x^4 - 821*x^5 - 354*x^6) / ((1 - 5*x)*(1 - 12*x + 32*x^2 + 64*x^3 - 173*x^4 - 332*x^5 - 139*x^6)). - _Colin Barker_, Jan 23 2019

%e Some solutions for n=6:

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

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

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

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

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

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

%Y Column 5 of A269537.

%K nonn

%O 1,1

%A _R. H. Hardin_, Feb 29 2016