ruc-ai4math/mathlib_handler_benchmark_410 huggingface dataset:
-- Mathlib/GroupTheory/FreeGroup/Basic.lean
@[to_additive]
theorem map.comp {γ : Type w} (f : α → β) (g : β → γ) (x) :
    map g (map f x) = map (g ∘ f) x
-- Mathlib/Order/Filter/AtTopBot.lean
theorem eventually_atTop_prod_self [SemilatticeSup α] [Nonempty α] {p : α × α → Prop} :
    (∀ᶠ x in atTop, p x) ↔ ∃ a, ∀ k l, a ≤ k → a ≤ l → p (k, l)
-- Mathlib/RingTheory/Polynomial/Cyclotomic/Basic.lean
/-- If `p` is prime, then `cyclotomic p R = ∑ i ∈ range p, X ^ i`. -/
theorem cyclotomic_prime (R : Type*) [Ring R] (p : ℕ) [hp : Fact p.Prime] :
    cyclotomic p R = ∑ i ∈ Finset.range p, X ^ i
-- Mathlib/CategoryTheory/Opposites.lean
/-- The equivalence between isomorphisms of the form `A ≅ B` and `B.unop ≅ A.unop`.

Note this is definitionally the same as the other three variants:
* `(Opposite.op A ≅ B) ≃ (B.unop ≅ A)`
* `(A ≅ Opposite.op B) ≃ (B ≅ A.unop)`
* `(Opposite.op A ≅ Opposite.op B) ≃ (B ≅ A)`
-/
@[simps]
def isoOpEquiv (A B : Cᵒᵖ) : (A ≅ B) ≃ (B.unop ≅ A.unop)
-- Mathlib/Analysis/SpecialFunctions/Log/ENNRealLog.lean
@[simp] lemma bot_lt_log_iff {x : ℝ≥0∞} : ⊥ < log x ↔ 0 < x
-- Mathlib/CategoryTheory/Bicategory/Kan/IsKan.lean
/-- Two 2-morphisms out of a left Kan lift are equal if their compositions with
each triangle 2-morphism are equal. -/
theorem hom_ext (H : IsKan t) {k : c ⟶ b} {τ τ' : t.lift ⟶ k}
    (w : t.unit ≫ τ ▷ f = t.unit ≫ τ' ▷ f) : τ = τ'
-- Mathlib/Data/Nat/Prime/Basic.lean
theorem coprime_primes {p q : ℕ} (pp : Prime p) (pq : Prime q) : Coprime p q ↔ p ≠ q
-- Mathlib/MeasureTheory/Constructions/Projective.lean
/-- Auxiliary lemma for `measure_univ_eq`. -/
lemma measure_univ_eq_of_subset (hP : IsProjectiveMeasureFamily P) (hJI : J ⊆ I) :
    P I univ = P J univ
-- Mathlib/Topology/Order/LocalExtr.lean
nonrec theorem IsLocalMaxOn.congr {f g : α → β} {a : α} (h : IsLocalMaxOn f s a)
    (heq : f =ᶠ[𝓝[s] a] g) (hmem : a ∈ s) : IsLocalMaxOn g s a
-- Mathlib/CategoryTheory/Limits/Constructions/Over/Products.lean
/-- Given all wide pullbacks in `C`, construct products in `C/B`. -/
theorem over_products_of_widePullbacks [HasWidePullbacks.{w} C] {B : C} :
    HasProducts.{w} (Over B)
-- Mathlib/Analysis/Calculus/ContDiff/Basic.lean
@[nontriviality]
theorem contDiffAt_of_subsingleton [Subsingleton F] : ContDiffAt 𝕜 n f x
-- Mathlib/Order/Circular.lean
theorem btw_cyclic_right {a b c : α} (h : btw a b c) : btw c a b
-- Mathlib/Algebra/Group/Equiv/Basic.lean
@[to_additive]
theorem ext_iff {f g : MulEquiv M N} : f = g ↔ ∀ x, f x = g x
-- Mathlib/GroupTheory/PGroup.lean
theorem of_card {n : ℕ} (hG : Nat.card G = p ^ n) : IsPGroup p G
-- Mathlib/MeasureTheory/Integral/IntervalIntegral.lean
theorem inv_smul_integral_comp_div_add (c d) :
    (c⁻¹ • ∫ x in a..b, f (x / c + d)) = ∫ x in a / c + d..b / c + d, f x
-- Mathlib/NumberTheory/LSeries/HurwitzZetaValues.lean
/-- Reformulation of `cosZeta_two_mul_nat` using `Gammaℂ`. -/
theorem cosZeta_two_mul_nat' (hk : k ≠ 0) (hx : x ∈ Icc (0 : ℝ) 1) :
    cosZeta x (2 * k) = (-1) ^ (k + 1) / (2 * k) / Gammaℂ (2 * k) *
      ((Polynomial.bernoulli (2 * k)).map (algebraMap ℚ ℂ)).eval (x : ℂ)
-- Mathlib/LinearAlgebra/AffineSpace/Basis.lean
@[simp]
theorem reindex_refl : b.reindex (Equiv.refl _) = b
-- Mathlib/Data/ZMod/Basic.lean
theorem valMinAbs_natCast_of_le_half (ha : a ≤ n / 2) : (a : ZMod n).valMinAbs = a
-- Mathlib/Data/Nat/PartENat.lean
theorem le_def (x y : PartENat) :
    x ≤ y ↔ ∃ h : y.Dom → x.Dom, ∀ hy : y.Dom, x.get (h hy) ≤ y.get hy
-- Mathlib/Data/DFinsupp/Order.lean
lemma coe_mono : Monotone ((⇑) : (Π₀ i, α i) → ∀ i, α i)
-- Mathlib/AlgebraicTopology/DoldKan/Projections.lean
/-- For each `q`, `Q q` is a natural transformation. -/
@[simps]
def natTransQ (q : ℕ) : alternatingFaceMapComplex C ⟶ alternatingFaceMapComplex C
-- Mathlib/Data/Sum/Interval.lean
@[simp]
lemma sumLexLift_inl_inl (a : α₁) (b : β₁) :
    sumLexLift f₁ f₂ g₁ g₂ (inl a) (inl b) = (f₁ a b).map Embedding.inl
-- Mathlib/Data/Vector/Defs.lean
/-- `take` of vectors corresponds under `toList` to `take` of lists. -/
@[simp]
theorem toList_take {n m : ℕ} (v : Vector α m) : toList (take n v) = List.take n (toList v)
-- Mathlib/Algebra/BigOperators/Ring.lean
@[simp] lemma sum_boole (p) [DecidablePred p] (s : Finset ι) :
    (∑ x ∈ s, if p x then 1 else 0 : α) = (s.filter p).card
-- Mathlib/Algebra/BigOperators/Finprod.lean
@[to_additive]
theorem finprod_unique [Unique α] (f : α → M) : ∏ᶠ i, f i = f default
-- Mathlib/MeasureTheory/Function/L1Space.lean
theorem Integrable.smul_const {f : α → 𝕜} (hf : Integrable f μ) (c : β) :
    Integrable (fun x => f x • c) μ
-- Mathlib/RingTheory/MvPowerSeries/Basic.lean
theorem coeff_X [DecidableEq σ] (n : σ →₀ ℕ) (s : σ) :
    coeff R n (X s : MvPowerSeries σ R) = if n = single s 1 then 1 else 0
-- Mathlib/Data/Finset/Interval.lean
/-- A function `f` from `Finset α` is strictly antitone if and only if `f (insert a s) < f s` for
all `s` and `a ∉ s`. -/
lemma strictAnti_iff_forall_lt_insert : StrictAnti f ↔ ∀ s ⦃a⦄, a ∉ s → f (insert a s) < f s
-- Mathlib/Data/Matroid/Basic.lean
theorem Base.infinite [InfiniteRk M] (hB : M.Base B) : B.Infinite
-- .lake/packages/batteries/Batteries/Data/Fin/Lemmas.lean
theorem foldl_loop (f : α → Fin (n+1) → α) (x) (h : m < n+1) :
    foldl.loop (n+1) f x m = foldl.loop n (fun x i => f x i.succ) (f x ⟨m, h⟩) m
-- Mathlib/LinearAlgebra/Span.lean
/-- A version of `Submodule.span_le_restrictScalars` with coercions. -/
@[simp]
theorem span_subset_span [Semiring S] [SMul R S] [Module S M] [IsScalarTower R S M] :
    ↑(span R s) ⊆ (span S s : Set M)
-- Mathlib/Analysis/CstarAlgebra/GelfandDuality.lean
theorem WeakDual.CharacterSpace.mem_spectrum_iff_exists {a : A} {z : ℂ} :
    z ∈ spectrum ℂ a ↔ ∃ f : characterSpace ℂ A, f a = z
-- Mathlib/Topology/ClopenBox.lean
lemma TopologicalSpace.Clopens.countable_iff_second_countable [T2Space X]
    [TotallyDisconnectedSpace X] : Countable (Clopens X) ↔ SecondCountableTopology X
-- Mathlib/Analysis/Convex/Deriv.lean
lemma derivWithin_lt_slope (hfc : StrictConcaveOn ℝ S f) (hx : x ∈ S) (hy : y ∈ S) (hxy : x < y)
    (hfd : DifferentiableWithinAt ℝ f S y) :
    derivWithin f S y < slope f x y
-- Mathlib/Data/Set/Defs.lean
@[simp] theorem mem_image2 : c ∈ image2 f s t ↔ ∃ a ∈ s, ∃ b ∈ t, f a b = c
-- Mathlib/MeasureTheory/Constructions/Prod/Basic.lean
/-- The reversed version of **Tonelli's Theorem** (symmetric version). In this version `f` is in
curried form, which makes it easier for the elaborator to figure out `f` automatically. -/
theorem lintegral_lintegral_symm [SFinite μ] ⦃f : α → β → ℝ≥0∞⦄
    (hf : AEMeasurable (uncurry f) (μ.prod ν)) :
    ∫⁻ x, ∫⁻ y, f x y ∂ν ∂μ = ∫⁻ z, f z.2 z.1 ∂ν.prod μ
-- Mathlib/Topology/Algebra/UniformRing.lean
@[simp]
theorem map_smul_eq_mul_coe (r : R) :
    Completion.map (r • ·) = ((algebraMap R A r : Completion A) * ·)
-- Mathlib/Data/Quot.lean
/-- `Quotient.mk''` is a surjective function. -/
theorem surjective_Quotient_mk'' : Function.Surjective (Quotient.mk'' : α → Quotient s₁)
-- Mathlib/Algebra/Periodic.lean
protected theorem Antiperiodic.funext [Add α] [Neg β] (h : Antiperiodic f c) :
    (fun x => f (x + c)) = -f
-- Mathlib/MeasureTheory/Function/LpSpace/DomAct/Basic.lean
@[to_additive (attr := simp)]
theorem smul_Lp_val (c : Mᵈᵐᵃ) (f : Lp E p μ) : (c • f).1 = c • f.1
-- Mathlib/Algebra/GroupWithZero/Units/Lemmas.lean
@[simp]
theorem map_eq_zero : f a = 0 ↔ a = 0
-- Mathlib/GroupTheory/GroupAction/Hom.lean
protected theorem map_zero (f : R →ₑ+*[φ] S) : f 0 = 0
-- Mathlib/Topology/MetricSpace/Antilipschitz.lean
theorem to_rightInverse (hf : AntilipschitzWith K f) {g : β → α} (hg : Function.RightInverse g f) :
    LipschitzWith K g
-- .lake/packages/lean4/src/lean/Init/Data/Array/Lemmas.lean
theorem extract_loop_zero (as bs : Array α) (start : Nat) : extract.loop as 0 start bs = bs
-- Mathlib/Topology/Algebra/Module/Basic.lean
theorem Submodule.smul_closure_subset (s : Submodule R M) (c : R) :
    c • closure (s : Set M) ⊆ closure (s : Set M)
-- Mathlib/Order/Interval/Set/Basic.lean
theorem Ioi_subset_Ioc_union_Ici : Ioi a ⊆ Ioc a b ∪ Ici b
-- Mathlib/Algebra/Order/Monoid/Unbundled/Basic.lean
@[to_additive const_add]
theorem StrictAntiOn.const_mul' (hf : StrictAntiOn f s) (c : α) :
    StrictAntiOn (fun x => c * f x) s
-- Mathlib/MeasureTheory/Integral/IntervalIntegral.lean
theorem integral_add_adjacent_intervals_cancel (hab : IntervalIntegrable f μ a b)
    (hbc : IntervalIntegrable f μ b c) :
    (((∫ x in a..b, f x ∂μ) + ∫ x in b..c, f x ∂μ) + ∫ x in c..a, f x ∂μ) = 0
-- Mathlib/RingTheory/Ideal/MinimalPrime.lean
theorem Ideal.exists_minimalPrimes_comap_eq {I : Ideal S} (f : R →+* S) (p)
    (H : p ∈ (I.comap f).minimalPrimes) : ∃ p' ∈ I.minimalPrimes, Ideal.comap f p' = p
-- Mathlib/Algebra/Order/Floor.lean
@[simp]
theorem lt_floor_add_one (a : α) : a < ⌊a⌋ + 1
-- Mathlib/RingTheory/LaurentSeries.lean
@[simp]
theorem single_order_mul_powerSeriesPart (x : LaurentSeries R) :
    (single x.order 1 : LaurentSeries R) * x.powerSeriesPart = x
-- Mathlib/SetTheory/Ordinal/Notation.lean
theorem oadd_lt_oadd_2 {e o₁ o₂ : ONote} {n₁ n₂ : ℕ+} (h₁ : NF (oadd e n₁ o₁)) (h : (n₁ : ℕ) < n₂) :
    oadd e n₁ o₁ < oadd e n₂ o₂
-- Mathlib/CategoryTheory/Monoidal/Center.lean
@[simp]
theorem leftUnitor_inv_f (X : Center C) : Hom.f (λ_ X).inv = (λ_ X.1).inv
-- Mathlib/Algebra/Polynomial/Degree/Definitions.lean
theorem eq_X_add_C_of_degree_le_one (h : degree p ≤ 1) : p = C (p.coeff 1) * X + C (p.coeff 0)
-- Mathlib/Analysis/Calculus/Deriv/Pow.lean
theorem derivWithin_pow (hxs : UniqueDiffWithinAt 𝕜 s x) :
    derivWithin (fun x : 𝕜 => x ^ n) s x = (n : 𝕜) * x ^ (n - 1)
-- Mathlib/Data/List/Sort.lean
theorem split_cons_of_eq (a : α) {l l₁ l₂ : List α} (h : split l = (l₁, l₂)) :
    split (a :: l) = (a :: l₂, l₁)
-- Mathlib/NumberTheory/NumberField/CanonicalEmbedding/Basic.lean
protected theorem norm_apply (x : E K) :
    mixedEmbedding.norm x = ∏ w, (normAtPlace w x) ^ (mult w)
-- Mathlib/Algebra/Group/Subgroup/Basic.lean
/-- A subgroup is characteristic if it is fixed by all automorphisms.
  Several equivalent conditions are provided by lemmas of the form `Characteristic.iff...` -/
structure Characteristic : Prop where
  /-- `H` is fixed by all automorphisms -/
  fixed : ∀ ϕ : G ≃* G, H.comap ϕ.toMonoidHom = H
-- Mathlib/Algebra/QuaternionBasis.lean
/-- There is a natural quaternionic basis for the `QuaternionAlgebra`. -/
@[simps i j k]
protected def self : Basis ℍ[R,c₁,c₂] c₁ c₂
-- Mathlib/Order/SymmDiff.lean
theorem Codisjoint.bihimp_inf_bihimp_le_right (h : Codisjoint b c) : a ⇔ b ⊓ a ⇔ c ≤ a
-- Mathlib/Data/Prod/Basic.lean
@[simp]
theorem «forall» {p : α × β → Prop} : (∀ x, p x) ↔ ∀ a b, p (a, b)
-- Mathlib/Order/Interval/Finset/Fin.lean
@[simp]
theorem map_valEmbedding_Ici : (Ici a).map Fin.valEmbedding = Icc ↑a (n - 1)
-- Mathlib/Algebra/Group/Subsemigroup/Operations.lean
@[to_additive (attr := simp)]
theorem coe_subtype : (MulMemClass.subtype S' : S' → M) = Subtype.val
-- Mathlib/Analysis/LocallyConvex/WithSeminorms.lean
theorem basisSets_zero (U) (hU : U ∈ p.basisSets) : (0 : E) ∈ U
-- Mathlib/RingTheory/WittVector/Frobenius.lean
theorem bind₁_frobeniusPolyRat_wittPolynomial (n : ℕ) :
    bind₁ (frobeniusPolyRat p) (wittPolynomial p ℚ n) = wittPolynomial p ℚ (n + 1)
-- Mathlib/CategoryTheory/Sites/ConcreteSheafification.lean
@[simps! hom_app inv_app]
noncomputable
def GrothendieckTopology.sheafificationIsoPresheafToSheafCompSheafToPreasheaf :
    J.sheafification D ≅ plusPlusSheaf J D ⋙ sheafToPresheaf J D
-- Mathlib/Algebra/Homology/HomotopyCofiber.lean
lemma inlX_nullHomotopy_f (i j : ι) (hij : c.Rel j i) :
    inlX K i j hij ≫ (nullHomotopicMap K).f j =
      inlX K i j hij ≫ (π K ≫ ι₀ K - 𝟙 _).f j
-- Mathlib/Analysis/Normed/Group/Hom.lean
@[simp]
theorem sub_apply (f g : NormedAddGroupHom V₁ V₂) (v : V₁) :
    (f - g : NormedAddGroupHom V₁ V₂) v = f v - g v
-- Mathlib/MeasureTheory/Measure/WithDensityVectorMeasure.lean
theorem Integrable.withDensityᵥ_trim_absolutelyContinuous {m m0 : MeasurableSpace α} {μ : Measure α}
    (hm : m ≤ m0) (hfi : Integrable f μ) :
    (μ.withDensityᵥ f).trim hm ≪ᵥ (μ.trim hm).toENNRealVectorMeasure
-- Mathlib/Topology/DenseEmbedding.lean
theorem extend_eq [T2Space γ] {f : α → γ} (hf : Continuous f) (a : α) : di.extend f (i a) = f a
-- Mathlib/Data/DFinsupp/Basic.lean
@[simp]
theorem erase_neg {β : ι → Type v} [∀ i, AddGroup (β i)] (i : ι) (f : Π₀ i, β i) :
    (-f).erase i = -f.erase i
-- Mathlib/Algebra/Order/Rearrangement.lean
/-- **Strict inequality case of the Rearrangement Inequality**: Pointwise multiplication of
`f` and `g`, which monovary together, is strictly decreased by a permutation if and only if
`f` and `g ∘ σ` do not monovary together. Stated by permuting the entries of `g`. -/
theorem Monovary.sum_comp_perm_mul_lt_sum_mul_iff (hfg : Monovary f g) :
    ∑ i, f (σ i) * g i < ∑ i, f i * g i ↔ ¬Monovary (f ∘ σ) g
-- Mathlib/Data/Finset/Basic.lean
@[simp, aesop safe apply (rule_sets := [finsetNonempty])]
theorem nonempty_range_iff : (range n).Nonempty ↔ n ≠ 0
-- Mathlib/Algebra/Group/Subgroup/Finite.lean
@[to_additive]
theorem eq_bot_of_card_le [Finite H] (h : Nat.card H ≤ 1) : H = ⊥
-- Mathlib/Order/ModularLattice.lean
theorem covBy_sup_of_inf_covBy_right : a ⊓ b ⋖ b → a ⋖ a ⊔ b
-- Mathlib/Data/Holor.lean
theorem cprankMax_add [Monoid α] [AddMonoid α] :
    ∀ {m : ℕ} {n : ℕ} {x : Holor α ds} {y : Holor α ds},
      CPRankMax m x → CPRankMax n y → CPRankMax (m + n) (x + y)
-- Mathlib/Topology/Separation.lean
/-- In a regular space, if a compact set and a closed set are disjoint, then they have disjoint
neighborhoods. -/
lemma SeparatedNhds.of_isCompact_isClosed {s t : Set X}
    (hs : IsCompact s) (ht : IsClosed t) (hst : Disjoint s t) : SeparatedNhds s t
-- Mathlib/Probability/Process/Stopping.lean
theorem memℒp_stoppedProcess_of_mem_finset (hτ : IsStoppingTime ℱ τ) (hu : ∀ n, Memℒp (u n) p μ)
    (n : ι) {s : Finset ι} (hbdd : ∀ ω, τ ω < n → τ ω ∈ s) : Memℒp (stoppedProcess u τ n) p μ
-- Mathlib/Algebra/Ring/CentroidHom.lean
@[simp]
theorem toEnd_sub (x y : CentroidHom α) : (x - y).toEnd = x.toEnd - y.toEnd
-- Mathlib/Algebra/Order/Floor.lean
@[simp]
theorem round_eq_zero_iff {x : α} : round x = 0 ↔ x ∈ Ico (-(1 / 2)) ((1 : α) / 2)
-- Mathlib/Analysis/InnerProductSpace/Orthogonal.lean
theorem IsOrtho.map (f : E →ₗᵢ[𝕜] F) {U V : Submodule 𝕜 E} (h : U ⟂ V) : U.map f ⟂ V.map f
-- Mathlib/CategoryTheory/Comma/StructuredArrow.lean
/-- To construct a morphism of structured arrows,
we need a morphism of the objects underlying the target,
and to check that the triangle commutes.
-/
@[simps]
def homMk {f f' : StructuredArrow S T} (g : f.right ⟶ f'.right)
    (w : f.hom ≫ T.map g = f'.hom := by aesop_cat) : f ⟶ f'
-- Mathlib/Algebra/Homology/QuasiIso.lean
lemma quasiIsoAt_iff' (f : K ⟶ L) (i j k : ι) (hi : c.prev j = i) (hk : c.next j = k)
    [K.HasHomology j] [L.HasHomology j] [(K.sc' i j k).HasHomology] [(L.sc' i j k).HasHomology] :
    QuasiIsoAt f j ↔
      ShortComplex.QuasiIso ((shortComplexFunctor' C c i j k).map f)
-- Mathlib/Algebra/Order/Floor.lean
theorem fract_mul_nat (a : α) (b : ℕ) : ∃ z : ℤ, fract a * b - fract (a * b) = z
-- Mathlib/Algebra/Homology/ShortComplex/HomologicalComplex.lean
@[simp]
lemma homologyMap_add : homologyMap (φ + ψ) i = homologyMap φ i + homologyMap ψ i
-- Mathlib/NumberTheory/ArithmeticFunction.lean
@[arith_mult]
theorem isMultiplicative_sigma {k : ℕ} : IsMultiplicative (σ k)
-- Mathlib/Topology/Instances/ENNReal.lean
theorem tsum_comp_le_tsum_of_injective {f : α → β} (hf : Injective f) (g : β → ℝ≥0∞) :
    ∑' x, g (f x) ≤ ∑' y, g y
-- Mathlib/Algebra/BigOperators/Pi.lean
/-- decomposing `x : ι → R` as a sum along the canonical basis -/
theorem pi_eq_sum_univ {ι : Type*} [Fintype ι] [DecidableEq ι] {R : Type*} [Semiring R]
    (x : ι → R) : x = ∑ i, (x i) • fun j => if i = j then (1 : R) else 0
-- Mathlib/Algebra/BigOperators/Group/Multiset.lean
@[to_additive (attr := simp, norm_cast)]
theorem prod_coe (l : List α) : prod ↑l = l.prod
-- Mathlib/LinearAlgebra/Matrix/NonsingularInverse.lean
/-- If matrix A is left invertible, then its inverse equals its left inverse. -/
theorem inv_eq_left_inv (h : B * A = 1) : A⁻¹ = B
-- Mathlib/Analysis/Convex/Combination.lean
/-- A weak version of Carathéodory's theorem. -/
theorem convexHull_eq_union_convexHull_finite_subsets (s : Set E) :
    convexHull R s = ⋃ (t : Finset E) (w : ↑t ⊆ s), convexHull R ↑t
-- Mathlib/Data/NNReal/Basic.lean
theorem div_lt_one_of_lt {a b : ℝ≥0} (h : a < b) : a / b < 1
-- Mathlib/Algebra/BigOperators/Group/Finset.lean
@[simp]
theorem sum_multiset_singleton (s : Finset α) : (s.sum fun x => {x}) = s.val
-- Mathlib/CategoryTheory/Limits/Cones.lean
/-- A map to the vertex of a cone naturally induces a cone by composition. -/
@[simps]
def extensions (c : Cone F) : yoneda.obj c.pt ⋙ uliftFunctor.{u₁} ⟶ F.cones
-- Mathlib/Data/ENNReal/Basic.lean
theorem lt_iff_exists_nnreal_btwn : a < b ↔ ∃ r : ℝ≥0, a < r ∧ (r : ℝ≥0∞) < b
-- Mathlib/Topology/Separation.lean
/-- A T₀ space, also known as a Kolmogorov space, is a topological space such that for every pair
`x ≠ y`, there is an open set containing one but not the other. We formulate the definition in terms
of the `Inseparable` relation.  -/
class T0Space (X : Type u) [TopologicalSpace X] : Prop where
  /-- Two inseparable points in a T₀ space are equal. -/
  t0 : ∀ ⦃x y : X⦄, Inseparable x y → x = y
-- Mathlib/RingTheory/NonUnitalSubsemiring/Basic.lean
theorem closure_eq_of_le {s : Set R} {t : NonUnitalSubsemiring R} (h₁ : s ⊆ t)
    (h₂ : t ≤ closure s) : closure s = t
-- Mathlib/LinearAlgebra/TensorProduct/Subalgebra.lean
theorem mulMap_toLinearMap : (A.mulMap B).toLinearMap = (toSubmodule A).mulMap (toSubmodule B)
-- Mathlib/CategoryTheory/Limits/VanKampen.lean
theorem NatTrans.equifibered_of_discrete {ι : Type*} {F G : Discrete ι ⥤ C}
    (α : F ⟶ G) : NatTrans.Equifibered α
-- Mathlib/Algebra/Homology/ShortComplex/RightHomology.lean
/-- The opposite of the left homology functor is the right homology functor. -/
@[simps!]
noncomputable def leftHomologyFunctorOpNatIso :
    (leftHomologyFunctor C).op ≅ opFunctor C ⋙ rightHomologyFunctor Cᵒᵖ
-- Mathlib/GroupTheory/Transfer.lean
/-- Explicit computation of the transfer homomorphism. -/
theorem transfer_eq_prod_quotient_orbitRel_zpowers_quot [FiniteIndex H] (g : G)
    [Fintype (Quotient (orbitRel (zpowers g) (G ⧸ H)))] :
    transfer ϕ g =
      ∏ q : Quotient (orbitRel (zpowers g) (G ⧸ H)),
        ϕ
          ⟨q.out'.out'⁻¹ * g ^ Function.minimalPeriod (g • ·) q.out' * q.out'.out',
            QuotientGroup.out'_conj_pow_minimalPeriod_mem H g q.out'⟩
-- Mathlib/Topology/Connected/Clopen.lean
theorem surjective_coe : Surjective (mk : α → ConnectedComponents α)
-- Mathlib/Order/Antichain.lean
protected theorem insert (hs : IsStrongAntichain r s)
    (h : ∀ ⦃b⦄, b ∈ s → a ≠ b → ∀ c, ¬r a c ∨ ¬r b c) : IsStrongAntichain r (insert a s)
-- Mathlib/Data/Fin/VecNotation.lean
@[simp]
theorem cons_vecAlt0 (h : m + 1 + 1 = n + 1 + (n + 1)) (x y : α) (u : Fin m → α) :
    vecAlt0 h (vecCons x (vecCons y u)) = vecCons x (vecAlt0 (by omega) u)
-- .lake/packages/lean4/src/lean/Init/Data/Array/BasicAux.lean
@[simp] theorem List.toArray_eq_toArray_eq (as bs : List α) : (as.toArray = bs.toArray) = (as = bs)
-- Mathlib/Analysis/Convex/Function.lean
theorem OrderIso.convexOn_symm (f : α ≃o β) (hf : ConcaveOn 𝕜 univ f) :
    ConvexOn 𝕜 univ f.symm
-- Mathlib/Order/WellFoundedSet.lean
/-- `a` is accessible under the relation `r` iff `r` is well-founded on the downward transitive
closure of `a` under `r` (including `a` or not). -/
theorem acc_iff_wellFoundedOn {α} {r : α → α → Prop} {a : α} :
    TFAE [Acc r a,
      WellFoundedOn { b | ReflTransGen r b a } r,
      WellFoundedOn { b | TransGen r b a } r]
-- Mathlib/Data/List/Basic.lean
theorem attach_map_coe' (l : List α) (f : α → β) :
    (l.attach.map fun (i : {i // i ∈ l}) => f i) = l.map f
-- Mathlib/Computability/AkraBazzi/AkraBazzi.lean
lemma bi_min_div_two_pos : 0 < b (min_bi b) / 2
-- Mathlib/CategoryTheory/GradedObject/Trifunctor.lean
/-- Given a trifunctor `F : C₁ ⥤ C₂ ⥤ C₃ ⥤ C₄`, a map `p : I₁ × I₂ × I₃ → J`, and
graded objects `X₁ : GradedObject I₁ C₁`, `X₂ : GradedObject I₂ C₂` and `X₃ : GradedObject I₃ C₃`,
this is the `J`-graded object sending `j` to the coproduct of
`((F.obj (X₁ i₁)).obj (X₂ i₂)).obj (X₃ i₃)` for `p ⟨i₁, i₂, i₃⟩ = j`. -/
@[simps]
noncomputable def mapTrifunctorMapFunctorObj (X₁ : GradedObject I₁ C₁)
    [∀ X₂ X₃, HasMap ((((mapTrifunctor F I₁ I₂ I₃).obj X₁).obj X₂).obj X₃) p] :
    GradedObject I₂ C₂ ⥤ GradedObject I₃ C₃ ⥤ GradedObject J C₄
-- Mathlib/Algebra/Associated/Basic.lean
theorem Prime.pow_dvd_of_dvd_mul_right [CancelCommMonoidWithZero α] {p a b : α} (hp : Prime p)
    (n : ℕ) (h : ¬p ∣ b) (h' : p ^ n ∣ a * b) : p ^ n ∣ a
-- Mathlib/Topology/UniformSpace/Cauchy.lean
theorem cauchy_pure {a : α} : Cauchy (pure a)
-- Mathlib/Data/Matroid/Constructions.lean
theorem uniqueBaseOn_indep_iff (hIE : I ⊆ E) : (uniqueBaseOn I E).Indep J ↔ J ⊆ I
-- Mathlib/Algebra/Module/LocalizedModule.lean
/-- The linear map `(LocalizedModule S M) → (LocalizedModule S M)` from `iso` is the identity. -/
lemma iso_localizedModule_eq_refl : iso S (mkLinearMap S M) = refl R (LocalizedModule S M)
-- Mathlib/Data/Set/Pointwise/Basic.lean
@[to_additive]
theorem preimage_mul_left_one' : (a⁻¹ * ·) ⁻¹' 1 = {a}
-- Mathlib/Probability/Martingale/Upcrossing.lean
theorem upperCrossingTime_lt_lowerCrossingTime (hab : a < b)
    (hn : lowerCrossingTime a b f N (n + 1) ω ≠ N) :
    upperCrossingTime a b f N (n + 1) ω < lowerCrossingTime a b f N (n + 1) ω
-- Mathlib/Data/Set/Image.lean
@[simp]
theorem _root_.Prod.range_fst [Nonempty β] : range (Prod.fst : α × β → α) = univ
-- Mathlib/Topology/Separation.lean
theorem disjoint_pure_nhds [T1Space X] {x y : X} (h : x ≠ y) : Disjoint (pure x) (𝓝 y)
-- Mathlib/Algebra/Order/GroupWithZero/Unbundled.lean
theorem mul_le_of_le_one_left [MulPosMono α] (hb : 0 ≤ b) (h : a ≤ 1) : a * b ≤ b
-- Mathlib/Data/Complex/Module.lean
@[simp]
theorem realPart_I_smul (a : A) : ℜ (I • a) = -ℑ a
-- Mathlib/RingTheory/Smooth/Basic.lean
/-- An `R` algebra `A` is smooth if it is formally smooth and of finite presentation.

In the stacks project, the definition of smooth is completely different, and tag
<https://stacks.math.columbia.edu/tag/00TN> proves that their definition is equivalent
to this.
-/
class Smooth [CommSemiring R] (A : Type u) [Semiring A] [Algebra R A] : Prop where
  formallySmooth : FormallySmooth R A := by infer_instance
  finitePresentation : FinitePresentation R A := by infer_instance
-- Mathlib/FieldTheory/RatFunc/Basic.lean
@[simp]
theorem toFractionRing_eq :
    (toFractionRing : RatFunc K → FractionRing K[X]) = IsLocalization.algEquiv K[X]⁰ _ _
-- Mathlib/Algebra/Homology/ImageToKernel.lean
theorem factorThruImageSubobject_comp_imageToKernel (w : f ≫ g = 0) :
    factorThruImageSubobject f ≫ imageToKernel f g w = factorThruKernelSubobject g f w
-- Mathlib/Data/Set/Finite.lean
theorem Finite.biUnion {ι} {s : Set ι} (hs : s.Finite) {t : ι → Set α}
    (ht : ∀ i ∈ s, (t i).Finite) : (⋃ i ∈ s, t i).Finite
-- Mathlib/Analysis/Complex/OperatorNorm.lean
@[simp]
theorem imCLM_nnnorm : ‖imCLM‖₊ = 1
-- Mathlib/Analysis/Calculus/MeanValue.lean
/-- General fencing theorem for continuous functions with an estimate on the derivative.
Let `f` and `B` be continuous functions on `[a, b]` such that

* `f a ≤ B a`;
* `B` has derivative `B'` everywhere on `ℝ`;
* `f` has right derivative `f'` at every point of `[a, b)`;
* we have `f' x ≤ B' x` on `[a, b)`.

Then `f x ≤ B x` everywhere on `[a, b]`. -/
theorem image_le_of_deriv_right_le_deriv_boundary {f f' : ℝ → ℝ} {a b : ℝ}
    (hf : ContinuousOn f (Icc a b)) (hf' : ∀ x ∈ Ico a b, HasDerivWithinAt f (f' x) (Ici x) x)
    {B B' : ℝ → ℝ} (ha : f a ≤ B a) (hB : ContinuousOn B (Icc a b))
    (hB' : ∀ x ∈ Ico a b, HasDerivWithinAt B (B' x) (Ici x) x)
    (bound : ∀ x ∈ Ico a b, f' x ≤ B' x) : ∀ ⦃x⦄, x ∈ Icc a b → f x ≤ B x
-- Mathlib/AlgebraicTopology/DoldKan/Decomposition.lean
@[simp]
theorem id_φ : (id X n).φ = 𝟙 _
-- Mathlib/CategoryTheory/Limits/Shapes/Pullback/Mono.lean
/-- Monomorphisms are stable under pullback in the first argument. -/
theorem mono_snd_of_is_pullback_of_mono {t : PullbackCone f g} (ht : IsLimit t) [Mono f] :
    Mono t.snd