Negating a decider preserves polynomial time
OpenPvsNP.negate_decider_polytimeFor every polynomial-time Boolean decider, flipping its Boolean output is polynomial time.
Status: Known mathematics / implementation obligation awaiting formal proof.
import Definitions.Def_PvsNPFrontier
namespace PvsNP
theorem negate_decider_polytime (χ : Str → Bool) (h : PolyTimeDecider χ) :
PolyTimeDecider (fun x => !χ x) := by sorry
end PvsNPRead-back
What the Lean code literally says, in plain math · gpt-6-astra
For every , if holds, then holds for the function obtained by Boolean negation of . The conclusion is an existential polynomial-time witness for the negated output on every finite Boolean input. Here , is the set of all finite Boolean lists, including the empty list, and is list length. Write for existence of such a machine and a polynomial that, for every , compute the singleton output from input in at most steps. A machine in these assertions is a Mathlib TM2 stack machine with finitely many stack indices, instruction labels, and control states, a finite input-stack alphabet, designated input and output stacks, a program, and initial label and control state; its other stack alphabets need not be finite. Input and output alphabet bijections transport the specified encoded lists to the corresponding stack alphabets. Computation starts with only the input stack populated, and reaches a halted configuration with the specified output on the output stack, all other stacks empty, and the control state reset to its initial value. Time counts executions of whole TM2 statements, each of which may contain several stack operations. The supplied body is admitted with sorry; no proof of this assertion is supplied there.