OFFSET
1,2
COMMENTS
If p is prime, a(p) = Sum_{d|p} (p/d) * floor(p/d^2) = p*p + 1*0 = p^2.
EXAMPLE
a(4) = 18; Sum_{d|4} (4/d) * floor(4/d^2) = 4*4 + 2*1 + 1*0 = 18.
MATHEMATICA
Table[Sum[(1 - Ceiling[n/k] + Floor[n/k]) (n/k) Floor[n/k^2], {k, n}], {n, 100}]
PROG
(PARI) a(n) = sumdiv(n, d, (n/d)*(n\d^2)); \\ Michel Marcus, May 17 2021
CROSSREFS
KEYWORD
nonn
AUTHOR
Wesley Ivan Hurt, May 16 2021
STATUS
approved