∑d∣nφ⁢(d)=∑d∣nφ⁢(nd)=nfor all ⁢n∈ℤ+.formulae-sequencesubscriptfragmentsdnormal-∣nφdsubscriptfragmentsdnormal-∣nφndnfor all nsubscriptℤ\sum_{{d\,\mid\,n}}\varphi(d)\;=\;\sum_{{d\,\mid\,n}}\varphi\left(\frac{n}{d}%
\right)\;=\;n\quad\mbox{for all }\,n\in\mathbb{Z}_{+}.

Proof. The first equality follows from the fact that any positive divisor of
nnn is got from n/dndn/d where ddd is a divisor of nnn.
Further, let 1≤m≤n1mn1\leq m\leq n where gcd⁡(m,n)=dmnd\gcd(m,\,n)=d. Then gcd⁡(m/d,n/d)=1mdnd1\gcd(m/d,\,n/d)=1 and
1≤m/d≤n/d1mdnd1\leq m/d\leq n/d. This defines a bijection between the prime classes modulo n/dndn/d and such values of mmm in {1, 2,…,n-1}1 2normal-…n1\{1,\,2,\,\ldots,\,n\!-\!1\} for which gcd⁡(m,n)=dmnd\gcd(m,\,n)=d. The number of the latters φ⁢(n/d)φnd\varphi(n/d).
Furthermore, the only mmm with 1≤m≤n1mn1\leq m\leq n and gcd⁡(m,n)=nmnn\gcd(m,\,n)=n is m:=nassignmnm:=n, and φ⁢(n/n)=φ⁢(1)φnnφ1\varphi(n/n)=\varphi(1), by definition. Summing then over all possible values ddd yields the second equality.