%I #20 Feb 16 2025 08:33:00
%S 0,8,3,4,0,24,7,8,0,40,11,6,0,56,15,4,0,24,19,20,0,88,23,24,0,104,3,
%T 14,0,120,31,8,0,136,35,12,0,152,39,40,0,168,43,22,0,184,47,6,0,40,51,
%U 52,0,24,55,56,0,232,59,30,0,248,21,4,0,264,67,68,0,280,71,24,0,296,15,38
%N Period of sequence {Kronecker(-n,k), k = 1, 2, 3, ...}, or 0 if the sequence is not periodic.
%C From _Jianing Song_, Nov 24 2018: (Start)
%C The sequence {Kronecker(-n,k)} forms a Dirichlet character modulo n if and only if n == 0, 3 (mod 4).
%C Let n = 2^t*s, s odd, then a(n) = A117888(n) if and only if t is odd, a(n) = A302138(n) if and only if t is odd or s == 3 (mod 4) (or both). (End)
%H Jean-Paul Allouche, Leo Goldmakher, <a href="http://arxiv.org/abs/1608.03957">Mock characters and the Kronecker symbol</a>, arXiv:1608.03957 [math.NT], 2016.
%H Eric Weisstein's World of Mathematics, <a href="https://mathworld.wolfram.com/KroneckerSymbol.html">Kronecker Symbol</a>
%F Let n = 2^t*s, s odd, then a(n) = 4*A007947(n) if t is odd; A007947(n) if t is even and s == 3 (mod 4); 2*A007947(n) if t is even and t > 0 and s == 1 (mod 4); 0 if t = 0 and s == 1 (mod 4). - _Jianing Song_, Nov 24 2018
%t per[lst_] := FindTransientRepeat[lst, 4] // Last // Length;
%t a[n_] := per[Table[KroneckerSymbol[-n, k], {k, 1, 1200}]];
%t Array[a, 76] (* _Jean-François Alcover_, Oct 08 2018 *)
%Y Cf. A007947.
%Y Cf. A117888 (period of Kronecker(n,k)), A302138 (period of Kronecker(k,n)).
%K nonn
%O 1,2
%A _Eric W. Weisstein_, Mar 30 2006
%E Edited by _N. J. A. Sloane_, May 31 2009