Skip to content

Add Ehrhart's sharp volume inequality - #387

Open
Vilin97 wants to merge 8 commits into
mainfrom
codex/import-openai-ehrhart-2026-09-04
Open

Add Ehrhart's sharp volume inequality#387
Vilin97 wants to merge 8 commits into
mainfrom
codex/import-openai-ehrhart-2026-09-04

Conversation

@Vilin97

@Vilin97 Vilin97 commented Sep 4, 2026

Copy link
Copy Markdown
Owner

Summary

  • Import OpenAI's formalization of Ehrhart's sharp volume inequality from ten-proofs, based on canonical commit 94bc0feb6a9ff12c7d31d6de640a725c9d43d2b6 and Dean Cureton's optimized proof development.
  • Split the 55,880-line monolith into seven coherent modules, each below Lean Pool's 10,000-code-line limit.
  • Expose a documented 19-declaration API while marking proof-local implementation declarations explicitly private.
  • Register the sharp inequality and its centered-simplex equality case.

Optimization

  • Exact source dependency closure retained 2,354 of 2,356 explicit declarations; removed the one genuinely unused declaration and retained the one source-elaboration dependency that proof-term reachability alone misses.
  • Replaced the Mathlib umbrella import with minimized module imports: 8,707 to 4,203 build jobs (51.7% fewer).
  • Artifact-clean build: 73.79s wall, 2,344,044 KiB peak RSS, versus 82s for the repaired umbrella-import monolith.
  • Shortened eleven heavily repeated internal bridge names, removing roughly 34k characters from their call sites.
  • Split the only two over-limit proofs into focused internal lemmas; removed two unused typeclass arguments and all current-toolchain deprecation/style warnings.

Verification

  • lake build LeanPool.EhrhartVolumeInequality (artifact-clean, warning-free)
  • lake exe runLinter LeanPool.EhrhartVolumeInequality
  • lake exe lint-style LeanPool.EhrhartVolumeInequality
  • lake exe mk_all --check
  • deterministic header, forbidden-text, registry-card, file-size, and proof-size checks
  • all four headline declarations checked through the public entry module
  • 19 public declarations pass the allowed-axiom audit
  • compiled option/backdoor audit passes

@greptile-apps

greptile-apps Bot commented Sep 4, 2026

Copy link
Copy Markdown

Greptile Summary

The PR imports and registers a modular formalization of Ehrhart's sharp volume inequality.

  • Adds a public entry module backed by seven transitively imported proof modules.
  • Registers the principal volume inequality and centered-simplex sharpness results.
  • Records the upstream repository, canonical revision, authorship, license, and mixed provenance.

Important Files Changed

Filename Overview
LeanPool/EhrhartVolumeInequality.lean Defines the documented project entry point and publicly re-exports the complete module chain.
LeanPool/EhrhartVolumeInequality/Convergence.lean Contains the final convergence arguments and the publicly exposed sharp volume inequality.
LeanPool/EhrhartVolumeInequality/Foundations.lean Establishes the foundational definitions and centered-simplex sharpness declarations used by the headline result.
LeanPool/EhrhartVolumeInequality/Convexity.lean Adds the convexity portion of the proof pipeline and publicly links later and earlier modules.
LeanPool/EhrhartVolumeInequality/FourierAnalysis.lean Adds the Fourier-analytic stage of the formalization within the transitive public import chain.
LeanPool/projects.yml Registers the project, its four main results, upstream revision, Apache-2.0 license, and provenance.
LeanPool.lean Adds the Ehrhart entry module and all component modules to the repository umbrella import.

Reviews (8): Last reviewed commit: "Merge remote-tracking branch 'origin/mai..." | Re-trigger Greptile

@github-actions

github-actions Bot commented Sep 4, 2026

Copy link
Copy Markdown
Contributor

Proof profile (new / modified Lean files)

lake build wall time (changed modules): 168.69 s (= 2.81 min) — user 476.95 s, sys 13.08 s.

This build covers the changed modules and their dependency cones on top of the restored cache. The serial per-file sums below are useful for ranking slow files, not as a build budget.

Total heartbeats: 7,135 maxHeartbeats units across 8 files (56,429 added LOC).

Sum of lean --profile: 416073.8 ms (= 416.07 s). Import-excluded time: 400863.8 ms (= 400.86 s).

Count-heartbeats wall-clock total: 344.00 s. Repeated import cost inside lean --profile: 15210.0 ms (= 15.21 s).

Heartbeat values come from Mathlib's linter.countHeartbeats and are already in maxHeartbeats units. Per-file wall clocks are measured under parallel load and are noisier than heartbeats.

LOC counts added lines in the profiled Lean files from this PR diff.

File LOC Heartbeats (maxHB) Count wall (s) lean --profile (s) Without import (s) Import (s) Decls Errors
LeanPool/EhrhartVolumeInequality/Foundations.lean 8,862 1,418 46.34 57.13 55.42 1.71 492 0
LeanPool/EhrhartVolumeInequality/Variation.lean 9,133 1,394 55.86 62.88 61.20 1.68 440 5
LeanPool/EhrhartVolumeInequality/FourierAnalysis.lean 9,181 1,253 46.33 63.95 62.23 1.72 431 0
LeanPool/EhrhartVolumeInequality/Regularization.lean 9,130 1,108 72.53 74.78 73.01 1.77 425 0
LeanPool/EhrhartVolumeInequality/Convexity.lean 8,745 842 40.37 55.76 53.97 1.79 291 0
LeanPool/EhrhartVolumeInequality/Resolvent.lean 9,190 767 66.25 83.23 81.46 1.77 254 0
LeanPool/EhrhartVolumeInequality/Convergence.lean 2,168 353 13.69 15.81 13.34 2.47 46 0
LeanPool/EhrhartVolumeInequality.lean 20 0 2.63 2.54 0.24 2.30 0 0
Total 56,429 7,135 344.00 416.07 400.86 15.21 2379 5

Aggregate phase totals

Phase Time
typeclass inference 139370.0 ms (= 139.37 s)
tactic execution 89540.0 ms (= 89.54 s)
interpretation 48591.0 ms (= 48.59 s)
elaboration 30091.2 ms (= 30.09 s)
type checking 27634.0 ms (= 27.63 s)
blocked (unaccounted) 21315.0 ms (= 21.32 s)
simp 15271.0 ms (= 15.27 s)
import 15210.0 ms (= 15.21 s)
tacticAnalysis 6358.4 ms (= 6.36 s)
linting 4509.3 ms (= 4.51 s)
ring 3485.0 ms (= 3.48 s)
parsing 3199.0 ms (= 3.20 s)

Slowest changed modules (from lake build)

Changed module Lake time
LeanPool.EhrhartVolumeInequality.Regularization 29.00 s
LeanPool.EhrhartVolumeInequality.Resolvent 29.00 s
LeanPool.EhrhartVolumeInequality.Foundations 23.00 s
LeanPool.EhrhartVolumeInequality.Variation 23.00 s
LeanPool.EhrhartVolumeInequality.FourierAnalysis 22.00 s
LeanPool.EhrhartVolumeInequality.Convexity 21.00 s
LeanPool.EhrhartVolumeInequality.Convergence 7.40 s
LeanPool.EhrhartVolumeInequality 1.50 s
Per-file `lean --profile` output

LeanPool/EhrhartVolumeInequality.lean

import took 2.3s
cumulative profiling times:
	elaboration 0.15ms
	import 2.3s
	initialization 41ms
	interpretation 191ms
	linting 0.343ms
	module linting 0.00167ms
	overlappingInstancesLinter 0.491ms
	parsing 0.0364ms
	tacticAnalysis 2.35ms
real 3.23
user 1.38
sys 1.08

LeanPool/EhrhartVolumeInequality/Convergence.lean

import took 2.47s
interpretation of Mathlib.Tactic._aux_Mathlib_Tactic_Linarith_Frontend___elabRules_Mathlib_Tactic_nlinarith_1._boxed took 319ms
interpretation of Lean.Elab.Tactic._aux_Mathlib_Tactic_Widget_Calc___elabRules_Lean_calcTactic_1._boxed took 161ms
tactic execution of Mathlib.Tactic.nlinarith took 249ms
interpretation of Lean.Elab.Tactic._aux_Mathlib_Tactic_Widget_Calc___elabRules_Lean_calcTactic_1._boxed took 104ms
cumulative profiling times:
	aesop 88.8ms
	attribute application 0.81ms
	compilation (IR) 0.31ms
	compilation (LCNF base) 2.77ms
	compilation (LCNF impure) 1.26ms
	compilation (LCNF mono) 1.92ms
	congr simp thm 21.6ms
	dsimp 84.8ms
	elaboration 981ms
	fix level params 7.16ms
	import 2.47s
	initialization 30.6ms
	instantiate metavars 21.8ms
	interpretation 2.74s
	let-to-have transformation 1.34ms
	linting 194ms
	module linting 0.00201ms
	norm_num 164ms
	overlappingInstancesLinter 18.6ms
	parsing 121ms
	process pre-definitions 87.7ms
	ring 197ms
	share common exprs 77.3ms
	simp 561ms
	tactic execution 3.95s
	tacticAnalysis 267ms
	type checking 644ms
	typeclass inference 3.07s
real 7.01
user 14.61
sys 1.34

LeanPool/EhrhartVolumeInequality/Convexity.lean

import took 1.79s
interpretation of Mathlib.Tactic._aux_Mathlib_Tactic_Linarith_Frontend___elabRules_Mathlib_Tactic_nlinarith_1._boxed took 119ms
interpretation of Mathlib.Tactic._aux_Mathlib_Tactic_Linarith_Frontend___elabRules_Mathlib_Tactic_nlinarith_1._boxed took 983ms
interpretation of Mathlib.Tactic._aux_Mathlib_Tactic_Linarith_Frontend___elabRules_Mathlib_Tactic_nlinarith_1._boxed took 174ms
elaboration took 145ms
tactic execution of Lean.Parser.Tactic.simpa took 222ms
tactic execution of Lean.Parser.Tactic.refine took 446ms
tactic execution of Lean.Parser.Tactic.rewriteSeq took 136ms
tactic execution of Mathlib.Tactic.nlinarith took 366ms
cumulative profiling times:
	aesop 66.6ms
	attribute application 4.34ms
	blocked (unaccounted) 125ms
	compilation (IR) 0.257ms
	compilation (LCNF base) 1.89ms
	compilation (LCNF impure) 0.916ms
	compilation (LCNF mono) 1.4ms
	congr simp thm 95.4ms
	dsimp 286ms
	elaboration 7.2s
	fix level params 30.6ms
	import 1.79s
	initialization 30.4ms
	instantiate metavars 58.7ms
	interpretation 8.7s
	let-to-have transformation 9.49ms
	linting 661ms
	module linting 0.00169ms
	norm_num 332ms
	overlappingInstancesLinter 89.2ms
	parsing 480ms
	process pre-definitions 340ms
	ring 536ms
	share common exprs 282ms
	simp 1.23s
	tactic execution 16s
	tacticAnalysis 958ms
	type checking 3.25s
	typeclass inference 13.2s
real 17.68
user 55.19
sys 1.52

LeanPool/EhrhartVolumeInequality/Foundations.lean

import took 1.71s
tactic execution of Lean.Parser.Tactic.refine took 854ms
interpretation of Mathlib.Tactic._aux_Mathlib_Tactic_Linarith_Frontend___elabRules_Mathlib_Tactic_nlinarith_1._boxed took 105ms
simp took 135ms
simp took 148ms
simp took 170ms
typeclass inference of CoeT took 122ms
interpretation of Mathlib.Tactic._aux_Mathlib_Tactic_Linarith_Frontend___elabRules_Mathlib_Tactic_nlinarith_1._boxed took 124ms
interpretation of Mathlib.Tactic._aux_Mathlib_Tactic_Linarith_Frontend___elabRules_Mathlib_Tactic_nlinarith_1._boxed took 131ms
interpretation of Mathlib.Tactic._aux_Mathlib_Tactic_Linarith_Frontend___elabRules_Mathlib_Tactic_nlinarith_1._boxed took 105ms
interpretation of Mathlib.Tactic._aux_Mathlib_Tactic_Linarith_Frontend___elabRules_Mathlib_Tactic_nlinarith_1._boxed took 267ms
interpretation of Mathlib.Tactic._aux_Mathlib_Tactic_Linarith_Frontend___elabRules_Mathlib_Tactic_nlinarith_1._boxed took 198ms
cumulative profiling times:
	aesop 171ms
	attribute application 7.27ms
	blocked (unaccounted) 7.23s
	compilation (IR) 1.93ms
	compilation (LCNF base) 29.1ms
	compilation (LCNF impure) 7.73ms
	compilation (LCNF mono) 14.9ms
	congr simp thm 80.2ms
	dsimp 162ms
	elaboration 2.6s
	fix level params 38.2ms
	import 1.71s
	initialization 39.4ms
	instantiate metavars 83.3ms
	interpretation 9.51s
	let-to-have transformation 7.62ms
	linting 737ms
	module linting 0.00175ms
	norm_num 537ms
	overlappingInstancesLinter 124ms
	parsing 513ms
	process pre-definitions 461ms
	ring 848ms
	share common exprs 346ms
	simp 2.85s
	tactic execution 8.99s
	tacticAnalysis 1.09s
	type checking 3.34s
	typeclass inference 15.6s
real 16.62
user 48.74
sys 1.81

LeanPool/EhrhartVolumeInequality/FourierAnalysis.lean

import took 1.72s
typeclass inference of Module.IsTorsionFree took 135ms
typeclass inference of ZeroHomClass took 117ms
tactic execution of Lean.Parser.Tactic.exact took 168ms
cumulative profiling times:
	attribute application 13.1ms
	blocked (unaccounted) 9.3s
	compilation (IR) 0.584ms
	compilation (LCNF base) 5.32ms
	compilation (LCNF impure) 2.32ms
	compilation (LCNF mono) 3.88ms
	congr simp thm 59.5ms
	dsimp 239ms
	elaboration 4.04s
	fix level params 34.2ms
	import 1.72s
	initialization 34.7ms
	instantiate metavars 50.5ms
	interpretation 6.54s
	let-to-have transformation 12.8ms
	linting 746ms
	module linting 0.00173ms
	norm_num 221ms
	overlappingInstancesLinter 104ms
	parsing 531ms
	process pre-definitions 492ms
	ring 420ms
	share common exprs 291ms
	simp 1.48s
	tactic execution 10.3s
	tacticAnalysis 1.01s
	type checking 4.7s
	typeclass inference 21.6s
real 19.01
user 53.99
sys 1.79

LeanPool/EhrhartVolumeInequality/Regularization.lean

import took 1.77s
elaboration took 112ms
simp took 164ms
interpretation of Mathlib.Tactic._aux_Mathlib_Tactic_Linarith_Frontend___elabRules_Mathlib_Tactic_nlinarith_1._boxed took 106ms
interpretation of Mathlib.Tactic._aux_Mathlib_Tactic_Linarith_Frontend___elabRules_Mathlib_Tactic_nlinarith_1._boxed took 103ms
typeclass inference of MeasureTheory.Measure.IsNegInvariant took 102ms
tactic execution of Lean.Parser.Tactic.exact took 171ms
tactic execution of Lean.Parser.Tactic.exact took 110ms
ring took 104ms
simp took 173ms
ring took 228ms
tactic execution of Lean.Parser.Tactic.rewriteSeq took 144ms
tactic execution of Lean.Parser.Tactic.rewriteSeq took 111ms
simp took 164ms
tactic execution of Lean.Parser.Tactic.change took 114ms
simp took 143ms
simp took 156ms
simp took 150ms
typeclass inference of SMul took 104ms
typeclass inference of SMul took 101ms
tactic execution of Lean.Parser.Tactic.refine took 205ms
tactic execution of Lean.Parser.Tactic.rewriteSeq took 170ms
tactic execution of Lean.Parser.Tactic.refine took 129ms
tactic execution of Lean.Parser.Tactic.rewriteSeq took 217ms
type checking took 144ms
cumulative profiling times:
	attribute application 37ms
	blocked (unaccounted) 1.56s
	compilation (IR) 0.539ms
	compilation (LCNF base) 4.86ms
	compilation (LCNF impure) 2.05ms
	compilation (LCNF mono) 3.56ms
	congr simp thm 119ms
	dsimp 287ms
	elaboration 5.61s
	fix level params 40.3ms
	import 1.77s
	initialization 34.7ms
	instantiate metavars 72.6ms
	interpretation 6.44s
	let-to-have transformation 25.9ms
	linting 715ms
	module linting 0.00164ms
	norm_num 159ms
	overlappingInstancesLinter 113ms
	parsing 527ms
	process pre-definitions 506ms
	ring 722ms
	share common exprs 359ms
	simp 3.77s
	tactic execution 16.5s
	tacticAnalysis 1.04s
	type checking 5.36s
	typeclass inference 29s
real 25.78
user 72.84
sys 1.68

LeanPool/EhrhartVolumeInequality/Resolvent.lean

import took 1.77s
tactic execution of Lean.calcTactic took 711ms
interpretation of Mathlib.Tactic._aux_Mathlib_Tactic_Linarith_Frontend___elabRules_Mathlib_Tactic_nlinarith_1._boxed took 346ms
interpretation of Mathlib.Tactic._aux_Mathlib_Tactic_Linarith_Frontend___elabRules_Mathlib_Tactic_nlinarith_1._boxed took 494ms
typeclass inference of Module.IsTorsionFree took 338ms
interpretation of Mathlib.Tactic._aux_Mathlib_Tactic_Linarith_Frontend___elabRules_Mathlib_Tactic_nlinarith_1._boxed took 101ms
tactic execution of Lean.Parser.Tactic.change took 137ms
interpretation of Mathlib.Tactic._aux_Mathlib_Tactic_Linarith_Frontend___elabRules_Mathlib_Tactic_nlinarith_1._boxed took 106ms
tactic execution of Lean.Parser.Tactic.refine took 130ms
tactic execution of Lean.Parser.Tactic.rewriteSeq took 207ms
type checking took 152ms
tactic execution of Mathlib.Tactic.nlinarith took 141ms
interpretation of Lean.Elab.Tactic._aux_Mathlib_Tactic_Widget_Calc___elabRules_Lean_calcTactic_1._boxed took 117ms
simp took 197ms
interpretation of Lean.Elab.Tactic._aux_Mathlib_Tactic_Widget_Calc___elabRules_Lean_calcTactic_1._boxed took 117ms
typeclass inference of SecondCountableTopologyEither took 152ms
tactic execution of Lean.Parser.Tactic.rewriteSeq took 136ms
cumulative profiling times:
	attribute application 3.6ms
	compilation (IR) 0.111ms
	compilation (LCNF base) 1.52ms
	compilation (LCNF impure) 0.422ms
	compilation (LCNF mono) 0.759ms
	congr simp thm 87.6ms
	dsimp 360ms
	elaboration 6.05s
	fix level params 48ms
	import 1.77s
	initialization 30.7ms
	instantiate metavars 94.7ms
	interpretation 8.05s
	let-to-have transformation 253ms
	linting 716ms
	module linting 0.00171ms
	norm_num 119ms
	overlappingInstancesLinter 95.3ms
	parsing 538ms
	process pre-definitions 588ms
	ring 252ms
	share common exprs 422ms
	simp 2.64s
	tactic execution 19.9s
	tacticAnalysis 941ms
	type checking 5.97s
	typeclass inference 34.3s
real 26.88
user 82.93
sys 1.61

LeanPool/EhrhartVolumeInequality/Variation.lean

import took 1.68s
interpretation of Mathlib.Tactic._aux_Mathlib_Tactic_Linarith_Frontend___elabRules_Mathlib_Tactic_nlinarith_1._boxed took 133ms
tactic execution of Lean.Parser.Tactic.obtain took 108ms
tactic execution of Lean.Parser.Tactic.exact took 187ms
LeanPool/EhrhartVolumeInequality/Variation.lean:2965:34: error: unsolved goals
n k : ℕ
K : CenteredBody n
hk : 0 < k
F : SourceFiniteEnergyPotential K
htransport : finiteEnergySourceGradientPushforward F = normalizedTargetBodyMeasure K
b : OrthonormalBasis (Fin (bergmanDimension K k)) ℂ ↥(momentMonomialSpan K hk F htransport)
z : TorusCharacters.LogSpace n
s : ↥(momentMonomialSpan K hk F htransport)
hrepr :
  (momentHolomorphicRepresentative K hk F htransport) (∑ i, ⟪b i, s⟫_ℂ • b i) z =
    (momentHolomorphicRepresentative K hk F htransport) s z
i : Fin (bergmanDimension K k)
a✝ : i ∈ Finset.univ
⊢ ⟪↑((starRingEnd ℂ) ((momentHolomorphicRepresentative K hk F htransport) (b i) z) • b i), ↑s⟫_ℂ =
    (momentHolomorphicRepresentative K hk F htransport) (b i) z * ⟪↑(b i), ↑s⟫_ℂ
tactic execution of Lean.Parser.Tactic.rewriteSeq took 212ms
typeclass inference of SeminormedAddCommGroup took 441ms
LeanPool/EhrhartVolumeInequality/Variation.lean:2969:42: warning: This simp argument is unused:
  inner_smul_left

Hint: Omit it from the simp argument list.
  [apply] simp only [Submodule.coe_inner, RingHomCompTriple.comp_apply, RingHom.id_apply]

Note: This linter can be disabled with `set_option linter.unusedSimpArgs false`
LeanPool/EhrhartVolumeInequality/Variation.lean:2970:12: warning: This simp argument is unused:
  RingHomCompTriple.comp_apply

Hint: Omit it from the simp argument list.
  [apply] simp only [Submodule.coe_inner, inner_smul_left, RingHom.id_apply]

Note: This linter can be disabled with `set_option linter.unusedSimpArgs false`
LeanPool/EhrhartVolumeInequality/Variation.lean:2971:12: warning: This simp argument is unused:
  RingHom.id_apply

Hint: Omit it from the simp argument list.
  [apply] simp only [Submodule.coe_inner, inner_smul_left, RingHomCompTriple.comp_apply]

Note: This linter can be disabled with `set_option linter.unusedSimpArgs false`
tactic execution of Lean.Parser.Tactic.rewriteSeq took 172ms
tactic execution of Mathlib.Tactic.nlinarith took 142ms
interpretation of Mathlib.Tactic._aux_Mathlib_Tactic_Linarith_Frontend___elabRules_Mathlib_Tactic_nlinarith_1._boxed took 149ms
tactic execution of Lean.Parser.Tactic.exact took 2.39s
tactic execution of Lean.Parser.Tactic.refine took 131ms
tactic execution of Lean.Parser.Tactic.rewriteSeq took 196ms
type checking took 111ms
tactic execution of Mathlib.Tactic.nlinarith took 270ms
cumulative profiling times:
	aesop 69.6ms
	attribute application 6.37ms
	blocked (unaccounted) 3.1s
	compilation (IR) 0.594ms
	compilation (LCNF base) 7.6ms
	compilation (LCNF impure) 2.46ms
	compilation (LCNF mono) 3.9ms
	congr simp thm 97.8ms
	dsimp 276ms
	elaboration 3.61s
	fix level params 38.8ms
	import 1.68s
	initialization 31ms
	instantiate metavars 61.3ms
	interpretation 6.42s
	let-to-have transformation 21.9ms
	linting 740ms
	module linting 0.00167ms
	norm_num 164ms
	overlappingInstancesLinter 98.4ms
	parsing 489ms
	process pre-definitions 472ms
	ring 510ms
	share common exprs 323ms
	simp 2.74s
	tactic execution 13.9s
	tacticAnalysis 1.05s
	type checking 4.37s
	typeclass inference 22.6s
real 19.97
user 59.75
sys 1.67
error: profile command exited with status 1

Advisory only — never blocks merge. Full log uploaded as the proof-profile artifact.

@github-actions

github-actions Bot commented Sep 4, 2026

Copy link
Copy Markdown
Contributor

🤖 LLM review (gpt-5.6-sol, 5 rubrics)

Reviewed head: 229b54fb665d9048ca1f19b8a4294a16049aea81

⚠️ Partial review — diff exceeded the size budget. The bodies of the 2 largest of 10 file patches were elided before review; an elided review cannot approve.

Verdict: 🤔 needs_discussion — computed from the rubric verdicts below, not chosen by a model.

Rubric Verdict Bottom line
Faithfulness pass Based on the partial diff, all four headline declarations match their informal claims and expose exactly the stated geometric hypotheses.
Novelty pass Based on the partial diff, none of the four headline results is already formalized in the supplied Mathlib or pool prior art.
Significance pass Based on the partial diff, this is a good-fit research-level formalization of a named sharp theorem in convex geometry and geometry of numbers.
Sources pass On the partial diff, the pinned ten-proofs repository is consistent as a provenance citation, but the cited commit’s contents are not visible enough to verify the theorem statement.
Code quality (advisory) 🤔 discuss Partial-diff review: the proof code is structured, but the project carries a substantial block of semantically unrelated imports that needs dependency cleanup before merge.
Aspect Value
Proves the claim proves_it
Assumed, not proved The main inequality takes the body’s convexity, compactness, full dimensionality, barycenter condition, and unique interior lattice point as hypotheses, all disclosed by the card; exists_centeredBody_sharp additionally assumes only 0 < n, while the two simplex equalities are unconditional.
Matches cited source 🟡 unverifiable
Fit good_fit
Level research
Branch convex geometry and geometry of numbers
Mode theory_building
Code quality 3 / 5

Statement check: The main theorem assumes 0 < n, convexity, compactness, nonempty interior, barycenter S = 0, and interiorLatticePoints S = {0}, then proves normalizedVolume S ≤ ((n : ℝ) + 1) ^ n / (n.factorial : ℝ); the other headlines establish the centered simplex’s exact volume and barycenter and construct it as a sharp CenteredBody witness.

The project proves Ehrhart's sharp volume bound via ehrhart_volume_inequality_for_sets and establishes sharpness through the centered simplex with exact volume, zero barycenter, and a unique interior lattice point.

Code quality findings (1)

  • import-residuePR-wide
    The project uses unrelated number-theory, ring-theory, tactic-extension, and manifold modules as transitive dependency carriers. This obscures the actual requirements of each module and makes the development unnecessarily sensitive to unrelated Mathlib refactors. Replace these with direct imports for the declarations used in each consuming file, and remove tactic extensions that are not exercised.
    Evidence: In LeanPool/EhrhartVolumeInequality/Foundations.lean: import Mathlib.NumberTheory.Height.NumberField, import Mathlib.NumberTheory.Height.Projectivization, import Mathlib.RingTheory.Etale.Weakly, import Mathlib.RingTheory.Henselian, import Mathlib.RingTheory.RegularLocalRing.Defs, import Mathlib.RingTheory.TotallySplit, import Mathlib.Tactic.NormNum.LegendreSymbol, and import Mathlib.Tactic.NormNum.NatFib. The same pattern continues with import Mathlib.Algebra.Ring.IsFormallyReal in Variation.lean and import Mathlib.Geometry.Manifold.Sheaf.Basic in FourierAnalysis.lean.

Tokens: 2,498,798 in / 14,080 out across 5 rubric calls · Tier: flex · Effort: xhigh · Cost: $12.8108
Each rubric is an independent review against .github/review-rubrics/ on top of .github/REVIEW_RULES.md. Disagree? Reply on the PR; rules can be updated in a PR of their own.

@Vilin97

Vilin97 commented Sep 4, 2026

Copy link
Copy Markdown
Owner Author

/review

@github-actions

github-actions Bot commented Sep 4, 2026

Copy link
Copy Markdown
Contributor

LLM review skipped: Lean Action CI conclusion was in_progress. Push a fix or comment /review after CI is green.

@Vilin97 Vilin97 added the needs-maintainer Requires a maintainer decision; automation must not merge label Sep 4, 2026
@Vilin97

Vilin97 commented Sep 4, 2026

Copy link
Copy Markdown
Owner Author

Automation disposition: needs-maintainer

Reviewed exact head bb8a246 after a verified repair pass. Unrelated imports were replaced by precise dependencies, the unused public dimension premise was removed, and the full project builds. The duplicated normalization-at-a-minimizer theory remains architectural, and the size-limited review still cannot cover the largest files; maintainer review is required before merge.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

needs-maintainer Requires a maintainer decision; automation must not merge

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant