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.
%I A333433 #24 Jan 17 2021 22:52:45 %S A333433 1,0,4,21,8,1555,9,6223,40,999,20,130801,24,4484077,128,117,60, %T A333433 118285781329,42,1432001198261,104,819,72,302508121,81,75625,200, %U A333433 61731,78,14507145975869,72,21958351241,820,12321,289,4375,144 %N A333433 a(n) is the n-th number m that divides n^m - 1 (or 0 if m does not exist). %C A333433 From _Jinyuan Wang_, Mar 25 2020: (Start) %C A333433 For n > 2, n < a(n) < q^(n-1), where q is a prime factor of n - 1. %C A333433 If p is a prime, then a(p^e+1) is divisible by p. Proof: we can prove that p | m for m > 1 and n = p^e + 1. If n^m == 1 (mod m) and m > 1 is the minimum value that cannot be divisible by p, then gcd(m, eulerphi(m)) = 1. Thus, m must be of the form q*p_2*...*p_k, where q < p_2 < ... < p_k. Note that q | (n^m - 1) = (n^q - 1)*(Sum_{i=0..(m/q)-1} n)^(i*q)) and n^q - 1 can never be divisible by q. Therefore, Sum_{i=0..(m/q)-1} n^(i*q) == n^(m/q) - 1 == 0 (mod q). Because n^(q-1) == 1 (mod q) and gcd(m/q, q - 1) = 1, then n == 1 (mod q), a contradiction! (End) %C A333433 a(38) <= 14948925257859919. - _Giovanni Resta_, Apr 15 2020 %H A333433 OEIS Wiki, <a href="/wiki/2^n mod n">2^n mod n</a> %F A333433 a(n) = A333432(n,n). %o A333433 (PARI) {a(n) = if(n==2, 0, my(cnt=0, k=0); while(cnt<n, k++; if(Mod(n, k)^k==1, cnt++)); k)} %Y A333433 Main diagonal of A333432. %Y A333433 Cf. A014960, A128358, A128360, A333430. %K A333433 nonn,more %O A333433 1,3 %A A333433 _Seiichi Manyama_, Mar 21 2020 %E A333433 a(30)-a(37) from _Giovanni Resta_, Apr 15 2020