Polynomial time is preserved by finite changes of a binary language
ProvedPvsNP.mem_P_of_agree_above_lengthcomplexity-theoryp-vs-nppolynomial-time
Let and be binary languages. Suppose has a polynomial-time decider and, for some cutoff , membership in agrees with membership in on every word of length at least . Then also has a polynomial-time decider.
The finitely many shorter words can be handled by a finite lookup table. This is the finite-change property used when an even stage of Ladner's construction lasts forever. Applied to the empty language, it also places every finite language in polynomial time.
Preamble
import Definitions.Def_PvsNP
Formal statement
theorem PvsNP.mem_P_of_agree_above_length (A B : Language Bool) (N : ℕ)
(hA : A ∈ PvsNP.P) (h : ∀ w : PvsNP.Str, N ≤ w.length → (w ∈ B ↔ w ∈ A)) :
B ∈ PvsNP.P := by sorrySource
R. E. Ladner, On the Structure of Polynomial Time Reducibility, J. ACM 22 (1975), 155–171, https://doi.org/10.1145/321864.321877. For the length-gated SAT construction see Two Proofs of Ladner’s Theorem, pp. 1–2, section “Proof by blowing holes in SAT”, https://web.cs.ucdavis.edu/~rogaway/classes/220/winter06/ladner-theorem.pdf.