Repository navigation
chore: generalize ConditionallyCompleteLinearOrderBot lemmas - #45436
astrainfinita wants to merge 67 commits into
Conversation
…or `sSup` and `sInf` In a subsequent PR, some assumptions will be added to `ordConnectedSubsetConditionallyCompleteLinearOrderOfBotTop`.
# Conflicts: # Mathlib/Algebra/Order/Nonneg/Lattice.lean # Mathlib/Basic/NNReal/Defs.lean # Mathlib/Order/CompleteLatticeIntervals.lean
…hTop` This PR moves the material on `sSup` and `sInf` on `WithTop α` and `WithBot α` from `Order/ConditionallyCompleteLattice/Basic` and `Order/ConditionallyCompleteLattice/Indexed` to a new file `Order/ConditionallyCompleteLattice/WithTop`. This material was scattered over five places in the two files, although the rest of these files does not depend on it.
…nces on `WithTop` Adds `OrderSupSet (WithTop α)` and `OrderInfSet (WithTop α)` instances (and their `WithBot` duals), and cleans up the API for `sSup` and `sInf` on `WithTop`.
PR summary 00bcab2bb5
|
| Files | Import difference |
|---|---|
| ../mathlib-ci/scripts/pr_summary/import_trans_difference.sh all | |
| There are 3324 files with changed transitive imports taking up over 154643 characters: this is too many to display! | |
You can run this locally from your mathlib4 directory: |
git clone https://github.com/leanprover-community/mathlib-ci.git ../mathlib-ci
Declarations diff (regex)
+ OrderSupSet.chooseBot
+ OrderSupSet.chooseBot_sSup_empty_of_noBotOrder
+ OrderSupSet.chooseBot_sSup_of_not_exists
+ Set.OrdConnected.coe_sInf
+ Set.OrdConnected.coe_sSup
+ Set.OrdConnected.conditionallyCompleteLinearOrder
+ Set.OrdConnected.csInf_image_mem
+ Set.OrdConnected.csSup_image_mem
+ Set.OrdConnected.sInf_empty_of_noTopOrder
+ Set.OrdConnected.sSup_empty_of_noBotOrder
+ Subtype.isLUB_of_csSup_image_mem
+ bddBelow_preimage_coe
+ coe_sInf'
+ exists_isLUB_cond
+ instOrderInfSet
+ instSupSet
+ instance : NoBotOrder ℤ := ⟨fun x ↦ ⟨x - 1, (Int.sub_one_lt_of_le le_rfl).not_ge⟩⟩
+ instance : NoTopOrder ℤ := ⟨fun x ↦ ⟨x + 1, (Int.lt_add_one_of_le le_rfl).not_ge⟩⟩
+ isCompl_range_coe
+ isGLB_coe_iff
+ isGLB_top_iff
+ isLUB_coe_iff
+ isLUB_top_iff
+ lowerBounds_preimage_coe
+ sInf_eq_coe_iff
+ sInf_eq_top_iff
+ sSup_eq_coe_iff
+ sSup_eq_top_iff
++ instOrderSupSet
- WithTop.coe_sInf'
- instance [SupSet α] : SupSet (WithTop α)
- ordConnectedSubsetConditionallyCompleteLinearOrder
--++ instance [ConditionallyCompleteLinearOrder α] :
You can run this locally as follows
## from your `mathlib4` directory:
git clone https://github.com/leanprover-community/mathlib-ci.git ../mathlib-ci
## summary with just the declaration names:
../mathlib-ci/scripts/pr_summary/declarations_diff.sh <optional_commit>
## more verbose report:
../mathlib-ci/scripts/pr_summary/declarations_diff.sh long <optional_commit>The doc-module for scripts/pr_summary/declarations_diff.sh in the mathlib-ci repository contains some details about this script.
Declarations diff (Lean)
✅ Lean-aware diff — post-build, computed from the Lean environment (commit
00bcab2).
- +52 new declarations
- −7 removed declarations
+ConditionallyCompleteLattice.exists_isGLB_cond
+ConditionallyCompleteLattice.exists_isLUB_cond
-ConditionallyCompleteLattice.isGLB_csInf
-ConditionallyCompleteLattice.isLUB_csSup
-ConditionallyCompleteLattice.toInfSet
+ConditionallyCompleteLattice.toOrderInfSet
+ConditionallyCompleteLattice.toOrderSupSet
-ConditionallyCompleteLattice.toSupSet
-ConditionallyCompleteLinearOrderBot.csSup_empty
+Int.instNoBotOrder
+Int.instNoTopOrder
+OrderInfSet.chooseTop
+OrderInfSet.chooseTop_sInf_empty_of_noTopOrder
+OrderInfSet.chooseTop_sInf_of_not_exists
+OrderInfSet.choose_sInf
+OrderSupSet.chooseBot
+OrderSupSet.chooseBot_sSup_empty_of_noBotOrder
+OrderSupSet.chooseBot_sSup_of_not_exists
+OrderSupSet.choose_sSup
+Seminorm.instOrderSupSet
+Set.OrdConnected.coe_sInf
+Set.OrdConnected.coe_sSup
+Set.OrdConnected.conditionallyCompleteLinearOrder
+Set.OrdConnected.csInf_image_mem
+Set.OrdConnected.csSup_image_mem
+Set.OrdConnected.sInf_empty_of_noTopOrder
+Set.OrdConnected.sSup_empty_of_noBotOrder
+Subtype.isGLB_of_csInf_image_mem
+Subtype.isLUB_of_csSup_image_mem
-WellFoundedLT.min.congr_simp
+WithBot.bddAbove_preimage_coe
+WithBot.instOrderInfSet
+WithBot.instOrderSupSet
+WithBot.isCompl_range_coe
+WithBot.isGLB_bot_iff
+WithBot.isGLB_coe_iff
+WithBot.isLUB_bot_iff
+WithBot.isLUB_coe_iff
+WithBot.sInf_eq_bot_iff
+WithBot.sInf_eq_coe_iff
+WithBot.sSup_eq_bot_iff
+WithBot.sSup_eq_coe_iff
+WithBot.upperBounds_preimage_coe
+WithTop.bddBelow_preimage_coe
+WithTop.instOrderInfSet
+WithTop.instOrderSupSet
+WithTop.isCompl_range_coe
+WithTop.isGLB_coe_iff
+WithTop.isGLB_top_iff
+WithTop.isLUB_coe_iff
+WithTop.isLUB_top_iff
+WithTop.lowerBounds_preimage_coe
+WithTop.sInf_eq_coe_iff
+WithTop.sInf_eq_top_iff
+WithTop.sSup_eq_coe_iff
+WithTop.sSup_eq_top_iff
+exists_isGLB_cond
+exists_isLUB_cond
-ordConnectedSubsetConditionallyCompleteLinearOrderNo changes to strong technical debt.
Increase in weak tech debt: (relative, absolute) = (1.00, 0.00)
| Current number | Change | Type (weak) |
|---|---|---|
| 5127 | 1 | exposed public sections |
Current commit 00bcab2bb5
Reference commit ee6c124192
This script lives in the mathlib-ci repository. To run it locally, from your mathlib4 directory:
git clone https://github.com/leanprover-community/mathlib-ci.git ../mathlib-ci
../mathlib-ci/scripts/reporting/technical-debt-metrics.py pr_summary
- The
relativevalue is the weighted sum of the differences with weight given by the inverse of the current value of the statistic. - The
absolutevalue is therelativevalue divided by the total sum of the inverses of the current values (i.e. the weighted average of the differences).
…llyCompleteLinearOrderBot`
…nditionallyCompleteLinearOrderBot`" This reverts commit 166d9c7.
|
This pull request has conflicts, please merge |
Refactor `ConditionallyCompleteLattice` to extend `OrderSupSet` and `OrderInfSet` instead of `SupSet` and `InfSet`, and drop the now-redundant `csSup_empty` field from `ConditionallyCompleteLinearOrderBot`. `OrderSupSet` implies `sSup ∅ = ⊥`, so we no longer need some nonemptiness assumptions. Also add shortcut instances `NoBotOrder ℤ` and `NoTopOrder ℤ` for `ConditionallyCompleteLinearOrder ℤ`. The cleanup of `ConditionallyCompleteLinearOrderBot` API is split into #45436 and #45438, and the typeclass itself will be deprecated in #45438.
|
This PR/issue depends on: |
…over-community#35674) Refactor `ConditionallyCompleteLattice` to extend `OrderSupSet` and `OrderInfSet` instead of `SupSet` and `InfSet`, and drop the now-redundant `csSup_empty` field from `ConditionallyCompleteLinearOrderBot`. `OrderSupSet` implies `sSup ∅ = ⊥`, so we no longer need some nonemptiness assumptions. Also add shortcut instances `NoBotOrder ℤ` and `NoTopOrder ℤ` for `ConditionallyCompleteLinearOrder ℤ`. The cleanup of `ConditionallyCompleteLinearOrderBot` API is split into leanprover-community#45436 and leanprover-community#45438, and the typeclass itself will be deprecated in leanprover-community#45438.
OrderSupSetinConditionallyCompleteLattice#35674diff