Lattice homomorphisms #
This file defines (bounded) lattice homomorphisms.
We use the DFunLike
design, so each type of morphisms has a companion typeclass which is meant to
be satisfied by itself and all stricter types.
Types of morphisms #
SupHom
: Maps which preserve⊔
.InfHom
: Maps which preserve⊓
.SupBotHom
: Finitary supremum homomorphisms. Maps which preserve⊔
and⊥
.InfTopHom
: Finitary infimum homomorphisms. Maps which preserve⊓
and⊤
.LatticeHom
: Lattice homomorphisms. Maps which preserve⊔
and⊓
.BoundedLatticeHom
: Bounded lattice homomorphisms. Maps which preserve⊤
,⊥
,⊔
and⊓
.
Typeclasses #
TODO #
Do we need more intersections between BotHom
, TopHom
and lattice homomorphisms?
The type of lattice homomorphisms from α
to β
.
- toFun : α → β
A
LatticeHom
preserves infima.
Instances For
The type of bounded lattice homomorphisms from α
to β
.
- toFun : α → β
A
BoundedLatticeHom
preserves the top element.A
BoundedLatticeHom
preserves the bottom element.
Instances For
SupHomClass F α β
states that F
is a type of ⊔
-preserving morphisms.
You should extend this class when you extend SupHom
.
A
SupHomClass
morphism preserves suprema.
Instances
InfHomClass F α β
states that F
is a type of ⊓
-preserving morphisms.
You should extend this class when you extend InfHom
.
An
InfHomClass
morphism preserves infima.
Instances
SupBotHomClass F α β
states that F
is a type of finitary supremum-preserving morphisms.
You should extend this class when you extend SupBotHom
.
A
SupBotHomClass
morphism preserves the bottom element.
Instances
InfTopHomClass F α β
states that F
is a type of finitary infimum-preserving morphisms.
You should extend this class when you extend SupBotHom
.
An
InfTopHomClass
morphism preserves the top element.
Instances
LatticeHomClass F α β
states that F
is a type of lattice morphisms.
You should extend this class when you extend LatticeHom
.
A
LatticeHomClass
morphism preserves infima.
Instances
BoundedLatticeHomClass F α β
states that F
is a type of bounded lattice morphisms.
You should extend this class when you extend BoundedLatticeHom
.
A
BoundedLatticeHomClass
morphism preserves the top element.A
BoundedLatticeHomClass
morphism preserves the bottom element.
Instances
Equations
- ⋯ = ⋯
Equations
- ⋯ = ⋯
Equations
- ⋯ = ⋯
Equations
- ⋯ = ⋯
Equations
- ⋯ = ⋯
Equations
- ⋯ = ⋯
Equations
- ⋯ = ⋯
Equations
- ⋯ = ⋯
Equations
- ⋯ = ⋯
Equations
- ⋯ = ⋯
Equations
- ⋯ = ⋯
Equations
- ⋯ = ⋯
Equations
- ⋯ = ⋯
Equations
- ⋯ = ⋯
We can regard an injective map preserving binary infima as an order embedding.
Equations
Instances For
Special case of map_compl
for boolean algebras.
Special case of map_sdiff
for boolean algebras.
Special case of map_symmDiff
for boolean algebras.
Equations
- instCoeTCLatticeHom = { coe := fun (f : F) => { toSupHom := { toFun := ⇑f, map_sup' := ⋯ }, map_inf' := ⋯ } }
Equations
- One or more equations did not get rendered due to their size.
Supremum homomorphisms #
Equations
- ⋯ = ⋯
Equations
- SupHom.instInhabitedSupHom α = { default := SupHom.id α }
The constant function as a SupHom
.
Equations
- SupHom.const α b = { toFun := fun (x : α) => b, map_sup' := ⋯ }
Instances For
Equations
- SupHom.instSemilatticeSupSupHomToSup = Function.Injective.semilatticeSup (fun (f : SupHom α β) => ⇑f) ⋯ ⋯
Equations
- SupHom.instBotSupHomToSup = { bot := SupHom.const α ⊥ }
Equations
- SupHom.instTopSupHomToSup = { top := SupHom.const α ⊤ }
Equations
- SupHom.instOrderBotSupHomToSupToLEToPreorderToPartialOrderInstSemilatticeSupSupHomToSup = OrderBot.lift DFunLike.coe ⋯ ⋯
Equations
- SupHom.instOrderTopSupHomToSupToLEToPreorderToPartialOrderInstSemilatticeSupSupHomToSup = OrderTop.lift DFunLike.coe ⋯ ⋯
Equations
- SupHom.instBoundedOrderSupHomToSupToLEToPreorderToPartialOrderInstSemilatticeSupSupHomToSup = BoundedOrder.lift DFunLike.coe ⋯ ⋯ ⋯
Infimum homomorphisms #
Equations
- ⋯ = ⋯
Equations
- InfHom.instInhabitedInfHom α = { default := InfHom.id α }
The constant function as an InfHom
.
Equations
- InfHom.const α b = { toFun := fun (x : α) => b, map_inf' := ⋯ }
Instances For
Equations
- InfHom.instSemilatticeInfInfHomToInf = Function.Injective.semilatticeInf (fun (f : InfHom α β) => ⇑f) ⋯ ⋯
Equations
- InfHom.instBotInfHomToInf = { bot := InfHom.const α ⊥ }
Equations
- InfHom.instTopInfHomToInf = { top := InfHom.const α ⊤ }
Equations
- InfHom.instOrderBotInfHomToInfToLEToPreorderToPartialOrderInstSemilatticeInfInfHomToInf = OrderBot.lift DFunLike.coe ⋯ ⋯
Equations
- InfHom.instOrderTopInfHomToInfToLEToPreorderToPartialOrderInstSemilatticeInfInfHomToInf = OrderTop.lift DFunLike.coe ⋯ ⋯
Equations
- InfHom.instBoundedOrderInfHomToInfToLEToPreorderToPartialOrderInstSemilatticeInfInfHomToInf = BoundedOrder.lift DFunLike.coe ⋯ ⋯ ⋯
Finitary supremum homomorphisms #
Copy of a SupBotHom
with a new toFun
equal to the old one. Useful to fix definitional
equalities.
Equations
- SupBotHom.copy f f' h = let __src := BotHom.copy (SupBotHom.toBotHom f) f' h; { toSupHom := SupHom.copy f.toSupHom f' h, map_bot' := ⋯ }
Instances For
Equations
- SupBotHom.instInhabitedSupBotHom α = { default := SupBotHom.id α }
Composition of SupBotHom
s as a SupBotHom
.
Equations
- SupBotHom.comp f g = let __src := SupHom.comp f.toSupHom g.toSupHom; let __src_1 := BotHom.comp (SupBotHom.toBotHom f) (SupBotHom.toBotHom g); { toSupHom := __src, map_bot' := ⋯ }
Instances For
Equations
- One or more equations did not get rendered due to their size.
Equations
- SupBotHom.instSemilatticeSupSupBotHomToSupToBotToLEToPreorderToPartialOrder = Function.Injective.semilatticeSup (fun (f : SupBotHom α β) => ⇑f) ⋯ ⋯
Equations
- SupBotHom.instOrderBotSupBotHomToSupToBotToLEToPreorderToPartialOrderToLEToPreorderToPartialOrderInstSemilatticeSupSupBotHomToSupToBotToLEToPreorderToPartialOrder = OrderBot.mk ⋯
Finitary infimum homomorphisms #
Copy of an InfTopHom
with a new toFun
equal to the old one. Useful to fix definitional
equalities.
Equations
- InfTopHom.copy f f' h = let __src := TopHom.copy (InfTopHom.toTopHom f) f' h; { toInfHom := InfHom.copy f.toInfHom f' h, map_top' := ⋯ }
Instances For
Equations
- InfTopHom.instInhabitedInfTopHom α = { default := InfTopHom.id α }
Composition of InfTopHom
s as an InfTopHom
.
Equations
- InfTopHom.comp f g = let __src := InfHom.comp f.toInfHom g.toInfHom; let __src_1 := TopHom.comp (InfTopHom.toTopHom f) (InfTopHom.toTopHom g); { toInfHom := __src, map_top' := ⋯ }
Instances For
Equations
- One or more equations did not get rendered due to their size.
Equations
- InfTopHom.instSemilatticeInfInfTopHomToInfToTopToLEToPreorderToPartialOrder = Function.Injective.semilatticeInf (fun (f : InfTopHom α β) => ⇑f) ⋯ ⋯
Equations
- InfTopHom.instOrderTopInfTopHomToInfToTopToLEToPreorderToPartialOrderToLEToPreorderToPartialOrderInstSemilatticeInfInfTopHomToInfToTopToLEToPreorderToPartialOrder = OrderTop.mk ⋯
Lattice homomorphisms #
Reinterpret a LatticeHom
as an InfHom
.
Equations
- LatticeHom.toInfHom f = { toFun := f.toFun, map_inf' := ⋯ }
Instances For
Equations
- LatticeHom.instFunLikeLatticeHom = { coe := fun (f : LatticeHom α β) => f.toFun, coe_injective' := ⋯ }
Equations
- ⋯ = ⋯
Copy of a LatticeHom
with a new toFun
equal to the old one. Useful to fix definitional
equalities.
Equations
- LatticeHom.copy f f' h = let __src := SupHom.copy f.toSupHom f' h; let __src_1 := InfHom.copy (LatticeHom.toInfHom f) f' h; { toSupHom := __src, map_inf' := ⋯ }
Instances For
id
as a LatticeHom
.
Equations
- LatticeHom.id α = { toSupHom := { toFun := id, map_sup' := ⋯ }, map_inf' := ⋯ }
Instances For
Equations
- LatticeHom.instInhabitedLatticeHom α = { default := LatticeHom.id α }
Composition of LatticeHom
s as a LatticeHom
.
Equations
- LatticeHom.comp f g = let __src := SupHom.comp f.toSupHom g.toSupHom; let __src_1 := InfHom.comp (LatticeHom.toInfHom f) (LatticeHom.toInfHom g); { toSupHom := __src, map_inf' := ⋯ }
Instances For
An order homomorphism from a linear order is a lattice homomorphism.
Equations
- ⋯ = ⋯
Reinterpret an order homomorphism to a linear order as a LatticeHom
.
Equations
- OrderHomClass.toLatticeHom α β f = { toSupHom := { toFun := ⇑f, map_sup' := ⋯ }, map_inf' := ⋯ }
Instances For
Bounded lattice homomorphisms #
Reinterpret a BoundedLatticeHom
as a SupBotHom
.
Equations
- BoundedLatticeHom.toSupBotHom f = { toSupHom := f.toSupHom, map_bot' := ⋯ }
Instances For
Reinterpret a BoundedLatticeHom
as an InfTopHom
.
Equations
- BoundedLatticeHom.toInfTopHom f = { toInfHom := { toFun := f.toFun, map_inf' := ⋯ }, map_top' := ⋯ }
Instances For
Reinterpret a BoundedLatticeHom
as a BoundedOrderHom
.
Equations
- BoundedLatticeHom.toBoundedOrderHom f = let __src := ↑f.toLatticeHom; { toOrderHom := { toFun := f.toFun, monotone' := ⋯ }, map_top' := ⋯, map_bot' := ⋯ }
Instances For
Equations
- BoundedLatticeHom.instFunLike = { coe := fun (f : BoundedLatticeHom α β) => f.toFun, coe_injective' := ⋯ }
Equations
- ⋯ = ⋯
Copy of a BoundedLatticeHom
with a new toFun
equal to the old one. Useful to fix
definitional equalities.
Equations
- One or more equations did not get rendered due to their size.
Instances For
id
as a BoundedLatticeHom
.
Equations
- BoundedLatticeHom.id α = let __src := LatticeHom.id α; let __src_1 := BoundedOrderHom.id α; { toLatticeHom := __src, map_top' := ⋯, map_bot' := ⋯ }
Instances For
Equations
- BoundedLatticeHom.instInhabitedBoundedLatticeHom α = { default := BoundedLatticeHom.id α }
Composition of BoundedLatticeHom
s as a BoundedLatticeHom
.
Equations
- One or more equations did not get rendered due to their size.
Instances For
Dual homs #
Reinterpret a supremum homomorphism as an infimum homomorphism between the dual lattices.
Equations
Instances For
Reinterpret an infimum homomorphism as a supremum homomorphism between the dual lattices.
Equations
Instances For
Reinterpret a lattice homomorphism as a lattice homomorphism between the dual lattices.
Equations
- One or more equations did not get rendered due to their size.
Instances For
Reinterpret a bounded lattice homomorphism as a bounded lattice homomorphism between the dual bounded lattices.
Equations
- One or more equations did not get rendered due to their size.
Instances For
Adjoins a ⊤
to the domain and codomain of a SupHom
.
Equations
- SupHom.withTop f = { toFun := WithTop.map ⇑f, map_sup' := ⋯ }
Instances For
Adjoins a ⊥
to the domain and codomain of a SupHom
.
Equations
- SupHom.withBot f = { toSupHom := { toFun := Option.map ⇑f, map_sup' := ⋯ }, map_bot' := ⋯ }
Instances For
Adjoins a ⊤
to the codomain of a SupHom
.
Equations
- SupHom.withTop' f = { toFun := fun (a : WithTop α) => Option.elim a ⊤ ⇑f, map_sup' := ⋯ }
Instances For
Adjoins a ⊥
to the domain of a SupHom
.
Equations
- SupHom.withBot' f = { toSupHom := { toFun := fun (a : WithBot α) => Option.elim a ⊥ ⇑f, map_sup' := ⋯ }, map_bot' := ⋯ }
Instances For
Adjoins a ⊤
to the domain and codomain of an InfHom
.
Equations
- InfHom.withTop f = { toInfHom := { toFun := Option.map ⇑f, map_inf' := ⋯ }, map_top' := ⋯ }
Instances For
Adjoins a ⊥
to the domain and codomain of an InfHom
.
Equations
- InfHom.withBot f = { toFun := Option.map ⇑f, map_inf' := ⋯ }
Instances For
Adjoins a ⊤
to the codomain of an InfHom
.
Equations
- InfHom.withTop' f = { toInfHom := { toFun := fun (a : WithTop α) => Option.elim a ⊤ ⇑f, map_inf' := ⋯ }, map_top' := ⋯ }
Instances For
Adjoins a ⊥
to the codomain of an InfHom
.
Equations
- InfHom.withBot' f = { toFun := fun (a : WithBot α) => Option.elim a ⊥ ⇑f, map_inf' := ⋯ }
Instances For
Adjoins a ⊤
to the domain and codomain of a LatticeHom
.
Equations
- LatticeHom.withTop f = let __src := InfHom.withTop (LatticeHom.toInfHom f); { toSupHom := SupHom.withTop f.toSupHom, map_inf' := ⋯ }
Instances For
Adjoins a ⊥
to the domain and codomain of a LatticeHom
.
Equations
- LatticeHom.withBot f = let __src := InfHom.withBot (LatticeHom.toInfHom f); { toSupHom := { toFun := ⇑(SupHom.withBot f.toSupHom), map_sup' := ⋯ }, map_inf' := ⋯ }
Instances For
Adjoins a ⊤
and ⊥
to the domain and codomain of a LatticeHom
.
Equations
- LatticeHom.withTopWithBot f = { toLatticeHom := LatticeHom.withTop (LatticeHom.withBot f), map_top' := ⋯, map_bot' := ⋯ }
Instances For
Adjoins a ⊥
to the codomain of a LatticeHom
.
Equations
- LatticeHom.withTop' f = let __src := SupHom.withTop' f.toSupHom; let __src_1 := InfHom.withTop' (LatticeHom.toInfHom f); { toSupHom := __src, map_inf' := ⋯ }
Instances For
Adjoins a ⊥
to the domain and codomain of a LatticeHom
.
Equations
- LatticeHom.withBot' f = let __src := SupHom.withBot' f.toSupHom; let __src_1 := InfHom.withBot' (LatticeHom.toInfHom f); { toSupHom := __src.toSupHom, map_inf' := ⋯ }
Instances For
Adjoins a ⊤
and ⊥
to the codomain of a LatticeHom
.
Equations
- LatticeHom.withTopWithBot' f = { toLatticeHom := LatticeHom.withTop' (LatticeHom.withBot' f), map_top' := ⋯, map_bot' := ⋯ }