login
a(n) = floor(2*sqrt(n)*phi(n)) - n.
2

%I #10 Sep 08 2022 08:45:14

%S 1,0,3,4,12,3,24,14,27,15,55,15,73,30,46,48,114,32,137,51,88,71,188,

%T 54,175,96,160,98,272,57,303,149,196,152,248,108,400,183,260,162,471,

%U 113,507,221,276,252,583,173,539,232,406,294,704,210,538,303,486,368,832,187,876

%N a(n) = floor(2*sqrt(n)*phi(n)) - n.

%C Always >= 0. But see A079530 and A097604 for stronger upper bounds on n/phi(n).

%D David Burton, Elementary Number Theory" 4th edition, problem 7a in section 7.2 has the equivalent of n/phi(n) <= 2*sqrt(n). - _Jud McCranie_, Aug 30 2004

%H G. C. Greubel, <a href="/A097850/b097850.txt">Table of n, a(n) for n = 1..10000</a>

%t Table[Floor[2*Sqrt[n]*EulerPhi[n]]-n, {n, 1, 100}] (* _G. C. Greubel_, Jan 14 2019 *)

%o (PARI) vector(100, n, (2*sqrt(n)*eulerphi(n))\1 -n) \\ _G. C. Greubel_, Jan 14 2019

%o (Magma) [Floor(2*Sqrt(n)*EulerPhi(n)) - n: n in [1..100]]; // _G. C. Greubel_, Jan 14 2019

%o (Sage) [floor(2*sqrt(n)*euler_phi(n)) - n for n in (1..100)] # _G. C. Greubel_, Jan 14 2019

%Y Cf. A079530, A097604.

%K nonn

%O 1,3

%A _N. J. A. Sloane_, Aug 30 2004