ruc-ai4math/mathlib_handler_benchmark_410 huggingface dataset:
-- Mathlib/Topology/UniformSpace/UniformConvergence.lean
theorem TendstoUniformlyOnFilter.congr {F' : ι → α → β} (hf : TendstoUniformlyOnFilter F f p p')
    (hff' : ∀ᶠ n : ι × α in p ×ˢ p', F n.fst n.snd = F' n.fst n.snd) :
    TendstoUniformlyOnFilter F' f p p'
-- Mathlib/Data/Set/Basic.lean
protected theorem ssubset_of_subset_of_ssubset {s₁ s₂ s₃ : Set α} (hs₁s₂ : s₁ ⊆ s₂)
    (hs₂s₃ : s₂ ⊂ s₃) : s₁ ⊂ s₃
-- Mathlib/Algebra/BigOperators/RingEquiv.lean
protected theorem map_prod [CommSemiring R] [CommSemiring S] (g : R ≃+* S) (f : α → R)
    (s : Finset α) : g (∏ x ∈ s, f x) = ∏ x ∈ s, g (f x)
-- Mathlib/Topology/Separation.lean
@[simp]
theorem inseparable_eq_eq [T0Space X] : Inseparable = @Eq X
-- Mathlib/CategoryTheory/Subterminal.lean
/-- The inclusion of the subterminal objects into the original category. -/
@[simps!]
def subterminalInclusion : Subterminals C ⥤ C
-- Mathlib/Data/Fintype/Card.lean
theorem Finite.exists_univ_list (α) [Finite α] : ∃ l : List α, l.Nodup ∧ ∀ x : α, x ∈ l
-- .lake/packages/batteries/Batteries/Data/String/Lemmas.lean
theorem hasNext : ∀ {it}, ValidFor l r it → (it.hasNext ↔ r ≠ [])
-- Mathlib/NumberTheory/Harmonic/GammaDeriv.lean
/-- Explicit formula for the derivative of the Gamma function at positive integers, in terms of
harmonic numbers and the Euler-Mascheroni constant `γ`. -/
lemma deriv_Gamma_nat (n : ℕ) :
    deriv Gamma (n + 1) = n ! * (-γ + harmonic n)
-- Mathlib/NumberTheory/LSeries/Basic.lean
lemma delta_mul_eq_smul_delta {f : ℕ → ℂ} : δ * f = f 1 • δ
-- .lake/packages/lean4/src/lean/Init/Data/Nat/Linear.lean
theorem Poly.of_isZero (ctx : Context) {p : Poly} (h : isZero p = true) : p.denote ctx = 0
-- Mathlib/RingTheory/Ideal/Prod.lean
@[simp]
theorem map_prodComm_prod :
    map ((RingEquiv.prodComm : R × S ≃+* S × R) : R × S →+* S × R) (prod I J) = prod J I
-- Mathlib/MeasureTheory/Measure/MeasureSpace.lean
theorem measure_eq_measure_larger_of_between_null_diff {s₁ s₂ s₃ : Set α} (h12 : s₁ ⊆ s₂)
    (h23 : s₂ ⊆ s₃) (h_nulldiff : μ (s₃ \ s₁) = 0) : μ s₂ = μ s₃
-- Mathlib/Algebra/BigOperators/Finsupp.lean
theorem sum_ite_self_eq' [DecidableEq α] {N : Type*} [AddCommMonoid N] (f : α →₀ N) (a : α) :
    (f.sum fun x v => ite (x = a) v 0) = f a
-- Mathlib/Topology/Algebra/Order/Compact.lean
theorem IsCompact.isGLB_sInf [ClosedIicTopology α] {s : Set α} (hs : IsCompact s)
    (ne_s : s.Nonempty) : IsGLB s (sInf s)
-- Mathlib/LinearAlgebra/Matrix/ToLinearEquiv.lean
theorem exists_vecMul_eq_zero_iff {A : Type*} [DecidableEq n] [CommRing A] [IsDomain A]
    {M : Matrix n n A} : (∃ v ≠ 0, v ᵥ* M = 0) ↔ M.det = 0
-- Mathlib/Data/List/MinMax.lean
theorem getElem_le_maximum_of_length_pos {i : ℕ} (w : i < l.length) (h := (Nat.zero_lt_of_lt w)) :
    l[i] ≤ l.maximum_of_length_pos h
-- Mathlib/Logic/Equiv/Set.lean
/-- The composition of an updated function with an equiv on a subtype can be expressed as an
updated function. -/
-- Porting note: replace `s : Set α` and `: s` with `p : α → Prop` and `: Subtype p`, since the
-- former now unfolds syntactically to a less general case of the latter.
theorem dite_comp_equiv_update {α : Type*} {β : Sort*} {γ : Sort*} {p : α → Prop}
    (e : β ≃ Subtype p)
    (v : β → γ) (w : α → γ) (j : β) (x : γ) [DecidableEq β] [DecidableEq α]
    [∀ j, Decidable (p j)] :
    (fun i : α => if h : p i then (Function.update v j x) (e.symm ⟨i, h⟩) else w i) =
      Function.update (fun i : α => if h : p i then v (e.symm ⟨i, h⟩) else w i) (e j) x
-- Mathlib/Geometry/Euclidean/Basic.lean
/-- Reflecting an orthogonal vector plus a point in the subspace
produces the negation of that vector plus the point. -/
theorem reflection_orthogonal_vadd {s : AffineSubspace ℝ P} [Nonempty s]
    [HasOrthogonalProjection s.direction] {p : P} (hp : p ∈ s) {v : V} (hv : v ∈ s.directionᗮ) :
    reflection s (v +ᵥ p) = -v +ᵥ p
-- Mathlib/Algebra/Star/Order.lean
theorem conjugate_lt_conjugate' {a b : R} (hab : a < b) {c : R} (hc : IsRegular c) :
    c * a * star c < c * b * star c
-- Mathlib/Data/Nat/ModEq.lean
/-- A natural number is odd iff it has residue `1` or `3` mod `4`-/
theorem odd_mod_four_iff {n : ℕ} : n % 2 = 1 ↔ n % 4 = 1 ∨ n % 4 = 3
-- Mathlib/Condensed/Light/TopCatAdjunction.lean
lemma continuous_coinducingCoprod {S : LightProfinite.{u}} (x : X.val.obj ⟨S⟩) :
    Continuous fun a ↦ (X.coinducingCoprod ⟨⟨S, x⟩, a⟩)
-- Mathlib/Data/Rat/Cast/Order.lean
@[simp]
theorem preimage_cast_Iio (p : ℚ≥0) : (↑) ⁻¹' Iio (p : K) = Iio p
-- Mathlib/Order/OrderIsoNat.lean
theorem orderEmbeddingOfSet_apply [DecidablePred (· ∈ s)] {n : ℕ} :
    orderEmbeddingOfSet s n = Subtype.ofNat s n
-- Mathlib/NumberTheory/LSeries/RiemannZeta.lean
lemma HurwitzZeta.hurwitzZetaEven_zero : hurwitzZetaEven 0 = riemannZeta
-- Mathlib/GroupTheory/CoprodI.lean
theorem smul_induction {C : Word M → Prop} (h_empty : C empty)
    (h_smul : ∀ (i) (m : M i) (w), C w → C (of m • w)) (w : Word M) : C w
-- Mathlib/Algebra/Star/Subalgebra.lean
theorem mul_mem_sup {S T : StarSubalgebra R A} {x y : A} (hx : x ∈ S) (hy : y ∈ T) :
    x * y ∈ S ⊔ T
-- Mathlib/Topology/Separation.lean
theorem injective_nhdsSet [T1Space X] : Function.Injective (𝓝ˢ : Set X → Filter X)
-- Mathlib/Order/Filter/EventuallyConst.lean
@[nontriviality]
lemma of_subsingleton_left [Subsingleton α] : EventuallyConst f l
-- Mathlib/Topology/Algebra/InfiniteSum/Module.lean
protected theorem ContinuousLinearEquiv.summable {f : ι → M} (e : M ≃SL[σ] M₂) :
    (Summable fun b : ι ↦ e (f b)) ↔ Summable f
-- Mathlib/Data/Ordmap/Ordset.lean
theorem Valid'.node3L {l} {x : α} {m} {y : α} {r o₁ o₂} (hl : Valid' o₁ l x) (hm : Valid' x m y)
    (hr : Valid' y r o₂) (H1 : BalancedSz (size l) (size m))
    (H2 : BalancedSz (size l + size m + 1) (size r)) : Valid' o₁ (@node3L α l x m y r) o₂
-- Mathlib/Algebra/Ring/Subring/Basic.lean
theorem prod_mono_left (t : Subring S) : Monotone fun s : Subring R => s.prod t
-- Mathlib/MeasureTheory/Measure/Lebesgue/EqHaar.lean
theorem addHaar_closedBall_center {E : Type*} [NormedAddCommGroup E] [MeasurableSpace E]
    [BorelSpace E] (μ : Measure E) [IsAddHaarMeasure μ] (x : E) (r : ℝ) :
    μ (closedBall x r) = μ (closedBall (0 : E) r)
-- Mathlib/Geometry/RingedSpace/OpenImmersion.lean
theorem to_iso [h' : Epi f.1.base] : IsIso f
-- Mathlib/Order/Heyting/Basic.lean
@[simp]
theorem fst_hnot [HNot α] [HNot β] (a : α × β) : (￢a).1 = ￢a.1
-- Mathlib/CategoryTheory/Limits/Shapes/BinaryProducts.lean
theorem coprod.desc_comp_assoc {C : Type u} [Category C] {V W X Y : C}
    [HasBinaryCoproduct X Y] (f : V ⟶ W) (g : X ⟶ V) (h : Y ⟶ V) {Z : C} (l : W ⟶ Z) :
    coprod.desc g h ≫ f ≫ l = coprod.desc (g ≫ f) (h ≫ f) ≫ l
-- Mathlib/Analysis/Convex/Deriv.lean
theorem strictAntiOn_deriv (hfc : StrictConcaveOn ℝ S f) (hfd : ∀ x ∈ S, DifferentiableAt ℝ f x) :
    StrictAntiOn (deriv f) S
-- Mathlib/Algebra/Module/Defs.lean
/-- `zsmul` is equal to any other module structure via a cast. -/
lemma Int.cast_smul_eq_nsmul (n : ℤ) (b : M) : (n : R) • b = n • b
-- Mathlib/Analysis/SpecialFunctions/Trigonometric/Deriv.lean
theorem ContDiff.sinh {n} (h : ContDiff ℝ n f) : ContDiff ℝ n fun x => Real.sinh (f x)
-- Mathlib/Analysis/Convex/Exposed.lean
theorem sInter [ContinuousAdd 𝕜] {F : Finset (Set E)} (hF : F.Nonempty)
    (hAF : ∀ B ∈ F, IsExposed 𝕜 A B) : IsExposed 𝕜 A (⋂₀ F)
-- Mathlib/CategoryTheory/Limits/Final.lean
theorem hasColimitsOfShape_of_final [HasColimitsOfShape C E] : HasColimitsOfShape D E
-- Mathlib/Analysis/InnerProductSpace/Adjoint.lean
/-- Conjugating preserves self-adjointness. -/
theorem adjoint_conj {T : E →L[𝕜] E} (hT : IsSelfAdjoint T) (S : F →L[𝕜] E) :
    IsSelfAdjoint (ContinuousLinearMap.adjoint S ∘L T ∘L S)
-- .lake/packages/batteries/Batteries/Data/HashMap/WF.lean
theorem modify_size [BEq α] [Hashable α] {m : Imp α β} {k}
    (h : m.size = m.buckets.size) :
    (modify m k f).size = (modify m k f).buckets.size
-- Mathlib/Topology/Basic.lean
/-- `x` is a cluster point of a set `s` if every neighbourhood of `x` meets `s` on a nonempty
set. See also `mem_closure_iff_clusterPt`. -/
theorem clusterPt_principal_iff :
    ClusterPt x (𝓟 s) ↔ ∀ U ∈ 𝓝 x, (U ∩ s).Nonempty
-- Mathlib/Algebra/GroupWithZero/NonZeroDivisors.lean
lemma nmem_nonZeroDivisorsLeft_iff {r : M₀} :
    r ∉ nonZeroDivisorsLeft M₀ ↔ {s | s * r = 0 ∧ s ≠ 0}.Nonempty
-- Mathlib/Algebra/Homology/BifunctorShift.lean
/-- Auxiliary definition for `mapBifunctorShift₂Iso`. -/
@[simps! hom_f_f inv_f_f]
def mapBifunctorHomologicalComplexShift₂Iso :
    ((F.mapBifunctorHomologicalComplex _ _).obj K₁).obj (K₂⟦y⟧) ≅
    (HomologicalComplex₂.shiftFunctor₂ D y).obj
      (((F.mapBifunctorHomologicalComplex _ _).obj K₁).obj K₂)
-- Mathlib/Data/Subtype.lean
protected theorem refl (s : Subtype p) : s ≈ s
-- Mathlib/Data/Finmap.lean
@[simp]
theorem erase_toFinmap (a : α) (s : AList β) : erase a ⟦s⟧ = AList.toFinmap (s.erase a)
-- Mathlib/Data/Finite/Defs.lean
@[simp]
theorem not_finite_iff_infinite : ¬Finite α ↔ Infinite α
-- Mathlib/FieldTheory/NormalClosure.lean
lemma normal_iff_forall_fieldRange_eq : Normal F K ↔ ∀ σ : K →ₐ[F] L, σ.fieldRange = K
-- Mathlib/Data/Matroid/Basic.lean
theorem Base.diff_finite_comm (hB₁ : M.Base B₁) (hB₂ : M.Base B₂) :
    (B₁ \ B₂).Finite ↔ (B₂ \ B₁).Finite
-- Mathlib/Algebra/Ring/Equiv.lean
@[simp]
theorem comp_symm (e : R ≃+* S) : (e : R →+* S).comp (e.symm : S →+* R) = RingHom.id S
-- Mathlib/Data/W/Constructions.lean
theorem leftInverse_list : Function.LeftInverse (ofList γ) (toList _)
-- Mathlib/Algebra/Order/Ring/Cast.lean
@[simp] lemma ofLex_intCast [IntCast R] (n : ℤ) : (ofLex n : R) = n
-- Mathlib/SetTheory/Ordinal/Arithmetic.lean
theorem blsub_comp {o o' : Ordinal.{max u v}} {f : ∀ a < o, Ordinal.{max u v w}}
    (hf : ∀ {i j} (hi) (hj), i ≤ j → f i hi ≤ f j hj) {g : ∀ a < o', Ordinal.{max u v}}
    (hg : blsub.{_, u} o' g = o) :
    (blsub.{_, w} o' fun a ha => f (g a ha) (by rw [← hg]; apply lt_blsub)) = blsub.{_, w} o f
-- Mathlib/AlgebraicTopology/DoldKan/Normalized.lean
@[reassoc (attr := simp)]
theorem PInftyToNormalizedMooreComplex_comp_inclusionOfMooreComplexMap (X : SimplicialObject A) :
    PInftyToNormalizedMooreComplex X ≫ inclusionOfMooreComplexMap X = PInfty
-- Mathlib/Analysis/InnerProductSpace/Calculus.lean
theorem hasStrictFDerivAt_norm_sq (x : F) :
    HasStrictFDerivAt (fun x => ‖x‖ ^ 2) (2 • (innerSL ℝ x)) x
-- .lake/packages/lean4/src/lean/Init/Data/Nat/Lemmas.lean
protected theorem add_le_of_le_sub' {n k m : Nat} (h : m ≤ k) : n ≤ k - m → m + n ≤ k
-- Mathlib/CategoryTheory/Limits/Over.lean
theorem mono_iff_mono_right [HasPullbacks C] {f g : Under X} (h : f ⟶ g) : Mono h ↔ Mono h.right
-- Mathlib/GroupTheory/Perm/Cycle/Type.lean
theorem two_le_of_mem_cycleType {σ : Perm α} {n : ℕ} (h : n ∈ σ.cycleType) : 2 ≤ n
-- Mathlib/CategoryTheory/Limits/Shapes/Kernels.lean
@[reassoc (attr := simp)]
theorem cokernelIsoOfEq_hom_comp_desc {Z} {f g : X ⟶ Y} [HasCokernel f] [HasCokernel g] (h : f = g)
    (e : Y ⟶ Z) (he) :
    (cokernelIsoOfEq h).hom ≫ cokernel.desc _ e he = cokernel.desc _ e (by simp [h, he])
-- Mathlib/Geometry/Manifold/MFDeriv/FDeriv.lean
theorem uniqueMDiffOn_iff_uniqueDiffOn : UniqueMDiffOn 𝓘(𝕜, E) s ↔ UniqueDiffOn 𝕜 s
-- Mathlib/NumberTheory/LSeries/Dirichlet.lean
/-- The L-series of a Dirichlet character mod `N > 0` converges absolutely at `s` if and only if
`re s > 1`. -/
lemma LSeriesSummable_iff {N : ℕ} (hN : N ≠ 0) (χ : DirichletCharacter ℂ N) {s : ℂ} :
    LSeriesSummable ↗χ s ↔ 1 < s.re
-- Mathlib/Analysis/SpecialFunctions/Complex/Arg.lean
@[simp]
lemma abs_mul_sin_arg (x : ℂ) : abs x * Real.sin (arg x) = x.im
-- Mathlib/Analysis/SpecialFunctions/Trigonometric/Deriv.lean
theorem DifferentiableWithinAt.cosh (hf : DifferentiableWithinAt ℝ f s x) :
    DifferentiableWithinAt ℝ (fun x => Real.cosh (f x)) s x
-- Mathlib/Analysis/NormedSpace/HahnBanach/SeparatingDual.lean
lemma completeSpace_continuousMultilinearMap_iff {m : ∀ i, M i} (hm : ∀ i, m i ≠ 0) :
    CompleteSpace (ContinuousMultilinearMap 𝕜 M F) ↔ CompleteSpace F
-- Mathlib/Geometry/Manifold/LocalInvariantProperties.lean
theorem liftPropWithinAt_univ : LiftPropWithinAt P g univ x ↔ LiftPropAt P g x
-- Mathlib/Analysis/SpecialFunctions/Pow/Real.lean
theorem antitoneOn_rpow_Ioi_of_exponent_nonpos {r : ℝ} (hr : r ≤ 0) :
    AntitoneOn (fun (x : ℝ) => x ^ r) (Set.Ioi 0)
-- Mathlib/Data/Int/Defs.lean
lemma succ_neg_succ (a : ℤ) : succ (-succ a) = -a
-- .lake/packages/lean4/src/lean/Init/Data/List/Lemmas.lean
theorem eq_nil_iff_forall_not_mem {l : List α} : l = [] ↔ ∀ a, a ∉ l
-- Mathlib/CategoryTheory/Limits/IsLimit.lean
@[reassoc (attr := simp)]
theorem conePointUniqueUpToIso_hom_comp {s t : Cone F} (P : IsLimit s) (Q : IsLimit t) (j : J) :
    (conePointUniqueUpToIso P Q).hom ≫ t.π.app j = s.π.app j
-- Mathlib/Algebra/DirectSum/Module.lean
/-- Given `Fintype α`, `linearEquivFunOnFintype R` is the natural `R`-linear equivalence
between `⨁ i, M i` and `∀ i, M i`. -/
@[simps apply]
def linearEquivFunOnFintype [Fintype ι] : (⨁ i, M i) ≃ₗ[R] ∀ i, M i
-- .lake/packages/batteries/Batteries/Data/List/Lemmas.lean
theorem findIdxs_cons :
    (x :: xs : List α).findIdxs p =
      bif p x then 0 :: (xs.findIdxs p).map (· + 1) else (xs.findIdxs p).map (· + 1)
-- Mathlib/Order/WithBot.lean
@[simp]
theorem toDual_symm_apply (a : WithBot αᵒᵈ) : WithTop.toDual.symm a = WithBot.ofDual a
-- Mathlib/Algebra/Homology/HomotopyCategory/HomComplexShift.lean
@[simp]
lemma rightUnshift_add {n' a : ℤ} (γ₁ γ₂ : Cochain K (L⟦a⟧) n') (n : ℤ) (hn : n' + a = n) :
    (γ₁ + γ₂).rightUnshift n hn = γ₁.rightUnshift n hn + γ₂.rightUnshift n hn
-- Mathlib/Topology/Instances/NNReal.lean
@[simp, norm_cast]
theorem tendsto_coe {f : Filter α} {m : α → ℝ≥0} {x : ℝ≥0} :
    Tendsto (fun a => (m a : ℝ)) f (𝓝 (x : ℝ)) ↔ Tendsto m f (𝓝 x)
-- Mathlib/Geometry/Euclidean/PerpBisector.lean
theorem mem_perpBisector_iff_dist_eq : c ∈ perpBisector p₁ p₂ ↔ dist c p₁ = dist c p₂
-- Mathlib/RingTheory/AlgebraicIndependent.lean
theorem algebraicIndependent_comp_subtype {s : Set ι} :
    AlgebraicIndependent R (x ∘ (↑) : s → A) ↔
      ∀ p ∈ MvPolynomial.supported R s, aeval x p = 0 → p = 0
-- Mathlib/Data/Set/Pointwise/Interval.lean
@[simp]
theorem preimage_const_sub_Ici : (fun x => a - x) ⁻¹' Ici b = Iic (a - b)
-- Mathlib/Analysis/Convex/StrictConvexSpace.lean
theorem norm_midpoint_lt_iff (h : ‖x‖ = ‖y‖) : ‖(1 / 2 : ℝ) • (x + y)‖ < ‖x‖ ↔ x ≠ y
-- .lake/packages/lean4/src/lean/Init/Data/List/Lemmas.lean
@[simp]
theorem cons_ne_self (a : α) (l : List α) : a :: l ≠ l
-- Mathlib/LinearAlgebra/Determinant.lean
/-- The determinant of `LinearMap.toMatrix` does not depend on the choice of basis. -/
theorem det_toMatrix_eq_det_toMatrix [DecidableEq κ] (b : Basis ι A M) (c : Basis κ A M)
    (f : M →ₗ[A] M) : det (LinearMap.toMatrix b b f) = det (LinearMap.toMatrix c c f)
-- Mathlib/CategoryTheory/Limits/Shapes/FunctorToTypes.lean
@[ext]
lemma prod_ext {a : C} (z w : (prod F G).obj a) (h1 : z.1 = w.1) (h2 : z.2 = w.2) :
    z = w
-- Mathlib/Algebra/Order/Group/Indicator.lean
@[to_additive]
lemma mulIndicator_iUnion_apply (h1 : (⊥ : M) = 1) (s : ι → Set α) (f : α → M) (x : α) :
    mulIndicator (⋃ i, s i) f x = ⨆ i, mulIndicator (s i) f x
-- Mathlib/Algebra/Ring/Subring/Basic.lean
@[simp, norm_cast]
theorem coe_natCast (n : ℕ) : ((n : s) : R) = n
-- .lake/packages/lean4/src/lean/Init/Data/Nat/Linear.lean
theorem Expr.eq_of_toNormPoly (ctx : Context) (a b : Expr) (h : a.toNormPoly = b.toNormPoly) : a.denote ctx = b.denote ctx
-- Mathlib/GroupTheory/Perm/Subgroup.lean
@[simp]
theorem sumCongrHom.card_range {α β : Type*} [Fintype (sumCongrHom α β).range]
    [Fintype (Perm α × Perm β)] :
    Fintype.card (sumCongrHom α β).range = Fintype.card (Perm α × Perm β)
-- Mathlib/Analysis/BoxIntegral/Partition/Filter.lean
theorem tendsto_embedBox_toFilteriUnion_top (l : IntegrationParams) (h : I ≤ J) :
    Tendsto (TaggedPrepartition.embedBox I J h) (l.toFilteriUnion I ⊤)
      (l.toFilteriUnion J (Prepartition.single J I h))
-- Mathlib/Data/Stream/Init.lean
@[simp] theorem concat_take_get {n : ℕ} {s : Stream' α} : s.take n ++ [s.get n] = s.take (n+1)
-- Mathlib/LinearAlgebra/TensorProduct/Subalgebra.lean
theorem mulMap_bot_right_eq : mulMap A ⊥ = A.val.comp A.rTensorBot.toAlgHom
-- Mathlib/Algebra/Ring/Idempotents.lean
@[simp]
theorem one_compl : (1 : { p : R // IsIdempotentElem p })ᶜ = 0
-- Mathlib/Algebra/Star/StarRingHom.lean
@[simp]
theorem coe_mk (f : A →ₙ+* B) (h) :
    ((⟨f, h⟩ : A  →⋆ₙ+* B) : A → B) = f
-- Mathlib/Analysis/Convex/Hull.lean
@[simp]
theorem affineSpan_convexHull (s : Set E) : affineSpan 𝕜 (convexHull 𝕜 s) = affineSpan 𝕜 s
-- Mathlib/AlgebraicGeometry/StructureSheaf.lean
theorem IsFraction.eq_mk' {U : Opens (PrimeSpectrum.Top R)} {f : ∀ x : U, Localizations R x}
    (hf : IsFraction f) :
    ∃ r s : R,
      ∀ x : U,
        ∃ hs : s ∉ x.1.asIdeal,
          f x =
            IsLocalization.mk' (Localization.AtPrime _) r
              (⟨s, hs⟩ : (x : PrimeSpectrum.Top R).asIdeal.primeCompl)
-- Mathlib/Topology/Algebra/Group/Basic.lean
@[to_additive]
theorem TopologicalGroup.ext {G : Type*} [Group G] {t t' : TopologicalSpace G}
    (tg : @TopologicalGroup G t _) (tg' : @TopologicalGroup G t' _)
    (h : @nhds G t 1 = @nhds G t' 1) : t = t'
-- Mathlib/MeasureTheory/Constructions/Prod/Basic.lean
@[simp]
lemma fst_prod [IsProbabilityMeasure ν] : (μ.prod ν).fst = μ
-- Mathlib/Analysis/NormedSpace/IndicatorFunction.lean
theorem indicator_norm_le_norm_self : indicator s (fun a => ‖f a‖) a ≤ ‖f a‖
-- Mathlib/Algebra/Polynomial/Basic.lean
private irreducible_def mul : R[X] → R[X] → R[X]
-- Mathlib/Topology/Category/TopCat/Limits/Pullbacks.lean
theorem pullback_snd_range {X Y S : TopCat} (f : X ⟶ S) (g : Y ⟶ S) :
    Set.range (pullback.snd f g) = { y : Y | ∃ x : X, f x = g y }
-- Mathlib/Data/Real/Pointwise.lean
theorem Real.sSup_smul_of_nonneg (ha : 0 ≤ a) (s : Set ℝ) : sSup (a • s) = a • sSup s
-- Mathlib/Analysis/Calculus/FDeriv/Basic.lean
theorem fderiv_const_apply (c : F) : fderiv 𝕜 (fun _ => c) x = 0
-- Mathlib/FieldTheory/SeparableDegree.lean
/-- If a polynomial has separable contraction, then its separable degree is equal to the degree of
the given separable contraction. -/
theorem HasSeparableContraction.natSepDegree_eq
    {q : ℕ} [ExpChar F q] (hf : f.HasSeparableContraction q) :
    f.natSepDegree = hf.degree
-- Mathlib/Data/Real/GoldenRatio.lean
/-- The opposite of the golden ratio is the inverse of its conjugate. -/
theorem inv_goldConj : ψ⁻¹ = -φ
-- Mathlib/Analysis/BoxIntegral/Partition/Additive.lean
@[simp]
theorem map_split_add (f : ι →ᵇᵃ[I₀] M) (hI : ↑I ≤ I₀) (i : ι) (x : ℝ) :
    (I.splitLower i x).elim' 0 f + (I.splitUpper i x).elim' 0 f = f I
-- Mathlib/RingTheory/MvPolynomial/Symmetric.lean
@[simp]
theorem rename_psum (n : ℕ) (e : σ ≃ τ) : rename e (psum σ R n) = psum τ R n
-- Mathlib/Deprecated/Subgroup.lean
@[to_additive]
theorem mclosure_inv_subset {s : Set G} : Monoid.Closure (Inv.inv ⁻¹' s) ⊆ closure s
-- Mathlib/Probability/Independence/Basic.lean
lemma iIndepFun.indepFun_prod_mk (hf_Indep : iIndepFun m f μ) (hf_meas : ∀ i, Measurable (f i))
    (i j k : ι) (hik : i ≠ k) (hjk : j ≠ k) :
    IndepFun (fun a => (f i a, f j a)) (f k) μ
-- Mathlib/Order/Interval/Set/OrdConnected.lean
theorem OrdConnected.out (h : OrdConnected s) : ∀ ⦃x⦄ (_ : x ∈ s) ⦃y⦄ (_ : y ∈ s), Icc x y ⊆ s
-- Mathlib/FieldTheory/RatFunc/Basic.lean
/-- `RatFunc K` is isomorphic to the field of fractions of `K[X]`, as rings.

This is an auxiliary definition; `simp`-normal form is `IsLocalization.algEquiv`.
-/
@[simps apply]
def toFractionRingRingEquiv : RatFunc K ≃+* FractionRing K[X]
-- Mathlib/Algebra/Order/Monoid/ToMulBot.lean
@[simp]
theorem toMulBot_coe_ofAdd (x : α) :
    toMulBot.symm (Multiplicative.ofAdd (x : WithBot α)) = Multiplicative.ofAdd x
-- Mathlib/Algebra/EuclideanDomain/Defs.lean
theorem val_dvd_le : ∀ a b : R, b ∣ a → a ≠ 0 → ¬a ≺ b
-- Mathlib/Data/Seq/Computation.lean
@[simp]
theorem map_id : ∀ s : Computation α, map id s = s
-- Mathlib/Order/Sublattice.lean
@[simp] lemma subtype_comp_inclusion (h : L ≤ M) : M.subtype.comp (inclusion h) = L.subtype
-- Mathlib/Topology/ContinuousFunction/Polynomial.lean
/-- The preimage of polynomials on `[0,1]` under the pullback map by `x ↦ (b-a) * x + a`
is the polynomials on `[a,b]`. -/
theorem polynomialFunctions.comap_compRightAlgHom_iccHomeoI (a b : ℝ) (h : a < b) :
    (polynomialFunctions I).comap (compRightAlgHom ℝ ℝ (iccHomeoI a b h).symm.toContinuousMap) =
      polynomialFunctions (Set.Icc a b)
-- Mathlib/GroupTheory/Perm/Finite.lean
@[simp]
theorem subtypePermOfFintype_apply (f : Perm α) {p : α → Prop} [Finite { x // p x }]
    (h : ∀ x, p x → p (f x)) (x : { x // p x }) : subtypePermOfFintype f h x = ⟨f x, h x x.2⟩
-- Mathlib/CategoryTheory/Localization/CalculusOfFractions/Preadditive.lean
lemma add_eq (f₁ f₂ : X' ⟶ Y') :
    letI := addCommGroup L W X' Y'
    f₁ + f₂ = add W eX eY f₁ f₂
-- Mathlib/Data/Set/Finite.lean
/-- Gives a `Set.Finite` for the `Finset` coerced to a `Set`.
This is a wrapper around `Set.toFinite`. -/
@[simp]
theorem finite_toSet (s : Finset α) : (s : Set α).Finite
-- Mathlib/Data/Matroid/Constructions.lean
theorem eq_emptyOn_or_nonempty (M : Matroid α) : M = emptyOn α ∨ Matroid.Nonempty M
-- Mathlib/Topology/ContinuousFunction/StoneWeierstrass.lean
/-- Given a continuous function `f` in a subalgebra of `C(X, ℝ)`, postcomposing by a polynomial
gives another function in `A`.

This lemma proves something slightly more subtle than this:
we take `f`, and think of it as a function into the restricted target `Set.Icc (-‖f‖) ‖f‖)`,
and then postcompose with a polynomial function on that interval.
This is in fact the same situation as above, and so also gives a function in `A`.
-/
theorem polynomial_comp_attachBound_mem (A : Subalgebra ℝ C(X, ℝ)) (f : A) (g : ℝ[X]) :
    (g.toContinuousMapOn (Set.Icc (-‖f‖) ‖f‖)).comp (f : C(X, ℝ)).attachBound ∈ A
-- Mathlib/Algebra/Order/Module/Defs.lean
lemma pos_iff_pos_of_smul_pos [PosSMulReflectLT α β] [SMulPosReflectLT α β] (hab : 0 < a • b) :
    0 < a ↔ 0 < b
-- Mathlib/Order/Monotone/Basic.lean
theorem monotone_dual_iff : Monotone (toDual ∘ f ∘ ofDual : αᵒᵈ → βᵒᵈ) ↔ Monotone f
-- Mathlib/Data/Bool/Basic.lean
theorem and_eq_true_eq_eq_true_and_eq_true (a b : Bool) :
    ((a && b) = true) = (a = true ∧ b = true)
-- Mathlib/Data/Nat/Totient.lean
theorem totient_le (n : ℕ) : φ n ≤ n
-- Mathlib/MeasureTheory/Integral/IntegralEqImproper.lean
theorem aecover_Ioi [NoMinOrder α] : AECover μ l fun i => Ioi (a i)
-- Mathlib/Analysis/Complex/Basic.lean
@[simp]
theorem im_to_complex {x : ℂ} : imC x = x.im
-- Mathlib/RingTheory/ChainOfDivisors.lean
theorem eq_pow_second_of_chain_of_has_chain {q : Associates M} {n : ℕ} (hn : n ≠ 0)
    {c : Fin (n + 1) → Associates M} (h₁ : StrictMono c)
    (h₂ : ∀ {r : Associates M}, r ≤ q ↔ ∃ i, r = c i) (hq : q ≠ 0) : q = c 1 ^ n
-- Mathlib/Order/Monotone/Basic.lean
protected theorem StrictMonoOn.compares (hf : StrictMonoOn f s) {a b : α} (ha : a ∈ s)
    (hb : b ∈ s) : ∀ {o : Ordering}, o.Compares (f a) (f b) ↔ o.Compares a b
-- Mathlib/Data/Set/UnionLift.lean
/-- `iUnionLift_const` is useful for proving that `iUnionLift` is a homomorphism
  of algebraic structures when defined on the Union of algebraic subobjects.
  For example, it could be used to prove that the lift of a collection
  of group homomorphisms on a union of subgroups preserves `1`. -/
theorem iUnionLift_const (c : T) (ci : ∀ i, S i) (hci : ∀ i, (ci i : α) = c) (cβ : β)
    (h : ∀ i, f i (ci i) = cβ) : iUnionLift S f hf T hT c = cβ
-- Mathlib/Data/Bool/Count.lean
@[simp]
theorem count_true_add_count_false (l : List Bool) : count true l + count false l = length l
-- Mathlib/Order/BoundedOrder.lean
@[simp] theorem up_top [Top α] : up (⊤ : α) = ⊤
-- Mathlib/Data/Fin/SuccPred.lean
@[simp]
theorem succ_eq {n : ℕ} : SuccOrder.succ = fun a => if a < Fin.last n then a + 1 else a
-- Mathlib/LinearAlgebra/TensorProduct/Vanishing.lean
/-- Every expression $\sum_i m_i \otimes n_i$ which vanishes also vanishes trivially if and only if
for every submodule $M' \subseteq M$, the map $M' \otimes N \to M \otimes N$ is injective. -/
theorem forall_vanishesTrivially_iff_forall_rTensor_injective :
    (∀ {ι : Type u} [Fintype ι] {m : ι → M} {n : ι → N},
      ∑ i, m i ⊗ₜ n i = (0 : M ⊗[R] N) → VanishesTrivially R m n) ↔
    ∀ M' : Submodule R M, Injective (rTensor N M'.subtype)