MatchingLogic.Semantics #
The free variables of a pattern. ∃x binds x.
Equations
- MatchingLogic.FV (MatchingLogic.Pattern.var x_1) = {x_1}
- MatchingLogic.FV MatchingLogic.Pattern.bot = ∅
- MatchingLogic.FV (MatchingLogic.Pattern.app σ f) = ⋃ (i : Fin (S.arity σ)), MatchingLogic.FV (f i)
- MatchingLogic.FV (φ.imp ψ) = MatchingLogic.FV φ ∪ MatchingLogic.FV ψ
- MatchingLogic.FV (MatchingLogic.Pattern.ex x_1 φ) = MatchingLogic.FV φ \ {x_1}
Instances For
A pattern is closed when it has no free variables. The paper assumes
throughout Sections 3-5 that Γ and φ are closed, without loss of
generality.
Equations
- MatchingLogic.Closed φ = (MatchingLogic.FV φ = ∅)
Instances For
@[simp]
theorem
MatchingLogic.denote_closed
{S : Signature}
{Var : Type}
[DecidableEq Var]
(M : Model S)
{φ : Pattern S Var}
(hφ : Closed φ)
(ρ ρ' : Var → M.carrier)
:
For a closed pattern the denotation does not depend on the valuation at all;
this is what licenses the paper's ⟦ψ⟧ notation.
Definition 1: totality and the three consequence relations #
def
MatchingLogic.LocalCons
{S : Signature}
{Var : Type}
[DecidableEq Var]
(Δ : Set (Pattern S Var))
(φ : Pattern S Var)
:
Δ ⊨loc φ: local consequence, comparing denotations pointwise.
Equations
- MatchingLogic.LocalCons Δ φ = ∀ (M : MatchingLogic.Model S) (ρ : Var → M.carrier), M.denoteSet ρ Δ ⊆ M.denote ρ φ
Instances For
def
MatchingLogic.GlobalCons
{S : Signature}
{Var : Type}
[DecidableEq Var]
(Γ : Set (Pattern S Var))
(φ : Pattern S Var)
:
Γ ⊨ φ: global consequence, asking for totality.
Equations
- MatchingLogic.GlobalCons Γ φ = ∀ (M : MatchingLogic.Model S), M.SatSet Γ → M.Sat φ
Instances For
theorem
MatchingLogic.Model.sat_iff_denote_eq_univ
{S : Signature}
{Var : Type}
[DecidableEq Var]
(M : Model S)
{φ : Pattern S Var}
(hφ : Closed φ)
(ρ : Var → M.carrier)
:
For closed φ, M ⊨ φ says exactly ⟦φ⟧ = M, with no valuation
quantifier left (paper, Section 2, "Closed patterns").