FormalConjecturesForMathlib/NumberTheory/PrimeGap.lean
Explanation legend Lean4 Domain Explanation Language (L4DEL)
L4DEL explanations are a separate layer. They do not change the Lean source. Intuition is explanatory prose; numbered items are a reading path; sources link the wording back to evidence.
- L4DEL
- Lean4 Domain Explanation Language
Credit: The upstream authors and contributors retain credit for the project and mathematics. lean4-explainer only renders their pinned source and adds the separately disclosed explanation layer.
Project sources: Pinned project documentation, Formal Conjectures paper, arXiv v1
1 declarations, 0 contain sorry, 0 declared as axioms
Imported by 1 file
- def
primeGapThe prime gap: the difference between the $n+1$-th and $n$-th prime line 27 sourceSource documentation
The prime gap: the difference between the $n+1$-th and $n$-th prime.
standard axioms: Classical.choice, Quot.sound, propext what this means
Statement uses:
NatProof uses:
HSub.hSub,Nat.nth,Nat.Prime,HAdd.hAdd,OfNat.ofNat5 instances, coercions and auxiliary constants left out.
noncomputable def primeGap (n : ℕ) : ℕ := (n + 1).nth Nat.Prime - n.nth Nat.Prime