Documentation

Pdl.Interpolation.FinePath

Fine paths in local tableaux and in tableaux #

This file collects helper definitions and lemmas that are used in Pdl.InterpolationCluster to define interpolants for proper clusters (Section 9 of the paper).

The two main definitions are LocalPathIn, for paths to arbitrary (also intermediate) nodes of a LocalTableau, and FinePathIn, for the nodes of a whole Tableau in the fine sense, i.e. including those nodes inside a local tableau that a loc step jumps over.

Paths inside a local tableau #

The Tableau type applies a whole LocalTableau in one loc step, and thus the PathIn type — and with it the edge relation ⋖_ and the clusters defined via — "jumps over" the intermediate nodes inside a local tableau. For the quasi-tableau in Definition 9.8 we need those intermediate nodes, because it is only there that each rule application is either a left or a right rule.

We therefore first define LocalPathIn, the analogue of PathIn for local tableaux, in the same spirit as LocalTableau.paths which is used for the completeness proof. Note that in contrast to LocalTableau.paths we here keep the nodes themselves and not only the sequents labelling them, so that we can still connect them to PathIn.

inductive LocalPathIn {X : Sequent} :

A path inside a LocalTableau, pointing at an arbitrary node of it — in contrast to LocalTableau.paths which only goes to the end nodes.

Instances For
    def instDecidableEqLocalPathIn.decEq {X✝ : Sequent} {a✝ : LocalTableau X✝} (x✝ x✝¹ : LocalPathIn a✝) :
    Decidable (x✝ = x✝¹)
    Equations
    Instances For

      The sequent at the node a local path is pointing at.

      Equations
      Instances For

        The local tableau rooted at the node a local path is pointing at.

        Equations
        Instances For

          Is this the empty local path, i.e. does it point at the root of the local tableau?

          Equations
          Instances For

            Is a local rule applied at the root of this local tableau?

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

              A local path is internal iff a local rule is applied at the node it points at, i.e. iff that node is not a leaf of the local tableau.

              Equations
              Instances For

                If the local path points at a leaf then this gives the end node it reaches.

                Equations
                Instances For
                  theorem LocalPathIn.last_of_endNodeAt? {X : Sequent} {lt : LocalTableau X} (lp : LocalPathIn lt) {Yh : (endNodesOf lt)} (h : lp.endNodeAt? = some Yh) :
                  lp.last = Yh

                  The children of the node a local path points at, inside the same local tableau.

                  Equations
                  Instances For

                    The sequents labelling the children of the root of a local tableau.

                    Equations
                    Instances For
                      noncomputable def LocalPathIn.endNodesBelow {X : Sequent} {lt : LocalTableau X} (lp : LocalPathIn lt) :

                      The end nodes of the whole local tableau that are below a given local path.

                      Equations
                      Instances For
                        theorem LocalPathIn.endNodesBelow_eq_of_endNodeAt? {X : Sequent} {lt : LocalTableau X} (lp : LocalPathIn lt) {Yh : (endNodesOf lt)} :
                        lp.endNodeAt? = some YhYh'lp.endNodesBelow, Yh' = Yh

                        A leaf of a local tableau is the only end node below itself.

                        theorem LocalPathIn.exists_child_endNodesBelow {X : Sequent} {lt : LocalTableau X} (lp : LocalPathIn lt) :
                        lp.isInternalYhlp.endNodesBelow, clp.children, Yh c.endNodesBelow

                        If an end node is below an internal node of a local tableau, then it is below one of the children of that node.

                        noncomputable def internalLocalPaths {X : Sequent} (lt : LocalTableau X) :

                        All internal nodes of a local tableau, i.e. those where a local rule is applied. Compare allPaths for PathIn.

                        Equations
                        Instances For

                          Fine paths: all nodes of a tableau #

                          A FinePathIn points at a node of the tableau in the fine sense: it may also point at an intermediate node inside a local tableau. Note that the end nodes of a local tableau are not fine nodes of their own: in the Tableau type they are the roots of the tableaux given by next, and that is where they show up here.

                          Hence a fine node is either

                          inductive FinePathIn {Hist : History} {X : Sequent} :
                          Tableau Hist XType

                          A path in a tableau that may also stop at an intermediate node inside a LocalTableau.

                          Instances For
                            @[instance_reducible]
                            instance instDecidableEqFinePathIn {Hist✝ : History} {X✝ : Sequent} {a✝ : Tableau Hist✝ X✝} :
                            Equations
                            def rootFine {H : History} {X : Sequent} (tab : Tableau H X) :

                            The fine path pointing at the root of a tableau.

                            Equations
                            Instances For
                              def FinePathIn.label {Hist : History} {X : Sequent} {tab : Tableau Hist X} :

                              The sequent at the node a fine path points at, i.e. Λ(t) for fine nodes t.

                              Equations
                              Instances For
                                def FinePathIn.base {Hist : History} {X : Sequent} {tab : Tableau Hist X} :
                                FinePathIn tabPathIn tab

                                The PathIn node in whose local tableau the given fine node lies.

                                Equations
                                Instances For
                                  def FinePathIn.children {Hist : History} {X : Sequent} {tab : Tableau Hist X} :

                                  The children of a fine node. Note that a child of an internal node of a local tableau may be a node of the tableau in the coarse PathIn sense, namely when it is an end node of that local tableau.

                                  Equations
                                  Instances For
                                    def PathIn.toFine {Hist : History} {X : Sequent} {tab : Tableau Hist X} :
                                    PathIn tabFinePathIn tab

                                    Any node in the coarse sense is also a node in the fine sense.

                                    Equations
                                    Instances For
                                      noncomputable def allFinePaths {H : History} {X : Sequent} (tab : Tableau H X) :

                                      All fine nodes of a tableau. Compare allPaths.

                                      Equations
                                      Instances For
                                        @[simp]
                                        theorem label_rootFine {H : History} {X : Sequent} (tab : Tableau H X) :
                                        (rootFine tab).label = X
                                        @[simp]
                                        theorem base_rootFine {H : History} {X : Sequent} (tab : Tableau H X) :
                                        @[simp]
                                        theorem PathIn.base_toFine {H : History} {X : Sequent} {tab : Tableau H X} (p : PathIn tab) :
                                        @[simp]
                                        theorem PathIn.label_toFine {H : History} {X : Sequent} {tab : Tableau H X} (p : PathIn tab) :
                                        theorem FinePathIn.mem_allFinePaths {H : History} {X : Sequent} {tab : Tableau H X} (f : FinePathIn tab) :
                                        theorem FinePathIn.base_of_mem_children {H : History} {X : Sequent} {tab : Tableau H X} (f g : FinePathIn tab) :
                                        g f.childreng.base = f.base f.base ⋖_ g.base

                                        Fine children either stay at the same node in the coarse sense, or they are a child of it. This connects the fine children with the edge relation ⋖_.

                                        theorem FinePathIn.map_label_children_inLoc {Hist : History} {X : Sequent} {nrep : ¬flprep Hist X} {nbas : ¬X.basic} {lt : LocalTableau X} {next : (Y : Sequent) → Y endNodesOf ltTableau (X :: Hist) Y} (lp : LocalPathIn lt) (h : lp.isInternal) :
                                        def FinePathIn.lra? {H : History} {X : Sequent} {tab : Tableau H X} :

                                        The local rule applied at a fine node, if any.

                                        Equations
                                        Instances For
                                          theorem FinePathIn.lra?_spec {H : History} {X : Sequent} {tab : Tableau H X} (f : FinePathIn tab) {lra : LocalRuleApp} (h : f.lra? = some lra) :

                                          If a local rule is applied at a fine node then that node is labelled with the premise and its children are labelled with the conclusions of that rule.

                                          theorem FinePathIn.locally_sound {H : History} {X : Sequent} {tab : Tableau H X} (f : FinePathIn tab) {lra : LocalRuleApp} (h : f.lra? = some lra) {W : Type} (M : KripkeModel W) (w : W) :
                                          (M, w) f.label gf.children, (M, w) g.label

                                          Local soundness and invertibility at the fine level: whenever a local rule is applied at a fine node, its label is satisfied exactly if the label of one of its children is. This is the property of the fine tableau that makes the quasi-tableau work.

                                          Left and right rules #

                                          At the fine level each rule application is a left rule or a right rule or neither (the latter for closing rules and loaded-path repeats), but never both. This is what Lemma 9.7 (a) is about, and it is the reason why we needed the fine nodes: on the Tableau level a loc step is in general a mix of left and right rules.

                                          Is this a local rule applied to the right component?

                                          Equations
                                          Instances For

                                            Is this a local rule applied to the left component?

                                            Equations
                                            Instances For
                                              Equations
                                              Instances For
                                                Equations
                                                Instances For

                                                  The (M), (L+) and (L-) rules acting on the right component.

                                                  Equations
                                                  Instances For
                                                    def PdlRule.isLeftRule {X Y : Sequent} :
                                                    PdlRule X YBool

                                                    The (M), (L+) and (L-) rules acting on the left component.

                                                    Equations
                                                    Instances For
                                                      def FinePathIn.usesRightRule {H : History} {X : Sequent} {tab : Tableau H X} :

                                                      Is a right rule applied at this fine node?

                                                      Equations
                                                      Instances For
                                                        def FinePathIn.usesLeftRule {H : History} {X : Sequent} {tab : Tableau H X} :

                                                        Is a left rule applied at this fine node?

                                                        Equations
                                                        Instances For

                                                          No node uses a left and a right rule at the same time.

                                                          A node where a right rule is applied is not a loaded-path repeat, and neither is the coarse node it belongs to.

                                                          def FinePathIn.atBigRoot {H : History} {X : Sequent} {tab : Tableau H X} :

                                                          Is this fine node also a node in the coarse sense, i.e. the root of the local tableau at its base?

                                                          Equations
                                                          Instances For
                                                            @[simp]
                                                            theorem atBigRoot_rootFine {H : History} {X : Sequent} (tab : Tableau H X) :
                                                            @[simp]
                                                            theorem PathIn.atBigRoot_toFine {H : History} {X : Sequent} {tab : Tableau H X} (p : PathIn tab) :

                                                            The labels of those end nodes of the local tableau at f.base that are below f. These are the labels of the children of f.base that can be reached from f.

                                                            Equations
                                                            Instances For
                                                              noncomputable def FinePathIn.coarseChildrenBelow {H : History} {X : Sequent} {tab : Tableau H X} :
                                                              FinePathIn tabList (PathIn tab)

                                                              The children of f.base in the coarse sense that are below the fine node f. Note that when f is a coarse node itself, i.e. f.atBigRoot, then these are all children of f.base, and that they get further restricted the deeper f sits inside the local tableau at f.base.

                                                              Equations
                                                              Instances For

                                                                If a coarse child q is below the fine node f, then f has a fine child g that is either still at the same coarse node and has q below it, or g is q.

                                                                theorem FinePathIn.eq_toFine_base_of_atBigRoot {H : History} {X : Sequent} {tab : Tableau H X} (f : FinePathIn tab) (h : f.atBigRoot = true) :

                                                                A fine node that is a coarse node is the image of that coarse node under toFine.

                                                                theorem PathIn.mem_coarseChildrenBelow_toFine {H : History} {X : Sequent} {tab : Tableau H X} (p q : PathIn tab) :

                                                                All children of a coarse node are below it in the fine sense. This is the converse of FinePathIn.base_of_mem_children for coarse nodes.

                                                                The right component of a sequent, again as a sequent but with empty left component. This is Λ₂ from the paper; we use it to label the nodes of the quasi-tableau.

                                                                Equations
                                                                Instances For

                                                                  Well-founded descent for fine paths #

                                                                  The children of a fine node (FinePathIn.children) are not structurally smaller than the node itself: a child of an internal node of a local tableau is again a path in the same local tableau, and a child of the last internal node is a FinePathIn.loc step, hence even structurally bigger. So there is no induction principle for FinePathIn that follows the child relation for free.

                                                                  Below we provide one, in the same way as PathIn.strong_upwards_inductionOn is obtained from flipEdge.wellFounded for the coarse PathIn nodes: we equip fine paths with a FinePathIn.length, bound it by a size measure Tableau.fineSize of the tableau, and conclude that there is no infinite chain of fine children — the child relation fineEdge has a well-founded flip. From that we get

                                                                  Dually, FinePathIn.descent states the descent principle in the contrapositive form in which it is used: if a property holds somewhere and always propagates to some child, then it holds at a node without children.

                                                                  A length for local paths #

                                                                  The number of steps of a local path.

                                                                  Equations
                                                                  Instances For
                                                                    noncomputable def LocalTableau.nodeCount {X : Sequent} :

                                                                    The number of nodes of a local tableau.

                                                                    Equations
                                                                    Instances For
                                                                      theorem LocalPathIn.length_lt_of_mem_children {X : Sequent} {lt : LocalTableau X} (lp lp' : LocalPathIn lt) :
                                                                      lp' lp.childrenlp.length < lp'.length

                                                                      Going to a child inside a local tableau increases the length.

                                                                      A length for fine paths #

                                                                      noncomputable def Tableau.fineSize {H : History} {X : Sequent} :
                                                                      Tableau H X

                                                                      A size measure for tableaux that also counts the intermediate nodes of the local tableaux, i.e. an upper bound for the length of any FinePathIn.

                                                                      Equations
                                                                      Instances For
                                                                        noncomputable def FinePathIn.length {H : History} {X : Sequent} {tab : Tableau H X} :
                                                                        FinePathIn tab

                                                                        The number of steps of a fine path, where a whole local tableau counts with its LocalTableau.nodeCount so that leaving it strictly increases the length.

                                                                        Equations
                                                                        Instances For
                                                                          theorem FinePathIn.length_lt_fineSize {H : History} {X : Sequent} {tab : Tableau H X} (f : FinePathIn tab) :
                                                                          theorem FinePathIn.length_lt_of_mem_children {H : History} {X : Sequent} {tab : Tableau H X} (f g : FinePathIn tab) :
                                                                          g f.childrenf.length < g.length

                                                                          Going to a fine child strictly increases the length of a fine path.

                                                                          The child relation on fine nodes and its well-founded flip #

                                                                          def fineEdge {H : History} {X : Sequent} {tab : Tableau H X} (f g : FinePathIn tab) :

                                                                          The child relation on fine nodes, the fine analogue of edge.

                                                                          Equations
                                                                          Instances For

                                                                            The child relation on fine nodes, the fine analogue of edge.

                                                                            Equations
                                                                            Instances For
                                                                              theorem fineEdge_then_length_lt {H : History} {X : Sequent} {tab : Tableau H X} {f g : FinePathIn tab} (h : f ⋖f g) :

                                                                              The flipped child relation on fine nodes is well-founded. Compare flipEdge.wellFounded.

                                                                              The induction principles #

                                                                              theorem FinePathIn.edge_upwards_inductionOn {H : History} {X : Sequent} {tab : Tableau H X} {motive : FinePathIn tabProp} (up : ∀ {u : FinePathIn tab}, (∀ {s : FinePathIn tab}, u ⋖f smotive s)motive u) (t : FinePathIn tab) :
                                                                              motive t

                                                                              Induction on fine nodes going from the leaves (= childless fine nodes) to the root. Compare PathIn.edge_upwards_inductionOn.

                                                                              theorem FinePathIn.strong_upwards_inductionOn {H : History} {X : Sequent} {tab : Tableau H X} {motive : FinePathIn tabProp} (ups : ∀ {u : FinePathIn tab}, (∀ {s : FinePathIn tab}, Relation.TransGen fineEdge u smotive s)motive u) (t : FinePathIn tab) :
                                                                              motive t

                                                                              Strong induction on fine nodes going from the leaves to the root: the motive may be assumed at all fine descendants. Compare PathIn.strong_upwards_inductionOn.

                                                                              theorem FinePathIn.descent {H : History} {X : Sequent} {tab : Tableau H X} {P : FinePathIn tabProp} (down : ∀ (u : FinePathIn tab), P uu.children gu.children, P g) (t : FinePathIn tab) (ht : P t) :
                                                                              ∃ (u : FinePathIn tab), P u u.children =

                                                                              The descent principle for fine nodes: if a property holds at some fine node and, at every fine node where it holds and which has a child, it also holds at some child, then it holds at some childless fine node.

                                                                              This is the form in which the well-foundedness is used when following a path downwards in the fine sense, cf. Lemma 9.7 (d) of the paper.

                                                                              theorem FinePathIn.strong_descent {H : History} {X : Sequent} {tab : Tableau H X} {P : FinePathIn tabProp} (down : ∀ (u : FinePathIn tab), P uu.children ∃ (g : FinePathIn tab), Relation.TransGen fineEdge u g P g) (t : FinePathIn tab) (ht : P t) :
                                                                              ∃ (u : FinePathIn tab), P u u.children =

                                                                              The descent principle in the strong form: the property is only required to propagate to some fine descendant (not necessarily a child) as long as the node is not childless.