Documentation

MIPRE.Foundations.Halting.Paper.Induction

The halting verifier along the paper's route: the values at level C #

Blueprint thm:halting in the paper's form, at a fixed level, from the decider of Paper/Decider.lean and gap-preserving compression: for a machine M and a parameter Ī» such that š’±^halt_{M,Ī»} is Ī»-bounded (the accounting of Paper/Cost.lean supplies one),

with C = max Cā‚€ 2 and answers of length at most G.bound (C + Ī»).

The argument is the criterion's (Cost.compressibility_criterion_levels) at the fixed level C, along the levels C, 2 ^ C, 2 ^ (2 ^ C), … of the recursion (lv): the two classes are A n, a value-1 PCC strategy at level n with answers of length at most n ^ Ī», and B n, value at most 1/2 there; GapCompression.completeness and soundness carry A (2 ^ n) → A n and B (2 ^ n) → B n at every level where neither of the decider's first two branches fires (lem:dhalt-values, the acceptance agreement with the compressed verifier); branch 1 puts a level in A outright and branch 2 in B; and the search halts exactly when the start level has value above 1/2 (exists_semL, tabL_value), which is what rules the search out below the level where M halts, and rules the start level out of B's complement when M does not.

The level the reduction outputs: max Cā‚€ 2, so that the time clauses of IsBounded apply there.

Equations
Instances For

    The levels of the recursion started at C: C, 2 ^ C, 2 ^ (2 ^ C), ….

    Equations
    Instances For
      @[simp]
      @[simp]
      theorem MIPRE.Halting.lv_succ (G : GapCompression) (j : ā„•) :
      lv G (j + 1) = 2 ^ lv G j
      theorem MIPRE.Halting.lv_mono (G : GapCompression) {j k : ā„•} (h : j ≤ k) :
      lv G j ≤ lv G k
      @[reducible, inline]

      The compressed verifier of š’±^halt, the same at every level.

      Equations
      Instances For

        The first branch fires: M halts within Nat.size n.

        Equations
        Instances For

          The second branch fires: the search halts within Nat.size n.

          Equations
          Instances For
            theorem MIPRE.Halting.branch1_of_halts {M : Cost.Prog} (hM : Cost.Halts M Cost.Data.nil) :
            ∃ (k : ā„•), āˆ€ (n : ā„•), k ≤ n.size → branch1 M n

            The acceptance of š’±^halt at a level, by branch #

            theorem MIPRE.Halting.accepts_diag_of_branch1 (G : GapCompression) (U : Cost.UniversalMachine) (UT : Cost.ClockedUniversalMachine) {S' : Cost.Prog} (M : Cost.Prog) (lam : ā„•) {n : ā„•} (h1 : branch1 M n) (x y : (Vhalt G U UT S' M lam).Questions n) :
            (Vhalt G U UT S' M lam).decider.Accepts n (CL.toBits x) (CL.toBits y) [] []
            theorem MIPRE.Halting.rejects_all_of_branch2 (G : GapCompression) (U : Cost.UniversalMachine) (UT : Cost.ClockedUniversalMachine) {S' : Cost.Prog} (M : Cost.Prog) (lam : ā„•) {n : ā„•} (h1 : ¬branch1 M n) (h2 : branch2 G U UT S' M lam n) (x y a b : Cost.BitStr) :
            ¬(Vhalt G U UT S' M lam).decider.Accepts n x y a b
            theorem MIPRE.Halting.accepts_iff_W (G : GapCompression) (U : Cost.UniversalMachine) (UT : Cost.ClockedUniversalMachine) {S' : Cost.Prog} (M : Cost.Prog) (lam : ā„•) {n : ā„•} (h1 : ¬branch1 M n) (h2 : ¬branch2 G U UT S' M lam n) (x y a b : Cost.BitStr) :
            (Vhalt G U UT S' M lam).decider.Accepts n x y a b ↔ (W G U UT S' M lam).decider.Accepts n x y a b
            theorem MIPRE.Halting.W_sampler (G : GapCompression) (U : Cost.UniversalMachine) (UT : Cost.ClockedUniversalMachine) {S' : Cost.Prog} (M : Cost.Prog) (lam : ā„•) :
            (W G U UT S' M lam).sampler = (Vhalt G U UT S' M lam).sampler

            Below the first branch, š’±^halt rejects every answer longer than the compressed bound.

            The two classes and the compression steps #

            The class A at level n: a value-1 PCC strategy with answers of length at most n ^ Ī».

            Equations
            Instances For

              The class B at level n: value at most 1/2 with answers of length at most n ^ Ī».

              Equations
              Instances For
                theorem MIPRE.Halting.A_of_branch1 (G : GapCompression) (U : Cost.UniversalMachine) (UT : Cost.ClockedUniversalMachine) {S' : Cost.Prog} (M : Cost.Prog) (lam : ā„•) {n : ā„•} (h1 : branch1 M n) :
                A G U UT S' M lam n
                theorem MIPRE.Halting.B_of_branch2 (G : GapCompression) (U : Cost.UniversalMachine) (UT : Cost.ClockedUniversalMachine) {S' : Cost.Prog} (M : Cost.Prog) (lam : ā„•) {n : ā„•} (h1 : ¬branch1 M n) (h2 : branch2 G U UT S' M lam n) :
                B G U UT S' M lam n
                theorem MIPRE.Halting.A_step (G : GapCompression) (U : Cost.UniversalMachine) (UT : Cost.ClockedUniversalMachine) {S' : Cost.Prog} (M : Cost.Prog) (lam : ā„•) (hb : (Vhalt G U UT S' M lam).IsBounded lam) {n : ā„•} (hn : C G ≤ n) (h1 : ¬branch1 M n) (h2 : ¬branch2 G U UT S' M lam n) (hA : A G U UT S' M lam (2 ^ n)) :
                (Vhalt G U UT S' M lam).HasPerfectPCC n (Polynomial.eval (n + lam) G.bound)

                Completeness carried down a level, where neither branch fires.

                theorem MIPRE.Halting.A_step' (G : GapCompression) (U : Cost.UniversalMachine) (UT : Cost.ClockedUniversalMachine) {S' : Cost.Prog} (M : Cost.Prog) (lam : ā„•) (hb : (Vhalt G U UT S' M lam).IsBounded lam) (hpoly : āˆ€ (n : ā„•), 2 ≤ n → Polynomial.eval (n + lam) G.bound ≤ n ^ lam) {n : ā„•} (hn : C G ≤ n) (h1 : ¬branch1 M n) (h2 : ¬branch2 G U UT S' M lam n) (hA : A G U UT S' M lam (2 ^ n)) :
                A G U UT S' M lam n
                theorem MIPRE.Halting.B_step (G : GapCompression) (U : Cost.UniversalMachine) (UT : Cost.ClockedUniversalMachine) {S' : Cost.Prog} (M : Cost.Prog) (lam : ā„•) (hb : (Vhalt G U UT S' M lam).IsBounded lam) (hpoly : āˆ€ (n : ā„•), 2 ≤ n → Polynomial.eval (n + lam) G.bound ≤ n ^ lam) {n : ā„•} (hn : C G ≤ n) (h1 : ¬branch1 M n) (h2 : ¬branch2 G U UT S' M lam n) (hB : B G U UT S' M lam (2 ^ n)) :
                B G U UT S' M lam n

                Soundness carried down a level, where neither branch fires.

                The search and the start level #

                theorem MIPRE.Halting.halts_search_iff (G : GapCompression) (U : Cost.UniversalMachine) (UT : Cost.ClockedUniversalMachine) {S' : Cost.Prog} (hS' : Cost.Prog.WellScoped 1 S') (hsem : āˆ€ (x : Cost.BitStr), Cost.Halts S' (Cost.encode x) ↔ 1 / 2 < quantumValue (tabL G U x (C G)).game) (M : Cost.Prog) (lam : ā„•) (hb : (Vhalt G U UT S' M lam).IsBounded lam) :
                Cost.Halts (searchP S' lam (dec G U UT S' M lam)) Cost.Data.nil ↔ 1 / 2 < (Vhalt G U UT S' M lam).valStar (C G) (Polynomial.eval (C G + lam) G.bound)

                The search halts exactly when the start level has value above 1/2.

                theorem MIPRE.Halting.branch2_of_lt (G : GapCompression) (U : Cost.UniversalMachine) (UT : Cost.ClockedUniversalMachine) {S' : Cost.Prog} (hS' : Cost.Prog.WellScoped 1 S') (hsem : āˆ€ (x : Cost.BitStr), Cost.Halts S' (Cost.encode x) ↔ 1 / 2 < quantumValue (tabL G U x (C G)).game) (M : Cost.Prog) (lam : ā„•) (hb : (Vhalt G U UT S' M lam).IsBounded lam) (h : 1 / 2 < (Vhalt G U UT S' M lam).valStar (C G) (Polynomial.eval (C G + lam) G.bound)) :
                ∃ (k : ā„•), āˆ€ (n : ā„•), k ≤ n.size → branch2 G U UT S' M lam n
                theorem MIPRE.Halting.lt_of_branch2 (G : GapCompression) (U : Cost.UniversalMachine) (UT : Cost.ClockedUniversalMachine) {S' : Cost.Prog} (hS' : Cost.Prog.WellScoped 1 S') (hsem : āˆ€ (x : Cost.BitStr), Cost.Halts S' (Cost.encode x) ↔ 1 / 2 < quantumValue (tabL G U x (C G)).game) (M : Cost.Prog) (lam : ā„•) (hb : (Vhalt G U UT S' M lam).IsBounded lam) {n : ā„•} (h2 : branch2 G U UT S' M lam n) :
                1 / 2 < (Vhalt G U UT S' M lam).valStar (C G) (Polynomial.eval (C G + lam) G.bound)
                theorem MIPRE.Halting.le_of_B_start (G : GapCompression) (U : Cost.UniversalMachine) (UT : Cost.ClockedUniversalMachine) {S' : Cost.Prog} (M : Cost.Prog) (lam : ā„•) (hpoly : āˆ€ (n : ā„•), 2 ≤ n → Polynomial.eval (n + lam) G.bound ≤ n ^ lam) (h1 : ¬branch1 M (C G)) (hB : B G U UT S' M lam (C G)) :
                (Vhalt G U UT S' M lam).valStar (C G) (Polynomial.eval (C G + lam) G.bound) ≤ 1 / 2

                The start level is in B only if its value is at most 1/2 — with the answer bound of the statement, once the first branch does not fire there.

                The two cases #

                theorem MIPRE.Halting.B_below (G : GapCompression) (U : Cost.UniversalMachine) (UT : Cost.ClockedUniversalMachine) {S' : Cost.Prog} (M : Cost.Prog) (lam : ā„•) (hb : (Vhalt G U UT S' M lam).IsBounded lam) (hpoly : āˆ€ (n : ā„•), 2 ≤ n → Polynomial.eval (n + lam) G.bound ≤ n ^ lam) (jā‚€ : ā„•) (hnot : ¬branch1 M (lv G jā‚€)) (hfire : branch2 G U UT S' M lam (lv G jā‚€)) (i j : ā„•) :
                j + i = jā‚€ → B G U UT S' M lam (lv G j)

                Below a level where the search fires while M has not halted, every level of the recursion is in B.

                theorem MIPRE.Halting.hasPerfectPCC_of_halts (G : GapCompression) (U : Cost.UniversalMachine) (UT : Cost.ClockedUniversalMachine) {S' : Cost.Prog} (hS' : Cost.Prog.WellScoped 1 S') (hsem : āˆ€ (x : Cost.BitStr), Cost.Halts S' (Cost.encode x) ↔ 1 / 2 < quantumValue (tabL G U x (C G)).game) (M : Cost.Prog) (lam : ā„•) (hb : (Vhalt G U UT S' M lam).IsBounded lam) (hpoly : āˆ€ (n : ā„•), 2 ≤ n → Polynomial.eval (n + lam) G.bound ≤ n ^ lam) (hM : Cost.Halts M Cost.Data.nil) :
                (Vhalt G U UT S' M lam).HasPerfectPCC (C G) (Polynomial.eval (C G + lam) G.bound)

                The halting case: š’±^halt has a value-1 PCC strategy at level C.

                theorem MIPRE.Halting.valStar_le_of_not_halts (G : GapCompression) (U : Cost.UniversalMachine) (UT : Cost.ClockedUniversalMachine) {S' : Cost.Prog} (hS' : Cost.Prog.WellScoped 1 S') (hsem : āˆ€ (x : Cost.BitStr), Cost.Halts S' (Cost.encode x) ↔ 1 / 2 < quantumValue (tabL G U x (C G)).game) (M : Cost.Prog) (lam : ā„•) (hb : (Vhalt G U UT S' M lam).IsBounded lam) (hpoly : āˆ€ (n : ā„•), 2 ≤ n → Polynomial.eval (n + lam) G.bound ≤ n ^ lam) (hM : ¬Cost.Halts M Cost.Data.nil) :
                (Vhalt G U UT S' M lam).valStar (C G) (Polynomial.eval (C G + lam) G.bound) ≤ 1 / 2

                The non-halting case: val*(š’±^halt_C) ≤ 1/2.