Documentation

MIPRE.TM.CookLevin.FamilyFml

The clause families as formulas #

For each family predicate of Families.lean and Window.lean, the formula computing it on a candidate of field formulas (CandF: three FieldsF and three sign formulas), with its exact semantics (eval_startF, …, eval_windowF) and its input bound. The fixed input tapes enter through value formulas (cellValF for a listed string, unaryValF for the unary time bound), tied to fixed by TapeSpec; the free tapes through the list of their indices (FreeSpec) (planning/succinct-cook-levin.md, S3).

Helpers #

theorem MIPRE.TM.CookLevin.Desc.eval_eqN {fs : List SAT.Fml} {w k : ℕ} (hl : fs.length = w) (hk : k < 2 ^ w) (x : ℕ → Bool) :
theorem MIPRE.TM.CookLevin.Desc.eval_ltN {fs : List SAT.Fml} {w k : ℕ} (hl : fs.length = w) (hk : k < 2 ^ w) (x : ℕ → Bool) :
theorem MIPRE.TM.CookLevin.Desc.eval_eqF {fs gs : List SAT.Fml} {w : ℕ} (hl : fs.length = w) (hg : gs.length = w) (x : ℕ → Bool) :
theorem MIPRE.TM.CookLevin.Desc.eval_ltF {fs gs : List SAT.Fml} {w : ℕ} (hl : fs.length = w) (hg : gs.length = w) (x : ℕ → Bool) :
theorem MIPRE.TM.CookLevin.Desc.eval_addN {fs gs : List SAT.Fml} {w k : ℕ} (hl : fs.length = w) (hg : gs.length = w) (hk : k < 2 ^ w) (x : ℕ → Bool) :
theorem MIPRE.TM.CookLevin.Desc.InputsLt.list_cons {n : ℕ} {f : SAT.Fml} {l : List SAT.Fml} (hf : SAT.Fml.InputsLt n f) (hl : ∀ g ∈ l, SAT.Fml.InputsLt n g) (g : SAT.Fml) :
g ∈ f :: l → SAT.Fml.InputsLt n g

Input bounds of the field formulas #

The field formulas read only inputs below n.

Instances For
    theorem MIPRE.TM.CookLevin.Desc.InputsLt.muxList {n : ℕ} {s : SAT.Fml} {as bs : List SAT.Fml} (hs : SAT.Fml.InputsLt n s) (ha : ∀ f ∈ as, SAT.Fml.InputsLt n f) (hb : ∀ f ∈ bs, SAT.Fml.InputsLt n f) (f : SAT.Fml) :
    theorem MIPRE.TM.CookLevin.Desc.InputsLt.take {n : ℕ} {l : List SAT.Fml} (h : ∀ f ∈ l, SAT.Fml.InputsLt n f) (k : ℕ) (f : SAT.Fml) :
    theorem MIPRE.TM.CookLevin.Desc.InputsLt.tail {n : ℕ} {l : List SAT.Fml} (h : ∀ f ∈ l, SAT.Fml.InputsLt n f) (f : SAT.Fml) :
    theorem MIPRE.TM.CookLevin.Desc.InputsLt.jF (e G b n : ℕ) (hn : b + mOf e G ≤ n) (f : SAT.Fml) :
    f ∈ Desc.jF e G b → SAT.Fml.InputsLt n f
    theorem MIPRE.TM.CookLevin.Desc.InputsLt.rF (e G T b n : ℕ) (hn : b + mOf e G ≤ n) (f : SAT.Fml) :
    f ∈ Desc.rF e G T b → SAT.Fml.InputsLt n f
    theorem MIPRE.TM.CookLevin.Desc.InputsLt.pAnsF (e G T b n : ℕ) (hn : b + mOf e G ≤ n) (f : SAT.Fml) :
    f ∈ Desc.pAnsF e G T b → SAT.Fml.InputsLt n f
    theorem MIPRE.TM.CookLevin.Desc.InputsLt.fieldOff (e G b n : ℕ) (hn : b + mOf e G ≤ n) (off w : ℕ) (h : off + w ≤ mOf e G) (f : SAT.Fml) :
    f ∈ SAT.Fml.field (b + off) w → SAT.Fml.InputsLt n f
    theorem MIPRE.TM.CookLevin.Desc.jsOff_add_le (e G : ℕ) (k : Fin 13) :
    jsOff e ↑k + W e ≤ mOf e G
    theorem MIPRE.TM.CookLevin.Desc.litFields_inputsLt (e G T b n : ℕ) (hn : b + mOf e G ≤ n) :

    Candidates of formulas #

    A candidate of formulas: three field records and three sign formulas.

    Instances For

      The candidate a candidate of formulas evaluates to.

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

        The three records have the field lengths.

        Instances For

          The candidate reads only inputs below n.

          Instances For

            Same-variable formulas #

            cellEq.

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

              auxEq.

              Equations
              • One or more equations did not get rendered due to their size.
              Instances For
                theorem MIPRE.TM.CookLevin.Desc.eval_cellEqF (e G : ℕ) {A B : FieldsF} (hA : FieldsF.Lengths e G A) (hB : FieldsF.Lengths e G B) (x : ℕ → Bool) :
                theorem MIPRE.TM.CookLevin.Desc.eval_headEqF (e G : ℕ) {A B : FieldsF} (hA : FieldsF.Lengths e G A) (hB : FieldsF.Lengths e G B) (x : ℕ → Bool) :
                theorem MIPRE.TM.CookLevin.Desc.eval_tEqF (e G : ℕ) {A B : FieldsF} (hA : FieldsF.Lengths e G A) (hB : FieldsF.Lengths e G B) (x : ℕ → Bool) :
                theorem MIPRE.TM.CookLevin.Desc.eval_auxEqF (e G : ℕ) {A B : FieldsF} (hA : FieldsF.Lengths e G A) (hB : FieldsF.Lengths e G B) (x : ℕ → Bool) :

                Unit clauses and signs #

                UnitCell.

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

                  UnitHead.

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

                    UnitState.

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

                      UnitEmitBad.

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

                        UnitEmitted.

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

                          UnitAux.

                          Equations
                          • One or more equations did not get rendered due to their size.
                          Instances For
                            theorem MIPRE.TM.CookLevin.Desc.eval_unitAuxF (e G : ℕ) {C : CandF} (hC : CandF.Lengths e G C) (x : ℕ → Bool) :

                            Positions and values #

                            Bdry S p.

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

                              p = 3 for an input tape, S + 3 for a work tape: the start cell.

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

                                v = workCode S p.

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

                                  The lookup table of a string of codes from cell k: p = k + i ∧ v = codes[i].

                                  Equations
                                  Instances For

                                    v = cellCode x S p for the string x of codes codes, of length at most S.

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

                                      v = cellCode 1^T S p.

                                      Equations
                                      • One or more equations did not get rendered due to their size.
                                      Instances For
                                        theorem MIPRE.TM.CookLevin.Desc.eval_bdryF (e G : ℕ) {A : FieldsF} (hA : FieldsF.Lengths e G A) (x : ℕ → Bool) :
                                        theorem MIPRE.TM.CookLevin.Desc.eval_lookupList (e G : ℕ) {A : FieldsF} (hA : FieldsF.Lengths e G A) (x : ℕ → Bool) (codes : List ℕ) (hc : ∀ c ∈ codes, c < 8) (k : ℕ) :
                                        k + codes.length < 2 ^ W e → (SAT.Fml.eval x (SAT.Fml.orList (lookupList e A k codes)) = true ↔ ∃ (i : ℕ) (h : i < codes.length), SAT.Fml.val A.p x = k + i ∧ SAT.Fml.val A.v x = codes[i])
                                        theorem MIPRE.TM.CookLevin.Desc.eval_cellValF (e G : ℕ) {A : FieldsF} (hA : FieldsF.Lengths e G A) (x : ℕ → Bool) (s : List Interp.Sym) (hs : s.length ≤ Sof e) :
                                        theorem MIPRE.TM.CookLevin.Desc.InputsLt.lookupList (e : ℕ) {n : ℕ} {A : FieldsF} (hA : FieldsF.InputsLt n A) (codes : List ℕ) (k : ℕ) (f : SAT.Fml) :
                                        f ∈ Desc.lookupList e A k codes → SAT.Fml.InputsLt n f

                                        More helpers #

                                        theorem MIPRE.TM.CookLevin.Desc.eval_gtN {fs : List SAT.Fml} {w k : ℕ} (hl : fs.length = w) (hk : k + 1 < 2 ^ w) (x : ℕ → Bool) :
                                        theorem MIPRE.TM.CookLevin.Desc.eval_geN {fs : List SAT.Fml} {w k : ℕ} (hl : fs.length = w) (hk : k < 2 ^ w) (x : ℕ → Bool) :
                                        structure MIPRE.TM.CookLevin.Desc.FreeSpec (fixed : Fin 7 → Option (List Interp.Sym)) (frees : List ℕ) :

                                        The tapes fixed j = none are the indices frees.

                                        Instances For
                                          structure MIPRE.TM.CookLevin.Desc.TapeSpec (e : ℕ) (A : FieldsF) (fixed : Fin 7 → Option (List Interp.Sym)) (tabs : List (ℕ × SAT.Fml)) :

                                          The entries (j, vf) of tabs are the fixed tapes fixed j = some x, with vf computing v = cellCode x S p on the record A.

                                          Instances For
                                            theorem MIPRE.TM.CookLevin.Desc.eval_freeTapeF (e G : ℕ) {fixed : Fin 7 → Option (List Interp.Sym)} {frees : List ℕ} (hs : FreeSpec fixed frees) {A : FieldsF} (hA : FieldsF.Lengths e G A) (x : ℕ → Bool) :
                                            theorem MIPRE.TM.CookLevin.Desc.eval_tZeroF (e G : ℕ) {A : FieldsF} (hA : FieldsF.Lengths e G A) (x : ℕ → Bool) :

                                            The start family #

                                            StartHead.

                                            Equations
                                            • One or more equations did not get rendered due to their size.
                                            Instances For
                                              noncomputable def MIPRE.TM.CookLevin.Desc.startStateF (e : ℕ) (C : CandF) :

                                              StartState.

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

                                                StartFixed, for the tapes tabs.

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

                                                  StartWork.

                                                  Equations
                                                  • One or more equations did not get rendered due to their size.
                                                  Instances For
                                                    noncomputable def MIPRE.TM.CookLevin.Desc.startF (e : ℕ) (tabs : List (ℕ × SAT.Fml)) (C : CandF) :

                                                    StartPred.

                                                    Equations
                                                    • One or more equations did not get rendered due to their size.
                                                    Instances For
                                                      theorem MIPRE.TM.CookLevin.Desc.eval_startFixedF (e G : ℕ) (fixed : Fin 7 → Option (List Interp.Sym)) (tabs : List (ℕ × SAT.Fml)) {C : CandF} (hC : CandF.Lengths e G C) (x : ℕ → Bool) (hs : TapeSpec e C.A₁ fixed tabs) :
                                                      SAT.Fml.eval x (startFixedF e tabs C) = true ↔ StartFixed e fixed (evalCand C x)
                                                      theorem MIPRE.TM.CookLevin.Desc.eval_startF (e G : ℕ) (fixed : Fin 7 → Option (List Interp.Sym)) (tabs : List (ℕ × SAT.Fml)) {C : CandF} (hC : CandF.Lengths e G C) (x : ℕ → Bool) (hs : TapeSpec e C.A₁ fixed tabs) :
                                                      SAT.Fml.eval x (startF e tabs C) = true ↔ StartPred e fixed (evalCand C x)
                                                      theorem MIPRE.TM.CookLevin.Desc.InputsLt.startFixedF (e : ℕ) {n : ℕ} (tabs : List (ℕ × SAT.Fml)) (htabs : ∀ jv ∈ tabs, SAT.Fml.InputsLt n jv.2) {C : CandF} (hC : CandF.InputsLt n C) :
                                                      theorem MIPRE.TM.CookLevin.Desc.InputsLt.startF (e : ℕ) {n : ℕ} (tabs : List (ℕ × SAT.Fml)) (htabs : ∀ jv ∈ tabs, SAT.Fml.InputsLt n jv.2) {C : CandF} (hC : CandF.InputsLt n C) :

                                                      The free family #

                                                      FreeBdry.

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

                                                        FreeOther.

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

                                                          FreeTwo.

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

                                                            FreeOneOf.

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

                                                              FreeNand.

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

                                                                FreeBlank.

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

                                                                  FreePred.

                                                                  Equations
                                                                  • One or more equations did not get rendered due to their size.
                                                                  Instances For
                                                                    theorem MIPRE.TM.CookLevin.Desc.eval_freeBdryF (e G : ℕ) (fixed : Fin 7 → Option (List Interp.Sym)) (frees : List ℕ) (hs : FreeSpec fixed frees) {C : CandF} (hC : CandF.Lengths e G C) (x : ℕ → Bool) :
                                                                    SAT.Fml.eval x (freeBdryF e frees C) = true ↔ FreeBdry e fixed (evalCand C x)
                                                                    theorem MIPRE.TM.CookLevin.Desc.eval_freeOtherF (e G : ℕ) (fixed : Fin 7 → Option (List Interp.Sym)) (frees : List ℕ) (hs : FreeSpec fixed frees) {C : CandF} (hC : CandF.Lengths e G C) (x : ℕ → Bool) :
                                                                    SAT.Fml.eval x (freeOtherF e frees C) = true ↔ FreeOther e fixed (evalCand C x)
                                                                    theorem MIPRE.TM.CookLevin.Desc.eval_freeTwoF (e G : ℕ) (fixed : Fin 7 → Option (List Interp.Sym)) (frees : List ℕ) (hs : FreeSpec fixed frees) {C : CandF} (hC : CandF.Lengths e G C) (x : ℕ → Bool) :
                                                                    SAT.Fml.eval x (freeTwoF e frees C) = true ↔ FreeTwo e fixed (evalCand C x)
                                                                    theorem MIPRE.TM.CookLevin.Desc.eval_freeOneOfF (e G : ℕ) (fixed : Fin 7 → Option (List Interp.Sym)) (frees : List ℕ) (hs : FreeSpec fixed frees) {C : CandF} (hC : CandF.Lengths e G C) (x : ℕ → Bool) :
                                                                    SAT.Fml.eval x (freeOneOfF e frees C) = true ↔ FreeOneOf e fixed (evalCand C x)
                                                                    theorem MIPRE.TM.CookLevin.Desc.eval_freeNandF (e G : ℕ) (fixed : Fin 7 → Option (List Interp.Sym)) (frees : List ℕ) (hs : FreeSpec fixed frees) {C : CandF} (hC : CandF.Lengths e G C) (x : ℕ → Bool) :
                                                                    SAT.Fml.eval x (freeNandF e frees C) = true ↔ FreeNand e fixed (evalCand C x)
                                                                    theorem MIPRE.TM.CookLevin.Desc.eval_freeBlankF (e G : ℕ) (fixed : Fin 7 → Option (List Interp.Sym)) (frees : List ℕ) (hs : FreeSpec fixed frees) {C : CandF} (hC : CandF.Lengths e G C) (x : ℕ → Bool) :
                                                                    SAT.Fml.eval x (freeBlankF e frees C) = true ↔ FreeBlank e fixed (evalCand C x)
                                                                    theorem MIPRE.TM.CookLevin.Desc.eval_freeF (e G : ℕ) (fixed : Fin 7 → Option (List Interp.Sym)) (frees : List ℕ) (hs : FreeSpec fixed frees) {C : CandF} (hC : CandF.Lengths e G C) (x : ℕ → Bool) :
                                                                    SAT.Fml.eval x (freeF e frees C) = true ↔ FreePred e fixed (evalCand C x)
                                                                    theorem MIPRE.TM.CookLevin.Desc.InputsLt.freeF (e : ℕ) {n : ℕ} (frees : List ℕ) {C : CandF} (hC : CandF.InputsLt n C) :

                                                                    The boundary, emission and final families #

                                                                    BdryCell.

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

                                                                      EmitZero.

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

                                                                        EmitStep.

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

                                                                          EmitMono.

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

                                                                            EmitOne.

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

                                                                              EmitOnce.

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

                                                                                EmitPred.

                                                                                Equations
                                                                                • One or more equations did not get rendered due to their size.
                                                                                Instances For
                                                                                  noncomputable def MIPRE.TM.CookLevin.Desc.finalStateF (e : ℕ) (C : CandF) :

                                                                                  FinalState.

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

                                                                                    FinalEmitted.

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

                                                                                      The five explicit families #

                                                                                      noncomputable def MIPRE.TM.CookLevin.Desc.mainF (e : ℕ) (tabs : List (ℕ × SAT.Fml)) (frees : List ℕ) (C : CandF) :

                                                                                      MainPred.

                                                                                      Equations
                                                                                      • One or more equations did not get rendered due to their size.
                                                                                      Instances For
                                                                                        theorem MIPRE.TM.CookLevin.Desc.eval_mainF (e G : ℕ) {fixed : Fin 7 → Option (List Interp.Sym)} {tabs : List (ℕ × SAT.Fml)} {frees : List ℕ} {C : CandF} (hC : CandF.Lengths e G C) (x : ℕ → Bool) (ht : TapeSpec e C.A₁ fixed tabs) (hf : FreeSpec fixed frees) :
                                                                                        SAT.Fml.eval x (mainF e tabs frees C) = true ↔ MainPred e fixed (evalCand C x)
                                                                                        theorem MIPRE.TM.CookLevin.Desc.InputsLt.mainF (e : ℕ) {n : ℕ} (tabs : List (ℕ × SAT.Fml)) (htabs : ∀ jv ∈ tabs, SAT.Fml.InputsLt n jv.2) (frees : List ℕ) {C : CandF} (hC : CandF.InputsLt n C) :
                                                                                        SAT.Fml.InputsLt n (Desc.mainF e tabs frees C)

                                                                                        The window family #

                                                                                        The templates of the check circuit enter the formula as data: a window variable is a descriptor (WDesc: a one-hot kind, and the tape, offset, value and state as bit strings), a literal spec an LDesc, so that the describer program builds the window formula by a fold over a constant list of descriptors, never inspecting a WinVar or a Gate.

                                                                                        The one-hot vector of length n with its k-th entry set.

                                                                                        Equations
                                                                                        Instances For
                                                                                          theorem MIPRE.TM.CookLevin.Desc.getElem_oneHot (n k i : ℕ) (h : i < (oneHot n k).length) :
                                                                                          (oneHot n k)[i] = decide (i = k)

                                                                                          Select by a one-hot vector: ⋁ᵢ bᵢ ∧ fᵢ.

                                                                                          Equations
                                                                                          Instances For
                                                                                            theorem MIPRE.TM.CookLevin.Desc.eval_selectF (hot : List Bool) (fs : List SAT.Fml) (x : ℕ → Bool) :
                                                                                            SAT.Fml.eval x (selectF hot fs) = true ↔ ∃ (i : ℕ) (h : i < (List.zipWith (fun (b : Bool) (f : SAT.Fml) => (SAT.Fml.const b).and f) hot fs).length), hot[i] = true ∧ SAT.Fml.eval x fs[i] = true
                                                                                            theorem MIPRE.TM.CookLevin.Desc.eval_selectF_oneHot (n k : ℕ) (fs : List SAT.Fml) (hl : fs.length = n) (hk : k < n) (x : ℕ → Bool) :
                                                                                            theorem MIPRE.TM.CookLevin.Desc.InputsLt.selectF {n : ℕ} (hot : List Bool) {fs : List SAT.Fml} (hfs : ∀ f ∈ fs, SAT.Fml.InputsLt n f) :

                                                                                            A window variable as data: the kind (one-hot over cellPre, headPre, cellPost, headPost, statePre, statePost, emitOne, emitBad), the tape (4 bits, and one-hot over the 13 tapes), the offset (3 bits), the value (3 bits), the state (Qb bits).

                                                                                            Instances For

                                                                                              The descriptor of a window variable.

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

                                                                                                The descriptor of nothing: no kind.

                                                                                                Equations
                                                                                                Instances For

                                                                                                  p = js_d + δ, the tape d given one-hot.

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

                                                                                                    WinMatch, on a descriptor.

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

                                                                                                      SpecMatch for a gate spec, with the gate index as bits.

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

                                                                                                        A literal spec as data.

                                                                                                        Instances For

                                                                                                          SpecMatch, on a descriptor.

                                                                                                          Equations
                                                                                                          Instances For

                                                                                                            The descriptors of the window variables, in the canonical order.

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

                                                                                                              The descriptor of a spec.

                                                                                                              Equations
                                                                                                              Instances For
                                                                                                                noncomputable def MIPRE.TM.CookLevin.Desc.Tpl.toN (G : ℕ) (tp : Tpl) :

                                                                                                                The descriptor of a template.

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

                                                                                                                  TplMatch, on a descriptor.

                                                                                                                  Equations
                                                                                                                  • One or more equations did not get rendered due to their size.
                                                                                                                  Instances For
                                                                                                                    noncomputable def MIPRE.TM.CookLevin.Desc.tplsFrom (G : ℕ) :

                                                                                                                    The template descriptors of the gates gs, numbered from g₀.

                                                                                                                    Equations
                                                                                                                    Instances For
                                                                                                                      noncomputable def MIPRE.TM.CookLevin.Desc.tplsOf (G : ℕ) (chk : SAT.Circuit) :

                                                                                                                      The template descriptors of the check circuit: the constant of the describer.

                                                                                                                      Equations
                                                                                                                      Instances For

                                                                                                                        WindowGates, on the descriptors tpls.

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

                                                                                                                          WindowOut.

                                                                                                                          Equations
                                                                                                                          • One or more equations did not get rendered due to their size.
                                                                                                                          Instances For
                                                                                                                            theorem MIPRE.TM.CookLevin.Desc.eval_posF (e G : ℕ) {Fa A : FieldsF} (hFa : FieldsF.Lengths e G Fa) (hA : FieldsF.Lengths e G A) (x : ℕ → Bool) (d : Tape 7 6) (δ : ℕ) (hδ : δ < 8) :
                                                                                                                            SAT.Fml.eval x (posF e Fa A (oneHot 13 (tapeCode d)) (nbits 3 δ)) = true ↔ SAT.Fml.val A.p x = SAT.Fml.val (Fa.js ⟨tapeCode d, ⋯⟩) x + δ
                                                                                                                            theorem MIPRE.TM.CookLevin.Desc.eval_winMatchN (e G : ℕ) {Fa A : FieldsF} (hFa : FieldsF.Lengths e G Fa) (hA : FieldsF.Lengths e G A) (x : ℕ → Bool) (wv : WinVar 7 6 Interp.Sym Interp.Ctl) :
                                                                                                                            SAT.Fml.eval x (winMatchN e Fa A (wvDesc wv)) = true ↔ WinMatch e (evalFields Fa x) wv (evalFields A x)
                                                                                                                            theorem MIPRE.TM.CookLevin.Desc.eval_auxMatchN (e G : ℕ) {Fa A : FieldsF} (hFa : FieldsF.Lengths e G Fa) (hA : FieldsF.Lengths e G A) (x : ℕ → Bool) (u : ℕ) (hu : u < G) :
                                                                                                                            SAT.Fml.eval x (auxMatchN e G Fa A (nbits (Gb G) u)) = true ↔ SpecMatch e G (evalFields Fa x) (LitSpec.aux u) (evalFields A x)
                                                                                                                            theorem MIPRE.TM.CookLevin.Desc.eval_specMatchN_aux (e G : ℕ) {Fa A : FieldsF} (hFa : FieldsF.Lengths e G Fa) (hA : FieldsF.Lengths e G A) (x : ℕ → Bool) (u : ℕ) (hu : u < G) :
                                                                                                                            theorem MIPRE.TM.CookLevin.Desc.eval_specMatchN_win (e G : ℕ) {Fa A : FieldsF} (hFa : FieldsF.Lengths e G Fa) (hA : FieldsF.Lengths e G A) (x : ℕ → Bool) (n : ℕ) :
                                                                                                                            theorem MIPRE.TM.CookLevin.Desc.eval_specMatchN (e G : ℕ) {Fa A : FieldsF} (hFa : FieldsF.Lengths e G Fa) (hA : FieldsF.Lengths e G A) (x : ℕ → Bool) (sp : LitSpec) (hsp : ∀ (u : ℕ), sp = LitSpec.aux u → u < G) :
                                                                                                                            SAT.Fml.eval x (specMatchN e G Fa A (LitSpec.toN G sp)) = true ↔ SpecMatch e G (evalFields Fa x) sp (evalFields A x)
                                                                                                                            theorem MIPRE.TM.CookLevin.Desc.eval_tplN (e G : ℕ) {C : CandF} (hC : CandF.Lengths e G C) (x : ℕ → Bool) (tp : Tpl) (hsp : ∀ (sp : LitSpec), sp = tp.1.1 ∨ sp = tp.2.1.1 ∨ sp = tp.2.2.1 → ∀ (u : ℕ), sp = LitSpec.aux u → u < G) :
                                                                                                                            SAT.Fml.eval x (tplN e G (Tpl.toN G tp) C) = true ↔ TplMatch e G tp (evalCand C x)
                                                                                                                            theorem MIPRE.TM.CookLevin.Desc.mem_tplsFrom (G : ℕ) (gs : List SAT.Gate) (g₀ : ℕ) (l : List NTpl) :
                                                                                                                            l ∈ tplsFrom G g₀ gs ↔ ∃ (i : ℕ) (h : i < gs.length), l = List.map (Tpl.toN G) (gateTemplates (g₀ + i) gs[i])
                                                                                                                            theorem MIPRE.TM.CookLevin.Desc.eval_windowGatesN (e G : ℕ) {C : CandF} (hC : CandF.Lengths e G C) (x : ℕ → Bool) (chk : SAT.Circuit) (hG : G = chk.gates.length) (hC' : chk.RefsLt) (hin : chk.InputsLt) (hinp : chk.inputs = winCard 7 6 Interp.Sym Interp.Ctl) :
                                                                                                                            SAT.Fml.eval x (windowGatesN e G (tplsOf G chk) C) = true ↔ WindowGates e G chk (evalCand C x)
                                                                                                                            theorem MIPRE.TM.CookLevin.Desc.eval_windowN (e G : ℕ) {C : CandF} (hC : CandF.Lengths e G C) (x : ℕ → Bool) (chk : SAT.Circuit) (hG : G = chk.gates.length) (hC' : chk.RefsLt) (hin : chk.InputsLt) (hinp : chk.inputs = winCard 7 6 Interp.Sym Interp.Ctl) :
                                                                                                                            SAT.Fml.eval x (windowN e G (tplsOf G chk) C) = true ↔ WindowPred e G chk (evalCand C x)
                                                                                                                            theorem MIPRE.TM.CookLevin.Desc.InputsLt.posF (e : ℕ) {n : ℕ} {Fa A : FieldsF} (hFa : FieldsF.InputsLt n Fa) (hA : FieldsF.InputsLt n A) (dHot : List Bool) (δ : Cost.BitStr) :
                                                                                                                            SAT.Fml.InputsLt n (Desc.posF e Fa A dHot δ)
                                                                                                                            theorem MIPRE.TM.CookLevin.Desc.InputsLt.tplN (e G : ℕ) {n : ℕ} {C : CandF} (hC : CandF.InputsLt n C) (tp : NTpl) :
                                                                                                                            theorem MIPRE.TM.CookLevin.Desc.InputsLt.windowN (e G : ℕ) {n : ℕ} {C : CandF} (hC : CandF.InputsLt n C) (tpls : List (List NTpl)) :

                                                                                                                            The whole tableau #

                                                                                                                            noncomputable def MIPRE.TM.CookLevin.Desc.tableauF (e G : ℕ) (tabs : List (ℕ × SAT.Fml)) (frees : List ℕ) (tpls : List (List NTpl)) (C : CandF) :

                                                                                                                            The formula of the tableau on a candidate: the five explicit families or the window family.

                                                                                                                            Equations
                                                                                                                            Instances For
                                                                                                                              theorem MIPRE.TM.CookLevin.Desc.eval_tableauF (e G : ℕ) {fixed : Fin 7 → Option (List Interp.Sym)} {tabs : List (ℕ × SAT.Fml)} {frees : List ℕ} {C : CandF} (hC : CandF.Lengths e G C) (x : ℕ → Bool) (ht : TapeSpec e C.A₁ fixed tabs) (hf : FreeSpec fixed frees) (chk : SAT.Circuit) (hG : G = chk.gates.length) (hC' : chk.RefsLt) (hin : chk.InputsLt) (hinp : chk.inputs = winCard 7 6 Interp.Sym Interp.Ctl) (hne : chk.gates ≠ []) :
                                                                                                                              SAT.Fml.eval x (tableauF e G tabs frees (tplsOf G chk) C) = true ↔ ∃ cl ∈ tableau Interp.U Interp.Sym.zero Interp.Sym.one (Sof e) fixed chk, Cand.Dec e chk.gates.length (evalCand C x) cl

                                                                                                                              The tableau formula is exact: it accepts a candidate iff the candidate decodes to a clause of tableau U 0 1 S fixed chk.

                                                                                                                              theorem MIPRE.TM.CookLevin.Desc.InputsLt.tableauF (e G : ℕ) {n : ℕ} (tabs : List (ℕ × SAT.Fml)) (htabs : ∀ jv ∈ tabs, SAT.Fml.InputsLt n jv.2) (frees : List ℕ) (tpls : List (List NTpl)) {C : CandF} (hC : CandF.InputsLt n C) :
                                                                                                                              SAT.Fml.InputsLt n (Desc.tableauF e G tabs frees tpls C)