login
a(n) = Sum_{d1|n, d2|n, d1<d2} [omega(d1) = omega(d2)], where omega is the number of distinct prime factors of n (A001221) and [ ] is the Iverson bracket.
0

%I #6 Aug 30 2020 16:39:28

%S 0,0,0,1,0,1,0,3,1,1,0,4,0,1,1,6,0,4,0,4,1,1,0,9,1,1,3,4,0,6,0,10,1,1,

%T 1,12,0,1,1,9,0,6,0,4,4,1,0,16,1,4,1,4,0,9,1,9,1,1,0,17,0,1,4,15,1,6,

%U 0,4,1,6,0,25,0,1,4,4,1,6,0,16,6,1,0,17,1,1,1,9,0,17,1,4

%N a(n) = Sum_{d1|n, d2|n, d1<d2} [omega(d1) = omega(d2)], where omega is the number of distinct prime factors of n (A001221) and [ ] is the Iverson bracket.

%C a(n) is the number of divisor pairs of n, (d1,d2), such that d1<d2 and where d1,d2 have the same number of distinct prime factors. For example, a(8) = 3 since we have the ordered pairs (2,4), (2,8) and (4,8), where the divisors in each pair have the same number of distinct prime factors.

%F a(n) >= 1 if and only if n is composite. (E.g. composite numbers either have a divisor pair of the form (p,p^k), where p is prime and k is a positive integer > 1, which implies that omega(p) = omega(p^k) = 1, or they have a divisor pair of the form (p,q) where p and q are distinct primes and omega(p) = omega(q) = 1. Then the total number of such divisor pairs is >= 1.)

%F Furthermore, a(n) = 0 if and only if n is noncomposite. (E.g. a(1) = 0 since 1 has no divisor pairs such that d1<d2, and a(p) = 0 (for p prime) since the only divisor pair of p such that d1<d2 is (1,p), of which, omega(1) = 0 but omega(p) = 1. So the primes have no such divisor pairs.)

%t Table[Sum[Sum[KroneckerDelta[PrimeNu[i], PrimeNu[k]] (1 - Ceiling[n/k] + Floor[n/k]) (1 - Ceiling[n/i] + Floor[n/i]), {i, k - 1}], {k, n}], {n, 100}]

%Y Cf. A001221 (omega).

%K nonn,easy

%O 1,8

%A _Wesley Ivan Hurt_, Aug 30 2020