Documentation

CslibFrontier.Computability.PolyTime.CSP.Edge.Solver.Lifting

Finite-buffer arbitrary-comparison lifting #

Implement the first-connector, shortest-exit and actual-arm scans of the existing whole-instance lifting construction. The comparison may change every surviving outside row. The actual native two-phase augmentation routine supplies its walk; all subsequent scans use original incidence records, binary global positions and list-funded prefix lengths.

The mathematical source is Lemmas 31 and 44 of [KKR18], arXiv:1602.03124v6, printed pp. 14 and 20–22. Finite representation bookkeeping is original.

Scope of one original positional record, with a bounded list default.

Instances For

    Record of a surviving original port in the actual contracted body. Its constraint position and original binary name are retained; its argument position is its outside-list rank.

    Instances For

      Invert surviving ports by the original finite incidence scan, preserving source tie order. The fallback is an actual cycle port on certified inputs; malformed raw positions remain total.

      Instances For

        Restore the actual outside prefix, retaining its original start and step order.

        Instances For

          Actual feasible original exits from one prefix, in source scan order. The original outside port must be unused; pair feasibility is tested on the prefix's current finite buffer.

          Instances For

            First feasible exit, with a unary number of whole prefix steps and binary port positions.

            • length : ℕ

              Actual prefix length; this clock is funded by the supplied walk's step list.

            • input : ℕ

              Original outside port's binary global position.

            • output : ℕ

              Original cycle port's binary global position.

            Instances For
              @[reducible, inline]

              The tuple of the fields of encExitCode.

              Instances For
                theorem Cslib.Complexity.CSP.EdgeSolver.NativeLifting.encExitCode_mk_inO {γ : Type} {encIn : γ ↪ List Bool} {x0 T0 S0 x1 T1 S1 x2 T2 S2 : γ → ℕ} (h0 : Turing.MultiTapeTM.ComputableInO x0 encIn Turing.MultiTapeTM.encUnary T0 S0) (h1 : Turing.MultiTapeTM.ComputableInO x1 encIn Turing.MultiTapeTM.encNat T1 S1) (h2 : Turing.MultiTapeTM.ComputableInO x2 encIn Turing.MultiTapeTM.encNat T2 S2) :
                Turing.MultiTapeTM.ComputableInO (fun (x : γ) => { length := x0 x, input := x1 x, output := x2 x }) encIn encExitCode (fun (x : γ) => T0 x + (T1 x + T2 x)) fun (x : γ) => S0 x + (S1 x + S2 x)
                theorem Cslib.Complexity.CSP.EdgeSolver.NativeLifting.encExitCode_length_budget {γ✝ : Type} {encIn✝ : γ✝ ↪ List Bool} {S✝ : γ✝ → ℕ} {g✝ : γ✝ → ExitCode} :
                theorem Cslib.Complexity.CSP.EdgeSolver.NativeLifting.encExitCode_output_budget {γ✝ : Type} {encIn✝ : γ✝ ↪ List Bool} {S✝ : γ✝ → ℕ} {g✝ : γ✝ → ExitCode} :
                theorem Cslib.Complexity.CSP.EdgeSolver.NativeLifting.encExitCode_mk_budget {γ : Type} {encIn : γ ↪ List Bool} {budget x0 x1 x2 : γ → ℕ} (h0 : Turing.MultiTapeTM.ComputableInSpace x0 encIn Turing.MultiTapeTM.encUnary budget) (h1 : Turing.MultiTapeTM.ComputableInSpace x1 encIn Turing.MultiTapeTM.encNat budget) (h2 : Turing.MultiTapeTM.ComputableInSpace x2 encIn Turing.MultiTapeTM.encNat budget) :
                Turing.MultiTapeTM.ComputableInSpace (fun (x : γ) => { length := x0 x, input := x1 x, output := x2 x }) encIn encExitCode budget
                theorem Cslib.Complexity.CSP.EdgeSolver.NativeLifting.encExitCode_input_budget {γ✝ : Type} {encIn✝ : γ✝ ↪ List Bool} {S✝ : γ✝ → ℕ} {g✝ : γ✝ → ExitCode} :

                Unary prefix length is framed, then the binary outside position is framed, then the binary cycle position.

                Instances For

                  Find the earliest whole prefix with a feasible original exit, then its first actual pair.

                  Instances For

                    Two actual arms at every matching original constraint, in original cycle-step order. Repeated original constraints are retained as separate copied steps.

                    Instances For

                      Choose the first actual valid arm against the already changed outside prefix.

                      Instances For

                        Perform the first feasible outside prefix and the first feasible actual original arm.

                        Instances For

                          Restore a connector-free augmentation directly, or restore the prefix before its first connector and execute the actual original exit/arm construction.

                          Instances For

                            Actual native comparison augmentation followed by whole-instance lifting. Every width check is supplied internally by the native augmentation routine.

                            Instances For