OFFSET
1,8
COMMENTS
a(n) = 0 if and only if n is a squarefree number (A005117), otherwise a(n) > 0.
If n is semiprime, then a(n) = 1+floor(sqrt(n))-ceiling(sqrt(n)). - Wesley Ivan Hurt, Dec 25 2016
LINKS
Antti Karttunen, Table of n, a(n) for n = 1..16384
FORMULA
Sum_{k=1..n} a(k) ~ c*n^2 + O(n*log(n)), where c = Pi^2/12 - 15/(2*Pi^2) = 0.062558... - Amiram Eldar, Mar 02 2021
MAPLE
A244963:= n -> numtheory:-sigma(n) - n*mul(1+1/t[1], t=ifactors(n)[2]):
seq(A244963(n), n=1..1000); # Robert Israel, Jul 15 2014
MATHEMATICA
nn = 200; Table[Sum[d, {d, Divisors[n]}], {n, 1, nn}] -
Table[Sum[n/d Abs[MoebiusMu[d]], {d, Divisors[n]}], {n, 1, nn}] (* Geoffrey Critzer, Mar 18 2015 *)
PROG
(PARI)
A001615(n) = (n * sumdivmult(n, d, issquarefree(d)/d)); \\ This function from Charles R Greathouse IV, Sep 09 2014
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Omar E. Pol, Jul 15 2014
STATUS
approved