OFFSET
1,4
FORMULA
MATHEMATICA
Table[Sum[(-1)^PrimeNu[n/d] EulerPhi[Last[Select[Divisors[n/d], SquareFreeQ]]] PartitionsP[d], {d, Divisors[n]}], {n, 50}]
PROG
(PARI) rad(n) = factorback(factorint(n)[, 1]); \\ A007947
a(n) = sumdiv(n, d, (-1)^omega(n/d) * eulerphi(rad(n/d)) * numbpart(d)); \\ Michel Marcus, Apr 03 2020
CROSSREFS
KEYWORD
nonn
AUTHOR
Ilya Gutkovskiy, Apr 02 2020
STATUS
approved