OFFSET
1,3
FORMULA
a(n) = Sum_{k=1..n} k * mu(k)^2 * floor(1/gcd(n,k)) * (ceiling(n/k) - floor(n/k)).
EXAMPLE
a(7) = 16. There are 4 squarefree numbers that are less than 7, do not divide 7, and relatively prime to 7: namely {2, 3, 5, 6}. Their sum is then 2 + 3 + 5 + 6 = 16.
MATHEMATICA
Table[Sum[k * MoebiusMu[k]^2 * Floor[1/GCD[n, k]] * (Ceiling[n/k] - Floor[n/k]), {k, n}], {n, 80}]
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Wesley Ivan Hurt, Jan 03 2024
STATUS
approved