OFFSET
1,18
LINKS
Michael De Vlieger, Table of n, a(n) for n = 1..10000
Michael De Vlieger, Hasse diagram of row 1440 of A162306 showing 4 squarefree composites in green, 3 primes in red, the empty product in gray, 17 perfect powers of primes in yellow, and 72 numbers that are neither squarefree nor prime powers in blue and purple, with purple additionally representing powerful numbers that are not prime powers.
FORMULA
EXAMPLE
a(2) = a(4) = a(p^k) = 0 since numbers m <= p^k such that rad(m) | p^k are all divisors that are prime powers p^j, j = 0..k.
a(k) = 0 for k < 12 since 12 is the smallest number that is neither squarefree nor prime powers.
a(12) = 1 since m = 12 is such that 12 <= 12 and rad(12) | 12.
a(18) = 2 since both k = 12 and k = 18 are such that rad(k) | 18.
MATHEMATICA
PROG
(PARI) rad(n) = factorback(factorint(n)[, 1]);
a(n) = sum(m=1, n, if (!issquarefree(m) && !isprimepower(m), ((n % rad(m))==0))); \\ Michel Marcus, Sep 29 2024
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Michael De Vlieger, Sep 28 2024
STATUS
approved