login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

Number of length-5 0..n arrays with no repeated value differing from the previous repeated value by other than plus or minus one modulo n+1.
1

%I #8 Jan 26 2019 11:10:17

%S 14,174,820,2670,6918,15358,30504,55710,95290,154638,240348,360334,

%T 523950,742110,1027408,1394238,1858914,2439790,3157380,4034478,

%U 5096278,6370494,7887480,9680350,11785098,14240718,17089324,20376270,24150270

%N Number of length-5 0..n arrays with no repeated value differing from the previous repeated value by other than plus or minus one modulo n+1.

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

%F Empirical: a(n) = n^5 + 5*n^4 + 4*n^3 + 6*n^2 + 4*n - 2 for n>1.

%F Conjectures from _Colin Barker_, Jan 26 2019: (Start)

%F G.f.: 2*x*(7 + 45*x - 7*x^2 + 40*x^3 - 36*x^4 + 13*x^5 - 2*x^6) / (1 - x)^6.

%F a(n) = 6*a(n-1) - 15*a(n-2) + 20*a(n-3) - 15*a(n-4) + 6*a(n-5) - a(n-6) for n>7.

%F (End)

%e Some solutions for n=3:

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

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

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

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

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

%Y Row 5 of A269678.

%K nonn

%O 1,1

%A _R. H. Hardin_, Mar 03 2016