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
BitVec.toInt_signExtend_of_lt
Mathlib/.lake/packages/lean4/src/lean/Init/Data/BitVec/Lemmas.lean
theorem toInt_signExtend_of_lt {x : BitVec w} (hv : w < v): (x.signExtend v).toInt = x.toInt
w v : Nat x : BitVec w hv : w < v ⊢ (signExtend v x)[v - 1] = x.msb
simp [getElem_signExtend, Nat.le_sub_one_of_lt hv]
no goals
8d5f3d5abff36d51
Finset.toRight_cons_inr
Mathlib/Data/Finset/Sum.lean
@[simp] lemma toRight_cons_inr (hb) : (cons (inr b) u hb).toRight = cons b u.toRight (by simpa)
α : Type u_1 β : Type u_2 b : β u : Finset (α ⊕ β) hb : inr b ∉ u ⊢ (cons (inr b) u hb).toRight = cons b u.toRight ⋯
ext y
case h α : Type u_1 β : Type u_2 b : β u : Finset (α ⊕ β) hb : inr b ∉ u y : β ⊢ y ∈ (cons (inr b) u hb).toRight ↔ y ∈ cons b u.toRight ⋯
8c6d972aff314ec7
FormalMultilinearSeries.ofScalars_radius_eq_top_of_tendsto
Mathlib/Analysis/Analytic/OfScalars.lean
theorem ofScalars_radius_eq_top_of_tendsto (hc : ∀ᶠ n in atTop, c n ≠ 0) (hc' : Tendsto (fun n ↦ ‖c n.succ‖ / ‖c n‖) atTop (𝓝 0)) : (ofScalars E c).radius = ⊤
case neg.refine_1 𝕜 : Type u_1 E : Type u_2 inst✝² : NontriviallyNormedField 𝕜 inst✝¹ : NormedRing E inst✝ : NormedAlgebra 𝕜 E c : ℕ → 𝕜 hc : ∀ᶠ (n : ℕ) in atTop, c n ≠ 0 hc' : Tendsto (fun n => ‖c n.succ‖ / ‖c n‖) atTop (𝓝 0) r' : ℝ≥0 hrz : ¬r' = 0 ⊢ Tendsto (fun n => ‖‖‖c (n + 1)‖ * ↑r' ^ (n + 1)‖‖ / ‖‖‖c n‖ * ↑r' ^ n‖‖) atTop (𝓝 0)
simp only [norm_norm]
case neg.refine_1 𝕜 : Type u_1 E : Type u_2 inst✝² : NontriviallyNormedField 𝕜 inst✝¹ : NormedRing E inst✝ : NormedAlgebra 𝕜 E c : ℕ → 𝕜 hc : ∀ᶠ (n : ℕ) in atTop, c n ≠ 0 hc' : Tendsto (fun n => ‖c n.succ‖ / ‖c n‖) atTop (𝓝 0) r' : ℝ≥0 hrz : ¬r' = 0 ⊢ Tendsto (fun n => ‖‖c (n + 1)‖ * ↑r' ^ (n + 1)‖ / ‖‖c n‖ * ↑r' ^ n‖) atTop (𝓝 0)
fed995db04eea233
FintypeCat.uSwitchEquiv_symm_naturality
Mathlib/CategoryTheory/FintypeCat.lean
lemma uSwitchEquiv_symm_naturality {X Y : FintypeCat.{u}} (f : X ⟶ Y) (x : X) : uSwitch.map f (X.uSwitchEquiv.symm x) = Y.uSwitchEquiv.symm (f x)
X Y : FintypeCat f : X ⟶ Y x : X.carrier ⊢ uSwitch.map f (X.uSwitchEquiv.symm x) = Y.uSwitchEquiv.symm (f x)
rw [← Equiv.apply_eq_iff_eq_symm_apply, ← uSwitchEquiv_naturality f, Equiv.apply_symm_apply]
no goals
96883c09ded383e5
lp.norm_eq_zero_iff
Mathlib/Analysis/Normed/Lp/lpSpace.lean
theorem norm_eq_zero_iff {f : lp E p} : ‖f‖ = 0 ↔ f = 0
case inr.inr α : Type u_3 E : α → Type u_4 p : ℝ≥0∞ inst✝ : (i : α) → NormedAddCommGroup (E i) f : ↥(lp E p) h : ‖f‖ = 0 hp : 0 < p.toReal hf : HasSum (fun i => ‖↑f i‖ ^ p.toReal) 0 ⊢ f = 0
have : ∀ i, 0 ≤ ‖f i‖ ^ p.toReal := fun i => Real.rpow_nonneg (norm_nonneg _) _
case inr.inr α : Type u_3 E : α → Type u_4 p : ℝ≥0∞ inst✝ : (i : α) → NormedAddCommGroup (E i) f : ↥(lp E p) h : ‖f‖ = 0 hp : 0 < p.toReal hf : HasSum (fun i => ‖↑f i‖ ^ p.toReal) 0 this : ∀ (i : α), 0 ≤ ‖↑f i‖ ^ p.toReal ⊢ f = 0
b5b6304c5b4b6762
RootPairing.infinite_of_linInd_coxeterWeight_four
Mathlib/LinearAlgebra/RootSystem/Reduced.lean
lemma infinite_of_linInd_coxeterWeight_four [NeZero (2 : R)] [NoZeroSMulDivisors ℤ M] (hl : LinearIndependent R ![P.root i, P.root j]) (hc : P.coxeterWeight i j = 4) : Infinite ι
case refine_3 ι : 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 i j : ι inst✝¹ : NeZero 2 inst✝ : NoZeroSMulDivisors ℤ M hc : P.coxeterWeight i j = 4 hl : ¬P.pairing j i • P.root i + -(2 • P.root j) = 0 ⊢ (P.toLin.flip (P.coroot i)) (P.root j) • P.root i ≠ 2 • P.root j
rw [ne_eq, coroot_root_eq_pairing, ← sub_eq_zero, sub_eq_add_neg]
case refine_3 ι : 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 i j : ι inst✝¹ : NeZero 2 inst✝ : NoZeroSMulDivisors ℤ M hc : P.coxeterWeight i j = 4 hl : ¬P.pairing j i • P.root i + -(2 • P.root j) = 0 ⊢ ¬P.pairing j i • P.root i + -(2 • P.root j) = 0
6d8a6318d73cc39f
CategoryTheory.ShortComplex.HomologyMapData.comm
Mathlib/Algebra/Homology/ShortComplex/Homology.lean
@[reassoc] lemma comm (h : HomologyMapData φ h₁ h₂) : h.left.φH ≫ h₂.iso.hom = h₁.iso.hom ≫ h.right.φH
C : Type u inst✝¹ : Category.{v, u} C inst✝ : HasZeroMorphisms C S₁ S₂ : ShortComplex C φ : S₁ ⟶ S₂ h₁ : S₁.HomologyData h₂ : S₂.HomologyData h : HomologyMapData φ h₁ h₂ ⊢ h.left.φH ≫ h₂.iso.hom = h₁.iso.hom ≫ h.right.φH
simp only [← cancel_epi h₁.left.π, ← cancel_mono h₂.right.ι, assoc, LeftHomologyMapData.commπ_assoc, HomologyData.comm, LeftHomologyMapData.commi_assoc, RightHomologyMapData.commι, HomologyData.comm_assoc, RightHomologyMapData.commp]
no goals
63ba4f728922b48b
EuclideanDomain.mod_eq_zero
Mathlib/Algebra/EuclideanDomain/Basic.lean
theorem mod_eq_zero {a b : R} : a % b = 0 ↔ b ∣ a := ⟨fun h => by rw [← div_add_mod a b, h, add_zero] exact dvd_mul_right _ _, fun ⟨c, e⟩ => by rw [e, ← add_left_cancel_iff, div_add_mod, add_zero] haveI := Classical.dec by_cases b0 : b = 0 · simp only [b0, zero_mul] · rw [mul_div_cancel_left₀ _ b0]⟩
case neg R : Type u inst✝ : EuclideanDomain R a b : R x✝ : b ∣ a c : R e : a = b * c this : (p : Prop) → Decidable p b0 : ¬b = 0 ⊢ b * c = b * (b * c / b)
rw [mul_div_cancel_left₀ _ b0]
no goals
b42d0fe6e6a8faaf
GenContFract.contsAux_eq_contsAux_squashGCF_of_le
Mathlib/Algebra/ContinuedFractions/ConvergentsEquiv.lean
theorem contsAux_eq_contsAux_squashGCF_of_le {m : ℕ} : m ≤ n → contsAux g m = (squashGCF g n).contsAux m := Nat.strong_induction_on m (by clear m intro m IH m_le_n rcases m with - | m' · rfl · rcases n with - | n' · exact (m'.not_succ_le_zero m_le_n).elim -- 1 ≰ 0 · rcases m' with - | m'' · rfl · -- get some inequalities to instantiate the IH for m'' and m'' + 1 have m'_lt_n : m'' + 1 < n' + 1 := m_le_n have succ_m''th_contsAux_eq := IH (m'' + 1) (lt_add_one (m'' + 1)) m'_lt_n.le have : m'' < m'' + 2 := lt_add_of_pos_right m'' zero_lt_two have m''th_contsAux_eq := IH m'' this (le_trans this.le m_le_n) have : (squashGCF g (n' + 1)).s.get? m'' = g.s.get? m'' := squashGCF_nth_of_lt (Nat.succ_lt_succ_iff.mp m'_lt_n) simp [contsAux, succ_m''th_contsAux_eq, m''th_contsAux_eq, this])
case succ.succ.succ K : Type u_1 g : GenContFract K inst✝ : DivisionRing K n' m'' : ℕ IH : ∀ m < m'' + 1 + 1, m ≤ n' + 1 → g.contsAux m = (g.squashGCF (n' + 1)).contsAux m m_le_n : m'' + 1 + 1 ≤ n' + 1 ⊢ g.contsAux (m'' + 1 + 1) = (g.squashGCF (n' + 1)).contsAux (m'' + 1 + 1)
have m'_lt_n : m'' + 1 < n' + 1 := m_le_n
case succ.succ.succ K : Type u_1 g : GenContFract K inst✝ : DivisionRing K n' m'' : ℕ IH : ∀ m < m'' + 1 + 1, m ≤ n' + 1 → g.contsAux m = (g.squashGCF (n' + 1)).contsAux m m_le_n : m'' + 1 + 1 ≤ n' + 1 m'_lt_n : m'' + 1 < n' + 1 ⊢ g.contsAux (m'' + 1 + 1) = (g.squashGCF (n' + 1)).contsAux (m'' + 1 + 1)
cf127cafa12b15bc
SzemerediRegularity.edgeDensity_chunk_uniform
Mathlib/Combinatorics/SimpleGraph/Regularity/Chunk.lean
theorem edgeDensity_chunk_uniform [Nonempty α] (hPα : #P.parts * 16 ^ #P.parts ≤ card α) (hPε : ↑100 ≤ ↑4 ^ #P.parts * ε ^ 5) (hU : U ∈ P.parts) (hV : V ∈ P.parts) : (G.edgeDensity U V : ℝ) ^ 2 - ε ^ 5 / ↑25 ≤ (∑ ab ∈ (chunk hP G ε hU).parts.product (chunk hP G ε hV).parts, (G.edgeDensity ab.1 ab.2 : ℝ) ^ 2) / ↑16 ^ #P.parts
α : Type u_1 inst✝³ : Fintype α inst✝² : DecidableEq α P : Finpartition univ hP : P.IsEquipartition G : SimpleGraph α inst✝¹ : DecidableRel G.Adj ε : ℝ U V : Finset α inst✝ : Nonempty α hPα : #P.parts * 16 ^ #P.parts ≤ Fintype.card α hPε : 100 ≤ 4 ^ #P.parts * ε ^ 5 hU : U ∈ P.parts hV : V ∈ P.parts ⊢ ↑(G.edgeDensity U V) ^ 2 - ε ^ 5 / 25 ≤ (∑ ab ∈ (chunk hP G ε hU).parts.product (chunk hP G ε hV).parts, ↑(G.edgeDensity ab.1 ab.2) ^ 2) / 16 ^ #P.parts
apply (edgeDensity_chunk_aux (hP := hP) hPα hPε hU hV).trans
α : Type u_1 inst✝³ : Fintype α inst✝² : DecidableEq α P : Finpartition univ hP : P.IsEquipartition G : SimpleGraph α inst✝¹ : DecidableRel G.Adj ε : ℝ U V : Finset α inst✝ : Nonempty α hPα : #P.parts * 16 ^ #P.parts ≤ Fintype.card α hPε : 100 ≤ 4 ^ #P.parts * ε ^ 5 hU : U ∈ P.parts hV : V ∈ P.parts ⊢ ((∑ ab ∈ (chunk hP G ε hU).parts.product (chunk hP G ε hV).parts, ↑(G.edgeDensity ab.1 ab.2)) / 16 ^ #P.parts) ^ 2 ≤ (∑ ab ∈ (chunk hP G ε hU).parts.product (chunk hP G ε hV).parts, ↑(G.edgeDensity ab.1 ab.2) ^ 2) / 16 ^ #P.parts
3385f6b5b19d88e6
Basis.le_span
Mathlib/LinearAlgebra/Dimension/StrongRankCondition.lean
theorem Basis.le_span {J : Set M} (v : Basis ι R M) (hJ : span R J = ⊤) : #(range v) ≤ #J
R : Type u M : Type v inst✝³ : Semiring R inst✝² : AddCommMonoid M inst✝¹ : Module R M ι : Type w inst✝ : RankCondition R J : Set M v : Basis ι R M hJ : span R J = ⊤ this✝ : Nontrivial R val✝ : Infinite ↑J S : ↑J → Set ι := fun j => ↑(v.repr ↑j).support S' : ↑J → Set M := fun j => ⇑v '' S j hs : range ⇑v ⊆ ⋃ j, S' j IJ : #↑J < #↑(range ⇑v) this : #↑(⋃ j, S' j) < #↑(range ⇑v) ⊢ False
exact not_le_of_lt this ⟨Set.embeddingOfSubset _ _ hs⟩
no goals
1cc5b7e43db3a8f1
Array.foldl_append
Mathlib/.lake/packages/lean4/src/lean/Init/Data/Array/Lemmas.lean
theorem foldl_append {β : Type _} (f : β → α → β) (b) (l l' : Array α) : (l ++ l').foldl f b = l'.foldl f (l.foldl f b)
α : Type u_1 β : Type u_2 f : β → α → β b : β l l' : Array α ⊢ foldl f b (l ++ l') = foldl f (foldl f b l) l'
simp [foldl_eq_foldlM]
no goals
865e5e8a7f53e7b5
Basis.SmithNormalForm.toAddSubgroup_index_eq_pow_mul_prod
Mathlib/LinearAlgebra/FreeModule/Int.lean
/-- Given a submodule `N` in Smith normal form of a free `R`-module, its index as an additive subgroup is an appropriate power of the cardinality of `R` multiplied by the product of the indexes of the ideals generated by each basis vector. -/ lemma toAddSubgroup_index_eq_pow_mul_prod [Module R M] {N : Submodule R M} (snf : Basis.SmithNormalForm N ι n) : N.toAddSubgroup.index = Nat.card R ^ (Fintype.card ι - n) * ∏ i : Fin n, (Ideal.span {snf.a i}).toAddSubgroup.index
case convert_3 ι : Type u_1 R : Type u_2 M : Type u_3 n : ℕ inst✝³ : CommRing R inst✝² : AddCommGroup M inst✝¹ : Fintype ι inst✝ : Module R M N : Submodule R M bM : Basis ι R M bN : Basis (Fin n) R ↥N f : Fin n ↪ ι a : Fin n → R snf : ∀ (i : Fin n), ↑(bN i) = a i • bM (f i) N' : Submodule R (ι → R) := Submodule.map bM.equivFun N hN' : N' = Submodule.map bM.equivFun N bN' : Basis (Fin n) R ↥N' := bN.map (bM.equivFun.submoduleMap N) snf' : ∀ (i : Fin n), ↑(bN' i) = Pi.single (f i) (a i) hNN' : N.toAddSubgroup.index = N'.toAddSubgroup.index g : ι → R h✝ : ∀ (i : ι), (if h : ∃ j, f j = i then a h.choose else 0) ∣ g i i : ι hj : ∃ j, f j = i j : Fin n h : j ≠ hj.choose hinj : f j ≠ f hj.choose ⊢ (if i = f j then ⋯.choose • a j else 0) = 0
rw [hj.choose_spec] at hinj
case convert_3 ι : Type u_1 R : Type u_2 M : Type u_3 n : ℕ inst✝³ : CommRing R inst✝² : AddCommGroup M inst✝¹ : Fintype ι inst✝ : Module R M N : Submodule R M bM : Basis ι R M bN : Basis (Fin n) R ↥N f : Fin n ↪ ι a : Fin n → R snf : ∀ (i : Fin n), ↑(bN i) = a i • bM (f i) N' : Submodule R (ι → R) := Submodule.map bM.equivFun N hN' : N' = Submodule.map bM.equivFun N bN' : Basis (Fin n) R ↥N' := bN.map (bM.equivFun.submoduleMap N) snf' : ∀ (i : Fin n), ↑(bN' i) = Pi.single (f i) (a i) hNN' : N.toAddSubgroup.index = N'.toAddSubgroup.index g : ι → R h✝ : ∀ (i : ι), (if h : ∃ j, f j = i then a h.choose else 0) ∣ g i i : ι hj : ∃ j, f j = i j : Fin n h : j ≠ hj.choose hinj : f j ≠ i ⊢ (if i = f j then ⋯.choose • a j else 0) = 0
3d7a9cb7455a5c0f
List.findIdx?_go_eq
Mathlib/.lake/packages/lean4/src/lean/Init/Data/List/Find.lean
theorem findIdx?_go_eq {p : α → Bool} {xs : List α} {i : Nat} : findIdx?.go p xs (i+1) = (findIdx?.go p xs 0).map fun k => k + (i + 1)
case cons.isFalse α : Type u_1 p : α → Bool head✝ : α tail✝ : List α i : Nat tail_ih✝ : ∀ {i : Nat}, Option.map (fun i => i + 1) (findIdx?.go p tail✝ i) = Option.map (fun k => k + (i + 1)) (findIdx?.go p tail✝ 0) h✝ : p head✝ = false ⊢ Option.map ((fun i => i + 1) ∘ fun k => k + (i + 1)) (findIdx?.go p tail✝ 0) = Option.map ((fun k => k + (i + 1)) ∘ fun k => k + 1) (findIdx?.go p tail✝ 0)
congr
case cons.isFalse.e_f α : Type u_1 p : α → Bool head✝ : α tail✝ : List α i : Nat tail_ih✝ : ∀ {i : Nat}, Option.map (fun i => i + 1) (findIdx?.go p tail✝ i) = Option.map (fun k => k + (i + 1)) (findIdx?.go p tail✝ 0) h✝ : p head✝ = false ⊢ ((fun i => i + 1) ∘ fun k => k + (i + 1)) = (fun k => k + (i + 1)) ∘ fun k => k + 1
00b11065e9d67637
FermatLastTheoremForThreeGen.a_cube_b_cube_congr_one_or_neg_one
Mathlib/NumberTheory/FLT/Three.lean
/-- Given `S' : Solution'`, then `S'.a` and `S'.b` are both congruent to `1` modulo `λ ^ 4` or are both congruent to `-1`. -/ lemma a_cube_b_cube_congr_one_or_neg_one : λ ^ 4 ∣ S'.a ^ 3 - 1 ∧ λ ^ 4 ∣ S'.b ^ 3 + 1 ∨ λ ^ 4 ∣ S'.a ^ 3 + 1 ∧ λ ^ 4 ∣ S'.b ^ 3 - 1
case intro.inl.intro.inl.intro K : Type u_1 inst✝² : Field K ζ : K hζ : IsPrimitiveRoot ζ ↑3 S' : Solution' hζ inst✝¹ : NumberField K inst✝ : IsCyclotomicExtension {3} ℚ K z : 𝓞 K hz : S'.c = λ * z x : 𝓞 K hx : S'.a ^ 3 - 1 = λ ^ 4 * x y : 𝓞 K hy : S'.b ^ 3 - 1 = λ ^ 4 * y ⊢ False
replace hζ : IsPrimitiveRoot ζ ((3 : ℕ+) ^ 1) := by rwa [pow_one]
case intro.inl.intro.inl.intro K : Type u_1 inst✝² : Field K ζ : K hζ✝ : IsPrimitiveRoot ζ ↑3 S' : Solution' hζ✝ inst✝¹ : NumberField K inst✝ : IsCyclotomicExtension {3} ℚ K z : 𝓞 K hz : S'.c = (hζ✝.toInteger - 1) * z x : 𝓞 K hx : S'.a ^ 3 - 1 = (hζ✝.toInteger - 1) ^ 4 * x y : 𝓞 K hy : S'.b ^ 3 - 1 = (hζ✝.toInteger - 1) ^ 4 * y hζ : IsPrimitiveRoot ζ (↑3 ^ 1) ⊢ False
7f0bf19b77a2dee2
Ideal.map_includeRight_eq
Mathlib/LinearAlgebra/TensorProduct/RightExactness.lean
/-- The ideal of `A ⊗[R] B` generated by `I` is the image of `A ⊗[R] I` -/ lemma Ideal.map_includeRight_eq (I : Ideal B) : (I.map (Algebra.TensorProduct.includeRight : B →ₐ[R] A ⊗[R] B)).restrictScalars R = LinearMap.range (LinearMap.lTensor A (Submodule.subtype (I.restrictScalars R)))
case a R : Type u_1 inst✝⁴ : CommSemiring R A : Type u_2 B : Type u_3 inst✝³ : Semiring A inst✝² : Semiring B inst✝¹ : Algebra R A inst✝ : Algebra R B I : Ideal B a : A b : ↥(Submodule.restrictScalars R I) this : a ⊗ₜ[R] ↑b = a ⊗ₜ[R] 1 * 1 ⊗ₜ[R] ↑b ⊢ 1 ⊗ₜ[R] ↑b ∈ map includeRight I
apply Ideal.mem_map_of_mem includeRight
case a R : Type u_1 inst✝⁴ : CommSemiring R A : Type u_2 B : Type u_3 inst✝³ : Semiring A inst✝² : Semiring B inst✝¹ : Algebra R A inst✝ : Algebra R B I : Ideal B a : A b : ↥(Submodule.restrictScalars R I) this : a ⊗ₜ[R] ↑b = a ⊗ₜ[R] 1 * 1 ⊗ₜ[R] ↑b ⊢ ↑b ∈ I
433dfbb2c63fd4cd
MeasureTheory.Measure.rnDeriv_add_right_of_mutuallySingular
Mathlib/MeasureTheory/Decomposition/RadonNikodym.lean
lemma rnDeriv_add_right_of_mutuallySingular {ν' : Measure α} [SigmaFinite μ] [SigmaFinite ν] [SigmaFinite ν'] (hνν' : ν ⟂ₘ ν') : μ.rnDeriv (ν + ν') =ᵐ[ν] μ.rnDeriv ν
α : Type u_1 m : MeasurableSpace α μ ν ν' : Measure α inst✝² : SigmaFinite μ inst✝¹ : SigmaFinite ν inst✝ : SigmaFinite ν' hνν' : ν ⟂ₘ ν' h_ac : ν ≪ ν + ν' h₁ : (μ.singularPart ν' + ν'.withDensity (μ.rnDeriv ν')).rnDeriv (ν + ν') =ᶠ[ae (ν + ν')] (μ.singularPart ν').rnDeriv (ν + ν') + (ν'.withDensity (μ.rnDeriv ν')).rnDeriv (ν + ν') h₂ : (μ.singularPart ν' + ν'.withDensity (μ.rnDeriv ν')).rnDeriv ν =ᶠ[ae ν] (μ.singularPart ν').rnDeriv ν + (ν'.withDensity (μ.rnDeriv ν')).rnDeriv ν h₃ : (μ.singularPart ν').rnDeriv (ν + ν') =ᶠ[ae ν] (μ.singularPart ν').rnDeriv ν ⊢ ν'.withDensity (μ.rnDeriv ν') ⟂ₘ ν
exact hνν'.symm.withDensity
no goals
aa79bd6ae3fefa2b
IsLocalizedModule.exist_integer_multiples
Mathlib/Algebra/Module/LocalizedModule/Int.lean
theorem exist_integer_multiples {ι : Type*} (s : Finset ι) (g : ι → M') : ∃ b : S, ∀ i ∈ s, IsInteger f (b.val • g i)
case refine_2 R : Type u_1 inst✝⁵ : CommSemiring R S : Submonoid R M : Type u_2 inst✝⁴ : AddCommMonoid M inst✝³ : Module R M M' : Type u_3 inst✝² : AddCommMonoid M' inst✝¹ : Module R M' f : M →ₗ[R] M' inst✝ : IsLocalizedModule S f ι : Type u_4 s : Finset ι g : ι → M' sec : ι → M × ↥S hsec : ∀ (i : ι), (sec i).2 • g i = f (sec i).1 i : ι hi : i ∈ s ⊢ (∏ j ∈ s.erase i, (sec j).2) • f (sec i).1 = (∏ i ∈ s, ↑(sec i).2) • g i
rw [← hsec, ← mul_smul, Submonoid.smul_def]
case refine_2 R : Type u_1 inst✝⁵ : CommSemiring R S : Submonoid R M : Type u_2 inst✝⁴ : AddCommMonoid M inst✝³ : Module R M M' : Type u_3 inst✝² : AddCommMonoid M' inst✝¹ : Module R M' f : M →ₗ[R] M' inst✝ : IsLocalizedModule S f ι : Type u_4 s : Finset ι g : ι → M' sec : ι → M × ↥S hsec : ∀ (i : ι), (sec i).2 • g i = f (sec i).1 i : ι hi : i ∈ s ⊢ ↑((∏ j ∈ s.erase i, (sec j).2) * (sec i).2) • g i = (∏ i ∈ s, ↑(sec i).2) • g i
0d28f5679ff37f99
Set.eq_insert_of_ncard_eq_succ
Mathlib/Data/Set/Card.lean
theorem eq_insert_of_ncard_eq_succ {n : ℕ} (h : s.ncard = n + 1) : ∃ a t, a ∉ t ∧ insert a t = s ∧ t.ncard = n
α : Type u_1 s : Set α n : ℕ h : s.ncard = n + 1 ⊢ ∃ a t, a ∉ t ∧ insert a t = s ∧ t.ncard = n
have hsf := finite_of_ncard_pos (n.zero_lt_succ.trans_eq h.symm)
α : Type u_1 s : Set α n : ℕ h : s.ncard = n + 1 hsf : s.Finite ⊢ ∃ a t, a ∉ t ∧ insert a t = s ∧ t.ncard = n
a83d5923ba572b58
CategoryTheory.shiftFunctorAdd_zero_add_hom_app
Mathlib/CategoryTheory/Shift/Basic.lean
lemma shiftFunctorAdd_zero_add_hom_app (a : A) (X : C) : (shiftFunctorAdd C 0 a).hom.app X = eqToHom (by dsimp; rw [zero_add]) ≫ ((shiftFunctorZero C A).inv.app X)⟦a⟧'
C : Type u A : Type u_1 inst✝² : Category.{v, u} C inst✝¹ : AddMonoid A inst✝ : HasShift C A a : A X : C ⊢ (shiftFunctorAdd C 0 a).hom.app X = eqToHom ⋯ ≫ (shiftFunctor C a).map ((shiftFunctorZero C A).inv.app X)
simp [← shiftFunctorAdd'_zero_add_hom_app, shiftFunctorAdd']
no goals
73e541f3a60f3c7f
tsub_tsub_tsub_cancel_right
Mathlib/Algebra/Order/Sub/Unbundled/Basic.lean
theorem tsub_tsub_tsub_cancel_right (h : c ≤ b) : a - c - (b - c) = a - b
α : Type u_1 inst✝⁵ : AddCommSemigroup α inst✝⁴ : PartialOrder α inst✝³ : ExistsAddOfLE α inst✝² : AddLeftMono α inst✝¹ : Sub α inst✝ : OrderedSub α a b c : α h : c ≤ b ⊢ a - c - (b - c) = a - b
rw [tsub_tsub, add_tsub_cancel_of_le h]
no goals
6e29741ba1746be9
MvPowerSeries.map.isLocalHom
Mathlib/RingTheory/MvPowerSeries/Inverse.lean
theorem map.isLocalHom : IsLocalHom (map σ f) := ⟨by rintro φ ⟨ψ, h⟩ replace h := congr_arg (constantCoeff σ S) h rw [constantCoeff_map] at h have : IsUnit (constantCoeff σ S ↑ψ) := isUnit_constantCoeff _ ψ.isUnit rw [h] at this rcases isUnit_of_map_unit f _ this with ⟨c, hc⟩ exact isUnit_of_mul_eq_one φ (invOfUnit φ c) (mul_invOfUnit φ c hc.symm)⟩
case intro σ : Type u_1 R : Type u_2 S : Type u_3 inst✝² : CommRing R inst✝¹ : CommRing S f : R →+* S inst✝ : IsLocalHom f φ : MvPowerSeries σ R ψ : (MvPowerSeries σ S)ˣ h : (constantCoeff σ S) ↑ψ = f ((constantCoeff σ R) φ) this : IsUnit ((constantCoeff σ S) ↑ψ) ⊢ IsUnit φ
rw [h] at this
case intro σ : Type u_1 R : Type u_2 S : Type u_3 inst✝² : CommRing R inst✝¹ : CommRing S f : R →+* S inst✝ : IsLocalHom f φ : MvPowerSeries σ R ψ : (MvPowerSeries σ S)ˣ h : (constantCoeff σ S) ↑ψ = f ((constantCoeff σ R) φ) this : IsUnit (f ((constantCoeff σ R) φ)) ⊢ IsUnit φ
f085e8794e8de496
Topology.IsUpperSet.upperSet_le_upper
Mathlib/Topology/Order/UpperLowerSetTopology.lean
lemma upperSet_le_upper {t₁ t₂ : TopologicalSpace α} [@Topology.IsUpperSet α t₁ _] [@Topology.IsUpper α t₂ _] : t₁ ≤ t₂ := fun s hs => by rw [@isOpen_iff_isUpperSet α _ t₁] exact IsUpper.isUpperSet_of_isOpen hs
α : Type u_1 inst✝² : Preorder α t₁ t₂ : TopologicalSpace α inst✝¹ : Topology.IsUpperSet α inst✝ : IsUpper α s : Set α hs : IsOpen s ⊢ IsUpperSet s
exact IsUpper.isUpperSet_of_isOpen hs
no goals
acbfb9816d196487
CategoryTheory.Presheaf.isLocallyInjective_of_isLocallyInjective_of_isLocallySurjective
Mathlib/CategoryTheory/Sites/LocallySurjective.lean
lemma isLocallyInjective_of_isLocallyInjective_of_isLocallySurjective {F₁ F₂ F₃ : Cᵒᵖ ⥤ A} (f₁ : F₁ ⟶ F₂) (f₂ : F₂ ⟶ F₃) [IsLocallyInjective J (f₁ ≫ f₂)] [IsLocallySurjective J f₁] : IsLocallyInjective J f₂ where equalizerSieve_mem {X} x₁ x₂ h
case refine_2 C : Type u inst✝⁵ : Category.{v, u} C J : GrothendieckTopology C A : Type u' inst✝⁴ : Category.{v', u'} A FA : A → A → Type u_1 CA : A → Type w' inst✝³ : (X Y : A) → FunLike (FA X Y) (CA X) (CA Y) inst✝² : ConcreteCategory A FA F₁ F₂ F₃ : Cᵒᵖ ⥤ A f₁ : F₁ ⟶ F₂ f₂ : F₂ ⟶ F₃ inst✝¹ : IsLocallyInjective J (f₁ ≫ f₂) inst✝ : IsLocallySurjective J f₁ X : Cᵒᵖ x₁ x₂ : ToType (F₂.obj X) h : (ConcreteCategory.hom (f₂.app X)) x₁ = (ConcreteCategory.hom (f₂.app X)) x₂ S : Sieve (unop X) := imageSieve f₁ x₁ ⊓ imageSieve f₁ x₂ hS : S ∈ J (unop X) T : ⦃Y : C⦄ → (f : Y ⟶ unop X) → S.arrows f → Sieve Y := fun Y f hf => equalizerSieve (localPreimage f₁ x₁ f ⋯) (localPreimage f₁ x₂ f ⋯) Y : C f : Y ⟶ unop X hf : S.arrows f ⊢ Sieve.pullback f (Sieve.bind S.arrows T) ∈ J Y
apply J.superset_covering (Sieve.le_pullback_bind _ _ _ hf)
case refine_2 C : Type u inst✝⁵ : Category.{v, u} C J : GrothendieckTopology C A : Type u' inst✝⁴ : Category.{v', u'} A FA : A → A → Type u_1 CA : A → Type w' inst✝³ : (X Y : A) → FunLike (FA X Y) (CA X) (CA Y) inst✝² : ConcreteCategory A FA F₁ F₂ F₃ : Cᵒᵖ ⥤ A f₁ : F₁ ⟶ F₂ f₂ : F₂ ⟶ F₃ inst✝¹ : IsLocallyInjective J (f₁ ≫ f₂) inst✝ : IsLocallySurjective J f₁ X : Cᵒᵖ x₁ x₂ : ToType (F₂.obj X) h : (ConcreteCategory.hom (f₂.app X)) x₁ = (ConcreteCategory.hom (f₂.app X)) x₂ S : Sieve (unop X) := imageSieve f₁ x₁ ⊓ imageSieve f₁ x₂ hS : S ∈ J (unop X) T : ⦃Y : C⦄ → (f : Y ⟶ unop X) → S.arrows f → Sieve Y := fun Y f hf => equalizerSieve (localPreimage f₁ x₁ f ⋯) (localPreimage f₁ x₂ f ⋯) Y : C f : Y ⟶ unop X hf : S.arrows f ⊢ T f hf ∈ J Y
fb4794d97c93223f
Monotone.alternating_series_le_tendsto
Mathlib/Analysis/SpecificLimits/Normed.lean
theorem Monotone.alternating_series_le_tendsto (hfl : Tendsto (fun n ↦ ∑ i ∈ range n, (-1) ^ i * f i) atTop (𝓝 l)) (hfm : Monotone f) (k : ℕ) : ∑ i ∈ range (2 * k + 1), (-1) ^ i * f i ≤ l
E : Type u_2 inst✝² : OrderedRing E inst✝¹ : TopologicalSpace E inst✝ : OrderClosedTopology E l : E f : ℕ → E hfl : Tendsto (fun n => ∑ i ∈ Finset.range n, (-1) ^ i * f i) atTop (𝓝 l) hfm : Monotone f k : ℕ ⊢ Monotone fun n => ∑ i ∈ Finset.range (2 * n + 1), (-1) ^ i * f i
refine monotone_nat_of_le_succ (fun n ↦ ?_)
E : Type u_2 inst✝² : OrderedRing E inst✝¹ : TopologicalSpace E inst✝ : OrderClosedTopology E l : E f : ℕ → E hfl : Tendsto (fun n => ∑ i ∈ Finset.range n, (-1) ^ i * f i) atTop (𝓝 l) hfm : Monotone f k n : ℕ ⊢ ∑ i ∈ Finset.range (2 * n + 1), (-1) ^ i * f i ≤ ∑ i ∈ Finset.range (2 * (n + 1) + 1), (-1) ^ i * f i
2a7dbce5730e93a1
Module.finitePresentation_of_ker
Mathlib/Algebra/Module/FinitePresentation.lean
lemma Module.finitePresentation_of_ker [Module.FinitePresentation R N] (l : M →ₗ[R] N) (hl : Function.Surjective l) [Module.FinitePresentation R (LinearMap.ker l)] : Module.FinitePresentation R M
case intro R : Type u_1 M : Type u_3 N : Type u_2 inst✝⁶ : Ring R inst✝⁵ : AddCommGroup M inst✝⁴ : Module R M inst✝³ : AddCommGroup N inst✝² : Module R N inst✝¹ : FinitePresentation R N l : M →ₗ[R] N hl : Function.Surjective ⇑l inst✝ : FinitePresentation R ↥(LinearMap.ker l) s : Finset M hs : Submodule.span R ↑s = ⊤ ⊢ FinitePresentation R M
refine ⟨s, hs, ?_⟩
case intro R : Type u_1 M : Type u_3 N : Type u_2 inst✝⁶ : Ring R inst✝⁵ : AddCommGroup M inst✝⁴ : Module R M inst✝³ : AddCommGroup N inst✝² : Module R N inst✝¹ : FinitePresentation R N l : M →ₗ[R] N hl : Function.Surjective ⇑l inst✝ : FinitePresentation R ↥(LinearMap.ker l) s : Finset M hs : Submodule.span R ↑s = ⊤ ⊢ (LinearMap.ker (linearCombination R Subtype.val)).FG
888cd3f368652bf6
LieModule.eventually_genWeightSpace_smul_add_eq_bot
Mathlib/Algebra/Lie/Weights/Chain.lean
lemma eventually_genWeightSpace_smul_add_eq_bot : ∀ᶠ (k : ℕ) in Filter.atTop, genWeightSpace M (k • χ₁ + χ₂) = ⊥
R : Type u_1 L : Type u_2 inst✝¹⁰ : CommRing R inst✝⁹ : LieRing L inst✝⁸ : LieAlgebra R L M : Type u_3 inst✝⁷ : AddCommGroup M inst✝⁶ : Module R M inst✝⁵ : LieRingModule L M inst✝⁴ : LieModule R L M inst✝³ : LieRing.IsNilpotent L χ₁ χ₂ : L → R inst✝² : NoZeroSMulDivisors ℤ R inst✝¹ : NoZeroSMulDivisors R M inst✝ : IsNoetherian R M hχ₁ : χ₁ ≠ 0 f : ℕ → L → R := fun k => k • χ₁ + χ₂ this : Function.Injective f ⊢ (f '' {x | ¬genWeightSpace M (x • χ₁ + χ₂) = ⊥}).Finite
apply (finite_genWeightSpace_ne_bot R L M).subset
R : Type u_1 L : Type u_2 inst✝¹⁰ : CommRing R inst✝⁹ : LieRing L inst✝⁸ : LieAlgebra R L M : Type u_3 inst✝⁷ : AddCommGroup M inst✝⁶ : Module R M inst✝⁵ : LieRingModule L M inst✝⁴ : LieModule R L M inst✝³ : LieRing.IsNilpotent L χ₁ χ₂ : L → R inst✝² : NoZeroSMulDivisors ℤ R inst✝¹ : NoZeroSMulDivisors R M inst✝ : IsNoetherian R M hχ₁ : χ₁ ≠ 0 f : ℕ → L → R := fun k => k • χ₁ + χ₂ this : Function.Injective f ⊢ f '' {x | ¬genWeightSpace M (x • χ₁ + χ₂) = ⊥} ⊆ {χ | genWeightSpace M χ ≠ ⊥}
ce52027cc0acda70
CPolynomialOn.fderiv
Mathlib/Analysis/Calculus/FDeriv/Analytic.lean
theorem CPolynomialOn.fderiv (h : CPolynomialOn 𝕜 f s) : CPolynomialOn 𝕜 (fderiv 𝕜 f) s
𝕜 : Type u_1 inst✝⁴ : NontriviallyNormedField 𝕜 E : Type u inst✝³ : NormedAddCommGroup E inst✝² : NormedSpace 𝕜 E F : Type v inst✝¹ : NormedAddCommGroup F inst✝ : NormedSpace 𝕜 F f : E → F s : Set E h : CPolynomialOn 𝕜 f s ⊢ CPolynomialOn 𝕜 (_root_.fderiv 𝕜 f) s
intro y hy
𝕜 : Type u_1 inst✝⁴ : NontriviallyNormedField 𝕜 E : Type u inst✝³ : NormedAddCommGroup E inst✝² : NormedSpace 𝕜 E F : Type v inst✝¹ : NormedAddCommGroup F inst✝ : NormedSpace 𝕜 F f : E → F s : Set E h : CPolynomialOn 𝕜 f s y : E hy : y ∈ s ⊢ CPolynomialAt 𝕜 (_root_.fderiv 𝕜 f) y
fe76f93d74149110
CategoryTheory.NatTrans.CommShift.of_isIso
Mathlib/CategoryTheory/Shift/CommShift.lean
lemma of_isIso [IsIso τ] [NatTrans.CommShift τ A] : NatTrans.CommShift (inv τ) A
C : Type u_1 D : Type u_2 inst✝⁸ : Category.{u_7, u_1} C inst✝⁷ : Category.{u_6, u_2} D F₁ F₂ : C ⥤ D τ : F₁ ⟶ F₂ A : Type u_5 inst✝⁶ : AddMonoid A inst✝⁵ : HasShift C A inst✝⁴ : HasShift D A inst✝³ : F₁.CommShift A inst✝² : F₂.CommShift A inst✝¹ : IsIso τ inst✝ : CommShift τ A ⊢ CommShift (inv τ) A
haveI : NatTrans.CommShift (asIso τ).hom A := by assumption
C : Type u_1 D : Type u_2 inst✝⁸ : Category.{u_7, u_1} C inst✝⁷ : Category.{u_6, u_2} D F₁ F₂ : C ⥤ D τ : F₁ ⟶ F₂ A : Type u_5 inst✝⁶ : AddMonoid A inst✝⁵ : HasShift C A inst✝⁴ : HasShift D A inst✝³ : F₁.CommShift A inst✝² : F₂.CommShift A inst✝¹ : IsIso τ inst✝ : CommShift τ A this : CommShift (asIso τ).hom A ⊢ CommShift (inv τ) A
d35da6153719fb9d
ContinuousMap.sup_mem_closed_subalgebra
Mathlib/Topology/ContinuousMap/StoneWeierstrass.lean
theorem sup_mem_closed_subalgebra (A : Subalgebra ℝ C(X, ℝ)) (h : IsClosed (A : Set C(X, ℝ))) (f g : A) : (f : C(X, ℝ)) ⊔ (g : C(X, ℝ)) ∈ A
case h.e'_4 X : Type u_1 inst✝¹ : TopologicalSpace X inst✝ : CompactSpace X A : Subalgebra ℝ C(X, ℝ) h : IsClosed ↑A f g : ↥A ⊢ A = A.topologicalClosure
apply SetLike.ext'
case h.e'_4.h X : Type u_1 inst✝¹ : TopologicalSpace X inst✝ : CompactSpace X A : Subalgebra ℝ C(X, ℝ) h : IsClosed ↑A f g : ↥A ⊢ ↑A = ↑A.topologicalClosure
1e1c647738699fd7
AkraBazziRecurrence.eventually_atTop_sumTransform_ge
Mathlib/Computability/AkraBazzi/AkraBazzi.lean
lemma eventually_atTop_sumTransform_ge : ∃ c > 0, ∀ᶠ (n : ℕ) in atTop, ∀ i, c * g n ≤ sumTransform (p a b) g (r i n) n
α : Type u_1 inst✝¹ : Fintype α T : ℕ → ℝ g : ℝ → ℝ a b : α → ℝ r : α → ℕ → ℕ inst✝ : Nonempty α R : AkraBazziRecurrence T g a b r c₁ : ℝ hc₁_mem : c₁ ∈ Set.Ioo 0 1 hc₁ : ∀ᶠ (n : ℕ) in atTop, ∀ (i : α), c₁ * ↑n ≤ ↑(r i n) c₂ : ℝ hc₂_mem : c₂ > 0 hc₂ : ∀ᶠ (n : ℕ) in atTop, ∀ u ∈ Set.Icc (c₁ * ↑n) ↑n, c₂ * g ↑n ≤ g u c₃ : ℝ hc₃_mem : c₃ ∈ Set.Ioo 0 1 hc₃ : ∀ᶠ (n : ℕ) in atTop, ∀ (i : α), ↑(r i n) ≤ c₃ * ↑n hc₁_pos : 0 < c₁ hc₃' : 0 < 1 - c₃ n : ℕ hn₁ : ∀ (i : α), c₁ * ↑n ≤ ↑(r i n) hn₂ : ∀ u ∈ Set.Icc (c₁ * ↑n) ↑n, c₂ * g ↑n ≤ g u hn₃ : ∀ (i : α), ↑(r i n) ≤ c₃ * ↑n hrpos : ∀ (i : α), 0 < r i n hr_lt_n : ∀ (i : α), r i n < n hn_pos : 0 < n i : α hrpos_i : 0 < r i n g_nonneg : 0 ≤ g ↑n hp : 0 > p a b + 1 ⊢ 0 ≤ c₁
positivity
no goals
aff66f2e59f80837
RingHom.locally_iff_isLocalization
Mathlib/RingTheory/RingHom/Locally.lean
/-- In the definition of `Locally` we may replace `Localization.Away` with an arbitrary algebra satisfying `IsLocalization.Away`. -/ lemma locally_iff_isLocalization (hP : RespectsIso P) (f : R →+* S) : Locally P f ↔ ∃ (s : Finset S) (_ : Ideal.span (s : Set S) = ⊤), ∀ t ∈ s, ∀ (Sₜ : Type u) [CommRing Sₜ] [Algebra S Sₜ] [IsLocalization.Away t Sₜ], P ((algebraMap S Sₜ).comp f)
case refine_1 P : {R S : Type u} → [inst : CommRing R] → [inst_1 : CommRing S] → (R →+* S) → Prop R S : Type u inst✝¹ : CommRing R inst✝ : CommRing S hP : RespectsIso fun {R S} [CommRing R] [CommRing S] => P f : R →+* S x✝³ : ∃ s, ∃ (_ : Ideal.span ↑s = ⊤), ∀ t ∈ s, P ((algebraMap S (Localization.Away t)).comp f) s : Finset S hsone : Ideal.span ↑s = ⊤ hs : ∀ t ∈ s, P ((algebraMap S (Localization.Away t)).comp f) t : S ht : t ∈ s Sₜ : Type u x✝² : CommRing Sₜ x✝¹ : Algebra S Sₜ x✝ : IsLocalization.Away t Sₜ e : Localization.Away t ≃+* Sₜ := (IsLocalization.algEquiv (Submonoid.powers t) (Localization.Away t) Sₜ).toRingEquiv ⊢ P ((algebraMap S Sₜ).comp f)
have : algebraMap S Sₜ = e.toRingHom.comp (algebraMap S (Localization.Away t)) := RingHom.ext (fun x ↦ (AlgEquiv.commutes (IsLocalization.algEquiv _ _ _) _).symm)
case refine_1 P : {R S : Type u} → [inst : CommRing R] → [inst_1 : CommRing S] → (R →+* S) → Prop R S : Type u inst✝¹ : CommRing R inst✝ : CommRing S hP : RespectsIso fun {R S} [CommRing R] [CommRing S] => P f : R →+* S x✝³ : ∃ s, ∃ (_ : Ideal.span ↑s = ⊤), ∀ t ∈ s, P ((algebraMap S (Localization.Away t)).comp f) s : Finset S hsone : Ideal.span ↑s = ⊤ hs : ∀ t ∈ s, P ((algebraMap S (Localization.Away t)).comp f) t : S ht : t ∈ s Sₜ : Type u x✝² : CommRing Sₜ x✝¹ : Algebra S Sₜ x✝ : IsLocalization.Away t Sₜ e : Localization.Away t ≃+* Sₜ := (IsLocalization.algEquiv (Submonoid.powers t) (Localization.Away t) Sₜ).toRingEquiv this : algebraMap S Sₜ = e.toRingHom.comp (algebraMap S (Localization.Away t)) ⊢ P ((algebraMap S Sₜ).comp f)
48f562d83319536b
Ideal.span_pow_eq_top
Mathlib/RingTheory/Ideal/Basic.lean
theorem span_pow_eq_top (s : Set α) (hs : span s = ⊤) (n : ℕ) : span ((fun (x : α) => x ^ n) '' s) = ⊤
case zero.inl α : Type u_2 inst✝ : CommSemiring α hs : span ∅ = ⊤ ⊢ 1 ∈ span ((fun x => x ^ 0) '' ∅)
rw [Set.image_empty, hs]
case zero.inl α : Type u_2 inst✝ : CommSemiring α hs : span ∅ = ⊤ ⊢ 1 ∈ ⊤
dd88b6d68cbdbab3
AddCircle.scaled_exp_map_periodic
Mathlib/Analysis/SpecialFunctions/Complex/Circle.lean
theorem scaled_exp_map_periodic : Function.Periodic (fun x => Circle.exp (2 * π / T * x)) T
T : ℝ ⊢ Periodic (fun x => Circle.exp (2 * π / T * x)) T
rcases eq_or_ne T 0 with (rfl | hT)
case inl ⊢ Periodic (fun x => Circle.exp (2 * π / 0 * x)) 0 case inr T : ℝ hT : T ≠ 0 ⊢ Periodic (fun x => Circle.exp (2 * π / T * x)) T
27ec239a7d4a816a
Real.toNNReal_eq_nnnorm_of_nonneg
Mathlib/Analysis/Normed/Group/Basic.lean
theorem toNNReal_eq_nnnorm_of_nonneg (hr : 0 ≤ r) : r.toNNReal = ‖r‖₊
case a r : ℝ hr : 0 ≤ r ⊢ ↑⟨r, hr⟩ = ↑‖r‖₊
rw [coe_mk, coe_nnnorm r, Real.norm_eq_abs r, abs_of_nonneg hr]
no goals
edbd0a0d12ba3801
MulChar.IsQuadratic.pow_char
Mathlib/NumberTheory/MulChar/Basic.lean
theorem IsQuadratic.pow_char {χ : MulChar R R'} (hχ : χ.IsQuadratic) (p : ℕ) [hp : Fact p.Prime] [CharP R' p] : χ ^ p = χ
case h.inr.inl R : Type u_1 inst✝² : CommMonoid R R' : Type u_2 inst✝¹ : CommRing R' χ : MulChar R R' hχ : χ.IsQuadratic p : ℕ hp : Fact (Nat.Prime p) inst✝ : CharP R' p x : Rˣ hx : χ ↑x = 1 ⊢ 1 ^ p = 1
rw [one_pow]
no goals
d7819318bd3ad273
Algebra.FormallyUnramified.ext_of_iInf
Mathlib/RingTheory/Unramified/Basic.lean
theorem ext_of_iInf [FormallyUnramified R A] (hI : ⨅ i, I ^ i = ⊥) {g₁ g₂ : A →ₐ[R] B} (H : ∀ x, Ideal.Quotient.mk I (g₁ x) = Ideal.Quotient.mk I (g₂ x)) : g₁ = g₂
case pos R : Type v inst✝⁵ : CommRing R A : Type u inst✝⁴ : CommRing A inst✝³ : Algebra R A B : Type w inst✝² : CommRing B inst✝¹ : Algebra R B I : Ideal B inst✝ : FormallyUnramified R A hI : ⨅ i, I ^ i = ⊥ g₁ g₂ : A →ₐ[R] B H : ∀ (x : A), (Ideal.Quotient.mk I) (g₁ x) = (Ideal.Quotient.mk I) (g₂ x) i : ℕ hi : i = 0 ⊢ (Ideal.Quotient.mkₐ R (I ^ i)).comp g₁ = (Ideal.Quotient.mkₐ R (I ^ i)).comp g₂
ext x
case pos.H R : Type v inst✝⁵ : CommRing R A : Type u inst✝⁴ : CommRing A inst✝³ : Algebra R A B : Type w inst✝² : CommRing B inst✝¹ : Algebra R B I : Ideal B inst✝ : FormallyUnramified R A hI : ⨅ i, I ^ i = ⊥ g₁ g₂ : A →ₐ[R] B H : ∀ (x : A), (Ideal.Quotient.mk I) (g₁ x) = (Ideal.Quotient.mk I) (g₂ x) i : ℕ hi : i = 0 x : A ⊢ ((Ideal.Quotient.mkₐ R (I ^ i)).comp g₁) x = ((Ideal.Quotient.mkₐ R (I ^ i)).comp g₂) x
18929210cec07ffd
MeasureTheory.pow_mul_meas_ge_le_eLpNorm
Mathlib/MeasureTheory/Function/LpSeminorm/ChebyshevMarkov.lean
theorem pow_mul_meas_ge_le_eLpNorm (hp_ne_zero : p ≠ 0) (hp_ne_top : p ≠ ∞) (hf : AEStronglyMeasurable f μ) (ε : ℝ≥0∞) : (ε * μ { x | ε ≤ (‖f x‖₊ : ℝ≥0∞) ^ p.toReal }) ^ (1 / p.toReal) ≤ eLpNorm f p μ
case h₁ α : Type u_1 E : Type u_2 m0 : MeasurableSpace α inst✝ : NormedAddCommGroup E p : ℝ≥0∞ μ : Measure α f : α → E hp_ne_zero : p ≠ 0 hp_ne_top : p ≠ ⊤ hf : AEStronglyMeasurable f μ ε : ℝ≥0∞ ⊢ ε * μ {x | ε ≤ ↑‖f x‖₊ ^ p.toReal} ≤ ∫⁻ (x : α), ‖f x‖ₑ ^ p.toReal ∂μ
exact mul_meas_ge_le_lintegral₀ (hf.enorm.pow_const _) ε
no goals
2fe447c04e0f4a71
Nat.digits_add
Mathlib/Data/Nat/Digits.lean
theorem digits_add (b : ℕ) (h : 1 < b) (x y : ℕ) (hxb : x < b) (hxy : x ≠ 0 ∨ y ≠ 0) : digits b (x + b * y) = x :: digits b y
case intro.succ.e_head x b : ℕ h : 1 < b + 2 hxb : x < b + 2 n✝ : ℕ hxy : x ≠ 0 ∨ n✝ + 1 ≠ 0 ⊢ (x + (b + 2) * (n✝ + 1)) % (b + 2) = x
simp [Nat.add_mod, mod_eq_of_lt hxb]
no goals
5707ca6647bd00ed
Stream.take_eq_takeTR
Mathlib/.lake/packages/batteries/Batteries/Data/Stream.lean
theorem take_eq_takeTR : @take = @takeTR
case h.h.h.h.h.snd x✝⁴ : Type u_2 x✝³ : Type u_1 x✝² : Stream x✝⁴ x✝³ x✝¹ : x✝⁴ x✝ : Nat ⊢ (take x✝¹ x✝).snd = (takeTR x✝¹ x✝).snd
rw [snd_takeTR, snd_take_eq_drop]
no goals
cbdb14a1a0777cbf
List.mapIdx_reverse
Mathlib/.lake/packages/lean4/src/lean/Init/Data/List/MapIdx.lean
theorem mapIdx_reverse {l : List α} {f : Nat → α → β} : l.reverse.mapIdx f = (mapIdx (fun i => f (l.length - 1 - i)) l).reverse
α : Type u_1 β : Type u_2 l : List α f : Nat → α → β i : Nat ⊢ (mapIdx (fun i => f (l.length - 1 - i)) l).reverse[i]? = Option.map (f i) l.reverse[i]?
by_cases h : i < l.length
case pos α : Type u_1 β : Type u_2 l : List α f : Nat → α → β i : Nat h : i < l.length ⊢ (mapIdx (fun i => f (l.length - 1 - i)) l).reverse[i]? = Option.map (f i) l.reverse[i]? case neg α : Type u_1 β : Type u_2 l : List α f : Nat → α → β i : Nat h : ¬i < l.length ⊢ (mapIdx (fun i => f (l.length - 1 - i)) l).reverse[i]? = Option.map (f i) l.reverse[i]?
8086284ec8908f69
isMeagre_iff_countable_union_isNowhereDense
Mathlib/Topology/GDelta/Basic.lean
/-- A set is meagre iff it is contained in a countable union of nowhere dense sets. -/ lemma isMeagre_iff_countable_union_isNowhereDense {s : Set X} : IsMeagre s ↔ ∃ S : Set (Set X), (∀ t ∈ S, IsNowhereDense t) ∧ S.Countable ∧ s ⊆ ⋃₀ S
case refine_2 X : Type u_5 inst✝ : TopologicalSpace X s : Set X ⊢ (∃ S, (∀ t ∈ S, IsNowhereDense t) ∧ S.Countable ∧ s ⊆ ⋃₀ S) → ∃ x, (∀ ⦃x_1 : Set X⦄, x_1 ∈ x → IsClosed x_1 ∧ IsNowhereDense x_1) ∧ (compl '' x).Countable ∧ s ⊆ ⋃₀ x
intro ⟨S, hS, hc, hsub⟩
case refine_2 X : Type u_5 inst✝ : TopologicalSpace X s : Set X S : Set (Set X) hS : ∀ t ∈ S, IsNowhereDense t hc : S.Countable hsub : s ⊆ ⋃₀ S ⊢ ∃ x, (∀ ⦃x_1 : Set X⦄, x_1 ∈ x → IsClosed x_1 ∧ IsNowhereDense x_1) ∧ (compl '' x).Countable ∧ s ⊆ ⋃₀ x
bee0252956d68792
BooleanSubalgebra.map_symm_eq_iff_eq_map
Mathlib/Order/BooleanSubalgebra.lean
lemma map_symm_eq_iff_eq_map {M : BooleanSubalgebra β} {e : β ≃o α} : L.map ↑e.symm = M ↔ L = M.map ↑e
α : Type u_2 β : Type u_3 inst✝¹ : BooleanAlgebra α inst✝ : BooleanAlgebra β L : BooleanSubalgebra α M : BooleanSubalgebra β e : β ≃o α ⊢ ↑(map { toFun := ⇑e.symm, map_sup' := ⋯, map_inf' := ⋯, map_top' := ⋯, map_bot' := ⋯ } L) = ↑M ↔ ↑L = ↑(map { toFun := ⇑e, map_sup' := ⋯, map_inf' := ⋯, map_top' := ⋯, map_bot' := ⋯ } M)
exact (Equiv.eq_image_iff_symm_image_eq _ _ _).symm
no goals
d4990c54f7f4a9cc
SimpleGraph.edgeDisjointTriangles_iff_mem_sym2_subsingleton
Mathlib/Combinatorics/SimpleGraph/Triangle/Basic.lean
lemma edgeDisjointTriangles_iff_mem_sym2_subsingleton : G.EdgeDisjointTriangles ↔ ∀ ⦃e : Sym2 α⦄, ¬ e.IsDiag → {s ∈ G.cliqueSet 3 | e ∈ (s : Finset α).sym2}.Subsingleton
case h.mp.intro.intro.intro.intro.intro.intro.intro.intro.inr.inr.inl α : Type u_1 G : SimpleGraph α a b : α hab : ¬a = b d : α hcd : G.Adj b d hde : G.Adj a d hce : G.Adj a b ⊢ ∃ c, G.Adj a c ∧ G.Adj b c ∧ {b, d, a} = {a, b, c}
exact ⟨d, by aesop⟩
no goals
dd5ab32164f7deff
groupCohomology.cochainsMap_f_map_mono
Mathlib/RepresentationTheory/GroupCohomology/Functoriality.lean
lemma cochainsMap_f_map_mono (hf : Function.Surjective f) [Mono φ] (i : ℕ) : Mono ((cochainsMap f φ).f i)
k G H : Type u inst✝³ : CommRing k inst✝² : Group G inst✝¹ : Group H A : Rep k H B : Rep k G f : G →* H φ : (Action.res (ModuleCat k) f).obj A ⟶ B hf : Function.Surjective ⇑f inst✝ : Mono φ i : ℕ ⊢ Mono ((cochainsMap f φ).f i)
simpa [ModuleCat.mono_iff_injective] using ((Rep.mono_iff_injective φ).1 inferInstance).comp_left.comp <| LinearMap.funLeft_injective_of_surjective k A _ hf.comp_left
no goals
e4c1b9c4ec35a7ae
LinearMap.ker_eq_bot_range_liftQ_iff
Mathlib/Algebra/Exact.lean
lemma ker_eq_bot_range_liftQ_iff (h : range f ≤ ker g) : ker ((range f).liftQ g h) = ⊥ ↔ ker g = range f
R : Type u_1 M : Type u_2 N : Type u_4 P : Type u_6 inst✝⁶ : Ring R inst✝⁵ : AddCommGroup M inst✝⁴ : AddCommGroup N inst✝³ : AddCommGroup P inst✝² : Module R M inst✝¹ : Module R N inst✝ : Module R P f : M →ₗ[R] N g : N →ₗ[R] P h : range f ≤ ker g ⊢ (∀ (x : N ⧸ range f), ((range f).liftQ g h) x = 0 ↔ x = 0) ↔ ∀ (x : N), g x = 0 ↔ ∃ y, f y = x
constructor
case mp R : Type u_1 M : Type u_2 N : Type u_4 P : Type u_6 inst✝⁶ : Ring R inst✝⁵ : AddCommGroup M inst✝⁴ : AddCommGroup N inst✝³ : AddCommGroup P inst✝² : Module R M inst✝¹ : Module R N inst✝ : Module R P f : M →ₗ[R] N g : N →ₗ[R] P h : range f ≤ ker g ⊢ (∀ (x : N ⧸ range f), ((range f).liftQ g h) x = 0 ↔ x = 0) → ∀ (x : N), g x = 0 ↔ ∃ y, f y = x case mpr R : Type u_1 M : Type u_2 N : Type u_4 P : Type u_6 inst✝⁶ : Ring R inst✝⁵ : AddCommGroup M inst✝⁴ : AddCommGroup N inst✝³ : AddCommGroup P inst✝² : Module R M inst✝¹ : Module R N inst✝ : Module R P f : M →ₗ[R] N g : N →ₗ[R] P h : range f ≤ ker g ⊢ (∀ (x : N), g x = 0 ↔ ∃ y, f y = x) → ∀ (x : N ⧸ range f), ((range f).liftQ g h) x = 0 ↔ x = 0
d991d6866470e4a6
Set.encard_eq_three
Mathlib/Data/Set/Card.lean
theorem encard_eq_three {α : Type u_1} {s : Set α} : encard s = 3 ↔ ∃ x y z, x ≠ y ∧ x ≠ z ∧ y ≠ z ∧ s = {x, y, z}
α : Type u_1 s : Set α ⊢ s.encard = 3 ↔ ∃ x y z, x ≠ y ∧ x ≠ z ∧ y ≠ z ∧ s = {x, y, z}
refine ⟨fun h ↦ ?_, fun ⟨x, y, z, hxy, hyz, hxz, hs⟩ ↦ ?_⟩
case refine_1 α : Type u_1 s : Set α h : s.encard = 3 ⊢ ∃ x y z, x ≠ y ∧ x ≠ z ∧ y ≠ z ∧ s = {x, y, z} case refine_2 α : Type u_1 s : Set α x✝ : ∃ x y z, x ≠ y ∧ x ≠ z ∧ y ≠ z ∧ s = {x, y, z} x y z : α hxy : x ≠ y hyz : x ≠ z hxz : y ≠ z hs : s = {x, y, z} ⊢ s.encard = 3
f3917f7e0cd671ea
CircleDeg1Lift.units_apply_inv_apply
Mathlib/Dynamics/Circle/RotationNumber/TranslationNumber.lean
theorem units_apply_inv_apply (f : CircleDeg1Liftˣ) (x : ℝ) : f ((f⁻¹ : CircleDeg1Liftˣ) x) = x
f : CircleDeg1Liftˣ x : ℝ ⊢ ↑f (↑f⁻¹ x) = x
simp only [← mul_apply, f.mul_inv, coe_one, id]
no goals
acac1f7bb9848a5c
HahnSeries.order_single_mul_of_isRegular
Mathlib/RingTheory/HahnSeries/Multiplication.lean
theorem order_single_mul_of_isRegular {g : Γ} {r : R} (hr : IsRegular r) {x : HahnSeries Γ R} (hx : x ≠ 0) : (((single g) r) * x).order = g + x.order
R : Type u_3 Γ : Type u_6 inst✝¹ : LinearOrderedCancelAddCommMonoid Γ inst✝ : NonUnitalNonAssocSemiring R g : Γ r : R hr : IsRegular r x : HahnSeries Γ R hx : x ≠ 0 h✝ : Nontrivial R ⊢ ((single g) r).leadingCoeff * x.leadingCoeff ≠ 0
rwa [leadingCoeff_of_single, ne_eq, hr.left.mul_left_eq_zero_iff, leadingCoeff_eq_iff]
no goals
fd006c7f15ff647b
NumberField.InfinitePlace.ComplexEmbedding.exists_comp_symm_eq_of_comp_eq
Mathlib/NumberTheory/NumberField/Embeddings.lean
lemma ComplexEmbedding.exists_comp_symm_eq_of_comp_eq [IsGalois k K] (φ ψ : K →+* ℂ) (h : φ.comp (algebraMap k K) = ψ.comp (algebraMap k K)) : ∃ σ : K ≃ₐ[k] K, φ.comp σ.symm = ψ
k : Type u_1 inst✝³ : Field k K : Type u_2 inst✝² : Field K inst✝¹ : Algebra k K inst✝ : IsGalois k K φ ψ : K →+* ℂ h : φ.comp (algebraMap k K) = ψ.comp (algebraMap k K) this✝¹ : Algebra k ℂ := (φ.comp (algebraMap k K)).toAlgebra this✝ : Algebra K ℂ := φ.toAlgebra this : IsScalarTower k K ℂ ψ' : K →ₐ[k] ℂ := { toRingHom := ψ, commutes' := ⋯ } ⊢ ∃ σ, φ.comp ↑σ.symm = ψ
use (AlgHom.restrictNormal' ψ' K).symm
case h k : Type u_1 inst✝³ : Field k K : Type u_2 inst✝² : Field K inst✝¹ : Algebra k K inst✝ : IsGalois k K φ ψ : K →+* ℂ h : φ.comp (algebraMap k K) = ψ.comp (algebraMap k K) this✝¹ : Algebra k ℂ := (φ.comp (algebraMap k K)).toAlgebra this✝ : Algebra K ℂ := φ.toAlgebra this : IsScalarTower k K ℂ ψ' : K →ₐ[k] ℂ := { toRingHom := ψ, commutes' := ⋯ } ⊢ φ.comp ↑(ψ'.restrictNormal' K).symm.symm = ψ
912b9e2017d03fa6
bernoulliFourierCoeff_eq
Mathlib/NumberTheory/ZetaValues.lean
theorem bernoulliFourierCoeff_eq {k : ℕ} (hk : k ≠ 0) (n : ℤ) : bernoulliFourierCoeff k n = -k ! / (2 * π * I * n) ^ k
case neg k✝ : ℕ hk✝ : k✝ ≠ 0 n : ℤ hn : n ≠ 0 k : ℕ hk : 1 ≤ k h'k : bernoulliFourierCoeff k n = -↑k ! / (2 * ↑π * I * ↑n) ^ k h : ¬k + 1 = 1 ⊢ -((↑k + 1) * ↑k !) / (2 * ↑π * I * ↑n * (2 * ↑π * I * ↑n) ^ k) = -((↑k + 1) * ↑k !) / ((2 * ↑π * I * ↑n) ^ k * (2 * ↑π * I * ↑n))
ring_nf
no goals
71b5051efe4665bf
spectrum.hasFPowerSeriesOnBall_inverse_one_sub_smul
Mathlib/Analysis/Normed/Algebra/Spectrum.lean
theorem hasFPowerSeriesOnBall_inverse_one_sub_smul [HasSummableGeomSeries A] (a : A) : HasFPowerSeriesOnBall (fun z : 𝕜 => Ring.inverse (1 - z • a)) (fun n => ContinuousMultilinearMap.mkPiRing 𝕜 (Fin n) (a ^ n)) 0 ‖a‖₊⁻¹ := { r_le
𝕜 : Type u_1 A : Type u_2 inst✝³ : NontriviallyNormedField 𝕜 inst✝² : NormedRing A inst✝¹ : NormedAlgebra 𝕜 A inst✝ : HasSummableGeomSeries A a : A y : 𝕜 hy : y ∈ EMetric.ball 0 (↑‖a‖₊)⁻¹ h : ¬‖a‖₊ = 0 ⊢ ‖y‖₊ < ‖a‖₊⁻¹
simpa only [← coe_inv h, mem_ball_zero_iff, Metric.emetric_ball_nnreal] using hy
no goals
040a66281ae63253
CategoryTheory.MonoidalCategory.tensorμ_tensorδ
Mathlib/CategoryTheory/Monoidal/Braided/Basic.lean
@[reassoc (attr := simp)] lemma tensorμ_tensorδ (X₁ X₂ Y₁ Y₂ : C) : tensorμ X₁ X₂ Y₁ Y₂ ≫ tensorδ X₁ X₂ Y₁ Y₂ = 𝟙 _
C : Type u₁ inst✝² : Category.{v₁, u₁} C inst✝¹ : MonoidalCategory C inst✝ : BraidedCategory C X₁ X₂ Y₁ Y₂ : C ⊢ tensorμ X₁ X₂ Y₁ Y₂ ≫ tensorδ X₁ X₂ Y₁ Y₂ = 𝟙 ((X₁ ⊗ X₂) ⊗ Y₁ ⊗ Y₂)
simp only [tensorμ, tensorδ, assoc, Iso.inv_hom_id_assoc, ← MonoidalCategory.whiskerLeft_comp_assoc, Iso.hom_inv_id_assoc, hom_inv_whiskerRight_assoc, Iso.hom_inv_id, Iso.inv_hom_id, MonoidalCategory.whiskerLeft_id, id_comp]
no goals
20f8ae0ec88ed79a
MeasureTheory.Measure.add_comp'
Mathlib/Probability/Kernel/Composition/MeasureComp.lean
/-- Same as `add_comp` except that it uses `⇑κ + ⇑η` instead of `⇑(κ + η)` in order to have a simp-normal form on the left of the equality. -/ @[simp] lemma add_comp' : (⇑κ + ⇑η) ∘ₘ μ = κ ∘ₘ μ + η ∘ₘ μ
α : Type u_1 β : Type u_2 mα : MeasurableSpace α mβ : MeasurableSpace β μ : Measure α κ η : Kernel α β ⊢ (⇑κ + ⇑η) ∘ₘ μ = ⇑κ ∘ₘ μ + ⇑η ∘ₘ μ
rw [← Kernel.coe_add, add_comp]
no goals
843a18552080baea
MultilinearMap.mkPiRing_eq_iff
Mathlib/LinearAlgebra/Multilinear/Basic.lean
theorem mkPiRing_eq_iff [Fintype ι] {z₁ z₂ : M₂} : MultilinearMap.mkPiRing R ι z₁ = MultilinearMap.mkPiRing R ι z₂ ↔ z₁ = z₂
R : Type uR ι : Type uι M₂ : Type v₂ inst✝³ : CommSemiring R inst✝² : AddCommMonoid M₂ inst✝¹ : Module R M₂ inst✝ : Fintype ι z₁ z₂ : M₂ ⊢ (∀ (x : ι → R), (∏ i : ι, x i) • z₁ = (∏ i : ι, x i) • z₂) ↔ z₁ = z₂
constructor <;> intro h
case mp R : Type uR ι : Type uι M₂ : Type v₂ inst✝³ : CommSemiring R inst✝² : AddCommMonoid M₂ inst✝¹ : Module R M₂ inst✝ : Fintype ι z₁ z₂ : M₂ h : ∀ (x : ι → R), (∏ i : ι, x i) • z₁ = (∏ i : ι, x i) • z₂ ⊢ z₁ = z₂ case mpr R : Type uR ι : Type uι M₂ : Type v₂ inst✝³ : CommSemiring R inst✝² : AddCommMonoid M₂ inst✝¹ : Module R M₂ inst✝ : Fintype ι z₁ z₂ : M₂ h : z₁ = z₂ ⊢ ∀ (x : ι → R), (∏ i : ι, x i) • z₁ = (∏ i : ι, x i) • z₂
e91bf17c3f81d970
Std.Sat.AIG.RefVec.ite.go_get_aux
Mathlib/.lake/packages/lean4/src/lean/Std/Sat/AIG/If.lean
theorem go_get_aux {w : Nat} (aig : AIG α) (curr : Nat) (hcurr : curr ≤ w) (discr : Ref aig) (lhs rhs : RefVec aig w) (s : RefVec aig curr) : ∀ (idx : Nat) (hidx : idx < curr) (hfoo), (go aig curr hcurr discr lhs rhs s).vec.get idx (by omega) = (s.get idx hidx).cast hfoo
α : Type inst✝¹ : Hashable α inst✝ : DecidableEq α w : Nat aig : AIG α curr : Nat hcurr : curr ≤ w discr : aig.Ref lhs rhs : aig.RefVec w s : aig.RefVec curr idx : Nat hidx : idx < curr ⊢ ∀ (hfoo : aig.decls.size ≤ (go aig curr hcurr discr lhs rhs s).aig.decls.size), (go aig curr hcurr discr lhs rhs s).vec.get idx ⋯ = (s.get idx hidx).cast hfoo
generalize hgo : go aig curr hcurr discr lhs rhs s = res
α : Type inst✝¹ : Hashable α inst✝ : DecidableEq α w : Nat aig : AIG α curr : Nat hcurr : curr ≤ w discr : aig.Ref lhs rhs : aig.RefVec w s : aig.RefVec curr idx : Nat hidx : idx < curr res : RefVecEntry α w hgo : go aig curr hcurr discr lhs rhs s = res ⊢ ∀ (hfoo : aig.decls.size ≤ res.aig.decls.size), res.vec.get idx ⋯ = (s.get idx hidx).cast hfoo
c08e573c9b942d4a
LinearMap.IsProj.codRestrict_apply_cod
Mathlib/LinearAlgebra/Projection.lean
theorem codRestrict_apply_cod {f : M →ₗ[S] M} (h : IsProj m f) (x : m) : h.codRestrict x = x
case a S : Type u_5 inst✝² : Semiring S M : Type u_6 inst✝¹ : AddCommMonoid M inst✝ : Module S M m : Submodule S M f : M →ₗ[S] M h : IsProj m f x : ↥m ⊢ f ↑x = ↑x
exact h.map_id x x.2
no goals
3e267d085658cef3
List.stronglyMeasurable_prod'
Mathlib/MeasureTheory/Function/StronglyMeasurable/Basic.lean
theorem _root_.List.stronglyMeasurable_prod' (l : List (α → M)) (hl : ∀ f ∈ l, StronglyMeasurable f) : StronglyMeasurable l.prod
α : Type u_1 M : Type u_5 inst✝² : Monoid M inst✝¹ : TopologicalSpace M inst✝ : ContinuousMul M m : MeasurableSpace α l : List (α → M) hl : ∀ f ∈ l, StronglyMeasurable f ⊢ StronglyMeasurable l.prod
induction' l with f l ihl
case nil α : Type u_1 M : Type u_5 inst✝² : Monoid M inst✝¹ : TopologicalSpace M inst✝ : ContinuousMul M m : MeasurableSpace α hl : ∀ f ∈ [], StronglyMeasurable f ⊢ StronglyMeasurable [].prod case cons α : Type u_1 M : Type u_5 inst✝² : Monoid M inst✝¹ : TopologicalSpace M inst✝ : ContinuousMul M m : MeasurableSpace α f : α → M l : List (α → M) ihl : (∀ f ∈ l, StronglyMeasurable f) → StronglyMeasurable l.prod hl : ∀ f_1 ∈ f :: l, StronglyMeasurable f_1 ⊢ StronglyMeasurable (f :: l).prod
281f39535a2f83b5
AkraBazziRecurrence.smoothingFn_mul_asympBound_isBigO_T
Mathlib/Computability/AkraBazzi/AkraBazzi.lean
/-- The main proof of the lower bound part of the Akra-Bazzi theorem. The factor `1 + ε n` does not change the asymptotic order, but is needed for the induction step to go through. -/ lemma smoothingFn_mul_asympBound_isBigO_T : (fun (n : ℕ) => (1 + ε n) * asympBound g a b n) =O[atTop] T
case h α : Type u_1 inst✝¹ : Fintype α T : ℕ → ℝ g : ℝ → ℝ a b : α → ℝ r : α → ℕ → ℕ inst✝ : Nonempty α R : AkraBazziRecurrence T g a b r b' : ℝ := b (min_bi b) / 2 hb_pos : 0 < b' c₁ : ℝ hc₁ : c₁ > 0 h_sumTransform_aux : ∀ᶠ (n : ℕ) in atTop, ∀ (i : α), sumTransform (p a b) g (r i n) n ≤ c₁ * g ↑n n₀ : ℕ n₀_ge_Rn₀ : R.n₀ ≤ n₀ h_b_floor : 0 < ⌊b' * ↑n₀⌋₊ h_smoothing_pos : ∀ (y : ℕ), n₀ ≤ y → 0 < 1 + ε ↑y h_smoothing_pos' : ∀ (y : ℕ), ⌊b' * ↑n₀⌋₊ ≤ y → 0 < 1 + ε ↑y h_asympBound_pos : ∀ (y : ℕ), n₀ ≤ y → 0 < asympBound g a b y h_asympBound_r_pos : ∀ (y : ℕ), n₀ ≤ y → ∀ (i : α), 0 < asympBound g a b (r i y) h_asympBound_floor : ∀ (y : ℕ), ⌊b' * ↑n₀⌋₊ ≤ y → 0 < asympBound g a b y n₀_pos : 0 < n₀ h_smoothing_r_pos : ∀ (y : ℕ), n₀ ≤ y → ∀ (i : α), 0 < 1 + ε ↑(r i y) bound2 : ∀ (y : ℕ), n₀ ≤ y → ∀ (i : α), b i ^ p a b * ↑y ^ p a b * (1 + ε ↑y) ≤ ↑(r i y) ^ p a b * (1 + ε ↑(r i y)) h_smoothingFn_floor : ∀ (y : ℕ), ⌊b' * ↑n₀⌋₊ ≤ y → 0 < 1 + ε ↑y h_sumTransform : ∀ (y : ℕ), n₀ ≤ y → ∀ (i : α), sumTransform (p a b) g (r i y) y ≤ c₁ * g ↑y h_bi_le_r : ∀ (y : ℕ), n₀ ≤ y → ∀ (i : α), b (min_bi b) / 2 * ↑y ≤ ↑(r i y) h_exp : ∀ (y : ℕ), n₀ ≤ y → ⌈rexp 1⌉₊ ≤ y h_base_nonempty : (Ico ⌊b (min_bi b) / 2 * ↑n₀⌋₊ n₀).Nonempty ⊢ ∃ c > 0, ∀ n ≥ n₀, c * ‖(1 + ε ↑n) * asympBound g a b n‖ ≤ ‖T n‖
set base_min : ℝ := (Finset.Ico (⌊b' * n₀⌋₊) n₀).inf' h_base_nonempty (fun n => T n / ((1 + ε n) * asympBound g a b n)) with base_min_def
case h α : Type u_1 inst✝¹ : Fintype α T : ℕ → ℝ g : ℝ → ℝ a b : α → ℝ r : α → ℕ → ℕ inst✝ : Nonempty α R : AkraBazziRecurrence T g a b r b' : ℝ := b (min_bi b) / 2 hb_pos : 0 < b' c₁ : ℝ hc₁ : c₁ > 0 h_sumTransform_aux : ∀ᶠ (n : ℕ) in atTop, ∀ (i : α), sumTransform (p a b) g (r i n) n ≤ c₁ * g ↑n n₀ : ℕ n₀_ge_Rn₀ : R.n₀ ≤ n₀ h_b_floor : 0 < ⌊b' * ↑n₀⌋₊ h_smoothing_pos : ∀ (y : ℕ), n₀ ≤ y → 0 < 1 + ε ↑y h_smoothing_pos' : ∀ (y : ℕ), ⌊b' * ↑n₀⌋₊ ≤ y → 0 < 1 + ε ↑y h_asympBound_pos : ∀ (y : ℕ), n₀ ≤ y → 0 < asympBound g a b y h_asympBound_r_pos : ∀ (y : ℕ), n₀ ≤ y → ∀ (i : α), 0 < asympBound g a b (r i y) h_asympBound_floor : ∀ (y : ℕ), ⌊b' * ↑n₀⌋₊ ≤ y → 0 < asympBound g a b y n₀_pos : 0 < n₀ h_smoothing_r_pos : ∀ (y : ℕ), n₀ ≤ y → ∀ (i : α), 0 < 1 + ε ↑(r i y) bound2 : ∀ (y : ℕ), n₀ ≤ y → ∀ (i : α), b i ^ p a b * ↑y ^ p a b * (1 + ε ↑y) ≤ ↑(r i y) ^ p a b * (1 + ε ↑(r i y)) h_smoothingFn_floor : ∀ (y : ℕ), ⌊b' * ↑n₀⌋₊ ≤ y → 0 < 1 + ε ↑y h_sumTransform : ∀ (y : ℕ), n₀ ≤ y → ∀ (i : α), sumTransform (p a b) g (r i y) y ≤ c₁ * g ↑y h_bi_le_r : ∀ (y : ℕ), n₀ ≤ y → ∀ (i : α), b (min_bi b) / 2 * ↑y ≤ ↑(r i y) h_exp : ∀ (y : ℕ), n₀ ≤ y → ⌈rexp 1⌉₊ ≤ y h_base_nonempty : (Ico ⌊b (min_bi b) / 2 * ↑n₀⌋₊ n₀).Nonempty base_min : ℝ := (Ico ⌊b' * ↑n₀⌋₊ n₀).inf' h_base_nonempty fun n => T n / ((1 + ε ↑n) * asympBound g a b n) base_min_def : base_min = (Ico ⌊b' * ↑n₀⌋₊ n₀).inf' h_base_nonempty fun n => T n / ((1 + ε ↑n) * asympBound g a b n) ⊢ ∃ c > 0, ∀ n ≥ n₀, c * ‖(1 + ε ↑n) * asympBound g a b n‖ ≤ ‖T n‖
82bb51116c3f899e
Set.Finite.image
Mathlib/Data/Set/Finite/Basic.lean
theorem Finite.image {s : Set α} (f : α → β) (hs : s.Finite) : (f '' s).Finite
α : Type u β : Type v s : Set α f : α → β hs : s.Finite ⊢ (f '' s).Finite
have := hs.to_subtype
α : Type u β : Type v s : Set α f : α → β hs : s.Finite this : Finite ↑s ⊢ (f '' s).Finite
1d7b24a4e0931515
EMetric.isClosed_subsets_of_isClosed
Mathlib/Topology/MetricSpace/Closeds.lean
theorem isClosed_subsets_of_isClosed (hs : IsClosed s) : IsClosed { t : Closeds α | (t : Set α) ⊆ s }
α : Type u inst✝ : EMetricSpace α s : Set α hs : IsClosed s t : Closeds α ht : t ∈ closure {t | ↑t ⊆ s} x : α hx : x ∈ t ⊢ x ∈ closure s
refine mem_closure_iff.2 fun ε εpos => ?_
α : Type u inst✝ : EMetricSpace α s : Set α hs : IsClosed s t : Closeds α ht : t ∈ closure {t | ↑t ⊆ s} x : α hx : x ∈ t ε : ℝ≥0∞ εpos : ε > 0 ⊢ ∃ y ∈ s, edist x y < ε
eed134e17fc5ce9d
Algebra.IsAlgebraic.lift_cardinalMk_le_sigma_polynomial
Mathlib/RingTheory/Algebraic/Cardinality.lean
theorem lift_cardinalMk_le_sigma_polynomial : lift.{u} #L ≤ #(Σ p : R[X], { x : L // x ∈ p.aroots L })
R : Type u inst✝⁵ : CommRing R L : Type v inst✝⁴ : CommRing L inst✝³ : IsDomain L inst✝² : Algebra R L inst✝¹ : NoZeroSMulDivisors R L inst✝ : Algebra.IsAlgebraic R L x y : L h : (fun x => let p := Classical.indefiniteDescription (fun x_1 => x_1 ≠ 0 ∧ (Polynomial.aeval x) x_1 = 0) ⋯; ⟨↑p, ⟨x, ⋯⟩⟩) x = (fun x => let p := Classical.indefiniteDescription (fun x_1 => x_1 ≠ 0 ∧ (Polynomial.aeval x) x_1 = 0) ⋯; ⟨↑p, ⟨x, ⋯⟩⟩) y ⊢ x = y
simp only [Set.coe_setOf, ne_eq, Set.mem_setOf_eq, Sigma.mk.inj_iff] at h
R : Type u inst✝⁵ : CommRing R L : Type v inst✝⁴ : CommRing L inst✝³ : IsDomain L inst✝² : Algebra R L inst✝¹ : NoZeroSMulDivisors R L inst✝ : Algebra.IsAlgebraic R L x y : L h : ↑(Classical.indefiniteDescription (fun x_1 => ¬x_1 = 0 ∧ (Polynomial.aeval x) x_1 = 0) ⋯) = ↑(Classical.indefiniteDescription (fun x => ¬x = 0 ∧ (Polynomial.aeval y) x = 0) ⋯) ∧ HEq ⟨x, ⋯⟩ ⟨y, ⋯⟩ ⊢ x = y
9dbc3398b59afa38
Types.Pushout.inl_rel'_inl_iff
Mathlib/CategoryTheory/Limits/Shapes/Types.lean
@[simp] lemma inl_rel'_inl_iff (x₁ y₁ : X₁) : Rel' f g (Sum.inl x₁) (Sum.inl y₁) ↔ x₁ = y₁ ∨ ∃ (x₀ y₀ : S) (_ : g x₀ = g y₀), x₁ = f x₀ ∧ y₁ = f y₀
case mpr S X₁ X₂ : Type u f : S ⟶ X₁ g : S ⟶ X₂ x₁ y₁ : X₁ ⊢ (x₁ = y₁ ∨ ∃ x₀ y₀, ∃ (_ : g x₀ = g y₀), x₁ = f x₀ ∧ y₁ = f y₀) → Rel' f g (Sum.inl x₁) (Sum.inl y₁)
rintro (rfl | ⟨_,_ , h, rfl, rfl⟩)
case mpr.inl S X₁ X₂ : Type u f : S ⟶ X₁ g : S ⟶ X₂ x₁ : X₁ ⊢ Rel' f g (Sum.inl x₁) (Sum.inl x₁) case mpr.inr.intro.intro.intro.intro S X₁ X₂ : Type u f : S ⟶ X₁ g : S ⟶ X₂ w✝¹ w✝ : S h : g w✝¹ = g w✝ ⊢ Rel' f g (Sum.inl (f w✝¹)) (Sum.inl (f w✝))
d928526eeaa2913f
BddOrd.id_apply
Mathlib/Order/Category/BddOrd.lean
lemma id_apply (X : BddOrd) (x : X) : (𝟙 X : X ⟶ X) x = x
X : BddOrd x : ↑X.toPartOrd ⊢ (ConcreteCategory.hom (𝟙 X)) x = x
simp
no goals
49293cb0f533256c
SimpleGraph.edist_bot
Mathlib/Combinatorics/SimpleGraph/Metric.lean
lemma edist_bot [DecidableEq V] : (⊥ : SimpleGraph V).edist u v = (if u = v then 0 else ⊤)
V : Type u_1 u v : V inst✝ : DecidableEq V ⊢ ⊥.edist u v = if u = v then 0 else ⊤
by_cases h : u = v <;> simp [h, edist_bot_of_ne]
no goals
4f40291f70ad31c1
MvPolynomial.NewtonIdentities.pairMap_involutive
Mathlib/RingTheory/MvPolynomial/Symmetric/NewtonIdentities.lean
theorem pairMap_involutive : (pairMap σ).Involutive
σ : Type u_1 inst✝ : DecidableEq σ ⊢ Function.Involutive (MvPolynomial.NewtonIdentities.pairMap σ)
intro t
σ : Type u_1 inst✝ : DecidableEq σ t : Finset σ × σ ⊢ MvPolynomial.NewtonIdentities.pairMap σ (MvPolynomial.NewtonIdentities.pairMap σ t) = t
d4c9b1d690e07836
Lean.Data.AC.Context.toList_nonEmpty
Mathlib/.lake/packages/lean4/src/lean/Init/Data/AC.lean
theorem Context.toList_nonEmpty (e : Expr) : e.toList ≠ []
case op.cons l r : Expr ih₁ : l.toList ≠ [] rhs_ih✝ : r.toList ≠ [] head✝ : Nat tail✝ : List Nat h : l.toList = head✝ :: tail✝ ⊢ ¬head✝ :: tail✝ ++ r.toList = []
simp [List.append]
no goals
c00518f72b14f35d
BitVec.toInt_abs_eq_ite
Mathlib/.lake/packages/lean4/src/lean/Init/Data/BitVec/Lemmas.lean
theorem toInt_abs_eq_ite {x : BitVec w} : x.abs.toInt = if x = intMin w then (intMin w).toInt else if x.msb then -x.toInt else x.toInt
w : Nat x : BitVec w ⊢ x.abs.toInt = if x = intMin w then (intMin w).toInt else if x.msb = true then -x.toInt else x.toInt
by_cases hx : x = intMin w
case pos w : Nat x : BitVec w hx : x = intMin w ⊢ x.abs.toInt = if x = intMin w then (intMin w).toInt else if x.msb = true then -x.toInt else x.toInt case neg w : Nat x : BitVec w hx : ¬x = intMin w ⊢ x.abs.toInt = if x = intMin w then (intMin w).toInt else if x.msb = true then -x.toInt else x.toInt
27d1365952689b50
HomologicalComplex.d_comp_XIsoOfEq_hom
Mathlib/Algebra/Homology/HomologicalComplex.lean
@[reassoc (attr := simp)] lemma d_comp_XIsoOfEq_hom (K : HomologicalComplex V c) {p₂ p₃ : ι} (h : p₂ = p₃) (p₁ : ι) : K.d p₁ p₂ ≫ (K.XIsoOfEq h).hom = K.d p₁ p₃
ι : Type u_1 V : Type u inst✝¹ : Category.{v, u} V inst✝ : HasZeroMorphisms V c : ComplexShape ι K : HomologicalComplex V c p₂ p₃ : ι h : p₂ = p₃ p₁ : ι ⊢ K.d p₁ p₂ ≫ (K.XIsoOfEq h).hom = K.d p₁ p₃
subst h
ι : Type u_1 V : Type u inst✝¹ : Category.{v, u} V inst✝ : HasZeroMorphisms V c : ComplexShape ι K : HomologicalComplex V c p₂ p₁ : ι ⊢ K.d p₁ p₂ ≫ (K.XIsoOfEq ⋯).hom = K.d p₁ p₂
5786182a83bb6e15
Lean.Data.AC.Context.evalList_append
Mathlib/.lake/packages/lean4/src/lean/Init/Data/AC.lean
theorem Context.evalList_append (ctx : Context α) (l r : List Nat) (h₁ : l ≠ []) (h₂ : r ≠ []) : evalList α ctx (l.append r) = ctx.op (evalList α ctx l) (evalList α ctx r)
case single α : Sort u_1 ctx : Context α r : List Nat h₂ : r ≠ [] x : Nat h₁ : [x] ≠ [] ⊢ evalList α ctx ([x].append r) = ctx.op (evalList α ctx [x]) (evalList α ctx r)
cases r
case single.nil α : Sort u_1 ctx : Context α x : Nat h₁ : [x] ≠ [] h₂ : [] ≠ [] ⊢ evalList α ctx ([x].append []) = ctx.op (evalList α ctx [x]) (evalList α ctx []) case single.cons α : Sort u_1 ctx : Context α x : Nat h₁ : [x] ≠ [] head✝ : Nat tail✝ : List Nat h₂ : head✝ :: tail✝ ≠ [] ⊢ evalList α ctx ([x].append (head✝ :: tail✝)) = ctx.op (evalList α ctx [x]) (evalList α ctx (head✝ :: tail✝))
9239bcb9323c7bb8
PadicSeq.add_eq_max_of_ne
Mathlib/NumberTheory/Padics/PadicNumbers.lean
theorem add_eq_max_of_ne {f g : PadicSeq p} (hfgne : f.norm ≠ g.norm) : (f + g).norm = max f.norm g.norm
p : ℕ hp : Fact (Nat.Prime p) f g : PadicSeq p hfgne : f.norm ≠ g.norm hfg : ¬f + g ≈ 0 hf : ¬f ≈ 0 hg : g ≈ 0 this✝ : (g - 0).LimZero this : f + g ≈ f h1 : (f + g).norm = f.norm ⊢ (f + g).norm = f.norm ⊔ g.norm
have h2 : g.norm = 0 := (norm_zero_iff _).2 hg
p : ℕ hp : Fact (Nat.Prime p) f g : PadicSeq p hfgne : f.norm ≠ g.norm hfg : ¬f + g ≈ 0 hf : ¬f ≈ 0 hg : g ≈ 0 this✝ : (g - 0).LimZero this : f + g ≈ f h1 : (f + g).norm = f.norm h2 : g.norm = 0 ⊢ (f + g).norm = f.norm ⊔ g.norm
70e67c5122e56027
IsCyclic.exists_ofOrder_eq_natCard
Mathlib/GroupTheory/SpecificGroups/Cyclic.lean
@[to_additive] lemma IsCyclic.exists_ofOrder_eq_natCard [h : IsCyclic α] : ∃ g : α, orderOf g = Nat.card α
case h α : Type u_1 inst✝ : Group α h : IsCyclic α g : α hg : ∀ (x : α), x ∈ zpowers g ⊢ orderOf g = Nat.card α
rw [← card_zpowers g, (eq_top_iff' (zpowers g)).mpr hg]
case h α : Type u_1 inst✝ : Group α h : IsCyclic α g : α hg : ∀ (x : α), x ∈ zpowers g ⊢ Nat.card ↥⊤ = Nat.card α
c40cde1ffa129f52
Real.summable_log_one_add_of_summable
Mathlib/Analysis/SpecialFunctions/Log/Summable.lean
lemma Real.summable_log_one_add_of_summable {f : ι → ℝ} (hf : Summable f) : Summable (fun i : ι => log (1 + |f i|))
ι : Type u_1 f : ι → ℝ hf : Summable f ⊢ Summable fun i => log (1 + |f i|)
have : Summable (fun n ↦ Complex.ofRealCLM (log (1 + |f n|))) := by convert Complex.summable_log_one_add_of_summable (Complex.ofRealCLM.summable hf.norm) with x rw [ofRealCLM_apply, ofReal_log (by positivity)] simp only [ofReal_add, ofReal_one, norm_eq_abs, ofRealCLM_apply]
ι : Type u_1 f : ι → ℝ hf : Summable f this : Summable fun n => ofRealCLM (log (1 + |f n|)) ⊢ Summable fun i => log (1 + |f i|)
4db2ca3d7bda0ab0
LieAlgebra.IsSemisimple.isSimple_of_isAtom
Mathlib/Algebra/Lie/Semisimple/Basic.lean
lemma isSimple_of_isAtom (I : LieIdeal R L) (hI : IsAtom I) : IsSimple R I where non_abelian := IsSemisimple.non_abelian_of_isAtom I hI eq_bot_or_eq_top
case intro.intro.intro.intro.intro.intro.a R : Type u_1 L : Type u_2 inst✝³ : CommRing R inst✝² : LieRing L inst✝¹ : LieAlgebra R L inst✝ : IsSemisimple R L I : LieIdeal R L hI : IsAtom I J : LieIdeal R ↥I y : ↥I hy : y ∈ ↑↑J a : L ha : a ∈ I b : L hb : b ∈ sSup ({I' | IsAtom I'} \ {I}) ⊢ ∃ a_1, ∃ (b : a_1 ∈ I), ⟨a_1, b⟩ ∈ J ∧ (↑I).subtype ⟨a_1, b⟩ = ⁅a, (↑I).subtype y⁆
erw [Submodule.coe_subtype]
case intro.intro.intro.intro.intro.intro.a R : Type u_1 L : Type u_2 inst✝³ : CommRing R inst✝² : LieRing L inst✝¹ : LieAlgebra R L inst✝ : IsSemisimple R L I : LieIdeal R L hI : IsAtom I J : LieIdeal R ↥I y : ↥I hy : y ∈ ↑↑J a : L ha : a ∈ I b : L hb : b ∈ sSup ({I' | IsAtom I'} \ {I}) ⊢ ∃ a_1, ∃ (b : a_1 ∈ I), ⟨a_1, b⟩ ∈ J ∧ ↑⟨a_1, b⟩ = ⁅a, ↑y⁆
94384633946b96a7
Int.abs_sub_lt_one_of_floor_eq_floor
Mathlib/Algebra/Order/Floor.lean
theorem abs_sub_lt_one_of_floor_eq_floor {α : Type*} [LinearOrderedCommRing α] [FloorRing α] {a b : α} (h : ⌊a⌋ = ⌊b⌋) : |a - b| < 1
α : Type u_4 inst✝¹ : LinearOrderedCommRing α inst✝ : FloorRing α a b : α h : ⌊a⌋ = ⌊b⌋ this✝² : a < ↑⌊a⌋ + 1 this✝¹ : b < ↑⌊b⌋ + 1 this✝ : ↑⌊a⌋ = ↑⌊b⌋ this : ↑⌊a⌋ ≤ a ⊢ |a - b| < 1
have : (⌊b⌋ : α) ≤ b := floor_le b
α : Type u_4 inst✝¹ : LinearOrderedCommRing α inst✝ : FloorRing α a b : α h : ⌊a⌋ = ⌊b⌋ this✝³ : a < ↑⌊a⌋ + 1 this✝² : b < ↑⌊b⌋ + 1 this✝¹ : ↑⌊a⌋ = ↑⌊b⌋ this✝ : ↑⌊a⌋ ≤ a this : ↑⌊b⌋ ≤ b ⊢ |a - b| < 1
11281188035b59c7
IsIdempotentElem.mul_one_sub_self
Mathlib/Algebra/Ring/Idempotent.lean
@[simp] lemma mul_one_sub_self (h : IsIdempotentElem a) : a * (1 - a) = 0
R : Type u_1 inst✝ : NonAssocRing R a : R h : IsIdempotentElem a ⊢ a * (1 - a) = 0
rw [mul_sub, mul_one, h.eq, sub_self]
no goals
b93c714e81a1fc1c
Module.exists_smul_eq_zero_and_mk_eq
Mathlib/Algebra/Module/PID.lean
theorem exists_smul_eq_zero_and_mk_eq {z : M} (hz : Module.IsTorsionBy R M (p ^ pOrder hM z)) {k : ℕ} (f : (R ⧸ R ∙ p ^ k) →ₗ[R] M ⧸ R ∙ z) : ∃ x : M, p ^ k • x = 0 ∧ Submodule.Quotient.mk (p := span R {z}) x = f 1
case h.e'_2.h.e'_6 R : Type u inst✝⁴ : CommRing R inst✝³ : IsPrincipalIdealRing R M : Type v inst✝² : AddCommGroup M inst✝¹ : Module R M inst✝ : IsDomain R p : R hp : Irreducible p hM : IsTorsion' M ↥(Submonoid.powers p) dec : (x : M) → Decidable (x = 0) z : M hz : IsTorsionBy R M (p ^ pOrder hM z) k : ℕ f : R ⧸ Submodule.span R {p ^ k} →ₗ[R] M ⧸ Submodule.span R {z} f1 : ∃ a, Submodule.Quotient.mk a = f 1 ⊢ p ^ k ∈ Submodule.span R {p ^ k}
exact Submodule.mem_span_singleton_self _
no goals
868eb814ce84c0fb
PreconnectedSpace.induction₂'
Mathlib/Topology/Connected/Clopen.lean
/-- In a preconnected space, given a transitive relation `P`, if `P x y` and `P y x` are true for `y` close enough to `x`, then `P x y` holds for all `x, y`. This is a version of the fact that, if an equivalence relation has open classes, then it has a single equivalence class. -/ lemma PreconnectedSpace.induction₂' [PreconnectedSpace α] (P : α → α → Prop) (h : ∀ x, ∀ᶠ y in 𝓝 x, P x y ∧ P y x) (h' : Transitive P) (x y : α) : P x y
α : Type u inst✝¹ : TopologicalSpace α inst✝ : PreconnectedSpace α P : α → α → Prop h : ∀ (x : α), ∀ᶠ (y : α) in 𝓝 x, P x y ∧ P y x h' : Transitive P x y : α ⊢ P x y
let u := {z | P x z}
α : Type u inst✝¹ : TopologicalSpace α inst✝ : PreconnectedSpace α P : α → α → Prop h : ∀ (x : α), ∀ᶠ (y : α) in 𝓝 x, P x y ∧ P y x h' : Transitive P x y : α u : Set α := {z | P x z} ⊢ P x y
97b52bfa4f7b2cfd
Vector.reverse_pmap
Mathlib/.lake/packages/lean4/src/lean/Init/Data/Vector/Attach.lean
theorem reverse_pmap {P : α → Prop} (f : (a : α) → P a → β) (xs : Vector α n) (H : ∀ (a : α), a ∈ xs → P a) : (xs.pmap f H).reverse = xs.reverse.pmap f (fun a h => H a (by simpa using h))
α : Type u_1 β : Type u_2 n : Nat P : α → Prop f : (a : α) → P a → β xs : Vector α n H : ∀ (a : α), a ∈ xs → P a ⊢ (pmap f xs H).reverse = pmap f xs.reverse ⋯
rw [pmap_reverse]
no goals
2da462a799da24ae
ZMod.cast_neg_one
Mathlib/Data/ZMod/Basic.lean
theorem cast_neg_one {R : Type*} [Ring R] (n : ℕ) : cast (-1 : ZMod n) = (n - 1 : R)
case succ R : Type u_1 inst✝ : Ring R n : ℕ ⊢ (-1).cast = ↑(n + 1) - 1
rw [← natCast_val, val_neg_one, Nat.cast_succ, add_sub_cancel_right]
no goals
5d13c9152d6ff8e4
Polynomial.derivativeFinsupp_one
Mathlib/Algebra/Polynomial/Derivative.lean
theorem derivativeFinsupp_one : derivativeFinsupp (1 : R[X]) = .single 0 1
R : Type u inst✝ : Semiring R ⊢ derivativeFinsupp 1 = Finsupp.single 0 1
simpa using derivativeFinsupp_C (1 : R)
no goals
8ebb754427a3b93b
OrthonormalBasis.orthonormal
Mathlib/Analysis/InnerProductSpace/PiL2.lean
theorem orthonormal (b : OrthonormalBasis ι 𝕜 E) : Orthonormal 𝕜 b
ι : Type u_1 𝕜 : Type u_3 inst✝³ : RCLike 𝕜 E : Type u_4 inst✝² : NormedAddCommGroup E inst✝¹ : InnerProductSpace 𝕜 E inst✝ : Fintype ι b : OrthonormalBasis ι 𝕜 E ⊢ ∀ (i j : ι), inner (b i) (b j) = if i = j then 1 else 0
intro i j
ι : Type u_1 𝕜 : Type u_3 inst✝³ : RCLike 𝕜 E : Type u_4 inst✝² : NormedAddCommGroup E inst✝¹ : InnerProductSpace 𝕜 E inst✝ : Fintype ι b : OrthonormalBasis ι 𝕜 E i j : ι ⊢ inner (b i) (b j) = if i = j then 1 else 0
1605b523466c7150
MeasureTheory.lintegral_pow_le_pow_lintegral_fderiv
Mathlib/Analysis/FunctionalSpaces/SobolevInequality.lean
theorem lintegral_pow_le_pow_lintegral_fderiv {u : E → F} (hu : ContDiff ℝ 1 u) (h2u : HasCompactSupport u) {p : ℝ} (hp : Real.IsConjExponent (finrank ℝ E) p) : ∫⁻ x, ‖u x‖ₑ ^ p ∂μ ≤ lintegralPowLePowLIntegralFDerivConst μ p * (∫⁻ x, ‖fderiv ℝ u x‖ₑ ∂μ) ^ p
F : Type u_3 inst✝⁷ : NormedAddCommGroup F inst✝⁶ : NormedSpace ℝ F E : Type u_4 inst✝⁵ : NormedAddCommGroup E inst✝⁴ : NormedSpace ℝ E inst✝³ : MeasurableSpace E inst✝² : BorelSpace E inst✝¹ : FiniteDimensional ℝ E μ : Measure E inst✝ : μ.IsAddHaarMeasure u : E → F hu : ContDiff ℝ 1 u h2u : HasCompactSupport u p : ℝ hp✝ : (↑(finrank ℝ E)).IsConjExponent p C : ℝ≥0 := lintegralPowLePowLIntegralFDerivConst μ p ι : Type := Fin (finrank ℝ E) hιcard : #ι = finrank ℝ E this✝ : finrank ℝ E = finrank ℝ (ι → ℝ) e : E ≃L[ℝ] ι → ℝ := ContinuousLinearEquiv.ofFinrankEq this✝ this : (Measure.map (⇑e.symm) volume).IsAddHaarMeasure hp : (↑#ι).IsConjExponent p h0p : 0 ≤ p c : ℝ≥0 := μ.addHaarScalarFactor (Measure.map (⇑e.symm) volume) hc : 0 < c h2c : μ = c • Measure.map (⇑e.symm) volume h3c : ↑c ≠ 0 h0C : C = c * ‖↑e.symm‖₊ ^ p * (c ^ p)⁻¹ hC : C * c ^ p = c * ‖↑e.symm‖₊ ^ p v : (ι → ℝ) → F := u ∘ ⇑e.symm hv : ContDiff ℝ 1 v h2v : HasCompactSupport v ⊢ Measurable fun x => ‖u x‖ₑ ^ p
borelize F
F : Type u_3 inst✝⁷ : NormedAddCommGroup F inst✝⁶ : NormedSpace ℝ F E : Type u_4 inst✝⁵ : NormedAddCommGroup E inst✝⁴ : NormedSpace ℝ E inst✝³ : MeasurableSpace E inst✝² : BorelSpace E inst✝¹ : FiniteDimensional ℝ E μ : Measure E inst✝ : μ.IsAddHaarMeasure u : E → F hu : ContDiff ℝ 1 u h2u : HasCompactSupport u p : ℝ hp✝ : (↑(finrank ℝ E)).IsConjExponent p C : ℝ≥0 := lintegralPowLePowLIntegralFDerivConst μ p ι : Type := Fin (finrank ℝ E) hιcard : #ι = finrank ℝ E this✝² : finrank ℝ E = finrank ℝ (ι → ℝ) e : E ≃L[ℝ] ι → ℝ := ContinuousLinearEquiv.ofFinrankEq this✝² this : (Measure.map (⇑e.symm) volume).IsAddHaarMeasure hp : (↑#ι).IsConjExponent p h0p : 0 ≤ p c : ℝ≥0 := μ.addHaarScalarFactor (Measure.map (⇑e.symm) volume) hc : 0 < c h2c : μ = c • Measure.map (⇑e.symm) volume h3c : ↑c ≠ 0 h0C : C = c * ‖↑e.symm‖₊ ^ p * (c ^ p)⁻¹ hC : C * c ^ p = c * ‖↑e.symm‖₊ ^ p v : (ι → ℝ) → F := u ∘ ⇑e.symm hv : ContDiff ℝ 1 v h2v : HasCompactSupport v this✝¹ : MeasurableSpace F := borel F this✝ : BorelSpace F ⊢ Measurable fun x => ‖u x‖ₑ ^ p
7e7c86c82b1c72d8
PadicSeq.norm_nonarchimedean
Mathlib/NumberTheory/Padics/PadicNumbers.lean
theorem norm_nonarchimedean (f g : PadicSeq p) : (f + g).norm ≤ max f.norm g.norm
p : ℕ hp : Fact (Nat.Prime p) f g : PadicSeq p hfg : ¬f + g ≈ 0 hf : f ≈ 0 hfg' : f + g ≈ g hcfg : (f + g).norm = g.norm hcl : f.norm = 0 ⊢ f.norm ⊔ g.norm = g.norm
rw [hcl]
p : ℕ hp : Fact (Nat.Prime p) f g : PadicSeq p hfg : ¬f + g ≈ 0 hf : f ≈ 0 hfg' : f + g ≈ g hcfg : (f + g).norm = g.norm hcl : f.norm = 0 ⊢ 0 ⊔ g.norm = g.norm
4a919ac1cede5d3f
MeasureTheory.lintegral_iSup
Mathlib/MeasureTheory/Integral/Lebesgue.lean
theorem lintegral_iSup {f : ℕ → α → ℝ≥0∞} (hf : ∀ n, Measurable (f n)) (h_mono : Monotone f) : ∫⁻ a, ⨆ n, f n a ∂μ = ⨆ n, ∫⁻ a, f n a ∂μ
α : Type u_1 m : MeasurableSpace α μ : Measure α f : ℕ → α → ℝ≥0∞ hf : ∀ (n : ℕ), Measurable (f n) h_mono : Monotone f c : ℝ≥0 → ℝ≥0∞ := ofNNReal ⊢ ∫⁻ (a : α), ⨆ n, f n a ∂μ = ⨆ n, ∫⁻ (a : α), f n a ∂μ
set F := fun a : α => ⨆ n, f n a
α : Type u_1 m : MeasurableSpace α μ : Measure α f : ℕ → α → ℝ≥0∞ hf : ∀ (n : ℕ), Measurable (f n) h_mono : Monotone f c : ℝ≥0 → ℝ≥0∞ := ofNNReal F : α → ℝ≥0∞ := fun a => ⨆ n, f n a ⊢ lintegral μ F = ⨆ n, ∫⁻ (a : α), f n a ∂μ
e37d047cd3bb7874
PresentedMonoid.ext
Mathlib/Algebra/PresentedMonoid/Basic.lean
theorem ext {M : Type*} [Monoid M] (rels : FreeMonoid α → FreeMonoid α → Prop) {φ ψ : PresentedMonoid rels →* M} (hx : ∀ (x : α), φ (.of rels x) = ψ (.of rels x)) : φ = ψ
case h α : Type u_2 M : Type u_3 inst✝ : Monoid M rels : FreeMonoid α → FreeMonoid α → Prop φ ψ : PresentedMonoid rels →* M hx : ∀ (x : α), φ (of rels x) = ψ (of rels x) x✝ : α ⊢ φ (of rels x✝) = (⇑ψ ∘ of rels) x✝
exact hx _
no goals
4e13ad6c6062fd98
antivary_inv_right₀
Mathlib/Algebra/Order/Monovary.lean
@[simp] lemma antivary_inv_right₀ (hg : StrongLT 0 g) : Antivary f g⁻¹ ↔ Monovary f g := forall_swap.trans <| forall₂_congr fun i j ↦ by simp [inv_lt_inv₀ (hg _) (hg _)]
ι : Type u_1 α : Type u_2 β : Type u_3 inst✝¹ : LinearOrderedSemifield α inst✝ : LinearOrderedSemifield β f : ι → α g : ι → β hg : StrongLT 0 g i j : ι ⊢ g⁻¹ j < g⁻¹ i → f i ≤ f j ↔ g i < g j → f i ≤ f j
simp [inv_lt_inv₀ (hg _) (hg _)]
no goals
2da24a0e14981587
ZMod.val_neg_one
Mathlib/Data/ZMod/Basic.lean
theorem val_neg_one (n : ℕ) : (-1 : ZMod n.succ).val = n
case zero ⊢ ↑(-1) = 0
simp [Nat.mod_one]
no goals
93b3ed05716419f6
GromovHausdorff.candidates_lipschitz_aux
Mathlib/Topology/MetricSpace/GromovHausdorffRealized.lean
theorem candidates_lipschitz_aux (fA : f ∈ candidates X Y) : f (x, y) - f (z, t) ≤ 2 * maxVar X Y * dist (x, y) (z, t) := calc f (x, y) - f (z, t) ≤ f (x, t) + f (t, y) - f (z, t)
X : Type u Y : Type v inst✝¹ : MetricSpace X inst✝ : MetricSpace Y f : GromovHausdorff.ProdSpaceFun X Y x y z t : X ⊕ Y fA : f ∈ candidates X Y ⊢ f (x, z) + f (t, y) ≤ ↑(GromovHausdorff.maxVar X Y) * dist x z + ↑(GromovHausdorff.maxVar X Y) * dist t y
gcongr <;> apply candidates_dist_bound fA
no goals
1bc3e613166ef4b1
MvPolynomial.finSuccEquiv_eq
Mathlib/Algebra/MvPolynomial/Equiv.lean
theorem finSuccEquiv_eq : (finSuccEquiv R n : MvPolynomial (Fin (n + 1)) R →+* Polynomial (MvPolynomial (Fin n) R)) = eval₂Hom (Polynomial.C.comp (C : R →+* MvPolynomial (Fin n) R)) fun i : Fin (n + 1) => Fin.cases Polynomial.X (fun k => Polynomial.C (X k)) i
case hC.a R : Type u inst✝ : CommSemiring R n : ℕ i : R ⊢ ((↑(finSuccEquiv R n)).comp C) i = ((eval₂Hom (Polynomial.C.comp C) fun i => Fin.cases Polynomial.X (fun k => Polynomial.C (X k)) i).comp C) i
simp only [finSuccEquiv, optionEquivLeft_apply, aeval_C, AlgEquiv.coe_trans, RingHom.coe_coe, coe_eval₂Hom, comp_apply, renameEquiv_apply, eval₂_C, RingHom.coe_comp, rename_C]
case hC.a R : Type u inst✝ : CommSemiring R n : ℕ i : R ⊢ (algebraMap R (MvPolynomial (Fin n) R)[X]) i = Polynomial.C (C i)
848c49066f7d034b
ContinuousMultilinearMap.changeOrigin_toFormalMultilinearSeries
Mathlib/Analysis/Calculus/FDeriv/Analytic.lean
theorem changeOrigin_toFormalMultilinearSeries [DecidableEq ι] : continuousMultilinearCurryFin1 𝕜 (∀ i, E i) F (f.toFormalMultilinearSeries.changeOrigin x 1) = f.linearDeriv x
case h.inr.refine_3.h.e_6.h.h.inl 𝕜 : Type u_1 inst✝⁶ : NontriviallyNormedField 𝕜 F : Type v inst✝⁵ : NormedAddCommGroup F inst✝⁴ : NormedSpace 𝕜 F ι : Type u_2 E : ι → Type u_3 inst✝³ : (i : ι) → NormedAddCommGroup (E i) inst✝² : (i : ι) → NormedSpace 𝕜 (E i) inst✝¹ : Fintype ι f : ContinuousMultilinearMap 𝕜 E F x : (i : ι) → E i inst✝ : DecidableEq ι y : (i : ι) → E i h✝ : Nonempty ι j : ι ⊢ Function.update x j (y j) j = if j = j then y j else x j
rw [Function.update_self, if_pos rfl]
no goals
d7dded01cf2a4e1b
Matrix.mulVec_injective_iff_isUnit
Mathlib/LinearAlgebra/Matrix/NonsingularInverse.lean
theorem mulVec_injective_iff_isUnit {A : Matrix m m K} : Function.Injective A.mulVec ↔ IsUnit A
m : Type u inst✝² : DecidableEq m K : Type u_3 inst✝¹ : Field K inst✝ : Fintype m A : Matrix m m K ⊢ Function.Injective A.mulVec ↔ Function.Injective fun v => v ᵥ* Aᵀ
simp_rw [vecMul_transpose]
no goals
42648d76e6284bc4
Mathlib.Meta.NormNum.isInt_ediv
Mathlib/Tactic/NormNum/DivMod.lean
lemma isInt_ediv {a b q m a' : ℤ} {b' r : ℕ} (ha : IsInt a a') (hb : IsNat b b') (hm : q * b' = m) (h : r + m = a') (h₂ : Nat.blt r b' = true) : IsInt (a / b) q := ⟨by obtain ⟨⟨rfl⟩, ⟨rfl⟩⟩ := ha, hb simp only [Nat.blt_eq] at h₂; simp only [← h, ← hm, Int.cast_id] rw [Int.add_mul_ediv_right _ _ (Int.ofNat_ne_zero.2 ((Nat.zero_le ..).trans_lt h₂).ne')] rw [Int.ediv_eq_zero_of_lt, zero_add] <;> [simp; simpa using h₂]⟩
a b q m a' : ℤ b' r : ℕ ha : IsInt a a' hb : IsNat b b' hm : q * ↑b' = m h : ↑r + m = a' h₂ : r.blt b' = true ⊢ a / b = ↑q
obtain ⟨⟨rfl⟩, ⟨rfl⟩⟩ := ha, hb
case mk.mk a q m : ℤ b' r : ℕ hm : q * ↑b' = m h₂ : r.blt b' = true h : ↑r + m = a ⊢ a / ↑b' = ↑q
9ce47b0eb26c011f
Lake.BuildKey.eq_of_quickCmp
Mathlib/.lake/packages/lean4/src/lean/lake/Lake/Build/Key.lean
theorem eq_of_quickCmp {k k' : BuildKey} : quickCmp k k' = Ordering.eq → k = k'
case customTarget.targetFacet p t package✝ target✝ facet✝ : Name ⊢ (match customTarget p t with | moduleFacet m f => match targetFacet package✝ target✝ facet✝ with | moduleFacet m' f' => match m.quickCmp m' with | Ordering.eq => f.quickCmp f' | ord => ord | x => Ordering.lt | packageFacet p f => match targetFacet package✝ target✝ facet✝ with | moduleFacet module facet => Ordering.gt | packageFacet p' f' => match p.quickCmp p' with | Ordering.eq => f.quickCmp f' | ord => ord | x => Ordering.lt | targetFacet p t f => match targetFacet package✝ target✝ facet✝ with | customTarget package target => Ordering.lt | targetFacet p' t' f' => match p.quickCmp p' with | Ordering.eq => match t.quickCmp t' with | Ordering.eq => f.quickCmp f' | ord => ord | ord => ord | x => Ordering.gt | customTarget p t => match targetFacet package✝ target✝ facet✝ with | customTarget p' t' => match p.quickCmp p' with | Ordering.eq => t.quickCmp t' | ord => ord | x => Ordering.gt) = Ordering.eq → customTarget p t = targetFacet package✝ target✝ facet✝
intro
case customTarget.targetFacet p t package✝ target✝ facet✝ : Name a✝ : (match customTarget p t with | moduleFacet m f => match targetFacet package✝ target✝ facet✝ with | moduleFacet m' f' => match m.quickCmp m' with | Ordering.eq => f.quickCmp f' | ord => ord | x => Ordering.lt | packageFacet p f => match targetFacet package✝ target✝ facet✝ with | moduleFacet module facet => Ordering.gt | packageFacet p' f' => match p.quickCmp p' with | Ordering.eq => f.quickCmp f' | ord => ord | x => Ordering.lt | targetFacet p t f => match targetFacet package✝ target✝ facet✝ with | customTarget package target => Ordering.lt | targetFacet p' t' f' => match p.quickCmp p' with | Ordering.eq => match t.quickCmp t' with | Ordering.eq => f.quickCmp f' | ord => ord | ord => ord | x => Ordering.gt | customTarget p t => match targetFacet package✝ target✝ facet✝ with | customTarget p' t' => match p.quickCmp p' with | Ordering.eq => t.quickCmp t' | ord => ord | x => Ordering.gt) = Ordering.eq ⊢ customTarget p t = targetFacet package✝ target✝ facet✝
6e2940eeabc7d427
exists_gt_t2space
Mathlib/Topology/ShrinkingLemma.lean
theorem exists_gt_t2space (v : PartialRefinement u s (fun w => IsCompact (closure w))) (hs : IsCompact s) (i : ι) (hi : i ∉ v.carrier) : ∃ v' : PartialRefinement u s (fun w => IsCompact (closure w)), v < v' ∧ IsCompact (closure (v' i))
ι : Type u_1 X : Type u_2 inst✝² : TopologicalSpace X u : ι → Set X s : Set X inst✝¹ : T2Space X inst✝ : LocallyCompactSpace X v : PartialRefinement u s fun w => IsCompact (closure w) hs : IsCompact s i : ι hi : i ∉ v.carrier si : Set X := s ∩ (⋃ j, ⋃ (_ : j ≠ i), v.toFun j)ᶜ hsi : si = s ∩ ⋂ i_1, ⋂ (_ : ¬i_1 = i), (v.toFun i_1)ᶜ hsic : IsCompact si ⊢ ∃ v', v < v' ∧ IsCompact (closure (v'.toFun i))
have : si ⊆ v i := by intro x hx have (j) (hj : j ≠ i) : x ∉ v j := by rw [hsi] at hx apply Set.not_mem_of_mem_compl have hsi' : x ∈ (⋂ i_1, ⋂ (_ : ¬i_1 = i), (v.toFun i_1)ᶜ) := Set.mem_of_mem_inter_right hx rw [ne_eq] at hj rw [Set.mem_iInter₂] at hsi' exact hsi' j hj obtain ⟨j, hj⟩ := Set.mem_iUnion.mp (v.subset_iUnion (Set.mem_of_mem_inter_left hx)) obtain rfl : j = i := by by_contra! h exact this j h hj exact hj
ι : Type u_1 X : Type u_2 inst✝² : TopologicalSpace X u : ι → Set X s : Set X inst✝¹ : T2Space X inst✝ : LocallyCompactSpace X v : PartialRefinement u s fun w => IsCompact (closure w) hs : IsCompact s i : ι hi : i ∉ v.carrier si : Set X := s ∩ (⋃ j, ⋃ (_ : j ≠ i), v.toFun j)ᶜ hsi : si = s ∩ ⋂ i_1, ⋂ (_ : ¬i_1 = i), (v.toFun i_1)ᶜ hsic : IsCompact si this : si ⊆ v.toFun i ⊢ ∃ v', v < v' ∧ IsCompact (closure (v'.toFun i))
b61f3fede2ad34cb
Real.posLog_sub_posLog_inv
Mathlib/Analysis/SpecialFunctions/Log/PosLog.lean
theorem posLog_sub_posLog_inv {r : ℝ} : log⁺ r - log⁺ r⁻¹ = log r
case pos r : ℝ h : 0 ≤ log r ⊢ 0 ⊔ log r - 0 ⊔ -log r = log r
simp [h]
no goals
78a5076ba1e60175
Stream'.WSeq.destruct_ofSeq
Mathlib/Data/Seq/WSeq.lean
theorem destruct_ofSeq (s : Seq α) : destruct (ofSeq s) = Computation.pure (s.head.map fun a => (a, ofSeq s.tail)) := destruct_eq_pure <| by simp only [destruct, Seq.destruct, Option.map_eq_map, ofSeq, Computation.corec_eq, rmap, Seq.head] rw [show Seq.get? (some <$> s) 0 = some <$> Seq.get? s 0 by apply Seq.map_get?] rcases Seq.get? s 0 with - | a · rfl dsimp only [(· <$> ·)] simp [destruct]
α : Type u s : Seq α ⊢ (↑s).destruct.destruct = Sum.inl (Option.map (fun a => (a, ↑s.tail)) s.head)
simp only [destruct, Seq.destruct, Option.map_eq_map, ofSeq, Computation.corec_eq, rmap, Seq.head]
α : Type u s : Seq α ⊢ (match match Option.map (fun a' => (a', (some <$> s).tail)) ((some <$> s).get? 0) with | none => Sum.inl none | some (none, s') => Sum.inr s' | some (some a, s') => Sum.inl (some (a, s')) with | Sum.inl a => Sum.inl a | Sum.inr b => Sum.inr (Computation.corec (fun s => match Option.map (fun a' => (a', Seq.tail s)) (Seq.get? s 0) with | none => Sum.inl none | some (none, s') => Sum.inr s' | some (some a, s') => Sum.inl (some (a, s'))) b)) = Sum.inl (Option.map (fun a => (a, some <$> s.tail)) (s.get? 0))
99deefc9eb9056e3
ZNum.cast_succ
Mathlib/Data/Num/Lemmas.lean
theorem cast_succ [AddGroupWithOne α] (n) : ((succ n : ZNum) : α) = n + 1
α : Type u_1 inst✝ : AddGroupWithOne α n : ZNum ⊢ ↑n.succ = ↑n + 1
rw [← add_one, cast_add, cast_one]
no goals
1fc5017990152a38
VitaliFamily.withDensity_limRatioMeas_eq
Mathlib/MeasureTheory/Covering/Differentiation.lean
theorem withDensity_limRatioMeas_eq : μ.withDensity (v.limRatioMeas hρ) = ρ
case refine_1 α : Type u_1 inst✝⁴ : PseudoMetricSpace α m0 : MeasurableSpace α μ : Measure α v : VitaliFamily μ inst✝³ : SecondCountableTopology α inst✝² : BorelSpace α inst✝¹ : IsLocallyFiniteMeasure μ ρ : Measure α inst✝ : IsLocallyFiniteMeasure ρ hρ : ρ ≪ μ s : Set α hs : MeasurableSet s ⊢ Tendsto (fun t => ↑t ^ 2) (𝓝[>] 1) (𝓝 (1 ^ 2))
exact ENNReal.Tendsto.pow (ENNReal.tendsto_coe.2 nhdsWithin_le_nhds)
no goals
c98b00e271c474ed
ArithmeticFunction.vonMangoldt.summable_residueClass_non_primes_div
Mathlib/NumberTheory/LSeries/PrimesInAP.lean
/-- The function `n ↦ Λ n / n`, restricted to non-primes in a residue class, is summable. This is used to convert results on `ArithmeticFunction.vonMangoldt.residueClass` to results on primes in an arithmetic progression. -/ lemma summable_residueClass_non_primes_div : Summable fun n : ℕ ↦ (if n.Prime then 0 else residueClass a n) / n
q : ℕ a : ZMod q h₀ : ∀ (n : ℕ), 0 ≤ (if Nat.Prime n then 0 else residueClass a n) / ↑n ⊢ Summable fun n => (if Nat.Prime n then 0 else residueClass a n) / ↑n
have hleF₀ (n : ℕ) : (if n.Prime then 0 else residueClass a n) / n ≤ F₀ n := by refine div_le_div_of_nonneg_right ?_ n.cast_nonneg split_ifs; exacts [le_rfl, residueClass_le a n]
q : ℕ a : ZMod q h₀ : ∀ (n : ℕ), 0 ≤ (if Nat.Prime n then 0 else residueClass a n) / ↑n hleF₀ : ∀ (n : ℕ), (if Nat.Prime n then 0 else residueClass a n) / ↑n ≤ ArithmeticFunction.vonMangoldt.F₀ n ⊢ Summable fun n => (if Nat.Prime n then 0 else residueClass a n) / ↑n
6c8eee8a1fa8d5a9