Documentation

CslibFrontier.Computability.Complexity.Classes.MIP.Arithmetization

Arithmetization of NEXP via succinct tableau decoding #

The tableau argument in Babai, Fortnow and Lund, §4.2, Proposition 4.2 reduces a nondeterministic exponential-time computation to a formula tested with three assignment oracle calls. Here a circuit returns the three signed variable addresses of an indexed tableau clause. For the circuit indexing local clauses, see the proof sketch of Theorem 6.1 in Williams, p. 20. The construction provides the following parts of the two-prover simulation:

  1. Unconditional NEXP to succinct tableau CNF reduction (exists_succinctCNF_of_mem_NEXP): every language A ∈ NEXP enc reduces to satisfiability of the uniform bit-field tableau CNF Cslib.Circuits.Boolean.Tableau.succinctCNF tm (frame (enc a)) (n a) (T a) for a fixed deterministic multi-tape machine tm and binary polynomial-time functions n, T : α → ℕ whose bit widths colBits (T a) and timeBits (T a) are polynomially bounded in (enc a).length.
  2. Uniform polynomial-time decoder construction (computableInPolyTime_decoderCode, exists_succinctDecoder_of_mem_NEXP): Tableau.Decoder.decoderCode tm is computable in polynomial time from (x, n, T) under (encBits, encNat, encNat)—in time polynomial in x.length + log n + log T even when n and T are exponential.
  3. Algebraic gate-and-clause arithmetization and sumcheck reduction: given a De Morgan decoder c : Circuit signature Q (3 * (L + 1)) and an assignment polynomial A : MvPolynomial (Fin L) F, the polynomial tableauConstraintPoly c A r on Q + c.size variables checks gate consistency (gateTracePoly R c), 3-literal clause violation (clauseUnsatPoly c A), and a random multilinear equality weight (eqCubePoly r). It has individual degree at most 1 + 3 * c.size + 3 * (L + 1), vanishes identically on the cube iff A induces a satisfying assignment of SuccinctVerifier.toCNF c (or succinctCNF), and on unsatisfiable formulas induces a nonzero multilinear polynomial detected by Schwartz–Zippel and Cslib.Interactive.Sumcheck.proof.

The proof-oracle verifier in Cslib.Complexity.NEXP_subset_PCPPoly applies this arithmetization to the uniformly constructed succinct decoder for every NEXP language.

Main definitions #

Main results #

References #

Reduction from NEXP to succinct tableau CNF #

Unconditional NEXP to succinct tableau CNF reduction: every A ∈ NEXP enc is decided by satisfiability of Tableau.succinctCNF tm (frame (enc a)) (n a) (T a) for one deterministic multi-tape machine tm and binary polynomial-time bounds n, T : α → ℕ whose bit-widths are polynomially bounded in (enc a).length. This is the tableau step from the proof of Babai, Fortnow and Lund, §4.2, Proposition 4.2.

Uniform polynomial-time construction of the succinct decoder #

Uniform polynomial-time construction of the succinct tableau decoder: for every multi-tape machine tm, Tableau.Decoder.decoderCode tm (x, n, T) is computable in polynomial time in x.length + (encNat n).length + (encNat T).length (O(|x| + log n + log T)), without expanding exponentially large runs or CNFs Williams, Theorem 6.1.

theorem Cslib.Complexity.MIP.exists_succinctDecoder_of_mem_NEXP {α : Type} {enc : α ↪ List Bool} {A : Set α} (hA : A ∈ NEXP enc) :
∃ (k : ℕ) (State : Type) (x : Fintype State) (x_1 : DecidableEq State) (tm : Turing.MultiTapeTM k Bool State) (n : α → ℕ) (T : α → ℕ), Turing.MultiTapeTM.ComputableInPolyTime (fun (a : α) => Circuits.Boolean.Tableau.Decoder.decoderCode tm (Turing.MultiTapeTM.frame (enc a), n a, T a)) enc Circuits.Boolean.encCode ∧ Turing.MultiTapeTM.ComputableInPolyTime (fun (a : α) => Circuits.Boolean.Tableau.clauseBits k State (T a)) enc Turing.MultiTapeTM.encUnary ∧ Turing.MultiTapeTM.ComputableInPolyTime (fun (a : α) => Circuits.Boolean.Tableau.labelBits k State (T a)) enc Turing.MultiTapeTM.encUnary ∧ ∀ (a : α), (Turing.MultiTapeTM.frame (enc a)).length ≤ n a ∧ n a < 2 * T a ∧ (a ∈ A ↔ (Circuits.Boolean.Tableau.succinctCNF tm (Turing.MultiTapeTM.frame (enc a)) (n a) (T a)).Satisfiable) ∧ ∃ (c : Circuits.Circuit Circuits.Boolean.signature (Circuits.Boolean.Tableau.clauseBits k State (T a)) (3 * (Circuits.Boolean.Tableau.labelBits k State (T a) + 1))), c.code = Circuits.Boolean.Tableau.Decoder.decoderCode tm (Turing.MultiTapeTM.frame (enc a), n a, T a) ∧ c.size ≤ Circuits.Boolean.Tableau.Decoder.sizeConst tm * (Circuits.Boolean.Tableau.colBits (T a) + Circuits.Boolean.Tableau.timeBits (T a) + (Turing.MultiTapeTM.frame (enc a)).length + 1) ∧ ∀ idx < 2 ^ Circuits.Boolean.Tableau.clauseBits k State (T a), List.ofFn (c.eval Circuits.Boolean.interpretation fun (i : Fin (Circuits.Boolean.Tableau.clauseBits k State (T a))) => idx.testBit ↑i) = List.flatMap (Circuits.Boolean.Tableau.Decoder.litBits (Circuits.Boolean.Tableau.labelBits k State (T a))) (Circuits.Boolean.Tableau.clauseAt tm (Turing.MultiTapeTM.frame (enc a)) (n a) (T a) idx)

Every native NEXP language has a polynomial-time succinct decoder. The gate code and both unary address widths are computable in polynomial time. The frame length and clock bounds let the caller relate the decoded clauses to the satisfiable tableau of the fixed machine.

Algebraic arithmetization of decoded succinct 3CNF formulas #

Field-valued semantics of a De Morgan gate operation Op on two ring elements: .const v ↦ bitVal R v, .not a _ ↦ 1 - a, .and a b ↦ a * b, .or a b ↦ a + b - a * b.

@[simp]
theorem Cslib.Complexity.MIP.map_opEvalField {R : Type u_1} {S : Type u_2} [CommRing R] [CommRing S] (φ : R →+* S) (op : Circuits.Boolean.Op) (a b : R) :
φ (opEvalField op a b) = opEvalField op (φ a) (φ b)
def Cslib.Complexity.MIP.eqBit {R : Type u_1} [CommRing R] (u v : R) :
R

Multilinear bit-equality indicator u * v + (1 - u) * (1 - v): equals 1 if u = v and 0 if u ≠ v for u, v ∈ {0, 1}.

@[simp]
theorem Cslib.Complexity.MIP.map_eqBit {R : Type u_1} {S : Type u_2} [CommRing R] [CommRing S] (φ : R →+* S) (u v : R) :
φ (eqBit u v) = eqBit (φ u) (φ v)
noncomputable def Cslib.Complexity.MIP.wireX {R : Type u_1} [CommRing R] (N w : ℕ) :

Variable X ⟨w, _⟩ when w < N, and 0 otherwise.

Polynomial checking that every gate j < c.size of a De Morgan circuit c satisfies its algebraic gate equation on wires (idx, w) ∈ F^{Q + c.size}.

noncomputable def Cslib.Complexity.MIP.clauseUnsatPoly {Q L : ℕ} {R : Type u_1} [CommRing R] (c : Circuits.Circuit Circuits.Boolean.signature Q (3 * (L + 1))) (A : MvPolynomial (Fin L) R) :

Polynomial checking that all three decoded literals output by c are falsified under the assignment polynomial A : MvPolynomial (Fin L) R.

noncomputable def Cslib.Complexity.MIP.eqCubePoly {N : ℕ} {R : Type u_1} [CommRing R] (r : Fin N → R) :

Multilinear equality indicator ∏ᵢ (rᵢ Xᵢ + (1 - rᵢ)(1 - Xᵢ)): on Boolean y, evaluates to eval r (indicatorPoly y).

noncomputable def Cslib.Complexity.MIP.tableauConstraintPoly {Q L : ℕ} {R : Type u_1} [CommRing R] (c : Circuits.Circuit Circuits.Boolean.signature Q (3 * (L + 1))) (A : MvPolynomial (Fin L) R) (r : Fin (Q + c.size) → R) :

Combined arithmetized constraint polynomial eqCubePoly r * gateTracePoly c * clauseUnsatPoly c A for succinct 3CNF verification over R.

Degree bounds #

theorem Cslib.Complexity.MIP.eqCubePoly_degreeOf_le {N : ℕ} {R : Type u_1} [CommRing R] (r : Fin N → R) (v : Fin N) :

Every variable in eqCubePoly r has degree at most 1.

If A ∈ restrictDegree (Fin L) R 1, then (clauseUnsatPoly c A).totalDegree ≤ 3 * (L + 1).

theorem Cslib.Complexity.MIP.tableauConstraintPoly_degreeOf_le {Q L : ℕ} {R : Type u_1} [CommRing R] (c : Circuits.Circuit Circuits.Boolean.signature Q (3 * (L + 1))) {A : MvPolynomial (Fin L) R} (hA : A ∈ MvPolynomial.restrictDegree (Fin L) R 1) (r : Fin (Q + c.size) → R) (v : Fin (Q + c.size)) :

Individual degree bound on tableauConstraintPoly c A r: every variable has degree at most 1 + 3 * c.size + 3 * (L + 1), polynomial in instance length for succinct NEXP decoders.

Boolean soundness and completeness #

On a Boolean input (idx, w) ∈ {0, 1}^{Q + c.size}, gateTracePoly R c equals 1 if w is the exact wire-by-wire evaluation trace of c on idx, and 0 otherwise.

At the honest gate trace w of circuit c on input idx, clauseUnsatPoly c A evaluates to the product of the three literal violation weights under A.

Exact Boolean soundness and completeness of gateTracePoly * clauseUnsatPoly over any field F against SuccinctVerifier.toCNF c: a satisfying assignment exists iff some multilinear polynomial A ∈ restrictDegree (Fin L) F 1 makes the product vanish at every Boolean point of {0, 1}^{Q + c.size}.

A circuit decoding clauseAt tm x n T produces a SuccinctVerifier.toCNF c equisatisfiable with Tableau.succinctCNF tm x n T.

Exact algebraic equivalence for Tableau.succinctCNF: succinctCNF tm x n T is satisfiable iff some multilinear polynomial A ∈ restrictDegree (Fin (labelBits k State T)) F 1 makes gateTracePoly F c * clauseUnsatPoly c A vanish on the Boolean cube {0, 1}^{Q + c.size}.

Sumcheck and Schwartz–Zippel soundness #

For every verifier challenge r : Fin (Q + c.size) → F, the sumcheck sum of tableauConstraintPoly c A r over {0, 1}^{Q + c.size} equals the multilinear extension of gateTracePoly F c * clauseUnsatPoly c A evaluated at r.

Completeness of Sumcheck for the arithmetized succinct 3CNF: when SuccinctVerifier.toCNF c is satisfiable, some multilinear A makes Sumcheck.rel (tableauConstraintPoly c A r) 0 ⟨Fin.elim0, 0⟩ () hold for every challenge r, and Sumcheck.proof d (tableauConstraintPoly c A r) is accepted with probability 1 whenever 1 + 3 * c.size + 3 * (L + 1) ≤ d.

Schwartz–Zippel + Sumcheck soundness: when SuccinctVerifier.toCNF c is unsatisfiable, for EVERY assignment polynomial A : MvPolynomial (Fin L) F:

  1. at a uniformly random challenge r : Fin (Q + c.size) → F, the arithmetized Sumcheck sum vanishes with probability at most (Q + c.size) / |F|; and
  2. for every r where the sum does not vanish, Sumcheck.proof d (tableauConstraintPoly c A r) is ((Q + c.size) * (d / |F|))-sound against every interactive prover.

Uniform polynomial-time verifier evaluation over ZMod p #

Modular multiplication (x * y) % p, totalized to 0 at p = 0.

@[simp]

At p = 0, mulMod evaluates to 0.

Natural-number mod-p evaluation of a De Morgan gate operation, matching opEvalField in ZMod p and bounded by p even at p = 0.

Multilinear bit-equality mod p, matching eqBit in ZMod p.

Multilinear literal-violation factor s * (1 - v) + (1 - s) * v mod p.

@[simp]
theorem Cslib.Complexity.MIP.natCast_opEvalMod {p : ℕ} (hp : 0 < p) (op : Circuits.Boolean.Op) (a b : ℕ) :
↑(opEvalMod p op a b) = opEvalField op ↑a ↑b
@[simp]
theorem Cslib.Complexity.MIP.natCast_eqBitMod {p : ℕ} (hp : 0 < p) (u v : ℕ) :
↑(eqBitMod p u v) = eqBit ↑u ↑v
@[simp]
theorem Cslib.Complexity.MIP.natCast_evalLitUnsatMod {p : ℕ} (hp : 0 < p) (s v : ℕ) :
↑(evalLitUnsatMod p s v) = ↑s * (1 - ↑v) + (1 - ↑s) * ↑v

Evaluate the product gateTracePoly mod p on wire residue vector z : List ℕ.

Evaluate the multilinear equality indicator eqCubePoly r at z mod p.

def Cslib.Complexity.MIP.evalClauseUnsatMod (p : ℕ) (z signWires litVals : List ℕ) :

Evaluate the clause falsification product clauseUnsatPoly mod p given the wire residue vector z, the three sign wire indices signWires, and the oracle values litVals.

def Cslib.Complexity.MIP.evalConstraintMod (p Q : ℕ) (gates : List (Circuits.Boolean.Op × List ℕ)) (rVec z signWires litVals : List ℕ) :

Evaluate the full verifier constraint tableauConstraintPoly c A r at z mod p given circuit gates gates, challenge rVec, point z, sign output wires signWires, and three oracle evaluations litVals.

theorem Cslib.Complexity.MIP.natCast_evalGateTraceMod {p Q M : ℕ} (hp : 0 < p) (c : Circuits.Circuit Circuits.Boolean.signature Q M) (z : Fin (Q + c.size) → ℕ) :
↑(evalGateTraceMod p Q (List.ofFn z) c.code.1) = (MvPolynomial.eval fun (i : Fin (Q + c.size)) => ↑(z i)) (gateTracePoly (ZMod p) c)

evalGateTraceMod agrees with evaluating gateTracePoly (ZMod p) c in ZMod p.

theorem Cslib.Complexity.MIP.natCast_eqCubeMod {p N : ℕ} (hp : 0 < p) (r z : Fin N → ℕ) :
↑(eqCubeMod p (List.ofFn r) (List.ofFn z)) = (MvPolynomial.eval fun (i : Fin N) => ↑(z i)) (eqCubePoly fun (i : Fin N) => ↑(r i))

eqCubeMod agrees with evaluating eqCubePoly r in ZMod p.

theorem Cslib.Complexity.MIP.natCast_evalClauseUnsatMod {p Q L : ℕ} (hp : 0 < p) (c : Circuits.Circuit Circuits.Boolean.signature Q (3 * (L + 1))) (A : MvPolynomial (Fin L) (ZMod p)) (z : Fin (Q + c.size) → ℕ) (val : Fin 3 → ℕ) (hval : ∀ (r : Fin 3), ↑(val r) = (MvPolynomial.eval fun (i : Fin L) => ↑(z ⟨(c.outputs (Circuits.Boolean.SuccinctVerifier.addressWire L r i)).toNat, ⋯⟩)) A) :

evalClauseUnsatMod agrees with evaluating clauseUnsatPoly c A in ZMod p when supplied with the three oracle evaluations val j = eval (addr_j(z)) A.

theorem Cslib.Complexity.MIP.natCast_evalConstraintMod {p Q L : ℕ} (hp : 0 < p) (c : Circuits.Circuit Circuits.Boolean.signature Q (3 * (L + 1))) (A : MvPolynomial (Fin L) (ZMod p)) (r z : Fin (Q + c.size) → ℕ) (val : Fin 3 → ℕ) (hval : ∀ (j : Fin 3), ↑(val j) = (MvPolynomial.eval fun (i : Fin L) => ↑(z ⟨(c.outputs (Circuits.Boolean.SuccinctVerifier.addressWire L j i)).toNat, ⋯⟩)) A) :
↑(evalConstraintMod p Q c.code.1 (List.ofFn r) (List.ofFn z) (List.ofFn fun (j : Fin 3) => (c.outputs (Circuits.Boolean.SuccinctVerifier.signWire L j)).toNat) (List.ofFn val)) = (MvPolynomial.eval fun (i : Fin (Q + c.size)) => ↑(z i)) (tableauConstraintPoly c A fun (i : Fin (Q + c.size)) => ↑(r i))

evalConstraintMod agrees with evaluating tableauConstraintPoly c A r in ZMod p.

evalGateTraceMod is computable in polynomial time uniformly over growing binary modulus p, binary circuit input count Q, residue vector z, and raw De Morgan code gates.