Step 23 / 64

University

The dossier equation, packed once

Fermat42 names the suspect once: non-zero a, b and a⁴ + b⁴ = c².

Start with a concrete example

A case file can contain three things: numbers, conditions on them, and an equation. Opening the equation field is like taking the right sheet out of a folder; it does not prove a new equation by itself.

A small check: try the idea

Think with the concrete example above. You can try again.

Does opening the equation field in a proof package, by itself, prove a new equation?

Read the answer and reasoning

No; it retrieves evidence already in the package. Think of taking the equation sheet out of a folder. It is existing evidence, now available to use in the next step.

Build the idea in three steps

  1. The whole case works with one shorthand: Fermat42 a b c says that a and b are non-zero and a ^ 4 + b ^ 4 = c ^ 2. The docstring promises the payoff: no integers satisfy it, so Fermat’s exponent four follows.
  2. Bundle theorems keep the dossier tidy: comm swaps a and b, because addition does not care about order — delta Fermat42 unfolds the shorthand first, then rw [add_comm] turns one side into the other.
  3. Name the suspect once, and every later page can say “a Fermat42 solution” instead of repeating three conditions — the same economy the whole library lives on.

A small example

Finding a field in a nested conjunction: the equation is packed as the third component — h.1.2.2 picks out a ^ 4 + b ^ 4 = c ^ 2 from the bundle, exactly how the proofs below reach it.

Lean definition · original excerpt

Mathlib · db584cd · Four.lean

/-- Shorthand for three non-zero integers `a`, `b`, and `c` satisfying `a ^ 4 + b ^ 4 = c ^ 2`.We will show that no integers satisfy this equation. Clearly Fermat's Last theorem for n = 4follows. -/def Fermat42 (a b c : ℤ) : Prop :=  a ≠ 0 ∧ b ≠ 0 ∧ a ^ 4 + b ^ 4 = c ^ 2 namespace Fermat42 theorem comm {a b c : ℤ} : Fermat42 a b c ↔ Fermat42 b a c := by  delta Fermat42  rw [add_comm]  tauto

How to read this Lean

comm’s proof is a small study in mechanics: delta unfolds the definition on both sides, rw [add_comm] reshapes one side, and tauto settles the logical bookkeeping. The neighboring lemmas mul and ne_zero live just below the excerpt — scaling a solution by k and the fact that c cannot be zero. The factual work of the case starts after the bookkeeping.

Where this idea is used

7. The veterans’ cabinet
I’m lost · Help

Mika’s help desk

The dossier equation, packed once

One thing at a time

Read the three explanation steps first. The Lean source is there for a closer look afterwards; you do not have to read it first.

In simpler words

Fermat42 names the suspect once: non-zero a, b and a⁴ + b⁴ = c².

Earlier ideas are listed under “Start with these ideas” on this page.

A small clue

Finding a field in a nested conjunction: the equation is packed as the third component — h.1.2.2 picks out a ^ 4 + b ^ 4 = c ^ 2 from the bundle, exactly how the proofs below reach it.

Close this panel to return to the exact place you were reading. These are prepared hints for this page.

Start with the first small story →