Documentation

Pdl.Semantics

Semantics (Section 2.2) #

Models and Truth #

structure KripkeModel (W : Type) :

Kripke Models, also known as Labelled Transition Systems

Instances For
    def complexityOfQuery {W : Type} :
    (_ : KripkeModel W) ×' (_ : W) ×' Formula ⊕' (_ : KripkeModel W) ×' (_ : Program) ×' (_ : W) ×' W → ℕ
    Equations
    Instances For
      def evaluate {W : Type} :
      KripkeModel W → W → Formula → Prop
      Equations
      Instances For
        def relate {W : Type} :
        KripkeModel W → Program → W → W → Prop
        Equations
        Instances For
          @[simp]
          theorem evalDis {W : Type} {M : KripkeModel W} {f g : Formula} {w : W} :
          evaluate M w (f ⋁ g) ↔ evaluate M w f ∨ evaluate M w g
          def evaluatePoint {W : Type} :
          Equations
          Instances For
            def tautology (φ : Formula) :
            Equations
            Instances For
              Equations
              Instances For

                Satisfiability #

                class HasSat (α : Type) :
                • satisfiable : α → Prop
                Instances
                  @[instance_reducible]
                  Equations
                  @[instance_reducible]
                  Equations
                  @[instance_reducible]
                  Equations
                  theorem sat_congr_of_mem_iff {L L' : List Formula} (h : ∀ (f : Formula), f ∈ L ↔ f ∈ L') :

                  Satisfiability of a list only depends on which formulas are in it.

                  Semantic implication and vDash notation #

                  Equations
                  Instances For
                    Equations
                    Instances For
                      def semEquiv (φ ψ : Formula) :
                      Equations
                      Instances For
                        def relEquiv (α β : Program) :
                        Equations
                        Instances For
                          theorem subsetSat {W : Type} {M : KripkeModel W} {w : W} {X Y : List Formula} :
                          (∀ φ ∈ X, evaluate M w φ) → Y ⊆ X → ∀ φ ∈ Y, evaluate M w φ
                          class vDash (α β : Type) :
                          • SemImplies : α → β → Prop
                          Instances
                            @[instance_reducible]
                            Equations
                            @[instance_reducible]
                            Equations
                            @[instance_reducible]
                            Equations
                            @[instance_reducible]
                            Equations
                            • One or more equations did not get rendered due to their size.
                            @[instance_reducible]
                            Equations
                            @[instance_reducible]
                            Equations
                            @[instance_reducible]
                            Equations
                            @[instance_reducible]
                            Equations
                            @[instance_reducible]
                            Equations
                            @[simp]
                            theorem vDashSingleton_iff_vDash_formula {W : Type} {M : KripkeModel W} {w : W} (φ : Formula) :
                            (M, w) ⊨ [φ] ↔ evaluate M w φ
                            theorem forms_to_lists {φ ψ : Formula} :
                            φ ⊨ ψ → [φ] ⊨ [ψ]
                            theorem deduction (X : List Formula) (ψ φ : Formula) :
                            X ++ [ψ] ⊨ φ ↔ X ⊨ ~(ψ ⋀ ~φ)

                            The Local Deduction Theorem.

                            theorem equivSat {W : Type} (φ ψ : Formula) {M : KripkeModel W} {w : W} :
                            φ ≡ ψ → (M, w) ⊨ φ → (M, w) ⊨ ψ
                            theorem equiv_iff (φ ψ : Formula) (φ_eq_ψ : φ ≡ ψ) {W : Type} {M : KripkeModel W} {w : W} :
                            (M, w) ⊨ φ ↔ (M, w) ⊨ ψ
                            theorem relate_steps_append {W✝ : Type} {M : KripkeModel W✝} {as bs : List Program} (x z : W✝) :
                            relate M (Program.steps (as ++ bs)) x z ↔ ∃ (y : W✝), relate M (Program.steps as) x y ∧ relate M (Program.steps bs) y z
                            theorem rel_steps_last {W✝ : Type} {M : KripkeModel W✝} {a : Program} {as : List Program} (v w : W✝) :
                            relate M (Program.steps (as ++ [a])) v w ↔ ∃ (mid : W✝), relate M (Program.steps as) v mid ∧ relate M a mid w
                            def relateSeq {W : Type} (M : KripkeModel W) (δ : List Program) (w v : W) :
                            Equations
                            Instances For
                              @[simp]
                              theorem relateSeq_nil {W : Type} {M : KripkeModel W} {w v : W} :
                              relateSeq M [] w v ↔ w = v
                              @[simp]
                              theorem relateSeq_singleton {W : Type} {M : KripkeModel W} {α : Program} {w v : W} :
                              relateSeq M [α] w v ↔ relate M α w v
                              theorem relateSeq_cons {W : Type} {M : KripkeModel W} {d : Program} {δ : List Program} {w v : W} :
                              relateSeq M (d :: δ) w v ↔ ∃ (u : W), relate M d w u ∧ relateSeq M δ u v
                              theorem relateSeq_append {W : Type} {M : KripkeModel W} {l1 l2 : List Program} {w v : W} :
                              relateSeq M (l1 ++ l2) w v ↔ ∃ (u : W), relateSeq M l1 w u ∧ relateSeq M l2 u v
                              theorem relate_steps_iff_relateSeq {W : Type} (M : KripkeModel W) (δ : List Program) (w v : W) :
                              relate M (Program.steps δ) w v ↔ relateSeq M δ w v
                              theorem relateSeq_iff_exists_Vector {W : Type} (M : KripkeModel W) (δ : List Program) (w v : W) :
                              relateSeq M δ w v ↔ ∃ (ws : List.Vector W δ.length.succ), w = ws.head ∧ v = ws.last ∧ ∀ (i : Fin δ.length), relate M (δ.get i) (ws.get i.castSucc) (ws.get i.succ)
                              theorem relate_unions {W : Type} {M : KripkeModel W} (L : List Program) (v u : W) :
                              relate M (Program.unions L) v u ↔ ∃ a ∈ L, relate M a v u

                              Relating along Program.unions L means relating along one of the programs in L.

                              theorem evalBoxes {W✝ : Type} {M : KripkeModel W✝} {w : W✝} (δ : List Program) (φ : Formula) :
                              evaluate M w (⌈⌈δ⌉⌉φ) ↔ ∀ (v : W✝), relateSeq M δ w v → evaluate M v φ
                              @[simp]
                              theorem evaluate_unload_box {W✝ : Type} {M : KripkeModel W✝} {w : W✝} {α : Program} {af : AnyFormula} :
                              evaluate M w (⌊α⌋af).unload ↔ ∀ (v : W✝), relate M α w v → (M, v) ⊨ af
                              theorem stepToStar {φ : Formula} {α : Program} {ψ : Formula} :
                              φ ⊨ (⌈α⌉φ) ⋀ ψ → φ ⊨ ⌈∗α⌉ψ

                              Semantic induction rule for the Kleene star operator.

                              theorem SemImplyAnyNegFormula_loadBoxes_iff {W : Type} {w : W} {δ : List Program} {M : KripkeModel W} {ξ : AnyFormula} :
                              (M, w) ⊨ ~''(AnyFormula.loadBoxes δ ξ) ↔ ∃ (v : W), relateSeq M δ w v ∧ (M, v) ⊨ ~''ξ