login
A330868
Number of proper divisors d of n such that n-d is squarefree.
0
0, 1, 1, 2, 0, 2, 1, 2, 1, 1, 1, 3, 0, 2, 2, 2, 0, 2, 0, 3, 1, 2, 1, 3, 0, 1, 1, 3, 0, 2, 1, 2, 2, 2, 2, 4, 0, 2, 2, 4, 0, 4, 1, 4, 2, 1, 1, 3, 1, 0, 1, 3, 0, 2, 0, 2, 1, 2, 1, 5, 0, 2, 2, 1, 0, 3, 1, 4, 2, 3, 1, 4, 0, 2, 2, 3, 2, 3, 1, 3, 1, 1, 1, 6, 0, 2, 2, 4, 0, 3
OFFSET
1,4
FORMULA
a(n) = Sum_{d|n, d<n} mu(n-d)^2, where mu is the Möbius function (A008683).
Let m = p^k, where p is a prime and k is a positive integer. Then a(p^k) = Sum_{i=0..k-1} mu(p^k - p^i)^2. In terms of m, a(m) = Sum_{j=0..Omega(m)-1} mu(m - rad(m)^j)^2, where mu = A008683, Omega = A001222 and rad = A001222.
EXAMPLE
a(11) = 1; The only proper divisor of 11 is 1 and 11-1 = 10 is squarefree.
a(12) = 3; There are five proper divisors of 12: 1, 2, 3, 4, 6. Of these, we see that 12-1 = 11, 12-2 = 10 and 12-6 = 6 are squarefree, but 12-3 = 9 and 12-4 = 8 are not.
a(13) = 0; The only proper divisor of 13 is 1, but 13-1 = 12 (which is not squarefree).
a(14) = 2; The proper divisors of 14 are 1, 2, and 7. Of these, only 14-1 = 13 and 14-7 = 7 are squarefree.
MATHEMATICA
Table[Sum[MoebiusMu[n - i]^2*(1 - Ceiling[n/i] + Floor[n/i]), {i, n - 1}], {n, 100}]
PROG
(PARI) a(n) = sumdiv(n, d, (d<n) && issquarefree(n-d)); \\ Michel Marcus, Apr 29 2020
CROSSREFS
Cf. A001222 (Omega), A007947 (rad), A008683 (Möbius).
Cf. A293227.
Sequence in context: A329643 A352697 A165414 * A178687 A325538 A238417
KEYWORD
nonn,easy
AUTHOR
Wesley Ivan Hurt, Apr 28 2020
STATUS
approved