Documentation

CslibFrontier.Computability.PCP.Encoded.Amplification

Executable amplification rounds #

A round follows the preprocessed graph's rotations, constructs the powered edge of every killed walk with its Boolean table, then applies the selected assignment tester and tabulates its output. The output uses the fixed answer alphabet, so it has the same representation as the next round's input.

The killed walks and the tester's slots, coins and queries are enumerated constructively (FinEnum), so a round takes no lists and needs no completeness hypotheses. The degree, alphabet, walk length and killing rate are fixed. All claims are uniform in the runtime graph, and the construction certificate charges the complete intermediate and output tables.

Main definitions #

Main results #

References #

def Cslib.PCP.Encoded.Graph.amplify {C α D : Type} [FinEnum α] [FinEnum D] (eval : C → α → α → Bool) (fallback : C) (rotate : ℕ × ℕ × D → ℕ × D) (T q : ℕ) [NeZero q] (g : Graph C) :

A normalized amplification round: power the preprocessed graph along every killed walk, then compose with every selected check and query. Each stage materializes the next stage's input.

theorem Cslib.PCP.Encoded.Graph.isPolyTime_amplify {C α D : Type} [FinEnum α] [FinEnum D] {Input : Type} {input : Input ↪ List Bool} {enc : C ↪ List Bool} {alphabet : α ↪ List Bool} {labelEncoding : D ↪ List Bool} {graph : Input → Graph C} {eval : C → α → α → Bool} {rotate : ℕ × ℕ × D → ℕ × D} (hgraph : Turing.MultiTapeTM.ComputableInPolyTime graph input (encoding enc)) (hrotate : Turing.MultiTapeTM.ComputableInPolyTime rotate (Turing.MultiTapeTM.encPair Turing.MultiTapeTM.encUnary (Turing.MultiTapeTM.encPair Turing.MultiTapeTM.encUnary labelEncoding)) (Turing.MultiTapeTM.encPair Turing.MultiTapeTM.encUnary labelEncoding)) (heval : Turing.MultiTapeTM.ComputableInPolyTime (fun (p : C × α × α) => eval p.1 p.2.1 p.2.2) (Turing.MultiTapeTM.encPair enc (Turing.MultiTapeTM.encPair alphabet alphabet)) Turing.MultiTapeTM.encBool) (fallback : C) (T q : ℕ) [NeZero q] :
Turing.MultiTapeTM.ComputableInPolyTime (fun (x : Input) => amplify eval fallback rotate T q (graph x)) input (encoding encConstraintTable)

Any certified graph expression can feed a round, with all internal finite encodings hidden.

@[simp]
theorem Cslib.PCP.Encoded.Graph.vertices_amplify {C α D : Type} [FinEnum α] [FinEnum D] (eval : C → α → α → Bool) (fallback : C) (rotate : ℕ × ℕ × D → ℕ × D) (T q : ℕ) [NeZero q] (g : Graph C) :
(amplify eval fallback rotate T q g).vertices = (2 * g.edges.length + 2 * g.edges.length * Fintype.card (PowerLabel D T q)) * Fintype.card (SelectedComposeSlot (PowerAlphabet D α T))

The output vertex count is linear in the number of original edges.

noncomputable def Cslib.PCP.Encoded.Graph.amplifyEdgeFactor (α D : Type) (T q : ℕ) :

The number of output edges per input edge, counting its two half-edges and all walks, coins and queries for each half-edge.

noncomputable def Cslib.PCP.Encoded.Graph.amplifySizeFactor (α D : Type) (T q : ℕ) :

A bound on the total output vertices and edges per input edge.

@[simp]
theorem Cslib.PCP.Encoded.Graph.length_edges_amplify {C α D : Type} [FinEnum α] [FinEnum D] (eval : C → α → α → Bool) (fallback : C) (rotate : ℕ × ℕ × D → ℕ × D) (T q : ℕ) [NeZero q] (g : Graph C) :
(amplify eval fallback rotate T q g).edges.length = amplifyEdgeFactor α D T q * g.edges.length

The edge count is multiplied by the fixed enumeration factor of the round.

theorem Cslib.PCP.Encoded.Graph.vertices_add_edges_amplify_le {C α D : Type} [FinEnum α] [FinEnum D] (eval : C → α → α → Bool) (fallback : C) (rotate : ℕ × ℕ × D → ℕ × D) (T q : ℕ) [NeZero q] (g : Graph C) :
(amplify eval fallback rotate T q g).vertices + (amplify eval fallback rotate T q g).edges.length ≤ amplifySizeFactor α D T q * (g.vertices + g.edges.length)

A single round grows total vertex and edge count by at most its fixed size factor.

theorem Cslib.PCP.Encoded.Graph.wellFormed_amplify {C α D : Type} [FinEnum α] [FinEnum D] (g : Graph C) (eval : C → α → α → Bool) (fallback : C) (family : (n : ℕ) → RotationMap (Fin n) D) (rotate : ℕ × ℕ × D → ℕ × D) (hrotate : ∀ (n : ℕ) (v : Fin n) (d : D), rotate (n, ↑v, d) = (↑((family n).rot (v, d)).1, ((family n).rot (v, d)).2)) (T q : ℕ) [NeZero q] :
(amplify eval fallback rotate T q g).WellFormed

Every generated endpoint lies in the declared range, independently of the input bounds.

theorem Cslib.PCP.Encoded.Graph.div_le_unsatVal_amplify {C α D : Type} [FinEnum α] [FinEnum D] (g : Graph C) (eval : C → α → α → Bool) (fallback : C) (family : (n : ℕ) → RotationMap (Fin n) D) (rotate : ℕ × ℕ × D → ℕ × D) (hrotate : ∀ (n : ℕ) (v : Fin n) (d : D), rotate (n, ↑v, d) = (↑((family n).rot (v, d)).1, ((family n).rot (v, d)).2)) (T q : ℕ) [NeZero q] [Nonempty α] :
((g.regularPreprocess eval fallback family).power T q).toConstraintGraph.unsatVal / 840 ≤ ((amplify eval fallback rotate T q g).toGraph id).unsatVal

The executable round retains the assignment tester's 1/840 fraction of the powered gap.

theorem Cslib.PCP.Encoded.Graph.le_unsatVal_amplify {C α D : Type} [FinEnum α] [FinEnum D] (g : Graph C) (eval : C → α → α → Bool) (fallback : C) (family : (n : ℕ) → RotationMap (Fin n) D) (rotate : ℕ × ℕ × D → ℕ × D) (hrotate : ∀ (n : ℕ) (v : Fin n) (d : D), rotate (n, ↑v, d) = (↑((family n).rot (v, d)).1, ((family n).rot (v, d)).2)) (T q : ℕ) [NeZero q] [Nonempty α] [Nonempty D] (μ : ℝ) (hgap : ∀ (n : ℕ), (family n).spectralExpansion ≤ μ) (hμ : μ < 1) (hq : 2 ≤ q) (hT : T = 4 * Fintype.card α * (q - 1)) :

The complete executable round inherits the mathematical amplification bound, using the explicit cloud numberings selected by its preprocessing program.

theorem Cslib.PCP.Encoded.Graph.min_le_unsatVal_amplify {C α D : Type} [FinEnum α] [FinEnum D] (g : Graph C) (eval : C → α → α → Bool) (fallback : C) (family : (n : ℕ) → RotationMap (Fin n) D) (rotate : ℕ × ℕ × D → ℕ × D) (hrotate : ∀ (n : ℕ) (v : Fin n) (d : D), rotate (n, ↑v, d) = (↑((family n).rot (v, d)).1, ((family n).rot (v, d)).2)) (T q : ℕ) [NeZero q] [Nonempty α] [Nonempty D] (μ : ℝ) (hgap : ∀ (n : ℕ), (family n).spectralExpansion ≤ μ) (hμ : μ < 1) (hq : 2 ≤ q) (hT : T = 4 * Fintype.card α * (q - 1)) {γ : ℝ} (hγ : 0 ≤ γ) (hgain : 2 ≤ ConstraintGraph.Amplification.gain 840 (Fintype.card α) (Fintype.card D) T q μ γ) :
min (2 * (g.toGraph eval).unsatVal) γ ≤ ((amplify eval fallback rotate T q g).toGraph id).unsatVal

A killing rate with sufficient gain doubles the value up to the fixed threshold. The pre-composition bound is shared with the mathematical amplification proof.

theorem Cslib.PCP.Encoded.Graph.satisfiable_amplify_iff {C α D : Type} [FinEnum α] [FinEnum D] (g : Graph C) (eval : C → α → α → Bool) (fallback : C) (family : (n : ℕ) → RotationMap (Fin n) D) (rotate : ℕ × ℕ × D → ℕ × D) (hrotate : ∀ (n : ℕ) (v : Fin n) (d : D), rotate (n, ↑v, d) = (↑((family n).rot (v, d)).1, ((family n).rot (v, d)).2)) (T q : ℕ) [NeZero q] [Nonempty α] [Nonempty D] (μ : ℝ) (hgap : ∀ (n : ℕ), (family n).spectralExpansion ≤ μ) (hμ : μ < 1) (hT : 1 ≤ T) (hq : 2 ≤ q) :
((amplify eval fallback rotate T q g).toGraph id).Satisfiable ↔ (g.toGraph eval).Satisfiable

A complete round preserves satisfiability whenever the expander family has a spectral gap.