Propositional Formulas mod Equivalence #
This file defines the type of propositional formulas over
a set ν of variables, quotiented by strong equivalence.
We show that they form a Boolean algebra with ordering given by semantic entailment. This allows us to use Mathlib's lattice notation & lemmas.
Equations
- Trestle.Model.PropFun.setoid ν = { r := Trestle.Model.PropForm.equivalent, iseqv := ⋯ }
A propositional function is a propositional formula up to semantic equivalence.
Equations
Instances For
Applied backwards, this reduces an equivalence between two syntactic formulas to an equality between the functions they denote.
Equations
Instances For
Equations
Instances For
Instances For
Equations
- Trestle.Model.PropFun.neg = Quotient.map (fun (x : Trestle.Model.PropForm ν) => x.neg) ⋯
Instances For
Equations
- Trestle.Model.PropFun.conj = Quotient.map₂ (fun (x1 x2 : Trestle.Model.PropForm ν) => x1.conj x2) ⋯
Instances For
Equations
- Trestle.Model.PropFun.disj = Quotient.map₂ (fun (x1 x2 : Trestle.Model.PropForm ν) => x1.disj x2) ⋯
Instances For
Equations
- Trestle.Model.PropFun.impl = Quotient.map₂ (fun (x1 x2 : Trestle.Model.PropForm ν) => x1.impl x2) ⋯
Instances For
Equations
- Trestle.Model.PropFun.biImpl = Quotient.map₂ (fun (x1 x2 : Trestle.Model.PropForm ν) => x1.biImpl x2) ⋯
Instances For
Evaluation
The unique extension of τ from variables to propositional functions.
Equations
Instances For
Satisfying assignments
Equations
Instances For
This instance is scoped so that when PropFun is open,
τ ⊨ φ implies φ : PropFun _ via the outParam.
Equations
Instances For
Equations
- Trestle.Model.PropFun.instDecidableEntailsPropAssignment τ φ = match h : Trestle.Model.PropFun.eval τ φ with | true => isTrue h | false => isFalse ⋯
Semantic entailment
Equations
- φ₁.entails φ₂ = ∀ (τ : Trestle.Model.PropAssignment ν), Trestle.Model.PropFun.eval τ φ₁ ≤ Trestle.Model.PropFun.eval τ φ₂
Instances For
From this point onwards we use lattice notation for PropFuns
in order to get the mathlib laws for free.
Equations
- One or more equations did not get rendered due to their size.
Lemmas to push Quotient.mk inwards.
All/any #
Equations
Instances For
Equations
Instances For
Satisfiable and Equisatisfiable #
Equations
- φ.Sat = ∃ (τ : Trestle.Model.PropAssignment ν), τ ⊨ φ
Instances For
Equations
Instances For
Equations
- One or more equations did not get rendered due to their size.
Instances For
Equations
- One or more equations did not get rendered due to their size.
Instances For
Equations
- One or more equations did not get rendered due to their size.
Instances For
Equations
- One or more equations did not get rendered due to their size.
Instances For
Equations
- One or more equations did not get rendered due to their size.
Instances For
Equations
- One or more equations did not get rendered due to their size.
Instances For
Equations
- One or more equations did not get rendered due to their size.
Instances For
Equations
- One or more equations did not get rendered due to their size.
Instances For
Equations
- One or more equations did not get rendered due to their size.