A053470 a(n) is the cototient of n (A051953) iterated twice.
0, 0, 0, 1, 0, 2, 0, 2, 1, 4, 0, 4, 0, 4, 1, 4, 0, 8, 0, 8, 3, 8, 0, 8, 1, 8, 3, 8, 0, 12, 0, 8, 1, 12, 1, 16, 0, 12, 7, 16, 0, 22, 0, 16, 9, 16, 0, 16, 1, 22, 1, 16, 0, 24, 7, 16, 9, 22, 0, 24, 0, 16, 9, 16, 1, 24, 0, 24, 5, 24, 0, 32, 0, 20, 11, 24, 1, 36, 0, 32, 9, 30, 0, 44, 9, 24, 1, 32, 0
Offset: 1
Keywords
Examples
n=50, n_1 = n - phi(n) = 50 - 20 = 30, n_2 = n_1 - Phi(n_1) = 30 - 8 = 22, so the 50th term is 22.
Links
- Antti Karttunen, Table of n, a(n) for n = 1..16384
Programs
-
Mathematica
Array[Nest[# - EulerPhi@ # &, #, 2] &, 89] (* Michael De Vlieger, Dec 23 2017 *)
-
PARI
A051953(n) = (n-eulerphi(n)); A053470(n) = if(1==n,0,A051953(A051953(n))); \\ Antti Karttunen, Dec 22 2017
Comments