Documentation

Complexitylib.Classes.PCP.Internal.AlgPosNum

A composed position's number #

A read of the assembled tester lands in one of three kinds of block: the encoding block of a vertex, a dart's linear table, or a dart's quadratic table. Which kind, and which cube inside the block, depends only on the read and the random string — with two exceptions, where the cube is shifted by the arithmetization of the dart's satisfying set. Which block, on the other hand, is a vertex or a dart of the outer graph, so it is the only part that grows with the input.

This module splits a position's number along that seam.

Main definitions #

Main results #

noncomputable def Complexity.RegCSP.blockNum {β : Type} (R : RegCSP β) [NumEnc R.graph.V] [NumEnc R.graph.D] (p : R.Dart) :

The number of the vertex or dart whose block a read's position lies in.

Equations
Instances For

    The cube a read names, from the satisfying set alone.

    Equations
    Instances For
      noncomputable def Complexity.RegCSP.cubeNum {β : Type} [Fintype β] (R : RegCSP β) {B : } (enc : βBooleanAnalysis.Cube B) (p : R.Dart) (z : BooleanAnalysis.Cube (Tester.ROf B)) :

      The number of the cube a read's position names inside its block.

      Equations
      Instances For
        def Complexity.RegCSP.posNum (cardV cardD cardB cardN cardNN k w c : ) :

        The number a kind, a block and a cube make: encoding blocks first, then the linear tables, then the quadratic ones.

        Equations
        • One or more equations did not get rendered due to their size.
        Instances For

          The block of an input read is the dart's tail, which its number names by division.

          The block of the other input read is the dart's head.

          theorem Complexity.RegCSP.val_head_toGraph_compose {β : Type} [Fintype β] (R : RegCSP β) [NumEnc R.graph.V] [NumEnc R.graph.D] {B : } (enc : βBooleanAnalysis.Cube B) (k : Fin (Fintype.card (compose enc R).Edge)) :

          The second endpoint of a composed edge.

          The test's verdict, from the satisfying set alone.

          Equations
          Instances For
            theorem Complexity.RegCSP.cubeNum_eq_cubeOfSet {β : Type} [Fintype β] (R : RegCSP β) {B : } (enc : βBooleanAnalysis.Cube B) (p : R.Dart) (z : BooleanAnalysis.Cube (Tester.ROf B)) (i : ReadIdx) :
            R.cubeNum enc p z i = cubeOfSet (satSet enc R p) z i

            The cube depends on the satisfying set alone.

            theorem Complexity.RegCSP.check_eq_checkOfSet {β : Type} [Fintype β] (R : RegCSP β) {B : } (enc : βBooleanAnalysis.Cube B) (p : R.Dart) (z : BooleanAnalysis.Cube (Tester.ROf B)) :
            (compose enc R).check p z = checkOfSet (satSet enc R p) z

            And so does the verdict.

            An edge's data and all three of its numbers, in one package: a caller never has to spell the composed system out, nor match anything against it.

            Everything depends on the dart's constraint alone #

            theorem Complexity.RegCSP.satSet_congr {β : Type} [Fintype β] (R : RegCSP β) {B : } (enc : βBooleanAnalysis.Cube B) {R' : RegCSP β} (p : R.Dart) (p' : R'.Dart) (h : R.rel p.1 p.2 = R'.rel p'.1 p'.2) :
            satSet enc R p = satSet enc R' p'

            The satisfying set depends only on the dart's constraint.

            theorem Complexity.RegCSP.cubeNum_congr {β : Type} [Fintype β] (R : RegCSP β) {B : } (enc : βBooleanAnalysis.Cube B) {β' : Type} [Fintype β'] [DecidableEq β'] [Nonempty β'] {R' : RegCSP β'} [NumEnc R'.graph.V] [NumEnc R'.graph.D] {enc' : β'BooleanAnalysis.Cube B} (p : R.Dart) (p' : R'.Dart) (z : BooleanAnalysis.Cube (Tester.ROf B)) (i : ReadIdx) (h : satSet enc R p = satSet enc' R' p') :
            R.cubeNum enc p z i = R'.cubeNum enc' p' z i

            So does the cube a read names, even across two different systems.

            theorem Complexity.RegCSP.check_congr {β : Type} [Fintype β] (R : RegCSP β) {B : } (enc : βBooleanAnalysis.Cube B) {β' : Type} [Fintype β'] [DecidableEq β'] [Nonempty β'] {R' : RegCSP β'} [NumEnc R'.graph.V] [NumEnc R'.graph.D] {enc' : β'BooleanAnalysis.Cube B} (p : R.Dart) (p' : R'.Dart) (z : BooleanAnalysis.Cube (Tester.ROf B)) (h : satSet enc R p = satSet enc' R' p') :
            (compose enc R).check p z = (compose enc' R').check p' z

            And so does the test's verdict.

            Across two graphs #

            theorem Complexity.satSet_eq_of_data {α : Type} [Fintype α] [DecidableEq α] (G G' : ConstraintGraph α) (E : ExpanderFamily) {q T B : } (hq : 0 < q) (v : (G.preprocess E).graph.V) (v' : (G'.preprocess E).graph.V) (x : (Fin T(G.preprocess E).graph.D) × (Fin TFin q)) (encβ : KOpinion (G.preprocess E).graph T αBooleanAnalysis.Cube B) (hpar : (fun (i : Fin ((G.preprocess E).graph.kLen x)) => NumEnc.enc ((G.preprocess E).graph.walkAt ((G.preprocess E).graph.kLen x) v ((G.preprocess E).graph.kWalk x) i) % 2) = fun (i : Fin ((G'.preprocess E).graph.kLen x)) => NumEnc.enc ((G'.preprocess E).graph.walkAt ((G'.preprocess E).graph.kLen x) v' ((G'.preprocess E).graph.kWalk x) i) % 2) (hcode : (fun (i : Fin ((G.preprocess E).graph.kLen x)) => codeOfRel (G.rel ((G.preprocess E).graph.walkAt ((G.preprocess E).graph.kLen x) v ((G.preprocess E).graph.kWalk x) i).1)) = fun (i : Fin ((G'.preprocess E).graph.kLen x)) => codeOfRel (G'.rel ((G'.preprocess E).graph.walkAt ((G'.preprocess E).graph.kLen x) v' ((G'.preprocess E).graph.kWalk x) i).1)) (hend : (G.preprocess E).graph.endIdx v ((G.preprocess E).graph.kWalk x) = (G'.preprocess E).graph.endIdx v' ((G'.preprocess E).graph.kWalk x)) :
            RegCSP.satSet encβ ((G.preprocess E).killedPow q T hq) (v, x) = RegCSP.satSet encβ ((G'.preprocess E).killedPow q T hq) (v', x)

            Two graphs whose walks show the same data have the same satisfying set. Both sides live in Finset (Cube (kOf B)), a type that does not mention either graph.

            theorem Complexity.cubeNum_eq_of_data {α : Type} [Fintype α] [DecidableEq α] [Nonempty α] (G G' : ConstraintGraph α) (E : ExpanderFamily) {q T B : } (hq : 0 < q) (v : (G.preprocess E).graph.V) (v' : (G'.preprocess E).graph.V) (x : (Fin T(G.preprocess E).graph.D) × (Fin TFin q)) (encβ : KOpinion (G.preprocess E).graph T αBooleanAnalysis.Cube B) (z : BooleanAnalysis.Cube (Tester.ROf B)) (i : ReadIdx) (h : RegCSP.satSet encβ ((G.preprocess E).killedPow q T hq) (v, x) = RegCSP.satSet encβ ((G'.preprocess E).killedPow q T hq) (v', x)) :
            ((G.preprocess E).killedPow q T hq).cubeNum encβ (v, x) z i = ((G'.preprocess E).killedPow q T hq).cubeNum encβ (v', x) z i

            The cube a read names is the same across two such graphs.

            theorem Complexity.check_eq_of_data {α : Type} [Fintype α] [DecidableEq α] [Nonempty α] (G G' : ConstraintGraph α) (E : ExpanderFamily) {q T B : } (hq : 0 < q) (v : (G.preprocess E).graph.V) (v' : (G'.preprocess E).graph.V) (x : (Fin T(G.preprocess E).graph.D) × (Fin TFin q)) (encβ : KOpinion (G.preprocess E).graph T αBooleanAnalysis.Cube B) (z : BooleanAnalysis.Cube (Tester.ROf B)) (h : RegCSP.satSet encβ ((G.preprocess E).killedPow q T hq) (v, x) = RegCSP.satSet encβ ((G'.preprocess E).killedPow q T hq) (v', x)) :
            (RegCSP.compose encβ ((G.preprocess E).killedPow q T hq)).check (v, x) z = (RegCSP.compose encβ ((G'.preprocess E).killedPow q T hq)).check (v', x) z

            And so is the test's verdict.