login
A109352
a(n) = sum of the prime divisors of the n-th squarefree composite number.
1
5, 7, 9, 8, 10, 13, 15, 10, 14, 19, 12, 21, 16, 12, 25, 20, 16, 22, 31, 33, 18, 16, 26, 14, 39, 18, 18, 43, 22, 45, 32, 20, 34, 49, 24, 22, 15, 55, 18, 40, 24, 28, 61, 24, 63, 44, 46, 20, 26, 69, 28, 50, 73, 24, 34, 75, 20, 36, 81, 56, 30, 19, 85, 24, 34, 62, 91, 22, 64, 42, 36
OFFSET
1,1
COMMENTS
Similar to the definition of A120944 except we list the sum of the divisors of n instead of n.
LINKS
FORMULA
a(n) = A008472(A120944(n)) = A001414(A120944(n)).
EXAMPLE
The 3rd squarefree composite number is 14 = 2*7, so a(3) = 2 + 7 = 9.
MAPLE
map(t-> convert(numtheory:-factorset(t), `+`), select(numtheory:-issqrfree and not isprime, [$6..1000])); # Robert Israel, Oct 09 2015
MATHEMATICA
lim = 200; Total@ Map[First, FactorInteger@ #] & /@ Select[Range@ lim, SquareFreeQ@ # && CompositeQ@ # &] (* Michael De Vlieger, Oct 09 2015 *)
PROG
(PARI) distinct(n) = \\ Sum of the distinct divisors p1, p2.. of n
if p1*p2..=n { local(a, x, m, p, ln, s); for(m=2, n, p=1; s=0; a=ifactord(m); ln=length(a); if(ln > 1, for(x=1, ln, p*=a[x]; s+=a[x]; ) ); if(p==m, print1(s", ") ) ) }
ifactord(n, m=0) = \\The vector of the distinct integer factors of n.
{ local(f, j, k, flist); flist=[]; f=Vec(factor(n, m)); for(j=1, length(f[1]), flist = concat(flist, f[1][j]) ); return(flist) }
(Python)
from math import isqrt
from sympy import primepi, mobius
def A109352(n):
def f(x): return n+1+primepi(x)+x-sum(mobius(k)*(x//k**2) for k in range(1, isqrt(x)+1))
m, k = n+1, f(n+1)
while m != k:
m, k = k, f(k)
return sum(primefactors(m)) # Chai Wah Wu, Aug 02 2024
CROSSREFS
KEYWORD
easy,nonn
AUTHOR
Cino Hilliard, Aug 21 2005
STATUS
approved