OFFSET
1,16
LINKS
Amiram Eldar, Table of n, a(n) for n = 1..10000
FORMULA
a(n) = Sum_{d|n, gcd(d, n/d) > 1} [d in A001597], where [] is the Iverson bracket.
EXAMPLE
a(16) = 2 since 16 have 2 nonunitary divisors that are perfect powers, 4 = 2^2 and 8 = 2^3.
a(32) = 3 since 32 have 3 nonunitary divisors that are perfect powers, 4 = 2^3, 8 = 2^3, and 16 = 2^4.
MATHEMATICA
ppQ[n_] := n == 1 || GCD @@ FactorInteger[n][[;; , 2]] > 1; a[n_] := DivisorSum[n, 1 &, !CoprimeQ[#, n/#] && ppQ[#] &]; Array[a, 100]
PROG
(PARI) a(n) = sumdiv(n, d, gcd(d, n/d) > 1 && (d == 1 || ispower(d)));
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Amiram Eldar, Jan 23 2025
STATUS
approved