Context
stringlengths
57
6.04k
file_name
stringlengths
21
79
start
int64
14
1.49k
end
int64
18
1.5k
theorem
stringlengths
25
1.55k
proof
stringlengths
5
7.36k
rank
int64
0
2.4k
import Mathlib.Data.Finsupp.Encodable import Mathlib.LinearAlgebra.Pi import Mathlib.LinearAlgebra.Span import Mathlib.Data.Set.Countable #align_import linear_algebra.finsupp from "leanprover-community/mathlib"@"9d684a893c52e1d6692a504a118bfccbae04feeb" noncomputable section open Set LinearMap Submodule namespa...
Mathlib/LinearAlgebra/Finsupp.lean
266
284
theorem disjoint_lsingle_lsingle (s t : Set Ξ±) (hs : Disjoint s t) : Disjoint (⨆ a ∈ s, LinearMap.range (lsingle a : M β†’β‚—[R] Ξ± β†’β‚€ M)) (⨆ a ∈ t, LinearMap.range (lsingle a : M β†’β‚—[R] Ξ± β†’β‚€ M)) := by
-- Porting note: 2 placeholders are added to prevent timeout. refine (Disjoint.mono (lsingle_range_le_ker_lapply s sᢜ ?_) (lsingle_range_le_ker_lapply t tᢜ ?_)) ?_ · apply disjoint_compl_right · apply disjoint_compl_right rw [disjoint_iff_inf_le] refine le_trans (le_iInf fun i => ?_) ...
1,319
import Mathlib.Data.Finsupp.Encodable import Mathlib.LinearAlgebra.Pi import Mathlib.LinearAlgebra.Span import Mathlib.Data.Set.Countable #align_import linear_algebra.finsupp from "leanprover-community/mathlib"@"9d684a893c52e1d6692a504a118bfccbae04feeb" noncomputable section open Set LinearMap Submodule namespa...
Mathlib/LinearAlgebra/Finsupp.lean
287
289
theorem span_single_image (s : Set M) (a : Ξ±) : Submodule.span R (single a '' s) = (Submodule.span R s).map (lsingle a : M β†’β‚—[R] Ξ± β†’β‚€ M) := by
rw [← span_image]; rfl
1,319
import Mathlib.Tactic.FinCases import Mathlib.Data.Nat.Choose.Sum import Mathlib.LinearAlgebra.Finsupp import Mathlib.Algebra.Field.IsField #align_import ring_theory.ideal.basic from "leanprover-community/mathlib"@"dc6c365e751e34d100e80fe6e314c3c3e0fd2988" universe u v w variable {Ξ± : Type u} {Ξ² : Type v} open ...
Mathlib/RingTheory/Ideal/Basic.lean
84
89
theorem eq_top_of_unit_mem (x y : α) (hx : x ∈ I) (h : y * x = 1) : I = ⊀ := eq_top_iff.2 fun z _ => calc z = z * (y * x) := by
simp [h] _ = z * y * x := Eq.symm <| mul_assoc z y x _ ∈ I := I.mul_mem_left _ hx
1,320
import Mathlib.Tactic.FinCases import Mathlib.Data.Nat.Choose.Sum import Mathlib.LinearAlgebra.Finsupp import Mathlib.Algebra.Field.IsField #align_import ring_theory.ideal.basic from "leanprover-community/mathlib"@"dc6c365e751e34d100e80fe6e314c3c3e0fd2988" universe u v w variable {Ξ± : Type u} {Ξ² : Type v} open ...
Mathlib/RingTheory/Ideal/Basic.lean
106
110
theorem unit_mul_mem_iff_mem {x y : Ξ±} (hy : IsUnit y) : y * x ∈ I ↔ x ∈ I := by
refine ⟨fun h => ?_, fun h => I.mul_mem_left y h⟩ obtain ⟨y', hy'⟩ := hy.exists_left_inv have := I.mul_mem_left y' h rwa [← mul_assoc, hy', one_mul] at this
1,320
import Mathlib.Tactic.FinCases import Mathlib.Data.Nat.Choose.Sum import Mathlib.LinearAlgebra.Finsupp import Mathlib.Algebra.Field.IsField #align_import ring_theory.ideal.basic from "leanprover-community/mathlib"@"dc6c365e751e34d100e80fe6e314c3c3e0fd2988" universe u v w variable {Ξ± : Type u} {Ξ² : Type v} open ...
Mathlib/RingTheory/Ideal/Basic.lean
167
168
theorem isCompactElement_top : CompleteLattice.IsCompactElement (⊀ : Ideal α) := by
simpa only [← span_singleton_one] using Submodule.singleton_span_isCompactElement 1
1,320
import Mathlib.Algebra.Algebra.Tower import Mathlib.Algebra.GroupWithZero.NonZeroDivisors import Mathlib.GroupTheory.MonoidLocalization import Mathlib.RingTheory.Ideal.Basic import Mathlib.GroupTheory.GroupAction.Ring #align_import ring_theory.localization.basic from "leanprover-community/mathlib"@"b69c9a770ecf37eb21...
Mathlib/RingTheory/Localization/Basic.lean
135
144
theorem of_le (N : Submonoid R) (h₁ : M ≀ N) (hβ‚‚ : βˆ€ r ∈ N, IsUnit (algebraMap R S r)) : IsLocalization N S where map_units' r := hβ‚‚ r r.2 surj' s := have ⟨⟨x, y, hy⟩, H⟩ := IsLocalization.surj M s ⟨⟨x, y, h₁ hy⟩, H⟩ exists_of_eq {x y} := by
rw [IsLocalization.eq_iff_exists M] rintro ⟨c, hc⟩ exact ⟨⟨c, h₁ c.2⟩, hc⟩
1,321
import Mathlib.Algebra.Algebra.Tower import Mathlib.Algebra.GroupWithZero.NonZeroDivisors import Mathlib.GroupTheory.MonoidLocalization import Mathlib.RingTheory.Ideal.Basic import Mathlib.GroupTheory.GroupAction.Ring #align_import ring_theory.localization.basic from "leanprover-community/mathlib"@"b69c9a770ecf37eb21...
Mathlib/RingTheory/Localization/Basic.lean
202
204
theorem sec_spec' (z : S) : algebraMap R S (IsLocalization.sec M z).1 = algebraMap R S (IsLocalization.sec M z).2 * z := by
rw [mul_comm, sec_spec]
1,321
import Mathlib.Algebra.Algebra.Tower import Mathlib.Algebra.GroupWithZero.NonZeroDivisors import Mathlib.GroupTheory.MonoidLocalization import Mathlib.RingTheory.Ideal.Basic import Mathlib.GroupTheory.GroupAction.Ring #align_import ring_theory.localization.basic from "leanprover-community/mathlib"@"b69c9a770ecf37eb21...
Mathlib/RingTheory/Localization/Basic.lean
222
225
theorem eq_zero_of_fst_eq_zero {z x} {y : M} (h : z * algebraMap R S y = algebraMap R S x) (hx : x = 0) : z = 0 := by
rw [hx, (algebraMap R S).map_zero] at h exact (IsUnit.mul_left_eq_zero (IsLocalization.map_units S y)).1 h
1,321
import Mathlib.Algebra.Algebra.Tower import Mathlib.Algebra.GroupWithZero.NonZeroDivisors import Mathlib.GroupTheory.MonoidLocalization import Mathlib.RingTheory.Ideal.Basic import Mathlib.GroupTheory.GroupAction.Ring #align_import ring_theory.localization.basic from "leanprover-community/mathlib"@"b69c9a770ecf37eb21...
Mathlib/RingTheory/Localization/Basic.lean
230
237
theorem map_eq_zero_iff (r : R) : algebraMap R S r = 0 ↔ βˆƒ m : M, ↑m * r = 0 := by
constructor Β· intro h obtain ⟨m, hm⟩ := (IsLocalization.eq_iff_exists M S).mp ((algebraMap R S).map_zero.trans h.symm) exact ⟨m, by simpa using hm.symm⟩ Β· rintro ⟨m, hm⟩ rw [← (IsLocalization.map_units S m).mul_right_inj, mul_zero, ← RingHom.map_mul, hm, RingHom.map_zero]
1,321
import Mathlib.RingTheory.UniqueFactorizationDomain import Mathlib.RingTheory.Localization.Basic #align_import ring_theory.localization.away.basic from "leanprover-community/mathlib"@"a7c017d750512a352b623b1824d75da5998457d0" section CommSemiring variable {R : Type*} [CommSemiring R] (M : Submonoid R) {S : Type*...
Mathlib/RingTheory/Localization/Away/Basic.lean
58
61
theorem mul_invSelf : algebraMap R S x * invSelf x = 1 := by
convert IsLocalization.mk'_mul_mk'_eq_one (M := Submonoid.powers x) (S := S) _ 1 symm apply IsLocalization.mk'_one
1,322
import Mathlib.RingTheory.Localization.Basic #align_import ring_theory.localization.integer from "leanprover-community/mathlib"@"9556784a5b84697562e9c6acb40500d4a82e675a" variable {R : Type*} [CommSemiring R] {M : Submonoid R} {S : Type*} [CommSemiring S] variable [Algebra R S] {P : Type*} [CommSemiring P] open ...
Mathlib/RingTheory/Localization/Integer.lean
63
66
theorem isInteger_smul {a : R} {b : S} (hb : IsInteger R b) : IsInteger R (a β€’ b) := by
rcases hb with ⟨b', hb⟩ use a * b' rw [← hb, (algebraMap R S).map_mul, Algebra.smul_def]
1,323
import Mathlib.RingTheory.Localization.Basic #align_import ring_theory.localization.integer from "leanprover-community/mathlib"@"9556784a5b84697562e9c6acb40500d4a82e675a" variable {R : Type*} [CommSemiring R] {M : Submonoid R} {S : Type*} [CommSemiring S] variable [Algebra R S] {P : Type*} [CommSemiring P] open ...
Mathlib/RingTheory/Localization/Integer.lean
85
87
theorem exists_integer_multiple (a : S) : βˆƒ b : M, IsInteger R ((b : R) β€’ a) := by
simp_rw [Algebra.smul_def, mul_comm _ a] apply exists_integer_multiple'
1,323
import Mathlib.RingTheory.Localization.Basic #align_import ring_theory.localization.integer from "leanprover-community/mathlib"@"9556784a5b84697562e9c6acb40500d4a82e675a" variable {R : Type*} [CommSemiring R] {M : Submonoid R} {S : Type*} [CommSemiring S] variable [Algebra R S] {P : Type*} [CommSemiring P] open ...
Mathlib/RingTheory/Localization/Integer.lean
91
103
theorem exist_integer_multiples {ΞΉ : Type*} (s : Finset ΞΉ) (f : ΞΉ β†’ S) : βˆƒ b : M, βˆ€ i ∈ s, IsLocalization.IsInteger R ((b : R) β€’ f i) := by
haveI := Classical.propDecidable refine ⟨∏ i ∈ s, (sec M (f i)).2, fun i hi => ⟨?_, ?_⟩⟩ Β· exact (∏ j ∈ s.erase i, (sec M (f j)).2) * (sec M (f i)).1 rw [RingHom.map_mul, sec_spec', ← mul_assoc, ← (algebraMap R S).map_mul, ← Algebra.smul_def] congr 2 refine _root_.trans ?_ (map_prod (Submonoid.subtype M) _...
1,323
import Mathlib.RingTheory.Localization.Basic #align_import ring_theory.localization.integer from "leanprover-community/mathlib"@"9556784a5b84697562e9c6acb40500d4a82e675a" variable {R : Type*} [CommSemiring R] {M : Submonoid R} {S : Type*} [CommSemiring S] variable [Algebra R S] {P : Type*} [CommSemiring P] open ...
Mathlib/RingTheory/Localization/Integer.lean
107
111
theorem exist_integer_multiples_of_finite {ΞΉ : Type*} [Finite ΞΉ] (f : ΞΉ β†’ S) : βˆƒ b : M, βˆ€ i, IsLocalization.IsInteger R ((b : R) β€’ f i) := by
cases nonempty_fintype ι obtain ⟨b, hb⟩ := exist_integer_multiples M Finset.univ f exact ⟨b, fun i => hb i (Finset.mem_univ _)⟩
1,323
import Mathlib.RingTheory.Localization.Basic #align_import ring_theory.localization.integer from "leanprover-community/mathlib"@"9556784a5b84697562e9c6acb40500d4a82e675a" variable {R : Type*} [CommSemiring R] {M : Submonoid R} {S : Type*} [CommSemiring S] variable [Algebra R S] {P : Type*} [CommSemiring P] open ...
Mathlib/RingTheory/Localization/Integer.lean
149
159
theorem finsetIntegerMultiple_image [DecidableEq R] (s : Finset S) : algebraMap R S '' finsetIntegerMultiple M s = commonDenomOfFinset M s β€’ (s : Set S) := by
delta finsetIntegerMultiple commonDenom rw [Finset.coe_image] ext constructor · rintro ⟨_, ⟨x, -, rfl⟩, rfl⟩ rw [map_integerMultiple] exact Set.mem_image_of_mem _ x.prop · rintro ⟨x, hx, rfl⟩ exact ⟨_, ⟨⟨x, hx⟩, s.mem_attach _, rfl⟩, map_integerMultiple M s id _⟩
1,323
import Mathlib.RingTheory.Localization.FractionRing import Mathlib.RingTheory.Localization.Integer import Mathlib.RingTheory.UniqueFactorizationDomain #align_import ring_theory.localization.num_denom from "leanprover-community/mathlib"@"831c494092374cfe9f50591ed0ac81a25efc5b86" variable {R : Type*} [CommRing R] (...
Mathlib/RingTheory/Localization/NumDen.lean
37
47
theorem exists_reduced_fraction (x : K) : βˆƒ (a : A) (b : nonZeroDivisors A), IsRelPrime a b ∧ mk' K a b = x := by
obtain ⟨⟨b, b_nonzero⟩, a, hab⟩ := exists_integer_multiple (nonZeroDivisors A) x obtain ⟨a', b', c', no_factor, rfl, rfl⟩ := UniqueFactorizationMonoid.exists_reduced_factors' a b (mem_nonZeroDivisors_iff_ne_zero.mp b_nonzero) obtain ⟨_, b'_nonzero⟩ := mul_mem_nonZeroDivisors.mp b_nonzero refine ⟨a', ...
1,324
import Mathlib.RingTheory.Localization.FractionRing import Mathlib.RingTheory.Localization.Integer import Mathlib.RingTheory.UniqueFactorizationDomain #align_import ring_theory.localization.num_denom from "leanprover-community/mathlib"@"831c494092374cfe9f50591ed0ac81a25efc5b86" variable {R : Type*} [CommRing R] (...
Mathlib/RingTheory/Localization/NumDen.lean
70
72
theorem mk'_num_den' (x : K) : algebraMap A K (num A x) / algebraMap A K (den A x) = x := by
rw [← mk'_eq_div] apply mk'_num_den
1,324
import Mathlib.RingTheory.Localization.FractionRing import Mathlib.RingTheory.Localization.Integer import Mathlib.RingTheory.UniqueFactorizationDomain #align_import ring_theory.localization.num_denom from "leanprover-community/mathlib"@"831c494092374cfe9f50591ed0ac81a25efc5b86" variable {R : Type*} [CommRing R] (...
Mathlib/RingTheory/Localization/NumDen.lean
97
105
theorem isInteger_of_isUnit_den {x : K} (h : IsUnit (den A x : A)) : IsInteger A x := by
cases' h with d hd have d_ne_zero : algebraMap A K (den A x) β‰  0 := IsFractionRing.to_map_ne_zero_of_mem_nonZeroDivisors (den A x).2 use ↑d⁻¹ * num A x refine _root_.trans ?_ (mk'_num_den A x) rw [map_mul, map_units_inv, hd] apply mul_left_cancelβ‚€ d_ne_zero rw [← mul_assoc, mul_inv_cancel d_ne_zero, ...
1,324
import Mathlib.RingTheory.Localization.AtPrime import Mathlib.RingTheory.Localization.Basic import Mathlib.RingTheory.Localization.FractionRing #align_import ring_theory.localization.localization_localization from "leanprover-community/mathlib"@"831c494092374cfe9f50591ed0ac81a25efc5b86" open Function namespace ...
Mathlib/RingTheory/Localization/LocalizationLocalization.lean
53
61
theorem mem_localizationLocalizationSubmodule {x : R} : x ∈ localizationLocalizationSubmodule M N ↔ βˆƒ (y : N) (z : M), algebraMap R S x = y * algebraMap R S z := by
rw [localizationLocalizationSubmodule, Submonoid.mem_comap, Submonoid.mem_sup] constructor · rintro ⟨y, hy, _, ⟨z, hz, rfl⟩, e⟩ exact ⟨⟨y, hy⟩, ⟨z, hz⟩, e.symm⟩ · rintro ⟨y, z, e⟩ exact ⟨y, y.prop, _, ⟨z, z.prop, rfl⟩, e.symm⟩
1,325
import Mathlib.RingTheory.Localization.AtPrime import Mathlib.RingTheory.Localization.Basic import Mathlib.RingTheory.Localization.FractionRing #align_import ring_theory.localization.localization_localization from "leanprover-community/mathlib"@"831c494092374cfe9f50591ed0ac81a25efc5b86" open Function namespace ...
Mathlib/RingTheory/Localization/LocalizationLocalization.lean
66
70
theorem localization_localization_map_units [IsLocalization N T] (y : localizationLocalizationSubmodule M N) : IsUnit (algebraMap R T y) := by
obtain ⟨y', z, eq⟩ := mem_localizationLocalizationSubmodule.mp y.prop rw [IsScalarTower.algebraMap_apply R S T, eq, RingHom.map_mul, IsUnit.mul_iff] exact ⟨IsLocalization.map_units T y', (IsLocalization.map_units _ z).map (algebraMap S T)⟩
1,325
import Mathlib.RingTheory.Localization.AtPrime import Mathlib.RingTheory.Localization.Basic import Mathlib.RingTheory.Localization.FractionRing #align_import ring_theory.localization.localization_localization from "leanprover-community/mathlib"@"831c494092374cfe9f50591ed0ac81a25efc5b86" open Function namespace ...
Mathlib/RingTheory/Localization/LocalizationLocalization.lean
73
89
theorem localization_localization_surj [IsLocalization N T] (x : T) : βˆƒ y : R Γ— localizationLocalizationSubmodule M N, x * algebraMap R T y.2 = algebraMap R T y.1 := by
rcases IsLocalization.surj N x with ⟨⟨y, s⟩, eqβ‚βŸ© -- x = y / s rcases IsLocalization.surj M y with ⟨⟨z, t⟩, eqβ‚‚βŸ© -- y = z / t rcases IsLocalization.surj M (s : S) with ⟨⟨z', t'⟩, eqβ‚ƒβŸ© -- s = z' / t' dsimp only at eq₁ eqβ‚‚ eq₃ refine ⟨⟨z * t', z' * t, ?_⟩, ?_⟩ -- x = y / s = (z * t') / (z' * t) Β· rw [m...
1,325
import Mathlib.RingTheory.Localization.AtPrime import Mathlib.RingTheory.Localization.Basic import Mathlib.RingTheory.Localization.FractionRing #align_import ring_theory.localization.localization_localization from "leanprover-community/mathlib"@"831c494092374cfe9f50591ed0ac81a25efc5b86" open Function namespace ...
Mathlib/RingTheory/Localization/LocalizationLocalization.lean
92
108
theorem localization_localization_exists_of_eq [IsLocalization N T] (x y : R) : algebraMap R T x = algebraMap R T y β†’ βˆƒ c : localizationLocalizationSubmodule M N, ↑c * x = ↑c * y := by
rw [IsScalarTower.algebraMap_apply R S T, IsScalarTower.algebraMap_apply R S T, IsLocalization.eq_iff_exists N T] rintro ⟨z, eqβ‚βŸ© rcases IsLocalization.surj M (z : S) with ⟨⟨z', s⟩, eqβ‚‚βŸ© dsimp only at eqβ‚‚ suffices (algebraMap R S) (x * z' : R) = (algebraMap R S) (y * z') by obtain ⟨c, eq₃ : ↑c * (x *...
1,325
import Mathlib.RingTheory.Localization.AtPrime import Mathlib.RingTheory.Localization.Basic import Mathlib.RingTheory.Localization.FractionRing #align_import ring_theory.localization.localization_localization from "leanprover-community/mathlib"@"831c494092374cfe9f50591ed0ac81a25efc5b86" open Function namespace ...
Mathlib/RingTheory/Localization/LocalizationLocalization.lean
125
133
theorem localization_localization_isLocalization_of_has_all_units [IsLocalization N T] (H : βˆ€ x : S, IsUnit x β†’ x ∈ N) : IsLocalization (N.comap (algebraMap R S)) T := by
convert localization_localization_isLocalization M N T using 1 dsimp [localizationLocalizationSubmodule] congr symm rw [sup_eq_left] rintro _ ⟨x, hx, rfl⟩ exact H _ (IsLocalization.map_units _ ⟨x, hx⟩)
1,325
import Mathlib.RingTheory.Localization.LocalizationLocalization #align_import ring_theory.localization.as_subring from "leanprover-community/mathlib"@"649ca66bf4d62796b5eefef966e622d91aa471f3" namespace Localization open nonZeroDivisors variable {A : Type*} (K : Type*) [CommRing A] (S : Submonoid A) (hS : S ≀ A...
Mathlib/RingTheory/Localization/AsSubring.lean
31
32
theorem map_isUnit_of_le (hS : S ≀ A⁰) (s : S) : IsUnit (algebraMap A K s) := by
apply IsLocalization.map_units K (⟨s.1, hS s.2⟩ : A⁰)
1,326
import Mathlib.Algebra.Algebra.Bilinear import Mathlib.RingTheory.Localization.Basic #align_import algebra.module.localized_module from "leanprover-community/mathlib"@"831c494092374cfe9f50591ed0ac81a25efc5b86" namespace LocalizedModule universe u v variable {R : Type u} [CommSemiring R] (S : Submonoid R) variab...
Mathlib/Algebra/Module/LocalizedModule.lean
99
102
theorem induction_on {Ξ² : LocalizedModule S M β†’ Prop} (h : βˆ€ (m : M) (s : S), Ξ² (mk m s)) : βˆ€ x : LocalizedModule S M, Ξ² x := by
rintro ⟨⟨m, s⟩⟩ exact h m s
1,327
import Mathlib.Algebra.Algebra.Bilinear import Mathlib.RingTheory.Localization.Basic #align_import algebra.module.localized_module from "leanprover-community/mathlib"@"831c494092374cfe9f50591ed0ac81a25efc5b86" namespace LocalizedModule universe u v variable {R : Type u} [CommSemiring R] (S : Submonoid R) variab...
Mathlib/Algebra/Module/LocalizedModule.lean
106
109
theorem induction_onβ‚‚ {Ξ² : LocalizedModule S M β†’ LocalizedModule S M β†’ Prop} (h : βˆ€ (m m' : M) (s s' : S), Ξ² (mk m s) (mk m' s')) : βˆ€ x y, Ξ² x y := by
rintro ⟨⟨m, s⟩⟩ ⟨⟨m', s'⟩⟩ exact h m m' s s'
1,327
import Mathlib.Algebra.Algebra.Bilinear import Mathlib.RingTheory.Localization.Basic #align_import algebra.module.localized_module from "leanprover-community/mathlib"@"831c494092374cfe9f50591ed0ac81a25efc5b86" namespace LocalizedModule universe u v variable {R : Type u} [CommSemiring R] (S : Submonoid R) variab...
Mathlib/Algebra/Module/LocalizedModule.lean
120
121
theorem liftOn_mk {Ξ± : Type*} {f : M Γ— S β†’ Ξ±} (wd : βˆ€ (p p' : M Γ— S), p β‰ˆ p' β†’ f p = f p') (m : M) (s : S) : liftOn (mk m s) f wd = f ⟨m, s⟩ := by
convert Quotient.liftOn_mk f wd ⟨m, s⟩
1,327
import Mathlib.Algebra.Algebra.Bilinear import Mathlib.RingTheory.Localization.Basic #align_import algebra.module.localized_module from "leanprover-community/mathlib"@"831c494092374cfe9f50591ed0ac81a25efc5b86" namespace LocalizedModule universe u v variable {R : Type u} [CommSemiring R] (S : Submonoid R) variab...
Mathlib/Algebra/Module/LocalizedModule.lean
132
135
theorem liftOnβ‚‚_mk {Ξ± : Type*} (f : M Γ— S β†’ M Γ— S β†’ Ξ±) (wd : βˆ€ (p q p' q' : M Γ— S), p β‰ˆ p' β†’ q β‰ˆ q' β†’ f p q = f p' q') (m m' : M) (s s' : S) : liftOnβ‚‚ (mk m s) (mk m' s') f wd = f ⟨m, s⟩ ⟨m', s'⟩ := by
convert Quotient.liftOnβ‚‚_mk f wd _ _
1,327
import Mathlib.Algebra.Algebra.Bilinear import Mathlib.RingTheory.Localization.Basic #align_import algebra.module.localized_module from "leanprover-community/mathlib"@"831c494092374cfe9f50591ed0ac81a25efc5b86" namespace LocalizedModule universe u v variable {R : Type u} [CommSemiring R] (S : Submonoid R) variab...
Mathlib/Algebra/Module/LocalizedModule.lean
142
145
theorem subsingleton (h : 0 ∈ S) : Subsingleton (LocalizedModule S M) := by
refine ⟨fun a b ↦ ?_⟩ induction a,b using LocalizedModule.induction_onβ‚‚ exact mk_eq.mpr ⟨⟨0, h⟩, by simp only [Submonoid.mk_smul, zero_smul]⟩
1,327
import Mathlib.Algebra.Algebra.Bilinear import Mathlib.RingTheory.Localization.Basic #align_import algebra.module.localized_module from "leanprover-community/mathlib"@"831c494092374cfe9f50591ed0ac81a25efc5b86" section IsLocalizedModule universe u v variable {R : Type*} [CommSemiring R] (S : Submonoid R) variabl...
Mathlib/Algebra/Module/LocalizedModule.lean
574
588
theorem IsLocalizedModule.of_linearEquiv (e : M' ≃ₗ[R] M'') [hf : IsLocalizedModule S f] : IsLocalizedModule S (e βˆ˜β‚— f : M β†’β‚—[R] M'') where map_units s := by
rw [show algebraMap R (Module.End R M'') s = e βˆ˜β‚— (algebraMap R (Module.End R M') s) βˆ˜β‚— e.symm by ext; simp, Module.End_isUnit_iff, LinearMap.coe_comp, LinearMap.coe_comp, LinearEquiv.coe_coe, LinearEquiv.coe_coe, EquivLike.comp_bijective, EquivLike.bijective_comp] exact (Module.End_isUnit_iff _).m...
1,327
import Mathlib.Algebra.Algebra.Bilinear import Mathlib.RingTheory.Localization.Basic #align_import algebra.module.localized_module from "leanprover-community/mathlib"@"831c494092374cfe9f50591ed0ac81a25efc5b86" section IsLocalizedModule universe u v variable {R : Type*} [CommSemiring R] (S : Submonoid R) variabl...
Mathlib/Algebra/Module/LocalizedModule.lean
599
610
theorem isLocalizedModule_iff_isLocalization {A Aβ‚›} [CommSemiring A] [Algebra R A] [CommSemiring Aβ‚›] [Algebra A Aβ‚›] [Algebra R Aβ‚›] [IsScalarTower R A Aβ‚›] : IsLocalizedModule S (IsScalarTower.toAlgHom R A Aβ‚›).toLinearMap ↔ IsLocalization (Algebra.algebraMapSubmonoid A S) Aβ‚› := by
rw [isLocalizedModule_iff, isLocalization_iff] refine and_congr ?_ (and_congr (forall_congr' fun _ ↦ ?_) (forallβ‚‚_congr fun _ _ ↦ ?_)) Β· simp_rw [← (Algebra.lmul R Aβ‚›).commutes, Algebra.lmul_isUnit_iff, Subtype.forall, Algebra.algebraMapSubmonoid, ← SetLike.mem_coe, Submonoid.coe_map, Set.forall_mem_...
1,327
import Mathlib.Algebra.Algebra.Defs import Mathlib.Algebra.Order.Group.Basic import Mathlib.Algebra.Order.Ring.Basic import Mathlib.RingTheory.Localization.Basic import Mathlib.SetTheory.Game.Birthday import Mathlib.SetTheory.Surreal.Basic #align_import set_theory.surreal.dyadic from "leanprover-community/mathlib"@"9...
Mathlib/SetTheory/Surreal/Dyadic.lean
52
52
theorem powHalf_leftMoves (n) : (powHalf n).LeftMoves = PUnit := by
cases n <;> rfl
1,328
import Mathlib.Algebra.Algebra.Defs import Mathlib.Algebra.Order.Group.Basic import Mathlib.Algebra.Order.Ring.Basic import Mathlib.RingTheory.Localization.Basic import Mathlib.SetTheory.Game.Birthday import Mathlib.SetTheory.Surreal.Basic #align_import set_theory.surreal.dyadic from "leanprover-community/mathlib"@"9...
Mathlib/SetTheory/Surreal/Dyadic.lean
64
64
theorem powHalf_moveLeft (n i) : (powHalf n).moveLeft i = 0 := by
cases n <;> cases i <;> rfl
1,328
import Mathlib.Algebra.Algebra.Defs import Mathlib.Algebra.Order.Group.Basic import Mathlib.Algebra.Order.Ring.Basic import Mathlib.RingTheory.Localization.Basic import Mathlib.SetTheory.Game.Birthday import Mathlib.SetTheory.Surreal.Basic #align_import set_theory.surreal.dyadic from "leanprover-community/mathlib"@"9...
Mathlib/SetTheory/Surreal/Dyadic.lean
85
86
theorem birthday_half : birthday (powHalf 1) = 2 := by
rw [birthday_def]; simp
1,328
import Mathlib.Algebra.Algebra.Defs import Mathlib.Algebra.Order.Group.Basic import Mathlib.Algebra.Order.Ring.Basic import Mathlib.RingTheory.Localization.Basic import Mathlib.SetTheory.Game.Birthday import Mathlib.SetTheory.Surreal.Basic #align_import set_theory.surreal.dyadic from "leanprover-community/mathlib"@"9...
Mathlib/SetTheory/Surreal/Dyadic.lean
90
95
theorem numeric_powHalf (n) : (powHalf n).Numeric := by
induction' n with n hn · exact numeric_one · constructor · simpa using hn.moveLeft_lt default · exact ⟨fun _ => numeric_zero, fun _ => hn⟩
1,328
import Mathlib.Algebra.Algebra.Defs import Mathlib.Algebra.Order.Group.Basic import Mathlib.Algebra.Order.Ring.Basic import Mathlib.RingTheory.Localization.Basic import Mathlib.SetTheory.Game.Birthday import Mathlib.SetTheory.Surreal.Basic #align_import set_theory.surreal.dyadic from "leanprover-community/mathlib"@"9...
Mathlib/SetTheory/Surreal/Dyadic.lean
106
109
theorem powHalf_le_one (n : β„•) : powHalf n ≀ 1 := by
induction' n with n hn Β· exact le_rfl Β· exact (powHalf_succ_le_powHalf n).trans hn
1,328
import Mathlib.Algebra.Algebra.Defs import Mathlib.Algebra.Order.Group.Basic import Mathlib.Algebra.Order.Ring.Basic import Mathlib.RingTheory.Localization.Basic import Mathlib.SetTheory.Game.Birthday import Mathlib.SetTheory.Surreal.Basic #align_import set_theory.surreal.dyadic from "leanprover-community/mathlib"@"9...
Mathlib/SetTheory/Surreal/Dyadic.lean
116
117
theorem powHalf_pos (n : β„•) : 0 < powHalf n := by
rw [← lf_iff_lt numeric_zero (numeric_powHalf n), zero_lf_le]; simp
1,328
import Mathlib.Algebra.Algebra.Defs import Mathlib.Algebra.Order.Group.Basic import Mathlib.Algebra.Order.Ring.Basic import Mathlib.RingTheory.Localization.Basic import Mathlib.SetTheory.Game.Birthday import Mathlib.SetTheory.Surreal.Basic #align_import set_theory.surreal.dyadic from "leanprover-community/mathlib"@"9...
Mathlib/SetTheory/Surreal/Dyadic.lean
124
156
theorem add_powHalf_succ_self_eq_powHalf (n) : powHalf (n + 1) + powHalf (n + 1) β‰ˆ powHalf n := by
induction' n using Nat.strong_induction_on with n hn constructor <;> rw [le_iff_forall_lf] <;> constructor Β· rintro (⟨⟨⟩⟩ | ⟨⟨⟩⟩) <;> apply lf_of_lt Β· calc 0 + powHalf n.succ β‰ˆ powHalf n.succ := zero_add_equiv _ _ < powHalf n := powHalf_succ_lt_powHalf n Β· calc powHalf n.succ + 0 ...
1,328
import Mathlib.Algebra.BigOperators.Fin import Mathlib.LinearAlgebra.Finsupp import Mathlib.LinearAlgebra.Prod import Mathlib.SetTheory.Cardinal.Basic import Mathlib.Tactic.FinCases import Mathlib.Tactic.LinearCombination import Mathlib.Lean.Expr.ExtraRecognizers import Mathlib.Data.Set.Subsingleton #align_import lin...
Mathlib/LinearAlgebra/LinearIndependent.lean
126
128
theorem linearIndependent_iff : LinearIndependent R v ↔ βˆ€ l, Finsupp.total ΞΉ M R v l = 0 β†’ l = 0 := by
simp [LinearIndependent, LinearMap.ker_eq_bot']
1,329
import Mathlib.Algebra.BigOperators.Fin import Mathlib.LinearAlgebra.Finsupp import Mathlib.LinearAlgebra.Prod import Mathlib.SetTheory.Cardinal.Basic import Mathlib.Tactic.FinCases import Mathlib.Tactic.LinearCombination import Mathlib.Lean.Expr.ExtraRecognizers import Mathlib.Data.Set.Subsingleton #align_import lin...
Mathlib/LinearAlgebra/LinearIndependent.lean
131
151
theorem linearIndependent_iff' : LinearIndependent R v ↔ βˆ€ s : Finset ΞΉ, βˆ€ g : ΞΉ β†’ R, βˆ‘ i ∈ s, g i β€’ v i = 0 β†’ βˆ€ i ∈ s, g i = 0 := linearIndependent_iff.trans ⟨fun hf s g hg i his => have h := hf (βˆ‘ i ∈ s, Finsupp.single i (g i)) <| by simpa only [map_sum, Finsupp.total_single] u...
{ rw [Finsupp.lapply_apply, Finsupp.single_eq_same] } _ = βˆ‘ j ∈ s, (Finsupp.lapply i : (ΞΉ β†’β‚€ R) β†’β‚—[R] R) (Finsupp.single j (g j)) := Eq.symm <| Finset.sum_eq_single i (fun j _hjs hji => by rw [Finsupp.lapply_apply, Finsupp.single_eq_of_ne hji]) fun hn...
1,329
import Mathlib.Algebra.BigOperators.Fin import Mathlib.LinearAlgebra.Finsupp import Mathlib.LinearAlgebra.Prod import Mathlib.SetTheory.Cardinal.Basic import Mathlib.Tactic.FinCases import Mathlib.Tactic.LinearCombination import Mathlib.Lean.Expr.ExtraRecognizers import Mathlib.Data.Set.Subsingleton #align_import lin...
Mathlib/LinearAlgebra/LinearIndependent.lean
154
164
theorem linearIndependent_iff'' : LinearIndependent R v ↔ βˆ€ (s : Finset ΞΉ) (g : ΞΉ β†’ R), (βˆ€ i βˆ‰ s, g i = 0) β†’ βˆ‘ i ∈ s, g i β€’ v i = 0 β†’ βˆ€ i, g i = 0 := by
classical exact linearIndependent_iff'.trans ⟨fun H s g hg hv i => if his : i ∈ s then H s g hv i his else hg i his, fun H s g hg i hi => by convert H s (fun j => if j ∈ s then g j else 0) (fun j hj => if_neg hj) (by simp_rw [ite_smul, zero_smul, Finset.sum_extend_by_zero, hg]) i ...
1,329
import Mathlib.Algebra.BigOperators.Fin import Mathlib.LinearAlgebra.Finsupp import Mathlib.LinearAlgebra.Prod import Mathlib.SetTheory.Cardinal.Basic import Mathlib.Tactic.FinCases import Mathlib.Tactic.LinearCombination import Mathlib.Lean.Expr.ExtraRecognizers import Mathlib.Data.Set.Subsingleton #align_import lin...
Mathlib/LinearAlgebra/LinearIndependent.lean
167
171
theorem not_linearIndependent_iff : Β¬LinearIndependent R v ↔ βˆƒ s : Finset ΞΉ, βˆƒ g : ΞΉ β†’ R, βˆ‘ i ∈ s, g i β€’ v i = 0 ∧ βˆƒ i ∈ s, g i β‰  0 := by
rw [linearIndependent_iff'] simp only [exists_prop, not_forall]
1,329
import Mathlib.Algebra.BigOperators.Fin import Mathlib.LinearAlgebra.Finsupp import Mathlib.LinearAlgebra.Prod import Mathlib.SetTheory.Cardinal.Basic import Mathlib.Tactic.FinCases import Mathlib.Tactic.LinearCombination import Mathlib.Lean.Expr.ExtraRecognizers import Mathlib.Data.Set.Subsingleton #align_import lin...
Mathlib/LinearAlgebra/LinearIndependent.lean
174
181
theorem Fintype.linearIndependent_iff [Fintype ΞΉ] : LinearIndependent R v ↔ βˆ€ g : ΞΉ β†’ R, βˆ‘ i, g i β€’ v i = 0 β†’ βˆ€ i, g i = 0 := by
refine ⟨fun H g => by simpa using linearIndependent_iff'.1 H Finset.univ g, fun H => linearIndependent_iff''.2 fun s g hg hs i => H _ ?_ _⟩ rw [← hs] refine (Finset.sum_subset (Finset.subset_univ _) fun i _ hi => ?_).symm rw [hg i hi, zero_smul]
1,329
import Mathlib.Algebra.BigOperators.Fin import Mathlib.LinearAlgebra.Finsupp import Mathlib.LinearAlgebra.Prod import Mathlib.SetTheory.Cardinal.Basic import Mathlib.Tactic.FinCases import Mathlib.Tactic.LinearCombination import Mathlib.Lean.Expr.ExtraRecognizers import Mathlib.Data.Set.Subsingleton #align_import lin...
Mathlib/LinearAlgebra/LinearIndependent.lean
186
189
theorem Fintype.linearIndependent_iff' [Fintype ΞΉ] [DecidableEq ΞΉ] : LinearIndependent R v ↔ LinearMap.ker (LinearMap.lsum R (fun _ ↦ R) β„• fun i ↦ LinearMap.id.smulRight (v i)) = βŠ₯ := by
simp [Fintype.linearIndependent_iff, LinearMap.ker_eq_bot', funext_iff]
1,329
import Mathlib.Algebra.BigOperators.Fin import Mathlib.LinearAlgebra.Finsupp import Mathlib.LinearAlgebra.Prod import Mathlib.SetTheory.Cardinal.Basic import Mathlib.Tactic.FinCases import Mathlib.Tactic.LinearCombination import Mathlib.Lean.Expr.ExtraRecognizers import Mathlib.Data.Set.Subsingleton #align_import lin...
Mathlib/LinearAlgebra/LinearIndependent.lean
192
194
theorem Fintype.not_linearIndependent_iff [Fintype ΞΉ] : Β¬LinearIndependent R v ↔ βˆƒ g : ΞΉ β†’ R, βˆ‘ i, g i β€’ v i = 0 ∧ βˆƒ i, g i β‰  0 := by
simpa using not_iff_not.2 Fintype.linearIndependent_iff
1,329
import Mathlib.LinearAlgebra.LinearIndependent #align_import linear_algebra.dimension from "leanprover-community/mathlib"@"47a5f8186becdbc826190ced4312f8199f9db6a5" noncomputable section universe w w' u u' v v' variable {R : Type u} {R' : Type u'} {M M₁ : Type v} {M' : Type v'} open Cardinal Submodule Function...
Mathlib/LinearAlgebra/Dimension/Basic.lean
79
84
theorem cardinal_lift_le_rank {ΞΉ : Type w} {v : ΞΉ β†’ M} (hv : LinearIndependent R v) : Cardinal.lift.{v} #ΞΉ ≀ Cardinal.lift.{w} (Module.rank R M) := by
rw [Module.rank] refine le_trans ?_ (lift_le.mpr <| le_ciSup (bddAbove_range.{v, v} _) ⟨_, hv.coe_range⟩) exact lift_mk_le'.mpr ⟨(Equiv.ofInjective _ hv.injective).toEmbedding⟩
1,330
import Mathlib.LinearAlgebra.LinearIndependent #align_import linear_algebra.dimension from "leanprover-community/mathlib"@"47a5f8186becdbc826190ced4312f8199f9db6a5" noncomputable section universe w w' u u' v v' variable {R : Type u} {R' : Type u'} {M M₁ : Type v} {M' : Type v'} open Cardinal Submodule Function...
Mathlib/LinearAlgebra/Dimension/Basic.lean
92
94
theorem cardinal_le_rank {ΞΉ : Type v} {v : ΞΉ β†’ M} (hv : LinearIndependent R v) : #ΞΉ ≀ Module.rank R M := by
simpa using hv.cardinal_lift_le_rank
1,330
import Mathlib.LinearAlgebra.Dimension.Basic import Mathlib.SetTheory.Cardinal.ToNat #align_import linear_algebra.finrank from "leanprover-community/mathlib"@"347636a7a80595d55bedf6e6fbd996a3c39da69a" universe u v w open Cardinal Submodule Module Function variable {R : Type u} {M : Type v} {N : Type w} variable...
Mathlib/LinearAlgebra/Dimension/Finrank.lean
58
61
theorem finrank_eq_of_rank_eq {n : β„•} (h : Module.rank R M = ↑n) : finrank R M = n := by
apply_fun toNat at h rw [toNat_natCast] at h exact mod_cast h
1,331
import Mathlib.LinearAlgebra.Dimension.Basic import Mathlib.SetTheory.Cardinal.ToNat #align_import linear_algebra.finrank from "leanprover-community/mathlib"@"347636a7a80595d55bedf6e6fbd996a3c39da69a" universe u v w open Cardinal Submodule Module Function variable {R : Type u} {M : Type v} {N : Type w} variable...
Mathlib/LinearAlgebra/Dimension/Finrank.lean
72
75
theorem finrank_le_of_rank_le {n : β„•} (h : Module.rank R M ≀ ↑n) : finrank R M ≀ n := by
rwa [← Cardinal.toNat_le_iff_le_of_lt_aleph0, toNat_natCast] at h Β· exact h.trans_lt (nat_lt_aleph0 n) Β· exact nat_lt_aleph0 n
1,331
import Mathlib.LinearAlgebra.Dimension.Basic import Mathlib.SetTheory.Cardinal.ToNat #align_import linear_algebra.finrank from "leanprover-community/mathlib"@"347636a7a80595d55bedf6e6fbd996a3c39da69a" universe u v w open Cardinal Submodule Module Function variable {R : Type u} {M : Type v} {N : Type w} variable...
Mathlib/LinearAlgebra/Dimension/Finrank.lean
78
81
theorem finrank_lt_of_rank_lt {n : β„•} (h : Module.rank R M < ↑n) : finrank R M < n := by
rwa [← Cardinal.toNat_lt_iff_lt_of_lt_aleph0, toNat_natCast] at h Β· exact h.trans (nat_lt_aleph0 n) Β· exact nat_lt_aleph0 n
1,331
import Mathlib.LinearAlgebra.Dimension.Basic import Mathlib.SetTheory.Cardinal.ToNat #align_import linear_algebra.finrank from "leanprover-community/mathlib"@"347636a7a80595d55bedf6e6fbd996a3c39da69a" universe u v w open Cardinal Submodule Module Function variable {R : Type u} {M : Type v} {N : Type w} variable...
Mathlib/LinearAlgebra/Dimension/Finrank.lean
84
89
theorem lt_rank_of_lt_finrank {n : β„•} (h : n < finrank R M) : ↑n < Module.rank R M := by
rwa [← Cardinal.toNat_lt_iff_lt_of_lt_aleph0, toNat_natCast] Β· exact nat_lt_aleph0 n Β· contrapose! h rw [finrank, Cardinal.toNat_apply_of_aleph0_le h] exact n.zero_le
1,331
import Mathlib.LinearAlgebra.Dimension.Basic import Mathlib.SetTheory.Cardinal.ToNat #align_import linear_algebra.finrank from "leanprover-community/mathlib"@"347636a7a80595d55bedf6e6fbd996a3c39da69a" universe u v w open Cardinal Submodule Module Function variable {R : Type u} {M : Type v} {N : Type w} variable...
Mathlib/LinearAlgebra/Dimension/Finrank.lean
92
93
theorem one_lt_rank_of_one_lt_finrank (h : 1 < finrank R M) : 1 < Module.rank R M := by
simpa using lt_rank_of_lt_finrank h
1,331
import Mathlib.LinearAlgebra.Dimension.Basic import Mathlib.SetTheory.Cardinal.ToNat #align_import linear_algebra.finrank from "leanprover-community/mathlib"@"347636a7a80595d55bedf6e6fbd996a3c39da69a" universe u v w open Cardinal Submodule Module Function variable {R : Type u} {M : Type v} {N : Type w} variable...
Mathlib/LinearAlgebra/Dimension/Finrank.lean
95
98
theorem finrank_le_finrank_of_rank_le_rank (h : lift.{w} (Module.rank R M) ≀ Cardinal.lift.{v} (Module.rank R N)) (h' : Module.rank R N < β„΅β‚€) : finrank R M ≀ finrank R N := by
simpa only [toNat_lift] using toNat_le_toNat h (lift_lt_aleph0.mpr h')
1,331
import Mathlib.Algebra.Group.Subgroup.Actions import Mathlib.Algebra.Order.Module.Algebra import Mathlib.LinearAlgebra.LinearIndependent import Mathlib.Algebra.Ring.Subring.Units #align_import linear_algebra.ray from "leanprover-community/mathlib"@"0f6670b8af2dff699de1c0b4b49039b31bc13c46" noncomputable section ...
Mathlib/LinearAlgebra/Ray.lean
61
63
theorem of_subsingleton [Subsingleton M] (x y : M) : SameRay R x y := by
rw [Subsingleton.elim x 0] exact zero_left _
1,332
import Mathlib.Algebra.Group.Subgroup.Actions import Mathlib.Algebra.Order.Module.Algebra import Mathlib.LinearAlgebra.LinearIndependent import Mathlib.Algebra.Ring.Subring.Units #align_import linear_algebra.ray from "leanprover-community/mathlib"@"0f6670b8af2dff699de1c0b4b49039b31bc13c46" noncomputable section ...
Mathlib/LinearAlgebra/Ray.lean
74
76
theorem refl (x : M) : SameRay R x x := by
nontriviality R exact Or.inr (Or.inr <| ⟨1, 1, zero_lt_one, zero_lt_one, rfl⟩)
1,332
import Mathlib.Algebra.Group.Subgroup.Actions import Mathlib.Algebra.Order.Module.Algebra import Mathlib.LinearAlgebra.LinearIndependent import Mathlib.Algebra.Ring.Subring.Units #align_import linear_algebra.ray from "leanprover-community/mathlib"@"0f6670b8af2dff699de1c0b4b49039b31bc13c46" noncomputable section ...
Mathlib/LinearAlgebra/Ray.lean
102
111
theorem trans (hxy : SameRay R x y) (hyz : SameRay R y z) (hy : y = 0 β†’ x = 0 ∨ z = 0) : SameRay R x z := by
rcases eq_or_ne x 0 with (rfl | hx); Β· exact zero_left z rcases eq_or_ne z 0 with (rfl | hz); Β· exact zero_right x rcases eq_or_ne y 0 with (rfl | hy); Β· exact (hy rfl).elim (fun h => (hx h).elim) fun h => (hz h).elim rcases hxy.exists_pos hx hy with ⟨r₁, rβ‚‚, hr₁, hrβ‚‚, hβ‚βŸ© rcases hyz.exists_pos hy hz with ...
1,332
import Mathlib.Algebra.Order.Invertible import Mathlib.Algebra.Order.Module.OrderedSMul import Mathlib.LinearAlgebra.AffineSpace.Midpoint import Mathlib.LinearAlgebra.Ray import Mathlib.Tactic.GCongr #align_import analysis.convex.segment from "leanprover-community/mathlib"@"c5773405394e073885e2a144c9ca14637e8eb963" ...
Mathlib/Analysis/Convex/Segment.lean
62
65
theorem segment_eq_imageβ‚‚ (x y : E) : [x -[π•œ] y] = (fun p : π•œ Γ— π•œ => p.1 β€’ x + p.2 β€’ y) '' { p | 0 ≀ p.1 ∧ 0 ≀ p.2 ∧ p.1 + p.2 = 1 } := by
simp only [segment, image, Prod.exists, mem_setOf_eq, exists_prop, and_assoc]
1,333
import Mathlib.Algebra.Order.Invertible import Mathlib.Algebra.Order.Module.OrderedSMul import Mathlib.LinearAlgebra.AffineSpace.Midpoint import Mathlib.LinearAlgebra.Ray import Mathlib.Tactic.GCongr #align_import analysis.convex.segment from "leanprover-community/mathlib"@"c5773405394e073885e2a144c9ca14637e8eb963" ...
Mathlib/Analysis/Convex/Segment.lean
68
71
theorem openSegment_eq_imageβ‚‚ (x y : E) : openSegment π•œ x y = (fun p : π•œ Γ— π•œ => p.1 β€’ x + p.2 β€’ y) '' { p | 0 < p.1 ∧ 0 < p.2 ∧ p.1 + p.2 = 1 } := by
simp only [openSegment, image, Prod.exists, mem_setOf_eq, exists_prop, and_assoc]
1,333
import Mathlib.Algebra.Order.Group.Instances import Mathlib.Analysis.Convex.Segment import Mathlib.Tactic.GCongr #align_import analysis.convex.star from "leanprover-community/mathlib"@"9003f28797c0664a49e4179487267c494477d853" open Set open Convex Pointwise variable {π•œ E F : Type*} section OrderedSemiring va...
Mathlib/Analysis/Convex/Star.lean
75
80
theorem starConvex_iff_segment_subset : StarConvex π•œ x s ↔ βˆ€ ⦃y⦄, y ∈ s β†’ [x -[π•œ] y] βŠ† s := by
constructor · rintro h y hy z ⟨a, b, ha, hb, hab, rfl⟩ exact h hy ha hb hab · rintro h y hy a b ha hb hab exact h hy ⟨a, b, ha, hb, hab, rfl⟩
1,334
import Mathlib.Algebra.Order.Group.Instances import Mathlib.Analysis.Convex.Segment import Mathlib.Tactic.GCongr #align_import analysis.convex.star from "leanprover-community/mathlib"@"9003f28797c0664a49e4179487267c494477d853" open Set open Convex Pointwise variable {π•œ E F : Type*} section OrderedSemiring va...
Mathlib/Analysis/Convex/Star.lean
93
99
theorem starConvex_iff_pointwise_add_subset : StarConvex π•œ x s ↔ βˆ€ ⦃a b : π•œβ¦„, 0 ≀ a β†’ 0 ≀ b β†’ a + b = 1 β†’ a β€’ {x} + b β€’ s βŠ† s := by
refine ⟨?_, fun h y hy a b ha hb hab => h ha hb hab (add_mem_add (smul_mem_smul_set <| mem_singleton _) ⟨_, hy, rfl⟩)⟩ rintro hA a b ha hb hab w ⟨au, ⟨u, rfl : u = x, rfl⟩, bv, ⟨v, hv, rfl⟩, rfl⟩ exact hA hv ha hb hab
1,334
import Mathlib.Algebra.Order.Group.Instances import Mathlib.Analysis.Convex.Segment import Mathlib.Tactic.GCongr #align_import analysis.convex.star from "leanprover-community/mathlib"@"9003f28797c0664a49e4179487267c494477d853" open Set open Convex Pointwise variable {π•œ E F : Type*} section OrderedSemiring va...
Mathlib/Analysis/Convex/Star.lean
121
125
theorem StarConvex.union (hs : StarConvex π•œ x s) (ht : StarConvex π•œ x t) : StarConvex π•œ x (s βˆͺ t) := by
rintro y (hy | hy) a b ha hb hab Β· exact Or.inl (hs hy ha hb hab) Β· exact Or.inr (ht hy ha hb hab)
1,334
import Mathlib.Algebra.Order.Group.Instances import Mathlib.Analysis.Convex.Segment import Mathlib.Tactic.GCongr #align_import analysis.convex.star from "leanprover-community/mathlib"@"9003f28797c0664a49e4179487267c494477d853" open Set open Convex Pointwise variable {π•œ E F : Type*} section OrderedSemiring va...
Mathlib/Analysis/Convex/Star.lean
128
133
theorem starConvex_iUnion {ΞΉ : Sort*} {s : ΞΉ β†’ Set E} (hs : βˆ€ i, StarConvex π•œ x (s i)) : StarConvex π•œ x (⋃ i, s i) := by
rintro y hy a b ha hb hab rw [mem_iUnion] at hy ⊒ obtain ⟨i, hy⟩ := hy exact ⟨i, hs i hy ha hb hab⟩
1,334
import Mathlib.Algebra.Order.Group.Instances import Mathlib.Analysis.Convex.Segment import Mathlib.Tactic.GCongr #align_import analysis.convex.star from "leanprover-community/mathlib"@"9003f28797c0664a49e4179487267c494477d853" open Set open Convex Pointwise variable {π•œ E F : Type*} section OrderedSemiring va...
Mathlib/Analysis/Convex/Star.lean
136
139
theorem starConvex_sUnion {S : Set (Set E)} (hS : βˆ€ s ∈ S, StarConvex π•œ x s) : StarConvex π•œ x (⋃₀ S) := by
rw [sUnion_eq_iUnion] exact starConvex_iUnion fun s => hS _ s.2
1,334
import Mathlib.Algebra.Order.Module.OrderedSMul import Mathlib.Analysis.Convex.Star import Mathlib.LinearAlgebra.AffineSpace.AffineSubspace #align_import analysis.convex.basic from "leanprover-community/mathlib"@"92bd7b1ffeb306a89f450bee126ddd8a284c259d" variable {π•œ E F Ξ² : Type*} open LinearMap Set open scope...
Mathlib/Analysis/Convex/Basic.lean
121
128
theorem Directed.convex_iUnion {ΞΉ : Sort*} {s : ΞΉ β†’ Set E} (hdir : Directed (Β· βŠ† Β·) s) (hc : βˆ€ ⦃i : ι⦄, Convex π•œ (s i)) : Convex π•œ (⋃ i, s i) := by
rintro x hx y hy a b ha hb hab rw [mem_iUnion] at hx hy ⊒ obtain ⟨i, hx⟩ := hx obtain ⟨j, hy⟩ := hy obtain ⟨k, hik, hjk⟩ := hdir i j exact ⟨k, hc (hik hx) (hjk hy) ha hb hab⟩
1,335
import Mathlib.Algebra.Order.Module.OrderedSMul import Mathlib.Analysis.Convex.Star import Mathlib.LinearAlgebra.AffineSpace.AffineSubspace #align_import analysis.convex.basic from "leanprover-community/mathlib"@"92bd7b1ffeb306a89f450bee126ddd8a284c259d" variable {π•œ E F Ξ² : Type*} open LinearMap Set open scope...
Mathlib/Analysis/Convex/Basic.lean
131
134
theorem DirectedOn.convex_sUnion {c : Set (Set E)} (hdir : DirectedOn (Β· βŠ† Β·) c) (hc : βˆ€ ⦃A : Set E⦄, A ∈ c β†’ Convex π•œ A) : Convex π•œ (⋃₀ c) := by
rw [sUnion_eq_iUnion] exact (directedOn_iff_directed.1 hdir).convex_iUnion fun A => hc A.2
1,335
import Mathlib.Analysis.Convex.Basic import Mathlib.Analysis.NormedSpace.Basic import Mathlib.Topology.MetricSpace.HausdorffDistance #align_import analysis.convex.body from "leanprover-community/mathlib"@"858a10cf68fd6c06872950fc58c4dcc68d465591" open scoped Pointwise Topology NNReal variable {V : Type*} struc...
Mathlib/Analysis/Convex/Body.lean
93
97
theorem zero_mem_of_symmetric (K : ConvexBody V) (h_symm : βˆ€ x ∈ K, - x ∈ K) : 0 ∈ K := by
obtain ⟨x, hx⟩ := K.nonempty rw [show 0 = (1/2 : ℝ) β€’ x + (1/2 : ℝ) β€’ (- x) by field_simp] apply convex_iff_forall_pos.mp K.convex hx (h_symm x hx) all_goals linarith
1,336
import Mathlib.Analysis.Convex.Basic import Mathlib.Order.Closure #align_import analysis.convex.hull from "leanprover-community/mathlib"@"92bd7b1ffeb306a89f450bee126ddd8a284c259d" open Set open Pointwise variable {π•œ E F : Type*} section convexHull section OrderedSemiring variable [OrderedSemiring π•œ] secti...
Mathlib/Analysis/Convex/Hull.lean
56
57
theorem convexHull_eq_iInter : convexHull π•œ s = β‹‚ (t : Set E) (_ : s βŠ† t) (_ : Convex π•œ t), t := by
simp [convexHull, iInter_subtype, iInter_and]
1,337
import Mathlib.Analysis.Convex.Basic import Mathlib.Order.Closure #align_import analysis.convex.hull from "leanprover-community/mathlib"@"92bd7b1ffeb306a89f450bee126ddd8a284c259d" open Set open Pointwise variable {π•œ E F : Type*} section convexHull section OrderedSemiring variable [OrderedSemiring π•œ] secti...
Mathlib/Analysis/Convex/Hull.lean
62
63
theorem mem_convexHull_iff : x ∈ convexHull π•œ s ↔ βˆ€ t, s βŠ† t β†’ Convex π•œ t β†’ x ∈ t := by
simp_rw [convexHull_eq_iInter, mem_iInter]
1,337
import Mathlib.Analysis.Convex.Basic import Mathlib.Order.Closure #align_import analysis.convex.hull from "leanprover-community/mathlib"@"92bd7b1ffeb306a89f450bee126ddd8a284c259d" open Set open Pointwise variable {π•œ E F : Type*} section convexHull section OrderedSemiring variable [OrderedSemiring π•œ] secti...
Mathlib/Analysis/Convex/Hull.lean
94
100
theorem convexHull_empty_iff : convexHull π•œ s = βˆ… ↔ s = βˆ… := by
constructor Β· intro h rw [← Set.subset_empty_iff, ← h] exact subset_convexHull π•œ _ Β· rintro rfl exact convexHull_empty
1,337
import Mathlib.Analysis.Convex.Basic import Mathlib.Order.Closure #align_import analysis.convex.hull from "leanprover-community/mathlib"@"92bd7b1ffeb306a89f450bee126ddd8a284c259d" open Set open Pointwise variable {π•œ E F : Type*} section convexHull section OrderedSemiring variable [OrderedSemiring π•œ] secti...
Mathlib/Analysis/Convex/Hull.lean
104
106
theorem convexHull_nonempty_iff : (convexHull π•œ s).Nonempty ↔ s.Nonempty := by
rw [nonempty_iff_ne_empty, nonempty_iff_ne_empty, Ne, Ne] exact not_congr convexHull_empty_iff
1,337
import Mathlib.Analysis.Convex.Basic import Mathlib.Order.Closure #align_import analysis.convex.hull from "leanprover-community/mathlib"@"92bd7b1ffeb306a89f450bee126ddd8a284c259d" open Set open Pointwise variable {π•œ E F : Type*} section convexHull section OrderedSemiring variable [OrderedSemiring π•œ] secti...
Mathlib/Analysis/Convex/Hull.lean
127
131
theorem convexHull_pair (x y : E) : convexHull π•œ {x, y} = segment π•œ x y := by
refine (convexHull_min ?_ <| convex_segment _ _).antisymm (segment_subset_convexHull (mem_insert _ _) <| subset_insert _ _ <| mem_singleton _) rw [insert_subset_iff, singleton_subset_iff] exact ⟨left_mem_segment _ _ _, right_mem_segment _ _ _⟩
1,337
import Mathlib.Analysis.Convex.Basic import Mathlib.Order.Closure #align_import analysis.convex.hull from "leanprover-community/mathlib"@"92bd7b1ffeb306a89f450bee126ddd8a284c259d" open Set open Pointwise variable {π•œ E F : Type*} section convexHull section OrderedSemiring variable [OrderedSemiring π•œ] secti...
Mathlib/Analysis/Convex/Hull.lean
144
158
theorem Convex.convex_remove_iff_not_mem_convexHull_remove {s : Set E} (hs : Convex π•œ s) (x : E) : Convex π•œ (s \ {x}) ↔ x βˆ‰ convexHull π•œ (s \ {x}) := by
constructor Β· rintro hsx hx rw [hsx.convexHull_eq] at hx exact hx.2 (mem_singleton _) rintro hx suffices h : s \ {x} = convexHull π•œ (s \ {x}) by rw [h] exact convex_convexHull π•œ _ exact Subset.antisymm (subset_convexHull π•œ _) fun y hy => ⟨convexHull_min diff_subset hs hy, by ...
1,337
import Mathlib.Analysis.Convex.Basic import Mathlib.Analysis.Convex.Hull import Mathlib.Analysis.NormedSpace.Basic import Mathlib.Topology.Bornology.Absorbs #align_import analysis.locally_convex.basic from "leanprover-community/mathlib"@"f2ce6086713c78a7f880485f7917ea547a215982" open Set open Pointwise Topology ...
Mathlib/Analysis/LocallyConvex/Basic.lean
81
82
theorem balanced_iff_closedBall_smul : Balanced π•œ s ↔ Metric.closedBall (0 : π•œ) 1 β€’ s βŠ† s := by
simp [balanced_iff_smul_mem, smul_subset_iff]
1,338
import Mathlib.Analysis.LocallyConvex.Basic #align_import analysis.locally_convex.balanced_core_hull from "leanprover-community/mathlib"@"f2ce6086713c78a7f880485f7917ea547a215982" open Set Pointwise Topology Filter variable {π•œ E ΞΉ : Type*} section balancedHull section SeminormedRing variable [SeminormedRing ...
Mathlib/Analysis/LocallyConvex/BalancedCoreHull.lean
81
82
theorem mem_balancedCore_iff : x ∈ balancedCore π•œ s ↔ βˆƒ t, Balanced π•œ t ∧ t βŠ† s ∧ x ∈ t := by
simp_rw [balancedCore, mem_sUnion, mem_setOf_eq, and_assoc]
1,339
import Mathlib.Analysis.LocallyConvex.Basic #align_import analysis.locally_convex.balanced_core_hull from "leanprover-community/mathlib"@"f2ce6086713c78a7f880485f7917ea547a215982" open Set Pointwise Topology Filter variable {π•œ E ΞΉ : Type*} section balancedHull section SeminormedRing variable [SeminormedRing ...
Mathlib/Analysis/LocallyConvex/BalancedCoreHull.lean
85
90
theorem smul_balancedCore_subset (s : Set E) {a : π•œ} (ha : β€–aβ€– ≀ 1) : a β€’ balancedCore π•œ s βŠ† balancedCore π•œ s := by
rintro x ⟨y, hy, rfl⟩ rw [mem_balancedCore_iff] at hy rcases hy with ⟨t, ht1, ht2, hy⟩ exact ⟨t, ⟨ht1, ht2⟩, ht1 a ha (smul_mem_smul_set hy)⟩
1,339
import Mathlib.Analysis.LocallyConvex.Basic #align_import analysis.locally_convex.balanced_core_hull from "leanprover-community/mathlib"@"f2ce6086713c78a7f880485f7917ea547a215982" open Set Pointwise Topology Filter variable {π•œ E ΞΉ : Type*} section balancedHull section SeminormedRing variable [SeminormedRing ...
Mathlib/Analysis/LocallyConvex/BalancedCoreHull.lean
108
109
theorem mem_balancedHull_iff : x ∈ balancedHull π•œ s ↔ βˆƒ r : π•œ, β€–rβ€– ≀ 1 ∧ x ∈ r β€’ s := by
simp [balancedHull]
1,339
import Mathlib.Analysis.LocallyConvex.Basic #align_import analysis.locally_convex.balanced_core_hull from "leanprover-community/mathlib"@"f2ce6086713c78a7f880485f7917ea547a215982" open Set Pointwise Topology Filter variable {π•œ E ΞΉ : Type*} section balancedHull section SeminormedRing variable [SeminormedRing ...
Mathlib/Analysis/LocallyConvex/BalancedCoreHull.lean
114
118
theorem Balanced.balancedHull_subset_of_subset (ht : Balanced π•œ t) (h : s βŠ† t) : balancedHull π•œ s βŠ† t := by
intros x hx obtain ⟨r, hr, y, hy, rfl⟩ := mem_balancedHull_iff.1 hx exact ht.smul_mem hr (h hy)
1,339
import Mathlib.Analysis.Convex.Hull #align_import analysis.convex.extreme from "leanprover-community/mathlib"@"c5773405394e073885e2a144c9ca14637e8eb963" open Function Set open scoped Classical open Affine variable {π•œ E F ΞΉ : Type*} {Ο€ : ΞΉ β†’ Type*} section SMul variable (π•œ) [OrderedSemiring π•œ] [AddCommMonoi...
Mathlib/Analysis/Convex/Extreme.lean
97
103
theorem IsExtreme.inter (hAB : IsExtreme π•œ A B) (hAC : IsExtreme π•œ A C) : IsExtreme π•œ A (B ∩ C) := by
use Subset.trans inter_subset_left hAB.1 rintro x₁ hx₁A xβ‚‚ hxβ‚‚A x ⟨hxB, hxC⟩ hx obtain ⟨hx₁B, hxβ‚‚B⟩ := hAB.2 hx₁A hxβ‚‚A hxB hx obtain ⟨hx₁C, hxβ‚‚C⟩ := hAC.2 hx₁A hxβ‚‚A hxC hx exact ⟨⟨hx₁B, hx₁C⟩, hxβ‚‚B, hxβ‚‚C⟩
1,340
import Mathlib.Analysis.Convex.Hull #align_import analysis.convex.extreme from "leanprover-community/mathlib"@"c5773405394e073885e2a144c9ca14637e8eb963" open Function Set open scoped Classical open Affine variable {π•œ E F ΞΉ : Type*} {Ο€ : ΞΉ β†’ Type*} section SMul variable (π•œ) [OrderedSemiring π•œ] [AddCommMonoi...
Mathlib/Analysis/Convex/Extreme.lean
111
117
theorem isExtreme_iInter {ΞΉ : Sort*} [Nonempty ΞΉ] {F : ΞΉ β†’ Set E} (hAF : βˆ€ i : ΞΉ, IsExtreme π•œ A (F i)) : IsExtreme π•œ A (β‹‚ i : ΞΉ, F i) := by
obtain i := Classical.arbitrary ΞΉ refine ⟨iInter_subset_of_subset i (hAF i).1, fun x₁ hx₁A xβ‚‚ hxβ‚‚A x hxF hx ↦ ?_⟩ simp_rw [mem_iInter] at hxF ⊒ have h := fun i ↦ (hAF i).2 hx₁A hxβ‚‚A (hxF i) hx exact ⟨fun i ↦ (h i).1, fun i ↦ (h i).2⟩
1,340
import Mathlib.Analysis.Convex.Hull #align_import analysis.convex.extreme from "leanprover-community/mathlib"@"c5773405394e073885e2a144c9ca14637e8eb963" open Function Set open scoped Classical open Affine variable {π•œ E F ΞΉ : Type*} {Ο€ : ΞΉ β†’ Type*} section SMul variable (π•œ) [OrderedSemiring π•œ] [AddCommMonoi...
Mathlib/Analysis/Convex/Extreme.lean
120
123
theorem isExtreme_biInter {F : Set (Set E)} (hF : F.Nonempty) (hA : βˆ€ B ∈ F, IsExtreme π•œ A B) : IsExtreme π•œ A (β‹‚ B ∈ F, B) := by
haveI := hF.to_subtype simpa only [iInter_subtype] using isExtreme_iInter fun i : F ↦ hA _ i.2
1,340
import Mathlib.Analysis.Convex.Hull #align_import analysis.convex.extreme from "leanprover-community/mathlib"@"c5773405394e073885e2a144c9ca14637e8eb963" open Function Set open scoped Classical open Affine variable {π•œ E F ΞΉ : Type*} {Ο€ : ΞΉ β†’ Type*} section SMul variable (π•œ) [OrderedSemiring π•œ] [AddCommMonoi...
Mathlib/Analysis/Convex/Extreme.lean
126
127
theorem isExtreme_sInter {F : Set (Set E)} (hF : F.Nonempty) (hAF : βˆ€ B ∈ F, IsExtreme π•œ A B) : IsExtreme π•œ A (β‹‚β‚€ F) := by
simpa [sInter_eq_biInter] using isExtreme_biInter hF hAF
1,340
import Mathlib.Analysis.Convex.Hull #align_import analysis.convex.join from "leanprover-community/mathlib"@"951bf1d9e98a2042979ced62c0620bcfb3587cf8" open Set variable {ΞΉ : Sort*} {π•œ E : Type*} section OrderedSemiring variable (π•œ) [OrderedSemiring π•œ] [AddCommMonoid E] [Module π•œ E] {s t s₁ sβ‚‚ t₁ tβ‚‚ u : Set ...
Mathlib/Analysis/Convex/Join.lean
36
37
theorem mem_convexJoin : x ∈ convexJoin π•œ s t ↔ βˆƒ a ∈ s, βˆƒ b ∈ t, x ∈ segment π•œ a b := by
simp [convexJoin]
1,341
import Mathlib.Analysis.Convex.Hull #align_import analysis.convex.join from "leanprover-community/mathlib"@"951bf1d9e98a2042979ced62c0620bcfb3587cf8" open Set variable {ΞΉ : Sort*} {π•œ E : Type*} section OrderedSemiring variable (π•œ) [OrderedSemiring π•œ] [AddCommMonoid E] [Module π•œ E] {s t s₁ sβ‚‚ t₁ tβ‚‚ u : Set ...
Mathlib/Analysis/Convex/Join.lean
57
57
theorem convexJoin_empty_left (t : Set E) : convexJoin π•œ βˆ… t = βˆ… := by
simp [convexJoin]
1,341
import Mathlib.Analysis.Convex.Hull #align_import analysis.convex.join from "leanprover-community/mathlib"@"951bf1d9e98a2042979ced62c0620bcfb3587cf8" open Set variable {ΞΉ : Sort*} {π•œ E : Type*} section OrderedSemiring variable (π•œ) [OrderedSemiring π•œ] [AddCommMonoid E] [Module π•œ E] {s t s₁ sβ‚‚ t₁ tβ‚‚ u : Set ...
Mathlib/Analysis/Convex/Join.lean
61
61
theorem convexJoin_empty_right (s : Set E) : convexJoin π•œ s βˆ… = βˆ… := by
simp [convexJoin]
1,341
import Mathlib.Analysis.Convex.Hull #align_import analysis.convex.join from "leanprover-community/mathlib"@"951bf1d9e98a2042979ced62c0620bcfb3587cf8" open Set variable {ΞΉ : Sort*} {π•œ E : Type*} section OrderedSemiring variable (π•œ) [OrderedSemiring π•œ] [AddCommMonoid E] [Module π•œ E] {s t s₁ sβ‚‚ t₁ tβ‚‚ u : Set ...
Mathlib/Analysis/Convex/Join.lean
65
66
theorem convexJoin_singleton_left (t : Set E) (x : E) : convexJoin π•œ {x} t = ⋃ y ∈ t, segment π•œ x y := by
simp [convexJoin]
1,341
import Mathlib.Analysis.Convex.Hull #align_import analysis.convex.join from "leanprover-community/mathlib"@"951bf1d9e98a2042979ced62c0620bcfb3587cf8" open Set variable {ΞΉ : Sort*} {π•œ E : Type*} section OrderedSemiring variable (π•œ) [OrderedSemiring π•œ] [AddCommMonoid E] [Module π•œ E] {s t s₁ sβ‚‚ t₁ tβ‚‚ u : Set ...
Mathlib/Analysis/Convex/Join.lean
70
71
theorem convexJoin_singleton_right (s : Set E) (y : E) : convexJoin π•œ s {y} = ⋃ x ∈ s, segment π•œ x y := by
simp [convexJoin]
1,341
import Mathlib.Analysis.Convex.Hull #align_import analysis.convex.join from "leanprover-community/mathlib"@"951bf1d9e98a2042979ced62c0620bcfb3587cf8" open Set variable {ΞΉ : Sort*} {π•œ E : Type*} section OrderedSemiring variable (π•œ) [OrderedSemiring π•œ] [AddCommMonoid E] [Module π•œ E] {s t s₁ sβ‚‚ t₁ tβ‚‚ u : Set ...
Mathlib/Analysis/Convex/Join.lean
75
75
theorem convexJoin_singletons (x : E) : convexJoin π•œ {x} {y} = segment π•œ x y := by
simp
1,341
import Mathlib.Analysis.Convex.Hull #align_import analysis.convex.join from "leanprover-community/mathlib"@"951bf1d9e98a2042979ced62c0620bcfb3587cf8" open Set variable {ΞΉ : Sort*} {π•œ E : Type*} section OrderedSemiring variable (π•œ) [OrderedSemiring π•œ] [AddCommMonoid E] [Module π•œ E] {s t s₁ sβ‚‚ t₁ tβ‚‚ u : Set ...
Mathlib/Analysis/Convex/Join.lean
79
81
theorem convexJoin_union_left (s₁ sβ‚‚ t : Set E) : convexJoin π•œ (s₁ βˆͺ sβ‚‚) t = convexJoin π•œ s₁ t βˆͺ convexJoin π•œ sβ‚‚ t := by
simp_rw [convexJoin, mem_union, iUnion_or, iUnion_union_distrib]
1,341
import Mathlib.Analysis.Convex.Hull #align_import analysis.convex.join from "leanprover-community/mathlib"@"951bf1d9e98a2042979ced62c0620bcfb3587cf8" open Set variable {ΞΉ : Sort*} {π•œ E : Type*} section OrderedSemiring variable (π•œ) [OrderedSemiring π•œ] [AddCommMonoid E] [Module π•œ E] {s t s₁ sβ‚‚ t₁ tβ‚‚ u : Set ...
Mathlib/Analysis/Convex/Join.lean
85
87
theorem convexJoin_union_right (s t₁ tβ‚‚ : Set E) : convexJoin π•œ s (t₁ βˆͺ tβ‚‚) = convexJoin π•œ s t₁ βˆͺ convexJoin π•œ s tβ‚‚ := by
simp_rw [convexJoin_comm s, convexJoin_union_left]
1,341
import Mathlib.Analysis.Convex.Hull #align_import analysis.convex.join from "leanprover-community/mathlib"@"951bf1d9e98a2042979ced62c0620bcfb3587cf8" open Set variable {ΞΉ : Sort*} {π•œ E : Type*} section OrderedSemiring variable (π•œ) [OrderedSemiring π•œ] [AddCommMonoid E] [Module π•œ E] {s t s₁ sβ‚‚ t₁ tβ‚‚ u : Set ...
Mathlib/Analysis/Convex/Join.lean
91
94
theorem convexJoin_iUnion_left (s : ΞΉ β†’ Set E) (t : Set E) : convexJoin π•œ (⋃ i, s i) t = ⋃ i, convexJoin π•œ (s i) t := by
simp_rw [convexJoin, mem_iUnion, iUnion_exists] exact iUnion_comm _
1,341
import Mathlib.Analysis.Convex.Hull #align_import analysis.convex.join from "leanprover-community/mathlib"@"951bf1d9e98a2042979ced62c0620bcfb3587cf8" open Set variable {ΞΉ : Sort*} {π•œ E : Type*} section OrderedSemiring variable (π•œ) [OrderedSemiring π•œ] [AddCommMonoid E] [Module π•œ E] {s t s₁ sβ‚‚ t₁ tβ‚‚ u : Set ...
Mathlib/Analysis/Convex/Join.lean
98
100
theorem convexJoin_iUnion_right (s : Set E) (t : ΞΉ β†’ Set E) : convexJoin π•œ s (⋃ i, t i) = ⋃ i, convexJoin π•œ s (t i) := by
simp_rw [convexJoin_comm s, convexJoin_iUnion_left]
1,341
import Mathlib.LinearAlgebra.Ray import Mathlib.Analysis.NormedSpace.Real #align_import analysis.normed_space.ray from "leanprover-community/mathlib"@"92ca63f0fb391a9ca5f22d2409a6080e786d99f7" open Real variable {E : Type*} [SeminormedAddCommGroup E] [NormedSpace ℝ E] {F : Type*} [NormedAddCommGroup F] [NormedSp...
Mathlib/Analysis/NormedSpace/Ray.lean
32
35
theorem norm_add (h : SameRay ℝ x y) : β€–x + yβ€– = β€–xβ€– + β€–yβ€– := by
rcases h.exists_eq_smul with ⟨u, a, b, ha, hb, -, rfl, rfl⟩ rw [← add_smul, norm_smul_of_nonneg (add_nonneg ha hb), norm_smul_of_nonneg ha, norm_smul_of_nonneg hb, add_mul]
1,342
import Mathlib.LinearAlgebra.Ray import Mathlib.Analysis.NormedSpace.Real #align_import analysis.normed_space.ray from "leanprover-community/mathlib"@"92ca63f0fb391a9ca5f22d2409a6080e786d99f7" open Real variable {E : Type*} [SeminormedAddCommGroup E] [NormedSpace ℝ E] {F : Type*} [NormedAddCommGroup F] [NormedSp...
Mathlib/Analysis/NormedSpace/Ray.lean
38
46
theorem norm_sub (h : SameRay ℝ x y) : β€–x - yβ€– = |β€–xβ€– - β€–yβ€–| := by
rcases h.exists_eq_smul with ⟨u, a, b, ha, hb, -, rfl, rfl⟩ wlog hab : b ≀ a generalizing a b with H Β· rw [SameRay.sameRay_comm] at h rw [norm_sub_rev, abs_sub_comm] exact H b a hb ha h (le_of_not_le hab) rw [← sub_nonneg] at hab rw [← sub_smul, norm_smul_of_nonneg hab, norm_smul_of_nonneg ha, norm_s...
1,342
import Mathlib.LinearAlgebra.Ray import Mathlib.Analysis.NormedSpace.Real #align_import analysis.normed_space.ray from "leanprover-community/mathlib"@"92ca63f0fb391a9ca5f22d2409a6080e786d99f7" open Real variable {E : Type*} [SeminormedAddCommGroup E] [NormedSpace ℝ E] {F : Type*} [NormedAddCommGroup F] [NormedSp...
Mathlib/Analysis/NormedSpace/Ray.lean
49
52
theorem norm_smul_eq (h : SameRay ℝ x y) : β€–xβ€– β€’ y = β€–yβ€– β€’ x := by
rcases h.exists_eq_smul with ⟨u, a, b, ha, hb, -, rfl, rfl⟩ simp only [norm_smul_of_nonneg, *, mul_smul] rw [smul_comm, smul_comm b, smul_comm a b u]
1,342
import Mathlib.LinearAlgebra.Ray import Mathlib.Analysis.NormedSpace.Real #align_import analysis.normed_space.ray from "leanprover-community/mathlib"@"92ca63f0fb391a9ca5f22d2409a6080e786d99f7" open Real variable {E : Type*} [SeminormedAddCommGroup E] [NormedSpace ℝ E] {F : Type*} [NormedAddCommGroup F] [NormedSp...
Mathlib/Analysis/NormedSpace/Ray.lean
59
65
theorem norm_injOn_ray_left (hx : x β‰  0) : { y | SameRay ℝ x y }.InjOn norm := by
rintro y hy z hz h rcases hy.exists_nonneg_left hx with ⟨r, hr, rfl⟩ rcases hz.exists_nonneg_left hx with ⟨s, hs, rfl⟩ rw [norm_smul, norm_smul, mul_left_inj' (norm_ne_zero_iff.2 hx), norm_of_nonneg hr, norm_of_nonneg hs] at h rw [h]
1,342
import Mathlib.LinearAlgebra.Ray import Mathlib.Analysis.NormedSpace.Real #align_import analysis.normed_space.ray from "leanprover-community/mathlib"@"92ca63f0fb391a9ca5f22d2409a6080e786d99f7" open Real variable {E : Type*} [SeminormedAddCommGroup E] [NormedSpace ℝ E] {F : Type*} [NormedAddCommGroup F] [NormedSp...
Mathlib/Analysis/NormedSpace/Ray.lean
68
69
theorem norm_injOn_ray_right (hy : y β‰  0) : { x | SameRay ℝ x y }.InjOn norm := by
simpa only [SameRay.sameRay_comm] using norm_injOn_ray_left hy
1,342
import Mathlib.Algebra.Module.Defs import Mathlib.LinearAlgebra.Finsupp import Mathlib.LinearAlgebra.FreeModule.Basic import Mathlib.LinearAlgebra.TensorProduct.Tower #align_import algebra.module.projective from "leanprover-community/mathlib"@"405ea5cee7a7070ff8fb8dcb4cfb003532e34bce" universe u v open LinearMap ...
Mathlib/Algebra/Module/Projective.lean
92
94
theorem projective_def' : Projective R P ↔ βˆƒ s : P β†’β‚—[R] P β†’β‚€ R, Finsupp.total P P R id βˆ˜β‚— s = .id := by
simp_rw [projective_def, DFunLike.ext_iff, Function.LeftInverse, comp_apply, id_apply]
1,343
import Mathlib.Algebra.Module.Defs import Mathlib.LinearAlgebra.Finsupp import Mathlib.LinearAlgebra.FreeModule.Basic import Mathlib.LinearAlgebra.TensorProduct.Tower #align_import algebra.module.projective from "leanprover-community/mathlib"@"405ea5cee7a7070ff8fb8dcb4cfb003532e34bce" universe u v open LinearMap ...
Mathlib/Algebra/Module/Projective.lean
98
116
theorem projective_lifting_property [h : Projective R P] (f : M β†’β‚—[R] N) (g : P β†’β‚—[R] N) (hf : Function.Surjective f) : βˆƒ h : P β†’β‚—[R] M, f.comp h = g := by
/- Here's the first step of the proof. Recall that `X β†’β‚€ R` is Lean's way of talking about the free `R`-module on a type `X`. The universal property `Finsupp.total` says that to a map `X β†’ N` from a type to an `R`-module, we get an associated R-module map `(X β†’β‚€ R) β†’β‚— N`. Apply this to a (noncomp...
1,343
import Mathlib.Algebra.Module.Defs import Mathlib.LinearAlgebra.Finsupp import Mathlib.LinearAlgebra.FreeModule.Basic import Mathlib.LinearAlgebra.TensorProduct.Tower #align_import algebra.module.projective from "leanprover-community/mathlib"@"405ea5cee7a7070ff8fb8dcb4cfb003532e34bce" universe u v open LinearMap ...
Mathlib/Algebra/Module/Projective.lean
156
163
theorem Projective.of_basis {ΞΉ : Type*} (b : Basis ΞΉ R P) : Projective R P := by
-- need P β†’β‚— (P β†’β‚€ R) for definition of projective. -- get it from `ΞΉ β†’ (P β†’β‚€ R)` coming from `b`. use b.constr β„• fun i => Finsupp.single (b i) (1 : R) intro m simp only [b.constr_apply, mul_one, id, Finsupp.smul_single', Finsupp.total_single, map_finsupp_sum] exact b.total_repr m
1,343
import Mathlib.RingTheory.Ideal.Basic import Mathlib.RingTheory.Ideal.Maps import Mathlib.LinearAlgebra.Finsupp import Mathlib.RingTheory.GradedAlgebra.Basic #align_import ring_theory.graded_algebra.homogeneous_ideal from "leanprover-community/mathlib"@"4e861f25ba5ceef42ba0712d8ffeb32f38ad6441" open SetLike Direc...
Mathlib/RingTheory/GradedAlgebra/HomogeneousIdeal.lean
64
69
theorem Ideal.IsHomogeneous.mem_iff {I} (hI : Ideal.IsHomogeneous π’œ I) {x} : x ∈ I ↔ βˆ€ i, (decompose π’œ x i : A) ∈ I := by
classical refine ⟨fun hx i ↦ hI i hx, fun hx ↦ ?_⟩ rw [← DirectSum.sum_support_decompose π’œ x] exact Ideal.sum_mem _ (fun i _ ↦ hx i)
1,344