cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A070673 Smallest m in range 2..n-1 such that m^8 == 1 mod n, or 1 if no such number exists.

This page as a plain text file.
%I A070673 #12 Mar 06 2024 09:02:54
%S A070673 1,1,2,3,2,5,6,3,8,3,10,5,5,13,2,3,2,17,18,3,8,21,22,5,7,5,26,13,12,7,
%T A070673 30,3,10,9,6,17,6,37,5,3,3,13,42,21,8,45,46,5,48,7,2,5,23,53,12,13,20,
%U A070673 17,58,7,11,61,8,7,8,23,66,9,22,13,70,17,10,31,7,37
%N A070673 Smallest m in range 2..n-1 such that m^8 == 1 mod n, or 1 if no such number exists.
%H A070673 Alois P. Heinz, <a href="/A070673/b070673.txt">Table of n, a(n) for n = 1..10000</a>
%p A070673 a:= proc(n) local m;
%p A070673       for m from 2 to n-1 do
%p A070673         if m &^ 8 mod n = 1 then return m fi
%p A070673       od; 1
%p A070673     end:
%p A070673 seq(a(n), n=1..100);  # _Alois P. Heinz_, Jun 29 2014
%t A070673 a[n_] := Module[{m}, For[m = 2, m <= n-1, m++,
%t A070673     If[PowerMod[m, 8, n] == 1, Return[m]]]; 1];
%t A070673 Table[a[n], {n, 1, 100}] (* _Jean-François Alcover_, Mar 06 2024 *)
%o A070673 (PARI) a(n) = {for (m=2, n-1, if (lift(Mod(m, n)^8) == 1, return (m));); return (1);} \\ _Michel Marcus_, Jun 29 2014
%Y A070673 Cf. A070667.
%K A070673 nonn
%O A070673 1,3
%A A070673 _N. J. A. Sloane_, May 08 2002