%I #16 Feb 16 2026 23:05:54
%S 1,1,1,3,3,3,1,1,1,1,1,1,1,1,1,15,15,15,15,15,15,15,15,15,15,15,15,15,
%T 15,15,1,6,6,6,3,3,6,6,6,6,6,1,6,6,3,6,6,6,3,6,6,6,6,3,6,3,6,6,6,6,6,
%U 6,1,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7
%N a(n) is the period length of the Ducci sequence, where the initial vector consists of the binary digits of n.
%H Wikipedia, <a href="https://en.wikipedia.org/wiki/Ducci_sequence">Ducci sequence</a>.
%F Let A_k = {a(n) | 2^(k-1) <= n < 2^k}. Then max(A_k) = A038553(k) and #A_k = A111944(k). - _Andrei Zabolotskii_, Feb 14 2026
%e n = 6: 6_10 = 110_2, vectors are (1,1,0)-->(0,1,1)-->(1,0,1)-->(1,1,0) repeats after 3 steps, thus a(6) = 3.
%e n = 7: 7_10 = 111_2, vectors are (1,1,1)-->(0,0,0)-->(0,0,0) repeats after 1 step, thus a(7) = 1.
%t a[n_] := Length[#] - FirstPosition[#, Last[#]][[1]]& @ NestWhileList[Abs[# - RotateLeft[#]] &, IntegerDigits[n, 2], Unequal, All]; Array[a, 80] (* _Amiram Eldar_, Feb 07 2026 *)
%Y Cf. A007788, A038553, A111944.
%K nonn,base
%O 1,4
%A _Ctibor O. Zizka_, Feb 07 2026