Skip to content

Commit d2af992

Browse files
2 parents 820b38f + 6179d6d commit d2af992

32 files changed

Lines changed: 1340 additions & 265 deletions

File tree

Mathlib.lean

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -112,7 +112,6 @@ public import Mathlib.Algebra.Category.CommAlgCat.FiniteType
112112
public import Mathlib.Algebra.Category.CommAlgCat.Monoidal
113113
public import Mathlib.Algebra.Category.CommBialgCat
114114
public import Mathlib.Algebra.Category.CommHopfAlgCat
115-
public import Mathlib.Algebra.Category.ContinuousCohomology.Basic
116115
public import Mathlib.Algebra.Category.FGModuleCat.Abelian
117116
public import Mathlib.Algebra.Category.FGModuleCat.Basic
118117
public import Mathlib.Algebra.Category.FGModuleCat.Colimits
@@ -1442,6 +1441,7 @@ public import Mathlib.AlgebraicGeometry.Morphisms.WeaklyEtale
14421441
public import Mathlib.AlgebraicGeometry.Noetherian
14431442
public import Mathlib.AlgebraicGeometry.Normalization
14441443
public import Mathlib.AlgebraicGeometry.OpenImmersion
1444+
public import Mathlib.AlgebraicGeometry.OrderOfVanishing
14451445
public import Mathlib.AlgebraicGeometry.Over
14461446
public import Mathlib.AlgebraicGeometry.PointsPi
14471447
public import Mathlib.AlgebraicGeometry.ProjectiveSpectrum.Basic
@@ -3242,6 +3242,7 @@ public import Mathlib.CategoryTheory.Preadditive.CommGrp_
32423242
public import Mathlib.CategoryTheory.Preadditive.Comma
32433243
public import Mathlib.CategoryTheory.Preadditive.EilenbergMoore
32443244
public import Mathlib.CategoryTheory.Preadditive.EndoFunctor
3245+
public import Mathlib.CategoryTheory.Preadditive.FreydCategory.Homotopy
32453246
public import Mathlib.CategoryTheory.Preadditive.FunctorCategory
32463247
public import Mathlib.CategoryTheory.Preadditive.HomOrthogonal
32473248
public import Mathlib.CategoryTheory.Preadditive.Indization
@@ -3381,6 +3382,7 @@ public import Mathlib.CategoryTheory.Sites.JointlySurjective
33813382
public import Mathlib.CategoryTheory.Sites.LeftExact
33823383
public import Mathlib.CategoryTheory.Sites.Limits
33833384
public import Mathlib.CategoryTheory.Sites.LocalProperties
3385+
public import Mathlib.CategoryTheory.Sites.LocalSite
33843386
public import Mathlib.CategoryTheory.Sites.Localization
33853387
public import Mathlib.CategoryTheory.Sites.LocallyBijective
33863388
public import Mathlib.CategoryTheory.Sites.LocallyFullyFaithful
@@ -6379,6 +6381,8 @@ public import Mathlib.RepresentationTheory.Equiv
63796381
public import Mathlib.RepresentationTheory.FDRep
63806382
public import Mathlib.RepresentationTheory.FinGroupCharZero
63816383
public import Mathlib.RepresentationTheory.FiniteIndex
6384+
public import Mathlib.RepresentationTheory.Homological.ContCohomology.Basic
6385+
public import Mathlib.RepresentationTheory.Homological.ContCohomology.LowDegree
63826386
public import Mathlib.RepresentationTheory.Homological.FiniteCyclic
63836387
public import Mathlib.RepresentationTheory.Homological.GroupCohomology.Basic
63846388
public import Mathlib.RepresentationTheory.Homological.GroupCohomology.FiniteCyclic

Mathlib/Algebra/Category/ContinuousCohomology/Basic.lean

Lines changed: 0 additions & 215 deletions
This file was deleted.

Mathlib/Algebra/Group/WithOne/Defs.lean

Lines changed: 35 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -125,15 +125,15 @@ lemma recOneCoe_coe {motive : WithOne α → Sort*} (h₁ h₂) (a : α) :
125125
rfl
126126

127127
/-- Deconstruct an `x : WithOne α` to the underlying value in `α`, given a proof that `x ≠ 1`. -/
128-
@[to_additive unzero
128+
@[to_additive
129129
/-- Deconstruct an `x : WithZero α` to the underlying value in `α`, given a proof that `x ≠ 0`. -/]
130130
def unone : ∀ {x : WithOne α}, x ≠ 1 → α | (x : α), _ => x
131131

132-
@[to_additive (attr := simp) unzero_coe]
132+
@[to_additive (attr := simp)]
133133
theorem unone_coe {x : α} (hx : (x : WithOne α) ≠ 1) : unone hx = x :=
134134
rfl
135135

136-
@[to_additive (attr := simp) coe_unzero]
136+
@[to_additive (attr := simp)]
137137
lemma coe_unone : ∀ {x : WithOne α} (hx : x ≠ 1), unone hx = x
138138
| (x : α), _ => rfl
139139

@@ -194,4 +194,36 @@ instance instCommMonoid [CommSemigroup α] : CommMonoid (WithOne α) where
194194
theorem coe_inv [Inv α] (a : α) : ((a⁻¹ : α) : WithOne α) = (a : WithOne α)⁻¹ :=
195195
rfl
196196

197+
/--
198+
Specialization of `Option.getD` to values in `WithOne α` that respects API boundaries.
199+
-/
200+
@[to_additive
201+
/-- Specialization of `Option.getD` to values in `WithZero α` that respects API boundaries. -/]
202+
def unoneD (d : α) (x : WithOne α) : α := recOneCoe d id x
203+
204+
@[to_additive (attr := simp)]
205+
theorem unoneD_one (d : α) : unoneD d 1 = d :=
206+
rfl
207+
208+
@[to_additive (attr := simp)]
209+
theorem unoneD_coe (d x : α) : unoneD d x = x :=
210+
rfl
211+
212+
@[to_additive]
213+
theorem unoneD_eq_iff {d y : α} {x : WithOne α} : unoneD d x = y ↔ x = y ∨ x = 1 ∧ y = d := by
214+
induction x <;> simp [@eq_comm _ d]
215+
216+
@[to_additive (attr := simp)]
217+
theorem unoneD_eq_self_iff {d : α} {x : WithOne α} : unoneD d x = d ↔ x = d ∨ x = 1 := by
218+
simp [unoneD_eq_iff]
219+
220+
@[to_additive]
221+
theorem unoneD_eq_unoneD_iff {d : α} {x y : WithOne α} :
222+
unoneD d x = unoneD d y ↔ x = y ∨ x = d ∧ y = 1 ∨ x = 1 ∧ y = d := by
223+
induction y <;> simp [unoneD_eq_iff, or_comm]
224+
225+
@[to_additive]
226+
lemma unoneD_eq_unone {d : α} {x : WithOne α} (hx : x ≠ 1) : unoneD d x = unone hx := by
227+
simp [unoneD_eq_iff]
228+
197229
end WithOne

Mathlib/Algebra/Module/Submodule/Ker.lean

Lines changed: 15 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -197,23 +197,21 @@ theorem ker_eq_bot {f : M →ₛₗ[τ₁₂] M₂} : ker f = ⊥ ↔ Injective
197197
alias _root_.LinearMapClass.ker_eq_bot := ker_eq_bot
198198

199199
@[simp] lemma injective_domRestrict_iff {f : M →ₛₗ[τ₁₂] M₂} {S : Submodule R M} :
200-
Injective (f.domRestrict S) ↔ S ⊓ LinearMap.ker f = ⊥ := by
201-
rw [← LinearMap.ker_eq_bot]
202-
refine ⟨fun h ↦ le_bot_iff.1 ?_, fun h ↦ le_bot_iff.1 ?_⟩
203-
· intro x ⟨hx, h'x⟩
204-
have : ⟨x, hx⟩ ∈ LinearMap.ker (LinearMap.domRestrict f S) := by simpa using h'x
205-
rw [h] at this
206-
simpa [mk_eq_zero] using this
207-
· rintro ⟨x, hx⟩ h'x
208-
have : x ∈ S ⊓ LinearMap.ker f := ⟨hx, h'x⟩
209-
rw [h] at this
210-
simpa [mk_eq_zero] using this
211-
212-
@[simp] theorem injective_restrict_iff_disjoint {p : Submodule R M} {f : M →ₗ[R] M}
213-
(hf : ∀ x ∈ p, f x ∈ p) :
214-
Injective (f.restrict hf) ↔ Disjoint p (ker f) := by
215-
rw [← ker_eq_bot, ker_restrict hf, ← ker_domRestrict, ker_eq_bot, injective_domRestrict_iff,
216-
disjoint_iff]
200+
Injective (f.domRestrict S) ↔ Disjoint S f.ker := by
201+
simp [← ker_eq_bot, ker_domRestrict, disjoint_iff_comap_eq_bot]
202+
203+
@[simp]
204+
theorem injective_restrict_iff {p : Submodule R M} {q : Submodule R₂ M₂} {f : M →ₛₗ[τ₁₂] M₂}
205+
(hf : ∀ x ∈ p, f x ∈ q) : Injective (f.restrict hf) ↔ Disjoint p (ker f) := by
206+
simp [← ker_eq_bot, ker_restrict, disjoint_iff_comap_eq_bot]
207+
208+
@[deprecated (since := "2026-07-01")]
209+
alias injective_restrict_iff_disjoint := injective_restrict_iff
210+
211+
@[simp]
212+
theorem injective_codRestrict_iff {q : Submodule R₂ M₂} {f : M →ₛₗ[τ₁₂] M₂}
213+
(hf : ∀ x, f x ∈ q) : Injective (f.codRestrict q hf) ↔ Injective f :=
214+
Set.injective_codRestrict _
217215

218216
end Ring
219217

0 commit comments

Comments
 (0)