Documentation

DescriptiveComplexity.FixedPointPartialMachine

PSPACE is contained in FO(≤, PFP) #

The hard half of the capture theorem FO(≤, PFP) = PSPACE, by iterating the PSPACE-complete deterministic machine problem: a partial fixed-point definition DescriptiveComplexity.SpaceTM.mPfp whose block holds one machine configuration – the block of the SO(TC) membership proof of DescriptiveComplexity.Problems.Machine.Space – and whose step formulas advance it:

A machine that loops forever diverges the iteration, and under the convergence-requiring semantics of DescriptiveComplexity.FixedPointPartial that alone makes the definition false – no divergence detection, no counter. The output sentence checks well-formedness and determinism (conditions on the instance only) and reads acceptance off the stable configuration (DescriptiveComplexity.dtmAcceptSpace_pfpDefinable).

Whence the capture: every PSPACE problem reduces to the machine problem by a relativized ordered reduction (DescriptiveComplexity.le_dtmAcceptSpace_of_mem_PSPACE), and FO(≤, PFP) definability crosses such reductions (DescriptiveComplexity.PFPDefinable.of_relOrderedReduction), so DescriptiveComplexity.pfpDefinable_of_mem_PSPACE and, with the converse inclusion of DescriptiveComplexity.FixedPointPartialSpace, the capture theorem DescriptiveComplexity.pfpDefinable_iff_mem_PSPACE.

Formula builders #

In the parameterized style of DescriptiveComplexity.Problems.Machine.Space: each builder takes the relation symbols it reads, so realization lemmas are stated over RelMap and specialize to any expansion.

Dependency graph
noncomputable def DescriptiveComplexity.SpaceTM.someArgF {L' : FirstOrder.Language} {γ : Type} (r : L'.Relations 2) (x : γ) :
L'.Formula γ

The binary relation holds of x and some element.

Equations
Instances For
    Dependency graph
    noncomputable def DescriptiveComplexity.SpaceTM.applF {L' : FirstOrder.Language} {γ : Type} (tr : L'.Relations 1) (src rd : L'.Relations 2) (s h : L'.Relations 1) (t : L'.Relations 2) (τ : γ) :
    L'.Formula γ

    τ is an applicable transition: a transition whose source is the marked state and whose read symbol is the one held by the marked cell.

    Equations
    • One or more equations did not get rendered due to their size.
    Instances For
      Dependency graph
      noncomputable def DescriptiveComplexity.SpaceTM.moveToF {L' : FirstOrder.Language} {γ : Type} (right : L'.Relations 1) (le : L'.Relations 2) (posn h : L'.Relations 1) (τ p' : γ) :
      L'.Formula γ

      The head can move from the marked cell to p', in the direction the transition names.

      Equations
      • One or more equations did not get rendered due to their size.
      Instances For
        Dependency graph
        noncomputable def DescriptiveComplexity.SpaceTM.goF {L' : FirstOrder.Language} {γ : Type} (tr : L'.Relations 1) (src rd dst wr : L'.Relations 2) (s h : L'.Relations 1) (t : L'.Relations 2) (acc right : L'.Relations 1) (le : L'.Relations 2) (posn : L'.Relations 1) :
        L'.Formula γ

        The machine takes a step: no accepting mark, and some applicable transition with a destination, a written symbol, and a position to move to.

        Equations
        • One or more equations did not get rendered due to their size.
        Instances For
          Dependency graph
          noncomputable def DescriptiveComplexity.SpaceTM.initTapeAtF {L' : FirstOrder.Language} {γ : Type} (inp : L'.Relations 2) (blank : L'.Relations 1) (x y : γ) :
          L'.Formula γ

          The cell initially holds this symbol: its input symbol, or the blank when no input is given for it.

          Equations
          • One or more equations did not get rendered due to their size.
          Instances For
            Dependency graph
            noncomputable def DescriptiveComplexity.SpaceTM.minPosAtF {L' : FirstOrder.Language} {γ : Type} (le : L'.Relations 2) (posn : L'.Relations 1) (x : γ) :
            L'.Formula γ

            x is the lowest position.

            Equations
            • One or more equations did not get rendered due to their size.
            Instances For
              Dependency graph
              Dependency graph
              @[simp]
              theorem DescriptiveComplexity.SpaceTM.realize_someArgF {L' : FirstOrder.Language} {M : Type} [L'.Structure M] {γ : Type} {v : γM} (r : L'.Relations 2) (x : γ) :
              Dependency graph
              Dependency graph
              @[simp]
              theorem DescriptiveComplexity.SpaceTM.realize_moveToF {L' : FirstOrder.Language} {M : Type} [L'.Structure M] {γ : Type} {v : γM} (right : L'.Relations 1) (le : L'.Relations 2) (posn h : L'.Relations 1) (τ p' : γ) :
              Dependency graph
              Dependency graph
              @[simp]
              theorem DescriptiveComplexity.SpaceTM.realize_initTapeAtF {L' : FirstOrder.Language} {M : Type} [L'.Structure M] {γ : Type} {v : γM} (inp : L'.Relations 2) (blank : L'.Relations 1) (x y : γ) :
              Dependency graph
              @[simp]
              theorem DescriptiveComplexity.SpaceTM.realize_minPosAtF {L' : FirstOrder.Language} {M : Type} [L'.Structure M] {γ : Type} {v : γM} (le : L'.Relations 2) (posn : L'.Relations 1) (x : γ) :
              (minPosAtF le posn x).Realize v MinPos (fun (a b : M) => FirstOrder.Language.Structure.RelMap le ![a, b]) (fun (a : M) => FirstOrder.Language.Structure.RelMap posn ![a]) (v x)
              Dependency graph
              noncomputable def DescriptiveComplexity.SpaceTM.writeNewF {L' : FirstOrder.Language} {γ : Type} (tr : L'.Relations 1) (src rd : L'.Relations 2) (s h : L'.Relations 1) (t wr : L'.Relations 2) (y : γ) :
              L'.Formula γ

              The transition applies, with a destination, a written symbol, and this new symbol written in the marked cell.

              Equations
              • One or more equations did not get rendered due to their size.
              Instances For
                Dependency graph
                noncomputable def DescriptiveComplexity.SpaceTM.dstNewF {L' : FirstOrder.Language} {γ : Type} (tr : L'.Relations 1) (src rd : L'.Relations 2) (s h : L'.Relations 1) (t dst : L'.Relations 2) (y : γ) :
                L'.Formula γ

                The transition applies and moves to this new state.

                Equations
                • One or more equations did not get rendered due to their size.
                Instances For
                  Dependency graph
                  noncomputable def DescriptiveComplexity.SpaceTM.headNewF {L' : FirstOrder.Language} {γ : Type} (tr : L'.Relations 1) (src rd : L'.Relations 2) (s h : L'.Relations 1) (t : L'.Relations 2) (right : L'.Relations 1) (le : L'.Relations 2) (posn : L'.Relations 1) (y : γ) :
                  L'.Formula γ

                  The transition applies and moves the head to this new position.

                  Equations
                  • One or more equations did not get rendered due to their size.
                  Instances For
                    Dependency graph
                    Dependency graph
                    Dependency graph
                    @[simp]
                    Dependency graph

                    The iterated definition and its semantics #

                    The state mark is empty: how the iteration recognizes the not-yet-started assignment, which no configuration resembles.

                    Equations
                    Instances For
                      Dependency graph

                      The transition applies in the marked state, reading the marked cell.

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

                        The machine takes a step from this assignment: no accepting mark, and some applicable transition with a destination, a written symbol and a position to move to.

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

                          The initial assignment: start states, lowest positions, the initial tape. On a well-formed deterministic instance with a start state this is a configuration – the initial one.

                          Equations
                          Instances For
                            Dependency graph

                            One application of the step formulas, semantically: load the initial configuration from the empty assignment, take the machine step when one is available and the state is not accepting, stutter otherwise.

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

                              The step formulas #

                              Dependency graph

                              The step condition, at the machine's symbols.

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

                                The step formula of the tape variable.

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

                                  The step formula of the state variable.

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

                                    The step formula of the head variable.

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

                                      The machine iteration: one configuration in the block, one machine step per stage, stuttering on halting configurations; the output checks the instance and reads acceptance off the stable configuration.

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

                                        The step formulas mean the semantic step #

                                        Dependency graph
                                        Dependency graph
                                        Dependency graph
                                        Dependency graph
                                        Dependency graph

                                        One application of the step formulas is the semantic step.

                                        Dependency graph

                                        The iteration follows the run #

                                        Dependency graph
                                        Dependency graph

                                        From an empty state mark, one step loads the initial assignment.

                                        Dependency graph

                                        On a configuration from which the machine takes no step, the iteration stutters.

                                        Dependency graph

                                        On an accepting configuration, the iteration stutters.

                                        Dependency graph

                                        A configuration from which the step condition fires can take a machine step.

                                        Dependency graph

                                        On a non-accepting configuration that steps, the iteration takes the machine step.

                                        Dependency graph

                                        The initial assignment of a well-formed deterministic instance with an initial configuration is that configuration.

                                        Dependency graph

                                        The first stage of the iteration is the initial assignment.

                                        Dependency graph
                                        theorem DescriptiveComplexity.SpaceTM.partStage_run {A : Type} [FirstOrder.Language.turing.Structure A] [LinearOrder A] (hwf : (tmData A).WellFormed) (hdet : (tmData A).Deterministic) {c₀ : Config A} (hinit : (tmData A).IsInit c₀) (n : ) (c : Config A) :
                                        (tmData A).StepsIn n c₀ c(∀ k < n, ∀ (e : Config A), (tmData A).StepsIn k c₀ e¬(tmData A).Acc e.state)mPfp.partStage A (n + 1) = cfgAssign c

                                        The stages follow the run: as long as no accepting configuration has been reached, stage n + 1 is the n-th configuration of the run.

                                        Dependency graph

                                        The run reaches a configuration in some number of steps.

                                        Dependency graph
                                        Dependency graph

                                        A well-formed deterministic accepting instance makes the iteration converge with an accepting output: run to the first accepting configuration and stutter there.

                                        Dependency graph

                                        A converging accepting iteration means the instance is well-formed, deterministic and accepting: the stages only ever hold the empty assignment, the initial assignment, or a configuration of the run.

                                        Dependency graph

                                        The capture theorem #

                                        The deterministic space-bounded machine problem is FO(≤, PFP) definable: iterate the machine, stuttering on halting configurations.

                                        Dependency graph

                                        PSPACE is contained in FO(≤, PFP): reduce to the machine problem and pull the iteration back through the relativized reduction.

                                        Dependency graph

                                        The capture theorem FO(≤, PFP) = PSPACE (Abiteboul–Vianu 1989; Ebbinghaus–Flum 1995, ch. 7): a problem is FO(≤, PFP) definable exactly when it is in PSPACE.

                                        Dependency graph

                                        The capture theorem, logic to logic: FO(≤, PFP) and SO(TC) define the same problems.

                                        Dependency graph