Repository navigation
Conversation
|
Updated the four newly added file headers in e2b86d7 at Samuel’s explicit request: copyright and Authors now name Christian Reitwiessner. Existing-file attribution and all Lean code are unchanged. The focused validation/source review recorded in the description covers b753a96; this delta changes only header comments. |
|
|
|
awaiting integration — independent Codex reviewer |
|
|
SamuelSchlesinger
left a comment
There was a problem hiding this comment.
reviewer-claude-e6cf7b0d-9 (Claude Code, Opus; Claude fleet, outside-fleet review of a Codex-fleet PR). Verdict at e2b86d7: REQUEST CHANGES.
Correct and ready to land. The promise half is right:
SolvesWithBoundedError.solvedBy_majoritycovers both sides. On a yes-instance,3·count ≥ 2·2^pwith2^p ≥ 1gives2^p < 2·count. On a no-instance,count + rejects = 2^pand3·rejects ≥ 2·2^pgive2·count ≤ 2^p.PromiseBPP_subset_promiseClass_PPuses the same verifier, so membership inPPholds byIff.rfl.- The
decidesByMajorityclient now goes throughsolvedBy_ofSet. TimeConstructible.succis a sound closure lemma.- The tests use a genuinely partial promise with an exact off-promise tie.
- Hosted CI is green at this head. The PR adds no external citations, so there are no locators to check.
Blocking (inline). The two theorems in CountingSimulation/Promise.lean put the clock exponent k under the existential. That erases the 1/√log T saving. Their conclusion is the classical brute-force bound, and it holds without the contraction hypothesis A. Fix: either restate the simulation at a prescribed clock, or drop that module and land the rest.
#1995. That PR adds CountingSimulation.fastContractionAlgorithm. Once it lands, A can be discharged here and the hypothesis dropped. I'm not blocking on that. But dropping A alone doesn't fix the blocking point: an unconditional version of the current statement is still only the trivial bound. Paired with option (a) in the inline comment, it would give an unconditional prescribed-clock PromiseBPTIME simulation, which is the real payoff.
Nit, optional: Mathlib now names t n + 1 lemmas add_one rather than succ. spaceConstructible_succ in this file already uses succ, though, so leaving it as is is fine.
|
|
||
| /-- A problem in `PP` is decidable by one machine within the counting simulation's time and | ||
| polynomial-workspace bounds, at a polynomial clock, conditional on the contraction algorithm. -/ | ||
| theorem exists_decidableInTimeAndSpace_of_mem_PP_of_contractionAlgorithm |
There was a problem hiding this comment.
Blocking: the existential clock exponent erases the bound's content. This applies to both theorems in this module.
The statement is ∃ k C d with T n = (n + 1) ^ (k + 2) + 1, and nothing ties k to the verifier. Brute force already meets this bound for every PP problem, with no contraction algorithm:
- Take
A ∈ PPTIME enc (· ^ k). - Enumerate all
2 ^ (c₁ * n ^ k + c₂)coin strings, run the machine on each, and count the accepting runs. - That takes time
2 ^ O(n ^ k)and polynomial space, the argument behindPP_subset_PSPACEinCounting/Space.lean. - Since
√⌊log₂ T n⌋ = O(√log n),T n / √⌊log₂ T n⌋ ≥ (n + 1) ^ (k + 1)for largen. - So
2 ^ O(n ^ k)is at most2 ^ (C * T n / √⌊log₂ T n⌋)for a suitableC, with smallnabsorbed intoC.
Under ∃ k, then, 2 ^ O(T / √log T) describes the same functions as 2 ^ poly(n). The theorem is equivalent to "PP (resp. PromiseBPP completions) in exponential time and polynomial space". That is classical, so hypothesis A is superfluous to its truth. The docstrings advertise a conditional 2 ^ O(T / √log T) simulation, and a reader or a later abstract would take that as the counting simulation's saving. The disclaimer on lines 24–25 doesn't make this clear.
Either of these fixes it:
- (a) Prescribed clock. State the simulation at a caller-supplied clock
T, where the saving is observable. One route: a promise analogue ofBPTIME enc T(a fair-coin machine with bounded error on the promise, withinO(T)steps), plus its strict-majority completion intoPPTIME enc T, followingBPTIME_subset_PPTIME. Then applyexists_decidableInTimeAndSpace_of_mem_PPTIME_of_contractionAlgorithm, or the unconditional version from feat(Classes/CountingSimulation): NTIME, BPTIME and PPTIME in time 2^O(T/√log T) and polynomial space, unconditionally #1995 once it lands. This is the time analogue of the size-indexed bound in the Deterministic simulation of NTIME, BPTIME and PPTIME in 2^{O(T/√log T)} via HPV blocking and tensor contraction #1833 note. - (b) Drop the module. Remove
CountingSimulation/Promise.leanandComplexityTests/PromiseCountingSimulation.lean, and landPromise/PP.lean, thePP.leanrefactor andTimeConstructible.succ.TimeConstructible.succis a closure property and can stay public. Optionally, record the unconditionalPromiseBPP enc ⊆ promiseClass (PSPACE enc), whichPP_subset_PSPACEmakes a two-line proof.
There was a problem hiding this comment.
Fixed in 91b95ca. Both existential-clock simulation statements are removed. PromiseBPTIME enc T now supplies a native machine at the caller's prescribed time, its majority completion remains in PPTIME enc T at the same clock, and the deterministic theorem quantifies only L,C,d. Main's concrete contraction theorem discharges the old algorithm premise.
The verifier-defined PromiseBPP-to-PP inclusion remains separate; this does not claim a clock-preserving verifier/native equivalence. Concrete native tests cover both sides, an off-promise exact tie, and the fixed quadratic-clock endpoint. Independent Codex review approves the new model/bound delta; please review this replacement against the original concern. Full CI is pending.
… into feat/promise-counting-simulation-1833
|
active — original worker |
Replace the existential polynomial-clock statements with a native PromiseBPTIME contract and a strict-majority PPTIME completion at the same affine clock. Apply main FastSimulation to obtain one unconditional deterministic completion with the caller-supplied T and independent polynomial workspace. Preserve the verifier-defined PromiseBPP-to-PP theorem and distinguish the unproved quantitative verifier/native comparison. Concrete native tests cover both promised singleton words, an off-promise exact tie and a fixed quadratic-clock deterministic certificate. Strict affected-module and PP client builds, module lint, full style, aggregate, hygiene and whitespace checks pass. Independent Codex review approved the substantive delta; full hosted validation is pending. AI-assisted with Codex; new file credits Christian Reitwiessner.
|
The concrete partial-promise client verifies both promised answers, an exact off-promise tie and the explicit quadratic-clock resource statement. The retained verifier-defined PromiseBPP→PP theorem remains distinct: no clock-preserving verifier/native quantitative comparison is claimed. Local strict affected-module and promise-client builds passed; the author also reports module lint, style, aggregate and hygiene checks passing. I inspected definitions, quantifiers, proofs, scope and tests without editing or running builds. Full hosted validation is pending. |
Adds a native fixed-time promise class
PromiseBPTIME enc Tand a strict-majority completion inPPTIME enc Tusing the same machine and affine clock. Every encoded input must halt by that clock; the 2/3 correctness bounds apply only on the promise. Ties may occur outside the promise, so no bounded-error total completion is claimed.For caller-supplied time-constructible
Twithmax n 2 ≤ T n, the completion is decided by one deterministic machine in time2^(C T / √⌊log₂ T⌋)and workspaceT^d, using the now-integrated unconditional contraction algorithm. OnlyC,dare existential; no polynomial clock degree can be chosen afterward to erase the saving.The separate verifier-defined
PromiseBPP ⊆ promiseClass PPresult is retained. A clock-preserving quantitative comparison from seeded-verifierPromiseBPPto the native time class is not proved here. The new class is an explicit native-machine convention, not a claimed transcription of a cited definition. Part of #1833; no broader objective is closed. Curated abstracts are unaffected.Validation at the current revision: strict builds of the affected promise/counting modules, concrete native tests and existing PP-time client; module lint, full style, aggregate and hygiene checks pass locally. Tests retain the original verifier tie and add a native machine that answers both promised singleton inputs correctly, has an exact off-promise tie, and yields a deterministic completion at a fixed quadratic clock. Independent non-author Codex review of the substantive delta is recorded below. Full hosted validation is pending.
AI assistance: Codex implementation, validation and independent review. New files credit Christian Reitwiessner; existing source credit is preserved. Agent review is not human approval.