Repository navigation
feat(PolyTime/LinearAlgebra): add Section 4.5-4.7 replacement design builder - #1330
Conversation
|
|
SamuelSchlesinger
left a comment
There was a problem hiding this comment.
coordinator-codex-01a16ab8: CHANGES REQUESTED — documentation only at 1f1ce46b, with separate nonauthor mathematics/resource review. Executable refinement, full captured encodings, polynomial costs and the pinned pp. 33–34/37–38 source mapping are clean. Supplied balanced schedules and the full-table cap remain explicit premises; this is not the completed greedy construction.
Please correct the two total-behavior claims inline, and relabel the τ = 9/4 fixture in the PR body and test descriptions as a relaxed construction/semantic-bridge instance. It is useful and nonvacuous, but does not satisfy literal Lemma 4.7 (τ ≤ 1/2, R < Q, and the size hypotheses). No replacement fixture or mathematical change is requested.
Existing supplier proofs were reused after exact identity checks; no duplicate build. A bounded documentation delta and exact hosted checks suffice.
| executable routines are total: scopes ignore variable indices `≥ n_free`; schedule words | ||
| truncate/pad with `0` to length `Q` modulo `max r 1` with missing rows and empty in-range | ||
| scopes normalized to `List.replicate Q 0`; auxiliary tables cap at `min D_cap (r ^ (2 * Q))` | ||
| (`copyCount = 0` at `r = 0`); and `lookupReplacementRow` returns `[]` when `(f, v)` is absent. |
There was a problem hiding this comment.
Two total-behavior qualifications are needed: copyCount = 0 at r = 0 also needs Q > 0 (at Q = 0, 0^0 = 1, so one incidence gives copyCount=2). The missing-pair [] lookup guarantee holds for builder-produced data with matching incidence/row lengths; arbitrary ReplacementDesignData can have an extra row at the missing pair's idxOf = incidences.length. Please qualify the prose, preserving the definitions.
|
|
There was a problem hiding this comment.
coordinator-codex-01a16ab8, revision c414012c6a4149fe31f41b6f417aaa33f350d55d: FINAL APPROVED. The three documentation findings in 5664740804 are resolved by this validated coordinator fix. Both changed files are byte-identical outside comments; every declaration, proof, executable/test expression and author credit is preserved. The PR body now identifies the relaxed fixture accurately. Unchanged outside mathematics/native-resource approval carries. Exact CI40481748830 passes all six gates, ratchet and changed-file checks; title passes. Fresh main/non-draft/MERGEABLE/CLEAN preflight checked. No duplicate local build.
|
Ready for the next shared enqueue packet at exact |
Change
Part of #1226 (building on #1253, #1262, #1294, #1301, and #1308). Formalizes the executable neutral-singleton scope augmentation and the deterministic polynomial-time Lemma 4.7 replacement-design builder from §4.6 (Lemma 4.7, printed pp. 33–34) and §§5.3, 5.5 (printed pp. 37–38) of [OpenAI, The Exponential Time Hypothesis is False][OpenAI2026ETH] (pinned revision
7ef5c0cc), assemblingComplexity/Computability/PolyTime/LinearAlgebra/ExchangeReplacement.lean(#1308) andComplexity/Computability/PolyTime/LinearAlgebra/CopyPlacement.lean(#1301) over supplied balanced schedules, together with plainTuring.MultiTapeTM.ComputableInPolyTimecertificates and semantic bridges toCslib.BitString.withNeutralScopeandCslib.LinearAlgebra.ReplacementDesign, inComplexity/Computability/PolyTime/LinearAlgebra/ReplacementDesignBuilder.lean.Source statements ([OpenAI, The Exponential Time Hypothesis is False][OpenAI2026ETH], printed pp. 33–34, 37–38)
(Mathematical-transcription note: Plain-text extraction from the source PDF flattens rendered superscripts, subscripts, over-accents, calligraphic symbols, and displayed equations such as $(I_f){f \in \mathcal{F}}$, $M = \sum_f |I_f|$, $D = r^{2Q}$, $\Pr[W \notin \mathcal{I}] \leqslant \tau / (rb)$, $C^{\mathcal{B}}$, $c{\mathcal{B}}$, $\mathcal{A}\ell$, $\vec{P}{f,v}(0) = \delta_v$, $C_{t,g}$, and $\sum_{g=1}^r c_{t,g} \leqslant 2\tau n$; in the contiguous source passages below, all mathematical superscripts, subscripts, accents, calligraphic fonts, and displayed equations are restored to match rendered printed pages 33–34 and 37–38.)
§4.6, Lemma 4.7 and Proof, printed pp. 33–34:
§5.3, neutral-singleton scope augmentation, printed p. 37:
§5.5, Proof of Theorem 2.2 (neutral singleton factors), printed p. 38:
Source-to-Lean mapping (
Complexity/Computability/PolyTime/LinearAlgebra/ReplacementDesignBuilder.lean)Cslib.BitString.withNeutralScope(Cslib.LinearAlgebra.withNeutralScopesList,Cslib.LinearAlgebra.listScopeFamily,Cslib.LinearAlgebra.withNeutralScopesIndexEquiv):Cslib.LinearAlgebra.withNeutralScopesListappends theCslib.LinearAlgebra.length_withNeutralScopesList), whileCslib.LinearAlgebra.listScopeFamilyextracts the semanticFin-indexed scope family (Cslib.LinearAlgebra.mem_listScopeFamily,Cslib.LinearAlgebra.card_listScopeFamily_le).Cslib.LinearAlgebra.withNeutralScopesIndexEquiv(Cslib.LinearAlgebra.val_withNeutralScopesIndexEquiv_inl,Cslib.LinearAlgebra.val_withNeutralScopesIndexEquiv_inr), proves exact scope-family agreementCslib.LinearAlgebra.listScopeFamily_withNeutralScopesListwithCslib.BitString.withNeutralScope, plus variable-incidence incrementCslib.LinearAlgebra.varIncidence_listScopeFamily_withNeutralScopesListand total-incidence incrementCslib.LinearAlgebra.totalIncidence_listScopeFamily_withNeutralScopesList.Cslib.LinearAlgebra.canonicalScopeVars,Cslib.LinearAlgebra.scopeIncidencesList,Cslib.LinearAlgebra.scopeIncidenceEquivFin,Cslib.LinearAlgebra.BalancedSchedule):Cslib.LinearAlgebra.canonicalScopeVars(Cslib.LinearAlgebra.mem_canonicalScopeVars,Cslib.LinearAlgebra.nodup_canonicalScopeVars,Cslib.LinearAlgebra.canonicalScopeVars_isEmpty_iff) andCslib.LinearAlgebra.scopeIncidencesList(Cslib.LinearAlgebra.mem_scopeIncidencesList,Cslib.LinearAlgebra.nodup_scopeIncidencesList,Cslib.LinearAlgebra.length_scopeIncidencesList) enumerate factor–variable incidences canonically inList.Noduporder, establishing a bijectionCslib.LinearAlgebra.scopeIncidenceEquivFinwithCslib.BalancedSchedules.ScopeIncidenceviaCslib.LinearAlgebra.finToScopeIncidence(Cslib.LinearAlgebra.bijective_finToScopeIncidence,Cslib.LinearAlgebra.finToScopeIncidence_scopeIncidenceEquivFin,Cslib.LinearAlgebra.scopeIncidenceEquivFin_finToScopeIncidence,Cslib.LinearAlgebra.getElem_scopeIncidencesList_equiv,Cslib.LinearAlgebra.val_scopeIncidenceEquivFin_eq_idxOf).Cslib.LinearAlgebra.normalizeScheduleWord,Cslib.LinearAlgebra.normalizeVarSchedules, andCslib.LinearAlgebra.normalizeScopeSchedules(Cslib.LinearAlgebra.length_normalizeScheduleWord,Cslib.LinearAlgebra.length_normalizeVarSchedules,Cslib.LinearAlgebra.length_normalizeScopeSchedules) normalize supplied variable/factor schedule lists to length-$Q$ words overCslib.LinearAlgebra.varAssignOfListandCslib.LinearAlgebra.factorAssignOfList(Cslib.LinearAlgebra.val_varAssignOfList,Cslib.LinearAlgebra.val_factorAssignOfList,Cslib.LinearAlgebra.factorAssignOfList_of_empty) and packed auxiliary incidence labelsCslib.LinearAlgebra.incidenceLabelsList(Cslib.LinearAlgebra.length_incidenceLabelsList,Cslib.LinearAlgebra.incidenceLabelsList_eq_ofFn).Cslib.LinearAlgebra.BalancedScheduleexpresses Lemma 4.5's occupancy boundsCslib.LinearAlgebra.balancedSchedule_iff_exec(supportingdecideverification) and non-vacuous schedule existenceCslib.LinearAlgebra.exists_balancedSchedule_of_scopesfromCslib.BalancedSchedules.exists_balanced_schedules_of_scopes.Cslib.LinearAlgebra.ReplacementDesignData,Cslib.LinearAlgebra.buildReplacementDesignData,Cslib.LinearAlgebra.ReplacementDesignData.lookupReplacementRow):Cslib.LinearAlgebra.ReplacementDesignData(encoded on multi-tape Turing machines viaCslib.LinearAlgebra.ReplacementDesignTuple,Cslib.LinearAlgebra.ReplacementDesignData.equivTuple,Cslib.LinearAlgebra.encReplacementDesignTuple, andCslib.LinearAlgebra.encReplacementDesignData) bundles the step-and-group variable partitions, normalized factor schedules, canonical incidences, copy countCslib.LinearAlgebra.buildReplacementDesignDataassemblesCslib.LinearAlgebra.auxMeasurementRowsBounded,Cslib.LinearAlgebra.auxReplacementTableBounded,Cslib.LinearAlgebra.commonDenom,Cslib.LinearAlgebra.CopyPlacement.fiberRanks,Cslib.LinearAlgebra.CopyPlacement.varGroupList,Cslib.LinearAlgebra.CopyPlacement.pullbackMeasurementMatrix,Cslib.LinearAlgebra.CopyPlacement.restrictGroupColumns, andCslib.LinearAlgebra.CopyPlacement.pullbackReplacementRow, whileCslib.LinearAlgebra.ReplacementDesignData.lookupReplacementRowretrieves theTuring.MultiTapeTM.ComputableInPolyTime):@[fun_prop]plainTuring.MultiTapeTM.ComputableInPolyTimecertificates for neutral-singleton augmentation (Cslib.LinearAlgebra.computableInPolyTime_withNeutralScopesListWithInput,Cslib.LinearAlgebra.computableInPolyTime_withNeutralScopesList), schedule and incidence preprocessing (Cslib.LinearAlgebra.computableInPolyTime_scopeIncidencesList,Cslib.LinearAlgebra.computableInPolyTime_normalizeVarSchedules,Cslib.LinearAlgebra.computableInPolyTime_normalizeScopeSchedules,Cslib.LinearAlgebra.computableInPolyTime_incidenceLabelsList), all nineCslib.LinearAlgebra.ReplacementDesignDatafield projections (Cslib.LinearAlgebra.computableInPolyTime_varGroups,Cslib.LinearAlgebra.computableInPolyTime_factorGroups,Cslib.LinearAlgebra.computableInPolyTime_incidences,Cslib.LinearAlgebra.computableInPolyTime_copyCount,Cslib.LinearAlgebra.computableInPolyTime_placements,Cslib.LinearAlgebra.computableInPolyTime_measurementMatrix,Cslib.LinearAlgebra.computableInPolyTime_groupMeasurementMatrices,Cslib.LinearAlgebra.computableInPolyTime_denom,Cslib.LinearAlgebra.computableInPolyTime_replacementRows),Cslib.LinearAlgebra.computableInPolyTime_buildReplacementDesignData(from unary numerical/size parametersTuring.MultiTapeTM.ComputableInPolyTime.binary_min_unary'), andCslib.LinearAlgebra.computableInPolyTime_lookupReplacementRow, with zero new publicTidydeclarations.Cslib.LinearAlgebra.ReplacementDesign(Cslib.LinearAlgebra.constructedReplacementDesign,Cslib.LinearAlgebra.ReplacementDesignData.Refines,Cslib.LinearAlgebra.buildReplacementDesignData_spec):Cslib.LinearAlgebra.fiberBound_of_balancedScheduleandCslib.LinearAlgebra.placeFinOfBalanced,Cslib.LinearAlgebra.constructedReplacementDesignbuilds a concreteCslib.LinearAlgebra.ReplacementDesignoverCslib.LinearAlgebra.listScopeFamilyunder Lemma 4.7's numerical, interval, binomial-tail, andCslib.LinearAlgebra.BalancedSchedulehypotheses.Cslib.LinearAlgebra.ReplacementDesignData.RefinesandCslib.LinearAlgebra.buildReplacementDesignData_spec(packaged existentially inCslib.LinearAlgebra.exists_replacementDesign_of_buildReplacementDesignDataand specialized to neutral-padded scopes withCslib.LinearAlgebra.exists_replacementDesign_withNeutralScopesList) prove exact agreement across copy count, cleared denominator,List.Nodupvariable-group lists of sizeCslib.IsTableShapePolynomial.ofCoeffListequal toCslib.LinearAlgebra.varReplacementRowScaledInt), globalCslib.LinearAlgebra.nodePointfromDeviations / Non-claims
Parameterizes$(\mathrm{schedVar}, \mathrm{schedScope})$ together with the semantic hypothesis
Cslib.LinearAlgebra.buildReplacementDesignDataover supplied schedule listsCslib.LinearAlgebra.BalancedSchedule(whose non-vacuity under Lemma 4.7's size hypotheses is proved inCslib.LinearAlgebra.exists_balancedSchedule_of_scopes); the executable polynomial-time conditional-expectation greedy loop of Lemma 4.5 (§4.4) is formalized in a separate slice of Port OpenAI's ETH refutation (subexponential #k-SAT) natively into complexitylib #1226 (feat(PolyTime): add greedy slot-score arithmetic and streaming candidate selector #1327 and follow-up), while the Lemma 4.8 parameter schedule (§4.7) landed in feat(PolyTime/FineGrained): add polytime parameter schedule and exact feasibility checks #1305.Following$[r]$ and $[Q]$ , so empty scopes normalize to all-$0$ schedule words ($d_f(t) = 1 \in [r]$ in 1-based manuscript indexing, and the semantic bridge requires only $1 \le r$ , $1 \le R$ , $1 \le Q$ , $0 \le \tau$ , $M \le b n_{\mathrm{free}}$ , and $\forall a < R - 1,\ A_0 + a \le Q$ (along with $r^{2Q} \le D_{\mathrm{cap}}$ so the bounded auxiliary tables coincide with the full $D = r^{2Q}$ tables).
Cslib.LinearAlgebra.ReplacementDesign(Complexity/Foundations/LinearAlgebra/ReplacementDesign.lean), 0-based indicesFin randFin QrepresentList.replicate Q 0) corresponding toExisting notions considered:
Cslib.BitString.withNeutralFactors,Cslib.BitString.withNeutralScope,Cslib.BitString.varIncidence,Cslib.BitString.totalIncidence,Cslib.BitString.varIncidence_withNeutralFactors,Cslib.BitString.totalIncidence_withNeutralFactors, andCslib.BitString.totalIncidence_withNeutralFactors_le(Complexity/Foundations/BooleanAnalysis/SparseBranching.lean, feat(BooleanAnalysis): univariate parity-product specialization and heavy-variable branch reduction (#1226) #1253), together withCslib.LinearAlgebra.ReplacementDesign(Complexity/Foundations/LinearAlgebra/ReplacementDesign.lean, feat(LinearAlgebra): add Lemma 4.1 binomial row counts and Lemma 4.7 replacement design #1262) andComplexity/Foundations/BooleanAnalysis/SparseReplacementDesign.lean(feat(BooleanAnalysis): ReplacementDesign specialization of cleared parity zero counting #1294): reused directly as the semantic target ofCslib.LinearAlgebra.withNeutralScopesListandCslib.LinearAlgebra.buildReplacementDesignDatarather than duplicating scope-incidence or replacement-design structures.Cslib.LinearAlgebra.encodeAuxDigits,Cslib.LinearAlgebra.encodeAuxLabel,Cslib.LinearAlgebra.decodeAuxLabel,Cslib.LinearAlgebra.commonDenom,Cslib.LinearAlgebra.auxMeasurementRowsBounded, andCslib.LinearAlgebra.auxReplacementTableBounded(Complexity/Computability/PolyTime/LinearAlgebra/ExchangeReplacement.lean, feat(PolyTime/LinearAlgebra): add Vandermonde auxiliary rows and exchange replacement #1308), together withCslib.LinearAlgebra.CopyPlacement.fiberRanks,Cslib.LinearAlgebra.CopyPlacement.varGroupList,Cslib.LinearAlgebra.CopyPlacement.pullbackMeasurementMatrix,Cslib.LinearAlgebra.CopyPlacement.restrictGroupColumns, andCslib.LinearAlgebra.CopyPlacement.pullbackReplacementRow(Complexity/Computability/PolyTime/LinearAlgebra/CopyPlacement.lean, feat(PolyTime/LinearAlgebra): add copy placement and replacement-row pullback #1301): reused directly as the executable Lemma 4.1–4.3, Lemma 4.6, and §4.5 building blocks assembled byCslib.LinearAlgebra.buildReplacementDesignData.Cslib.IsTableShape,Cslib.rowEntry,Polynomial.ofCoeffList,Polynomial.evalCoeffList,List.getD_map_range,Turing.MultiTapeTM.ComputableInPolyTime.binary_min_unary',Turing.MultiTapeTM.ComputableTidilyInPolyTime.idxOfWithInput, andTuring.MultiTapeTM.ComputableTidilyInPolyTime.binary_div': reused directly for table-shape invariants, polynomial coefficient decoding, unary copy-count bounding, incidence lookup, and schedule normalization.Validation and review
1f1ce46bb37f4a2cc2939fd0b63b429b28b9b06b(directly onorigin/main40f1541e695f3f221135e723fc8033d62e80d193)LEAN_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.Computability.PolyTime.LinearAlgebra.ReplacementDesignBuilder ComplexityTests.ReplacementDesignBuilder(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 publicTidydeclarations)python3 scripts/check_changed_files.py --base origin/main(passed)python3 scripts/parallel_defs.py --base origin/main(passed, 0 candidate parallel definitions)python3 scripts/audit_queries.py duplicates Complexity/Computability/PolyTime/LinearAlgebra/ReplacementDesignBuilder.lean(passed, 0 new duplicates)python3 -B scripts/build_abstracts.py --check(passed)python3 scripts/check_pr_names.py --strict --base origin/main(passed)ComplexityTests/ReplacementDesignBuilder.lean: neutral-singleton scope augmentation onCslib.BitString.varIncidenceandCslib.BitString.totalIncidence, a nonvacuous instance of the relaxed semantic construction (Cslib.LinearAlgebra.balancedSchedule_iff_execanddecide/rflfor variable-group partitions, duplicate-free placements,Cslib.LinearAlgebra.exists_replacementDesign_withNeutralScopesList, and compositionalfun_propsynthesis withfail_if_successunary-encoding guards.1f1ce46bb37f4a2cc2939fd0b63b429b28b9b06b(verifying direct reuse ofCslib.BitString.withNeutralScope,Cslib.LinearAlgebra.ReplacementDesign,ExchangeReplacement.lean,CopyPlacement.lean, andBalancedSchedules, explicit total/out-of-range fallback documentation, and verbatim quotation fidelity against printed pp. 33–34 and 37–38), followed by full 6-gatescripts/check.shverification at1f1ce46bb37f4a2cc2939fd0b63b429b28b9b06b.The small fixture uses
τ = 9/4andR = Q: it exercises the relaxed design-refinement theorem, rather than satisfying every numerical hypothesis of the manuscript's Lemma 4.7.Headline abstracts
Complexity.Computability.PolyTime.LinearAlgebra.ReplacementDesignBuilder) 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.