ruc-ai4math/mathlib_handler_benchmark_410 huggingface dataset:
-- Mathlib/CategoryTheory/Localization/Resolution.lean
/-- The type of morphisms in the category `Φ.RightResolution X₂` (when `W₁` is multiplicative). -/
@[ext]
structure Hom (R R' : Φ.RightResolution X₂) where
  /-- a morphism in the source category -/
  f : R.X₁ ⟶ R'.X₁
  hf : W₁ f
  comm : R.w ≫ Φ.functor.map f = R'.w := by aesop_cat
-- Mathlib/Order/Interval/Set/UnorderedInterval.lean
lemma _root_.Monotone.mapsTo_uIcc (hf : Monotone f) : MapsTo f (uIcc a b) (uIcc (f a) (f b))
-- Mathlib/Computability/TMToPartrec.lean
/-- The `stepNormal` function respects the `then k'` homomorphism. Note that this is an exact
equality, not a simulation; the original and embedded machines move in lock-step until the
embedded machine reaches the halt state. -/
theorem stepNormal_then (c) (k k' : Cont) (v) :
    stepNormal c (k.then k') v = (stepNormal c k v).then k'
-- Mathlib/RingTheory/SurjectiveOnStalks.lean
lemma surjectiveOnStalks_of_exists_div (h : ∀ x : S, ∃ r s : R, IsUnit (f s) ∧ f s * x = f r) :
    SurjectiveOnStalks f
-- Mathlib/Algebra/Polynomial/Eval.lean
@[simp]
protected theorem map_neg {S} [Ring S] (f : R →+* S) : (-p).map f = -p.map f
-- Mathlib/Algebra/Module/LocalizedModule.lean
theorem mk'_smul_mk (r : R) (m : M) (s s' : S) :
    IsLocalization.mk' T r s • mk m s' = mk (r • m) (s * s')
-- Mathlib/Algebra/Order/ToIntervalMod.lean
@[simp]
theorem toIcoMod_toIcoMod (a₁ a₂ b : α) : toIcoMod hp a₁ (toIcoMod hp a₂ b) = toIcoMod hp a₁ b
-- Mathlib/Topology/Homotopy/Basic.lean
protected theorem congr_fun {F G : Homotopy f₀ f₁} (h : F = G) (x : I × X) : F x = G x
-- Mathlib/Data/Nat/Factorization/Root.lean
@[simp] lemma floorRoot_zero_left (a : ℕ) : floorRoot 0 a = 0
-- Mathlib/CategoryTheory/Adjunction/Basic.lean
@[reassoc (attr := simp)]
theorem right_triangle_components :
    adj.unit.app (G.obj Y) ≫ G.map (adj.counit.app Y) = 𝟙 (G.obj Y)
-- .lake/packages/batteries/Batteries/Data/String/Lemmas.lean
theorem dropWhile (p : Char → Bool) : ∀ {s}, Valid s → Valid (s.dropWhile p)
-- Mathlib/Analysis/NormedSpace/OperatorNorm/Bilinear.lean
theorem opNorm_ext [RingHomIsometric σ₁₃] (f : E →SL[σ₁₂] F) (g : E →SL[σ₁₃] G)
    (h : ∀ x, ‖f x‖ = ‖g x‖) : ‖f‖ = ‖g‖
-- Mathlib/AlgebraicGeometry/Morphisms/Affine.lean
/-- A morphism of schemes `X ⟶ Y` is affine if
the preimage of any affine open subset of `Y` is affine. -/
@[mk_iff]
class IsAffineHom {X Y : Scheme} (f : X ⟶ Y) : Prop where
  isAffine_preimage : ∀ U : Y.Opens, IsAffineOpen U → IsAffineOpen (f ⁻¹ᵁ U)
-- Mathlib/Algebra/Group/Units.lean
@[to_additive]
protected theorem ext_iff {a b : αˣ} : a = b ↔ (a : α) = b
-- Mathlib/LinearAlgebra/Multilinear/Basic.lean
@[simp]
theorem map_update_zero [DecidableEq ι] (m : ∀ i, M₁ i) (i : ι) : f (update m i 0) = 0
-- Mathlib/Topology/MetricSpace/IsometricSMul.lean
/-- If `G` acts isometrically on `X`, then the image of a bounded set in `X` under scalar
multiplication by `c : G` is bounded. See also `Bornology.IsBounded.smul₀` for a similar lemma about
normed spaces. -/
@[to_additive "Given an additive isometric action of `G` on `X`, the image of a bounded set in `X`
under translation by `c : G` is bounded"]
theorem Bornology.IsBounded.smul [PseudoMetricSpace X] [SMul G X] [IsometricSMul G X] {s : Set X}
    (hs : IsBounded s) (c : G) : IsBounded (c • s)
-- Mathlib/RingTheory/WittVector/StructurePolynomial.lean
theorem wittStructureRat_vars [Fintype idx] (Φ : MvPolynomial idx ℚ) (n : ℕ) :
    (wittStructureRat p Φ n).vars ⊆ Finset.univ ×ˢ Finset.range (n + 1)
-- Mathlib/Algebra/Module/Submodule/Basic.lean
@[simp]
theorem toAddSubmonoid_eq : p.toAddSubmonoid = q.toAddSubmonoid ↔ p = q
-- Mathlib/Computability/Primrec.lean
theorem nat_div : Primrec₂ ((· / ·) : ℕ → ℕ → ℕ)
-- Mathlib/Order/Filter/AtTopBot.lean
theorem disjoint_atTop_principal_Iio [Preorder α] (x : α) : Disjoint atTop (𝓟 (Iio x))
-- Mathlib/Probability/Independence/Conditional.lean
theorem condIndepSets_of_condIndepSets_of_le_left {s₁ s₂ s₃ : Set (Set Ω)}
    (h_indep : CondIndepSets m' hm' s₁ s₂ μ) (h31 : s₃ ⊆ s₁) :
    CondIndepSets m' hm' s₃ s₂ μ
-- Mathlib/Algebra/Group/Units.lean
@[to_additive (attr := simp)]
theorem mul_left_inj (a : αˣ) {b c : α} : b * a = c * a ↔ b = c
-- Mathlib/MeasureTheory/Constructions/Pi.lean
nonrec theorem pi_univ : Measure.pi μ univ = ∏ i, μ i univ
-- Mathlib/RingTheory/Localization/AtPrime.lean
theorem isUnit_mk'_iff (x : R) (y : I.primeCompl) : IsUnit (mk' S x y) ↔ x ∈ I.primeCompl
-- Mathlib/Topology/Separation.lean
theorem isClosed_singleton [T1Space X] {x : X} : IsClosed ({x} : Set X)
-- Mathlib/Analysis/Calculus/ContDiff/Defs.lean
@[simp]
theorem norm_iteratedFDerivWithin_zero : ‖iteratedFDerivWithin 𝕜 0 f s x‖ = ‖f x‖
-- Mathlib/AlgebraicGeometry/Restrict.lean
@[simp, reassoc]
lemma Scheme.restrictRestrict_inv_restrict_restrict (X : Scheme.{u}) (U : X.Opens)
    (V : U.toScheme.Opens) :
    (X.restrictRestrict U V).inv ≫ V.ι ≫ U.ι = Opens.ι _
-- Mathlib/Analysis/SpecificLimits/Basic.lean
theorem factorial_tendsto_atTop : Tendsto Nat.factorial atTop atTop
-- .lake/packages/lean4/src/lean/Init/Core.lean
theorem decide_false_eq_false (h : Decidable False) : @decide False h = false
-- Mathlib/Algebra/MvPolynomial/Comap.lean
theorem comap_id : comap (AlgHom.id R (MvPolynomial σ R)) = id
-- Mathlib/AlgebraicTopology/FundamentalGroupoid/SimplyConnected.lean
/-- Another version of `simply_connected_iff_paths_homotopic` -/
theorem simply_connected_iff_paths_homotopic' {Y : Type*} [TopologicalSpace Y] :
    SimplyConnectedSpace Y ↔
      PathConnectedSpace Y ∧ ∀ {x y : Y} (p₁ p₂ : Path x y), Path.Homotopic p₁ p₂
-- Mathlib/Order/SuccPred/Basic.lean
lemma SuccOrder.forall_ne_bot_iff
    [Nontrivial α] [PartialOrder α] [OrderBot α] [SuccOrder α] [IsSuccArchimedean α]
    (P : α → Prop) :
    (∀ i, i ≠ ⊥ → P i) ↔ (∀ i, P (SuccOrder.succ i))
-- Mathlib/Algebra/Order/Monoid/ToMulBot.lean
@[simp]
theorem toMulBot_lt : toMulBot a < toMulBot b ↔ a < b
-- Mathlib/Data/Nat/WithBot.lean
theorem one_le_iff_zero_lt {x : WithBot ℕ} : 1 ≤ x ↔ 0 < x
-- Mathlib/CategoryTheory/CatCommSq.lean
lemma hInv_hInv (h : CatCommSq T.functor L R B.functor) :
    hInv T.symm R L B.symm (hInv T L R B h) = h
-- Mathlib/Data/Finset/Lattice.lean
@[simp]
theorem toDual_sup' [SemilatticeSup α] {s : Finset ι} (hs : s.Nonempty) (f : ι → α) :
    toDual (s.sup' hs f) = s.inf' hs (toDual ∘ f)
-- Mathlib/Analysis/Asymptotics/Theta.lean
theorem isTheta_const_mul_left {c : 𝕜} {f : α → 𝕜} (hc : c ≠ 0) :
    (fun x ↦ c * f x) =Θ[l] g ↔ f =Θ[l] g
-- Mathlib/Topology/Bornology/BoundedOperation.lean
/-- A typeclass saying that `(p : R × R) ↦ p.1 - p.2` maps any product of bounded sets to a bounded
set. This property automatically holds for seminormed additive groups, but it also holds, e.g.,
for `ℝ≥0`. -/
class BoundedSub (R : Type*) [Bornology R] [Sub R] : Prop where
  isBounded_sub : ∀ {s t : Set R},
    Bornology.IsBounded s → Bornology.IsBounded t → Bornology.IsBounded (s - t)
-- Mathlib/Analysis/SpecialFunctions/Trigonometric/Series.lean
/-- The power series expansion of `Real.sin`. -/
theorem Real.hasSum_sin (r : ℝ) :
    HasSum (fun n : ℕ => (-1) ^ n * r ^ (2 * n + 1) / ↑(2 * n + 1)!) (Real.sin r)
-- Mathlib/Algebra/ModEq.lean
theorem not_modEq_iff_ne_mod_zmultiples :
    ¬a ≡ b [PMOD p] ↔ (b : α ⧸ AddSubgroup.zmultiples p) ≠ a
-- Mathlib/AlgebraicGeometry/EllipticCurve/Jacobian.lean
@[simp] lemma map_dblZ : dblZ (W'.map f) (f ∘ P) = f (W'.dblZ P)
-- Mathlib/Data/Num/Lemmas.lean
theorem natSize_to_nat (n) : natSize n = Nat.size n
-- Mathlib/Topology/Order/Hom/Basic.lean
@[simp]
theorem cancel_right {g₁ g₂ : β →Co γ} {f : α →Co β} (hf : Surjective f) :
    g₁.comp f = g₂.comp f ↔ g₁ = g₂
-- Mathlib/Algebra/DirectSum/Ring.lean
theorem toSemiring_of (f : ∀ i, A i →+ R) (hone hmul) (i : ι) (x : A i) :
    toSemiring f hone hmul (of _ i x) = f _ x
-- Mathlib/Data/Set/Basic.lean
theorem not_mem_singleton_iff {a b : α} : a ∉ ({b} : Set α) ↔ a ≠ b
-- Mathlib/RingTheory/Ideal/AssociatedPrime.lean
theorem LinearEquiv.isAssociatedPrime_iff (l : M ≃ₗ[R] M') :
    IsAssociatedPrime I M ↔ IsAssociatedPrime I M'
-- Mathlib/CategoryTheory/Endofunctor/Algebra.lean
/-- To construct an isomorphism of algebras, it suffices to give an isomorphism of the As which
commutes with the structure morphisms.
-/
@[simps!]
def isoMk (h : A₀.1 ≅ A₁.1) (w : F.map h.hom ≫ A₁.str = A₀.str ≫ h.hom := by aesop_cat) :
    A₀ ≅ A₁
-- Mathlib/NumberTheory/ADEInequality.lean
theorem admissible_of_one_lt_sumInv {p q r : ℕ+} (H : 1 < sumInv {p, q, r}) :
    Admissible {p, q, r}
-- Mathlib/Combinatorics/SimpleGraph/Walk.lean
theorem transfer_eq_map_of_le (hp) (GH : G ≤ H) :
    p.transfer H hp = p.map (SimpleGraph.Hom.mapSpanningSubgraphs GH)
-- Mathlib/Tactic/Ring/Basic.lean
theorem coeff_one (k : ℕ) : k.rawCast = (nat_lit 1).rawCast * k
-- Mathlib/LinearAlgebra/Span.lean
@[simp]
theorem mem_prod {p : Submodule R M} {q : Submodule R M'} {x : M × M'} :
    x ∈ prod p q ↔ x.1 ∈ p ∧ x.2 ∈ q
-- Mathlib/Data/Finset/Grade.lean
lemma covBy_iff_card_sdiff_eq_one : t ⋖ s ↔ t ⊆ s ∧ (s \ t).card = 1
-- Mathlib/RingTheory/Polynomial/ScaleRoots.lean
@[simp]
theorem zero_scaleRoots (s : R) : scaleRoots 0 s = 0
-- Mathlib/MeasureTheory/Function/ConditionalExpectation/CondexpL2.lean
theorem inner_condexpL2_eq_inner_fun (hm : m ≤ m0) (f g : α →₂[μ] E)
    (hg : AEStronglyMeasurable' m g μ) :
    ⟪(condexpL2 E 𝕜 hm f : α →₂[μ] E), g⟫₂ = ⟪f, g⟫₂
-- Mathlib/MeasureTheory/Function/LpSpace.lean
theorem toLp_val {f : α → E} (h : Memℒp f p μ) : (toLp f h).1 = AEEqFun.mk f h.1
-- Mathlib/RingTheory/Polynomial/Chebyshev.lean
theorem T_eq_U_sub_X_mul_U (n : ℤ) : T R n = U R n - X * U R (n - 1)
-- Mathlib/Data/PFunctor/Univariate/M.lean
@[simp]
theorem mk_dest (x : M F) : M.mk (dest x) = x
-- Mathlib/Data/ENNReal/Inv.lean
/-- Order isomorphism between an initial interval in `ℝ≥0∞` and an initial interval in `ℝ≥0`. -/
@[simps! apply_coe]
def orderIsoIicCoe (a : ℝ≥0) : Iic (a : ℝ≥0∞) ≃o Iic a
-- Mathlib/Data/Num/Lemmas.lean
@[simp]
theorem gcd_to_nat (a b) : (gcd a b : ℕ) = Int.gcd a b
-- Mathlib/LinearAlgebra/Dimension/Finite.lean
/-- See `rank_subsingleton` for the reason that `Nontrivial R` is needed. -/
@[simp]
theorem Submodule.rank_eq_zero [Nontrivial R] [NoZeroSMulDivisors R M] {S : Submodule R M} :
    Module.rank R S = 0 ↔ S = ⊥
-- Mathlib/Algebra/Algebra/NonUnitalSubalgebra.lean
@[simp]
theorem to_subring_eq_top {R A : Type*} [CommRing R] [Ring A] [Algebra R A]
    {S : NonUnitalSubalgebra R A} : S.toNonUnitalSubring = ⊤ ↔ S = ⊤
-- Mathlib/Data/PNat/Defs.lean
@[norm_cast]
theorem one_coe : ((1 : ℕ+) : ℕ) = 1
-- Mathlib/Data/List/TFAE.lean
/-- If `P₁ x ↔ ... ↔ Pₙ x` for all `x`, then `(∃ x, P₁ x) ↔ ... ↔ (∃ x, Pₙ x)`.
Note: in concrete cases, Lean has trouble finding the list `[P₁, ..., Pₙ]` from the list
`[(∃ x, P₁ x), ..., (∃ x, Pₙ x)]`, but simply providing a list of underscores with the right
length makes it happier.

Example:
```lean
example (P₁ P₂ P₃ : ℕ → Prop) (H : ∀ n, [P₁ n, P₂ n, P₃ n].TFAE) :
    [∃ n, P₁ n, ∃ n, P₂ n, ∃ n, P₃ n].TFAE :=
  exists_tfae [_, _, _] H
```
-/
theorem exists_tfae {α : Type*} (l : List (α → Prop)) (H : ∀ a : α, (l.map (fun p ↦ p a)).TFAE) :
    (l.map (fun p ↦ ∃ a, p a)).TFAE
-- Mathlib/GroupTheory/SemidirectProduct.lean
@[simp]
theorem left_inl (n : N) : (inl n : N ⋊[φ] G).left = n
-- Mathlib/Algebra/Ring/Defs.lean
@[to_additive]
theorem mul_ite {α} [Mul α] (P : Prop) [Decidable P] (a b c : α) :
    (a * if P then b else c) = if P then a * b else a * c
-- Mathlib/Data/List/Perm.lean
theorem perm_replicate_append_replicate {l : List α} {a b : α} {m n : ℕ} (h : a ≠ b) :
    l ~ replicate m a ++ replicate n b ↔ count a l = m ∧ count b l = n ∧ l ⊆ [a, b]
-- Mathlib/GroupTheory/Perm/Basic.lean
@[simp] lemma inv_addLeft : (Equiv.addLeft a)⁻¹ = Equiv.addLeft (-a)
-- Mathlib/Order/Sublattice.lean
@[simp, norm_cast] lemma coe_sInf (S : Set (Sublattice α)) : sInf S = ⋂ L ∈ S, (L : Set α)
-- Mathlib/Data/List/Sym.lean
theorem sym2_map (f : α → β) (xs : List α) :
    (xs.map f).sym2 = xs.sym2.map (Sym2.map f)
-- Mathlib/Order/Ideal.lean
@[simp]
theorem principal_le_iff : principal x ≤ I ↔ x ∈ I
-- Mathlib/Order/Height.lean
theorem chainHeight_image (f : α → β) (hf : ∀ {x y}, x < y ↔ f x < f y) (s : Set α) :
    (f '' s).chainHeight = s.chainHeight
-- .lake/packages/batteries/Batteries/Data/String/Lemmas.lean
private theorem ne_self_add_add_csize : i ≠ i + (n + Char.utf8Size c)
-- Mathlib/CategoryTheory/Groupoid/Subgroupoid.lean
theorem id_mem_of_nonempty_isotropy (c : C) : c ∈ objs S → 𝟙 c ∈ S.arrows c c
-- Mathlib/Algebra/Module/Submodule/Ker.lean
@[simp]
theorem ker_zero : ker (0 : M →ₛₗ[τ₁₂] M₂) = ⊤
-- Mathlib/Data/Matrix/Notation.lean
theorem smul_mat_empty {m' : Type*} (x : α) (A : Fin 0 → m' → α) : x • A = ![]
-- .lake/packages/batteries/Batteries/Data/BinomialHeap/Basic.lean
theorem Heap.WF.tail? (hwf : (s : Heap α).WF le n) : s.tail? le = some tl → tl.WF le 0
-- Mathlib/Algebra/Module/LocalizedModule.lean
theorem mk_neg {M : Type*} [AddCommGroup M] [Module R M] {m : M} {s : S} : mk (-m) s = -mk m s
-- Mathlib/Analysis/BoxIntegral/Integrability.lean
/-- A simple function is McShane integrable w.r.t. any locally finite measure. -/
theorem hasBoxIntegral (f : SimpleFunc (ι → ℝ) E) (μ : Measure (ι → ℝ)) [IsLocallyFiniteMeasure μ]
    (I : Box ι) (l : IntegrationParams) (hl : l.bRiemann = false) :
    HasIntegral.{u, v, v} I l f μ.toBoxAdditive.toSMul (f.integral (μ.restrict I))
-- .lake/packages/lean4/src/lean/Init/Core.lean
theorem Eq.propIntro {a b : Prop} (h₁ : a → b) (h₂ : b → a) : a = b
-- Mathlib/Order/Interval/Set/Basic.lean
@[simp]
theorem Ioo_eq_empty_of_le (h : b ≤ a) : Ioo a b = ∅
-- Mathlib/Analysis/MellinTransform.lean
/-- If `f` is `O(x ^ (-a))` as `x → +∞`, then `log • f` is `O(x ^ (-b))` for every `b < a`. -/
theorem isBigO_rpow_top_log_smul [NormedSpace ℝ E] {a b : ℝ} {f : ℝ → E} (hab : b < a)
    (hf : f =O[atTop] (· ^ (-a))) :
    (fun t : ℝ => log t • f t) =O[atTop] (· ^ (-b))
-- Mathlib/CategoryTheory/MorphismProperty/Basic.lean
lemma monotone_map (F : C ⥤ D) :
    Monotone (map · F)
-- Mathlib/Data/List/Sublists.lean
theorem revzip_sublists' (l : List α) : ∀ l₁ l₂, (l₁, l₂) ∈ revzip l.sublists' → l₁ ++ l₂ ~ l
-- Mathlib/CategoryTheory/Sites/Closed.lean
theorem close_eq_self_of_isClosed {X : C} {S : Sieve X} (hS : J₁.IsClosed S) : J₁.close S = S
-- Mathlib/MeasureTheory/Integral/Lebesgue.lean
/-- If a monotone sequence of functions has an upper bound and the sequence of integrals of these
functions tends to the integral of the upper bound, then the sequence of functions converges
almost everywhere to the upper bound. -/
lemma tendsto_of_lintegral_tendsto_of_monotone {α : Type*} {mα : MeasurableSpace α}
    {f : ℕ → α → ℝ≥0∞} {F : α → ℝ≥0∞} {μ : Measure α}
    (hF_meas : AEMeasurable F μ)
    (hf_tendsto : Tendsto (fun i ↦ ∫⁻ a, f i a ∂μ) atTop (𝓝 (∫⁻ a, F a ∂μ)))
    (hf_mono : ∀ᵐ a ∂μ, Monotone (fun i ↦ f i a))
    (h_bound : ∀ᵐ a ∂μ, ∀ i, f i a ≤ F a) (h_int_finite : ∫⁻ a, F a ∂μ ≠ ∞) :
    ∀ᵐ a ∂μ, Tendsto (fun i ↦ f i a) atTop (𝓝 (F a))
-- Mathlib/CategoryTheory/Limits/Shapes/Pullback/Cospan.lean
@[simp]
theorem spanExt_app_right : (spanExt iX iY iZ wf wg).app WalkingSpan.right = iZ
-- Mathlib/Data/Finset/Sym.lean
@[simp]
theorem sym_mono (h : s ⊆ t) (n : ℕ) : s.sym n ⊆ t.sym n
-- Mathlib/LinearAlgebra/Alternating/Basic.lean
@[simp]
theorem map_sub [DecidableEq ι] (i : ι) (x y : M') :
    g' (update v' i (x - y)) = g' (update v' i x) - g' (update v' i y)
-- Mathlib/Data/Bool/Basic.lean
theorem decide_iff (p : Prop) [d : Decidable p] : decide p = true ↔ p
-- Mathlib/GroupTheory/DoubleCoset.lean
theorem mk_eq_of_doset_eq {H K : Subgroup G} {a b : G} (h : doset a H K = doset b H K) :
    mk H K a = mk H K b
-- Mathlib/Order/UpperLower/Basic.lean
@[simp] lemma IsLowerSet.disjoint_upperClosure_left (ht : IsLowerSet t) :
    Disjoint ↑(upperClosure s) t ↔ Disjoint s t
-- Mathlib/Logic/Equiv/Nat.lean
@[simp]
theorem natSumNatEquivNat_apply : ⇑natSumNatEquivNat = Sum.elim (2 * ·) (2 * · + 1)
-- Mathlib/Topology/Compactness/Compact.lean
lemma eq_finite_iUnion_of_isTopologicalBasis_of_isCompact_open (b : ι → Set X)
    (hb : IsTopologicalBasis (Set.range b)) (U : Set X) (hUc : IsCompact U) (hUo : IsOpen U) :
    ∃ s : Set ι, s.Finite ∧ U = ⋃ i ∈ s, b i
-- Mathlib/CategoryTheory/PathCategory.lean
@[simp]
theorem Prefunctor.mapPath_comp' (F : V ⥤q W) {X Y Z : Paths V} (f : X ⟶ Y) (g : Y ⟶ Z) :
    F.mapPath (f ≫ g) = (F.mapPath f).comp (F.mapPath g)
-- Mathlib/Algebra/CharP/Reduced.lean
@[simp]
theorem ExpChar.pow_prime_pow_mul_eq_one_iff (p k m : ℕ) [ExpChar R p] (x : R) :
    x ^ (p ^ k * m) = 1 ↔ x ^ m = 1
-- .lake/packages/lean4/src/lean/Init/SimpLemmas.lean
@[simp] theorem Bool.or_false (b : Bool) : (b || false) = b
-- Mathlib/MeasureTheory/Function/L1Space.lean
@[simp]
theorem hasFiniteIntegral_add_measure {f : α → β} :
    HasFiniteIntegral f (μ + ν) ↔ HasFiniteIntegral f μ ∧ HasFiniteIntegral f ν
-- Mathlib/MeasureTheory/MeasurableSpace/Basic.lean
@[simp]
theorem coe_empty : ↑(∅ : Subtype (MeasurableSet : Set α → Prop)) = (∅ : Set α)
-- Mathlib/Analysis/Normed/Group/Quotient.lean
/-- For any `x : M ⧸ S` and any `0 < ε`, there is `m : M` such that `Submodule.Quotient.mk m = x`
and `‖m‖ < ‖x‖ + ε`. -/
nonrec theorem Submodule.Quotient.norm_mk_lt {S : Submodule R M} (x : M ⧸ S) {ε : ℝ} (hε : 0 < ε) :
    ∃ m : M, Submodule.Quotient.mk m = x ∧ ‖m‖ < ‖x‖ + ε
-- Mathlib/Probability/Distributions/Uniform.lean
theorem toMeasurable_iff {X : Ω → E} {s : Set E} :
    IsUniform X (toMeasurable μ s) ℙ μ ↔ IsUniform X s ℙ μ
-- Mathlib/GroupTheory/Torsion.lean
/-- Direct products of torsion free groups are torsion free. -/
@[to_additive AddMonoid.IsTorsionFree.prod
      "Direct products of additive torsion free groups are torsion free."]
theorem IsTorsionFree.prod {η : Type*} {Gs : η → Type*} [∀ i, Group (Gs i)]
    (tfGs : ∀ i, IsTorsionFree (Gs i)) : IsTorsionFree <| ∀ i, Gs i
-- Mathlib/MeasureTheory/Function/LpSeminorm/Basic.lean
theorem eLpNorm'_eq_zero_iff (hq0_lt : 0 < q) {f : α → E} (hf : AEStronglyMeasurable f μ) :
    eLpNorm' f q μ = 0 ↔ f =ᵐ[μ] 0
-- Mathlib/Order/Filter/Bases.lean
@[simp]
theorem disjoint_principal_left {f : Filter α} {s : Set α} : Disjoint (𝓟 s) f ↔ sᶜ ∈ f
-- Mathlib/NumberTheory/LSeries/Convergence.lean
lemma LSeries.abscissaOfAbsConv_congr {f g : ℕ → ℂ} (h : ∀ {n}, n ≠ 0 → f n = g n) :
    abscissaOfAbsConv f = abscissaOfAbsConv g
-- Mathlib/Algebra/BigOperators/Group/List.lean
lemma length_sigma {σ : α → Type*} (l₁ : List α) (l₂ : ∀ a, List (σ a)) :
    length (l₁.sigma l₂) = (l₁.map fun a ↦ length (l₂ a)).sum
-- Mathlib/Order/Filter/Basic.lean
theorem eventuallyEq_of_mem {l : Filter α} {f g : α → β} {s : Set α} (hs : s ∈ l) (h : EqOn f g s) :
    f =ᶠ[l] g
-- Mathlib/MeasureTheory/Constructions/Polish/Basic.lean
/-- A countable union of analytic sets is analytic. -/
theorem AnalyticSet.iUnion [Countable ι] {s : ι → Set α} (hs : ∀ n, AnalyticSet (s n)) :
    AnalyticSet (⋃ n, s n)
-- Mathlib/Analysis/Analytic/Composition.lean
/-- If two formal multilinear series have positive radius of convergence, then the terms appearing
in the definition of their composition are also summable (when multiplied by a suitable positive
geometric term). -/
theorem comp_summable_nnreal (q : FormalMultilinearSeries 𝕜 F G) (p : FormalMultilinearSeries 𝕜 E F)
    (hq : 0 < q.radius) (hp : 0 < p.radius) :
    ∃ r > (0 : ℝ≥0),
      Summable fun i : Σ n, Composition n => ‖q.compAlongComposition p i.2‖₊ * r ^ i.1
-- Mathlib/Data/Finset/Sups.lean
theorem infs_union_left : (s₁ ∪ s₂) ⊼ t = s₁ ⊼ t ∪ s₂ ⊼ t
-- Mathlib/Algebra/Lie/Weights/Basic.lean
lemma weightSpace_ne_bot (χ : Weight R L M) : weightSpace M χ ≠ ⊥
-- Mathlib/Order/UpperLower/Basic.lean
theorem isLowerSet_iUnion₂ {f : ∀ i, κ i → Set α} (hf : ∀ i j, IsLowerSet (f i j)) :
    IsLowerSet (⋃ (i) (j), f i j)
-- Mathlib/Algebra/Field/Subfield.lean
@[simp]
theorem mem_fieldRange {f : K →+* L} {y : L} : y ∈ f.fieldRange ↔ ∃ x, f x = y
-- Mathlib/Data/Real/ENatENNReal.lean
@[simp, norm_cast]
theorem toENNReal_sub (m n : ℕ∞) : ↑(m - n) = (m - n : ℝ≥0∞)
-- Mathlib/Topology/Algebra/UniformGroup.lean
@[to_additive]
theorem TopologicalGroup.tendstoLocallyUniformlyOn_iff {ι α : Type*} [TopologicalSpace α]
    (F : ι → α → G) (f : α → G) (p : Filter ι) (s : Set α) :
    @TendstoLocallyUniformlyOn α G ι (TopologicalGroup.toUniformSpace G) _ F f p s ↔
      ∀ u ∈ 𝓝 (1 : G), ∀ x ∈ s, ∃ t ∈ 𝓝[s] x, ∀ᶠ i in p, ∀ a ∈ t, F i a / f a ∈ u
-- Mathlib/LinearAlgebra/BilinearForm/Basic.lean
theorem zero_left (x : M) : B 0 x = 0
-- Mathlib/CategoryTheory/Limits/Preserves/Shapes/Biproducts.lean
theorem biproduct.mapBiproduct_hom_desc (g : ∀ j, f j ⟶ W) :
    ((F.mapBiproduct f).hom ≫ biproduct.desc fun j => F.map (g j)) = F.map (biproduct.desc g)
-- Mathlib/Algebra/BigOperators/Group/Multiset.lean
@[to_additive]
theorem prod_eq_pow_single [DecidableEq α] (a : α) (h : ∀ a' ≠ a, a' ∈ s → a' = 1) :
    s.prod = a ^ s.count a
-- Mathlib/CategoryTheory/Limits/Shapes/ConcreteCategory.lean
theorem widePushout_exists_rep {B : C} {α : Type _} {X : α → C} (f : ∀ j : α, B ⟶ X j)
    [HasWidePushout.{v} B X f] [PreservesColimit (wideSpan B X f) (forget C)]
    (x : ↑(widePushout B X f)) : (∃ y : B, head f y = x) ∨ ∃ (i : α) (y : X i), ι f i y = x
-- Mathlib/Combinatorics/SimpleGraph/Path.lean
theorem isBridge_iff_mem_and_forall_cycle_not_mem {e : Sym2 V} :
    G.IsBridge e ↔ e ∈ G.edgeSet ∧ ∀ ⦃u : V⦄ (p : G.Walk u u), p.IsCycle → e ∉ p.edges
-- Mathlib/Order/Filter/Basic.lean
protected theorem lawfulMonad : LawfulMonad Filter
-- Mathlib/Analysis/Calculus/Deriv/Basic.lean
@[simp]
theorem deriv_id' : deriv (@id 𝕜) = fun _ => 1
-- Mathlib/Algebra/Category/ModuleCat/Sheaf.lean
@[simp]
lemma add_val {M N : SheafOfModules.{v} R} (f g : M ⟶ N) :
    (f + g).val = f.val + g.val
-- Mathlib/CategoryTheory/Monoidal/Preadditive.lean
@[ext]
theorem leftDistributor_ext₂_right {J : Type} [Fintype J]
    {X Y Z : C} {f : J → C} {g h : X ⟶ Y ⊗ (Z ⊗ ⨁ f)}
    (w : ∀ j, g ≫ (Y ◁ (Z ◁ biproduct.π f j)) = h ≫ (Y ◁ (Z ◁ biproduct.π f j))) :
    g = h
-- Mathlib/Order/LiminfLimsup.lean
theorem le_limsup_of_frequently_le {α β} [ConditionallyCompleteLinearOrder β] {f : Filter α}
    {u : α → β} {b : β} (hu_le : ∃ᶠ x in f, b ≤ u x)
    (hu : f.IsBoundedUnder (· ≤ ·) u := by isBoundedDefault) :
    b ≤ limsup u f
-- Mathlib/Analysis/Calculus/FDeriv/Analytic.lean
/-- If a function has a finite power series on a ball, then so does its derivative.
This is a variant of `HasFiniteFPowerSeriesOnBall.fderiv` where the degree of `f` is `< n`
and not `< n + 1`. -/
theorem HasFiniteFPowerSeriesOnBall.fderiv' (h : HasFiniteFPowerSeriesOnBall f p x n r) :
    HasFiniteFPowerSeriesOnBall (fderiv 𝕜 f) p.derivSeries x (n - 1) r
-- Mathlib/Geometry/Manifold/ContMDiff/Basic.lean
/-- The composition of `C^n` functions within domains at points is `C^n`. -/
theorem ContMDiffWithinAt.comp' {t : Set M'} {g : M' → M''} (x : M)
    (hg : ContMDiffWithinAt I' I'' n g t (f x)) (hf : ContMDiffWithinAt I I' n f s x) :
    ContMDiffWithinAt I I'' n (g ∘ f) (s ∩ f ⁻¹' t) x
-- Mathlib/RingTheory/PolynomialAlgebra.lean
@[simp] theorem matPolyEquiv_diagonal_X :
    matPolyEquiv (diagonal fun _ : n => (X : R[X])) = X
-- Mathlib/Algebra/Homology/HomotopyCategory/HomComplexShift.lean
@[simp]
lemma leftShift_add (a n' : ℤ) (hn' : n + a = n') :
    (γ₁ + γ₂).leftShift a n' hn' = γ₁.leftShift a n' hn' + γ₂.leftShift a n' hn'
-- Mathlib/Data/List/Rotate.lean
theorem IsRotated.perm (h : l ~r l') : l ~ l'
-- Mathlib/SetTheory/Ordinal/Arithmetic.lean
@[simp]
theorem range_familyOfBFamily' {ι : Type u} (r : ι → ι → Prop) [IsWellOrder ι r] {o}
    (ho : type r = o) (f : ∀ a < o, α) : range (familyOfBFamily' r ho f) = brange o f
-- Mathlib/Order/Basic.lean
theorem le_or_le [LinearOrder α] {a b : α} (h : a ≤ b) (c : α) : a ≤ c ∨ c ≤ b
-- Mathlib/Geometry/Manifold/ContMDiff/Basic.lean
/-- `g ∘ f` is `C^n` within `s` at `x` if `g` is `C^n` at `f x` and
`f` is `C^n` within `s` at `x`. -/
theorem ContMDiffAt.comp_contMDiffWithinAt {g : M' → M''} (x : M)
    (hg : ContMDiffAt I' I'' n g (f x)) (hf : ContMDiffWithinAt I I' n f s x) :
    ContMDiffWithinAt I I'' n (g ∘ f) s x
-- Mathlib/SetTheory/Game/PGame.lean
theorem mk_lf_of_le {xl xr y j} (xL) {xR : xr → PGame} : xR j ≤ y → mk xl xr xL xR ⧏ y
-- Mathlib/CategoryTheory/Comma/Arrow.lean
@[simp]
theorem inv_left [IsIso sq] : (inv sq).left = inv sq.left