WithBot, WithTop #
Adding a bot or a top to an order.
Main declarations #
With<Top/Bot> α: EquipsOption αwith the order onαplusnoneas the top/bottom element.
Specialization of Option.getD to values in WithBot α that respects API boundaries.
Equations
- WithBot.unbot' d x = WithBot.recBotCoe d id x
Instances For
Lift a map f : α → β to WithBot α → WithBot β. Implemented using Option.map.
Equations
- WithBot.map f = Option.map f
Instances For
Deconstruct a x : WithBot α to the underlying value in α, given a proof that x ≠ ⊥.
Equations
- WithBot.unbot (some x_2) x_3 = x_2
Instances For
Equations
- WithBot.instTop = { top := ↑⊤ }
Equations
Equations
Equations
There is a general version le_bot_iff, but this lemma does not require a PartialOrder.
A version of bot_lt_iff_ne_bot for WithBot that only requires LT α, not
PartialOrder α.
Equations
- WithBot.preorder = Preorder.mk ⋯ ⋯ ⋯
Equations
Alias of the reverse direction of WithBot.monotone_map_iff.
Alias of the reverse direction of WithBot.strictMono_map_iff.
Equations
- One or more equations did not get rendered due to their size.
Equations
- WithBot.semilatticeInf = SemilatticeInf.mk (WithBot.map₂ fun (x1 x2 : α) => x1 ⊓ x2) ⋯ ⋯ ⋯
Equations
Equations
Equations
Equations
WithTop.toDual is the equivalence sending ⊤ to ⊥ and any a : α to toDual a : αᵒᵈ.
See WithTop.toDualBotEquiv for the related order-iso.
Equations
Instances For
WithTop.ofDual is the equivalence sending ⊤ to ⊥ and any a : αᵒᵈ to ofDual a : α.
See WithTop.toDualBotEquiv for the related order-iso.
Equations
Instances For
WithBot.toDual is the equivalence sending ⊥ to ⊤ and any a : α to toDual a : αᵒᵈ.
See WithBot.toDual_top_equiv for the related order-iso.
Equations
Instances For
WithBot.ofDual is the equivalence sending ⊥ to ⊤ and any a : αᵒᵈ to ofDual a : α.
See WithBot.ofDual_top_equiv for the related order-iso.
Equations
Instances For
Specialization of Option.getD to values in WithTop α that respects API boundaries.
Equations
- WithTop.untop' d x = WithTop.recTopCoe d id x
Instances For
Lift a map f : α → β to WithTop α → WithTop β. Implemented using Option.map.
Equations
- WithTop.map f = Option.map f
Instances For
Deconstruct a x : WithTop α to the underlying value in α, given a proof that x ≠ ⊤.
Equations
- WithTop.untop (some x_2) x_3 = x_2
Instances For
Equations
- WithTop.instBot = { bot := ↑⊥ }
Equations
Equations
Equations
There is a general version top_le_iff, but this lemma does not require a PartialOrder.
A version of lt_top_iff_ne_top for WithTop that only requires LT α, not
PartialOrder α.
Equations
- WithTop.preorder = Preorder.mk ⋯ ⋯ ⋯
Equations
Alias of the reverse direction of WithTop.monotone_map_iff.
Alias of the reverse direction of WithTop.strictMono_map_iff.
Equations
- WithTop.semilatticeInf = SemilatticeInf.mk (Option.liftOrGet fun (x1 x2 : α) => x1 ⊓ x2) ⋯ ⋯ ⋯
Equations
- WithTop.semilatticeSup = SemilatticeSup.mk (WithTop.map₂ fun (x1 x2 : α) => x1 ⊔ x2) ⋯ ⋯ ⋯
Equations
Equations
Equations
Equations
- x✝¹.decidableLE x✝ = decidable_of_decidable_of_iff ⋯
Equations
- x✝¹.decidableLT x✝ = decidable_of_decidable_of_iff ⋯