Up-sets and down-sets #
This file defines upper and lower sets in an order.
Main declarations #
IsUpperSet
: Predicate for a set to be an upper set. This means every element greater than a member of the set is in the set itself.IsLowerSet
: Predicate for a set to be a lower set. This means every element less than a member of the set is in the set itself.UpperSet
: The type of upper sets.LowerSet
: The type of lower sets.upperClosure
: The greatest upper set containing a set.lowerClosure
: The least lower set containing a set.UpperSet.Ici
: Principal upper set.Set.Ici
as an upper set.UpperSet.Ioi
: Strict principal upper set.Set.Ioi
as an upper set.LowerSet.Iic
: Principal lower set.Set.Iic
as a lower set.LowerSet.Iio
: Strict principal lower set.Set.Iio
as a lower set.
Notation #
×ˢ
is notation forUpperSet.prod
/LowerSet.prod
.
Notes #
Upper sets are ordered by reverse inclusion. This convention is motivated by the fact that this
makes them order-isomorphic to lower sets and antichains, and matches the convention on Filter
.
TODO #
Lattice structure on antichains. Order equivalence between upper/lower sets and antichains.
Unbundled upper/lower sets #
Alias of the reverse direction of isLowerSet_preimage_ofDual_iff
.
Alias of the reverse direction of isUpperSet_preimage_ofDual_iff
.
Alias of the reverse direction of isLowerSet_preimage_toDual_iff
.
Alias of the reverse direction of isUpperSet_preimage_toDual_iff
.
Alias of the forward direction of isUpperSet_iff_Ici_subset
.
Alias of the forward direction of isLowerSet_iff_Iic_subset
.
Bundled upper/lower sets #
Order #
Equations
- UpperSet.instTopUpperSet = { top := { carrier := ∅, upper' := (_ : IsUpperSet ∅) } }
Equations
- UpperSet.instBotUpperSet = { bot := { carrier := Set.univ, upper' := (_ : IsUpperSet Set.univ) } }
Equations
- UpperSet.instSupSetUpperSet = { sSup := fun (S : Set (UpperSet α)) => { carrier := ⋂ s ∈ S, ↑s, upper' := (_ : IsUpperSet (⋂ i ∈ S, ↑i)) } }
Equations
- UpperSet.instInfSetUpperSet = { sInf := fun (S : Set (UpperSet α)) => { carrier := ⋃ s ∈ S, ↑s, upper' := (_ : IsUpperSet (⋃ i ∈ S, ↑i)) } }
Equations
- One or more equations did not get rendered due to their size.
Equations
- LowerSet.instSupSetLowerSet = { sSup := fun (S : Set (LowerSet α)) => { carrier := ⋃ s ∈ S, ↑s, lower' := (_ : IsLowerSet (⋃ i ∈ S, ↑i)) } }
Equations
- LowerSet.instInfSetLowerSet = { sInf := fun (S : Set (LowerSet α)) => { carrier := ⋂ s ∈ S, ↑s, lower' := (_ : IsLowerSet (⋂ i ∈ S, ↑i)) } }
Equations
- One or more equations did not get rendered due to their size.
Complement #
The complement of a lower set as an upper set.
Equations
- UpperSet.compl s = { carrier := (↑s)ᶜ, lower' := (_ : IsLowerSet (↑s)ᶜ) }
Instances For
The complement of a lower set as an upper set.
Equations
- LowerSet.compl s = { carrier := (↑s)ᶜ, upper' := (_ : IsUpperSet (↑s)ᶜ) }
Instances For
Equations
- One or more equations did not get rendered due to their size.
Equations
- One or more equations did not get rendered due to their size.
Map #
Principal sets #
The smallest upper set containing a given element.
Equations
- UpperSet.Ici a = { carrier := Set.Ici a, upper' := (_ : IsUpperSet (Set.Ici a)) }
Instances For
The smallest upper set containing a given element.
Equations
- UpperSet.Ioi a = { carrier := Set.Ioi a, upper' := (_ : IsUpperSet (Set.Ioi a)) }
Instances For
Principal lower set. Set.Iic
as a lower set. The smallest lower set containing a given
element.
Equations
- LowerSet.Iic a = { carrier := Set.Iic a, lower' := (_ : IsLowerSet (Set.Iic a)) }
Instances For
Strict principal lower set. Set.Iio
as a lower set.
Equations
- LowerSet.Iio a = { carrier := Set.Iio a, lower' := (_ : IsLowerSet (Set.Iio a)) }
Instances For
Equations
- instDecidablePredMemUpperClosure = inst
Equations
- instDecidablePredMemLowerClosure = inst
upperClosure
forms a reversed Galois insertion with the coercion from upper sets to sets.
Equations
- One or more equations did not get rendered due to their size.
Instances For
lowerClosure
forms a Galois insertion with the coercion from lower sets to sets.
Equations
- One or more equations did not get rendered due to their size.
Instances For
Alias of the forward direction of bddAbove_lowerClosure
.
Alias of the reverse direction of bddAbove_lowerClosure
.
Alias of the forward direction of bddBelow_upperClosure
.
Alias of the reverse direction of bddBelow_upperClosure
.
Set Difference #
The biggest lower subset of a lower set s
disjoint from a set t
.
Equations
- LowerSet.sdiff s t = { carrier := ↑s \ ↑(upperClosure t), lower' := (_ : IsLowerSet (↑s \ ↑(upperClosure t))) }
Instances For
The biggest lower subset of a lower set s
not containing an element a
.
Equations
- LowerSet.erase s a = { carrier := ↑s \ ↑(UpperSet.Ici a), lower' := (_ : IsLowerSet (↑s \ ↑(UpperSet.Ici a))) }
Instances For
The biggest upper subset of a upper set s
disjoint from a set t
.
Equations
- UpperSet.sdiff s t = { carrier := ↑s \ ↑(lowerClosure t), upper' := (_ : IsUpperSet (↑s \ ↑(lowerClosure t))) }
Instances For
The biggest upper subset of a upper set s
not containing an element a
.
Equations
- UpperSet.erase s a = { carrier := ↑s \ ↑(LowerSet.Iic a), upper' := (_ : IsUpperSet (↑s \ ↑(LowerSet.Iic a))) }
Instances For
Product #
The product of two upper sets as an upper set.
Equations
- UpperSet.prod s t = { carrier := ↑s ×ˢ ↑t, upper' := (_ : IsUpperSet (s.carrier ×ˢ ↑t)) }
Instances For
The product of two lower sets as a lower set.
Equations
- LowerSet.prod s t = { carrier := ↑s ×ˢ ↑t, lower' := (_ : IsLowerSet (s.carrier ×ˢ ↑t)) }