login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

A066727
Least factor of n^phi(n) - 1.
2
0, 1, 2, 3, 2, 5, 2, 3, 2, 3, 2, 5, 2, 3, 2, 3, 2, 7, 2, 3, 2, 3, 2, 5, 2, 3, 2, 3, 2, 17, 2, 3, 2, 3, 2, 5, 2, 3, 2, 3, 2, 5, 2, 3, 2, 3, 2, 5, 2, 3, 2, 3, 2, 5, 2, 3, 2, 3, 2, 13, 2, 3, 2, 3, 2, 5, 2, 3, 2, 3, 2, 5, 2, 3, 2, 3, 2, 5, 2, 3, 2, 3, 2, 5, 2, 3, 2, 3, 2, 7, 2, 3, 2, 3, 2, 5, 2, 3, 2, 3
OFFSET
1,3
COMMENTS
n^Phi(n)-1 is never prime. This sequence is an outgrowth of Euler's generalization to Fermat's little theorem.
LINKS
FORMULA
For n > 1, a(n) = A020639(A066916(n)). - Antti Karttunen, Oct 24 2024
MATHEMATICA
a = {}; Do[ a = Append[a, FactorInteger[ n^EulerPhi[n] - 1, FactorComplete -> False][[1, 1]]], {n, 1, 100}]; a
PROG
(PARI)
A020639(n) = if(1==n, n, forprime(p=2, , if(!(n%p), return(p))));
A066727(n) = if(1==n, 0, A020639((n^eulerphi(n))-1)); \\ Antti Karttunen, Oct 24 2024
CROSSREFS
KEYWORD
nonn
AUTHOR
Robert G. Wilson v, Jan 15 2002
STATUS
approved