login
Let u(1)=u(2)=1 and u(k)=abs(u(k-1)-u(k-2)-n); sequence gives length of period of u(k).
1

%I #14 Jul 12 2018 08:57:57

%S 1,18,4,18,18,48,28,54,8,72,26,36,42,36,36,24,24,48,10,162,52,84,114,

%T 192,24,246,88,30,30,48,168,138,32,126,98,312,126,222,100,228,16,384,

%U 80,258,120,192,26,360,20,300,16,360,178,180,430,390,32,162,170,192,42,306

%N Let u(1)=u(2)=1 and u(k)=abs(u(k-1)-u(k-2)-n); sequence gives length of period of u(k).

%C u(k) is periodic for any n - see Reble link.

%H Don Reble, <a href="/A080694/a080694.ps">On the wholeness of Sloane's A080694</a>

%e When n=3, {u(k)} sequence is 1, 1, 3, 1, 5, 1, 7, 3, 7, 1, 9, 5, 7, 1, 9, 5, 7, 1, 9, 5, 7, 1, ... with period (7, 1, 9, 5) of length 4, hence a(3)=4. If n=7 the period of u(k) is (19, 7, 19, 5, 21, 9, 19, 3, 23, 13, 17, 3, 21, 11, 17, 1, 23, 15, 15, 7, 15, 1, 21, 13, 15, 5, 17, 5) of length 28.

%K nonn

%O 1,2

%A _Benoit Cloitre_, Mar 03 2003

%E Corrected and extended by _Vladeta Jovovic_, Mar 07 2003

%E More terms from _Don Reble_, Mar 08 2003