A323413 Infinitary analog of cototient function A051953: a(n) = n - A091732(n).
0, 1, 1, 1, 1, 4, 1, 5, 1, 6, 1, 6, 1, 8, 7, 1, 1, 10, 1, 8, 9, 12, 1, 18, 1, 14, 11, 10, 1, 22, 1, 17, 13, 18, 11, 12, 1, 20, 15, 28, 1, 30, 1, 14, 13, 24, 1, 18, 1, 26, 19, 16, 1, 38, 15, 38, 21, 30, 1, 36, 1, 32, 15, 19, 17, 46, 1, 20, 25, 46, 1, 48, 1, 38, 27, 22, 17, 54, 1, 20, 1, 42, 1, 48, 21, 44, 31, 58, 1, 58, 19
Offset: 1
Keywords
Links
- Antti Karttunen, Table of n, a(n) for n = 1..21000
- Antti Karttunen, Data supplement: n, a(n) computed for n = 1..100000
Programs
-
Mathematica
f[p_, e_] := p^(2^(-1 + Position[Reverse @ IntegerDigits[e, 2], 1])); a[1] = 0; a[n_] := n - Times @@ (Flatten@(f @@@ FactorInteger[n]) - 1); Array[a, 100] (* Amiram Eldar, Jan 09 2021 *)
-
PARI
ispow2(n) = (n && !bitand(n,n-1)); A302777(n) = ispow2(isprimepower(n)); A091732(n) = { my(m=1); while(n > 1, fordiv(n, d, if((d
A302777(n/d), m *= ((n/d)-1); n = d; break))); (m); }; A323413(n) = (n-A091732(n));
Formula
a(n) = n - A091732(n).
Sum_{k=1..n} a(k) ~ c * n^2, where c = 1/2 - A327575 = 0.171064... . - Amiram Eldar, Dec 15 2023