name
stringlengths
3
112
file
stringlengths
21
116
statement
stringlengths
17
8.64k
state
stringlengths
7
205k
tactic
stringlengths
3
4.55k
result
stringlengths
7
205k
id
stringlengths
16
16
LieModule.trace_toEnd_genWeightSpace
Mathlib/Algebra/Lie/Weights/Basic.lean
@[simp] lemma trace_toEnd_genWeightSpace [IsDomain R] [IsPrincipalIdealRing R] [Module.Free R M] [Module.Finite R M] (χ : L → R) (x : L) : trace R _ (toEnd R L (genWeightSpace M χ) x) = finrank R (genWeightSpace M χ) • χ x
R : Type u_2 L : Type u_3 M : Type u_4 inst✝¹¹ : CommRing R inst✝¹⁰ : LieRing L inst✝⁹ : LieAlgebra R L inst✝⁸ : AddCommGroup M inst✝⁷ : Module R M inst✝⁶ : LieRingModule L M inst✝⁵ : LieModule R L M inst✝⁴ : LieRing.IsNilpotent L inst✝³ : IsDomain R inst✝² : IsPrincipalIdealRing R inst✝¹ : Free R M inst✝ : Module.Finite R M χ : L → R x : L ⊢ (trace R ↥(genWeightSpace M χ)) ((toEnd R L ↥(genWeightSpace M χ)) x) = finrank R ↥(genWeightSpace M χ) • χ x
suffices _root_.IsNilpotent ((toEnd R L (genWeightSpace M χ) x) - χ x • LinearMap.id) by replace this := (isNilpotent_trace_of_isNilpotent this).eq_zero rwa [map_sub, map_smul, trace_id, sub_eq_zero, smul_eq_mul, mul_comm, ← nsmul_eq_mul] at this
R : Type u_2 L : Type u_3 M : Type u_4 inst✝¹¹ : CommRing R inst✝¹⁰ : LieRing L inst✝⁹ : LieAlgebra R L inst✝⁸ : AddCommGroup M inst✝⁷ : Module R M inst✝⁶ : LieRingModule L M inst✝⁵ : LieModule R L M inst✝⁴ : LieRing.IsNilpotent L inst✝³ : IsDomain R inst✝² : IsPrincipalIdealRing R inst✝¹ : Free R M inst✝ : Module.Finite R M χ : L → R x : L ⊢ _root_.IsNilpotent ((toEnd R L ↥(genWeightSpace M χ)) x - χ x • LinearMap.id)
2105e30533b87f10
Module.reflection_mul_reflection_zpow_apply
Mathlib/LinearAlgebra/Reflection.lean
/-- A formula for $(r_1 r_2)^m z$, where $m$ is an integer and $z \in M$. -/ lemma reflection_mul_reflection_zpow_apply (m : ℤ) (z : M) (t : R := f y * g x - 2) (ht : t = f y * g x - 2
R : Type u_1 M : Type u_2 inst✝² : CommRing R inst✝¹ : AddCommGroup M inst✝ : Module R M x y : M f g : Dual R M hf : f x = 2 hg : g y = 2 z : M t : optParam R (f y * g x - 2) ht : autoParam (t = f y * g x - 2) _auto✝ a✝ : ∀ (n : ℕ), ((reflection hf * reflection hg) ^ ↑n) z = z + (Polynomial.eval t (S R ((↑n - 2) / 2)) * (Polynomial.eval t (S R ((↑n - 1) / 2)) + Polynomial.eval t (S R ((↑n - 3) / 2)))) • ((g x * f z - g z) • y - f z • x) + (Polynomial.eval t (S R ((↑n - 1) / 2)) * (Polynomial.eval t (S R (↑n / 2)) + Polynomial.eval t (S R ((↑n - 2) / 2)))) • ((f y * g z - f z) • x - g z • y) m : ℕ ht' : t = g x * f y - 2 a b : ℤ hab : autoParam (a + b = -3) _auto✝ ⊢ a / 2 = -(b / 2) - 2
omega
no goals
ede6c0c006554b73
ite_eq_ite
Mathlib/.lake/packages/lean4/src/lean/Init/PropLemmas.lean
theorem ite_eq_ite (p : Prop) {h h' : Decidable p} (x y : α) : (@ite _ p h x y = @ite _ p h' x y) ↔ True
α : Sort u_1 p : Prop h h' : Decidable p x y : α ⊢ (if p then x else y) = if p then x else y
congr
no goals
ff25be8a485bb34f
Std.Tactic.BVDecide.LRAT.Internal.DefaultFormula.clear_insert_inductive_case
Mathlib/.lake/packages/lean4/src/lean/Std/Tactic/BVDecide/LRAT/Internal/Formula/RupAddResult.lean
theorem clear_insert_inductive_case {n : Nat} (f : DefaultFormula n) (f_assignments_size : f.assignments.size = n) (units : Array (Literal (PosFin n))) (units_nodup : ∀ i : Fin units.size, ∀ j : Fin units.size, i ≠ j → units[i] ≠ units[j]) (idx : Fin units.size) (assignments : Array Assignment) (ih : ClearInsertInductionMotive f f_assignments_size units idx.1 assignments) : ClearInsertInductionMotive f f_assignments_size units (idx.1 + 1) (clearUnit assignments units[idx])
case right.right.right.right n : Nat f : DefaultFormula n f_assignments_size : f.assignments.size = n units : Array (Literal (PosFin n)) units_nodup : ∀ (i j : Fin units.size), i ≠ j → units[i] ≠ units[j] idx : Fin units.size assignments : Array Assignment hsize : assignments.size = n hsize' : (clearUnit assignments units[idx]).size = n i : Fin n j1 : Fin units.size j1_ge_idx : ↑j1 ≥ ↑idx j2 : Fin units.size j2_ge_idx : ↑j2 ≥ ↑idx i_gt_zero : ↑i > 0 ih1 : units[↑j1] = (⟨↑i, ⋯⟩, true) ih2 : units[↑j2] = (⟨↑i, ⋯⟩, false) ih3 : assignments[↑i] = both ih4 : f.assignments[↑i] = unassigned ih5 : ∀ (k : Fin units.size), ↑k ≥ ↑idx → ¬k = j1 → ¬k = j2 → ¬units[↑k].fst.val = ↑i idx_ne_j1 : ¬idx = j1 idx_ne_j2 : ¬idx = j2 ⊢ (clearUnit assignments units[idx])[↑i] = both ∧ f.assignments[↑i] = unassigned ∧ ∀ (k : Fin units.size), ↑k ≥ ↑idx + 1 → k ≠ j1 → k ≠ j2 → units[k].fst.val ≠ ↑i
constructor
case right.right.right.right.left n : Nat f : DefaultFormula n f_assignments_size : f.assignments.size = n units : Array (Literal (PosFin n)) units_nodup : ∀ (i j : Fin units.size), i ≠ j → units[i] ≠ units[j] idx : Fin units.size assignments : Array Assignment hsize : assignments.size = n hsize' : (clearUnit assignments units[idx]).size = n i : Fin n j1 : Fin units.size j1_ge_idx : ↑j1 ≥ ↑idx j2 : Fin units.size j2_ge_idx : ↑j2 ≥ ↑idx i_gt_zero : ↑i > 0 ih1 : units[↑j1] = (⟨↑i, ⋯⟩, true) ih2 : units[↑j2] = (⟨↑i, ⋯⟩, false) ih3 : assignments[↑i] = both ih4 : f.assignments[↑i] = unassigned ih5 : ∀ (k : Fin units.size), ↑k ≥ ↑idx → ¬k = j1 → ¬k = j2 → ¬units[↑k].fst.val = ↑i idx_ne_j1 : ¬idx = j1 idx_ne_j2 : ¬idx = j2 ⊢ (clearUnit assignments units[idx])[↑i] = both case right.right.right.right.right n : Nat f : DefaultFormula n f_assignments_size : f.assignments.size = n units : Array (Literal (PosFin n)) units_nodup : ∀ (i j : Fin units.size), i ≠ j → units[i] ≠ units[j] idx : Fin units.size assignments : Array Assignment hsize : assignments.size = n hsize' : (clearUnit assignments units[idx]).size = n i : Fin n j1 : Fin units.size j1_ge_idx : ↑j1 ≥ ↑idx j2 : Fin units.size j2_ge_idx : ↑j2 ≥ ↑idx i_gt_zero : ↑i > 0 ih1 : units[↑j1] = (⟨↑i, ⋯⟩, true) ih2 : units[↑j2] = (⟨↑i, ⋯⟩, false) ih3 : assignments[↑i] = both ih4 : f.assignments[↑i] = unassigned ih5 : ∀ (k : Fin units.size), ↑k ≥ ↑idx → ¬k = j1 → ¬k = j2 → ¬units[↑k].fst.val = ↑i idx_ne_j1 : ¬idx = j1 idx_ne_j2 : ¬idx = j2 ⊢ f.assignments[↑i] = unassigned ∧ ∀ (k : Fin units.size), ↑k ≥ ↑idx + 1 → k ≠ j1 → k ≠ j2 → units[k].fst.val ≠ ↑i
c90be518eb885cb1
hasFDerivAt_of_tendstoUniformlyOnFilter
Mathlib/Analysis/Calculus/UniformLimitsDeriv.lean
theorem hasFDerivAt_of_tendstoUniformlyOnFilter [NeBot l] (hf' : TendstoUniformlyOnFilter f' g' l (𝓝 x)) (hf : ∀ᶠ n : ι × E in l ×ˢ 𝓝 x, HasFDerivAt (f n.1) (f' n.1 n.2) n.2) (hfg : ∀ᶠ y in 𝓝 x, Tendsto (fun n => f n y) l (𝓝 (g y))) : HasFDerivAt g (g' x) x
case h ι : Type u_1 l : Filter ι E : Type u_2 inst✝⁶ : NormedAddCommGroup E 𝕜 : Type u_3 inst✝⁵ : NontriviallyNormedField 𝕜 inst✝⁴ : IsRCLikeNormedField 𝕜 inst✝³ : NormedSpace 𝕜 E G : Type u_4 inst✝² : NormedAddCommGroup G inst✝¹ : NormedSpace 𝕜 G f : ι → E → G g : E → G f' : ι → E → E →L[𝕜] G g' : E → E →L[𝕜] G x : E inst✝ : l.NeBot hf' : TendstoUniformlyOnFilter f' g' l (𝓝 x) hf : ∀ᶠ (n : ι × E) in l ×ˢ 𝓝 x, HasFDerivAt (f n.1) (f' n.1 n.2) n.2 hfg : ∀ᶠ (y : E) in 𝓝 x, Tendsto (fun n => f n y) l (𝓝 (g y)) this : RCLike 𝕜 := IsRCLikeNormedField.rclike 𝕜 x✝ : ι × E ⊢ (↑‖x✝.2 - x‖)⁻¹ • (g x✝.2 - g x - (g' x) (x✝.2 - x)) = (↑‖x✝.2 - x‖)⁻¹ • (g x✝.2 - g x - (f x✝.1 x✝.2 - f x✝.1 x) + (f x✝.1 x✝.2 - f x✝.1 x - ((f' x✝.1 x) x✝.2 - (f' x✝.1 x) x)) + (f' x✝.1 x - g' x) (x✝.2 - x))
congr
case h.e_a ι : Type u_1 l : Filter ι E : Type u_2 inst✝⁶ : NormedAddCommGroup E 𝕜 : Type u_3 inst✝⁵ : NontriviallyNormedField 𝕜 inst✝⁴ : IsRCLikeNormedField 𝕜 inst✝³ : NormedSpace 𝕜 E G : Type u_4 inst✝² : NormedAddCommGroup G inst✝¹ : NormedSpace 𝕜 G f : ι → E → G g : E → G f' : ι → E → E →L[𝕜] G g' : E → E →L[𝕜] G x : E inst✝ : l.NeBot hf' : TendstoUniformlyOnFilter f' g' l (𝓝 x) hf : ∀ᶠ (n : ι × E) in l ×ˢ 𝓝 x, HasFDerivAt (f n.1) (f' n.1 n.2) n.2 hfg : ∀ᶠ (y : E) in 𝓝 x, Tendsto (fun n => f n y) l (𝓝 (g y)) this : RCLike 𝕜 := IsRCLikeNormedField.rclike 𝕜 x✝ : ι × E ⊢ g x✝.2 - g x - (g' x) (x✝.2 - x) = g x✝.2 - g x - (f x✝.1 x✝.2 - f x✝.1 x) + (f x✝.1 x✝.2 - f x✝.1 x - ((f' x✝.1 x) x✝.2 - (f' x✝.1 x) x)) + (f' x✝.1 x - g' x) (x✝.2 - x)
d7a89a2808c33b6f
ENNReal.toReal_eq_toReal_iff'
Mathlib/Data/ENNReal/Basic.lean
theorem toReal_eq_toReal_iff' {x y : ℝ≥0∞} (hx : x ≠ ⊤) (hy : y ≠ ⊤) : x.toReal = y.toReal ↔ x = y
x y : ℝ≥0∞ hx : x ≠ ⊤ hy : y ≠ ⊤ ⊢ x.toReal = y.toReal ↔ x = y
simp only [ENNReal.toReal, NNReal.coe_inj, toNNReal_eq_toNNReal_iff' hx hy]
no goals
ea89e142acb8ae88
RootPairing.smul_coroot_eq_of_root_eq_smul
Mathlib/LinearAlgebra/RootSystem/Defs.lean
lemma smul_coroot_eq_of_root_eq_smul [Finite ι] [NoZeroSMulDivisors ℤ N] (i j : ι) (t : R) (h : P.root j = t • P.root i) : t • P.coroot j = P.coroot i
ι : Type u_1 R : Type u_2 M : Type u_3 N : Type u_4 inst✝⁶ : CommRing R inst✝⁵ : AddCommGroup M inst✝⁴ : Module R M inst✝³ : AddCommGroup N inst✝² : Module R N P : RootPairing ι R M N inst✝¹ : Finite ι inst✝ : NoZeroSMulDivisors ℤ N i j : ι t : R h : P.root j = t • P.root i hij : t * P.pairing i j = 2 ⊢ (P.root' i) (P.coroot i) = 2
simp
no goals
b308f2233dbb1785
FreeGroup.Red.to_append_iff
Mathlib/GroupTheory/FreeGroup/Basic.lean
theorem to_append_iff : Red L (L₁ ++ L₂) ↔ ∃ L₃ L₄, L = L₃ ++ L₄ ∧ Red L₃ L₁ ∧ Red L₄ L₂ := Iff.intro (by generalize eq : L₁ ++ L₂ = L₁₂ intro h induction' h with L' L₁₂ hLL' h ih generalizing L₁ L₂ · exact ⟨_, _, eq.symm, by rfl, by rfl⟩ · obtain @⟨s, e, a, b⟩ := h rcases List.append_eq_append_iff.1 eq with (⟨s', rfl, rfl⟩ | ⟨e', rfl, rfl⟩) · have : L₁ ++ (s' ++ (a, b) :: (a, not b) :: e) = L₁ ++ s' ++ (a, b) :: (a, not b) :: e := by simp rcases ih this with ⟨w₁, w₂, rfl, h₁, h₂⟩ exact ⟨w₁, w₂, rfl, h₁, h₂.tail Step.not⟩ · have : s ++ (a, b) :: (a, not b) :: e' ++ L₂ = s ++ (a, b) :: (a, not b) :: (e' ++ L₂) := by simp rcases ih this with ⟨w₁, w₂, rfl, h₁, h₂⟩ exact ⟨w₁, w₂, rfl, h₁.tail Step.not, h₂⟩) fun ⟨_, _, Eq, h₃, h₄⟩ => Eq.symm ▸ append_append h₃ h₄
α : Type u L L₁ L₂ L₁₂ : List (α × Bool) eq : L₁ ++ L₂ = L₁₂ ⊢ Red L L₁₂ → ∃ L₃ L₄, L = L₃ ++ L₄ ∧ Red L₃ L₁ ∧ Red L₄ L₂
intro h
α : Type u L L₁ L₂ L₁₂ : List (α × Bool) eq : L₁ ++ L₂ = L₁₂ h : Red L L₁₂ ⊢ ∃ L₃ L₄, L = L₃ ++ L₄ ∧ Red L₃ L₁ ∧ Red L₄ L₂
6fd81a62b1bdb428
List.getElem_of_append
Mathlib/.lake/packages/lean4/src/lean/Init/Data/List/Lemmas.lean
theorem getElem_of_append {l : List α} (eq : l = l₁ ++ a :: l₂) (h : l₁.length = i) : l[i]'(eq ▸ h ▸ by simp_arith) = a := Option.some.inj <| by rw [← getElem?_eq_getElem, eq, getElem?_append_right (h ▸ Nat.le_refl _), h] simp
α : Type u_1 l₁ : List α a : α l₂ : List α i : Nat l : List α eq : l = l₁ ++ a :: l₂ h : l₁.length = i ⊢ (a :: l₂)[i - i]? = some a
simp
no goals
5ad05d79585858af
IsIntegrallyClosed.pow_dvd_pow_iff
Mathlib/RingTheory/IntegralClosure/IntegrallyClosed.lean
theorem pow_dvd_pow_iff [IsDomain R] [IsIntegrallyClosed R] {n : ℕ} (hn : n ≠ 0) {a b : R} : a ^ n ∣ b ^ n ↔ a ∣ b
case neg R : Type u_1 inst✝² : CommRing R inst✝¹ : IsDomain R inst✝ : IsIntegrallyClosed R n : ℕ hn : n ≠ 0 a b : R x✝ : a ^ n ∣ b ^ n x : R hx : b ^ n = a ^ n * x ha : ¬a = 0 ⊢ a ∣ b
let K := FractionRing R
case neg R : Type u_1 inst✝² : CommRing R inst✝¹ : IsDomain R inst✝ : IsIntegrallyClosed R n : ℕ hn : n ≠ 0 a b : R x✝ : a ^ n ∣ b ^ n x : R hx : b ^ n = a ^ n * x ha : ¬a = 0 K : Type u_1 := FractionRing R ⊢ a ∣ b
fff7a7a39e81336f
MeasureTheory.IsSetSemiring.exists_disjoint_finset_diff_eq
Mathlib/MeasureTheory/SetSemiring.lean
/-- In a semiring of sets `C`, for all set `s ∈ C` and finite set of sets `I ⊆ C`, there is a finite set of sets in `C` whose union is `s \ ⋃₀ I`. See `IsSetSemiring.disjointOfDiffUnion` for a definition that gives such a set. -/ lemma exists_disjoint_finset_diff_eq (hC : IsSetSemiring C) (hs : s ∈ C) (hI : ↑I ⊆ C) : ∃ J : Finset (Set α), ↑J ⊆ C ∧ PairwiseDisjoint (J : Set (Set α)) id ∧ s \ ⋃₀ I = ⋃₀ J
α : Type u_1 C : Set (Set α) s : Set α I : Finset (Set α) hC : IsSetSemiring C hs : s ∈ C t : Set α I' : Finset (Set α) a✝ : t ∉ I' h : ↑I' ⊆ C → ∃ J, ↑J ⊆ C ∧ (↑J).PairwiseDisjoint id ∧ s \ ⋃₀ ↑I' = ⋃₀ ↑J hI : insert t ↑I' ⊆ C ht : t ∈ C J : Finset (Set α) h_ss : ↑J ⊆ C h_dis : (↑J).PairwiseDisjoint id h_eq : s \ ⋃₀ ↑I' = ⋃₀ ↑J Ju : (u : Set α) → u ∈ C → Finset (Set α) := fun u hu => hC.disjointOfDiff hu ht hJu_subset : ∀ (u : Set α) (hu : u ∈ C), ↑(Ju u hu) ⊆ C hJu_disj : ∀ (u : Set α) (hu : u ∈ C), (↑(Ju u hu)).PairwiseDisjoint id hJu_sUnion : ∀ (u : Set α) (hu : u ∈ C), ⋃₀ ↑(Ju u hu) = u \ t u : Set α hu : u ∈ C v : Set α hv : v ∈ C huv_disj : Disjoint u v ⊢ Disjoint (⋃₀ ↑(Ju u hu)) (⋃₀ ↑(Ju v hv))
rw [hJu_sUnion, hJu_sUnion]
α : Type u_1 C : Set (Set α) s : Set α I : Finset (Set α) hC : IsSetSemiring C hs : s ∈ C t : Set α I' : Finset (Set α) a✝ : t ∉ I' h : ↑I' ⊆ C → ∃ J, ↑J ⊆ C ∧ (↑J).PairwiseDisjoint id ∧ s \ ⋃₀ ↑I' = ⋃₀ ↑J hI : insert t ↑I' ⊆ C ht : t ∈ C J : Finset (Set α) h_ss : ↑J ⊆ C h_dis : (↑J).PairwiseDisjoint id h_eq : s \ ⋃₀ ↑I' = ⋃₀ ↑J Ju : (u : Set α) → u ∈ C → Finset (Set α) := fun u hu => hC.disjointOfDiff hu ht hJu_subset : ∀ (u : Set α) (hu : u ∈ C), ↑(Ju u hu) ⊆ C hJu_disj : ∀ (u : Set α) (hu : u ∈ C), (↑(Ju u hu)).PairwiseDisjoint id hJu_sUnion : ∀ (u : Set α) (hu : u ∈ C), ⋃₀ ↑(Ju u hu) = u \ t u : Set α hu : u ∈ C v : Set α hv : v ∈ C huv_disj : Disjoint u v ⊢ Disjoint (u \ t) (v \ t)
0bd1b80571fe1ad6
quasispectrum.mul_comm
Mathlib/Algebra/Algebra/Quasispectrum.lean
lemma quasispectrum.mul_comm {R A : Type*} [CommRing R] [NonUnitalRing A] [Module R A] [IsScalarTower R A A] [SMulCommClass R A A] (a b : A) : quasispectrum R (a * b) = quasispectrum R (b * a)
case h.e'_4 R : Type u_3 A : Type u_4 inst✝⁴ : CommRing R inst✝³ : NonUnitalRing A inst✝² : Module R A inst✝¹ : IsScalarTower R A A inst✝ : SMulCommClass R A A a b : A ⊢ quasispectrum R (a * b) ∩ {r | IsUnit r}ᶜ = quasispectrum R (b * a) ∩ {r | IsUnit r}ᶜ
rw [Set.inter_eq_right.mpr, Set.inter_eq_right.mpr]
case h.e'_4 R : Type u_3 A : Type u_4 inst✝⁴ : CommRing R inst✝³ : NonUnitalRing A inst✝² : Module R A inst✝¹ : IsScalarTower R A A inst✝ : SMulCommClass R A A a b : A ⊢ {r | IsUnit r}ᶜ ⊆ quasispectrum R (b * a) case h.e'_4 R : Type u_3 A : Type u_4 inst✝⁴ : CommRing R inst✝³ : NonUnitalRing A inst✝² : Module R A inst✝¹ : IsScalarTower R A A inst✝ : SMulCommClass R A A a b : A ⊢ {r | IsUnit r}ᶜ ⊆ quasispectrum R (a * b)
8da711bcdac575e2
FormalMultilinearSeries.changeOriginSeriesTerm_changeOriginIndexEquiv_symm
Mathlib/Analysis/Analytic/ChangeOrigin.lean
lemma changeOriginSeriesTerm_changeOriginIndexEquiv_symm (n t) : let s := changeOriginIndexEquiv.symm ⟨n, t⟩ p.changeOriginSeriesTerm s.1 s.2.1 s.2.2 s.2.2.2 (fun _ ↦ x) (fun _ ↦ y) = p n (t.piecewise (fun _ ↦ x) fun _ ↦ y)
𝕜 : Type u_1 E : Type u_2 F : Type u_3 inst✝⁴ : NontriviallyNormedField 𝕜 inst✝³ : NormedAddCommGroup E inst✝² : NormedSpace 𝕜 E inst✝¹ : NormedAddCommGroup F inst✝ : NormedSpace 𝕜 F p : FormalMultilinearSeries 𝕜 E F x y : E n : ℕ t : Finset (Fin n) ⊢ ∀ (m : ℕ) (hm : n = m), (p n) (t.piecewise (fun x_1 => x) fun x => y) = (p m) ((Finset.map (finCongr hm).toEmbedding t).piecewise (fun x_1 => x) fun x => y)
rintro m rfl
𝕜 : Type u_1 E : Type u_2 F : Type u_3 inst✝⁴ : NontriviallyNormedField 𝕜 inst✝³ : NormedAddCommGroup E inst✝² : NormedSpace 𝕜 E inst✝¹ : NormedAddCommGroup F inst✝ : NormedSpace 𝕜 F p : FormalMultilinearSeries 𝕜 E F x y : E n : ℕ t : Finset (Fin n) ⊢ (p n) (t.piecewise (fun x_1 => x) fun x => y) = (p n) ((Finset.map (finCongr ⋯).toEmbedding t).piecewise (fun x_1 => x) fun x => y)
22d7f6c6c9378f52
IsArtinian.surjective_of_injective_endomorphism
Mathlib/RingTheory/Artinian/Module.lean
theorem surjective_of_injective_endomorphism (f : M →ₗ[R] M) (s : Injective f) : Surjective f
R : Type u_1 M : Type u_2 inst✝³ : Semiring R inst✝² : AddCommMonoid M inst✝¹ : Module R M inst✝ : IsArtinian R M f : M →ₗ[R] M s : Injective ⇑f h : ¬Surjective ⇑f ⊢ ∀ (n : ℕ), (fun x => LinearMap.range (f ^ x)) (n + 1) < (fun x => LinearMap.range (f ^ x)) n
intro n
R : Type u_1 M : Type u_2 inst✝³ : Semiring R inst✝² : AddCommMonoid M inst✝¹ : Module R M inst✝ : IsArtinian R M f : M →ₗ[R] M s : Injective ⇑f h : ¬Surjective ⇑f n : ℕ ⊢ (fun x => LinearMap.range (f ^ x)) (n + 1) < (fun x => LinearMap.range (f ^ x)) n
b91f29bf146c34f4
ZMod.natCast_eq_iff
Mathlib/Data/ZMod/Basic.lean
theorem natCast_eq_iff (p : ℕ) (n : ℕ) (z : ZMod p) [NeZero p] : ↑n = z ↔ ∃ k, n = z.val + p * k
case mpr.intro p : ℕ z : ZMod p inst✝ : NeZero p k : ℕ ⊢ ↑(z.val + p * k) = z
rw [Nat.cast_add, natCast_zmod_val, Nat.cast_mul, natCast_self, zero_mul, add_zero]
no goals
ab99dcba150b55bd
ZMod.castHom_bijective
Mathlib/Data/ZMod/Basic.lean
theorem castHom_bijective [Fintype R] (h : Fintype.card R = n) : Function.Bijective (ZMod.castHom (dvd_refl n) R)
n : ℕ R : Type u_1 inst✝² : Ring R inst✝¹ : CharP R n inst✝ : Fintype R h : Fintype.card R = n this : NeZero n ⊢ Injective ⇑(castHom ⋯ R)
apply ZMod.castHom_injective
no goals
f5948c31783484d7
QuaternionAlgebra.Basis.ext
Mathlib/Algebra/QuaternionBasis.lean
theorem ext ⦃q₁ q₂ : Basis A c₁ c₂ c₃⦄ (hi : q₁.i = q₂.i) (hj : q₁.j = q₂.j) : q₁ = q₂
case mk R : Type u_1 A : Type u_2 inst✝² : CommRing R inst✝¹ : Ring A inst✝ : Algebra R A c₁ c₂ c₃ : R q₂ : Basis A c₁ c₂ c₃ i✝ j✝ k✝ : A i_mul_i✝ : i✝ * i✝ = c₁ • 1 + c₂ • i✝ j_mul_j✝ : j✝ * j✝ = c₃ • 1 i_mul_j✝ : i✝ * j✝ = k✝ j_mul_i✝ : j✝ * i✝ = c₂ • j✝ - k✝ hi : { i := i✝, j := j✝, k := k✝, i_mul_i := i_mul_i✝, j_mul_j := j_mul_j✝, i_mul_j := i_mul_j✝, j_mul_i := j_mul_i✝ }.i = q₂.i hj : { i := i✝, j := j✝, k := k✝, i_mul_i := i_mul_i✝, j_mul_j := j_mul_j✝, i_mul_j := i_mul_j✝, j_mul_i := j_mul_i✝ }.j = q₂.j ⊢ { i := i✝, j := j✝, k := k✝, i_mul_i := i_mul_i✝, j_mul_j := j_mul_j✝, i_mul_j := i_mul_j✝, j_mul_i := j_mul_i✝ } = q₂
rename_i q₁_i_mul_j _
case mk R : Type u_1 A : Type u_2 inst✝² : CommRing R inst✝¹ : Ring A inst✝ : Algebra R A c₁ c₂ c₃ : R q₂ : Basis A c₁ c₂ c₃ i✝ j✝ k✝ : A i_mul_i✝ : i✝ * i✝ = c₁ • 1 + c₂ • i✝ j_mul_j✝ : j✝ * j✝ = c₃ • 1 q₁_i_mul_j : i✝ * j✝ = k✝ j_mul_i✝ : j✝ * i✝ = c₂ • j✝ - k✝ hi : { i := i✝, j := j✝, k := k✝, i_mul_i := i_mul_i✝, j_mul_j := j_mul_j✝, i_mul_j := q₁_i_mul_j, j_mul_i := j_mul_i✝ }.i = q₂.i hj : { i := i✝, j := j✝, k := k✝, i_mul_i := i_mul_i✝, j_mul_j := j_mul_j✝, i_mul_j := q₁_i_mul_j, j_mul_i := j_mul_i✝ }.j = q₂.j ⊢ { i := i✝, j := j✝, k := k✝, i_mul_i := i_mul_i✝, j_mul_j := j_mul_j✝, i_mul_j := q₁_i_mul_j, j_mul_i := j_mul_i✝ } = q₂
4fecd0862ec9d558
Set.image_const_sub_Iio
Mathlib/Algebra/Order/Group/Pointwise/Interval.lean
theorem image_const_sub_Iio : (fun x => a - x) '' Iio b = Ioi (a - b)
α : Type u_1 inst✝ : OrderedAddCommGroup α a b : α this : ∀ (a_1 : Set α), ((fun x => a + x) ∘ fun x => -x) '' a_1 = (fun x => a + x) '' ((fun x => -x) '' a_1) ⊢ (fun x => a - x) '' Iio b = Ioi (a - b)
dsimp [Function.comp_def] at this
α : Type u_1 inst✝ : OrderedAddCommGroup α a b : α this : ∀ (a_1 : Set α), (fun x => a + -x) '' a_1 = (fun x => a + x) '' ((fun x => -x) '' a_1) ⊢ (fun x => a - x) '' Iio b = Ioi (a - b)
5983d5134060a94c
CategoryTheory.ShortComplex.isIso_homologyMap_of_epi_of_isIso_of_mono'
Mathlib/Algebra/Homology/ShortComplex/Homology.lean
lemma isIso_homologyMap_of_epi_of_isIso_of_mono' (φ : S₁ ⟶ S₂) [S₁.HasHomology] [S₂.HasHomology] (h₁ : Epi φ.τ₁) (h₂ : IsIso φ.τ₂) (h₃ : Mono φ.τ₃) : IsIso (homologyMap φ)
C : Type u inst✝³ : Category.{v, u} C inst✝² : HasZeroMorphisms C S₁ S₂ : ShortComplex C φ : S₁ ⟶ S₂ inst✝¹ : S₁.HasHomology inst✝ : S₂.HasHomology h₁ : Epi φ.τ₁ h₂ : IsIso φ.τ₂ h₃ : Mono φ.τ₃ ⊢ IsIso (homologyMap φ)
dsimp only [homologyMap]
C : Type u inst✝³ : Category.{v, u} C inst✝² : HasZeroMorphisms C S₁ S₂ : ShortComplex C φ : S₁ ⟶ S₂ inst✝¹ : S₁.HasHomology inst✝ : S₂.HasHomology h₁ : Epi φ.τ₁ h₂ : IsIso φ.τ₂ h₃ : Mono φ.τ₃ ⊢ IsIso (homologyMap' φ S₁.homologyData S₂.homologyData)
ba7976bb8d6998a3
Set.Countable.isPathConnected_compl_of_one_lt_rank
Mathlib/Analysis/NormedSpace/Connected.lean
theorem Set.Countable.isPathConnected_compl_of_one_lt_rank (h : 1 < Module.rank ℝ E) {s : Set E} (hs : s.Countable) : IsPathConnected sᶜ
case intro.inr E : Type u_1 inst✝⁴ : AddCommGroup E inst✝³ : Module ℝ E inst✝² : TopologicalSpace E inst✝¹ : ContinuousAdd E inst✝ : ContinuousSMul ℝ E h : 1 < Module.rank ℝ E s : Set E hs : s.Countable this : Nontrivial E a : E ha : a ∈ sᶜ b : E hb : b ∈ sᶜ hab : a ≠ b c : E := 2⁻¹ • (a + b) x : E := 2⁻¹ • (b - a) ⊢ JoinedIn sᶜ a b
have Ia : c - x = a := by simp only [c, x] module
case intro.inr E : Type u_1 inst✝⁴ : AddCommGroup E inst✝³ : Module ℝ E inst✝² : TopologicalSpace E inst✝¹ : ContinuousAdd E inst✝ : ContinuousSMul ℝ E h : 1 < Module.rank ℝ E s : Set E hs : s.Countable this : Nontrivial E a : E ha : a ∈ sᶜ b : E hb : b ∈ sᶜ hab : a ≠ b c : E := 2⁻¹ • (a + b) x : E := 2⁻¹ • (b - a) Ia : c - x = a ⊢ JoinedIn sᶜ a b
a2405a5e761a2c4d
DirectSum.decompose_lhom_ext
Mathlib/Algebra/DirectSum/Decomposition.lean
theorem decompose_lhom_ext {N} [AddCommMonoid N] [Module R N] ⦃f g : M →ₗ[R] N⦄ (h : ∀ i, f ∘ₗ (ℳ i).subtype = g ∘ₗ (ℳ i).subtype) : f = g := LinearMap.ext <| (decomposeLinearEquiv ℳ).symm.surjective.forall.mpr <| suffices f ∘ₗ (decomposeLinearEquiv ℳ).symm = (g ∘ₗ (decomposeLinearEquiv ℳ).symm : (⨁ i, ℳ i) →ₗ[R] N) from DFunLike.congr_fun this linearMap_ext _ fun i => by simp_rw [LinearMap.comp_assoc, decomposeLinearEquiv_symm_comp_lof ℳ i, h]
ι : Type u_1 R : Type u_2 M : Type u_3 inst✝⁶ : DecidableEq ι inst✝⁵ : Semiring R inst✝⁴ : AddCommMonoid M inst✝³ : Module R M ℳ : ι → Submodule R M inst✝² : Decomposition ℳ N : Type u_5 inst✝¹ : AddCommMonoid N inst✝ : Module R N f g : M →ₗ[R] N h : ∀ (i : ι), f ∘ₗ (ℳ i).subtype = g ∘ₗ (ℳ i).subtype i : ι ⊢ (f ∘ₗ ↑(decomposeLinearEquiv ℳ).symm) ∘ₗ lof R ι (fun i => ↥(ℳ i)) i = (g ∘ₗ ↑(decomposeLinearEquiv ℳ).symm) ∘ₗ lof R ι (fun i => ↥(ℳ i)) i
simp_rw [LinearMap.comp_assoc, decomposeLinearEquiv_symm_comp_lof ℳ i, h]
no goals
df4cf824c2973bb8
Set.Nonempty.eq_univ
Mathlib/Data/Set/Basic.lean
theorem Nonempty.eq_univ [Subsingleton α] : s.Nonempty → s = univ
case intro α : Type u s : Set α inst✝ : Subsingleton α x : α hx : x ∈ s ⊢ s = univ
exact eq_univ_of_forall fun y => by rwa [Subsingleton.elim y x]
no goals
5ca5e8752663b705
Nat.divisors_subset_properDivisors
Mathlib/NumberTheory/Divisors.lean
theorem divisors_subset_properDivisors {m : ℕ} (hzero : n ≠ 0) (h : m ∣ n) (hdiff : m ≠ n) : divisors m ⊆ properDivisors n
n m : ℕ hzero : n ≠ 0 h : m ∣ n hdiff : m ≠ n ⊢ ∀ ⦃x : ℕ⦄, x ∈ m.divisors → x ∈ n.properDivisors
intro x hx
n m : ℕ hzero : n ≠ 0 h : m ∣ n hdiff : m ≠ n x : ℕ hx : x ∈ m.divisors ⊢ x ∈ n.properDivisors
b0a1218cac480e84
AlgebraicGeometry.StructureSheaf.comap_comp
Mathlib/AlgebraicGeometry/StructureSheaf.lean
theorem comap_comp (f : R →+* S) (g : S →+* P) (U : Opens (PrimeSpectrum.Top R)) (V : Opens (PrimeSpectrum.Top S)) (W : Opens (PrimeSpectrum.Top P)) (hUV : ∀ p ∈ V, PrimeSpectrum.comap f p ∈ U) (hVW : ∀ p ∈ W, PrimeSpectrum.comap g p ∈ V) : (comap (g.comp f) U W fun p hpW => hUV (PrimeSpectrum.comap g p) (hVW p hpW)) = (comap g V W hVW).comp (comap f U V hUV) := RingHom.ext fun s => Subtype.eq <| funext fun p => by rw [comap_apply] rw [Localization.localRingHom_comp _ (PrimeSpectrum.comap g p.1).asIdeal] <;> -- refl works here, because `PrimeSpectrum.comap (g.comp f) p` is defeq to -- `PrimeSpectrum.comap f (PrimeSpectrum.comap g p)` rfl
R : Type u inst✝² : CommRing R S : Type u inst✝¹ : CommRing S P : Type u inst✝ : CommRing P f : R →+* S g : S →+* P U : Opens ↑(PrimeSpectrum.Top R) V : Opens ↑(PrimeSpectrum.Top S) W : Opens ↑(PrimeSpectrum.Top P) hUV : ∀ p ∈ V, (PrimeSpectrum.comap f) p ∈ U hVW : ∀ p ∈ W, (PrimeSpectrum.comap g) p ∈ V s : ↑((structureSheaf R).val.obj (op U)) p : ↥(unop (op W)) ⊢ (Localization.localRingHom ((PrimeSpectrum.comap (g.comp f)) ↑p).asIdeal (↑p).asIdeal (g.comp f) ⋯) (↑s ⟨(PrimeSpectrum.comap (g.comp f)) ↑p, ⋯⟩) = ↑(((comap g V W hVW).comp (comap f U V hUV)) s) p
rw [Localization.localRingHom_comp _ (PrimeSpectrum.comap g p.1).asIdeal] <;> rfl
no goals
a319f413ced4abd9
PerfectPairing.exists_basis_basis_of_span_eq_top_of_mem_algebraMap
Mathlib/LinearAlgebra/PerfectPairing/Restrict.lean
/-- If a perfect pairing over a field `L` takes values in a subfield `K` along two `K`-subspaces whose `L` span is full, then these subspaces induce a `K`-structure in the sense of [*Algebra I*, Bourbaki : Chapter II, §8.1 Definition 1][bourbaki1989]. -/ lemma exists_basis_basis_of_span_eq_top_of_mem_algebraMap (M' : Submodule K M) (N' : Submodule K N) (hM : span L (M' : Set M) = ⊤) (hN : span L (N' : Set N) = ⊤) (hp : ∀ᵉ (x ∈ M') (y ∈ N'), p x y ∈ (algebraMap K L).range) : ∃ (n : ℕ) (b : Basis (Fin n) L M) (b' : Basis (Fin n) K M'), ∀ i, b i = b' i
case intro.intro.intro K : Type u_1 L : Type u_2 M : Type u_3 N : Type u_4 inst✝⁹ : Field K inst✝⁸ : Field L inst✝⁷ : Algebra K L inst✝⁶ : AddCommGroup M inst✝⁵ : AddCommGroup N inst✝⁴ : Module L M inst✝³ : Module L N inst✝² : Module K M inst✝¹ : Module K N inst✝ : IsScalarTower K L M p : PerfectPairing L M N M' : Submodule K M N' : Submodule K N hM : span L ↑M' = ⊤ hN : span L ↑N' = ⊤ hp : ∀ x ∈ M', ∀ y ∈ N', (p x) y ∈ (algebraMap K L).range this✝¹ : IsReflexive L M this✝ : IsReflexive L N v : Set M hv₁ : v ⊆ ↑M' hv₂ : span L v = ⊤ hv₃ : LinearIndependent L Subtype.val b : Basis { x // x ∈ v } L M := Basis.mk hv₃ ⋯ this : Fintype ↑v v' : ↑v → ↥M' := fun i => ⟨↑i, ⋯⟩ ⊢ ∃ n b b', ∀ (i : Fin n), b i = ↑(b' i)
have hv' : LinearIndependent K v' := by replace hv₃ := hv₃.restrict_scalars (R := K) <| by simp_rw [← Algebra.algebraMap_eq_smul_one] exact FaithfulSMul.algebraMap_injective K L rw [show ((↑) : v → M) = M'.subtype ∘ v' by ext; simp [v']] at hv₃ exact hv₃.of_comp
case intro.intro.intro K : Type u_1 L : Type u_2 M : Type u_3 N : Type u_4 inst✝⁹ : Field K inst✝⁸ : Field L inst✝⁷ : Algebra K L inst✝⁶ : AddCommGroup M inst✝⁵ : AddCommGroup N inst✝⁴ : Module L M inst✝³ : Module L N inst✝² : Module K M inst✝¹ : Module K N inst✝ : IsScalarTower K L M p : PerfectPairing L M N M' : Submodule K M N' : Submodule K N hM : span L ↑M' = ⊤ hN : span L ↑N' = ⊤ hp : ∀ x ∈ M', ∀ y ∈ N', (p x) y ∈ (algebraMap K L).range this✝¹ : IsReflexive L M this✝ : IsReflexive L N v : Set M hv₁ : v ⊆ ↑M' hv₂ : span L v = ⊤ hv₃ : LinearIndependent L Subtype.val b : Basis { x // x ∈ v } L M := Basis.mk hv₃ ⋯ this : Fintype ↑v v' : ↑v → ↥M' := fun i => ⟨↑i, ⋯⟩ hv' : LinearIndependent (ι := ↑v) K v' ⊢ ∃ n b b', ∀ (i : Fin n), b i = ↑(b' i)
28e714660261030d
MeasureTheory.isStoppingTime_hitting_isStoppingTime
Mathlib/Probability/Process/HittingTime.lean
theorem isStoppingTime_hitting_isStoppingTime [ConditionallyCompleteLinearOrder ι] [WellFoundedLT ι] [Countable ι] [TopologicalSpace ι] [OrderTopology ι] [FirstCountableTopology ι] [TopologicalSpace β] [PseudoMetrizableSpace β] [MeasurableSpace β] [BorelSpace β] {f : Filtration ι m} {u : ι → Ω → β} {τ : Ω → ι} (hτ : IsStoppingTime f τ) {N : ι} (hτbdd : ∀ x, τ x ≤ N) {s : Set β} (hs : MeasurableSet s) (hf : Adapted f u) : IsStoppingTime f fun x => hitting u s (τ x) N x
Ω : Type u_1 β : Type u_2 ι : Type u_3 m : MeasurableSpace Ω inst✝⁹ : ConditionallyCompleteLinearOrder ι inst✝⁸ : WellFoundedLT ι inst✝⁷ : Countable ι inst✝⁶ : TopologicalSpace ι inst✝⁵ : OrderTopology ι inst✝⁴ : FirstCountableTopology ι inst✝³ : TopologicalSpace β inst✝² : PseudoMetrizableSpace β inst✝¹ : MeasurableSpace β inst✝ : BorelSpace β f : Filtration ι m u : ι → Ω → β τ : Ω → ι hτ : IsStoppingTime f τ N : ι hτbdd : ∀ (x : Ω), τ x ≤ N s : Set β hs : MeasurableSet s hf : Adapted f u n : ι h₁ : {x | hitting u s (τ x) N x ≤ n} = (⋃ i, ⋃ (_ : i ≤ n), {x | τ x = i} ∩ {x | hitting u s i N x ≤ n}) ∪ ⋃ i, ⋃ (_ : i > n), {x | τ x = i} ∩ {x | hitting u s i N x ≤ n} ⊢ MeasurableSet {ω | (fun x => hitting u s (τ x) N x) ω ≤ n}
have h₂ : ⋃ i > n, {x | τ x = i} ∩ {x | hitting u s i N x ≤ n} = ∅ := by ext x simp only [gt_iff_lt, Set.mem_iUnion, Set.mem_inter_iff, Set.mem_setOf_eq, exists_prop, Set.mem_empty_iff_false, iff_false, not_exists, not_and, not_le] rintro m hm rfl exact lt_of_lt_of_le hm (le_hitting (hτbdd _) _)
Ω : Type u_1 β : Type u_2 ι : Type u_3 m : MeasurableSpace Ω inst✝⁹ : ConditionallyCompleteLinearOrder ι inst✝⁸ : WellFoundedLT ι inst✝⁷ : Countable ι inst✝⁶ : TopologicalSpace ι inst✝⁵ : OrderTopology ι inst✝⁴ : FirstCountableTopology ι inst✝³ : TopologicalSpace β inst✝² : PseudoMetrizableSpace β inst✝¹ : MeasurableSpace β inst✝ : BorelSpace β f : Filtration ι m u : ι → Ω → β τ : Ω → ι hτ : IsStoppingTime f τ N : ι hτbdd : ∀ (x : Ω), τ x ≤ N s : Set β hs : MeasurableSet s hf : Adapted f u n : ι h₁ : {x | hitting u s (τ x) N x ≤ n} = (⋃ i, ⋃ (_ : i ≤ n), {x | τ x = i} ∩ {x | hitting u s i N x ≤ n}) ∪ ⋃ i, ⋃ (_ : i > n), {x | τ x = i} ∩ {x | hitting u s i N x ≤ n} h₂ : ⋃ i, ⋃ (_ : i > n), {x | τ x = i} ∩ {x | hitting u s i N x ≤ n} = ∅ ⊢ MeasurableSet {ω | (fun x => hitting u s (τ x) N x) ω ≤ n}
2ade5d53007f19b3
Orientation.norm_div_tan_oangle_sub_left_of_oangle_eq_pi_div_two
Mathlib/Geometry/Euclidean/Angle/Oriented/RightAngle.lean
theorem norm_div_tan_oangle_sub_left_of_oangle_eq_pi_div_two {x y : V} (h : o.oangle x y = ↑(π / 2)) : ‖y‖ / Real.Angle.tan (o.oangle (x - y) x) = ‖x‖
V : Type u_1 inst✝¹ : NormedAddCommGroup V inst✝ : InnerProductSpace ℝ V hd2 : Fact (finrank ℝ V = 2) o : Orientation ℝ V (Fin 2) x y : V h : o.oangle x y = ↑(π / 2) ⊢ ‖y‖ / (o.oangle (x - y) x).tan = ‖x‖
rw [← neg_inj, oangle_rev, ← oangle_neg_orientation_eq_neg, neg_inj] at h ⊢
V : Type u_1 inst✝¹ : NormedAddCommGroup V inst✝ : InnerProductSpace ℝ V hd2 : Fact (finrank ℝ V = 2) o : Orientation ℝ V (Fin 2) x y : V h : (-o).oangle y x = ↑(π / 2) ⊢ ‖y‖ / ((-o).oangle x (x - y)).tan = ‖x‖
cd182e180412192d
Matrix.circulant_mul
Mathlib/LinearAlgebra/Matrix/Circulant.lean
theorem circulant_mul [Semiring α] [Fintype n] [AddGroup n] (v w : n → α) : circulant v * circulant w = circulant (circulant v *ᵥ w)
case a α : Type u_1 n : Type u_3 inst✝² : Semiring α inst✝¹ : Fintype n inst✝ : AddGroup n v w : n → α i j : n ⊢ ∀ (x : n), v (i - x) * w (x - j) = v (i - j - (Equiv.subRight j) x) * w ((Equiv.subRight j) x)
intro x
case a α : Type u_1 n : Type u_3 inst✝² : Semiring α inst✝¹ : Fintype n inst✝ : AddGroup n v w : n → α i j x : n ⊢ v (i - x) * w (x - j) = v (i - j - (Equiv.subRight j) x) * w ((Equiv.subRight j) x)
9247ee4e7f05243a
AccPt.nhds_inter
Mathlib/Topology/Perfect.lean
theorem AccPt.nhds_inter {x : α} {U : Set α} (h_acc : AccPt x (𝓟 C)) (hU : U ∈ 𝓝 x) : AccPt x (𝓟 (U ∩ C))
α : Type u_1 inst✝ : TopologicalSpace α C : Set α x : α U : Set α h_acc : AccPt x (𝓟 C) hU : U ∈ 𝓝 x ⊢ 𝓝[≠] x ≤ 𝓟 U
rw [le_principal_iff]
α : Type u_1 inst✝ : TopologicalSpace α C : Set α x : α U : Set α h_acc : AccPt x (𝓟 C) hU : U ∈ 𝓝 x ⊢ U ∈ 𝓝[≠] x
e1c3c6891dd944be
Fin.predAbove_left_monotone
Mathlib/Order/Fin/Basic.lean
lemma predAbove_left_monotone (i : Fin (n + 1)) : Monotone fun p ↦ predAbove p i := fun a b H ↦ by dsimp [predAbove] split_ifs with ha hb hb · rfl · exact pred_le _ · have : b < a := castSucc_lt_castSucc_iff.mpr (hb.trans_le (le_of_not_gt ha)) exact absurd H this.not_le · rfl
case pos n : ℕ i : Fin (n + 1) a b : Fin n H : a ≤ b ha : a.castSucc < i hb : b.castSucc < i ⊢ i.pred ⋯ ≤ i.pred ⋯
rfl
no goals
74aeb5d3b481472b
CategoryTheory.DifferentialObject.eqToHom_f
Mathlib/CategoryTheory/DifferentialObject.lean
theorem eqToHom_f {X Y : DifferentialObject S C} (h : X = Y) : Hom.f (eqToHom h) = eqToHom (congr_arg _ h)
S : Type u_1 inst✝³ : AddMonoidWithOne S C : Type u inst✝² : Category.{v, u} C inst✝¹ : HasZeroMorphisms C inst✝ : HasShift C S X : DifferentialObject S C ⊢ (eqToHom ⋯).f = eqToHom ⋯
rw [eqToHom_refl, eqToHom_refl]
S : Type u_1 inst✝³ : AddMonoidWithOne S C : Type u inst✝² : Category.{v, u} C inst✝¹ : HasZeroMorphisms C inst✝ : HasShift C S X : DifferentialObject S C ⊢ (𝟙 X).f = 𝟙 X.obj
ffcc110b6830f2f9
EReal.continuousAt_mul_top_top
Mathlib/Topology/Instances/EReal/Lemmas.lean
private lemma continuousAt_mul_top_top : ContinuousAt (fun p : EReal × EReal ↦ p.1 * p.2) (⊤, ⊤)
case h.refine_2.refine_2.refine_2 x : ℝ ⊢ (⊤, ⊤).2 ∈ Ioi 1
rw [Set.mem_Ioi, ← EReal.coe_one]
case h.refine_2.refine_2.refine_2 x : ℝ ⊢ ↑1 < (⊤, ⊤).2
14ad4956648676bd
Complex.integral_rpow_mul_exp_neg_mul_rpow
Mathlib/MeasureTheory/Integral/Gamma.lean
theorem Complex.integral_rpow_mul_exp_neg_mul_rpow {p q b : ℝ} (hp : 1 ≤ p) (hq : - 2 < q) (hb : 0 < b) : ∫ x : ℂ, ‖x‖ ^ q * rexp (- b * ‖x‖ ^ p) = (2 * π / p) * b ^ (-(q + 2) / p) * Real.Gamma ((q + 2) / p)
p q b : ℝ hp : 1 ≤ p hq : -2 < q hb : 0 < b ⊢ ∫ (x : ℂ), ‖x‖ ^ q * rexp (-b * ‖x‖ ^ p) = 2 * π / p * b ^ (-(q + 2) / p) * Real.Gamma ((q + 2) / p)
calc _ = ∫ x in Ioi (0 : ℝ) ×ˢ Ioo (-π) π, x.1 * (|x.1| ^ q * rexp (- b * |x.1| ^ p)) := by rw [← Complex.integral_comp_polarCoord_symm, polarCoord_target] simp_rw [Complex.norm_polarCoord_symm, smul_eq_mul] _ = (∫ x in Ioi (0 : ℝ), x * |x| ^ q * rexp (- b * |x| ^ p)) * ∫ _ in Ioo (-π) π, 1 := by rw [← setIntegral_prod_mul, volume_eq_prod] simp_rw [mul_one] congr! 2; ring _ = 2 * π * ∫ x in Ioi (0 : ℝ), x * |x| ^ q * rexp (- b * |x| ^ p) := by simp_rw [integral_const, Measure.restrict_apply MeasurableSet.univ, Set.univ_inter, volume_Ioo, sub_neg_eq_add, ← two_mul, ENNReal.toReal_ofReal (by positivity : 0 ≤ 2 * π), smul_eq_mul, mul_one, mul_comm] _ = 2 * π * ∫ x in Ioi (0 : ℝ), x ^ (q + 1) * rexp (-b * x ^ p) := by congr 1 refine setIntegral_congr_fun measurableSet_Ioi (fun x hx => ?_) rw [mem_Ioi] at hx rw [abs_eq_self.mpr hx.le, rpow_add hx, rpow_one] ring _ = (2 * π / p) * b ^ (-(q + 2) / p) * Real.Gamma ((q + 2) / p) := by rw [_root_.integral_rpow_mul_exp_neg_mul_rpow (by linarith) (by linarith) hb, add_assoc, one_add_one_eq_two] ring
no goals
c4a815d7c64d67fa
Equiv.Perm.cycleOf_zpow_apply_self
Mathlib/GroupTheory/Perm/Cycle/Factors.lean
theorem cycleOf_zpow_apply_self (f : Perm α) [DecidableRel f.SameCycle] (x : α) : ∀ n : ℤ, (cycleOf f x ^ n) x = (f ^ n) x
case negSucc α : Type u_2 f : Perm α inst✝ : DecidableRel f.SameCycle x : α z : ℕ ⊢ (f.cycleOf x ^ Int.negSucc z) x = (f ^ Int.negSucc z) x
rw [zpow_negSucc, ← inv_pow, cycleOf_inv, zpow_negSucc, ← inv_pow, cycleOf_pow_apply_self]
no goals
47a5061368da539b
Polynomial.splits_prod_iff
Mathlib/Algebra/Polynomial/Splits.lean
theorem splits_prod_iff {ι : Type u} {s : ι → K[X]} {t : Finset ι} : (∀ j ∈ t, s j ≠ 0) → ((∏ x ∈ t, s x).Splits i ↔ ∀ j ∈ t, (s j).Splits i)
K : Type v L : Type w inst✝¹ : Field K inst✝ : Field L i : K →+* L ι : Type u s : ι → K[X] t : Finset ι ⊢ (∀ j ∈ t, s j ≠ 0) → (Splits i (∏ x ∈ t, s x) ↔ ∀ j ∈ t, Splits i (s j))
refine Finset.induction_on t (fun _ => ⟨fun _ _ h => by simp only [Finset.not_mem_empty] at h, fun _ => splits_one i⟩) fun a t hat ih ht => ?_
K : Type v L : Type w inst✝¹ : Field K inst✝ : Field L i : K →+* L ι : Type u s : ι → K[X] t✝ : Finset ι a : ι t : Finset ι hat : a ∉ t ih : (∀ j ∈ t, s j ≠ 0) → (Splits i (∏ x ∈ t, s x) ↔ ∀ j ∈ t, Splits i (s j)) ht : ∀ j ∈ insert a t, s j ≠ 0 ⊢ Splits i (∏ x ∈ insert a t, s x) ↔ ∀ j ∈ insert a t, Splits i (s j)
72d77f00dc774bee
affineIndependent_iff_indicator_eq_of_affineCombination_eq
Mathlib/LinearAlgebra/AffineSpace/Independent.lean
theorem affineIndependent_iff_indicator_eq_of_affineCombination_eq (p : ι → P) : AffineIndependent k p ↔ ∀ (s1 s2 : Finset ι) (w1 w2 : ι → k), ∑ i ∈ s1, w1 i = 1 → ∑ i ∈ s2, w2 i = 1 → s1.affineCombination k p w1 = s2.affineCombination k p w2 → Set.indicator (↑s1) w1 = Set.indicator (↑s2) w2
case mp k : Type u_1 V : Type u_2 P : Type u_3 inst✝³ : Ring k inst✝² : AddCommGroup V inst✝¹ : Module k V inst✝ : AffineSpace V P ι : Type u_4 p : ι → P ha : AffineIndependent k p s1 s2 : Finset ι w1 w2 : ι → k hw1 : ∑ i ∈ s1, w1 i = 1 hw2 : ∑ i ∈ s2, w2 i = 1 heq : (affineCombination k s1 p) w1 = (affineCombination k s2 p) w2 ⊢ (↑s1).indicator w1 = (↑s2).indicator w2
ext i
case mp.h k : Type u_1 V : Type u_2 P : Type u_3 inst✝³ : Ring k inst✝² : AddCommGroup V inst✝¹ : Module k V inst✝ : AffineSpace V P ι : Type u_4 p : ι → P ha : AffineIndependent k p s1 s2 : Finset ι w1 w2 : ι → k hw1 : ∑ i ∈ s1, w1 i = 1 hw2 : ∑ i ∈ s2, w2 i = 1 heq : (affineCombination k s1 p) w1 = (affineCombination k s2 p) w2 i : ι ⊢ (↑s1).indicator w1 i = (↑s2).indicator w2 i
4f9d6693c0403c52
EMetric.hausdorffEdist_triangle
Mathlib/Topology/MetricSpace/HausdorffDistance.lean
theorem hausdorffEdist_triangle : hausdorffEdist s u ≤ hausdorffEdist s t + hausdorffEdist t u
α : Type u inst✝ : PseudoEMetricSpace α s t u : Set α ⊢ hausdorffEdist s u ≤ hausdorffEdist s t + hausdorffEdist t u
rw [hausdorffEdist_def]
α : Type u inst✝ : PseudoEMetricSpace α s t u : Set α ⊢ (⨆ x ∈ s, infEdist x u) ⊔ ⨆ y ∈ u, infEdist y s ≤ hausdorffEdist s t + hausdorffEdist t u
91d661feb399f899
solvableByRad.induction
Mathlib/FieldTheory/AbelRuffini.lean
theorem induction (P : solvableByRad F E → Prop) (base : ∀ α : F, P (algebraMap F (solvableByRad F E) α)) (add : ∀ α β : solvableByRad F E, P α → P β → P (α + β)) (neg : ∀ α : solvableByRad F E, P α → P (-α)) (mul : ∀ α β : solvableByRad F E, P α → P β → P (α * β)) (inv : ∀ α : solvableByRad F E, P α → P α⁻¹) (rad : ∀ α : solvableByRad F E, ∀ n : ℕ, n ≠ 0 → P (α ^ n) → P α) (α : solvableByRad F E) : P α
F : Type u_1 inst✝² : Field F E : Type u_2 inst✝¹ : Field E inst✝ : Algebra F E P : ↥(solvableByRad F E) → Prop base : ∀ (α : F), P ((algebraMap F ↥(solvableByRad F E)) α) add : ∀ (α β : ↥(solvableByRad F E)), P α → P β → P (α + β) neg : ∀ (α : ↥(solvableByRad F E)), P α → P (-α) mul : ∀ (α β : ↥(solvableByRad F E)), P α → P β → P (α * β) inv : ∀ (α : ↥(solvableByRad F E)), P α → P α⁻¹ rad : ∀ (α : ↥(solvableByRad F E)) (n : ℕ), n ≠ 0 → P (α ^ n) → P α α : E a✝ : IsSolvableByRad F α α₀ : ↥(solvableByRad F E) hα₀ : ↑α₀ = α Pα : P α₀ ⊢ ↑α₀⁻¹ = α⁻¹
rw [← hα₀]
F : Type u_1 inst✝² : Field F E : Type u_2 inst✝¹ : Field E inst✝ : Algebra F E P : ↥(solvableByRad F E) → Prop base : ∀ (α : F), P ((algebraMap F ↥(solvableByRad F E)) α) add : ∀ (α β : ↥(solvableByRad F E)), P α → P β → P (α + β) neg : ∀ (α : ↥(solvableByRad F E)), P α → P (-α) mul : ∀ (α β : ↥(solvableByRad F E)), P α → P β → P (α * β) inv : ∀ (α : ↥(solvableByRad F E)), P α → P α⁻¹ rad : ∀ (α : ↥(solvableByRad F E)) (n : ℕ), n ≠ 0 → P (α ^ n) → P α α : E a✝ : IsSolvableByRad F α α₀ : ↥(solvableByRad F E) hα₀ : ↑α₀ = α Pα : P α₀ ⊢ ↑α₀⁻¹ = (↑α₀)⁻¹
856cf0182c98d000
Orientation.cos_oangle_add_left_mul_norm_of_oangle_eq_pi_div_two
Mathlib/Geometry/Euclidean/Angle/Oriented/RightAngle.lean
theorem cos_oangle_add_left_mul_norm_of_oangle_eq_pi_div_two {x y : V} (h : o.oangle x y = ↑(π / 2)) : Real.Angle.cos (o.oangle (x + y) y) * ‖x + y‖ = ‖y‖
V : Type u_1 inst✝¹ : NormedAddCommGroup V inst✝ : InnerProductSpace ℝ V hd2 : Fact (finrank ℝ V = 2) o : Orientation ℝ V (Fin 2) x y : V h : (-o).oangle y x = ↑(π / 2) ⊢ ((-o).oangle y (x + y)).cos * ‖x + y‖ = ‖y‖
rw [add_comm]
V : Type u_1 inst✝¹ : NormedAddCommGroup V inst✝ : InnerProductSpace ℝ V hd2 : Fact (finrank ℝ V = 2) o : Orientation ℝ V (Fin 2) x y : V h : (-o).oangle y x = ↑(π / 2) ⊢ ((-o).oangle y (y + x)).cos * ‖y + x‖ = ‖y‖
ff44f08a8b90fea3
orbit_fixingSubgroup_compl_subset
Mathlib/GroupTheory/GroupAction/FixingSubgroup.lean
theorem orbit_fixingSubgroup_compl_subset {s : Set α} {a : α} (a_in_s : a ∈ s) : MulAction.orbit (fixingSubgroup M sᶜ) a ⊆ s
M : Type u_1 α : Type u_2 inst✝¹ : Group M inst✝ : MulAction M α s : Set α a : α a_in_s : a ∈ s ⊢ orbit (↥(fixingSubgroup M sᶜ)) a ⊆ s
intro b b_in_orbit
M : Type u_1 α : Type u_2 inst✝¹ : Group M inst✝ : MulAction M α s : Set α a : α a_in_s : a ∈ s b : α b_in_orbit : b ∈ orbit (↥(fixingSubgroup M sᶜ)) a ⊢ b ∈ s
5bc157162cc1d042
Cardinal.ofENat_mul_aleph0
Mathlib/SetTheory/Cardinal/ENat.lean
@[simp] lemma ofENat_mul_aleph0 {m : ℕ∞} (hm : m ≠ 0) : ↑m * ℵ₀ = ℵ₀
case top hm : ⊤ ≠ 0 ⊢ ↑⊤ * ℵ₀ = ℵ₀
exact aleph0_mul_aleph0
no goals
148366b6dd4a869f
Subgroup.conj_smul_le_of_le
Mathlib/Algebra/Group/Subgroup/Pointwise.lean
theorem conj_smul_le_of_le {P H : Subgroup G} (hP : P ≤ H) (h : H) : MulAut.conj (h : G) • P ≤ H
G : Type u_2 inst✝ : Group G P H : Subgroup G hP : P ≤ H h : ↥H ⊢ MulAut.conj ↑h • P ≤ H
rintro - ⟨g, hg, rfl⟩
case intro.intro G : Type u_2 inst✝ : Group G P H : Subgroup G hP : P ≤ H h : ↥H g : G hg : g ∈ ↑P ⊢ ((MulDistribMulAction.toMonoidEnd (MulAut G) G) (MulAut.conj ↑h)) g ∈ H
53dad7a591b125b9
ProbabilityTheory.IsRatCondKernelCDFAux.setIntegral_iInf_rat_gt
Mathlib/Probability/Kernel/Disintegration/CDFToKernel.lean
lemma IsRatCondKernelCDFAux.setIntegral_iInf_rat_gt (hf : IsRatCondKernelCDFAux f κ ν) [IsFiniteKernel κ] [IsFiniteKernel ν] (a : α) (q : ℚ) {A : Set β} (hA : MeasurableSet A) : ∫ t in A, ⨅ r : Ioi q, f (a, t) r ∂(ν a) = (κ a (A ×ˢ Iic (q : ℝ))).toReal
case refine_2.refine_3 α : Type u_1 β : Type u_2 mα : MeasurableSpace α mβ : MeasurableSpace β κ : Kernel α (β × ℝ) ν : Kernel α β f : α × β → ℚ → ℝ hf : IsRatCondKernelCDFAux f κ ν inst✝¹ : IsFiniteKernel κ inst✝ : IsFiniteKernel ν a : α q : ℚ A : Set β hA : MeasurableSet A ⊢ (fun c => f (a, c) q) ≤ᶠ[ae (ν a)] fun t => ⨅ r, f (a, t) ↑r
filter_upwards [hf.mono a] with c h_mono using le_ciInf (fun r ↦ h_mono (le_of_lt r.prop))
no goals
5552b387e425f2b5
AlgebraicGeometry.Scheme.Opens.nonempty_iff
Mathlib/AlgebraicGeometry/Restrict.lean
@[simp] lemma nonempty_iff : Nonempty U.toScheme ↔ (U : Set X).Nonempty
X : Scheme U : X.Opens ⊢ Nonempty ↑↑(↑U).toPresheafedSpace ↔ (↑U).Nonempty
simp only [toScheme_carrier, SetLike.coe_sort_coe, nonempty_subtype]
X : Scheme U : X.Opens ⊢ (∃ x, x ∈ U) ↔ (↑U).Nonempty
e60fa5e3d9b34049
Asymptotics.IsEquivalent.smul
Mathlib/Analysis/Asymptotics/AsymptoticEquivalent.lean
theorem IsEquivalent.smul {α E 𝕜 : Type*} [NormedField 𝕜] [NormedAddCommGroup E] [NormedSpace 𝕜 E] {a b : α → 𝕜} {u v : α → E} {l : Filter α} (hab : a ~[l] b) (huv : u ~[l] v) : (fun x ↦ a x • u x) ~[l] fun x ↦ b x • v x
case intro.intro.intro.intro α : Type u_1 E : Type u_2 𝕜 : Type u_3 inst✝² : NormedField 𝕜 inst✝¹ : NormedAddCommGroup E inst✝ : NormedSpace 𝕜 E a b : α → 𝕜 u v : α → E l : Filter α hab : ∀ ⦃c : ℝ⦄, 0 < c → ∀ᶠ (x : α) in l, ‖(a - b) x‖ ≤ c * ‖b x‖ huv : ∀ ⦃c : ℝ⦄, 0 < c → ∀ᶠ (x : α) in l, ‖(u - v) x‖ ≤ c * ‖v x‖ φ : α → 𝕜 habφ : a =ᶠ[l] φ * b this : ((fun x => a x • u x) - fun x => b x • v x) =ᶠ[l] fun x => b x • (φ x • u x - v x) C : ℝ hC : C > 0 hCuv : ∀ᶠ (x : α) in l, ‖u x‖ ≤ C * ‖v x‖ hφ : ∀ ε > 0, ∀ᶠ (x : α) in l, ‖φ x - 1‖ < ε c : ℝ hc : 0 < c ⊢ ∀ᶠ (x : α) in l, ‖φ x • u x - v x‖ ≤ c * ‖v x‖
specialize hφ (c / 2 / C) (div_pos (div_pos hc zero_lt_two) hC)
case intro.intro.intro.intro α : Type u_1 E : Type u_2 𝕜 : Type u_3 inst✝² : NormedField 𝕜 inst✝¹ : NormedAddCommGroup E inst✝ : NormedSpace 𝕜 E a b : α → 𝕜 u v : α → E l : Filter α hab : ∀ ⦃c : ℝ⦄, 0 < c → ∀ᶠ (x : α) in l, ‖(a - b) x‖ ≤ c * ‖b x‖ huv : ∀ ⦃c : ℝ⦄, 0 < c → ∀ᶠ (x : α) in l, ‖(u - v) x‖ ≤ c * ‖v x‖ φ : α → 𝕜 habφ : a =ᶠ[l] φ * b this : ((fun x => a x • u x) - fun x => b x • v x) =ᶠ[l] fun x => b x • (φ x • u x - v x) C : ℝ hC : C > 0 hCuv : ∀ᶠ (x : α) in l, ‖u x‖ ≤ C * ‖v x‖ c : ℝ hc : 0 < c hφ : ∀ᶠ (x : α) in l, ‖φ x - 1‖ < c / 2 / C ⊢ ∀ᶠ (x : α) in l, ‖φ x • u x - v x‖ ≤ c * ‖v x‖
1fc300a902bb7f39
Nat.pepin_primality
Mathlib/NumberTheory/Fermat.lean
/-- `Fₙ = 2^(2^n)+1` is prime if `3^(2^(2^n-1)) = -1 mod Fₙ` (**Pépin's test**). -/ lemma pepin_primality (n : ℕ) (h : 3 ^ (2 ^ (2 ^ n - 1)) = (-1 : ZMod (fermatNumber n))) : (fermatNumber n).Prime
case ha n : ℕ h : 3 ^ 2 ^ (2 ^ n - 1) = -1 this : Fact (2 < n.fermatNumber) key : 2 ^ n = 2 ^ n - 1 + 1 ⊢ 3 ^ (2 ^ 2 ^ n + 1 - 1) = 1
rw [Nat.add_sub_cancel, key, pow_succ, pow_mul, ← pow_succ, ← key, h, neg_one_sq]
no goals
663d69b05282f8ff
ONote.NFBelow.lt
Mathlib/SetTheory/Ordinal/Notation.lean
theorem NFBelow.lt {e n a b} (h : NFBelow (ONote.oadd e n a) b) : repr e < b
e : ONote n : ℕ+ a : ONote b : Ordinal.{0} h : (e.oadd n a).NFBelow b ⊢ e.repr < b
obtain - | ⟨h₁, h₂, h₃⟩ := h
case oadd' e : ONote n : ℕ+ a : ONote b eb✝ : Ordinal.{0} h₁ : e.NFBelow eb✝ h₂ : a.NFBelow e.repr h₃ : e.repr < b ⊢ e.repr < b
e4c846269cddce61
IsMax.withBot
Mathlib/Order/WithBot.lean
theorem _root_.IsMax.withBot (h : IsMax a) : IsMax (a : WithBot α) := fun x ↦ by cases x <;> simp; simpa using @h _
α : Type u_1 a : α inst✝ : LE α h : IsMax a x : WithBot α ⊢ ↑a ≤ x → x ≤ ↑a
cases x <;> simp
case coe α : Type u_1 a : α inst✝ : LE α h : IsMax a a✝ : α ⊢ a ≤ a✝ → a✝ ≤ a
dae9b9feff5d1505
NonUnitalSubsemiring.unitization_range
Mathlib/Algebra/Algebra/Subalgebra/Unitization.lean
theorem unitization_range : (unitization s).range = subalgebraOfSubsemiring (.closure s)
R : Type u_1 S : Type u_2 inst✝¹ : Semiring R inst✝ : SetLike S R hSR : NonUnitalSubsemiringClass S R s : S ⊢ (unitization s).range = subalgebraOfSubsemiring (Subsemiring.closure ↑s)
have := AddSubmonoidClass.nsmulMemClass (S := S)
R : Type u_1 S : Type u_2 inst✝¹ : Semiring R inst✝ : SetLike S R hSR : NonUnitalSubsemiringClass S R s : S this : SMulMemClass S ℕ R ⊢ (unitization s).range = subalgebraOfSubsemiring (Subsemiring.closure ↑s)
bef695ba967db83c
Polynomial.exists_root_of_degree_eq_one
Mathlib/Algebra/Polynomial/FieldDivision.lean
theorem exists_root_of_degree_eq_one (h : degree p = 1) : ∃ x, IsRoot p x := ⟨-((p.coeff 1)⁻¹ * p.coeff 0), by rw [← mem_roots (by simp [← zero_le_degree_iff, h])] simp [roots_degree_eq_one h]⟩
R : Type u inst✝ : Field R p : R[X] h : p.degree = 1 ⊢ -((p.coeff 1)⁻¹ * p.coeff 0) ∈ p.roots
simp [roots_degree_eq_one h]
no goals
48d63a9d139e135c
Relation.reflGen_eq_self
Mathlib/Logic/Relation.lean
lemma reflGen_eq_self (hr : Reflexive r) : ReflGen r = r
α : Type u_1 r : α → α → Prop hr : Reflexive r ⊢ ReflGen r = r
ext x y
case h.h.a α : Type u_1 r : α → α → Prop hr : Reflexive r x y : α ⊢ ReflGen r x y ↔ r x y
1d961a1ffd12f4cb
Real.cosh_add
Mathlib/Data/Complex/Trigonometric.lean
theorem cosh_add : cosh (x + y) = cosh x * cosh y + sinh x * sinh y
x y : ℝ ⊢ cosh (x + y) = cosh x * cosh y + sinh x * sinh y
rw [← ofReal_inj]
x y : ℝ ⊢ ↑(cosh (x + y)) = ↑(cosh x * cosh y + sinh x * sinh y)
3284e2e8c4a39b73
Equiv.Perm.ofSubtype_swap_eq
Mathlib/GroupTheory/Perm/Support.lean
theorem ofSubtype_swap_eq {p : α → Prop} [DecidablePred p] (x y : Subtype p) : ofSubtype (Equiv.swap x y) = Equiv.swap ↑x ↑y := Equiv.ext fun z => by by_cases hz : p z · rw [swap_apply_def, ofSubtype_apply_of_mem _ hz] split_ifs with hzx hzy · simp_rw [hzx, Subtype.coe_eta, swap_apply_left] · simp_rw [hzy, Subtype.coe_eta, swap_apply_right] · rw [swap_apply_of_ne_of_ne] <;> simp [Subtype.ext_iff, *] · rw [ofSubtype_apply_of_not_mem _ hz, swap_apply_of_ne_of_ne] · intro h apply hz rw [h] exact Subtype.prop x intro h apply hz rw [h] exact Subtype.prop y
case neg.a α : Type u_1 inst✝¹ : DecidableEq α p : α → Prop inst✝ : DecidablePred p x y : Subtype p z : α hz : ¬p z h : z = ↑x ⊢ p ↑x
exact Subtype.prop x
no goals
7c967a4cc58d1491
Lean.Order.csup_conj
Mathlib/.lake/packages/lean4/src/lean/Init/Internal/Order/Basic.lean
theorem csup_conj (c P : α → Prop) (hchain : chain c) (h : ∀ x, c x → ∃ y, c y ∧ x ⊑ y ∧ P y) : csup c = csup (fun x => c x ∧ P x)
case a.intro.intro.intro α : Sort u inst✝ : CCPO α c P : α → Prop hchain : chain c h : ∀ (x : α), c x → ∃ y, c y ∧ x ⊑ y ∧ P y x : α hcx : c x y : α hcy : c y hxy : x ⊑ y hPy : P y ⊢ y ⊑ csup fun x => c x ∧ P x
clear x hcx hxy
case a.intro.intro.intro α : Sort u inst✝ : CCPO α c P : α → Prop hchain : chain c h : ∀ (x : α), c x → ∃ y, c y ∧ x ⊑ y ∧ P y y : α hcy : c y hPy : P y ⊢ y ⊑ csup fun x => c x ∧ P x
3024f009497d9407
Prod.comul_comp_inl
Mathlib/RingTheory/Coalgebra/Basic.lean
theorem comul_comp_inl : comul ∘ₗ inl R A B = TensorProduct.map (.inl R A B) (.inl R A B) ∘ₗ comul
R : Type u A : Type v B : Type w inst✝⁶ : CommSemiring R inst✝⁵ : AddCommMonoid A inst✝⁴ : AddCommMonoid B inst✝³ : Module R A inst✝² : Module R B inst✝¹ : Coalgebra R A inst✝ : Coalgebra R B ⊢ comul ∘ₗ inl R A B = TensorProduct.map (inl R A B) (inl R A B) ∘ₗ comul
ext
case h R : Type u A : Type v B : Type w inst✝⁶ : CommSemiring R inst✝⁵ : AddCommMonoid A inst✝⁴ : AddCommMonoid B inst✝³ : Module R A inst✝² : Module R B inst✝¹ : Coalgebra R A inst✝ : Coalgebra R B x✝ : A ⊢ (comul ∘ₗ inl R A B) x✝ = (TensorProduct.map (inl R A B) (inl R A B) ∘ₗ comul) x✝
0d8c212aec19a778
convexJoin_singleton_left
Mathlib/Analysis/Convex/Join.lean
theorem convexJoin_singleton_left (t : Set E) (x : E) : convexJoin 𝕜 {x} t = ⋃ y ∈ t, segment 𝕜 x y
𝕜 : Type u_2 E : Type u_3 inst✝² : OrderedSemiring 𝕜 inst✝¹ : AddCommMonoid E inst✝ : Module 𝕜 E t : Set E x : E ⊢ convexJoin 𝕜 {x} t = ⋃ y ∈ t, segment 𝕜 x y
simp [convexJoin]
no goals
772f52dc249e0189
Finset.sum_mul_self_eq_zero_iff
Mathlib/Algebra/Order/BigOperators/Ring/Finset.lean
theorem sum_mul_self_eq_zero_iff [LinearOrderedSemiring R] [ExistsAddOfLE R] (s : Finset ι) (f : ι → R) : ∑ i ∈ s, f i * f i = 0 ↔ ∀ i ∈ s, f i = 0
ι : Type u_1 R : Type u_2 inst✝¹ : LinearOrderedSemiring R inst✝ : ExistsAddOfLE R s : Finset ι f : ι → R ⊢ (∀ i ∈ s, f i * f i = 0) ↔ ∀ i ∈ s, f i = 0
simp
no goals
0e4c80553bdf342d
GromovHausdorff.ghDist_le_nonemptyCompacts_dist
Mathlib/Topology/MetricSpace/GromovHausdorff.lean
theorem ghDist_le_nonemptyCompacts_dist (p q : NonemptyCompacts X) : dist p.toGHSpace q.toGHSpace ≤ dist p q
X : Type u inst✝ : MetricSpace X p q : NonemptyCompacts X ha : Isometry Subtype.val hb : Isometry Subtype.val A : dist p q = hausdorffDist ↑p ↑q I : ↑p = range Subtype.val J : ↑q = range Subtype.val ⊢ dist p.toGHSpace q.toGHSpace ≤ dist p q
rw [A, I, J]
X : Type u inst✝ : MetricSpace X p q : NonemptyCompacts X ha : Isometry Subtype.val hb : Isometry Subtype.val A : dist p q = hausdorffDist ↑p ↑q I : ↑p = range Subtype.val J : ↑q = range Subtype.val ⊢ dist p.toGHSpace q.toGHSpace ≤ hausdorffDist (range Subtype.val) (range Subtype.val)
08300c0b3db15994
CategoryTheory.Abelian.Ext.mk₀_zero
Mathlib/Algebra/Homology/DerivedCategory/Ext/Basic.lean
@[simp] lemma mk₀_zero : mk₀ (0 : X ⟶ Y) = 0
C : Type u inst✝² : Category.{v, u} C inst✝¹ : Abelian C inst✝ : HasExt C X Y : C this : HasDerivedCategory C := HasDerivedCategory.standard C ⊢ mk₀ 0 = 0
ext
case h C : Type u inst✝² : Category.{v, u} C inst✝¹ : Abelian C inst✝ : HasExt C X Y : C this : HasDerivedCategory C := HasDerivedCategory.standard C ⊢ (mk₀ 0).hom = hom 0
76b7e767784f943a
Class.sUnion_apply
Mathlib/SetTheory/ZFC/Basic.lean
theorem sUnion_apply {x : Class} {y : ZFSet} : (⋃₀ x) y ↔ ∃ z : ZFSet, x z ∧ y ∈ z
x : Class.{u_1} y : ZFSet.{u_1} ⊢ (⋃₀ x) y ↔ ∃ z, x z ∧ y ∈ z
constructor
case mp x : Class.{u_1} y : ZFSet.{u_1} ⊢ (⋃₀ x) y → ∃ z, x z ∧ y ∈ z case mpr x : Class.{u_1} y : ZFSet.{u_1} ⊢ (∃ z, x z ∧ y ∈ z) → (⋃₀ x) y
de10961c81e49695
coeSubmodule_differentIdeal
Mathlib/RingTheory/DedekindDomain/Different.lean
lemma coeSubmodule_differentIdeal [NoZeroSMulDivisors A B] : coeSubmodule L (differentIdeal A B) = 1 / Submodule.traceDual A K 1
A : Type u_1 K : Type u_2 L : Type u B : Type u_3 inst✝¹⁹ : CommRing A inst✝¹⁸ : Field K inst✝¹⁷ : CommRing B inst✝¹⁶ : Field L inst✝¹⁵ : Algebra A K inst✝¹⁴ : Algebra B L inst✝¹³ : Algebra A B inst✝¹² : Algebra K L inst✝¹¹ : Algebra A L inst✝¹⁰ : IsScalarTower A K L inst✝⁹ : IsScalarTower A B L inst✝⁸ : IsDomain A inst✝⁷ : IsFractionRing A K inst✝⁶ : FiniteDimensional K L inst✝⁵ : Algebra.IsSeparable K L inst✝⁴ : IsIntegralClosure B A L inst✝³ : IsIntegrallyClosed A inst✝² : IsDedekindDomain B inst✝¹ : IsFractionRing B L inst✝ : NoZeroSMulDivisors A B this : ↑(FractionRing.algEquiv B L).toLinearEquiv ∘ₗ Algebra.linearMap B (FractionRing B) = Algebra.linearMap B L ⊢ (algebraMap (FractionRing A) (FractionRing B)).comp ↑(FractionRing.algEquiv A K).symm.toRingEquiv = (↑(FractionRing.algEquiv B L).symm.toRingEquiv).comp (algebraMap K L)
apply IsLocalization.ringHom_ext A⁰
case h A : Type u_1 K : Type u_2 L : Type u B : Type u_3 inst✝¹⁹ : CommRing A inst✝¹⁸ : Field K inst✝¹⁷ : CommRing B inst✝¹⁶ : Field L inst✝¹⁵ : Algebra A K inst✝¹⁴ : Algebra B L inst✝¹³ : Algebra A B inst✝¹² : Algebra K L inst✝¹¹ : Algebra A L inst✝¹⁰ : IsScalarTower A K L inst✝⁹ : IsScalarTower A B L inst✝⁸ : IsDomain A inst✝⁷ : IsFractionRing A K inst✝⁶ : FiniteDimensional K L inst✝⁵ : Algebra.IsSeparable K L inst✝⁴ : IsIntegralClosure B A L inst✝³ : IsIntegrallyClosed A inst✝² : IsDedekindDomain B inst✝¹ : IsFractionRing B L inst✝ : NoZeroSMulDivisors A B this : ↑(FractionRing.algEquiv B L).toLinearEquiv ∘ₗ Algebra.linearMap B (FractionRing B) = Algebra.linearMap B L ⊢ ((algebraMap (FractionRing A) (FractionRing B)).comp ↑(FractionRing.algEquiv A K).symm.toRingEquiv).comp (algebraMap A K) = ((↑(FractionRing.algEquiv B L).symm.toRingEquiv).comp (algebraMap K L)).comp (algebraMap A K)
de2215dd565ee658
cfcₙ_integral
Mathlib/Analysis/CStarAlgebra/ContinuousFunctionalCalculus/Integral.lean
/-- The non-unital continuous functional calculus commutes with integration. -/ lemma cfcₙ_integral [TopologicalSpace X] [OpensMeasurableSpace X] (f : X → 𝕜 → 𝕜) (bound : X → ℝ) (a : A) [SecondCountableTopologyEither X C(quasispectrum 𝕜 a, 𝕜)₀] (hf₁ : ∀ x, ContinuousOn (f x) (quasispectrum 𝕜 a)) (hf₂ : ∀ x, f x 0 = 0) (hf₃ : Continuous (fun x ↦ (⟨⟨_, hf₁ x |>.restrict⟩, hf₂ x⟩ : C(quasispectrum 𝕜 a, 𝕜)₀))) (hbound : ∀ x, ∀ z ∈ quasispectrum 𝕜 a, ‖f x z‖ ≤ ‖bound x‖) (hbound_finite_integral : HasFiniteIntegral bound μ) (ha : p a
X : Type u_1 𝕜 : Type u_2 A : Type u_3 p : A → Prop inst✝¹² : RCLike 𝕜 inst✝¹¹ : MeasurableSpace X μ : Measure X inst✝¹⁰ : NonUnitalNormedRing A inst✝⁹ : StarRing A inst✝⁸ : CompleteSpace A inst✝⁷ : NormedSpace 𝕜 A inst✝⁶ : NormedSpace ℝ A inst✝⁵ : IsScalarTower 𝕜 A A inst✝⁴ : SMulCommClass 𝕜 A A inst✝³ : NonUnitalContinuousFunctionalCalculus 𝕜 p inst✝² : TopologicalSpace X inst✝¹ : OpensMeasurableSpace X f : X → 𝕜 → 𝕜 bound : X → ℝ a : A inst✝ : SecondCountableTopologyEither X C(↑(quasispectrum 𝕜 a), 𝕜)₀ hf₁ : ∀ (x : X), ContinuousOn (f x) (quasispectrum 𝕜 a) hf₂ : ∀ (x : X), f x 0 = 0 hf₃ : Continuous fun x => { toFun := (quasispectrum 𝕜 a).restrict (f x), continuous_toFun := ⋯, map_zero' := ⋯ } hbound : ∀ (x : X), ∀ z ∈ quasispectrum 𝕜 a, ‖f x z‖ ≤ ‖bound x‖ hbound_finite_integral : HasFiniteIntegral bound μ ha : autoParam (p a) _auto✝ fc : X → C(↑(quasispectrum 𝕜 a), 𝕜)₀ := fun x => { toFun := (quasispectrum 𝕜 a).restrict (f x), continuous_toFun := ⋯, map_zero' := ⋯ } x : X ⊢ ‖↑(fc x)‖ ≤ ‖bound x‖
rw [ContinuousMap.norm_le _ (norm_nonneg (bound x))]
X : Type u_1 𝕜 : Type u_2 A : Type u_3 p : A → Prop inst✝¹² : RCLike 𝕜 inst✝¹¹ : MeasurableSpace X μ : Measure X inst✝¹⁰ : NonUnitalNormedRing A inst✝⁹ : StarRing A inst✝⁸ : CompleteSpace A inst✝⁷ : NormedSpace 𝕜 A inst✝⁶ : NormedSpace ℝ A inst✝⁵ : IsScalarTower 𝕜 A A inst✝⁴ : SMulCommClass 𝕜 A A inst✝³ : NonUnitalContinuousFunctionalCalculus 𝕜 p inst✝² : TopologicalSpace X inst✝¹ : OpensMeasurableSpace X f : X → 𝕜 → 𝕜 bound : X → ℝ a : A inst✝ : SecondCountableTopologyEither X C(↑(quasispectrum 𝕜 a), 𝕜)₀ hf₁ : ∀ (x : X), ContinuousOn (f x) (quasispectrum 𝕜 a) hf₂ : ∀ (x : X), f x 0 = 0 hf₃ : Continuous fun x => { toFun := (quasispectrum 𝕜 a).restrict (f x), continuous_toFun := ⋯, map_zero' := ⋯ } hbound : ∀ (x : X), ∀ z ∈ quasispectrum 𝕜 a, ‖f x z‖ ≤ ‖bound x‖ hbound_finite_integral : HasFiniteIntegral bound μ ha : autoParam (p a) _auto✝ fc : X → C(↑(quasispectrum 𝕜 a), 𝕜)₀ := fun x => { toFun := (quasispectrum 𝕜 a).restrict (f x), continuous_toFun := ⋯, map_zero' := ⋯ } x : X ⊢ ∀ (x_1 : ↑(quasispectrum 𝕜 a)), ‖↑(fc x) x_1‖ ≤ ‖bound x‖
c8ceb0f73ee7838a
MvPowerSeries.order_monomial
Mathlib/RingTheory/MvPowerSeries/Order.lean
theorem order_monomial {d : σ →₀ ℕ} {a : R} [Decidable (a = 0)] : order (monomial R d a) = if a = 0 then (⊤ : ℕ∞) else ↑(degree d)
σ : Type u_1 R : Type u_2 inst✝¹ : Semiring R d : σ →₀ ℕ a : R inst✝ : Decidable (a = 0) ⊢ ((monomial R d) a).order = if a = 0 then ⊤ else ↑((weight fun x => 1) d)
exact weightedOrder_monomial _
no goals
e18d3565ea1400f2
String.join_eq
Mathlib/.lake/packages/batteries/Batteries/Data/String/Lemmas.lean
theorem join_eq (ss : List String) : join ss = ⟨(ss.map data).flatten⟩ := go ss [] where go : ∀ (ss : List String) cs, ss.foldl (· ++ ·) (mk cs) = ⟨cs ++ (ss.map data).flatten⟩ | [], _ => by simp | ⟨s⟩::ss, _ => (go ss _).trans (by simp)
ss✝ : List String s : List Char ss : List String x✝ : List Char ⊢ { data := x✝ ++ s ++ (List.map data ss).flatten } = { data := x✝ ++ (List.map data ({ data := s } :: ss)).flatten }
simp
no goals
2cc551e94da7df0b
LieIdeal.map_bracket_le
Mathlib/Algebra/Lie/IdealOperations.lean
theorem map_bracket_le {I₁ I₂ : LieIdeal R L} : map f ⁅I₁, I₂⁆ ≤ ⁅map f I₁, map f I₂⁆
case intro.mk.intro.mk R : Type u L : Type v L' : Type w₂ inst✝⁴ : CommRing R inst✝³ : LieRing L inst✝² : LieAlgebra R L inst✝¹ : LieRing L' inst✝ : LieAlgebra R L' f : L →ₗ⁅R⁆ L' I₁ I₂ : LieIdeal R L x y₁ : L hy₁ : y₁ ∈ I₁ y₂ : L hy₂ : y₂ ∈ I₂ hx : ⁅↑⟨y₁, hy₁⟩, ↑⟨y₂, hy₂⟩⁆ = x fy₁ : ↥(map f I₁) := ⟨f y₁, ⋯⟩ ⊢ ⁅↑⟨y₁, hy₁⟩, ↑⟨y₂, hy₂⟩⁆ ∈ ↑(comap f ⁅map f I₁, map f I₂⁆)
let fy₂ : ↥(map f I₂) := ⟨f y₂, mem_map hy₂⟩
case intro.mk.intro.mk R : Type u L : Type v L' : Type w₂ inst✝⁴ : CommRing R inst✝³ : LieRing L inst✝² : LieAlgebra R L inst✝¹ : LieRing L' inst✝ : LieAlgebra R L' f : L →ₗ⁅R⁆ L' I₁ I₂ : LieIdeal R L x y₁ : L hy₁ : y₁ ∈ I₁ y₂ : L hy₂ : y₂ ∈ I₂ hx : ⁅↑⟨y₁, hy₁⟩, ↑⟨y₂, hy₂⟩⁆ = x fy₁ : ↥(map f I₁) := ⟨f y₁, ⋯⟩ fy₂ : ↥(map f I₂) := ⟨f y₂, ⋯⟩ ⊢ ⁅↑⟨y₁, hy₁⟩, ↑⟨y₂, hy₂⟩⁆ ∈ ↑(comap f ⁅map f I₁, map f I₂⁆)
f4b2fffd77926150
Rat.AbsoluteValue.is_prime_of_minimal_nat_zero_lt_and_lt_one
Mathlib/NumberTheory/Ostrowski.lean
/-- The minimal positive integer with absolute value smaller than 1 is a prime number. -/ lemma is_prime_of_minimal_nat_zero_lt_and_lt_one : p.Prime
f : AbsoluteValue ℚ ℝ a b : ℕ hp0 : 0 < f ↑(a * b) hp1 : f ↑(a * b) < 1 hmin : ∀ (m : ℕ), 0 < f ↑m ∧ f ↑m < 1 → a * b ≤ m ha₁ : a ≠ 1 hb₁ : b ≠ 1 ha₀ : a ≠ 0 hb₀ : b ≠ 0 hap : a < a * b ⊢ 1 < a
omega
no goals
462fd42846234179
Std.Tactic.BVDecide.LRAT.Internal.DefaultFormula.confirmRupHint_preserves_invariant_helper
Mathlib/.lake/packages/lean4/src/lean/Std/Tactic/BVDecide/LRAT/Internal/Formula/RupAddResult.lean
theorem confirmRupHint_preserves_invariant_helper {n : Nat} (f : DefaultFormula n) (f_assignments_size : f.assignments.size = n) (acc : Array Assignment × CNF.Clause (PosFin n) × Bool × Bool) (hsize : acc.1.size = n) (l : Literal (PosFin n)) (ih : DerivedLitsInvariant f f_assignments_size acc.1 hsize acc.2.1) (h : ¬hasAssignment l.snd acc.fst[l.fst.val]! = true) : have hsize' : (Array.modify acc.1 l.1.1 (addAssignment l.snd)).size = n
case left n : Nat f : DefaultFormula n f_assignments_size : f.assignments.size = n acc : Array Assignment × CNF.Clause (PosFin n) × Bool × Bool hsize : acc.fst.size = n l : Literal (PosFin n) ih : f.DerivedLitsInvariant f_assignments_size acc.fst hsize acc.snd.fst h : ¬hasAssignment l.snd acc.fst[l.fst.val]! = true hsize'✝ : (acc.fst.modify l.fst.val (addAssignment l.snd)).size = n := Eq.mpr (id (congrArg (fun _a => _a = n) (Array.size_modify acc.fst l.fst.val (addAssignment l.snd)))) hsize i : Fin n i_in_bounds : ↑i < acc.fst.size l_in_bounds : l.fst.val < acc.fst.size h1 : acc.fst[↑i] = f.assignments[↑i] h2 : ∀ (l : Literal (PosFin n)), l ∈ acc.snd.fst → l.fst.val ≠ ↑i l_eq_i : l.fst.val = ↑i zero_lt_length_list : 0 < (l :: acc.snd.fst).length ⊢ ((l :: acc.snd.fst).get ⟨0, zero_lt_length_list⟩).fst.val = ↑i
simp only [List.get, l_eq_i]
no goals
02ca1706b397b254
fourierIntegral_gaussian_pi'
Mathlib/Analysis/SpecialFunctions/Gaussian/FourierTransform.lean
theorem _root_.fourierIntegral_gaussian_pi' (hb : 0 < b.re) (c : ℂ) : (𝓕 fun x : ℝ => cexp (-π * b * x ^ 2 + 2 * π * c * x)) = fun t : ℝ => 1 / b ^ (1 / 2 : ℂ) * cexp (-π / b * (t + I * c) ^ 2)
b : ℂ hb : 0 < b.re c : ℂ this : b ≠ 0 ⊢ (-↑π * b).re < 0
simpa only [neg_mul, neg_re, re_ofReal_mul, neg_lt_zero] using mul_pos pi_pos hb
no goals
b9a2243045a942ca
SimpleGraph.isIndepSet_induce
Mathlib/Combinatorics/SimpleGraph/Clique.lean
theorem isIndepSet_induce {F : Set α} {s : Set F} : ((⊤ : Subgraph G).induce F).coe.IsIndepSet s ↔ G.IsIndepSet (Subtype.val '' s)
α : Type u_1 G : SimpleGraph α F : Set α s : Set ↑F ⊢ (⊤.induce F).coe.IsIndepSet s ↔ G.IsIndepSet (Subtype.val '' s)
simp [Set.Pairwise]
no goals
058c7cd9290187ac
HasFPowerSeriesOnBall.isBigO_image_sub_image_sub_deriv_principal
Mathlib/Analysis/Analytic/Basic.lean
theorem HasFPowerSeriesOnBall.isBigO_image_sub_image_sub_deriv_principal (hf : HasFPowerSeriesOnBall f p x r) (hr : r' < r) : (fun y : E × E => f y.1 - f y.2 - p 1 fun _ => y.1 - y.2) =O[𝓟 (EMetric.ball (x, x) r')] fun y => ‖y - (x, x)‖ * ‖y.1 - y.2‖
𝕜 : Type u_1 E : Type u_2 F : Type u_3 inst✝⁴ : NontriviallyNormedField 𝕜 inst✝³ : NormedAddCommGroup E inst✝² : NormedSpace 𝕜 E inst✝¹ : NormedAddCommGroup F inst✝ : NormedSpace 𝕜 F f : E → F p : FormalMultilinearSeries 𝕜 E F x : E r r' : ℝ≥0∞ hf : HasFPowerSeriesWithinOnBall f p univ x r hr : r' < r ⊢ (fun y => f y.1 - f y.2 - (p 1) fun x => y.1 - y.2) =O[𝓟 (EMetric.ball (x, x) r')] fun y => ‖y - (x, x)‖ * ‖y.1 - y.2‖
simpa using hf.isBigO_image_sub_image_sub_deriv_principal hr
no goals
cc6a0632f4d3aa1e
Multiset.isDershowitzMannaLT_singleton_insert
Mathlib/Data/Multiset/DershowitzManna.lean
private lemma isDershowitzMannaLT_singleton_insert (h : OneStep N (a ::ₘ M)) : ∃ M', N = a ::ₘ M' ∧ OneStep M' M ∨ N = M + M' ∧ ∀ x ∈ M', x < a
case intro.intro.intro.intro.intro.inl α : Type u_1 inst✝ : Preorder α M : Multiset α a : α X Y : Multiset α h0 : a ::ₘ M = X + {a} h2 : ∀ y ∈ Y, y < a ⊢ X + Y = M + Y
simpa [add_comm _ {a}, singleton_add, eq_comm] using h0
no goals
fe1657f5397146bc
Nat.nth_of_forall_not
Mathlib/Data/Nat/Nth.lean
theorem nth_of_forall_not {n : ℕ} (hp : ∀ n' ≥ n, ¬p n') : nth p n = 0
p : ℕ → Prop n : ℕ hp : ∀ n' ≥ n, ¬p n' this : setOf p ⊆ ↑(range n) ⊢ ⋯.toFinset ⊆ range n
exact Set.Finite.toFinset_subset.mpr this
no goals
6bf1c9d4ae0922f6
SeminormFamily.filter_eq_iInf
Mathlib/Analysis/LocallyConvex/WithSeminorms.lean
theorem filter_eq_iInf (p : SeminormFamily 𝕜 E ι) : p.moduleFilterBasis.toFilterBasis.filter = ⨅ i, (𝓝 0).comap (p i)
case refine_1.refine_1 𝕜 : Type u_1 E : Type u_5 ι : Type u_8 inst✝³ : NormedField 𝕜 inst✝² : AddCommGroup E inst✝¹ : Module 𝕜 E inst✝ : Nonempty ι p : SeminormFamily 𝕜 E ι i : ι ε : ℝ hε : 0 < ε ⊢ ({i}.sup p).ball 0 ε ∈ AddGroupFilterBasis.toFilterBasis
exact p.basisSets_mem {i} hε
no goals
043221e62cb70beb
ZMod.ker_intCastRingHom
Mathlib/RingTheory/ZMod.lean
theorem ZMod.ker_intCastRingHom (n : ℕ) : RingHom.ker (Int.castRingHom (ZMod n)) = Ideal.span ({(n : ℤ)} : Set ℤ)
n : ℕ ⊢ RingHom.ker (Int.castRingHom (ZMod n)) = Ideal.span {↑n}
ext
case h n : ℕ x✝ : ℤ ⊢ x✝ ∈ RingHom.ker (Int.castRingHom (ZMod n)) ↔ x✝ ∈ Ideal.span {↑n}
b698aed1a1a94ada
List.mapIdx_singleton
Mathlib/.lake/packages/lean4/src/lean/Init/Data/List/MapIdx.lean
theorem mapIdx_singleton {a : α} : mapIdx f [a] = [f 0 a]
α : Type u_1 α✝ : Type u_2 f : Nat → α → α✝ a : α ⊢ mapIdx f [a] = [f 0 a]
simp
no goals
c34353a5e52a0924
ExteriorAlgebra.ιMulti_span
Mathlib/LinearAlgebra/ExteriorAlgebra/Grading.lean
/-- The union of the images of the maps `ExteriorAlgebra.ιMulti R n` for `n` running through all natural numbers spans the exterior algebra. -/ lemma ιMulti_span : Submodule.span R (Set.range fun x : Σ n, (Fin n → M) => ιMulti R x.1 x.2) = ⊤
case h_homogeneous R : Type u_1 M : Type u_2 inst✝² : CommRing R inst✝¹ : AddCommGroup M inst✝ : Module R M i✝ : ℕ hm✝ : ↥(⋀[R]^i✝ M) m : ExteriorAlgebra R M hm : m ∈ ⋀[R]^i✝ M ⊢ ↑⟨m, hm⟩ ∈ Submodule.span R (Set.range fun x => (ιMulti R x.fst) x.snd)
apply Set.mem_of_mem_of_subset hm
case h_homogeneous R : Type u_1 M : Type u_2 inst✝² : CommRing R inst✝¹ : AddCommGroup M inst✝ : Module R M i✝ : ℕ hm✝ : ↥(⋀[R]^i✝ M) m : ExteriorAlgebra R M hm : m ∈ ⋀[R]^i✝ M ⊢ ↑(⋀[R]^i✝ M) ⊆ ↑(Submodule.span R (Set.range fun x => (ιMulti R x.fst) x.snd))
6122bc0f0c7cb07d
Multiset.rel_refl_of_refl_on
Mathlib/Data/Multiset/ZeroCons.lean
theorem rel_refl_of_refl_on {m : Multiset α} {r : α → α → Prop} : (∀ x ∈ m, r x x) → Rel r m m
α : Type u_1 m : Multiset α r : α → α → Prop ⊢ (∀ (x : α), x ∈ m → r x x) → Rel r m m
refine m.induction_on ?_ ?_
case refine_1 α : Type u_1 m : Multiset α r : α → α → Prop ⊢ (∀ (x : α), x ∈ 0 → r x x) → Rel r 0 0 case refine_2 α : Type u_1 m : Multiset α r : α → α → Prop ⊢ ∀ (a : α) (s : Multiset α), ((∀ (x : α), x ∈ s → r x x) → Rel r s s) → (∀ (x : α), x ∈ a ::ₘ s → r x x) → Rel r (a ::ₘ s) (a ::ₘ s)
ab00a6fe45ebb271
Order.krullDim_le_one_iff
Mathlib/Order/KrullDimension.lean
lemma krullDim_le_one_iff : krullDim α ≤ 1 ↔ ∀ x : α, IsMin x ∨ IsMax x
case mpr.intro.intro.intro.intro α : Type u_1 inst✝ : Preorder α x y : α hxy : y < x z : α hzx : x < z ⊢ ∃ i, 1 < ↑i.length
exact ⟨⟨2, ![y, x, z], fun i ↦ by fin_cases i <;> simpa⟩, by simp⟩
no goals
191756a8f12b45b2
BitVec.getMsbD_setWidth'
Mathlib/.lake/packages/lean4/src/lean/Init/Data/BitVec/Lemmas.lean
theorem getMsbD_setWidth' (ge : m ≥ n) (x : BitVec n) (i : Nat) : getMsbD (setWidth' ge x) i = (decide (m - n ≤ i) && getMsbD x (i + n - m))
case neg m n : Nat ge : m ≥ n x : BitVec n i : Nat h₁ : ¬decide (i < m) = true h₂ : ¬decide (m - n ≤ i) = true h₃ : ¬decide (i + n - m < n) = true h₄ : ¬n - 1 - (i + n - m) = m - 1 - i ⊢ (decide (i < m) && x.getLsbD (m - 1 - i)) = (decide (m - n ≤ i) && (decide (i + n - m < n) && x.getLsbD (n - 1 - (i + n - m))))
simp only [h₁, h₂, h₃, h₄]
case neg m n : Nat ge : m ≥ n x : BitVec n i : Nat h₁ : ¬decide (i < m) = true h₂ : ¬decide (m - n ≤ i) = true h₃ : ¬decide (i + n - m < n) = true h₄ : ¬n - 1 - (i + n - m) = m - 1 - i ⊢ (false && x.getLsbD (m - 1 - i)) = (false && (false && x.getLsbD (n - 1 - (i + n - m))))
03a8635c3d52111b
UniformSpace.metrizable_uniformity
Mathlib/Topology/Metrizable/Uniformity.lean
theorem UniformSpace.metrizable_uniformity (X : Type*) [UniformSpace X] [IsCountablyGenerated (𝓤 X)] : ∃ I : PseudoMetricSpace X, I.toUniformSpace = ‹_›
X : Type u_2 inst✝¹ : UniformSpace X inst✝ : (𝓤 X).IsCountablyGenerated U : ℕ → Set (X × X) hU_symm : ∀ (n : ℕ), SymmetricRel (U n) hU_comp : ∀ ⦃m n : ℕ⦄, m < n → U n ○ (U n ○ U n) ⊆ U m hB : (𝓤 X).HasAntitoneBasis U d : X → X → ℝ≥0 := fun x y => if h : ∃ n, (x, y) ∉ U n then (1 / 2) ^ Nat.find h else 0 hd₀ : ∀ {x y : X}, d x y = 0 ↔ Inseparable x y hd_symm : ∀ (x y : X), d x y = d y x hr : 1 / 2 ∈ Ioo 0 1 I : PseudoMetricSpace X := PseudoMetricSpace.ofPreNNDist d ⋯ hd_symm hdist_le : ∀ (x y : X), dist x y ≤ ↑(d x y) hle_d : ∀ {x y : X} {n : ℕ}, (1 / 2) ^ n ≤ d x y ↔ (x, y) ∉ U n ⊢ ∀ (x y : X), ↑(d x y) ≤ 2 * dist x y
refine PseudoMetricSpace.le_two_mul_dist_ofPreNNDist _ _ _ fun x₁ x₂ x₃ x₄ => ?_
X : Type u_2 inst✝¹ : UniformSpace X inst✝ : (𝓤 X).IsCountablyGenerated U : ℕ → Set (X × X) hU_symm : ∀ (n : ℕ), SymmetricRel (U n) hU_comp : ∀ ⦃m n : ℕ⦄, m < n → U n ○ (U n ○ U n) ⊆ U m hB : (𝓤 X).HasAntitoneBasis U d : X → X → ℝ≥0 := fun x y => if h : ∃ n, (x, y) ∉ U n then (1 / 2) ^ Nat.find h else 0 hd₀ : ∀ {x y : X}, d x y = 0 ↔ Inseparable x y hd_symm : ∀ (x y : X), d x y = d y x hr : 1 / 2 ∈ Ioo 0 1 I : PseudoMetricSpace X := PseudoMetricSpace.ofPreNNDist d ⋯ hd_symm hdist_le : ∀ (x y : X), dist x y ≤ ↑(d x y) hle_d : ∀ {x y : X} {n : ℕ}, (1 / 2) ^ n ≤ d x y ↔ (x, y) ∉ U n x₁ x₂ x₃ x₄ : X ⊢ d x₁ x₄ ≤ 2 * (d x₁ x₂ ⊔ (d x₂ x₃ ⊔ d x₃ x₄))
6b4b13aa9c62ee27
Ordinal.card_opow_le
Mathlib/SetTheory/Cardinal/Arithmetic.lean
theorem card_opow_le (a b : Ordinal) : (a ^ b).card ≤ max ℵ₀ (max a.card b.card)
case inl.intro.inl.intro n m : ℕ ⊢ (↑n ^ ↑m).card ≤ ℵ₀ ⊔ ((↑n).card ⊔ (↑m).card)
rw [← natCast_opow, card_nat]
case inl.intro.inl.intro n m : ℕ ⊢ ↑(n ^ m) ≤ ℵ₀ ⊔ ((↑n).card ⊔ (↑m).card)
128126bfa7317aa2
MeasureTheory.mul_upcrossingsBefore_le
Mathlib/Probability/Martingale/Upcrossing.lean
theorem mul_upcrossingsBefore_le (hf : a ≤ f N ω) (hab : a < b) : (b - a) * upcrossingsBefore a b f N ω ≤ ∑ k ∈ Finset.range N, upcrossingStrat a b f N k ω * (f (k + 1) - f k) ω
Ω : Type u_1 a b : ℝ f : ℕ → Ω → ℝ N : ℕ ω : Ω hf : a ≤ f N ω hab : a < b hN : ¬N = 0 k : ℕ ⊢ ∑ n ∈ Finset.range N, (Set.Ico (lowerCrossingTime a b f N k ω) (upperCrossingTime a b f N (k + 1) ω)).indicator (fun m => f (m + 1) ω - f m ω) n = stoppedValue f (upperCrossingTime a b f N (k + 1)) ω - stoppedValue f (lowerCrossingTime a b f N k) ω
rw [Finset.sum_indicator_eq_sum_filter, (_ : Finset.filter (fun i => i ∈ Set.Ico (lowerCrossingTime a b f N k ω) (upperCrossingTime a b f N (k + 1) ω)) (Finset.range N) = Finset.Ico (lowerCrossingTime a b f N k ω) (upperCrossingTime a b f N (k + 1) ω)), Finset.sum_Ico_eq_add_neg _ lowerCrossingTime_le_upperCrossingTime_succ, Finset.sum_range_sub fun n => f n ω, Finset.sum_range_sub fun n => f n ω, neg_sub, sub_add_sub_cancel]
Ω : Type u_1 a b : ℝ f : ℕ → Ω → ℝ N : ℕ ω : Ω hf : a ≤ f N ω hab : a < b hN : ¬N = 0 k : ℕ ⊢ f (upperCrossingTime a b f N (k + 1) ω) ω - f (lowerCrossingTime a b f N k ω) ω = stoppedValue f (upperCrossingTime a b f N (k + 1)) ω - stoppedValue f (lowerCrossingTime a b f N k) ω Ω : Type u_1 a b : ℝ f : ℕ → Ω → ℝ N : ℕ ω : Ω hf : a ≤ f N ω hab : a < b hN : ¬N = 0 k : ℕ ⊢ Finset.filter (fun i => i ∈ Set.Ico (lowerCrossingTime a b f N k ω) (upperCrossingTime a b f N (k + 1) ω)) (Finset.range N) = Finset.Ico (lowerCrossingTime a b f N k ω) (upperCrossingTime a b f N (k + 1) ω)
fc87e1e3d79bf5b5
LieSubmodule.comap_normalizer
Mathlib/Algebra/Lie/Normalizer.lean
theorem comap_normalizer (f : M' →ₗ⁅R,L⁆ M) : N.normalizer.comap f = (N.comap f).normalizer
R : Type u_1 L : Type u_2 M : Type u_3 M' : Type u_4 inst✝¹⁰ : CommRing R inst✝⁹ : LieRing L inst✝⁸ : LieAlgebra R L inst✝⁷ : AddCommGroup M inst✝⁶ : Module R M inst✝⁵ : LieRingModule L M inst✝⁴ : LieModule R L M inst✝³ : AddCommGroup M' inst✝² : Module R M' inst✝¹ : LieRingModule L M' inst✝ : LieModule R L M' N : LieSubmodule R L M f : M' →ₗ⁅R,L⁆ M ⊢ comap f N.normalizer = (comap f N).normalizer
ext
case h R : Type u_1 L : Type u_2 M : Type u_3 M' : Type u_4 inst✝¹⁰ : CommRing R inst✝⁹ : LieRing L inst✝⁸ : LieAlgebra R L inst✝⁷ : AddCommGroup M inst✝⁶ : Module R M inst✝⁵ : LieRingModule L M inst✝⁴ : LieModule R L M inst✝³ : AddCommGroup M' inst✝² : Module R M' inst✝¹ : LieRingModule L M' inst✝ : LieModule R L M' N : LieSubmodule R L M f : M' →ₗ⁅R,L⁆ M m✝ : M' ⊢ m✝ ∈ comap f N.normalizer ↔ m✝ ∈ (comap f N).normalizer
ec68f89d7c6a8532
MvQPF.has_good_supp_iff
Mathlib/Data/QPF/Multivariate/Basic.lean
theorem has_good_supp_iff {α : TypeVec n} (x : F α) : (∀ p, LiftP p x ↔ ∀ (i), ∀ u ∈ supp x i, p i u) ↔ ∃ a f, abs ⟨a, f⟩ = x ∧ ∀ i a' f', abs ⟨a', f'⟩ = x → f i '' univ ⊆ f' i '' univ
case mp.intro.intro.intro n : ℕ F : TypeVec.{u} n → Type u_1 q : MvQPF F α : TypeVec.{u} n x : F α h : ∀ (p : (i : Fin2 n) → α i → Prop), LiftP p x ↔ ∀ (i : Fin2 n), ∀ u ∈ supp x i, p i u a : (P F).A f : (P F).B a ⟹ α xeq : x = abs ⟨a, f⟩ h' : ∀ (i : Fin2 n) (j : (P F).B a i), supp x i (f i j) ⊢ ∀ (i : Fin2 n) (a' : (P F).A) (f' : (P F).B a' ⟹ α), abs ⟨a', f'⟩ = x → f i '' univ ⊆ f' i '' univ
intro a' f' h''
case mp.intro.intro.intro n : ℕ F : TypeVec.{u} n → Type u_1 q : MvQPF F α : TypeVec.{u} n x : F α h : ∀ (p : (i : Fin2 n) → α i → Prop), LiftP p x ↔ ∀ (i : Fin2 n), ∀ u ∈ supp x i, p i u a : (P F).A f : (P F).B a ⟹ α xeq : x = abs ⟨a, f⟩ h' : ∀ (i : Fin2 n) (j : (P F).B a i), supp x i (f i j) a' : Fin2 n f' : (P F).A h'' : (P F).B f' ⟹ α ⊢ abs ⟨f', h''⟩ = x → f a' '' univ ⊆ h'' a' '' univ
c8763328353a1fcf
Turing.TM2.step_supports
Mathlib/Computability/TuringMachine.lean
theorem step_supports (M : Λ → Stmt Γ Λ σ) {S : Finset Λ} (ss : Supports M S) : ∀ {c c' : Cfg Γ Λ σ}, c' ∈ step M c → c.l ∈ Finset.insertNone S → c'.l ∈ Finset.insertNone S | ⟨some l₁, v, T⟩, c', h₁, h₂ => by replace h₂ := ss.2 _ (Finset.some_mem_insertNone.1 h₂) simp only [step, Option.mem_def, Option.some.injEq] at h₁; subst c' revert h₂; induction M l₁ generalizing v T with intro hs | branch p q₁' q₂' IH₁ IH₂ => unfold stepAux; cases p v · exact IH₂ _ _ hs.2 · exact IH₁ _ _ hs.1 | goto => exact Finset.some_mem_insertNone.2 (hs _) | halt => apply Multiset.mem_cons_self | load _ _ IH | _ _ _ _ IH => exact IH _ _ hs
K : Type u_1 Γ : K → Type u_2 Λ : Type u_3 σ : Type u_4 inst✝¹ : Inhabited Λ inst✝ : DecidableEq K M : Λ → Stmt Γ Λ σ S : Finset Λ ss : Supports M S l₁ : Λ v : σ T : (k : K) → List (Γ k) c' : Cfg Γ Λ σ h₂ : SupportsStmt S (M l₁) h₁ : stepAux (M l₁) v T = c' ⊢ c'.l ∈ Finset.insertNone S
subst c'
K : Type u_1 Γ : K → Type u_2 Λ : Type u_3 σ : Type u_4 inst✝¹ : Inhabited Λ inst✝ : DecidableEq K M : Λ → Stmt Γ Λ σ S : Finset Λ ss : Supports M S l₁ : Λ v : σ T : (k : K) → List (Γ k) h₂ : SupportsStmt S (M l₁) ⊢ (stepAux (M l₁) v T).l ∈ Finset.insertNone S
4820c6206a25e806
Language.reverse_mem_reverse
Mathlib/Computability/Language.lean
lemma reverse_mem_reverse : a.reverse ∈ l.reverse ↔ a ∈ l
α : Type u_1 l : Language α a : List α ⊢ a.reverse ∈ l.reverse ↔ a ∈ l
rw [mem_reverse, List.reverse_reverse]
no goals
59408426c58d4c28
Finsupp.iSup_lsingle_range
Mathlib/LinearAlgebra/Finsupp/Span.lean
theorem iSup_lsingle_range : ⨆ a, LinearMap.range (lsingle a : M →ₗ[R] α →₀ M) = ⊤
α : Type u_1 M : Type u_2 R : Type u_5 inst✝² : Semiring R inst✝¹ : AddCommMonoid M inst✝ : Module R M f : α →₀ M x✝ : f ∈ ⊤ ⊢ f.sum single ∈ ⨆ a, LinearMap.range (lsingle a)
exact sum_mem fun a _ => Submodule.mem_iSup_of_mem a ⟨_, rfl⟩
no goals
c55a20c551a2d199
Ordnode.insertWith.valid_aux
Mathlib/Data/Ordmap/Ordset.lean
theorem insertWith.valid_aux [IsTotal α (· ≤ ·)] [DecidableRel (α := α) (· ≤ ·)] (f : α → α) (x : α) (hf : ∀ y, x ≤ y ∧ y ≤ x → x ≤ f y ∧ f y ≤ x) : ∀ {t o₁ o₂}, Valid' o₁ t o₂ → Bounded nil o₁ x → Bounded nil x o₂ → Valid' o₁ (insertWith f x t) o₂ ∧ Raised (size t) (size (insertWith f x t)) | nil, _, _, _, bl, br => ⟨valid'_singleton bl br, Or.inr rfl⟩ | node sz l y r, o₁, o₂, h, bl, br => by rw [insertWith, cmpLE] split_ifs with h_1 h_2 <;> dsimp only · rcases h with ⟨⟨lx, xr⟩, hs, hb⟩ rcases hf _ ⟨h_1, h_2⟩ with ⟨xf, fx⟩ refine ⟨⟨⟨lx.mono_right (le_trans h_2 xf), xr.mono_left (le_trans fx h_1)⟩, hs, hb⟩, Or.inl rfl⟩ · rcases insertWith.valid_aux f x hf h.left bl (lt_of_le_not_le h_1 h_2) with ⟨vl, e⟩ suffices H : _ by refine ⟨vl.balanceL h.right H, ?_⟩ rw [size_balanceL vl.3 h.3.2.2 vl.2 h.2.2.2 H, h.2.size_eq] exact (e.add_right _).add_right _ exact Or.inl ⟨_, e, h.3.1⟩ · have : y < x := lt_of_le_not_le ((total_of (· ≤ ·) _ _).resolve_left h_1) h_1 rcases insertWith.valid_aux f x hf h.right this br with ⟨vr, e⟩ suffices H : _ by refine ⟨h.left.balanceR vr H, ?_⟩ rw [size_balanceR h.3.2.1 vr.3 h.2.2.1 vr.2 H, h.2.size_eq] exact (e.add_left _).add_right _ exact Or.inr ⟨_, e, h.3.1⟩
α : Type u_1 inst✝² : Preorder α inst✝¹ : IsTotal α fun x1 x2 => x1 ≤ x2 inst✝ : DecidableRel fun x1 x2 => x1 ≤ x2 f : α → α x : α hf : ∀ (y : α), x ≤ y ∧ y ≤ x → x ≤ f y ∧ f y ≤ x sz : ℕ l : Ordnode α y : α r : Ordnode α o₁ : WithBot α o₂ : WithTop α h : Valid' o₁ (node sz l y r) o₂ bl : nil.Bounded o₁ ↑x br : nil.Bounded (↑x) o₂ ⊢ Valid' o₁ (match if x ≤ y then if y ≤ x then Ordering.eq else Ordering.lt else Ordering.gt with | Ordering.lt => (insertWith f x l).balanceL y r | Ordering.eq => node sz l (f y) r | Ordering.gt => l.balanceR y (insertWith f x r)) o₂ ∧ Raised (node sz l y r).size (match if x ≤ y then if y ≤ x then Ordering.eq else Ordering.lt else Ordering.gt with | Ordering.lt => (insertWith f x l).balanceL y r | Ordering.eq => node sz l (f y) r | Ordering.gt => l.balanceR y (insertWith f x r)).size
split_ifs with h_1 h_2 <;> dsimp only
case pos α : Type u_1 inst✝² : Preorder α inst✝¹ : IsTotal α fun x1 x2 => x1 ≤ x2 inst✝ : DecidableRel fun x1 x2 => x1 ≤ x2 f : α → α x : α hf : ∀ (y : α), x ≤ y ∧ y ≤ x → x ≤ f y ∧ f y ≤ x sz : ℕ l : Ordnode α y : α r : Ordnode α o₁ : WithBot α o₂ : WithTop α h : Valid' o₁ (node sz l y r) o₂ bl : nil.Bounded o₁ ↑x br : nil.Bounded (↑x) o₂ h_1 : x ≤ y h_2 : y ≤ x ⊢ Valid' o₁ (node sz l (f y) r) o₂ ∧ Raised (node sz l y r).size (node sz l (f y) r).size case neg α : Type u_1 inst✝² : Preorder α inst✝¹ : IsTotal α fun x1 x2 => x1 ≤ x2 inst✝ : DecidableRel fun x1 x2 => x1 ≤ x2 f : α → α x : α hf : ∀ (y : α), x ≤ y ∧ y ≤ x → x ≤ f y ∧ f y ≤ x sz : ℕ l : Ordnode α y : α r : Ordnode α o₁ : WithBot α o₂ : WithTop α h : Valid' o₁ (node sz l y r) o₂ bl : nil.Bounded o₁ ↑x br : nil.Bounded (↑x) o₂ h_1 : x ≤ y h_2 : ¬y ≤ x ⊢ Valid' o₁ ((insertWith f x l).balanceL y r) o₂ ∧ Raised (node sz l y r).size ((insertWith f x l).balanceL y r).size case neg α : Type u_1 inst✝² : Preorder α inst✝¹ : IsTotal α fun x1 x2 => x1 ≤ x2 inst✝ : DecidableRel fun x1 x2 => x1 ≤ x2 f : α → α x : α hf : ∀ (y : α), x ≤ y ∧ y ≤ x → x ≤ f y ∧ f y ≤ x sz : ℕ l : Ordnode α y : α r : Ordnode α o₁ : WithBot α o₂ : WithTop α h : Valid' o₁ (node sz l y r) o₂ bl : nil.Bounded o₁ ↑x br : nil.Bounded (↑x) o₂ h_1 : ¬x ≤ y ⊢ Valid' o₁ (l.balanceR y (insertWith f x r)) o₂ ∧ Raised (node sz l y r).size (l.balanceR y (insertWith f x r)).size
6bc0954662ae2391
EuclideanGeometry.Sphere.secondInter_secondInter
Mathlib/Geometry/Euclidean/Sphere/SecondInter.lean
theorem Sphere.secondInter_secondInter (s : Sphere P) (p : P) (v : V) : s.secondInter (s.secondInter p v) v = p
case pos V : Type u_1 P : Type u_2 inst✝³ : NormedAddCommGroup V inst✝² : InnerProductSpace ℝ V inst✝¹ : MetricSpace P inst✝ : NormedAddTorsor V P s : Sphere P p : P v : V hv : v = 0 ⊢ s.secondInter (s.secondInter p v) v = p
simp [hv]
no goals
ee5a6023431a9a7c
GenContFract.abs_sub_convs_le
Mathlib/Algebra/ContinuedFractions/Computation/Approximations.lean
theorem abs_sub_convs_le (not_terminatedAt_n : ¬(of v).TerminatedAt n) : |v - (of v).convs n| ≤ 1 / ((of v).dens n * ((of v).dens <| n + 1))
case intro.intro.intro.intro.intro.intro.right K : Type u_1 v : K n : ℕ inst✝¹ : LinearOrderedField K inst✝ : FloorRing K not_terminatedAt_n : ¬(of v).TerminatedAt n g : GenContFract K := of v nextConts : Pair K := g.contsAux (n + 2) conts : Pair K := g.contsAux (n + 1) conts_eq : conts = g.contsAux (n + 1) pred_conts : Pair K := g.contsAux n pred_conts_eq : pred_conts = g.contsAux n gp : Pair K s_nth_eq : g.s.get? n = some gp gp_a_eq_one : gp.a = 1 nextConts_b_eq : nextConts.b = pred_conts.b + gp.b * conts.b den : K := conts.b * (pred_conts.b + gp.b * conts.b) ifp_succ_n : IntFractPair K succ_nth_stream_eq : IntFractPair.stream v (n + 1) = some ifp_succ_n ifp_succ_n_b_eq_gp_b : ↑ifp_succ_n.b = gp.b ifp_n : IntFractPair K stream_nth_eq : IntFractPair.stream v n = some ifp_n stream_nth_fr_ne_zero : ifp_n.fr ≠ 0 if_of_eq_ifp_succ_n : IntFractPair.of ifp_n.fr⁻¹ = ifp_succ_n den' : K := conts.b * (pred_conts.b + ifp_n.fr⁻¹ * conts.b) nextConts_b_ineq : ↑(fib (n + 2)) ≤ pred_conts.b + gp.b * conts.b conts_b_ineq : ↑(fib (n + 1)) ≤ conts.b zero_lt_conts_b : 0 < conts.b ⊢ gp.b * conts.b ≤ ifp_n.fr⁻¹ * conts.b
suffices (ifp_succ_n.b : K) * conts.b ≤ ifp_n.fr⁻¹ * conts.b by rwa [← ifp_succ_n_b_eq_gp_b]
case intro.intro.intro.intro.intro.intro.right K : Type u_1 v : K n : ℕ inst✝¹ : LinearOrderedField K inst✝ : FloorRing K not_terminatedAt_n : ¬(of v).TerminatedAt n g : GenContFract K := of v nextConts : Pair K := g.contsAux (n + 2) conts : Pair K := g.contsAux (n + 1) conts_eq : conts = g.contsAux (n + 1) pred_conts : Pair K := g.contsAux n pred_conts_eq : pred_conts = g.contsAux n gp : Pair K s_nth_eq : g.s.get? n = some gp gp_a_eq_one : gp.a = 1 nextConts_b_eq : nextConts.b = pred_conts.b + gp.b * conts.b den : K := conts.b * (pred_conts.b + gp.b * conts.b) ifp_succ_n : IntFractPair K succ_nth_stream_eq : IntFractPair.stream v (n + 1) = some ifp_succ_n ifp_succ_n_b_eq_gp_b : ↑ifp_succ_n.b = gp.b ifp_n : IntFractPair K stream_nth_eq : IntFractPair.stream v n = some ifp_n stream_nth_fr_ne_zero : ifp_n.fr ≠ 0 if_of_eq_ifp_succ_n : IntFractPair.of ifp_n.fr⁻¹ = ifp_succ_n den' : K := conts.b * (pred_conts.b + ifp_n.fr⁻¹ * conts.b) nextConts_b_ineq : ↑(fib (n + 2)) ≤ pred_conts.b + gp.b * conts.b conts_b_ineq : ↑(fib (n + 1)) ≤ conts.b zero_lt_conts_b : 0 < conts.b ⊢ ↑ifp_succ_n.b * conts.b ≤ ifp_n.fr⁻¹ * conts.b
a2279d23d2560b5e
Hindman.FP.finset_prod
Mathlib/Combinatorics/Hindman.lean
theorem FP.finset_prod {M} [CommMonoid M] (a : Stream' M) (s : Finset ℕ) (hs : s.Nonempty) : (s.prod fun i => a.get i) ∈ FP a
case H M : Type u_1 inst✝ : CommMonoid M a : Stream' M s : Finset ℕ ih : ∀ t ⊂ s, ∀ (hs : t.Nonempty), ∏ i ∈ t, a.get i ∈ FP (Stream'.drop (t.min' hs) a) hs : s.Nonempty ⊢ (Stream'.drop (s.min' hs) a).head * ∏ x ∈ s.erase (s.min' hs), a.get x ∈ FP (Stream'.drop (s.min' hs) a)
rcases (s.erase (s.min' hs)).eq_empty_or_nonempty with h | h
case H.inl M : Type u_1 inst✝ : CommMonoid M a : Stream' M s : Finset ℕ ih : ∀ t ⊂ s, ∀ (hs : t.Nonempty), ∏ i ∈ t, a.get i ∈ FP (Stream'.drop (t.min' hs) a) hs : s.Nonempty h : s.erase (s.min' hs) = ∅ ⊢ (Stream'.drop (s.min' hs) a).head * ∏ x ∈ s.erase (s.min' hs), a.get x ∈ FP (Stream'.drop (s.min' hs) a) case H.inr M : Type u_1 inst✝ : CommMonoid M a : Stream' M s : Finset ℕ ih : ∀ t ⊂ s, ∀ (hs : t.Nonempty), ∏ i ∈ t, a.get i ∈ FP (Stream'.drop (t.min' hs) a) hs : s.Nonempty h : (s.erase (s.min' hs)).Nonempty ⊢ (Stream'.drop (s.min' hs) a).head * ∏ x ∈ s.erase (s.min' hs), a.get x ∈ FP (Stream'.drop (s.min' hs) a)
2807cb40e776fcc5
StrictMonoOn.exists_slope_lt_deriv_aux
Mathlib/Analysis/Convex/Deriv.lean
theorem StrictMonoOn.exists_slope_lt_deriv_aux {x y : ℝ} {f : ℝ → ℝ} (hf : ContinuousOn f (Icc x y)) (hxy : x < y) (hf'_mono : StrictMonoOn (deriv f) (Ioo x y)) (h : ∀ w ∈ Ioo x y, deriv f w ≠ 0) : ∃ a ∈ Ioo x y, (f y - f x) / (y - x) < deriv f a
x y : ℝ f : ℝ → ℝ hf : ContinuousOn f (Icc x y) hxy : x < y hf'_mono : StrictMonoOn (deriv f) (Ioo x y) h : ∀ w ∈ Ioo x y, deriv f w ≠ 0 A : DifferentiableOn ℝ f (Ioo x y) ⊢ ∃ a ∈ Ioo x y, (f y - f x) / (y - x) < deriv f a
obtain ⟨a, ⟨hxa, hay⟩, ha⟩ : ∃ a ∈ Ioo x y, deriv f a = (f y - f x) / (y - x) := exists_deriv_eq_slope f hxy hf A
case intro.intro.intro x y : ℝ f : ℝ → ℝ hf : ContinuousOn f (Icc x y) hxy : x < y hf'_mono : StrictMonoOn (deriv f) (Ioo x y) h : ∀ w ∈ Ioo x y, deriv f w ≠ 0 A : DifferentiableOn ℝ f (Ioo x y) a : ℝ ha : deriv f a = (f y - f x) / (y - x) hxa : x < a hay : a < y ⊢ ∃ a ∈ Ioo x y, (f y - f x) / (y - x) < deriv f a
be3b59c8e97fd897
OrdinalApprox.lfpApprox_mem_fixedPoints_of_eq
Mathlib/SetTheory/Ordinal/FixedPointApproximants.lean
/-- If the sequence of ordinal-indexed approximations takes a value twice, then it actually stabilised at that value. -/ lemma lfpApprox_mem_fixedPoints_of_eq {a b c : Ordinal} (h_init : x ≤ f x) (h_ab : a < b) (h_ac : a ≤ c) (h_fab : lfpApprox f x a = lfpApprox f x b) : lfpApprox f x c ∈ fixedPoints f
α : Type u inst✝ : CompleteLattice α f : α →o α x : α a b c : Ordinal.{u} h_init : x ≤ f x h_ab : a < b h_ac : a ≤ c h_fab : lfpApprox f x a = lfpApprox f x b ⊢ lfpApprox f x (a + 1) = lfpApprox f x a
exact Monotone.eq_of_le_of_le (lfpApprox_monotone f x) h_fab (SuccOrder.le_succ a) (SuccOrder.succ_le_of_lt h_ab)
no goals
fcaa28d818378714
UniformSpace.Completion.continuous_hatInv
Mathlib/Topology/Algebra/UniformField.lean
theorem continuous_hatInv [CompletableTopField K] {x : hat K} (h : x ≠ 0) : ContinuousAt hatInv x
K : Type u_1 inst✝² : Field K inst✝¹ : UniformSpace K inst✝ : CompletableTopField K x : hat K h : x ≠ 0 ⊢ ∀ᶠ (x : hat K) in 𝓝 x, ∃ c, Tendsto (fun x => ↑x⁻¹) (Filter.comap coe' (𝓝 x)) (𝓝 c)
apply mem_of_superset (compl_singleton_mem_nhds h)
K : Type u_1 inst✝² : Field K inst✝¹ : UniformSpace K inst✝ : CompletableTopField K x : hat K h : x ≠ 0 ⊢ {0}ᶜ ⊆ {x | (fun x => ∃ c, Tendsto (fun x => ↑x⁻¹) (Filter.comap coe' (𝓝 x)) (𝓝 c)) x}
2b79bfc09ae36473
FormalMultilinearSeries.changeOrigin_eval_of_finite
Mathlib/Analysis/Analytic/CPolynomialDef.lean
theorem changeOrigin_eval_of_finite (p : FormalMultilinearSeries 𝕜 E F) {n : ℕ} (hn : ∀ (m : ℕ), n ≤ m → p m = 0) (x y : E) : (p.changeOrigin x).sum y = p.sum (x + y)
𝕜 : Type u_1 E : Type u_2 F : Type u_3 inst✝⁴ : NontriviallyNormedField 𝕜 inst✝³ : NormedAddCommGroup E inst✝² : NormedSpace 𝕜 E inst✝¹ : NormedAddCommGroup F inst✝ : NormedSpace 𝕜 F p : FormalMultilinearSeries 𝕜 E F n✝ : ℕ hn : ∀ (m : ℕ), n✝ ≤ m → p m = 0 x y : E f : (k : ℕ) × (l : ℕ) × { s // s.card = l } → F := fun s => ((p.changeOriginSeriesTerm s.fst s.snd.fst ↑s.snd.snd ⋯) fun x_1 => x) fun x => y finsupp : (Function.support f).Finite hfkl : ∀ (k l : ℕ), HasSum (fun x => f ⟨k, ⟨l, x⟩⟩) (((p.changeOriginSeries k l) fun x_1 => x) fun x => y) hfk : ∀ (k : ℕ), HasSum (fun x => f ⟨k, x⟩) ((p.changeOrigin x k) fun x => y) hf : HasSum f ((p.changeOrigin x).sum y) n : ℕ ⊢ HasSum (fun c => (f ∘ ⇑changeOriginIndexEquiv.symm) ⟨n, c⟩) ((p n) fun x_1 => x + y)
rw [← Pi.add_def, (p n).map_add_univ (fun _ ↦ x) fun _ ↦ y]
𝕜 : Type u_1 E : Type u_2 F : Type u_3 inst✝⁴ : NontriviallyNormedField 𝕜 inst✝³ : NormedAddCommGroup E inst✝² : NormedSpace 𝕜 E inst✝¹ : NormedAddCommGroup F inst✝ : NormedSpace 𝕜 F p : FormalMultilinearSeries 𝕜 E F n✝ : ℕ hn : ∀ (m : ℕ), n✝ ≤ m → p m = 0 x y : E f : (k : ℕ) × (l : ℕ) × { s // s.card = l } → F := fun s => ((p.changeOriginSeriesTerm s.fst s.snd.fst ↑s.snd.snd ⋯) fun x_1 => x) fun x => y finsupp : (Function.support f).Finite hfkl : ∀ (k l : ℕ), HasSum (fun x => f ⟨k, ⟨l, x⟩⟩) (((p.changeOriginSeries k l) fun x_1 => x) fun x => y) hfk : ∀ (k : ℕ), HasSum (fun x => f ⟨k, x⟩) ((p.changeOrigin x k) fun x => y) hf : HasSum f ((p.changeOrigin x).sum y) n : ℕ ⊢ HasSum (fun c => (f ∘ ⇑changeOriginIndexEquiv.symm) ⟨n, c⟩) (∑ s : Finset (Fin n), (p n) (s.piecewise (fun x_1 => x) fun x => y))
8c604310c51ca63d
ModuleCat.ExtendScalars.hom_ext
Mathlib/Algebra/Category/ModuleCat/ChangeOfRings.lean
@[ext] lemma hom_ext {M : ModuleCat R} {N : ModuleCat S} {α β : (extendScalars f).obj M ⟶ N} (h : ∀ (m : M), α ((1 : S) ⊗ₜ m) = β ((1 : S) ⊗ₜ m)) : α = β
case a.hf.H R : Type u₁ S : Type u₂ inst✝¹ : CommRing R inst✝ : CommRing S f : R →+* S M : ModuleCat R N : ModuleCat S α β : (extendScalars f).obj M ⟶ N h : ∀ (m : ↑M), (ConcreteCategory.hom α) (1 ⊗ₜ[R] m) = (ConcreteCategory.hom β) (1 ⊗ₜ[R] m) this : Algebra R S := f.toAlgebra s : S m : ↑M ⊢ (ConcreteCategory.hom α) (s ⊗ₜ[R] m) = (ConcreteCategory.hom β) (s ⊗ₜ[R] m)
have : s ⊗ₜ[R] (m : M) = s • (1 : S) ⊗ₜ[R] m := by rw [ExtendScalars.smul_tmul, mul_one]
case a.hf.H R : Type u₁ S : Type u₂ inst✝¹ : CommRing R inst✝ : CommRing S f : R →+* S M : ModuleCat R N : ModuleCat S α β : (extendScalars f).obj M ⟶ N h : ∀ (m : ↑M), (ConcreteCategory.hom α) (1 ⊗ₜ[R] m) = (ConcreteCategory.hom β) (1 ⊗ₜ[R] m) this✝ : Algebra R S := f.toAlgebra s : S m : ↑M this : s ⊗ₜ[R] m = s • 1 ⊗ₜ[R] m ⊢ (ConcreteCategory.hom α) (s ⊗ₜ[R] m) = (ConcreteCategory.hom β) (s ⊗ₜ[R] m)
89a1ddede4e60741
eVariationOn.comp_eq_of_antitoneOn
Mathlib/Topology/EMetricSpace/BoundedVariation.lean
theorem comp_eq_of_antitoneOn (f : α → E) {t : Set β} (φ : β → α) (hφ : AntitoneOn φ t) : eVariationOn (f ∘ φ) t = eVariationOn f (φ '' t)
α : Type u_1 inst✝² : LinearOrder α E : Type u_2 inst✝¹ : PseudoEMetricSpace E β : Type u_3 inst✝ : LinearOrder β f : α → E t : Set β φ : β → α hφ : AntitoneOn φ t ⊢ eVariationOn f (φ '' t) ≤ eVariationOn (f ∘ φ) t
cases isEmpty_or_nonempty β
case inl α : Type u_1 inst✝² : LinearOrder α E : Type u_2 inst✝¹ : PseudoEMetricSpace E β : Type u_3 inst✝ : LinearOrder β f : α → E t : Set β φ : β → α hφ : AntitoneOn φ t h✝ : IsEmpty β ⊢ eVariationOn f (φ '' t) ≤ eVariationOn (f ∘ φ) t case inr α : Type u_1 inst✝² : LinearOrder α E : Type u_2 inst✝¹ : PseudoEMetricSpace E β : Type u_3 inst✝ : LinearOrder β f : α → E t : Set β φ : β → α hφ : AntitoneOn φ t h✝ : Nonempty β ⊢ eVariationOn f (φ '' t) ≤ eVariationOn (f ∘ φ) t
1c2ffe34f4a2d4cd
AlgebraicGeometry.Scheme.affineBasisCover_is_basis
Mathlib/AlgebraicGeometry/Cover/Open.lean
theorem affineBasisCover_is_basis (X : Scheme.{u}) : TopologicalSpace.IsTopologicalBasis {x : Set X | ∃ a : X.affineBasisCover.J, x = Set.range (X.affineBasisCover.map a).base}
case h_nhds.intro.intro.intro.intro.intro.intro.intro.refine_2 X : Scheme a : ↑↑X.toPresheafedSpace U : Set ↑↑X.toPresheafedSpace haU : a ∈ U hU : IsOpen U x : ↑↑(X.affineCover.obj (X.affineCover.f a)).toPresheafedSpace e : (ConcreteCategory.hom (X.affineCover.map (X.affineCover.f a)).base) x = a U' : Set ↑↑(X.affineCover.obj (X.affineCover.f a)).toPresheafedSpace := ⇑(ConcreteCategory.hom (X.affineCover.map (X.affineCover.f a)).base) ⁻¹' U hxU' : x ∈ U' s : ↑⋯.choose hxV : x ∈ ↑(PrimeSpectrum.basicOpen s) hVU : ↑(PrimeSpectrum.basicOpen s) ⊆ U' ⊢ ⇑(ConcreteCategory.hom (X.affineCover.map (X.affineCover.f a)).base) '' (PrimeSpectrum.basicOpen s).carrier ⊆ U
rw [Set.image_subset_iff]
case h_nhds.intro.intro.intro.intro.intro.intro.intro.refine_2 X : Scheme a : ↑↑X.toPresheafedSpace U : Set ↑↑X.toPresheafedSpace haU : a ∈ U hU : IsOpen U x : ↑↑(X.affineCover.obj (X.affineCover.f a)).toPresheafedSpace e : (ConcreteCategory.hom (X.affineCover.map (X.affineCover.f a)).base) x = a U' : Set ↑↑(X.affineCover.obj (X.affineCover.f a)).toPresheafedSpace := ⇑(ConcreteCategory.hom (X.affineCover.map (X.affineCover.f a)).base) ⁻¹' U hxU' : x ∈ U' s : ↑⋯.choose hxV : x ∈ ↑(PrimeSpectrum.basicOpen s) hVU : ↑(PrimeSpectrum.basicOpen s) ⊆ U' ⊢ (PrimeSpectrum.basicOpen s).carrier ⊆ ⇑(ConcreteCategory.hom (X.affineCover.map (X.affineCover.f a)).base) ⁻¹' U
f074a127ed56c597
top_le_span_of_aux
Mathlib/LinearAlgebra/Basis/Exact.lean
private lemma top_le_span_of_aux (v : κ ⊕ σ → M) (hg : Function.Surjective g) (hslzero : ∀ i, s (v (.inl i)) = 0) (hli : LinearIndependent R (s ∘ v ∘ .inr)) (hsp : ⊤ ≤ Submodule.span R (Set.range v)) : ⊤ ≤ Submodule.span R (Set.range <| g ∘ v ∘ .inl)
case intro R✝ : Type u_1 M✝ : Type u_2 K✝ : Type u_3 P✝ : Type u_4 inst✝¹³ : Ring R✝ inst✝¹² : AddCommGroup M✝ inst✝¹¹ : AddCommGroup K✝ inst✝¹⁰ : AddCommGroup P✝ inst✝⁹ : Module R✝ M✝ inst✝⁸ : Module R✝ K✝ inst✝⁷ : Module R✝ P✝ g✝ : M✝ →ₗ[R✝] P✝ s✝ : M✝ →ₗ[R✝] K✝ κ✝ : Type u_6 σ✝ : Type u_7 R : Type u_1 M : Type u_2 K : Type u_3 P : Type u_4 inst✝⁶ : Ring R inst✝⁵ : AddCommGroup M inst✝⁴ : AddCommGroup K inst✝³ : AddCommGroup P inst✝² : Module R M inst✝¹ : Module R K inst✝ : Module R P f : K →ₗ[R] M g : M →ₗ[R] P s : M →ₗ[R] K hs : s ∘ₗ f = LinearMap.id hfg : Function.Exact ⇑f ⇑g κ : Type u_6 σ : Type u_7 v : κ ⊕ σ → M hg : Function.Surjective ⇑g hslzero : ∀ (i : κ), s (v (Sum.inl i)) = 0 hli : LinearIndependent R (⇑s ∘ v ∘ Sum.inr) hsp : ⊤ ≤ Submodule.span R (Set.range v) c : κ ⊕ σ →₀ R this : (c.sum fun i a => a • v i) ∈ Submodule.span R (Set.range v) h : ∑ x ∈ c.support.toRight, c (Sum.inr x) • s (v (Sum.inr x)) = 0 ⊢ g (c.sum fun i a => a • v i) ∈ Submodule.span R (Set.range (⇑g ∘ v ∘ Sum.inl))
replace hli := (linearIndependent_iff'.mp hli) c.support.toRight (c ∘ .inr) h
case intro R✝ : Type u_1 M✝ : Type u_2 K✝ : Type u_3 P✝ : Type u_4 inst✝¹³ : Ring R✝ inst✝¹² : AddCommGroup M✝ inst✝¹¹ : AddCommGroup K✝ inst✝¹⁰ : AddCommGroup P✝ inst✝⁹ : Module R✝ M✝ inst✝⁸ : Module R✝ K✝ inst✝⁷ : Module R✝ P✝ g✝ : M✝ →ₗ[R✝] P✝ s✝ : M✝ →ₗ[R✝] K✝ κ✝ : Type u_6 σ✝ : Type u_7 R : Type u_1 M : Type u_2 K : Type u_3 P : Type u_4 inst✝⁶ : Ring R inst✝⁵ : AddCommGroup M inst✝⁴ : AddCommGroup K inst✝³ : AddCommGroup P inst✝² : Module R M inst✝¹ : Module R K inst✝ : Module R P f : K →ₗ[R] M g : M →ₗ[R] P s : M →ₗ[R] K hs : s ∘ₗ f = LinearMap.id hfg : Function.Exact ⇑f ⇑g κ : Type u_6 σ : Type u_7 v : κ ⊕ σ → M hg : Function.Surjective ⇑g hslzero : ∀ (i : κ), s (v (Sum.inl i)) = 0 hsp : ⊤ ≤ Submodule.span R (Set.range v) c : κ ⊕ σ →₀ R this : (c.sum fun i a => a • v i) ∈ Submodule.span R (Set.range v) h : ∑ x ∈ c.support.toRight, c (Sum.inr x) • s (v (Sum.inr x)) = 0 hli : ∀ i ∈ c.support.toRight, (⇑c ∘ Sum.inr) i = 0 ⊢ g (c.sum fun i a => a • v i) ∈ Submodule.span R (Set.range (⇑g ∘ v ∘ Sum.inl))
d124f5729aeaf148
CategoryTheory.isSheaf_coherent
Mathlib/CategoryTheory/Sites/Coherent/CoherentSheaves.lean
lemma isSheaf_coherent (P : Cᵒᵖ ⥤ Type w) : Presieve.IsSheaf (coherentTopology C) P ↔ (∀ (B : C) (α : Type) [Finite α] (X : α → C) (π : (a : α) → (X a ⟶ B)), EffectiveEpiFamily X π → (Presieve.ofArrows X π).IsSheafFor P)
case mpr C : Type u_1 inst✝¹ : Category.{u_2, u_1} C inst✝ : Precoherent C P : Cᵒᵖ ⥤ Type w ⊢ (∀ (B : C) (α : Type) [inst : Finite α] (X : α → C) (π : (a : α) → X a ⟶ B), EffectiveEpiFamily X π → Presieve.IsSheafFor P (Presieve.ofArrows X π)) → Presieve.IsSheaf (coherentTopology C) P
intro h
case mpr C : Type u_1 inst✝¹ : Category.{u_2, u_1} C inst✝ : Precoherent C P : Cᵒᵖ ⥤ Type w h : ∀ (B : C) (α : Type) [inst : Finite α] (X : α → C) (π : (a : α) → X a ⟶ B), EffectiveEpiFamily X π → Presieve.IsSheafFor P (Presieve.ofArrows X π) ⊢ Presieve.IsSheaf (coherentTopology C) P
5dd76cf3a7d8a0a6