Skip to content

Commit e64ff0f

Browse files
committed
chore(Data/Set): split some chunks off large file Data/Set/Lattice.lean (#23098)
This PR tries to split some meaningful chunks off of `Mathlib.Data.Set.Lattice`: * The new file `Mathlib.Data.Set.BooleanAlgebra` contains the `CompleteAtomicBooleanAlgebra (Set ɑ)` instance (and nothing more) * The new file `Mathlib.Data.Set.Lattice.Image` contains results on the interaction between the complete lattice structure and `image`, `preimage`, `image2`, `MapsTo`, `InjOn`, ... This leaves `Mathlib.Data.Set.Lattice` focussed on interactions between the lattice operators themselves, more or less. (Although there is a bit that doesn't really fit with lattice theory and might move to `Data.Set.Sigma` except it would screw up the import direction...) I first tried designing this split by following the import structure but found nothing useful to guide us there: the lemmas that could be upstreamed or at least moved to another file seem to follow no real pattern. So I went instead by looking at the lemma contents entirely and hoped for `lake exe shake` to catch some import improvements (we get a few tens of files with a few import reductions, and it happens that one of those, `Mathlib.Data.Finset.Lattice.Fold` is on the long pole).
1 parent 45ff492 commit e64ff0f

File tree

27 files changed

+671
-605
lines changed

27 files changed

+671
-605
lines changed

Mathlib.lean

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3199,6 +3199,7 @@ import Mathlib.Data.Seq.WSeq
31993199
import Mathlib.Data.Set.Accumulate
32003200
import Mathlib.Data.Set.Basic
32013201
import Mathlib.Data.Set.BoolIndicator
3202+
import Mathlib.Data.Set.BooleanAlgebra
32023203
import Mathlib.Data.Set.Card
32033204
import Mathlib.Data.Set.Card.Arithmetic
32043205
import Mathlib.Data.Set.CoeSort
@@ -3222,6 +3223,7 @@ import Mathlib.Data.Set.Image
32223223
import Mathlib.Data.Set.Inclusion
32233224
import Mathlib.Data.Set.Insert
32243225
import Mathlib.Data.Set.Lattice
3226+
import Mathlib.Data.Set.Lattice.Image
32253227
import Mathlib.Data.Set.List
32263228
import Mathlib.Data.Set.MemPartition
32273229
import Mathlib.Data.Set.Monotone

Mathlib/Algebra/Group/Pointwise/Set/Basic.lean

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ Authors: Johan Commelin, Floris van Doorn, Yaël Dillies
66
import Mathlib.Algebra.Group.Equiv.Basic
77
import Mathlib.Algebra.Group.Prod
88
import Mathlib.Algebra.Order.Monoid.Unbundled.Pow
9-
import Mathlib.Data.Set.Lattice
9+
import Mathlib.Data.Set.Lattice.Image
1010
import Mathlib.Tactic.MinImports
1111

1212
/-!

Mathlib/Algebra/Group/Subsemigroup/Basic.lean

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ Authors: Johannes Hölzl, Kenny Lau, Johan Commelin, Mario Carneiro, Kevin Buzza
55
Amelia Livingston, Yury Kudryashov, Yakov Pechersky
66
-/
77
import Mathlib.Algebra.Group.Subsemigroup.Defs
8-
import Mathlib.Data.Set.Lattice
8+
import Mathlib.Data.Set.Lattice.Image
99

1010
/-!
1111
# Subsemigroups: `CompleteLattice` structure

Mathlib/Algebra/Order/Group/Action.lean

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ Authors: Eric Wieser
66
import Mathlib.Algebra.Group.Action.Defs
77
import Mathlib.Algebra.Order.Monoid.Unbundled.Defs
88
import Mathlib.Order.ConditionallyCompleteLattice.Basic
9+
import Mathlib.Tactic.Cases
910

1011
/-!
1112
# Results about `CovariantClass G α HSMul.hSMul LE.le`

Mathlib/CategoryTheory/Sites/Sieves.lean

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@ Copyright (c) 2020 Bhavik Mehta. All rights reserved.
33
Released under Apache 2.0 license as described in the file LICENSE.
44
Authors: Bhavik Mehta, Edward Ayers
55
-/
6-
import Mathlib.Data.Set.Lattice
76
import Mathlib.CategoryTheory.Limits.Shapes.Pullback.HasPullback
7+
import Mathlib.Data.Set.BooleanAlgebra
88

99
/-!
1010
# Theory of sieves

Mathlib/CategoryTheory/Subpresheaf/Basic.lean

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ Released under Apache 2.0 license as described in the file LICENSE.
44
Authors: Andrew Yang, Joël Riou
55
-/
66
import Mathlib.CategoryTheory.Elementwise
7-
import Mathlib.Data.Set.Lattice
7+
import Mathlib.Data.Set.Lattice.Image
88

99
/-!
1010

Mathlib/Data/Finset/Lattice/Fold.lean

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ Authors: Mario Carneiro
55
-/
66
import Mathlib.Data.Finset.Fold
77
import Mathlib.Data.Multiset.Lattice
8-
import Mathlib.Data.Set.Lattice
8+
import Mathlib.Data.Set.BooleanAlgebra
99
import Mathlib.Order.Hom.Lattice
1010
import Mathlib.Order.Nat
1111

Mathlib/Data/Finset/NAry.lean

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ Authors: Yaël Dillies
55
-/
66
import Mathlib.Data.Finset.Lattice.Prod
77
import Mathlib.Data.Finite.Prod
8+
import Mathlib.Data.Set.Lattice.Image
89

910
/-!
1011
# N-ary images of finsets

Mathlib/Data/Nat/Pairing.lean

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ Authors: Leonardo de Moura, Mario Carneiro
55
-/
66
import Mathlib.Algebra.Notation.Prod
77
import Mathlib.Data.Nat.Sqrt
8-
import Mathlib.Data.Set.Lattice
8+
import Mathlib.Data.Set.Lattice.Image
99

1010
/-!
1111
# Naturals pairing function

Mathlib/Data/Rel.lean

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ Copyright (c) 2018 Jeremy Avigad. All rights reserved.
33
Released under Apache 2.0 license as described in the file LICENSE.
44
Authors: Jeremy Avigad
55
-/
6-
import Mathlib.Data.Set.Lattice
6+
import Mathlib.Data.Set.BooleanAlgebra
77
import Mathlib.Tactic.AdaptationNote
88

99
/-!

0 commit comments

Comments
 (0)