Minimality and Maximality #
This file defines minimality and maximality of an element with respect to a predicate P
on
an ordered type α
.
Main declarations #
Implementation Details #
This file underwent a refactor from a version where minimality and maximality were defined using
sets rather than predicates, and with an unbundled order relation rather than a LE
instance.
A side effect is that it has become less straightforward to state that something is minimal
with respect to a relation that is not defeq to the default LE
.
One possible way would be with a type synonym,
and another would be with an ad hoc LE
instance and @
notation.
This was not an issue in practice anywhere in mathlib at the time of the refactor,
but it may be worth re-examining this to make it easier in the future; see the TODO below.
TODO #
In the linearly ordered case, versions of lemmas like
minimal_mem_image
will hold withMonotoneOn
/AntitoneOn
assumptions rather than the strongerx ≤ y ↔ f x ≤ f y
assumptions.Set.maximal_iff_forall_insert
andSet.minimal_iff_forall_diff_singleton
will generalize to lemmas about covering in the case of anIsStronglyAtomic
/IsStronglyCoatomic
order.Finset
versions of the lemmas about sets.API to allow for easily expressing min/maximality with respect to an arbitrary non-
LE
relation.
Alias of the reverse direction of minimal_toDual
.
Alias of the forward direction of minimal_toDual
.
Alias of the reverse direction of maximal_toDual
.
Alias of the forward direction of maximal_toDual
.
Alias of the forward direction of not_minimal_iff_exists_lt
.
Alias of the forward direction of not_maximal_iff_exists_gt
.
If P y
holds, and everything satisfying P
is above y
, then y
is the unique minimal
element satisfying P
.
If P y
holds, and everything satisfying P
is below y
, then y
is the unique maximal
element satisfying P
.
If t
is an antichain shadowing and including the set of maximal elements of s
,
then t
is the set of maximal elements of s
.
If t
is an antichain shadowed by and including the set of minimal elements of s
,
then t
is the set of minimal elements of s
.
If two sets are antitonically order isomorphic, their minimals/maximals are too.
Equations
- One or more equations did not get rendered due to their size.
Instances For
If two sets are antitonically order isomorphic, their maximals/minimals are too.
Equations
- One or more equations did not get rendered due to their size.