login
A344483
a(n) = n^2 + sigma(n) - n*d(n).
0
1, 3, 7, 11, 21, 24, 43, 47, 67, 78, 111, 100, 157, 164, 189, 207, 273, 255, 343, 322, 389, 432, 507, 444, 581, 614, 661, 672, 813, 732, 931, 895, 1005, 1074, 1133, 1063, 1333, 1352, 1421, 1370, 1641, 1524, 1807, 1756, 1833, 2004, 2163, 1948, 2311, 2293, 2469, 2490
OFFSET
1,2
COMMENTS
For all 1 <= k <= n, if k|n then add k to a running total, otherwise add n. (For example, a(9) = 1 + 9 + 3 + 9 + 9 + 9 + 9 + 9 + 9 = 67, where each divisor of 9 appears in fixed order from 1..9 and 9's appear everywhere else.)
If p is prime, a(p) = p^2 + sigma(p) - p*d(p) = p^2 - p + 1.
FORMULA
a(n) = n * Sum_{k=1..n} 1 / k^c(n/k), where c(n) = 1 - ceiling(n) + floor(n).
EXAMPLE
a(6) = 6^2 + sigma(6) - 6*d(6) = 36 + 12 - 24 = 24.
MATHEMATICA
Table[n^2 + DivisorSigma[1, n] - n*DivisorSigma[0, n], {n, 100}]
CROSSREFS
Cf. A000005 (tau), A000203 (sigma).
Sequence in context: A057660 A130972 A350400 * A151923 A187264 A067498
KEYWORD
nonn
AUTHOR
Wesley Ivan Hurt, May 20 2021
STATUS
approved