OFFSET
1,4
LINKS
Amiram Eldar, Table of n, a(n) for n = 1..10000
FORMULA
Sum_{k=1..n} a(k) ~ c * n^2, where c = A072691 - A307160 = 0.069628292421818906692... . - Amiram Eldar, Nov 25 2025
EXAMPLE
For n = 12 the divisors of 12 are 1, 2, 3, 4, 6, 12, and the bi-unitary divisors of 12 are 1, 3, 4, 12, hence the non-bi-unitary divisors of 12 are 2 and 6, and the sum of them is 2 + 6 = 8, so a(12) = 8. Also the sum of the divisors of 12 is 28, and the sum of the bi-unitary divisors of 12 is 20, so a(12) = 28 - 20 = 8.
MATHEMATICA
f1[p_, e_] := (p^(e+1) - 1)/(p - 1); f2[p_, e_] := f1[p, e] - If[OddQ[e], 0, p^(e/2)]; a[1] = 0; a[n_] := Times @@ f1 @@@ (fct = FactorInteger[n]) - Times @@ f2 @@@ fct; Array[a, 100] (* Amiram Eldar, Apr 04 2024 *)
PROG
(PARI) a(n) = {my(f = factor(n)); sigma(f) - prod(i = 1, #f~, (f[i, 1]^(f[i, 2]+1)-1)/(f[i, 1]-1) - if(!(f[i, 2] % 2), f[i, 1]^(f[i, 2]/2))); } \\ Amiram Eldar, Nov 25 2025
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Omar E. Pol, Sep 22 2018
STATUS
approved
