A182817 Number of elements k in Z/mZ such that k^m=k, for nonprime m = A018252(n).
1, 2, 4, 2, 3, 4, 4, 4, 9, 2, 4, 4, 9, 4, 4, 5, 4, 3, 8, 8, 2, 9, 4, 9, 4, 4, 9, 4, 8, 4, 15, 4, 4, 7, 4, 9, 8, 4, 9, 4, 9, 4, 8, 4, 9, 2, 25, 24, 4, 9, 16, 4, 4, 9, 8, 9, 8, 4, 3, 4, 8, 25, 4, 9, 4, 8, 49, 4, 9, 4, 9, 4, 4, 9, 4, 8, 4, 45, 4, 4, 8, 9, 8, 8, 9, 4, 15, 4, 9, 8, 11, 4, 9, 8, 5, 8, 2, 9, 16, 8, 49, 4, 9, 4, 8, 8, 9, 4, 9, 4, 25, 4, 9, 8, 8, 4, 27, 16, 9, 8, 4, 9, 4, 9, 4
Offset: 1
Keywords
Links
- Amiram Eldar, Table of n, a(n) for n = 1..10000
- "Lunkwill", Carmichael numbers and Fermat primality, Dec 02 2010.
Programs
-
Mathematica
f[n_] := Times @@ ((1 + GCD[n-1, #-1]) & /@ FactorInteger[n][[;;,1]]); f /@ Select[Range[165], !PrimeQ[#] &] (* Amiram Eldar, Mar 27 2021 *)
Comments