A064950 a(n) = Sum_{i|n, j|n} lcm(i,j).
1, 7, 10, 27, 16, 70, 22, 83, 55, 112, 34, 270, 40, 154, 160, 227, 52, 385, 58, 432, 220, 238, 70, 830, 141, 280, 244, 594, 88, 1120, 94, 579, 340, 364, 352, 1485, 112, 406, 400, 1328, 124, 1540, 130, 918, 880, 490, 142, 2270, 267, 987, 520, 1080, 160, 1708
Offset: 1
Links
- Harry J. Smith, Table of n, a(n) for n = 1..1000
Programs
-
Mathematica
a[n_]:= Sum[LCM[i,j], {i, Divisors[n]}, {j, Divisors[n]}]; Array[a,60] (* Jean-François Alcover, Jun 03 2019 *) f[p_, e_] := (p^(e+2) - 3*p^(e+1) + p + 1 + 2*p^(e+2)*e - 2*p^(e+1)*e)/(p-1)^2; a[1] = 1; a[n_] := Times @@ f @@@ FactorInteger[n]; Array[a, 60] (* Amiram Eldar, Aug 28 2023 *)
-
PARI
for (n=1, 1000, d=divisors(n); a=sum(i=1, length(d), numdiv(d[i]^2)*d[i]); write("b064950.txt", n, " ", a)) \\ Harry J. Smith, Oct 01 2009
-
Sage
def A064950(n) : tau = sloane.A000005; D = divisors(n) return reduce(lambda x,y: x+y, [d*tau(d^2) for d in D]) [A064950(n) for n in (1..54)] # Peter Luschny, Sep 10 2012
Formula
a(n) = Sum_{d|n} d*tau(d^2).
Multiplicative with a(p^e) = (p^(e+2) - 3*p^(e+1) + p + 1 + 2*p^(e+2)*e - 2*p^(e+1)*e)/(p-1)^2.