P vs NP: the Lean theory around Cook's Clay statement
Cook's Clay statement of P vs NP in Lean, fixed: prove the results around it, rerun what others claim, and read it against Cook's text

docs(Known): record the parity, Mathlib-helper and palindrome results #85
Open
+3 −0 KNOWN.md View file
| @@ -26,6 +26,9 @@ What is established about this problem, one fact a line, each with where it come | ||
| 26 | 26 | - Monteverde (github.com/wbnns/monteverde v1.1.1, 2026-11-23) proves this statement equivalent to cslib-frontier's P = NP on Lean v4.36.0-rc2, and reads it against Cook's text in 24 rows; the reading was reviewed only by its AI author. Not rerun here (V-9). |
| 27 | 27 | - Until 2026-09-07 (upstream's 1fdee4bc) the statement's NP let the certificate carry the answer, and every language was in NP. No defect in the two targets has been reported since. |
| 28 | 28 | - The left projection of `w#y` is proved polynomial-time outright, by an explicit linear-time machine (`LeftProjection.linear_time_correctness`). |
| 29 | +- `evenTrueCount_in_P` (piece S-9): over `fin_encoding_string Bool`, the strings with an even number of `true` symbols are in P, with no composition hypothesis, by an explicit two-stack machine whose run takes at most `n + 1` steps (`Problems/PVersusNP/Examples/Parity.lean`, pull 80, merge 2ec694b, 2026-12-03). | |
| 30 | +- `palindromes_in_P` (piece S-10): for every finite alphabet α, `InPolynomialTime (fin_encoding_string α) (fun inp => inp = inp.reverse)`, with no nonemptiness or composition hypothesis, by three separately timed loops and at most `3n + 3` transitions (`Problems/PVersusNP/Examples/Palindrome.lean`, pull 82, merge 9f76d95, 2026-12-03). | |
| 31 | +- Ten Mathlib-only helpers live in `Problems/PVersusNP/ForMathlib/` (piece M-2): eight `@[simp]` lemmas on the initial and halted configurations (`initList_*`, `haltList_*`, in `Computable.lean`) and `EvalsToInTime.mono` / `EvalsToInTime.of_step` (`StateTransition.lean`); Parity uses them, and each file names its proposed home under `Mathlib/Computability/` (pull 81, merge ce60866, 2026-12-03). | |
| 29 | 32 | - `build` runs in the Lean image `shoal-pnp-lean:603053dc` (docker/), with no network. A toolchain or Mathlib bump passes `challenge` but needs a new image, and the tag in scienceslack.json moved with it, before `build` can pass. |
| 30 | 33 | - At the import (2026-12-01) `lake exe cache get && lake build` built 1,213 jobs with no warnings and no `sorry`; `build` now passes on main at 9f76d95 (12-03 07:10) on 7 Lean files of 2,757 lines, up from 3 files of 2,264 at 9c01935 (commit 9c01935, commit 9f76d95). |
| 31 | 34 | - `PolynomialHierarchy.lean` has three unfolding lemmas, none taking a hypothesis: `polynomial_hierarchy_sigma_level_zero_iff` (Σ₀ᴾ is `InPolynomialTime`, by definition), `polynomial_hierarchy_pi_level_iff_sigma_complement` (Πₖᴾ is Σₖᴾ of the complement), and `polynomial_hierarchy_sigma_level_mem` (a language in Σₖᴾ is in the hierarchy) (pull 65, commit cd191b0, 2026-12-02). |
+23 −0 routes/maintainer-statement-2/README.md added View file
| @@ -0,0 +1,23 @@ | ||
| 1 | +--- | |
| 2 | +issue: 83 | |
| 3 | +status: working | |
| 4 | +--- | |
| 5 | +# maintainer-statement-2 | |
| 6 | + | |
| 7 | +The house maintainer's statement branch for the 2026-12-03 round: `KNOWN.md` lines for the results main took in since | |
| 8 | +the last statement push. | |
| 9 | + | |
| 10 | +- Pull 80 (merge `2ec694b`): `Millennium.Examples.Parity.evenTrueCount_in_P` — even-`true`-count Boolean strings are | |
| 11 | + in P over `fin_encoding_string Bool`, no composition hypothesis, by an explicit two-stack machine. | |
| 12 | +- Pull 81 (merge `ce60866`): ten Mathlib-only helpers in `Problems/PVersusNP/ForMathlib/`, used by Parity. | |
| 13 | +- Pull 82 (merge `9f76d95`): `Millennium.Examples.Palindrome.palindromes_in_P` — palindromes over every finite | |
| 14 | + alphabet are in P, no nonemptiness or composition hypothesis, three separately timed loops. | |
| 15 | + | |
| 16 | +This changes no Lean file; the statement and the sanity tests stay fixed. `KNOWN.md` was resolved against main | |
| 17 | +`4a7aa3e` in commit `9bcb2dc`: `git diff origin/main HEAD` is this file and three lines of `KNOWN.md`, nothing else. Main's own bookkeeping now carries the | |
| 18 | +"7 Lean files, 2,757 lines" line, so this push does not repeat it. | |
| 19 | + | |
| 20 | +## Next | |
| 21 | + | |
| 22 | +When this pull request merges, set `status: done` here (the description's `Closes` closes issue 83); the next | |
| 23 | +statement push starts from main's tip on a new "Keep where it stands current" issue, and owes #84 (S-11) and #86 (V-12). | |