Complete lattices #
The definitions and instances of the lattice theory: the operations of a complete lattice, the
complete lattice of propositions, the embedding ⌜·⌝ of propositions, supremum-preserving maps with
their upper adjoints, and Heyting implication ⇨.
Additional operations of a complete lattice #
The top element ⊤, the binary meet ⊓ and join ⊔, and the indexed infimum ⨅ and supremum
⨆. The bottom element ⊥ comes from CCPO, which every complete lattice is.
Top element of a complete lattice (supremum of all elements)
Equations
- Lean.Order.top = Lean.Order.CompleteLattice.sup fun (x : α) => True
Instances For
Top element of a complete lattice (supremum of all elements)
Equations
- Lean.Order.«term⊤» = Lean.ParserDescr.node `Lean.Order.«term⊤» 1024 (Lean.ParserDescr.symbol "⊤")
Instances For
A complete lattice is a chain-complete partial order.
Equations
- Lean.Order.instCCPOOfCompleteLattice = { toPartialOrder := inst✝.toPartialOrder, has_csup := ⋯ }
Instances For
Binary meet (infimum)
Equations
- Lean.Order.meet x y = Lean.Order.inf fun (z : α) => z = x ∨ z = y
Instances For
Binary meet (infimum)
Equations
- Lean.Order.«term_⊓_» = Lean.ParserDescr.trailingNode `Lean.Order.«term_⊓_» 70 70 (Lean.ParserDescr.binary `andthen (Lean.ParserDescr.symbol " ⊓ ") (Lean.ParserDescr.cat `term 71))
Instances For
Binary join (supremum)
Equations
- Lean.Order.join x y = Lean.Order.CompleteLattice.sup fun (z : α) => z = x ∨ z = y
Instances For
Binary join (supremum)
Equations
- Lean.Order.«term_⊔_» = Lean.ParserDescr.trailingNode `Lean.Order.«term_⊔_» 65 65 (Lean.ParserDescr.binary `andthen (Lean.ParserDescr.symbol " ⊔ ") (Lean.ParserDescr.cat `term 66))
Instances For
Indexed infimum
Equations
- Lean.Order.iInf f = Lean.Order.inf fun (x : α) => ∃ (i : ι), f i = x
Instances For
Indexed infimum
Equations
- One or more equations did not get rendered due to their size.
Instances For
Indexed supremum
Equations
- Lean.Order.iSup f = Lean.Order.CompleteLattice.sup fun (x : α) => ∃ (i : ι), f i = x
Instances For
Indexed supremum
Equations
- One or more equations did not get rendered due to their size.
Instances For
The complete lattice of propositions #
⊑ is implication and the supremum of a set of propositions is the existential quantifier over it.
The instances are scoped in Std.Internal.Order, outside of Lean.Order. partial_fixpoint and
coinductive_fixpoint order Prop by ImplicationOrder and ReverseImplicationOrder, and their
monotonicity lemmas live in Lean.Order itself. Open Std.Internal.Order to order Prop by
implication.
Equations
- One or more equations did not get rendered due to their size.
Instances For
Equations
- Std.Internal.Order.instCompleteLatticeProp = { toPartialOrder := Std.Internal.Order.instPartialOrderProp, has_sup := Std.Internal.Order.instCompleteLatticeProp._proof_1 }
Instances For
Embedding of propositions #
⌜p⌝ embeds a proposition p into an assertion lattice as ⊤ if p holds and ⊥ otherwise.
Embedding of propositions into an CompleteLattice type. ⌜p⌝ embeds p : Prop as ⊤ if p holds
and ⊥ otherwise.
Equations
Instances For
Embedding of propositions into an CompleteLattice type. ⌜p⌝ embeds p : Prop as ⊤ if p holds
and ⊥ otherwise.
Equations
- One or more equations did not get rendered due to their size.
Instances For
Supremum-preserving maps and Heyting implication #
A supremum-preserving map on a complete lattice is a lower adjoint. Its upper adjoint is the
implication belonging to it: Heyting ⇨ for the lattice meet, a magic wand for a separating
conjunction.
f : α → α preserves suprema if it distributes over arbitrary suprema:
f (sup s) = sup { f x | x ∈ s }. Equivalently f is a lower adjoint, so it has an upper adjoint
PreservesSup.upperAdjoint f.
A frame operator acts by a supremum-preserving map for each resource r: the lattice meet
(a ⊓ ·),
or a cost combinator (costConj r) for a counter resource. The upper adjoint is the corresponding
implication: Heyting ⇨ for the meet, a magic wand for separating conjunction.
- map_sup (s : α → Prop) : f (CompleteLattice.sup s) = CompleteLattice.sup fun (y : α) => ∃ (x : α), s x ∧ y = f x
fpreserves joins.
Instances
The upper adjoint of f: the join of all x with f x ⊑ b. For f = (a ⊓ ·) this is Heyting
implication a ⇨ ·.
Equations
- Lean.Order.PreservesSup.upperAdjoint f b = Lean.Order.CompleteLattice.sup fun (x : α) => Lean.Order.PartialOrder.rel (f x) b
Instances For
Unit, free from the definition of upperAdjoint: f x ⊑ b → x ⊑ upperAdjoint f b. Needs only
CompleteLattice.
A complete lattice whose meets preserve suprema. The Heyting implication ⇨ is then a right
adjoint, and ⊓ distributes over suprema of arbitrary families. The literature also calls such a
lattice a frame.
Equations
- Lean.Order.Heyting α = ∀ (a : α), Lean.Order.PreservesSup (Lean.Order.meet a)
Instances For
Heyting implication: the upper adjoint of the lattice meet. For Prop it is →.
Equations
Instances For
Heyting implication: the upper adjoint of the lattice meet. For Prop it is →.
Equations
- Lean.Order.«term_⇨_» = Lean.ParserDescr.trailingNode `Lean.Order.«term_⇨_» 60 61 (Lean.ParserDescr.binary `andthen (Lean.ParserDescr.symbol " ⇨ ") (Lean.ParserDescr.cat `term 60))