HelpContactFor teachers and institutes
>_StemPy Lab
Mock TestsClasses

>_StemPy Lab

Learn. Solve. Code the solutions. Test yourself.

Live examsFree mock exams, timed and rankedEveryone starts together, and your score and rank come the moment it ends.See the exams →
Live examsInternational live exams are comingTell us which exam you want first. Timed practice papers are open now.See what is coming →

Learn

  • Physics
  • Chemistry
  • Mathematics
  • Biology
  • Python Programming
  • Statistics & Data Science
  • Computer Science
  • Space Science and Astronomy
  • Classes
  • Groups

Practice

  • Problems
  • Quizzes
  • Mock Tests
  • Prepare for an Exam
  • Question Sets
  • Exams
  • Certificates
  • Python Labs
  • AI Practice Generator
  • Student-Created Tests

Community

  • Discussions
  • Resources
  • Notes
  • Glossary
  • Blog

Account

  • Log in
© 2026 senLearn. All rights reserved.HelpFor SchoolsAboutContactPrivacy PolicyTerms of UseRefund Policy
  1. Problems
  2. /Prove that Σ_(d mid n)φ(d) = n for every positive integer n, by sorting the fractions 1/n, 2/n, ……
AdvancedMathematicsHigh School (11–12)Number TheoryproofNumericalOlympiad

Prove that Σ_(d mid n)φ(d) = n for every positive integer n, by sorting the fractions 1/n, 2/n, ……

StemPy LabContributed by StemPy Lab

Try it on paper first. A hint, the key idea and the worked solution are here when you need them.

Prove that ∑d∣nφ(d)=n\sum_{d \mid n}\varphi(d) = n∑d∣n​φ(d)=n for every positive integer nnn, by sorting the fractions 1n,2n,…,nn\dfrac{1}{n}, \dfrac{2}{n}, \dots, \dfrac{n}{n}n1​,n2​,…,nn​ by their denominators in lowest terms. Then count the fractions ab\dfrac{a}{b}ba​ in lowest terms with 0<ab≤10 < \dfrac{a}{b} \le 10<ba​≤1 and 1≤b≤121 \le b \le 121≤b≤12. Give that count, and the value of ∑d∣36φ(d)\sum_{d \mid 36}\varphi(d)∑d∣36​φ(d).

Check your answer

Work it out on paper, then type your number. The answer itself stays hidden.

Need a reminder? The key ideaShowHide

φ(n)\varphi(n)φ(n) counts 1≤k≤n1 \le k \le n1≤k≤n with gcd⁡(k,n)=1\gcd(k, n) = 1gcd(k,n)=1. If gcd⁡(a,n)=1\gcd(a, n) = 1gcd(a,n)=1, Euler's theorem gives

aφ(n)≡1(modn),φ(n)=n∏p∣n(1−1p).\displaystyle a^{\varphi(n)} \equiv 1 \pmod n, \qquad \varphi(n) = n\prod_{p \mid n}\left(1 - \tfrac{1}{p}\right).aφ(n)≡1(modn),φ(n)=np∣n∏​(1−p1​).

The worked solution

Check an answer or open a hint to unlock the worked solution.

Have you tried it?

Work it out on paper first. It is fine to get stuck or make a mistake: that is how we learn. When you are ready, go through the solution one step at a time, and check each step against your own.

Step 1. Sort the fractions. Each kn\dfrac{k}{n}nk​ with 1≤k≤n1 \le k \le n1≤k≤n reduces to a unique ad\dfrac{a}{d}da​ with d∣nd \mid nd∣n, 1≤a≤d1 \le a \le d1≤a≤d and gcd⁡(a,d)=1\gcd(a, d) = 1gcd(a,d)=1.

Step 2. Go back. Each such ad\dfrac{a}{d}da​ comes from exactly one kkk, namely k=a⋅ndk = a \cdot \dfrac{n}{d}k=a⋅dn​.

Step 3. Count. For each divisor ddd there are φ(d)\varphi(d)φ(d) choices of aaa. The nnn fractions are split into groups of sizes φ(d)\varphi(d)φ(d), so ∑d∣nφ(d)=n\sum_{d \mid n}\varphi(d) = n∑d∣n​φ(d)=n. Proof complete.

Step 4. The count up to 12. Fractions in (0,1](0, 1](0,1] in lowest terms with denominator exactly bbb number φ(b)\varphi(b)φ(b). So the count is φ(1)+⋯+φ(12)=1+1+2+2+4+2+6+4+6+4+10+4=46\varphi(1) + \cdots + \varphi(12) = 1 + 1 + 2 + 2 + 4 + 2 + 6 + 4 + 6 + 4 + 10 + 4 = 46φ(1)+⋯+φ(12)=1+1+2+2+4+2+6+4+6+4+10+4=46.

Step 5. For 36. The theorem gives ∑d∣36φ(d)=36\sum_{d \mid 36}\varphi(d) = 36∑d∣36​φ(d)=36. Directly: 1+1+2+2+2+6+4+6+12=361 + 1 + 2 + 2 + 2 + 6 + 4 + 6 + 12 = 361+1+2+2+2+6+4+6+12=36 for d=1,2,3,4,6,9,12,18,36d = 1, 2, 3, 4, 6, 9, 12, 18, 36d=1,2,3,4,6,9,12,18,36.

Answer: 464646 fractions, and the divisor sum for 363636 is 363636.

Log in to save this for later
← All Problems
← Find the last two digits of 13²⁰²⁶, that is, its remainder on division by 100…Find every positive integer n with φ(n) = 12… →
More onNumber Theory

Discussion (0)

Log in to join the discussion.

Loading…

More on this topic

  1. The triangular numbers are 1, 3, 6, 10, …, where the nth one is (n(n + 1))/2…Advanced
  2. Prove that the equation x³ + y³ + z³ = n has no solution in integers when n leaves remainder 4 or 5…Advanced
  3. Find every triple of positive integers a ≤ b ≤ c with 1/a + 1/b + 1/c = 1, and prove that there are…Advanced
  4. Find all pairs of positive integers (x, y) with x² - y² = 945…Hard
  5. A teacher wants a list of every primitive Pythagorean triple whose hypotenuse is less than 100…Advanced
All problems on this topic →