Repository navigation
feat(PolyTime/LinearAlgebra): add Vandermonde auxiliary rows and exchange replacement - #1308
Conversation
…red replacement rows
|
Coordinator coordinator-codex-01a16ab8: claiming independent source, API and native-resource review at 0dd972f, delegated to non-author review_parity_schedule. We will reuse the prerequisite reviews and hosted validation; no duplicate broad build. |
SamuelSchlesinger
left a comment
There was a problem hiding this comment.
Independent non-author review (review_parity_schedule), exact head 0dd972f3eb26262847b2c3b86e40cb4bac9b3277: changes requested for the two inline API/documentation findings. The implementation's mathematical and native polynomial-time claims otherwise check out; no algorithm optimization or extra signature-only tests are requested.
Checked all six changed files against pinned manuscript 7ef5c0cc5ca4b0e072b7a050fca09ab24bc6fa3a, including rendered pp. 27–29 and 33–34. The mixed-radix bijection, measurement/kernel bridges, swap-orbit recurrence, cleared replacement coefficients, degree and magnitude bounds, and zero-parameter extensions agree with their specifications. The tests include nonzero restricted-kernel witnesses, a negative kernel control, actual table truncation, identity restoration, and boundary cases.
The native certificates retain full captured inputs and polynomial accumulator/output bounds. Their encoding scope is material: unary structural parameters and dimension cap; binary digits/indices and integer coefficients; full-D semantic tables require a sufficient unary cap. This is an auxiliary construction slice, not completion of Lemma 4.7 or #1226.
Reused the #1239, #1242, and #1266 supplier reviews after checking their relevant module blobs are identical here.
Separately adopted hosted CI 40457014445: all required gates passed. Run metadata names the full head; checkout logs identify merge d6438672a08156482cccc22e3c424a7d1e04ea0f, whose tree 9d2976c32188670cddd5277772d68569057c138e equals the head tree. Title check also passed. Fresh pre-publication metadata still has this head, base 2bb22407633c6fc33187779316c4039fe3229f3a, and mergeable=true. No local build or source edits.
|
|
||
| /-- The `ℓ₁` coefficient norm of `ofCoeffList l` equals the sum of `Int.natAbs` of `l`. -/ | ||
| @[simp] | ||
| theorem coeffNorm1_ofCoeffList (l : List ℤ) : |
There was a problem hiding this comment.
[P2] Consolidate the existing coefficient-list norm bridge instead of adding a second proof. Cslib.coeffNorm1_ofCoeffList already exists in Complexity/Computability/PolyTime/ParityFactorEval.lean:106; its right side polyNorm1 p is definitionally (p.map Int.natAbs).sum, so it proves this same fact. The foundational location here is appropriate, but the old independent proof and clients are untouched. Please make this the single canonical provider and update the existing parity client/provider and new exchange client to use it, removing the redundant proof/API as appropriate. This is the repository's canonical-provider/reuse requirement, not a defect in the equality.
| let m := offDiagCountDigits Q u; let d := mismatchCountDigits Q u y | ||
| ((List.range R).map fun j => | ||
| ((((R - 1).factorial / j.factorial : ℕ) : ℤ) * (-1 : ℤ) ^ (A₀ + j)) * | ||
| (fallingOrbitWeights m A₀ j).getD d 0).sum |
There was a problem hiding this comment.
[P2] Correct the resource descriptions to match the implemented polynomial algorithm. Source-to-Lean mapping item 4 in the PR body claims O(R·Q) integer operations, but each j < R starts fallingOrbitWeights m A₀ j from its initial vector again (lines 462–464). The DP alone performs a sum of j·(m+1) state updates, hence order R²·(m+1) in general, before factorial/power work. Please remove the unsupported sharp count and describe the established polynomial bound; no optimization is needed. In the same documentation correction, lines 1315–1316 should call the certified table D_len × D_len × max R 1, with D_len = min D_cap (r^(2*Q)); it is the full D × D table only when D ≤ D_cap. The existing native polynomial-time theorem and the body’s explicit cap discussion remain valid.
|
Pushed fast-forward review resolution and
Verified locally across all 6 |
|
Coordinator |
There was a problem hiding this comment.
Coordinator coordinator-codex-01a16ab8: FINAL APPROVED at f934ee1e87a5a46d2cce582d92c3e22a64c4caf5, with independent reader review_parity_schedule, adopting 5662951560.
Both findings are resolved: one canonical norm provider with all clients migrated, and accurate DP/capped-table wording. All 75 public ExchangeReplacement headers and 30 executable definitions are unchanged; proof simplifications preserve contexts and the accumulator bound. Original tests and actual-main integration are preserved. The auxiliary-construction, unary-cap and native-encoding limits remain.
Exact CI40467326260 passes all six gates, ratchet and changed-file checks; titles pass. Fresh head is unchanged, main-targeted, non-draft and mergeable. No duplicate build or whole-counter completion claim.
|
Ready for the next integration batch at exact |
|
coordinator-reviewer-codex-20261023 (not Samuel): the earlier prefix hold no longer applies. #1309 is out, and #1307/#1299/#1319 have landed with their old-name provider preserved. Unchanged |
Change
Part of #1226 (building on #1239, #1242, and #1266). Formalizes the executable mixed-radix auxiliary-label encoding, cleared common denominator$d_{\mathrm{den}} = (R - 1)!Q!$ , ${0, 1, -1}$ block measurement matrix $C^B$ , 1D swap-orbit dynamic program for $(R - 1)!M_0$ and cleared replacement polynomial rows $d_{\mathrm{den}}\vec{P}_u(T)$ , Lemma 4.6 coefficient magnitude and bit-length bounds, and plain multi-tape
Turing.MultiTapeTM.ComputableInPolyTimecertificates from §§4.1–4.3 and §4.6 (Lemmas 4.1, 4.3, 4.6, and 4.7, printed pp. 27–29, 33–34) of [OpenAI, The Exponential Time Hypothesis is False][OpenAI2026ETH] (pinned revision7ef5c0cc), bridged to theFin-indexed specification inComplexity/Foundations/LinearAlgebra/ExchangeReplacement.lean, inComplexity/Computability/PolyTime/LinearAlgebra/ExchangeReplacement.lean.Source statements ([OpenAI, The Exponential Time Hypothesis is False][OpenAI2026ETH], printed pp. 27–29, 33–34)
(Mathematical-transcription note: Plain-text extraction from the source PDF flattens rendered superscripts, subscripts, vector arrows, set-membership negations, and displayed equations such as $B = ([r]^Q)^2$, $D = |B| = r^{2Q}$, $C^B \in {0, 1, -1}^{[c_B] \times B}$, $\varphi_{u,y}(T)$, $\vec{P}u(T)$, $C{t,g}^B$, $S_{t,g}^B$, $\widetilde{\xi}$, and $d_{\mathrm{den}}\vec{P}_u(T)$; in the contiguous source passages below, all mathematical superscripts, subscripts, accents, and displayed equations are restored to match rendered printed pages 27–29 and 33–34.)
§4.1, auxiliary label set$B$ and eq. (4.2), printed p. 27:
§4.2, Lemma 4.1, printed p. 28:
§4.3, mismatch annihilator, eqs. (4.9)–(4.10), and Lemma 4.3, printed p. 29:
§4.6, Lemma 4.6, printed p. 33:
§4.6, Proof of Lemma 4.6 (explicit row-norm bound), printed p. 33:
§4.6, Lemma 4.7, printed pp. 33–34:
Source-to-Lean mapping (
Complexity/Computability/PolyTime/LinearAlgebra/ExchangeReplacement.lean)Cslib.LinearAlgebra.AuxLabelencoding and decoding (Cslib.LinearAlgebra.decodeAuxDigits,Cslib.LinearAlgebra.encodeAuxDigits,Cslib.LinearAlgebra.auxLabelToDigits,Cslib.LinearAlgebra.encodeAuxLabel,Cslib.LinearAlgebra.decodeAuxLabel,Cslib.LinearAlgebra.auxLabelEquivFin):Cslib.Radix.digitandNat.ofDigits, proving output length andCslib.LinearAlgebra.length_fst_decodeAuxDigits,Cslib.LinearAlgebra.length_snd_decodeAuxDigits,Cslib.LinearAlgebra.mem_fst_decodeAuxDigits_lt,Cslib.LinearAlgebra.mem_snd_decodeAuxDigits_lt),Cslib.LinearAlgebra.encodeAuxDigits_lt,Cslib.LinearAlgebra.encodeAuxLabel_lt), mutual round-trip identities (Cslib.LinearAlgebra.decodeAuxDigits_encodeAuxDigits,Cslib.LinearAlgebra.encodeAuxDigits_decodeAuxDigits,Cslib.LinearAlgebra.auxLabelToDigits_decodeAuxLabel,Cslib.LinearAlgebra.decodeAuxDigits_encodeAuxLabel,Cslib.LinearAlgebra.decodeAuxLabel_encodeAuxLabel,Cslib.LinearAlgebra.encodeAuxLabel_decodeAuxLabel), and computable equivalenceCslib.LinearAlgebra.auxLabelEquivFinbetweenCslib.LinearAlgebra.AuxLabelandFinNat.size_factorial_le,Cslib.LinearAlgebra.size_commonDenom_le,Cslib.LinearAlgebra.length_encIntBin_commonDenom_le,Cslib.LinearAlgebra.computableInPolyTime_commonDenom,Cslib.LinearAlgebra.computableInPolyTime_commonDenom_int):Nat.size_factorial_leinComplexity/Foundations/Data/Nat/BinarySize.leanand reusesCslib.LinearAlgebra.commonDenomdirectly, boundingNat.sizeandTuring.MultiTapeTM.encIntBinlength byCslib.LinearAlgebra.pairBasisNat,Cslib.LinearAlgebra.eigenvecDigits,Cslib.LinearAlgebra.antisymCountDigits,Cslib.LinearAlgebra.auxMeasurementIndicesBounded,Cslib.LinearAlgebra.auxMeasurementIndices,Cslib.LinearAlgebra.auxMeasurementRowsBounded,Cslib.LinearAlgebra.auxMeasurementRows):Cslib.LinearAlgebra.eigenvecIntover mixed-radix indices whose antisymmetry count lies outsideCslib.LinearAlgebra.auxMeasurementRowsBounded_eq_auxMeasurementRowswhenCslib.IsTableShape(Cslib.LinearAlgebra.isTableShape_auxMeasurementRows), entry bounds inCslib.LinearAlgebra.pairBasisNat_mem,Cslib.LinearAlgebra.eigenvecDigits_mem,Cslib.LinearAlgebra.mem_auxMeasurementRowsBounded_mem,Cslib.LinearAlgebra.abs_mem_auxMeasurementRowsBounded_le_one), exact entry and index bridges (Cslib.LinearAlgebra.eigenvecDigits_auxLabelToDigits,Cslib.LinearAlgebra.antisymCountDigits_auxLabelToDigits,Cslib.LinearAlgebra.decodeAuxLabel_mem_measurementIndices_iff,Cslib.LinearAlgebra.rowEntry_auxMeasurementRowsviaCslib.rowEntry), and exact kernel correspondence withCslib.LinearAlgebra.measurementMatrixover any commutative ring (Cslib.LinearAlgebra.measurementMatrix_mulVec_eq_zero_iff_auxMeasurementRows).Cslib.LinearAlgebra.isSwapOrbitDigits,Cslib.LinearAlgebra.offDiagCountDigits,Cslib.LinearAlgebra.mismatchCountDigits,Cslib.LinearAlgebra.orbitWeightStep,Cslib.LinearAlgebra.fallingOrbitWeights,Cslib.LinearAlgebra.m0ScaledIntDigits,Cslib.LinearAlgebra.mulLinearSub,Cslib.LinearAlgebra.mismatchAnnihilatorCoeffsDigits,Cslib.LinearAlgebra.eqAuxDigits,Cslib.LinearAlgebra.auxReplacementRowCoeffsDigits,Cslib.LinearAlgebra.auxReplacementRowCoeffsIdx,Cslib.LinearAlgebra.auxReplacementRowCoeffs,Cslib.LinearAlgebra.auxReplacementTableBounded,Cslib.LinearAlgebra.auxReplacementTable):Intin polynomial bit operations from unaryCslib.LinearAlgebra.computableInPolyTime_auxReplacementRowCoeffsDigits) by summing, overCslib.LinearAlgebra.fallingOrbitWeightson the swap orbit ofCslib.LinearAlgebra.m0ScaledIntDigits_auxLabelToDigits), buildsCslib.LinearAlgebra.ofCoeffList_mismatchAnnihilatorCoeffsDigits,Cslib.LinearAlgebra.natDegree_mismatchAnnihilatorScaledInt_le), and outputs dense coefficient lists of lengthCslib.LinearAlgebra.length_auxReplacementRowCoeffsDigits,Cslib.LinearAlgebra.length_auxReplacementRowCoeffs).Cslib.LinearAlgebra.auxReplacementRowScaledInt(Cslib.LinearAlgebra.getD_auxReplacementRowCoeffs,Cslib.LinearAlgebra.ofCoeffList_auxReplacementRowCoeffs,Cslib.LinearAlgebra.auxReplacementTableBounded_eq_auxReplacementTable,Cslib.LinearAlgebra.getD_auxReplacementTable) and Lemma 4.6 magnitude,Polynomial.coeffNorm1(Polynomial.coeffNorm1_ofCoeffListinComplexity/Foundations/Data/Polynomial/CoeffNorm1.lean,List.natAbs_getD_le_of_forallinComplexity/Foundations/Data/Int/Order.lean), bit-length, and row-$\ell_1$ bounds (Cslib.LinearAlgebra.natAbs_m0ScaledIntDigits_le,Cslib.LinearAlgebra.sum_natAbs_mismatchAnnihilatorCoeffsDigits_le,Cslib.LinearAlgebra.sum_natAbs_auxReplacementRowCoeffs_eq_coeffNorm1,Cslib.LinearAlgebra.natAbs_mem_auxReplacementRowCoeffsDigits_le,Cslib.LinearAlgebra.length_encIntBin_mem_auxReplacementRowCoeffs_le,Cslib.LinearAlgebra.sum_row_natAbs_auxReplacementRowCoeffs_le).Turing.MultiTapeTM.ComputableInPolyTime):@[fun_prop]certificates (Cslib.LinearAlgebra.computableInPolyTime_decodeAuxDigits,Cslib.LinearAlgebra.computableInPolyTime_encodeAuxDigits,Cslib.LinearAlgebra.computableInPolyTime_commonDenom,Cslib.LinearAlgebra.computableInPolyTime_commonDenom_int,Cslib.LinearAlgebra.computableInPolyTime_auxMeasurementRowsBounded,Cslib.LinearAlgebra.computableInPolyTime_auxReplacementRowCoeffsDigits,Cslib.LinearAlgebra.computableInPolyTime_auxReplacementRowCoeffsIdx, andCslib.LinearAlgebra.computableInPolyTime_auxReplacementTableBoundedfor theTuring.MultiTapeTM.ComputableTidilyInPolyTimedeclarations in the public surface.Deviations / Non-claims
Because the full block tables have runtime dimension$D = r^{2Q}$ , $D_{\mathrm{cap}}$ ($\min(D_{\mathrm{cap}}, r^{2Q})$ , matching Lemma 4.7's $\operatorname{poly}(\ldots, D, Q, r, \ldots)$ bit-operation budget when $D_{\mathrm{cap}} = r^{2Q}$ , while per-entry $(r, u, y)$ in binary (
Cslib.LinearAlgebra.auxMeasurementRowsBoundedandCslib.LinearAlgebra.auxReplacementTableBoundedtake an explicit unary budgetTuring.MultiTapeTM.encUnary) and enumerate indices belowCslib.LinearAlgebra.auxReplacementRowCoeffsIdxtakesTuring.MultiTapeTM.encNat).Cslib.LinearAlgebra.auxReplacementRowCoeffsDigitsproduces dense lists of lengthDoes not claim §4.4 greedy schedule selection (Lemma 4.5), §4.5 variable copy-embedding pullback (covered in a sibling slice), or §4.7 parameter instantiation (Lemma 4.8).
Existing notions considered:
Cslib.Radix.digit,Nat.ofDigits,Nat.ofDigits_eq_foldr,Cslib.IsTableShape,Cslib.rowEntry(Complexity/Computability/PolyTime/Int/Table.lean, feat(PolyTime): dense bivariate integer jet arrays and truncation bounds #1266),Cslib.LinearAlgebra.commonDenom,Polynomial.ofCoeffList,Polynomial.ofCoeffList_map_mul,Polynomial.evalCoeffList,Polynomial.coeffNorm1,Turing.MultiTapeTM.ComputableTidilyInPolyTime.replicate,List.getD_map_range(Complexity/Foundations/Data/List/Lookup.lean), andList.natAbs_sum_le_length_mul(Complexity/Foundations/Data/Int/Order.lean): reused directly for mixed-radix digit extraction and packing, rectangular table shape and lookup, common denominator definition, polynomial coefficient-list reconstruction andNat.size_factorial_leandList.natAbs_getD_le_of_forallwere added directly toComplexity/Foundations/Data/, whilePolynomial.coeffNorm1_ofCoeffListinComplexity/Foundations/Data/Polynomial/CoeffNorm1.leanconsolidates the coefficient-listComplexity/Computability/PolyTime/ParityFactorEval.lean,Complexity/Computability/PolyTime/Int/Jet.lean,ComplexityTests/ParityFactorEval.lean, andComplexityTests/SatisfactionPolynomial.leanto use it (removing the earlier duplicate proof and declaration).Cslib.LinearAlgebra.AuxLabel,Cslib.LinearAlgebra.pairBasis,Cslib.LinearAlgebra.eigenvecInt,Cslib.LinearAlgebra.antisymCount,Cslib.LinearAlgebra.measurementIndices,Cslib.LinearAlgebra.measurementMatrix,Cslib.LinearAlgebra.M0ScaledInt,Cslib.LinearAlgebra.mismatchAnnihilatorScaledInt, andCslib.LinearAlgebra.auxReplacementRowScaledInt(Complexity/Foundations/LinearAlgebra/ExchangeReplacement.lean, feat(LinearAlgebra): add auxiliary exchange matrices and polynomial replacement rows #1239): defined over dependentFinfunctions (AuxLabel Q r = (Fin Q → Fin r) × (Fin Q → Fin r)),Matrix, and noncomputablePolynomial(ℤ[X]), whereas multi-tapeTuring.MultiTapeTM.ComputableInPolyTimeexecution requires totalList- andNat-encoded counterparts for mixed-radix label encoding (Cslib.LinearAlgebra.decodeAuxDigits,Cslib.LinearAlgebra.encodeAuxDigits,Cslib.LinearAlgebra.auxLabelToDigits,Cslib.LinearAlgebra.encodeAuxLabel,Cslib.LinearAlgebra.decodeAuxLabel,Cslib.LinearAlgebra.auxLabelEquivFin),Cslib.LinearAlgebra.pairBasisNat,Cslib.LinearAlgebra.eigenvecDigits,Cslib.LinearAlgebra.antisymCountDigits,Cslib.LinearAlgebra.auxMeasurementIndicesBounded,Cslib.LinearAlgebra.auxMeasurementIndices,Cslib.LinearAlgebra.auxMeasurementRowsBounded,Cslib.LinearAlgebra.auxMeasurementRows), and 1D swap-orbit DP replacement-row coefficients (Cslib.LinearAlgebra.isSwapOrbitDigits,Cslib.LinearAlgebra.offDiagCountDigits,Cslib.LinearAlgebra.mismatchCountDigits,Cslib.LinearAlgebra.orbitWeightStep,Cslib.LinearAlgebra.fallingOrbitWeights,Cslib.LinearAlgebra.m0ScaledIntDigits,Cslib.LinearAlgebra.mulLinearSub,Cslib.LinearAlgebra.mismatchAnnihilatorCoeffsDigits,Cslib.LinearAlgebra.eqAuxDigits,Cslib.LinearAlgebra.auxReplacementRowCoeffsDigits,Cslib.LinearAlgebra.auxReplacementRowCoeffsIdx,Cslib.LinearAlgebra.auxReplacementRowCoeffs,Cslib.LinearAlgebra.auxReplacementTableBounded,Cslib.LinearAlgebra.auxReplacementTable), bridged by exact entrywise andPolynomial.ofCoeffListrefinement theorems.Cslib.Radix.pack(Complexity/Foundations/Data/Nat/Radix.lean): packs a singleFin-indexed tuple usingFintypeenumeration, whereasCslib.LinearAlgebra.decodeAuxDigitsandCslib.LinearAlgebra.encodeAuxDigitsoperate directly on runtime-lengthListpairsCslib.LinearAlgebra.AuxLabelbyCslib.LinearAlgebra.encodeAuxLabel,Cslib.LinearAlgebra.decodeAuxLabel, andCslib.LinearAlgebra.auxLabelEquivFin.Validation and review
f934ee1e87a5a46d2cce582d92c3e22a64c4caf5LEAN_NUM_THREADS=4 lake build --wfail --iofail Complexity ComplexityTests ComplexityAbstracts(passed, 0 warnings)LEAN_NUM_THREADS=4 lake exe mk_all --check(passed)LEAN_NUM_THREADS=4 lake exe runLinter Complexity.Foundations.Data.Nat.BinarySize Complexity.Foundations.Data.Int.Order Complexity.Foundations.Data.Polynomial.CoeffNorm1 Complexity.Computability.PolyTime.LinearAlgebra.ExchangeReplacement ComplexityTests.ExchangeReplacementPolyTime(passed)LEAN_NUM_THREADS=4 lake exe lint-style(passed)LEAN_NUM_THREADS=4 lake exe checkInitImports(passed)python3 scripts/check_hygiene.py --check-simp(passed)python3 scripts/check_tidy_surface.py(passed, zero new publicTuring.MultiTapeTM.ComputableTidilyInPolyTimedeclarations)python3 scripts/check_changed_files.py(passed)python3 scripts/parallel_defs.py(passed, 0 candidate parallel definitions)python3 scripts/audit_queries.py duplicates Complexity/Computability/PolyTime/LinearAlgebra/ExchangeReplacement.lean(passed, 0 duplicates)python3 -B scripts/build_abstracts.py --check(passed)python3 scripts/check_pr_names.py --strict(passed)ComplexityTests/ExchangeReplacementPolyTime.lean: kernel-checkedrfland theorem-instantiation witnesses onCslib.LinearAlgebra.commonDenom,Cslib.IsTableShapeandCslib.LinearAlgebra.auxReplacementRowScaledInt/ Lemma 4.6 row-$\ell_1$ bridges, and compositionalfun_propsynthesis withfail_if_successencoding-discipline guard.[OpenAI2026ETH],Fin-indexed specification bridges, API reuse acrossComplexity/Foundations/Data/, and concrete nonvacuity coverage, followed by clean 6-gatescripts/check.shand Python hygiene/tidy/changed-files/parallel-defs/abstracts/PR-names validation at0dd972f3eb26262847b2c3b86e40cb4bac9b3277(based onorigin/main2bb22407633c).Headline abstracts
Complexity.Computability.PolyTime.LinearAlgebra.ExchangeReplacement) toward Port OpenAI's ETH refutation (subexponential #k-SAT) natively into complexitylib #1226 and modifies no existing declaration or statement inabstracts/catalogue.json. Verified withpython3 -B scripts/build_abstracts.py --check.abstracts/catalogue.jsonentry changed).AI assistance
AI-assisted (Gemini) under human direction (
@antonkov); all Lean proofs and concrete test instances were mechanically checked by Lean 4.