Riemann hypothesis: the Lean proof, cleaned up together
The 2026 Lean proof of the Riemann hypothesis and GRH, machine-checked by others, not refereed, no word from Clay; cleaned up together: more readable, faster to build, the theorems unchanged

chore(Lib/Adelic): omit the unused PolishSpace G in ofReal_mul_lintegral_iwasawa_translate
Browse filesThe build's one linter warning under src/ is IwasawaUnfolding.lean:397:0: the lemma does not use the section instance [PolishSpace G]. Add it to the omit above the lemma, as upstream did in 41164658f3; statement, proof and the one caller are untouched. Part of #2
Checks
build Program · lake build and Comparator
Details
challenge Program · challenge files and build config
Details
ci/docs
Details
+48 −11 routes/p1-lib-adelic/README.md View file
| @@ -5,23 +5,60 @@ status: working | ||
| 5 | 5 | # p1-lib-adelic |
| 6 | 6 | |
| 7 | 7 | P-1 (#2), unit: the **Adelic** folder of `src/Lib` (54 files): fix every linter warning Lean |
| 8 | -prints for its files, without changing any statement, and leave `show` as it is. | |
| 8 | +prints for its files, changing no statement, and leave `show` as it is. | |
| 9 | 9 | |
| 10 | -## Where the warnings come from | |
| 10 | +## The folder's warnings | |
| 11 | 11 | |
| 12 | -There is no Lean on this machine and none is installed. The warnings are read from the | |
| 13 | -site's own `build` logs, which replay every module's saved output: jobs 693, 836 and 1359 | |
| 14 | -each end `lake build Lib New Main Challenge` with one linter warning under `src/`, and it | |
| 15 | -is in this folder: | |
| 12 | +There is no Lean on this machine, and none was installed. The warnings are read from the site's | |
| 13 | +`build` logs. `checks/build.py` prints each step's last 25 lines, and its second step, `lake build | |
| 14 | +Lib New Main Challenge`, replays every module's saved output: that part of a log is whole, and it | |
| 15 | +names each module with a warning. Three jobs agree, on trees that differ from `main` only in files | |
| 16 | +of `src/New` (jobs 693, 836 and 1359; 1359 built `520a333`, whose `src/` is `main` `b525acd`'s): | |
| 17 | +under `src/` there is one linter warning, and it is in this folder. | |
| 16 | 18 | |
| 17 | 19 | ``` |
| 18 | -src/Lib/Adelic/QuotientMeasure/IwasawaUnfolding.lean:397:0: automatically included section | |
| 19 | -variable(s) unused in theorem `New.ofReal_mul_lintegral_iwasawa_translate`: [PolishSpace G] | |
| 20 | +⚠ [16310/17258] Replayed Lib.Adelic.QuotientMeasure.IwasawaUnfolding | |
| 21 | +warning: src/Lib/Adelic/QuotientMeasure/IwasawaUnfolding.lean:397:0: automatically included section variable(s) unused in theorem `New.ofReal_mul_lintegral_iwasawa_translate`: | |
| 22 | + [PolishSpace G] | |
| 20 | 23 | ``` |
| 21 | 24 | |
| 22 | -The other 15 folders of `src/Lib` print none there. | |
| 25 | +The log's five other warnings are `declaration uses 'sorry'` in `Challenge.lean`, which states the | |
| 26 | +theorems with `sorry` on purpose. The other 53 files of this folder print none, and neither do the | |
| 27 | +other 15 folders of `src/Lib`. | |
| 28 | + | |
| 29 | +What this does not show: a warning that the cached build never printed. Those logs are upstream's | |
| 30 | +cache for `630d1e43` (docker/README.md), built with the toolchain and lakefile pinned here. | |
| 31 | + | |
| 32 | +## The change | |
| 33 | + | |
| 34 | +One line, `IwasawaUnfolding.lean:393`: `omit [IsHaarMeasure ν] [IsHaarMeasure lam] in` becomes | |
| 35 | +`omit [PolishSpace G] [IsHaarMeasure ν] [IsHaarMeasure lam] in`. | |
| 36 | + | |
| 37 | +- The lemma's statement and proof are untouched. Its signature loses the instance argument | |
| 38 | + `[PolishSpace G]`, which its statement does not use: that is the warning. | |
| 39 | +- Its one caller, `New.lintegral_iwasawa` (line 487), passes `w ν κ i` and lets Lean find its | |
| 40 | + instances, so it is untouched too. | |
| 41 | +- It is upstream's fix: leanprover-community/riemann-hypothesis `41164658f3` (2026-12-02, "refactor: | |
| 42 | + drop two unused instance arguments", merged in batch `d7b6cb86f4`). There the `variable` block | |
| 43 | + above the lemma, the lemma and its caller read as they do here, line for line. | |
| 44 | + | |
| 45 | +This file already omits unused section variables the same way above six other declarations (lines | |
| 46 | +57, 97, 119, 208, 424, 512). `omit` is also the one fix that leaves the lemma's assertion as it is: | |
| 47 | +the linter asks to omit the variable or to move it out of scope, and both take `[PolishSpace G]` | |
| 48 | +out of the signature. If "without changing any statement" forbids that, this warning cannot be | |
| 49 | +fixed, and the maintainer should say so. | |
| 50 | + | |
| 51 | +## How to reproduce | |
| 52 | + | |
| 53 | +- `shoal get jobs/1359/log` (693 and 836 likewise): the lines after `$ lake build Lib New Main | |
| 54 | + Challenge`. | |
| 55 | +- `git diff origin/main -- src/Lib/Adelic/QuotientMeasure/IwasawaUnfolding.lean`. | |
| 56 | +- `python3 checks/challenge.py .` in the repository's root: `ok`, on this branch. | |
| 23 | 57 | |
| 24 | 58 | ## Next |
| 25 | 59 | |
| 26 | -Add `[PolishSpace G]` to the `omit` line above that lemma, as upstream did in | |
| 27 | -`41164658f3`, push, and read `challenge` and `build` on the head. | |
| 60 | +The pull request is open (Part of #2). Its `build` log says whether the warning is gone: the file | |
| 61 | +and the 172 modules that import it are rebuilt there, and no module of this folder should be | |
| 62 | +replayed with a warning. Then the maintainer's review and its replay report. On the evidence above, | |
| 63 | +the other 15 folders of `src/Lib` have nothing to fix, so their part of #2 is a question for the | |
| 64 | +maintainer, not a pull request. | |
+1 −1 src/Lib/Adelic/QuotientMeasure/IwasawaUnfolding.lean View file
| @@ -390,7 +390,7 @@ variable {G M : Type*} [Group G] [Group M] [TopologicalSpace G] [IsTopologicalGr | ||
| 390 | 390 | (κ : Measure K) [IsHaarMeasure κ] |
| 391 | 391 | {lam : Measure N} [IsHaarMeasure lam] (i : M →* G) |
| 392 | 392 | |
| 393 | -omit [IsHaarMeasure ν] [IsHaarMeasure lam] in | |
| 393 | +omit [PolishSpace G] [IsHaarMeasure ν] [IsHaarMeasure lam] in | |
| 394 | 394 | /-- Let `N` be unimodular, and let conjugation by `i m` multiply integrals over `N` by `w m`. The |
| 395 | 395 | integral of `f (i a * u * (n * i m * k) * l⁻¹)` over `K × M × N`, times `w m`, is the integral of |
| 396 | 396 | `f (i a * u * l⁻¹)`. -/ |