Flypitch.FOL.Semantics interprets the syntax and proof system from the preceding files in
first-order structures. It defines term and formula realization, semantic consequence, and
proves the soundness of the natural-deduction rules.
An L-structure consists of a carrier type and interpretations of the symbols of L.
- carrier : Type u
Instances For
Equations
- Flypitch.fol.instCoeSortStructureType = { coe := fun (S : Flypitch.fol.Structure L) => S.carrier }
Interpret a partially applied term in a structure under a valuation.
Equations
- Flypitch.fol.realize_term v (&k) x_3 = v k
- Flypitch.fol.realize_term v (Flypitch.fol.preterm.func f) x✝ = M.fun_map f x✝
- Flypitch.fol.realize_term v (t₁.app t₂) x✝ = Flypitch.fol.realize_term v t₁ (Flypitch.dvector.cons (Flypitch.fol.realize_term v t₂ Flypitch.dvector.nil) x✝)
Instances For
Interpret a preformula under a valuation and arguments for its unapplied relation slots.
Equations
- Flypitch.fol.realize_formula x✝ Flypitch.fol.preformula.falsum x_5 = False
- Flypitch.fol.realize_formula x✝ (t₁ ≃ t₂) xs = (Flypitch.fol.realize_term x✝ t₁ xs = Flypitch.fol.realize_term x✝ t₂ xs)
- Flypitch.fol.realize_formula x✝¹ (Flypitch.fol.preformula.rel R) x✝ = M.rel_map R x✝
- Flypitch.fol.realize_formula x✝¹ (f.apprel t) x✝ = Flypitch.fol.realize_formula x✝¹ f (Flypitch.dvector.cons (Flypitch.fol.realize_term x✝¹ t Flypitch.dvector.nil) x✝)
- Flypitch.fol.realize_formula x✝ (f₁ ⟹ f₂) xs = (Flypitch.fol.realize_formula x✝ f₁ xs → Flypitch.fol.realize_formula x✝ f₂ xs)
- Flypitch.fol.realize_formula x✝ (∀' f) xs = ∀ (x : M.carrier), Flypitch.fol.realize_formula (x✝[x // 0]) f xs
Instances For
Formula substitution is semantically the same as updating the valuation at the substituted variable.
Specialization of realize_formula_subst to substitution at variable 0.
A closed formula is satisfied in M when every valuation realizes it.
Equations
- Flypitch.fol.satisfied_in M f = ∀ (v : ℕ → M.carrier), Flypitch.fol.realize_formula v f Flypitch.dvector.nil
Instances For
Every formula in T is satisfied in M.
Equations
- Flypitch.fol.all_satisfied_in M T = ∀ ⦃f : Flypitch.fol.formula L⦄, f ∈ T → Flypitch.fol.satisfied_in M f
Instances For
Semantic consequence of a single formula from a set of assumptions.
Equations
- T ⊨ f = ∀ (M : Flypitch.fol.Structure L) (v : ℕ → M.carrier), (∀ g ∈ T, Flypitch.fol.realize_formula v g Flypitch.dvector.nil) → Flypitch.fol.realize_formula v f Flypitch.dvector.nil
Instances For
Semantic consequence of every formula in T' from T.
Equations
- Flypitch.fol.all_satisfied T T' = ∀ ⦃f : Flypitch.fol.formula L⦄, f ∈ T' → T ⊨ f
Instances For
Equations
- Flypitch.fol.«term_⊨_» = Lean.ParserDescr.trailingNode `Flypitch.fol.«term_⊨_» 51 52 (Lean.ParserDescr.binary `andthen (Lean.ParserDescr.symbol " ⊨ ") (Lean.ParserDescr.cat `term 52))
Instances For
Semantic consequence can be composed with satisfaction in a specific structure.
Satisfaction of a theory in a structure is closed under semantic consequence.
Semantic consequence is monotone in the conclusion set.
Semantic consequence composes transitively.
Pointwise semantic consequence composes transitively.