A060609 Repeatedly apply Euler phi to n-th prime; a(n) = highest power of 2 that is seen.
2, 2, 4, 2, 4, 4, 16, 2, 4, 4, 8, 4, 16, 4, 4, 8, 4, 16, 8, 8, 8, 8, 16, 16, 32, 16, 32, 8, 4, 16, 4, 16, 64, 8, 8, 16, 16, 2, 16, 8, 16, 16, 8, 64, 8, 16, 16, 8, 16, 8, 16, 32, 64, 16, 256, 16, 16, 8, 16, 32, 8, 16, 32, 32, 32, 16, 32, 32, 8, 16, 64, 16, 32, 32, 4, 8, 64, 32, 64, 128
Offset: 1
Examples
n=100,p(100)=541, Phi-iteration chain is {541,540,144,48,16,8,4,2,1} with 9 terms. The largest power of 2 is the 5th term=16=a(100).
Links
- Amiram Eldar, Table of n, a(n) for n = 1..10000
Programs
-
Mathematica
Table[Max[Select[NestWhileList[EulerPhi[#]&,Prime[n],#>1&],IntegerQ[Log2[#]]&]],{n,80}] (* Harvey P. Dale, Aug 23 2025 *)