%I #14 Mar 21 2020 16:37:00
%S 0,0,1,1,1,2,1,0,1,3,2,5,2,6,0,4,2,8,3,3,4,0,5,11,2,2,6,9,0,7,4,15,4,
%T 10,8,0,6,9,3,12,4,20,0,3,5,12,11,23,2,0,2,16,12,13,9,20,0,3,7,29,4,
%U 30,15,0,8,6,10,33,16,22,0,35,6,12,9,4,6,0,12,39,4,27,20,41,0,16,3,7,5,44,12
%N Multiplicative suborder of 7 (mod n) = sord(7, n).
%C a(n) is minimum e for which 7^e = +/-1 mod n, or zero if no e exists.
%D H. Cohen, Course in Computational Algebraic Number Theory, Springer, 1993, p. 25, Algorithm 1.4.3
%H Eric Weisstein's World of Mathematics, <a href="http://mathworld.wolfram.com/MultiplicativeOrder.html">Multiplicative Order.</a>
%H S. Wolfram, <a href="http://www.stephenwolfram.com/publications/articles/ca/84-properties/9/text.html">Algebraic Properties of Cellular Automata (1984)</a>, Appendix B.
%t Suborder[k_, n_] := If[n > 1 && GCD[k, n] == 1, Min[MultiplicativeOrder[k, n, {-1, 1}]], 0];
%t a[n_] := Suborder[7, n];
%t a /@ Range[0, 100] (* _Jean-François Alcover_, Mar 21 2020, after _T. D. Noe_ in A003558 *)
%K easy,nonn
%O 0,6
%A _Harry J. Smith_, Feb 08 2005
|