Skip to content

Commit 6184acb

Browse files
Merge master into nightly-testing
2 parents 11c83ea + 413249c commit 6184acb

File tree

6 files changed

+78
-5
lines changed

6 files changed

+78
-5
lines changed

Mathlib.lean

+1
Original file line numberDiff line numberDiff line change
@@ -1846,6 +1846,7 @@ import Mathlib.CategoryTheory.Galois.Prorepresentability
18461846
import Mathlib.CategoryTheory.Galois.Topology
18471847
import Mathlib.CategoryTheory.Generator.Abelian
18481848
import Mathlib.CategoryTheory.Generator.Basic
1849+
import Mathlib.CategoryTheory.Generator.Indization
18491850
import Mathlib.CategoryTheory.Generator.Preadditive
18501851
import Mathlib.CategoryTheory.Generator.Presheaf
18511852
import Mathlib.CategoryTheory.Generator.Sheaf

Mathlib/Analysis/Calculus/Deriv/Basic.lean

+3
Original file line numberDiff line numberDiff line change
@@ -658,6 +658,9 @@ theorem deriv_const' : (deriv fun _ : 𝕜 => c) = fun _ => 0 :=
658658
theorem derivWithin_const : derivWithin (fun _ => c) s = 0 := by
659659
ext; simp [derivWithin]
660660

661+
@[simp]
662+
theorem derivWithin_zero : derivWithin (0 : 𝕜 → F) s = 0 := derivWithin_const _ _
663+
661664
end Const
662665

663666
section Continuous

Mathlib/Analysis/Calculus/Deriv/Mul.lean

+16
Original file line numberDiff line numberDiff line change
@@ -246,6 +246,17 @@ theorem derivWithin_mul_const (hc : DifferentiableWithinAt 𝕜 c s x) (d : 𝔸
246246
· exact (hc.hasDerivWithinAt.mul_const d).derivWithin hxs
247247
· simp [derivWithin_zero_of_isolated hxs]
248248

249+
lemma derivWithin_mul_const_field (u : 𝕜') :
250+
derivWithin (fun y => v y * u) s x = derivWithin v s x * u := by
251+
by_cases hv : DifferentiableWithinAt 𝕜 v s x
252+
· rw [derivWithin_mul_const hv u]
253+
by_cases hu : u = 0
254+
· simp [hu]
255+
rw [derivWithin_zero_of_not_differentiableWithinAt hv, zero_mul,
256+
derivWithin_zero_of_not_differentiableWithinAt]
257+
have : v = fun x ↦ (v x * u) * u⁻¹ := by ext; simp [hu]
258+
exact fun h_diff ↦ hv <| this ▸ h_diff.mul_const _
259+
249260
theorem deriv_mul_const (hc : DifferentiableAt 𝕜 c x) (d : 𝔸) :
250261
deriv (fun y => c y * d) x = deriv c x * d :=
251262
(hc.hasDerivAt.mul_const d).deriv
@@ -284,6 +295,11 @@ theorem derivWithin_const_mul (c : 𝔸) (hd : DifferentiableWithinAt 𝕜 d s x
284295
· exact (hd.hasDerivWithinAt.const_mul c).derivWithin hxs
285296
· simp [derivWithin_zero_of_isolated hxs]
286297

298+
lemma derivWithin_const_mul_field (u : 𝕜') :
299+
derivWithin (fun y => u * v y) s x = u * derivWithin v s x := by
300+
simp_rw [mul_comm u]
301+
exact derivWithin_mul_const_field u
302+
287303
theorem deriv_const_mul (c : 𝔸) (hd : DifferentiableAt 𝕜 d x) :
288304
deriv (fun y => c * d y) x = c * deriv d x :=
289305
(hd.hasDerivAt.const_mul c).deriv
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
/-
2+
Copyright (c) 2025 Markus Himmel. All rights reserved.
3+
Released under Apache 2.0 license as described in the file LICENSE.
4+
Authors: Markus Himmel
5+
-/
6+
import Mathlib.CategoryTheory.Generator.Basic
7+
import Mathlib.CategoryTheory.Limits.Indization.Category
8+
9+
/-!
10+
# Separating set in the category of ind-objects
11+
12+
We construct a separating set in the category of ind-objects.
13+
14+
## Future work
15+
16+
Once we have constructed zero morphisms in the category of ind-objects, we will be able to show
17+
that under sufficient conditions, the category of ind-objects has a separating object.
18+
19+
-/
20+
21+
universe v u
22+
23+
namespace CategoryTheory
24+
25+
open Limits
26+
27+
section
28+
29+
variable {C : Type u} [Category.{v} C]
30+
31+
theorem Ind.isSeparating_range_yoneda : IsSeparating (Set.range (Ind.yoneda : C ⥤ _).obj) := by
32+
refine fun X Y f g h => (cancel_epi (Ind.colimitPresentationCompYoneda X).hom).1 ?_
33+
exact colimit.hom_ext (fun i => by simp [← Category.assoc, h])
34+
35+
end
36+
37+
end CategoryTheory

Mathlib/Data/Fintype/Basic.lean

+1-5
Original file line numberDiff line numberDiff line change
@@ -1060,11 +1060,7 @@ variable [Fintype α] [DecidableEq β] {f : α → β}
10601060
/-- `bijInv f` is the unique inverse to a bijection `f`. This acts
10611061
as a computable alternative to `Function.invFun`. -/
10621062
def bijInv (f_bij : Bijective f) (b : β) : α :=
1063-
Fintype.choose (fun a => f a = b)
1064-
(by
1065-
rcases f_bij.right b with ⟨a', fa_eq_b⟩
1066-
rw [← fa_eq_b]
1067-
exact ⟨a', ⟨rfl, fun a h => f_bij.left h⟩⟩)
1063+
Fintype.choose (fun a => f a = b) (f_bij.existsUnique b)
10681064

10691065
theorem leftInverse_bijInv (f_bij : Bijective f) : LeftInverse (bijInv f_bij) f := fun a =>
10701066
f_bij.left (choose_spec (fun a' => f a' = f a) _)

Mathlib/RingTheory/Artinian/Ring.lean

+20
Original file line numberDiff line numberDiff line change
@@ -91,6 +91,26 @@ theorem isField_of_isReduced_of_isLocalRing [IsReduced R] [IsLocalRing R] : IsFi
9191
(IsArtinianRing.equivPi R).trans (RingEquiv.piUnique _) |>.toMulEquiv.isField
9292
_ (Ideal.Quotient.field _).toIsField
9393

94+
section IsUnit
95+
96+
open nonZeroDivisors
97+
98+
/-- If an element of an artinian ring is not a zero divisor then it is a unit. -/
99+
theorem isUnit_of_mem_nonZeroDivisors {a : R} (ha : a ∈ R⁰) : IsUnit a :=
100+
IsUnit.isUnit_iff_mulLeft_bijective.mpr <|
101+
IsArtinian.bijective_of_injective_endomorphism (LinearMap.mulLeft R a)
102+
fun _ _ ↦ (mul_cancel_left_mem_nonZeroDivisors ha).mp
103+
104+
/-- In an artinian ring, an element is a unit iff it is a non-zero-divisor.
105+
See also `isUnit_iff_mem_nonZeroDivisors_of_finite`.-/
106+
theorem isUnit_iff_mem_nonZeroDivisors {a : R} : IsUnit a ↔ a ∈ R⁰ :=
107+
⟨IsUnit.mem_nonZeroDivisors, isUnit_of_mem_nonZeroDivisors⟩
108+
109+
theorem isUnit_submonoid_eq : IsUnit.submonoid R = R⁰ := by
110+
ext; simp [IsUnit.mem_submonoid_iff, isUnit_iff_mem_nonZeroDivisors]
111+
112+
end IsUnit
113+
94114
section Localization
95115

96116
variable (S : Submonoid R) (L : Type*) [CommSemiring L] [Algebra R L] [IsLocalization S L]

0 commit comments

Comments
 (0)