# How do we show that the sum is equal to $0$?

We have the arithmetic function $$f(n)=\sum_{d\mid n}\mu (d)\cdot d$$ I want to show that if $n$ is divisible by $p^2$ for some prime $p$ then $\displaystyle{\sum_{d\mid n}f(d)\mu \left (\frac{n}{d}\right )=0}$.

From the first subquestion we have that $f\left (p_1^{e_1}\cdots p_k^{e_k}\right )=(-1)^k\cdot (p_1-1)\cdots (p_k-1)$.



I have done the following:

We have that $n=p^2\cdot k$, where $k=q_1^{a_1}\cdots q_y^{a_y}$.

\begin{align*}\sum_{d\mid n}f(d)\mu \left (\frac{n}{d}\right )&=\sum_\limits{0\leq\beta\leq 2 \\ 0\leq e_i\leq a_i}f\left (p^{\beta}\cdot q_1^{e_1}\cdots q_y^{e_y}\right )\mu \left (\frac{p^{2}\cdot q_1^{a_1}\cdots q_y^{a_y}}{p^{\beta}\cdot q_1^{e_1}\cdots q_y^{e_y}}\right ) \\& =\sum_\limits{0\leq\beta\leq 2 \\ 0\leq e_i\leq a_i}f\left (p^{\beta}\cdot q_1^{e_1}\cdots q_y^{e_y}\right )\cdot \mu \left (p^{2-\beta}\right )\cdot \mu\left (q_1^{a_1-e_1}\right )\cdots \mu \left (q_y^{a_y-e_y}\right ) \\ & = \sum_\limits{1\leq\beta\leq 2 \\ a_i-2\leq e_i\leq a_i}f\left (p^{\beta}\cdot q_1^{e_1}\cdots q_y^{e_y}\right )\cdot (-1)^{2-\beta}\cdot (-1)^{a_1-e_1}\cdots (-1)^{a_y-e_y}\end{align*}

Is everything correct so far? How could we continue? Do we maybe apply the first subquestion? But we can use this result only if $(p,q_i)=1$, $\forall 1\leq i\leq y$, right?

• We don't know what it is the first subquestion... Do you know what value takes $\mu(n)$ at the $n$'s divisible by squares of primes? What it tells you about the sum do you want to show it is zero? – xarles Aug 6 '18 at 15:10
• At the first subquestion I had to show that $f\left (p_1^{e_1}\cdots p_k^{e_k}\right )=(-1)^k\cdot (p_1-1)\cdots (p_k-1)$. We have that $\mu (p^2\cdot k)=0$, $\forall k$, right? @xarles – Mary Star Aug 6 '18 at 15:14
• This can be shown with the Mobius Inversion Formula. In this case, $b_d = \mu(d) d$ and $a_n = f(n)$. – Paul LeVan Aug 6 '18 at 15:17
• – Robert Z Aug 6 '18 at 15:21
• So, in the sum you want to consider all sumands with $d$ coprime with $p$ are zero; and the same if $n/d$ is divisible by $p^2$. Now, for every $d$ divisor such that $n/d$ is coprime with $p$, the sumand correspoding to the divisor $pd$ cancels with it. – xarles Aug 6 '18 at 15:23

By Möbius Inversion Formula, given $f(n):=\sum_{d|n}g(d)$, then $$g(n)=\sum_{d|n}\mu(d)f(n/d)=\sum_{d|n}\mu(n/d)f(n).$$ See also Mobius Inversion Formula [Proof] .
In your case let $g(n):=\mu (n)\cdot n$, then $$\sum_{d|n}\mu(d)f(n/d)=\sum_{d|n}\mu(n/d)f(n)=g(n)=\mu (n)\cdot n.$$ Therefore, if $n$ is divisible by $p^2$ for some prime $p$ then by Möbius Inversion Formula, $$\sum_{d|n}\mu(n/d)f(n)=\mu (n)\cdot n=0\cdot n=0$$ because $\mu (n)=0$.
Define $D_n:=$ divisors $d$ of $n$ such that $p$ does not divide $n/d$. Then $$\sum_{d\mid n} f(d)\mu(n/d)=\sum_{d\in D_n}(f(d)\mu(n/d)+ f(d/p)\mu(pn/d),$$ since $\mu(p^kn/d)$ is zero for all $k>1$.
But for all $d\in D_n$ we have $$f(d)=\prod_{q\mid d} (1-q)= f(d/p)$$ (where the $q$ are the primes that divide $d$), since $p^2\mid d$, and $\mu(pn/d)=-\mu(n/d)$, since $p$ does not divide $n/d$.