Successor and predecessor limits #
We define the predicate Order.IsSuccPrelimit
for "successor pre-limits", values that don't cover
any others. They are so named since they can't be the successors of anything smaller. We define
Order.IsPredPrelimit
analogously, and prove basic results.
For some applications, it is desirable to exclude minimal elements from being successor limits, or
maximal elements from being predecessor limits. As such, we also provide Order.IsSuccLimit
and
Order.IsPredLimit
, which exclude these cases.
TODO #
The plan is to eventually replace Ordinal.IsLimit
and Cardinal.IsLimit
with the common
predicate Order.IsSuccLimit
.
Successor limits #
A successor pre-limit is a value that doesn't cover any other.
It's so named because in a successor order, a successor pre-limit can't be the successor of anything smaller.
Use IsSuccLimit
if you want to exclude the case of a minimal element.
Equations
- Order.IsSuccPrelimit a = ∀ (b : α), ¬b ⋖ a
Instances For
Alias of Order.IsSuccPrelimit.of_dense
.
Alias of Order.IsSuccPrelimit.of_dense
.
A successor limit is a value that isn't minimal and doesn't cover any other.
It's so named because in a successor order, a successor limit can't be the successor of anything smaller.
This previously allowed the element to be minimal. This usage is now covered by IsSuccPrelimit
.
Equations
- Order.IsSuccLimit a = (¬IsMin a ∧ Order.IsSuccPrelimit a)
Instances For
Alias of IsMin.isSuccPrelimit
.
Alias of Order.isSuccPrelimit_bot
.
Given j < i
with i
a prelimit, IsSuccPrelimit.mid
picks an arbitrary element strictly
between j
and i
.
Equations
- hi.mid hj = Classical.indefiniteDescription (Membership.mem (Set.Ioo j i)) ⋯
Instances For
Alias of Order.IsSuccPrelimit.isMin_of_noMax
.
Alias of Order.isSuccPrelimit_iff_of_noMax
.
Alias of Order.isSuccPrelimit_of_succ_ne
.
See not_isSuccPrelimit_iff
for a version that states that a
is a successor of a value other
than itself.
Alias of Order.mem_range_succ_of_not_isSuccPrelimit
.
See not_isSuccPrelimit_iff
for a version that states that a
is a successor of a value other
than itself.
Alias of Order.mem_range_succ_or_isSuccPrelimit
.
Alias of Order.isSuccPrelimit_of_succ_lt
.
Alias of Order.isSuccPrelimit_iff_succ_lt
.
Alias of Order.isSuccPrelimit_iff_succ_ne
.
Alias of Order.not_isSuccPrelimit_iff'
.
Predecessor limits #
A predecessor pre-limit is a value that isn't covered by any other.
It's so named because in a predecessor order, a predecessor pre-limit can't be the predecessor of anything smaller.
Use IsPredLimit
to exclude the case of a maximal element.
Equations
- Order.IsPredPrelimit a = ∀ (b : α), ¬a ⋖ b
Instances For
Alias of Order.IsPredPrelimit.of_dense
.
Alias of Order.IsPredPrelimit.of_dense
.
Alias of the reverse direction of Order.isSuccPrelimit_toDual_iff
.
Alias of the reverse direction of Order.isPredPrelimit_toDual_iff
.
Alias of the reverse direction of Order.isSuccPrelimit_toDual_iff
.
Alias of the reverse direction of Order.isSuccPrelimit_toDual_iff
.
Alias of the reverse direction of Order.isPredPrelimit_toDual_iff
.
Alias of the reverse direction of Order.isPredPrelimit_toDual_iff
.
A predecessor limit is a value that isn't maximal and doesn't cover any other.
It's so named because in a predecessor order, a predecessor limit can't be the predecessor of anything larger.
This previously allowed the element to be maximal. This usage is now covered by IsPredPreLimit
.
Equations
- Order.IsPredLimit a = (¬IsMax a ∧ Order.IsPredPrelimit a)
Instances For
Alias of the reverse direction of Order.isSuccLimit_toDual_iff
.
Alias of the reverse direction of Order.isPredLimit_toDual_iff
.
Alias of IsMax.isPredPrelimit
.
Alias of Order.isPredPrelimit_top
.
Alias of Order.IsPredPrelimit.isMax_of_noMin
.
Alias of Order.isPredPrelimit_iff_of_noMin
.
Alias of Order.isPredPrelimit_of_pred_ne
.
See not_isPredPrelimit_iff
for a version that states that a
is a successor of a value other
than itself.
Alias of Order.mem_range_pred_of_not_isPredPrelimit
.
See not_isPredPrelimit_iff
for a version that states that a
is a successor of a value other
than itself.
Alias of Order.mem_range_pred_or_isPredPrelimit
.
Alias of Order.isPredPrelimit_of_pred_lt
.
Alias of Order.isPredPrelimit_iff_lt_pred
.
Alias of Order.IsPredPrelimit.isMax
.
Induction principles #
A value can be built by building it on successors and successor pre-limits.
Equations
- Order.isSuccPrelimitRecOn b hs hl = if hb : Order.IsSuccPrelimit b then hl b hb else cast ⋯ (hs (Classical.choose ⋯) ⋯)
Instances For
A value can be built by building it on predecessors and predecessor pre-limits.
Equations
- Order.isPredPrelimitRecOn b hs hl = Order.isSuccPrelimitRecOn b hs fun (a : αᵒᵈ) (ha : Order.IsSuccPrelimit a) => hl a ⋯
Instances For
A value can be built by building it on minimal elements, successors, and successor limits.
Equations
- Order.isSuccLimitRecOn b hm hs hl = Order.isSuccPrelimitRecOn b hs fun (a : α) (ha : Order.IsSuccPrelimit a) => if h : IsMin a then hm a h else hl a ⋯
Instances For
A value can be built by building it on maximal elements, predecessors, and predecessor limits.
Equations
- Order.isPredLimitRecOn b hm hs hl = Order.isSuccLimitRecOn b hm hs fun (a : αᵒᵈ) (ha : Order.IsSuccLimit a) => hl a ⋯
Instances For
Recursion principle on a well-founded partial SuccOrder
.
Equations
- One or more equations did not get rendered due to their size.
Instances For
Recursion principle on a well-founded partial SuccOrder
, separating out the case of a
minimal element.
Equations
- SuccOrder.limitRecOn b hm hs hl = SuccOrder.prelimitRecOn b hs fun (a : α) (ha : Order.IsSuccPrelimit a) (IH : (b : α) → b < a → C b) => if h : IsMin a then hm a h else hl a ⋯ IH
Instances For
Recursion principle on a well-founded partial PredOrder
.
Equations
- PredOrder.prelimitRecOn b hp hl = SuccOrder.prelimitRecOn b hp fun (a : αᵒᵈ) (ha : Order.IsSuccPrelimit a) => hl a ⋯
Instances For
Recursion principle on a well-founded partial PredOrder
, separating out the case of a
maximal element.
Equations
- PredOrder.limitRecOn b hm hs hl = SuccOrder.limitRecOn b hm hs fun (a : αᵒᵈ) (ha : Order.IsSuccLimit a) => hl a ⋯