Repository navigation
Import nonsingularity of flat Apéry rectangles - #1204
Conversation
There was a problem hiding this comment.
Author validation: approve for inclusion.
- Faithfulness.
FlatRectangleNonSingularOnquantifies over the two numerical semigroups, their injectively enumerated minimal Apéry exponents and all rectangle factorizations, and concludes that the determinant oflogYZMatrixis nonzero.IsFlatAlgencodes the unique decomposition criterion of Huang–Jafari Lemma 3.1. The rational statement follows by clearing denominators in both finite generating sets. The PR claims precisely the determinant conclusion of Question 4.13(2). - Proof and significance. The canonical-factorization proof establishes existence, uniqueness, and that the row's own coefficient vanishes. After scaling to gcd one,
box_mod_bijectiveidentifies the unique box coordinates with residues.cyclic_hajos_stepuses the standard character of the quotient by the current subgroup to identify a new digit whose carry lands in the subgroup. The determinant proof kills a hypothetical kernel vector one coordinate at a time. The subgroup extension has no numerical-semigroup assumptions and is independently importable. - Novelty and sources. The pinned Mathlib and Tau Ceti searches found the character and matrix machinery used by the port but no cyclic digit subgroup-extension theorem or Apéry-rectangle determinant theorem. The prior Lean Pool PR #1160 registered the repository in the candidates list. No project card or import for this result exists on main. The pinned Apache-2.0 source, release timestamp, proof-workflow credit and the cited paper support the card.
- Engineering and trust. Reviewed the five proof modules, the public wrappers and the card. The import uses explicit Mathlib modules and the standard additive-character API, with no generated certificates or external verification. The public wrapper, all 78 scoped declarations, the card declarations, axiom closure, option-injection and compiler-message audits, generated indexes and text style passed locally. The profiled cyclic proof completed successfully. GitHub's required checks and configured review provide the release gate for this head.
Project metadata advisoryThis advisory summarizes source-project metadata for project entries added or changed by this PR.
License is read from GitHub SPDX metadata when available, and the last commit and Lean version are read from the source repository's default branch. |
|
Advisory cross-file review against Lean Pool's supervisory rubric. This is not by itself a significance, source-verification, or merge verdict. [Low impact] No blocking issue was established, but the unavailable upstream evidence prevents an unconditional merge recommendation. SummaryImports the flat Apéry rectangle nonsingularity proof and exports the cyclic-group extension theorem.
Reviews (3) · Last reviewed commit: "Label generalized canonical factorizatio..." · Reviewed by Greptile |
Proof profile (new / modified Lean files)
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: 110,163 maxHeartbeats units across 7 valid files (1,096 added LOC). Sum of Count-heartbeats wall-clock total: 24.20 s. Repeated import cost inside Heartbeat values sum disjoint root command traces with LOC counts added lines in the profiled Lean files from this PR diff.
Aggregate phase totals
Slowest changed modules (from
|
| Changed module | Lake time |
|---|---|
LeanPool.HuangJafari.CyclicFactorization |
4.60 s |
LeanPool.HuangJafari.Statement |
3.70 s |
LeanPool.HuangJafari.FlatRectangle |
1.50 s |
LeanPool.HuangJafari.Factorization |
1.30 s |
LeanPool.HuangJafari.Scaling |
1.20 s |
LeanPool.HuangJafari.Imports |
0.73 s |
LeanPool.HuangJafari |
0.72 s |
Per-file `lean --profile` output
LeanPool/HuangJafari.lean
import took 1.43s
cumulative profiling times:
declTypeLinter 0.267ms
elaboration 0.21ms
import 1.43s
initialization 33.4ms
interpretation 101ms
linting 0.5ms
module linting 0.0232ms
parsing 0.0289ms
tacticAnalysis 0.417ms
real 2.22
user 0.74
sys 0.74
LeanPool/HuangJafari/CyclicFactorization.lean
import took 2.12s
cumulative profiling times:
attribute application 0.0212ms
congr simp thm 2.49ms
declTypeLinter 2.83ms
dsimp 0.872ms
elaboration 20.8ms
fix level params 0.533ms
import 2.12s
initialization 27.5ms
instantiate metavars 3.05ms
interpretation 217ms
let-to-have transformation 0.0795ms
linting 17ms
module linting 0.0191ms
norm_num 0.14ms
parsing 11.6ms
process pre-definitions 4.85ms
share common exprs 3.23ms
simp 60.6ms
tactic execution 175ms
tacticAnalysis 2.72ms
type checking 39.4ms
typeclass inference 223ms
real 3.33
user 1.63
sys 0.92
LeanPool/HuangJafari/Factorization.lean
import took 556ms
cumulative profiling times:
attribute application 0.0303ms
blocked (unaccounted) 0.177ms
congr simp thm 1.73ms
declTypeLinter 4.84ms
elaboration 11.7ms
fix level params 1.14ms
import 556ms
initialization 25.9ms
instantiate metavars 2.23ms
interpretation 172ms
let-to-have transformation 0.0365ms
linting 13.5ms
module linting 0.0234ms
parsing 9.77ms
process pre-definitions 5.4ms
share common exprs 2.73ms
simp 79.4ms
tactic execution 129ms
tacticAnalysis 3.18ms
type checking 69.8ms
typeclass inference 179ms
real 1.65
user 1.29
sys 0.69
LeanPool/HuangJafari/FlatRectangle.lean
import took 646ms
cumulative profiling times:
attribute application 0.0956ms
congr simp thm 8.05ms
declTypeLinter 7.01ms
dsimp 6.05ms
elaboration 32ms
fix level params 0.947ms
import 646ms
initialization 26.6ms
instantiate metavars 9.08ms
interpretation 311ms
let-to-have transformation 0.0888ms
linting 34.1ms
module linting 0.0302ms
norm_num 2.95ms
parsing 18.6ms
process pre-definitions 12.3ms
ring 18.4ms
share common exprs 7.66ms
simp 220ms
tactic execution 350ms
tacticAnalysis 6.23ms
type checking 170ms
typeclass inference 272ms
real 2.07
user 2.15
sys 0.73
LeanPool/HuangJafari/Imports.lean
import took 582ms
cumulative profiling times:
declTypeLinter 0.131ms
elaboration 0.0722ms
import 582ms
initialization 26.6ms
interpretation 93.2ms
linting 0.2ms
module linting 0.0256ms
parsing 0.00173ms
tacticAnalysis 0.121ms
real 1.37
user 0.74
sys 0.70
LeanPool/HuangJafari/Scaling.lean
import took 562ms
cumulative profiling times:
attribute application 0.0826ms
congr simp thm 4.29ms
declTypeLinter 7.34ms
elaboration 34.9ms
fix level params 3.96ms
import 562ms
initialization 26ms
instantiate metavars 5.81ms
interpretation 199ms
let-to-have transformation 0.157ms
linting 25ms
module linting 0.0274ms
parsing 13ms
process pre-definitions 13ms
share common exprs 8.39ms
simp 370ms
tactic execution 279ms
tacticAnalysis 4.88ms
type checking 40.5ms
typeclass inference 410ms
real 1.74
user 2.00
sys 0.70
LeanPool/HuangJafari/Statement.lean
import took 542ms
cumulative profiling times:
attribute application 0.0719ms
compilation (IR) 0.14ms
compilation (LCNF base) 1.63ms
compilation (LCNF impure) 0.519ms
compilation (LCNF mono) 0.984ms
declTypeLinter 7.81ms
elaboration 23.8ms
fix level params 0.205ms
import 542ms
initialization 25.6ms
instantiate metavars 0.106ms
interpretation 135ms
let-to-have transformation 0.0757ms
linting 6.18ms
module linting 0.0209ms
parsing 5.19ms
process pre-definitions 3.89ms
share common exprs 0.435ms
tacticAnalysis 1.96ms
type checking 1.75ms
typeclass inference 29.4ms
real 1.36
user 0.81
sys 0.69
Advisory only — never blocks merge. Full log uploaded as the proof-profile artifact.
🤖 LLM review (
|
| Rubric | Verdict | Bottom line |
|---|---|---|
| Faithfulness | ✅ pass |
All three card claims match the Lean, and the targeted build passed while the head’s pool CI was still running. Head CI |
| Novelty | ✅ pass |
Source searches of pinned Mathlib, pinned Tau Ceti, and the pool found no duplicate headline, with broader equivalence still unverifiable and all seven changed Lean modules compiling locally while the head’s full CI build remained in progress. CI run |
| Significance | ✅ pass |
The general determinant theorem meets the pool’s research bar, and all seven added Lean modules compiled locally while the full CI build was still running. Build pool check |
| Sources | ✅ pass |
The determinant statement matches Huang–Jafari’s Question 4.13(2), and Le’s pinned formalization supports the cyclic subgroup lemma and the labelled generalization of canonical factorization. Huang–Jafari · Pinned Lean source |
| Code quality (advisory) | flag |
All seven Lean modules compiled locally and Lean Action CI passed for this head, with duplicated rectangle transport and digit-sum proofs worth consolidating. Lean Action CI |
| Aspect | Value |
|---|---|
| Proves the claim | ✅ proves_it |
| Assumed, not proved | The determinant theorem takes finite positive generation, exponent flatness, a rectangle indexed by the minimal Apéry exponents, and the canonical rows as inputs. The separate factorization theorem proves those rows exist uniquely using the stated cancellation and weight membership hypotheses. The cyclic theorem assumes the stated digit bijection, digit ranges of size at least two, and a subgroup represented by a proper subset of positions. |
| Matches cited source | ✅ matches |
| Fit | ✅ good_fit |
| Level | research |
| Branch | commutative algebra |
| Mode | mixed |
| Code quality | 3 / 5 |
Statement check: For every flat rectangular numerical semigroup extension in ℚ≥0, the integer matrix with the side lengths on the diagonal and the negated canonical digits off the diagonal satisfies (logYZMatrix β B).det ≠ 0. Huang–Jafari, equation (4)
The project resolves Huang–Jafari’s Question 4.13(2) in every finite dimension by using a character sum to extend subgroups in a cyclic digit factorization and prove (logYZMatrix β B).det ≠ 0. Question 4.13(2)
Novelty findings (2)
- partial-overlap —
LeanPool/HuangJafari/Factorization.lean:94
The existing Apéry decomposition covers a base generated by one positive natural number.HuangJafari.existsUnique_rectangleFactorizationhandles a flat rectangular extension of cancellative additive commutative monoids and proves unique bounded coordinates withq.2 i = 0for each boundary row.
Evidence: Tau Ceti’sAddSubmonoid.existsUnique_mem_aperySet_mul_add_equniquely writes an element as a multiple of a positive member plus an Apéry representative. Tau Ceti declaration - partial-overlap —
LeanPool/HuangJafari/CyclicFactorization.lean:128
The PR reuses Tau Ceti’s bounded representatives lemma after proving the existence of an unused digit satisfyingj ∉ J ∧ β j • g j ∈ H. It then identifies the enlarged subgroup with the digit vectors supported oninsert j J.
Evidence: Tau Ceti’sSubgroup.mem_sup_zpowers_iff_exists_mul_powgives bounded representatives after adjoining a normalizing element under the premisehpow : x ^ m ∈ H. Tau Ceti declaration
Code quality findings (5)
- duplicate-proof —
LeanPool/HuangJafari/Scaling.lean:247
Denominator clearing and gcd normalization each choose preimages for the weights and row offsets, then transport the same three rectangle hypotheses. Extract this step into a lemma in Scaling.lean so a change to the rectangle predicates requires one update.
Evidence: InflatRectangleNonSingular_iff_nat,let sN : Fin n → ℕ := fun i ↦ Classical.choose (hs_mem i)is followed byrw [← hsN_eq] at hs hrect hfact. In FlatRectangle.lean:214,flatRectangleNonSingularNat_holdsrepeats this withlet s₁ : Fin n → ℕ := fun i ↦ Classical.choose (hs_mem i)andrw [← hs₁_eq] at hs hrect hfact. - duplicate-proof —
LeanPool/HuangJafari/CyclicFactorization.lean:168
Both directions of the subgroup extension split the sum at the changed digit and prove that every other summand is unchanged. The two factorization proofs repeat the same bookkeeping. UseFunction.updatefor the digit changes and rewrite the resulting sums withFunction.apply_updateandFinset.sum_update_of_mem.
Evidence: Incyclic_hajos_step, each direction usesFinset.sum_congr rflonFinset.univ.erase j, first afterlet c : ∀ i : Fin n, Fin (β i) := Function.update c₀ j rand then afterlet c₀ : ∀ i : Fin n, Fin (β i) := fun i ↦ if i = j then ⟨0, hβ0 i⟩ else c i. The same split appears intwo_le_beta_of_isRectangleat Factorization.lean:62 andexistsUnique_rectangleFactorizationat Factorization.lean:126. - library-reuse —
LeanPool/HuangJafari/FlatRectangle.lean:30
The difference predicate carries its own closure proofs, including a positive and negative split for integer scaling. Bundle the same carrier as anAddSubgroup ℤ. Negation swaps the two witnesses, andzsmul_memandsum_memsupply the closure steps used in the Bézout argument.
Evidence:InDiffis defined by∃ a ∈ S, ∃ b ∈ S, (a : ℤ) - (b : ℤ) = z. The proof ofinDiff_zmulintroduceslet p : ℕ := c.toNatandlet q : ℕ := (-c).toNat, andexists_gcd_diffusesFinset.sum_induction _ (InDiff S) (fun _ _ ↦ inDiff_add). - proof-reuse —
LeanPool/HuangJafari/FlatRectangle.lean:131
The surjectivity helper constructs an Apéry representative by a separate least-witness argument. Its sole caller already has flatness. Pass that hypothesis to the helper, decompose the constructed representative in the larger monoid, and use divisibility to send the base term to zero modulod.
Evidence:apery_mod_surjuseslet w : ℕ := Nat.find hexandexact Nat.find_min hex hs₂_lt ⟨hs₂, hs₂_mod⟩. Its only call isrcases apery_mod_surj hd_dvd h1_diff z with ⟨w, hw_ap, hw_mod⟩inbox_mod_bijective, which takes(hflat : IsFlatAlg S S'). - library-reuse —
LeanPool/HuangJafari/CyclicFactorization.lean:39
The carry proof contains local proofs for finding an index outside a smaller finset and mapping a finite sum through a character. UseFinset.exists_mem_notMem_of_card_lt_cardfor the first andmap_sumonχ.toAddMonoidHomfor the second, leaving the proof focused on the carry argument.
Evidence:exists_carry_into_subgroupproveshave hex_out : ∃ i₀ : Fin n, i₀ ∉ J := byviahave hJ_univ : J = Finset.univ := by. At line 76, it provesχ (∑ a ∈ s, f a) = ∏ a ∈ s, χ (f a)viainduction s using Finset.induction_on with.
Tokens: 9,264,694 in / 46,313 out across 5 model calls · Tier: codex-subscription · Effort: xhigh · Billing: Codex subscription quota (no API credits) · Estimated cost: $37.7535 (Standard API equivalent; uncached input)
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.
CI was not green for this commit at review time; this review does not replace CI.
There was a problem hiding this comment.
Author validation follow-up: approve for inclusion at 391eae8a3f.
- The matrix docstring now cites Equation (4), and the project card states the cyclic lemma’s lower bound of two on each digit range. The determinant theorem retains its statement. I checked the corrected citation against the paper and the radix hypothesis against the Lean signature. Huang–Jafari, §4 · Initial configured review
- The carry proof uses Mathlib’s cyclic quotient equivalence and standard additive character. It then uses Tau Ceti’s bounded representatives to identify the enlarged subgroup. The scaling proof shares the lift of finite generating sets and uses Mathlib’s closure-map and finite Bézout lemmas. Canonical factorization now accepts direct generator membership and derives digit positivity from the bounded row. The two arithmetic reductions still lift their exponent data at the point of use.
- The warning-free project build, generated indexes, text style, seven-module declaration lint, card declarations, axiom closure, forbidden-option environment audit and build-message audit passed. The five-module benchmark after review repairs was 6.97 s median (7.33, 6.97, 6.78 s), against 10.12 s for the original baseline. The cyclic module, the determinant module and the scaling module passed standalone profiling.
|
/review Please review |
|
/review Please review |
Vilin97
left a comment
There was a problem hiding this comment.
Author validation follow-up: approve for inclusion at 06a8af949a.
The upstream canonical factorization assumes an enumeration of the minimal Apéry exponents. The port’s theorem instead assumes each weight belongs to the larger monoid. I verified that the card now identifies this generalization and cites the upstream statement. The Lean sources are identical to the previous head, whose proof and dependency review is linked below. The generated indexes, project build, card declarations, and axiom, environment and compiler-message audits passed locally. Pinned upstream theorem · Author review of the Lean changes
Imports the Lean proof of the nonsingularity assertion in Huang and Jafari’s Question 4.13(2). The result turns the rectangular Apéry factorization into a cyclic-group digit factorization and uses a character sum to control the factorizations that form the rows of the matrix.
Source and scope
e82d75ac598e79a87066cff8388bbb646c4d47af. The pinned README credits a Lean and proof workflow using Claude Opus and Gemini, directed and verified by Le. Release · Source revisionPort and validation
fc4f59e577. Split the proof into modules for statements, canonical factorization, scaling, the cyclic-group argument and the determinant. Replaced the Mathlib umbrella import with explicit dependencies, used Mathlib’s additive character and reduction homomorphism, and removed the diagnostic command.taskset -c 4-7 lake build LeanPool.HuangJafari.FlatRectangleon the Azure VM removed the five project modules’ build artifacts before each run and reused the pinned dependency cache. Median wall time was 10.12 s before (10.12, 9.46, 10.30 s) and 5.24 s after (5.84, 5.24, 5.10 s). Median Lake time forCyclicFactorizationwas 2.5 s before and 1.7 s after. VM load varied between these runs. The optimized cyclic module also passed standalone Lean profiling.