Show HN: Shrinking and distilling the 17.4M-line Riemann Hypothesis Lean proof (opens in a new tab)github.com
1 pointsWorking with Gemini 4 Carbon, I treated the archive like a compiler IR problem to measure how much of the 17.4M lines is dead or duplicate weight and extract a human-readable blueprint.
Static import graphs get tricked because files carry large unused import headers (for example, RiemannHypothesisOfEveryCharacter.lean is a 20-line Mathlib functional-equation proof sitting under 208 unused import lines). Joining all 175,187 source files against Andrew Sutherland's 61.5 GB lean4export kernel DAG (1.065B expression nodes, 1.48M declarations) and running exact kernel reachability, proof-irrelevant Prop/Def CSE, and transitive import reduction cuts:
175,187 to 105,044 .lean files (-40.0%, 70,143 dead files)
719,897 to 202,054 project import edges (-71.9%)
17,374,215 to 9,282,866 namespace-coalesced clean lines (-46.6%, -8.09M lines, zero custom axioms)
Across parallel subtasks, the raw proof re-proved identical propositions 241,514 times, including 66,548 lemmas already in Mathlib/Core. We also rewrote the 61.5 GB kernel export directly (-300,664 fold records, -20.5%) and verified it from scratch with Lean FRO's Rust kernel checker (con-ron --compare in --verified mode, 188.5s on 64 threads, exit 0 across all 5 RH and Dirichlet GRH theorems).Running Lengauer-Tarjan dominators on the cleaned DAG also explained why the live proof is still ~9.3M lines: EveryCharacterOfLiteratureOfVWin.lean defines ~110 Published.* slots for famous 20th-century theorems absent from Mathlib and proves them all from first principles (including a 44k-line proof of Hironaka embedded resolution of singularities in char 0, 124k lines of toroidal Shimura compactifications, Bhatt-Scholze crystalline lattices, Moriwaki Arakelov bigness, Casselman-Wallach, and Siegel-Weil), feeding a 6-act cyclic 4/(3o+1) Landau prime-sum positivity argument.
Interactive Lengauer-Tarjan Dominator Flamegraph & 6-Act Blueprint:
https://tanclary.github.io/riemann-blueprint/
Comments (0) 0 threads
No comments yet.