Math 2.0

Number theory Proof

Proof that the units of Z/nZ are the residues coprime to n

Builds on Integers modulo nResidue classUnit of a ringGreatest common divisorBézout's identity

Proof

We prove the two directions separately.

  1. Let n≥1n \geq 1 and aa be integers. Write [b][b] for the residue class of an integer bb modulo nn, so [b]=b+nℤ[b] = b + n\Z.
  2. In the ring ℤ/nℤ\Z/n\Z the product is [b][c]=[bc][b][c] = [bc], and the identity is [1][1]. The ring is commutative, because bc=cbbc = cb.
  3. If b=c+nmb = c + nm for an integer mm, then b+nℤ=c+nℤb + n\Z = c + n\Z, so [b]=[c][b] = [c].
  4. If [b]=[c][b] = [c], then b∈[b]=[c]=c+nℤb \in [b] = [c] = c + n\Z, so b=c+nmb = c + nm for an integer mm.
  5. First assume gcd⁡(a,n)=1\gcd(a, n) = 1. By Bézout's identity, there are integers xx and yy with ax+ny=1ax + ny = 1.
  6. Then ax=1+n(−y)ax = 1 + n(-y). By step 3, [a][x]=[ax]=[1][a][x] = [ax] = [1].
  7. By step 2, also [x][a]=[1][x][a] = [1]. So [a][a] is a unit of ℤ/nℤ\Z/n\Z, with inverse [x][x].
  8. Now assume that [a][a] is a unit. Then there is a class [x][x] with [a][x]=[1][a][x] = [1], that is, [ax]=[1][ax] = [1].
  9. By step 4, there is an integer mm with ax=1+nmax = 1 + nm, so 1=ax−nm1 = ax - nm.
  10. Let d=gcd⁡(a,n)d = \gcd(a, n) be the greatest common divisor. It exists and d≥1d \geq 1, because n≥1n \geq 1, so aa and nn are not both 00.
  11. The integer dd divides aa and nn, so it divides ax−nm=1ax - nm = 1.
  12. A positive divisor of 11 is 11, so d=1d = 1.
  13. Thus [a][a] is a unit of ℤ/nℤ\Z/n\Z if and only if gcd⁡(a,n)=1\gcd(a, n) = 1.

Idea

An inverse of [a][a] is an integer xx with ax+ny=1ax + ny = 1 for some integer yy. Bézout's identity gives such xx and yy exactly when gcd⁡(a,n)=1\gcd(a, n) = 1. Conversely, such an equation forces every common divisor of aa and nn to divide 11.

Reading path

To understand this page from the ground up, read these 32 pages in order. The foundations come first. The path takes the proofs Proof of Bézout's identity, Proof of the commutativity of addition by induction, Proof of strong induction from ordinary induction, Proof that congruence is compatible with addition, Proof that congruence is compatible with multiplication, Proof of the well-ordering principle from strong induction, Proof of the division algorithm.

Show the path as a graph
Definition by recursion, concept, no evidence levelDefinition by recursi…conceptDivisibility, definition, no evidence levelDivisibilitydefinitionGroup, concept, no evidence levelGroupconceptMathematical induction, concept, no evidence levelMathematical inductionconceptNatural numbers, object, no evidence levelNatural numbersobjectPeano axioms, concept, no evidence levelPeano axiomsconceptCongruence modulo n, definition, no evidence levelCongruence modulo ndefinitionGreatest common divisor, definition, no evidence levelGreatest common divis…definitionRing, definition, no evidence levelRingdefinitionSuccessor function, definition, no evidence levelSuccessor functiondefinitionResidue class, definition, no evidence levelResidue classdefinitionProof that congruence is compatible with addition, proof, no evidence levelProof that congruence…proofProof that congruence is compatible with multiplication, proof, no evidence levelProof that congruence…proofUnit of a ring, definition, no evidence levelUnit of a ringdefinitionAddition of natural numbers, definition, no evidence levelAddition of natural n…definitionThe successor function is injective, statement, no evidence levelThe successor functio…statementZero is not a successor, statement, no evidence levelZero is not a success…statementCongruence is compatible with addition, statement, no evidence levelCongruence is compati…statementCongruence is compatible with multiplication, statement, no evidence levelCongruence is compati…statementProof of the commutativity of addition by induction, proof, no evidence levelProof of the commutat…proofOrder on the natural numbers, definition, no evidence levelOrder on the natural …definitionIntegers modulo n, definition, no evidence levelIntegers modulo ndefinitionCommutativity of addition, statement, no evidence levelCommutativity of addi…statementProof of strong induction from ordinary induction, proof, no evidence levelProof of strong induc…proofStrong induction, statement, no evidence levelStrong inductionstatementProof of the well-ordering principle from strong induction, proof, no evidence levelProof of the well-ord…proofWell-ordering principle, statement, no evidence levelWell-ordering princip…statementProof of the division algorithm, proof, no evidence levelProof of the division…proofDivision algorithm, statement, no evidence levelDivision algorithmstatementProof of Bézout's identity, proof, no evidence levelProof of Bézout's ide…proofBézout's identity, statement, no evidence levelBézout's identitystatementProof that the units of Z/nZ are the residues coprime to n, proof, no evidence levelProof that the units …proof
Each page uses the pages above it. The colour of the bar on a box shows how strong the evidence is, and the box also gives it as text. The list has the same pages.
  • no evidence level
  1. Definition by recursion concept
  2. Divisibility definition
  3. Group concept
  4. Mathematical induction concept
  5. Natural numbers object
  6. Peano axioms concept
  7. Congruence modulo n definition
  8. Greatest common divisor definition
  9. Ring definition
  10. Successor function definition
  11. Residue class definition
  12. Proof that congruence is compatible with addition proof
  13. Proof that congruence is compatible with multiplication proof
  14. Unit of a ring definition
  15. Addition of natural numbers definition
  16. The successor function is injective statement
  17. Zero is not a successor statement
  18. Congruence is compatible with addition statement
  19. Congruence is compatible with multiplication statement
  20. Proof of the commutativity of addition by induction proof
  21. Order on the natural numbers definition
  22. Integers modulo n definition
  23. Commutativity of addition statement
  24. Proof of strong induction from ordinary induction proof
  25. Strong induction statement
  26. Proof of the well-ordering principle from strong induction proof
  27. Well-ordering principle statement
  28. Proof of the division algorithm proof
  29. Division algorithm statement
  30. Proof of Bézout's identity proof
  31. Bézout's identity statement
  32. Proof that the units of Z/nZ are the residues coprime to n proof

Where this leads

12 pages build on this one.

Further reading

  1. Web https://proofwiki.org/wiki/Multiplicative_Inverse_in_Monoid_of_Integers_Modulo_m
About this page
TagTKE9RVC3TQ
URIm2://TKE9RVC3TQ
Kindproof
WritingW0 stub
MSC11A07, 20K01
ProvesUnits of Z/nZ are the residues coprime to n
UsesIntegers modulo n, Residue class, Unit of a ring, Greatest common divisor, Bézout's identity
Changed4 November 2026

Markdown · JSON · Edit on GitHub

What this page needs for W1

  • an inventory row: the row of the inventory that the node accounts for (0 of 1)
  • a source with a locator (0 of 1)

The writing levels say how complete the text of a page is. They do not measure its truth.

What links here

No page links to this page yet.