Documentation

LeanPool.PDL.Sequent

Sequents #

Optional loaded formulas (Olfs) #

@[reducible, inline]
abbrev PDL.Olf :

In nodes we optionally have a negated loaded formula on the left or right.

Equations
Instances For

    The vocabulary of the optional loaded formula, ignoring its side.

    Equations
    Instances For
      @[instance_reducible]
      Equations
      @[simp]
      theorem PDL.Option.some_subseteq {α : Type u_1} {x : α} {O : Option α} :
      some x ⊆ O ↔ some x = O
      @[simp]
      theorem PDL.Option.none_subseteq {α : Type u_1} {O : Option α} :
      @[instance_reducible]
      instance PDL.Option.instDecidableSubset {α : Type u_1} [DecidableEq α] (o1 o2 : Option α) :
      Decidable (o1 ⊆ o2)

      The subset relation on Option α from Option.instHasSubsetOption is decidable.

      Equations
      @[instance_reducible]
      instance PDL.Option.insHasSdiff {α : Type u_1} [DecidableEq α] :

      Instance that is used to say (O : Olf) \ (O' : Olf).

      Equations
      • One or more equations did not get rendered due to their size.
      @[simp]
      theorem PDL.Option.insHasSdiff_none {α : Type u_1} {o : Option α} [DecidableEq α] :
      @[simp]
      @[simp]

      The unloaded left formula contributed by an optional loading.

      Equations
      Instances For
        @[simp]
        @[simp]
        theorem PDL.Olf.L_inr {lf : NegLoadFormula} :
        L (some (Sum.inr lf)) = ∅
        @[simp]
        theorem PDL.Olf.L_inl {lf : NegLoadFormula} :
        L (some (Sum.inl lf)) = {lf.1.unload.neg}
        theorem PDL.Olf.L_subset_of_subset {O1 O2 : Olf} (h : O1 ⊆ O2) :
        O1.L ⊆ O2.L
        theorem PDL.Olf.L_sdiff_subset {O Ocond : Olf} :
        (O \ Ocond).L ⊆ O.L

        The unloaded right formula contributed by an optional loading.

        Equations
        Instances For
          @[simp]
          @[simp]
          theorem PDL.Olf.R_inl {lf : NegLoadFormula} :
          R (some (Sum.inl lf)) = ∅
          @[simp]
          theorem PDL.Olf.R_inr {lf : NegLoadFormula} :
          R (some (Sum.inr lf)) = {lf.1.unload.neg}
          theorem PDL.Olf.R_subset_of_subset {O1 O2 : Olf} (h : O1 ⊆ O2) :
          O1.R ⊆ O2.R
          theorem PDL.Olf.R_sdiff_subset {O Ocond : Olf} :
          (O \ Ocond).R ⊆ O.R
          def Option.pdlOverwrite {α : Type u_1} :
          Option α → Option α → Option α

          Use the new optional value when present, otherwise retain the old value.

          Equations
          Instances For
            def PDL.Olf.change (oldO Ocond newO : Olf) :

            Remove the rule's required loading and install its new loading when present.

            Equations
            Instances For
              @[simp]
              theorem PDL.Olf.change_old_none_none {oldO : Olf} :
              oldO.change none none = oldO
              @[simp]
              theorem PDL.Olf.change_none_none_new {newO : Olf} :
              change none none newO = newO
              @[simp]
              theorem PDL.Olf.change_some {oldO whatever : Olf} {wnlf : NegLoadFormula ⊕ NegLoadFormula} :
              oldO.change whatever (some wnlf) = some wnlf
              @[simp]
              theorem PDL.Olf.change_some_some_eq {Onew : Olf} {nχ : NegLoadFormula ⊕ NegLoadFormula} :
              change (some nχ) (some nχ) Onew = Onew

              Whether the optional loading is absent.

              Equations
              Instances For

                Whether the optional loading belongs to the left component.

                Equations
                Instances For

                  Whether the optional loading belongs to the right component.

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

                    Sequents and their (multi)set quality #

                    @[implicit_reducible]

                    A tableau node is labelled with two finite sets of formulas and an Olf. Each formula is placed on the left or right and up to one formula may be loaded.

                    Equations
                    Instances For
                      @[instance_reducible]
                      Equations

                      All ordinary formulas of a sequent, including its loading after unloading.

                      Equations
                      Instances For

                        Components and sides of sequents #

                        The ordinary formulas in the left component.

                        Equations
                        Instances For

                          The ordinary formulas in the right component.

                          Equations
                          Instances For

                            The optional loaded formula and its side.

                            Equations
                            Instances For
                              @[simp]
                              theorem PDL.Sequent.L_eq {L R : Finset Formula} {O : Olf} :
                              @[simp]
                              theorem PDL.Sequent.R_eq {L R : Finset Formula} {O : Olf} :
                              @[simp]
                              theorem PDL.Sequent.O_eq {L R : Finset Formula} {O : Olf} :

                              The left component including any left loading after unloading.

                              Equations
                              Instances For

                                The right component including any right loading after unloading.

                                Equations
                                Instances For
                                  @[simp]
                                  theorem PDL.Sequent.left_eq {L R : Finset Formula} {O : Olf} :
                                  left (L, R, O) = L ∪ O.L
                                  @[simp]
                                  theorem PDL.Sequent.right_eq {L R : Finset Formula} {O : Olf} :
                                  right (L, R, O) = R ∪ O.R

                                  (Joint) vocabulary of sequents #

                                  Like Olf.voc but without the ⊕ inside.

                                  Equations
                                  Instances For

                                    The combined vocabulary of formula lists and optional loaded formulas.

                                    Equations
                                    Instances For

                                      Finset version of lfovoc.

                                      Equations
                                      Instances For

                                        The joint vocabulary occurring on both the left and the right side.

                                        Equations
                                        Instances For
                                          theorem PDL.jvoc_sub_of_voc_sub {Y X : Sequent} (hl : Y.left.pdlFvoc ⊆ X.left.pdlFvoc) (hr : Y.right.pdlFvoc ⊆ X.right.pdlFvoc) :
                                          jvoc Y ⊆ jvoc X

                                          Formulas as elements of sequents #

                                          @[instance_reducible, instance 10000]
                                          Equations
                                          @[simp]
                                          theorem PDL.Sequent.mem_def {φ : Formula} {X : Sequent} :
                                          φ ∈ X ↔ φ ∈ X.L ∨ φ ∈ X.R
                                          @[instance_reducible]
                                          Equations
                                          • One or more equations did not get rendered due to their size.
                                          @[instance_reducible]
                                          Equations
                                          • One or more equations did not get rendered due to their size.

                                          Whether the specified loaded formula is the loading on either side of a sequent.

                                          Equations
                                          Instances For
                                            @[instance_reducible]
                                            Equations

                                            Membership of a negated ordinary or loaded formula in a sequent.

                                            Equations
                                            Instances For

                                              Closed, basic, loaded and free sequents #

                                              A sequent is closed iff it contains ⊥ or contains a formula and its negation.

                                              Equations
                                              Instances For

                                                A sequent is basic iff it only contains basic formulas and is not closed.

                                                Equations
                                                Instances For
                                                  @[instance_reducible]
                                                  instance PDL.Fintype.decidableExistsConjFintype {α : Type u_1} {p q : α → Prop} [DecidablePred q] [Fintype (Subtype p)] :
                                                  Decidable (∃ (a : α), p a ∧ q a)

                                                  A variant of Fintype.decidableExistsFintype, used by instDecidableClosed.

                                                  Equations
                                                  @[instance_reducible]
                                                  Equations
                                                  @[instance_reducible]
                                                  Equations

                                                  Whether a sequent carries a loaded formula.

                                                  Equations
                                                  Instances For

                                                    A loaded sequent that is not loaded on the left is loaded on the right.

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

                                                    Whether a sequent has no loaded formula.

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

                                                      Semantics of sequents #

                                                      @[instance_reducible]
                                                      Equations
                                                      @[instance_reducible]
                                                      Equations
                                                      theorem PDL.vDash_setEqTo_iff {W : Type} {X Y : Sequent} (h : X = Y) (M : KripkeModel W) (w : W) :

                                                      Removing loaded formulas from sequents #

                                                      Remove a negated formula from the ordinary components or from the optional loading.

                                                      Equations
                                                      Instances For
                                                        @[simp]
                                                        theorem PDL.Sequent.isFree_then_without_isFree (LRO : Sequent) :
                                                        LRO.isFree → ∀ (anf : AnyNegFormula), (LRO.without anf).isFree
                                                        inductive PDL.Side :

                                                        The left and right components of a sequent.

                                                        Instances For
                                                          def PDL.sideOf {α : Type u_1} :
                                                          α ⊕ α → Side

                                                          The component indicated by a sum constructor.

                                                          Equations
                                                          Instances For

                                                            Whatever formulas #

                                                            A type to describe all formulas that can occur in a sequent, without losing information about whether they are loaded or not.

                                                            Unfortunately our AnyFormula type does not include negated loaded formulas, so this is yet another type to describe "whatever formula" can be in a sequent, without losing information.

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

                                                                The optional loading viewed as a finset of tagged formulas.

                                                                Equations
                                                                Instances For

                                                                  All ordinary and loaded formulas of a sequent, retaining their tags.

                                                                  Equations
                                                                  Instances For

                                                                    A normal formula is in X.wForms iff it is on the left or on the right of X. (Note that the Olf part of X only contributes negated loaded formulas.)

                                                                    In a basic sequent all free diamonds are atomic.

                                                                    A negated loaded formula is in X.wForms iff it is the loaded formula of X.

                                                                    In a basic sequent all loaded diamonds are atomic.

                                                                    Sorting Finsets of Sequents #

                                                                    Lexicographic orders on lists and pairs #

                                                                    NOTE: The following two definitions and their properties are general, i.e. not about PDL at all. These could be moved to a separate file (or even might be in newer versions of Mathlib?).

                                                                    def PDL.listLex {α : Type} (le : α → α → Prop) :
                                                                    List α → List α → Prop

                                                                    Lexicographic extension of a relation le to lists: shorter lists come first, and lists of the same shape are compared element-wise from left to right.

                                                                    Equations
                                                                    Instances For
                                                                      theorem PDL.listLex_refl {α : Type} {le : α → α → Prop} (hrefl : ∀ (a : α), le a a) (as : List α) :
                                                                      listLex le as as
                                                                      theorem PDL.listLex_antisymm {α : Type} {le : α → α → Prop} (hanti : ∀ (a b : α), le a b → le b a → a = b) (as bs : List α) :
                                                                      listLex le as bs → listLex le bs as → as = bs
                                                                      theorem PDL.listLex_trans {α : Type} {le : α → α → Prop} (hanti : ∀ (a b : α), le a b → le b a → a = b) (htrans : ∀ (a b c : α), le a b → le b c → le a c) (as bs cs : List α) :
                                                                      listLex le as bs → listLex le bs cs → listLex le as cs
                                                                      theorem PDL.listLex_total {α : Type} {le : α → α → Prop} (hrefl : ∀ (a : α), le a a) (htotal : ∀ (a b : α), le a b ∨ le b a) (as bs : List α) :
                                                                      listLex le as bs ∨ listLex le bs as
                                                                      def PDL.prodLex {α β : Type} (le1 : α → α → Prop) (le2 : β → β → Prop) :
                                                                      α × β → α × β → Prop

                                                                      Lexicographic combination of two relations on a product type.

                                                                      Equations
                                                                      Instances For
                                                                        @[instance_reducible]
                                                                        instance PDL.prodLex.instDecidableRel {α β : Type} [DecidableEq α] (le1 : α → α → Prop) (le2 : β → β → Prop) [DecidableRel le1] [DecidableRel le2] :
                                                                        Equations
                                                                        theorem PDL.prodLex_refl {α β : Type} {le1 : α → α → Prop} {le2 : β → β → Prop} (h1 : ∀ (a : α), le1 a a) (h2 : ∀ (b : β), le2 b b) (x : α × β) :
                                                                        prodLex le1 le2 x x
                                                                        theorem PDL.prodLex_antisymm {α β : Type} {le1 : α → α → Prop} {le2 : β → β → Prop} (h1 : ∀ (a a' : α), le1 a a' → le1 a' a → a = a') (h2 : ∀ (b b' : β), le2 b b' → le2 b' b → b = b') (x y : α × β) :
                                                                        prodLex le1 le2 x y → prodLex le1 le2 y x → x = y
                                                                        theorem PDL.prodLex_trans {α β : Type} {le1 : α → α → Prop} {le2 : β → β → Prop} (hanti1 : ∀ (a a' : α), le1 a a' → le1 a' a → a = a') (htrans1 : ∀ (a a' a'' : α), le1 a a' → le1 a' a'' → le1 a a'') (htrans2 : ∀ (b b' b'' : β), le2 b b' → le2 b' b'' → le2 b b'') (x y z : α × β) :
                                                                        prodLex le1 le2 x y → prodLex le1 le2 y z → prodLex le1 le2 x z
                                                                        theorem PDL.prodLex_total {α β : Type} {le1 : α → α → Prop} {le2 : β → β → Prop} (hrefl1 : ∀ (a : α), le1 a a) (htotal1 : ∀ (a a' : α), le1 a a' ∨ le1 a' a) (htotal2 : ∀ (b b' : β), le2 b b' ∨ le2 b' b) (x y : α × β) :
                                                                        prodLex le1 le2 x y ∨ prodLex le1 le2 y x

                                                                        An order on loaded formulas, via a key #

                                                                        Every loaded formula is a non-empty sequence of loading boxes followed by a normal formula. The key of a loaded formula records exactly this data, and hence determines it uniquely. NOTE: This could be moved to Pdl/Syntax.lean.

                                                                        Equations
                                                                        Instances For

                                                                          Inverse of LoadFormula.key, see LoadFormula.ofKey_key. (The value for the empty list of programs is arbitrary.) NOTE: This could be moved to Pdl/Syntax.lean.

                                                                          Equations
                                                                          Instances For

                                                                            The key of a loaded formula determines it.

                                                                            theorem PDL.LoadFormula.key_injective {χ χ' : LoadFormula} (h : χ.key = χ'.key) :
                                                                            χ = χ'

                                                                            An order on sequents, via a key #

                                                                            Key of an Olf: which side (if any) is loaded, together with the key of the loaded formula.

                                                                            Equations
                                                                            Instances For
                                                                              theorem PDL.Olf.key_injective {O O' : Olf} :
                                                                              O.key = O'.key → O = O'

                                                                              Key of a sequent: the sorted lists of the left and right side, and the key of the Olf.

                                                                              Equations
                                                                              Instances For

                                                                                Finsets of formulas with the same pdlSort are equal. NOTE: This could be moved to Pdl/Syntax.lean.

                                                                                theorem PDL.Sequent.key_injective {X Y : Sequent} (h : X.key = Y.key) :
                                                                                X = Y

                                                                                Order used to compare the keys of Olfs.

                                                                                Equations
                                                                                Instances For
                                                                                  theorem PDL.olfKeyLe_antisymm (x y : ℕ × List Program × Formula) (h1 : olfKeyLe x y) (h2 : olfKeyLe y x) :
                                                                                  x = y
                                                                                  theorem PDL.olfKeyLe_trans (x y z : ℕ × List Program × Formula) (h1 : olfKeyLe x y) (h2 : olfKeyLe y z) :

                                                                                  A linear order on sequents, used to define Finset.pdlSeqSort.

                                                                                  Equations
                                                                                  Instances For

                                                                                    Sort a finite set of sequents into a list, using Sequent.le.

                                                                                    Equations
                                                                                    Instances For