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”).
%I #11 Sep 08 2022 08:45:14
%S 0,0,1,1,7,0,15,8,16,7,35,7,48,17,28,29,76,18,91,30,56,44,126,31,116,
%T 60,105,61,184,31,205,96,129,97,165,65,272,118,172,103,321,67,346,143,
%U 182,165,398,108,366,150,272,192,482,133,364,197,327,243,571,115,601,272,341
%N a(n) = floor( phi(n)*sqrt(2*n) ) - n.
%C This is known to be always >= 0, i.e. that n/phi(n) <= sqrt(2n) holds for all n. This is a consequence of the stronger inequality in A079530.
%D D. S. Mitrinovic et al., Handbook of Number Theory, Kluwer, p. 9.
%H G. C. Greubel, <a href="/A097604/b097604.txt">Table of n, a(n) for n = 1..10000</a>
%t Table[Floor[Sqrt[2*n]*EulerPhi[n]] - n, {n, 1, 100}] (* _G. C. Greubel_, Jan 14 2019 *)
%o (PARI) vector(100, n, (sqrt(2*n)*eulerphi(n))\1 -n) \\ _G. C. Greubel_, Jan 14 2019
%o (Magma) [Floor(Sqrt(2*n)*EulerPhi(n)) - n: n in [1..100]]; // _G. C. Greubel_, Jan 14 2019
%o (Sage) [floor(sqrt(2*n)*euler_phi(n)) - n for n in (1..100)] # _G. C. Greubel_, Jan 14 2019
%Y Cf. A079530, A097850.
%K nonn
%O 1,5
%A _N. J. A. Sloane_, based on emails from _Alonso del Arte_ and _Jud McCranie_, Aug 30 2004