A348946 a(n) = gcd(sigma(n), A348944(n)), where A348944 is the arithmetic mean of A003959 and A034448, and sigma is the sum of divisors function.
1, 3, 4, 7, 6, 12, 8, 3, 13, 18, 12, 28, 14, 24, 24, 1, 18, 39, 20, 42, 32, 36, 24, 12, 31, 42, 2, 56, 30, 72, 32, 3, 48, 54, 48, 1, 38, 60, 56, 18, 42, 96, 44, 84, 78, 72, 48, 4, 57, 93, 72, 98, 54, 6, 72, 24, 80, 90, 60, 168, 62, 96, 104, 1, 84, 144, 68, 126, 96, 144, 72, 3, 74, 114, 124, 140, 96, 168, 80, 6, 1, 126
Offset: 1
Keywords
Links
Crossrefs
Programs
-
Mathematica
f1[p_, e_] := (p^(e + 1) - 1)/(p - 1); f2[p_, e_] := (p + 1)^e; f3[p_, e_] := p^e + 1; a[1] = 1; a[n_] := GCD[Times @@ f1 @@@ (f = FactorInteger[n]), (Times @@ f2 @@@ f + Times @@ f3 @@@ f)/2]; Array[a, 100] (* Amiram Eldar, Nov 05 2021 *)
-
PARI
A003959(n) = { my(f = factor(n)); for(i=1, #f~, f[i, 1]++); factorback(f); }; A034448(n) = { my(f = factor(n)); prod(k=1, #f~, 1+(f[k, 1]^f[k, 2])); }; A348946(n) = gcd(sigma(n), ((1/2)*(A003959(n)+A034448(n))));
Comments