ruc-ai4math/mathlib_handler_benchmark_410 huggingface dataset:
-- Mathlib/Analysis/SumOverResidueClass.lean
/-- A sequence `f` with values in an additive topological group `R` is summable on the
residue class of `k` mod `m` if and only if `f (m*n + k)` is summable. -/
lemma summable_indicator_mod_iff_summable {R : Type*} [AddCommGroup R] [TopologicalSpace R]
    [TopologicalAddGroup R] (m : ℕ) [hm : NeZero m] (k : ℕ) (f : ℕ → R) :
    Summable ({n : ℕ | (n : ZMod m) = k}.indicator f) ↔ Summable fun n ↦ f (m * n + k)
-- Mathlib/Order/OrdContinuous.lean
theorem map_isLeast (hf : RightOrdContinuous f) {s : Set α} {x : α} (h : IsLeast s x) :
    IsLeast (f '' s) (f x)
-- Mathlib/RingTheory/Finiteness.lean
theorem of_comp_finite {f : A →ₐ[R] B} {g : B →ₐ[R] C} (h : (g.comp f).Finite) : g.Finite
-- Mathlib/RingTheory/AdjoinRoot.lean
theorem coe_injective' [Fact (Irreducible f)] : Function.Injective ((↑) : K → AdjoinRoot f)
-- Mathlib/Order/Lattice.lean
/-- Pointwise infimum of two monotone functions is a monotone function. -/
protected theorem inf [Preorder α] [SemilatticeInf β] {f g : α → β} (hf : Antitone f)
    (hg : Antitone g) :
    Antitone (f ⊓ g)
-- Mathlib/Order/Filter/CardinalInter.lean
@[simp]
theorem mem_ofCardinalInter {l : Set (Set α)} (hc : 2 < c)
    (hl : ∀ S : Set (Set α), (#S < c) → S ⊆ l → ⋂₀ S ∈ l) (h_mono : ∀ s t, s ∈ l → s ⊆ t → t ∈ l)
    {s : Set α} : s ∈ Filter.ofCardinalInter l hc hl h_mono ↔ s ∈ l
-- Mathlib/LinearAlgebra/Matrix/BilinearForm.lean
@[simp]
theorem BilinForm.toMatrix'_comp (B : BilinForm R₂ (n → R₂)) (l r : (o → R₂) →ₗ[R₂] n → R₂) :
    BilinForm.toMatrix' (B.comp l r) =
      (LinearMap.toMatrix' l)ᵀ * BilinForm.toMatrix' B * LinearMap.toMatrix' r
-- Mathlib/Data/Nat/PartENat.lean
@[simp]
theorem dom_some (x : ℕ) : (some x).Dom
-- Mathlib/Topology/Irreducible.lean
theorem isIrreducible_irreducibleComponent {x : X} : IsIrreducible (irreducibleComponent x)
-- Mathlib/Order/Concept.lean
@[simp]
theorem snd_ssubset_snd_iff : c.snd ⊂ d.snd ↔ d < c
-- Mathlib/CategoryTheory/Preadditive/Yoneda/Basic.lean
/-- Composing the preadditive yoneda embedding with the forgetful functor yields the regular
Yoneda embedding.
-/
@[simp]
theorem whiskering_preadditiveCoyoneda :
    preadditiveCoyoneda ⋙
        (whiskeringRight C AddCommGrp (Type v)).obj (forget AddCommGrp) =
      coyoneda
-- Mathlib/Analysis/Normed/Algebra/Spectrum.lean
/-- In a (nontrivial) complex Banach algebra, every element has nonempty spectrum. -/
protected theorem nonempty : (spectrum ℂ a).Nonempty
-- Mathlib/Algebra/Module/Torsion.lean
theorem supIndep_torsionBy : S.SupIndep fun i => torsionBy R M <| q i
-- Mathlib/ModelTheory/LanguageMap.lean
theorem lhomWithConstants_injective : (L.lhomWithConstants α).Injective
-- Mathlib/MeasureTheory/Function/L1Space.lean
theorem integrable_withDensity_iff_integrable_coe_smul₀ {f : α → ℝ≥0} (hf : AEMeasurable f μ)
    {g : α → E} :
    Integrable g (μ.withDensity fun x => f x) ↔ Integrable (fun x => (f x : ℝ) • g x) μ
-- Mathlib/Analysis/Analytic/Constructions.lean
/-- Analytic functions on products are analytic in the second coordinate -/
theorem AnalyticAt.curry_right {f : E × F → G} {p : E × F} (fa : AnalyticAt 𝕜 f p) :
    AnalyticAt 𝕜 (fun y ↦ f (p.1, y)) p.2
-- Mathlib/Data/Nat/Digits.lean
theorem digits_eq_cons_digits_div {b n : ℕ} (h : 1 < b) (w : n ≠ 0) :
    digits b n = (n % b) :: digits b (n / b)
-- Mathlib/Topology/Connected/Basic.lean
theorem Inducing.isPreconnected_image [TopologicalSpace β] {s : Set α} {f : α → β}
    (hf : Inducing f) : IsPreconnected (f '' s) ↔ IsPreconnected s
-- Mathlib/Algebra/Polynomial/RingDivision.lean
theorem X_sub_C_pow_dvd_iff {p : R[X]} {t : R} {n : ℕ} :
    (X - C t) ^ n ∣ p ↔ X ^ n ∣ p.comp (X + C t)
-- Mathlib/Logic/Equiv/Set.lean
theorem image_symm_preimage {α β} {f : α → β} (hf : Injective f) (u s : Set α) :
    (fun x => (Set.image f s hf).symm x : f '' s → α) ⁻¹' u = Subtype.val ⁻¹' (f '' u)
-- Mathlib/Data/Finset/NoncommProd.lean
theorem noncommFoldr_eq_foldr (s : Multiset α) (h : LeftCommutative f) (b : β) :
    noncommFoldr f s (fun x _ y _ _ => h x y) b = foldr f h b s
-- .lake/packages/lean4/src/lean/Init/SimpLemmas.lean
theorem dite_cond_eq_false {α : Sort u} {c : Prop} {_ : Decidable c} {t : c → α} {e : ¬ c → α} (h : c = False) : (dite c t e) = e (of_eq_false h)
-- Mathlib/Topology/Algebra/Module/WeakDual.lean
theorem eval_continuous (y : F) : Continuous fun x : WeakBilin B => B x y
-- Mathlib/Data/PFun.lean
@[simp]
theorem comp_assoc (f : γ →. δ) (g : β →. γ) (h : α →. β) : (f.comp g).comp h = f.comp (g.comp h)
-- Mathlib/Order/GaloisConnection.lean
theorem l_u_l_eq_l' : l ∘ u ∘ l = l
-- Mathlib/LinearAlgebra/Dimension/Finite.lean
theorem finrank_eq_zero_of_basis_imp_false (h : ∀ s : Finset M, Basis.{v} (s : Set M) R M → False) :
    finrank R M = 0
-- Mathlib/Order/SymmDiff.lean
theorem symmDiff_right_comm : a ∆ b ∆ c = a ∆ c ∆ b
-- Mathlib/Data/Matrix/Basic.lean
theorem conjTranspose_smul_self [Mul α] [StarMul α] (c : α) (M : Matrix m n α) :
    (c • M)ᴴ = MulOpposite.op (star c) • Mᴴ
-- Mathlib/RingTheory/AdjoinRoot.lean
theorem finitePresentation : Algebra.FinitePresentation R (AdjoinRoot f)
-- Mathlib/Algebra/Group/Aut.lean
@[simp]
theorem conj_apply [Group G] (g h : G) : conj g h = g * h * g⁻¹
-- Mathlib/SetTheory/Game/Nim.lean
theorem moveLeft_nim {o : Ordinal} (i) : (nim o).moveLeft (toLeftMovesNim i) = nim i
-- Mathlib/Combinatorics/SimpleGraph/Ends/Defs.lean
@[simp]
theorem ComponentCompl.mem_supp_iff {v : V} {C : ComponentCompl G K} :
    v ∈ C ↔ ∃ vK : v ∉ K, G.componentComplMk vK = C
-- .lake/packages/lean4/src/lean/Init/Data/Fin/Lemmas.lean
@[simp] theorem is_le' {a : Fin n} : a ≤ n
-- Mathlib/Topology/UniformSpace/UniformConvergence.lean
theorem tendstoLocallyUniformlyOn_iff_filter :
    TendstoLocallyUniformlyOn F f p s ↔ ∀ x ∈ s, TendstoUniformlyOnFilter F f p (𝓝[s] x)
-- Mathlib/SetTheory/Cardinal/Cofinality.lean
theorem ord_cof (hf : IsFundamentalSequence a o f) :
    IsFundamentalSequence a a.cof.ord fun i hi => f i (hi.trans_le (by rw [hf.cof_eq]))
-- Mathlib/Algebra/Star/NonUnitalSubsemiring.lean
theorem mem_carrier {s : NonUnitalStarSubsemiring R} {x : R} : x ∈ s.carrier ↔ x ∈ s
-- Mathlib/Analysis/SpecialFunctions/Trigonometric/Basic.lean
theorem sin_ne_zero_iff {x : ℝ} : sin x ≠ 0 ↔ ∀ n : ℤ, (n : ℝ) * π ≠ x
-- Mathlib/Analysis/SpecificLimits/Basic.lean
theorem geom_le {u : ℕ → ℝ} {c : ℝ} (hc : 0 ≤ c) (n : ℕ) (h : ∀ k < n, c * u k ≤ u (k + 1)) :
    c ^ n * u 0 ≤ u n
-- Mathlib/Topology/Separation.lean
theorem Filter.limUnder_eq_iff {f : Filter Y} [NeBot f] {g : Y → X} (h : ∃ x, Tendsto g f (𝓝 x))
    {x} : @limUnder _ _ _ ⟨x⟩ f g = x ↔ Tendsto g f (𝓝 x)
-- Mathlib/Analysis/Convex/Extreme.lean
theorem mem_extremePoints : x ∈ A.extremePoints 𝕜 ↔
    x ∈ A ∧ ∀ᵉ (x₁ ∈ A) (x₂ ∈ A), x ∈ openSegment 𝕜 x₁ x₂ → x₁ = x ∧ x₂ = x
-- Mathlib/CategoryTheory/Closed/Monoidal.lean
@[simp]
theorem curry_uncurry (f : X ⟶ A ⟶[C] Y) : curry (uncurry f) = f
-- .lake/packages/batteries/Batteries/Classes/SatisfiesM.lean
@[simp] theorem SatisfiesM_StateT_eq [Monad m] [LawfulMonad m] :
    SatisfiesM (m := StateT ρ m) (α := α) p x ↔ ∀ s, SatisfiesM (m := m) (p ·.1) (x s)
-- Mathlib/Tactic/Ring/Basic.lean
theorem neg_congr {R} [Ring R] {a a' b : R} (_ : a = a')
    (_ : -a' = b) : (-a : R) = b
-- Mathlib/Analysis/SpecialFunctions/Trigonometric/Complex.lean
theorem tan_add {x y : ℂ}
    (h : ((∀ k : ℤ, x ≠ (2 * k + 1) * π / 2) ∧ ∀ l : ℤ, y ≠ (2 * l + 1) * π / 2) ∨
      (∃ k : ℤ, x = (2 * k + 1) * π / 2) ∧ ∃ l : ℤ, y = (2 * l + 1) * π / 2) :
    tan (x + y) = (tan x + tan y) / (1 - tan x * tan y)
-- Mathlib/CategoryTheory/MorphismProperty/Limits.lean
theorem StableUnderBaseChange.diagonal (hP : StableUnderBaseChange P) [P.RespectsIso] :
    P.diagonal.StableUnderBaseChange
-- Mathlib/Data/Fin/Basic.lean
lemma lt_last_iff_ne_last {a : Fin (n + 1)} : a < last n ↔ a ≠ last n
-- Mathlib/RingTheory/PiTensorProduct.lean
/--
The map `Aᵢ ⟶ ⨂ᵢ Aᵢ` given by `a ↦ 1 ⊗ ... ⊗ a ⊗ 1 ⊗ ...`
-/
@[simps]
def singleAlgHom [DecidableEq ι] (i : ι) : A i →ₐ[R] ⨂[R] i, A i
-- Mathlib/Data/Set/Function.lean
theorem EqOn.trans (h₁ : EqOn f₁ f₂ s) (h₂ : EqOn f₂ f₃ s) : EqOn f₁ f₃ s
-- Mathlib/Combinatorics/SimpleGraph/Path.lean
protected theorem «forall» {p : G.ConnectedComponent → Prop} :
    (∀ c : G.ConnectedComponent, p c) ↔ ∀ v, p (G.connectedComponentMk v)
-- Mathlib/NumberTheory/LegendreSymbol/ZModChar.lean
/-- Define the first primitive quadratic character on `ZMod 8`, `χ₈`.
It corresponds to the extension `ℚ(√2)/ℚ`. -/
@[simps]
def χ₈ : MulChar (ZMod 8) ℤ
-- Mathlib/MeasureTheory/Measure/Restrict.lean
/-- This lemma shows that `Inf` and `restrict` commute for measures. -/
theorem restrict_sInf_eq_sInf_restrict {m0 : MeasurableSpace α} {m : Set (Measure α)}
    (hm : m.Nonempty) (ht : MeasurableSet t) :
    (sInf m).restrict t = sInf ((fun μ : Measure α => μ.restrict t) '' m)
-- Mathlib/Analysis/Calculus/Taylor.lean
/-- **Taylor's theorem** with the general mean value form of the remainder.

We assume that `f` is `n+1`-times continuously differentiable in the closed set `Icc x₀ x` and
`n+1`-times differentiable on the open set `Ioo x₀ x`, and `g` is a differentiable function on
`Ioo x₀ x` and continuous on `Icc x₀ x`. Then there exists an `x' ∈ Ioo x₀ x` such that
$$f(x) - (P_n f)(x₀, x) = \frac{(x - x')^n}{n!} \frac{g(x) - g(x₀)}{g' x'},$$
where $P_n f$ denotes the Taylor polynomial of degree $n$. -/
theorem taylor_mean_remainder {f : ℝ → ℝ} {g g' : ℝ → ℝ} {x x₀ : ℝ} {n : ℕ} (hx : x₀ < x)
    (hf : ContDiffOn ℝ n f (Icc x₀ x))
    (hf' : DifferentiableOn ℝ (iteratedDerivWithin n f (Icc x₀ x)) (Ioo x₀ x))
    (gcont : ContinuousOn g (Icc x₀ x))
    (gdiff : ∀ x_1 : ℝ, x_1 ∈ Ioo x₀ x → HasDerivAt g (g' x_1) x_1)
    (g'_ne : ∀ x_1 : ℝ, x_1 ∈ Ioo x₀ x → g' x_1 ≠ 0) :
    ∃ x' ∈ Ioo x₀ x, f x - taylorWithinEval f n (Icc x₀ x) x₀ x =
    ((x - x') ^ n / n ! * (g x - g x₀) / g' x') • iteratedDerivWithin (n + 1) f (Icc x₀ x) x'
-- Mathlib/Analysis/Calculus/FDeriv/Mul.lean
theorem fderivWithin_multiset_prod [DecidableEq ι] {u : Multiset ι} {x : E}
    (hxs : UniqueDiffWithinAt 𝕜 s x) (h : ∀ i ∈ u, DifferentiableWithinAt 𝕜 (g i ·) s x) :
    fderivWithin 𝕜 (fun x ↦ (u.map (g · x)).prod) s x =
      (u.map fun i ↦ ((u.erase i).map (g · x)).prod • fderivWithin 𝕜 (g i) s x).sum
-- Mathlib/NumberTheory/DirichletCharacter/Bounds.lean
/-- The values of a Dirichlet character with target a normed field have norm bounded by `1`. -/
lemma norm_le_one (a : ZMod n) : ‖χ a‖ ≤ 1
-- Mathlib/Data/Finset/Lattice.lean
theorem map_ofDual_max (s : Finset αᵒᵈ) : s.max.map ofDual = (s.image ofDual).min
-- Mathlib/Data/Finset/Basic.lean
theorem insert_def (a : α) (s : Finset α) : insert a s = ⟨_, s.2.ndinsert a⟩
-- Mathlib/Data/ZMod/Basic.lean
theorem _root_.Nat.le_div_two_iff_mul_two_le {n m : ℕ} : m ≤ n / 2 ↔ (m : ℤ) * 2 ≤ n
-- Mathlib/Data/Set/Pointwise/Interval.lean
theorem image_add_const_Iic : (fun x => x + a) '' Iic b = Iic (b + a)
-- Mathlib/Data/Int/Log.lean
theorem log_of_right_le_one (b : ℕ) {r : R} (hr : r ≤ 1) : log b r = -Nat.clog b ⌈r⁻¹⌉₊
-- .lake/packages/lean4/src/lean/Init/Data/Array/Lemmas.lean
/-- # mkArray -/

@[simp] theorem mkArray_data (n : Nat) (v : α) : (mkArray n v).data = List.replicate n v
-- Mathlib/NumberTheory/LucasLehmer.lean
@[simp] theorem ofNat_snd (n : ℕ) [n.AtLeastTwo] :
    (no_index (OfNat.ofNat n) : X q).snd = 0
-- Mathlib/RingTheory/TensorProduct/Basic.lean
theorem natCast_def (n : ℕ) : (n : A ⊗[R] B) = (n : A) ⊗ₜ (1 : B)
-- Mathlib/CategoryTheory/FiberedCategory/BasedCategory.lean
@[ext]
lemma ext (β : BasedNatTrans F G) (h : α.toNatTrans = β.toNatTrans) : α = β
-- Mathlib/CategoryTheory/Limits/Types.lean
@[simp]
theorem Colimit.ι_desc_apply' (F : J ⥤ Type v) (s : Cocone F) (j : J) (x : F.obj j) :
    colimit.desc F s (colimit.ι F j x) = s.ι.app j x
-- Mathlib/CategoryTheory/Bicategory/NaturalTransformation/Oplax.lean
/-- A structure on an Oplax natural transformation that promotes it to a strong natural
transformation.

See `StrongNatTrans.mkOfOplax`. -/
structure StrongCore {F G : OplaxFunctor B C} (η : OplaxNatTrans F G) where
  naturality {a b : B} (f : a ⟶ b) : F.map f ≫ η.app b ≅ η.app a ≫ G.map f
  naturality_hom {a b : B} (f : a ⟶ b) : (naturality f).hom = η.naturality f := by aesop_cat
-- Mathlib/Combinatorics/SimpleGraph/Walk.lean
@[simp]
theorem cons_reverseAux {u v w x : V} (p : G.Walk u v) (q : G.Walk w x) (h : G.Adj w u) :
    (cons h p).reverseAux q = p.reverseAux (cons (G.symm h) q)
-- Mathlib/CategoryTheory/Limits/Shapes/ZeroObjects.lean
theorem Iso.isZero_iff {X Y : C} (e : X ≅ Y) : IsZero X ↔ IsZero Y
-- Mathlib/Topology/PartialHomeomorph.lean
theorem secondCountableTopology_source [SecondCountableTopology Y] :
    SecondCountableTopology e.source
-- Mathlib/Analysis/SpecialFunctions/Log/Basic.lean
theorem tendsto_log_nhdsWithin_zero : Tendsto log (𝓝[≠] 0) atBot
-- Mathlib/Data/Set/Lattice.lean
theorem mapsTo_iUnion₂_iUnion₂ {s : ∀ i, κ i → Set α} {t : ∀ i, κ i → Set β} {f : α → β}
    (H : ∀ i j, MapsTo f (s i j) (t i j)) : MapsTo f (⋃ (i) (j), s i j) (⋃ (i) (j), t i j)
-- Mathlib/GroupTheory/FreeAbelianGroup.lean
@[simp]
theorem map_of (f : α → β) (y : α) : f <$> of y = of (f y)
-- Mathlib/CategoryTheory/Comma/StructuredArrow.lean
lemma homMk'_mk_comp (f : S.obj Y ⟶ T) (g : Y' ⟶ Y) (g' : Y'' ⟶ Y') :
    homMk' (mk f) (g' ≫ g) = eqToHom (by simp) ≫ homMk' (mk (S.map g ≫ f)) g' ≫ homMk' (mk f) g
-- Mathlib/Data/Matroid/Basic.lean
@[aesop unsafe 15% (rule_sets := [Matroid])]
theorem Basis.left_subset_ground (hI : M.Basis I X) : I ⊆ M.E
-- Mathlib/Data/PNat/Interval.lean
@[simp]
theorem card_Ioo : (Ioo a b).card = b - a - 1
-- Mathlib/SetTheory/Cardinal/Basic.lean
@[norm_cast]
theorem nat_succ (n : ℕ) : (n.succ : Cardinal) = succ ↑n
-- Mathlib/Data/Stream/Init.lean
@[simp]
theorem cycle_singleton (a : α) : cycle [a] (by simp) = const a
-- Mathlib/LinearAlgebra/TensorProduct/Graded/Internal.lean
theorem auxEquiv_symm_one : (auxEquiv R 𝒜 ℬ).symm 1 = 1
-- Mathlib/Topology/Separation.lean
/-- Points of a finite set can be separated by open sets from each other. -/
theorem Set.Finite.t2_separation [T2Space X] {s : Set X} (hs : s.Finite) :
    ∃ U : X → Set X, (∀ x, x ∈ U x ∧ IsOpen (U x)) ∧ s.PairwiseDisjoint U
-- Mathlib/Data/Nat/Totient.lean
theorem sum_totient' (n : ℕ) : (∑ m ∈ (range n.succ).filter (· ∣ n), φ m) = n
-- Mathlib/Topology/Order/DenselyOrdered.lean
/-- The `atBot` filter for an open interval `Ioo a b` comes from the right-neighbourhoods filter at
the left endpoint in the ambient order. -/
theorem comap_coe_Ioo_nhdsWithin_Ioi (a b : α) : comap ((↑) : Ioo a b → α) (𝓝[>] a) = atBot
-- Mathlib/Order/GaloisConnection.lean
theorem galoisConnection_mul_div {k : ℕ} (h : 0 < k) :
    GaloisConnection (fun n => n * k) fun n => n / k
-- Mathlib/MeasureTheory/Function/LpSeminorm/Basic.lean
theorem eLpNormEssSup_const_smul (c : 𝕜) (f : α → F) :
    eLpNormEssSup (c • f) μ = (‖c‖₊ : ℝ≥0∞) * eLpNormEssSup f μ
-- Mathlib/Algebra/Lie/Submodule.lean
@[simp]
theorem range_incl : N.incl.range = N
-- Mathlib/Topology/MetricSpace/Infsep.lean
theorem Finite.einfsep_exists_of_nontrivial (hsf : s.Finite) (hs : s.Nontrivial) :
    ∃ x ∈ s, ∃ y ∈ s, x ≠ y ∧ s.einfsep = edist x y
-- Mathlib/Algebra/MvPolynomial/Basic.lean
lemma zero_not_mem_coeffs (p : MvPolynomial σ R) : 0 ∉ p.coeffs
-- Mathlib/Combinatorics/SimpleGraph/Connectivity/Subgraph.lean
lemma connected_iff_forall_exists_walk_subgraph (H : G.Subgraph) :
    H.Connected ↔
      H.verts.Nonempty ∧
        ∀ {u v}, u ∈ H.verts → v ∈ H.verts → ∃ p : G.Walk u v, p.toSubgraph ≤ H
-- Mathlib/Data/Nat/Prime/Defs.lean
theorem minFac_prime {n : ℕ} (n1 : n ≠ 1) : Prime (minFac n)
-- Mathlib/Analysis/Convex/Mul.lean
/-- `x^m`, `m : ℤ` is convex on `(0, +∞)` for all `m`. -/
lemma convexOn_zpow : ∀ n : ℤ, ConvexOn 𝕜 (Ioi 0) fun x : 𝕜 ↦ x ^ n
-- Mathlib/Control/Fold.lean
theorem foldl_toList (f : α → β → α) (xs : t β) (x : α) :
    foldl f x xs = List.foldl f x (toList xs)
-- Mathlib/RingTheory/Algebraic.lean
theorem isAlgebraic_nat [Nontrivial R] (n : ℕ) : IsAlgebraic R (n : A)
-- Mathlib/Analysis/Normed/Module/Dual.lean
/-- Given a neighborhood `s` of the origin in a normed space `E`, the dual norms
of all elements of the polar `polar 𝕜 s` are bounded by a constant. -/
theorem isBounded_polar_of_mem_nhds_zero {s : Set E} (s_nhd : s ∈ 𝓝 (0 : E)) :
    IsBounded (polar 𝕜 s)
-- Mathlib/Data/ENNReal/Inv.lean
@[simp] theorem inv_zero : (0 : ℝ≥0∞)⁻¹ = ∞
-- .lake/packages/batteries/Batteries/Data/String/Lemmas.lean
theorem _root_.String.valid_toSubstring (s : String) : Valid s
-- Mathlib/Analysis/Normed/Lp/PiLp.lean
/-- This holds independent of `p` and does not require `[Fact (1 ≤ p)]`. We keep it separate
from `pi_Lp.pseudo_emetric_space` so it can be used also for `p < 1`. -/
protected theorem edist_comm (f g : PiLp p β) : edist f g = edist g f
-- Mathlib/Analysis/Convolution.lean
theorem _root_.Continuous.convolution_integrand_fst [ContinuousSub G] (hg : Continuous g) (t : G) :
    Continuous fun x => L (f t) (g (x - t))
-- Mathlib/Probability/Kernel/Condexp.lean
theorem _root_.MeasureTheory.Integrable.integral_condexpKernel [NormedSpace ℝ F]
    (hf_int : Integrable f μ) :
    Integrable (fun ω => ∫ y, f y ∂condexpKernel μ m ω) μ
-- Mathlib/Order/Filter/Germ/Basic.lean
@[simp]
theorem liftPred_coe {p : β → Prop} {f : α → β} : LiftPred p (f : Germ l β) ↔ ∀ᶠ x in l, p (f x)
-- Mathlib/Topology/Basic.lean
@[simp]
theorem eventually_mem_nhds : (∀ᶠ x' in 𝓝 x, s ∈ 𝓝 x') ↔ s ∈ 𝓝 x
-- Mathlib/Probability/Kernel/RadonNikodym.lean
lemma singularPart_of_subset_mutuallySingularSetSlice [IsFiniteKernel κ]
    [IsFiniteKernel η] {a : α} {s : Set γ} (hsm : MeasurableSet s)
    (hs : s ⊆ mutuallySingularSetSlice κ η a) :
    singularPart κ η a s = κ a s
-- Mathlib/RingTheory/Multiplicity.lean
@[simp]
theorem get_multiplicity_self {a : α} (ha : Finite a a) : get (multiplicity a a) ha = 1
-- Mathlib/Algebra/Homology/ShortComplex/SnakeLemma.lean
/-- Exactness of `L₀.X₃ ⟶ L₃.X₁ ⟶ L₃.X₂`. -/
lemma L₂'_exact : S.L₂'.Exact
-- Mathlib/SetTheory/Cardinal/Ordinal.lean
theorem mul_le_max_of_aleph0_le_right {a b : Cardinal} (h : ℵ₀ ≤ b) : a * b ≤ max a b
-- Mathlib/NumberTheory/MulChar/Basic.lean
/-- Evaluation of the trivial character -/
lemma one_apply {x : R} (hx : IsUnit x) : (1 : MulChar R R') x = 1
-- Mathlib/LinearAlgebra/Matrix/SchurComplement.lean
theorem invOf_fromBlocks₁₁_eq (A : Matrix m m α) (B : Matrix m n α) (C : Matrix n m α)
    (D : Matrix n n α) [Invertible A] [Invertible (D - C * ⅟ A * B)]
    [Invertible (fromBlocks A B C D)] :
    ⅟ (fromBlocks A B C D) =
      fromBlocks (⅟ A + ⅟ A * B * ⅟ (D - C * ⅟ A * B) * C * ⅟ A) (-(⅟ A * B * ⅟ (D - C * ⅟ A * B)))
        (-(⅟ (D - C * ⅟ A * B) * C * ⅟ A)) (⅟ (D - C * ⅟ A * B))
-- Mathlib/Topology/Order/Hom/Basic.lean
@[simp]
theorem coe_copy (f : α →Co β) (f' : α → β) (h : f' = f) : ⇑(f.copy f' h) = f'
-- Mathlib/RingTheory/Localization/Basic.lean
@[simp]
theorem mk'_mul_mk'_eq_one (x y : M) : mk' S (x : R) y * mk' S (y : R) x = 1
-- Mathlib/MeasureTheory/Constructions/Prod/Basic.lean
theorem ae_ae_eq_of_ae_eq_uncurry {f g : α → β → γ} (h : uncurry f =ᵐ[μ.prod ν] uncurry g) :
    ∀ᵐ x ∂μ, f x =ᵐ[ν] g x
-- Mathlib/SetTheory/Cardinal/Cofinality.lean
@[simp]
theorem cof_omega : cof ω = ℵ₀
-- Mathlib/Probability/Kernel/Composition.lean
@[simp]
lemma snd_swapRight (κ : Kernel α (β × γ)) : snd (swapRight κ) = fst κ
-- Mathlib/MeasureTheory/MeasurableSpace/Defs.lean
theorem forall_generateFrom_mem_iff_mem_iff {S : Set (Set α)} {x y : α} :
    (∀ s, MeasurableSet[generateFrom S] s → (x ∈ s ↔ y ∈ s)) ↔ (∀ s ∈ S, x ∈ s ↔ y ∈ s)
-- Mathlib/NumberTheory/Modular.lean
theorem eq_zero_of_mem_fdo_of_T_zpow_mem_fdo {n : ℤ} (hz : z ∈ 𝒟ᵒ) (hg : T ^ n • z ∈ 𝒟ᵒ) :
    n = 0
-- Mathlib/Analysis/NormedSpace/Connected.lean
/-- Let `E` be a linear subspace in a real vector space.
If `E` has codimension at least two, its complement is connected. -/
theorem isConnected_compl_of_one_lt_codim {E : Submodule ℝ F} (hcodim : 1 < Module.rank ℝ (F ⧸ E)) :
    IsConnected (Eᶜ : Set F)
-- Mathlib/Combinatorics/Quiver/Cast.lean
@[simp]
theorem Path.cast_nil {u u' : U} (hu : u = u') : (Path.nil : Path u u).cast hu hu = Path.nil
-- .lake/packages/batteries/Batteries/Data/List/Lemmas.lean
theorem exists_or_eq_self_of_eraseP (p) (l : List α) :
    l.eraseP p = l ∨
    ∃ a l₁ l₂, (∀ b ∈ l₁, ¬p b) ∧ p a ∧ l = l₁ ++ a :: l₂ ∧ l.eraseP p = l₁ ++ l₂
-- Mathlib/Order/LiminfLimsup.lean
/-- Writing a limsup as an infimum of supremum, in a (possibly non-complete) conditionally complete
linear order. A reparametrization trick is needed to avoid taking the supremum of sets which are
not bounded below. -/
theorem HasBasis.limsup_eq_ite {v : Filter ι} {p : ι' → Prop} {s : ι' → Set ι}
    [Countable (Subtype p)] [Nonempty (Subtype p)] (hv : v.HasBasis p s) (f : ι → α) :
    limsup f v = if ∃ (j : Subtype p), s j = ∅ then sInf univ else
      if ∀ (j : Subtype p), ¬BddAbove (range (fun (i : s j) ↦ f i)) then sInf ∅
      else ⨅ (j : Subtype p), ⨆ (i : s (limsup_reparam f s p j)), f i
-- Mathlib/Analysis/SpecialFunctions/Pow/Deriv.lean
/-- The function `(1 + t/x) ^ x` tends to `exp t` at `+∞` for naturals `x`. -/
theorem tendsto_one_plus_div_pow_exp (t : ℝ) :
    Tendsto (fun x : ℕ => (1 + t / (x : ℝ)) ^ x) atTop (𝓝 (Real.exp t))
-- Mathlib/MeasureTheory/Function/L1Space.lean
/-- If `f` is `ℝ`-valued and integrable, then for any `c > 0` the set `{x | f x > c}` has finite
measure. -/
lemma Integrable.measure_gt_lt_top {f : α → ℝ} (hf : Integrable f μ) {ε : ℝ} (ε_pos : 0 < ε) :
    μ {a : α | ε < f a} < ∞
-- Mathlib/Analysis/Convex/Between.lean
theorem Sbtw.trans_right_left {w x y z : P} (h₁ : Sbtw R w x z) (h₂ : Sbtw R x y z) :
    Sbtw R w x y
-- Mathlib/GroupTheory/Perm/Sign.lean
@[simp]
theorem sign_symm_trans_trans [DecidableEq β] [Fintype β] (f : Perm α) (e : α ≃ β) :
    sign ((e.symm.trans f).trans e) = sign f
-- Mathlib/Algebra/Star/StarAlgHom.lean
@[simp]
theorem mk_coe (f : A →⋆ₐ[R] B) (h₁ h₂ h₃ h₄ h₅ h₆) :
    (⟨⟨⟨⟨⟨f, h₁⟩, h₂⟩, h₃, h₄⟩, h₅⟩, h₆⟩ : A →⋆ₐ[R] B) = f
-- Mathlib/Algebra/Category/ModuleCat/Adjunctions.lean
theorem associativity (X Y Z : Type u) :
    ((μ R X Y).hom ⊗ 𝟙 ((free R).obj Z)) ≫ (μ R (X ⊗ Y) Z).hom ≫ map (free R).obj (α_ X Y Z).hom =
      (α_ ((free R).obj X) ((free R).obj Y) ((free R).obj Z)).hom ≫
        (𝟙 ((free R).obj X) ⊗ (μ R Y Z).hom) ≫ (μ R X (Y ⊗ Z)).hom
-- Mathlib/Order/UpperLower/Basic.lean
@[simp] protected lemma upper (s : UpperSet α) : IsUpperSet (s : Set α)
-- Mathlib/Data/Set/Function.lean
@[simp]
theorem restrict_apply (f : α → β) (s : Set α) (x : s) : s.restrict f x = f x
-- Mathlib/CategoryTheory/Iso.lean
@[simp]
theorem eq_comp_inv (α : X ⟶ Y) [IsIso α] {f : Z ⟶ Y} {g : Z ⟶ X} : g = f ≫ inv α ↔ g ≫ α = f
-- Mathlib/Data/Fin/Basic.lean
theorem min_val {a : Fin n} : min (a : ℕ) n = a
-- Mathlib/Control/Functor.lean
@[functor_norm]
theorem map_mk {α β} (h : α → β) (x : F (G α)) : h <$> Comp.mk x = Comp.mk ((h <$> ·) <$> x)
-- .lake/packages/batteries/Batteries/Data/Nat/Gcd.lean
@[simp] theorem coprime_one_left_eq_true (n) : Coprime 1 n = True
-- Mathlib/Logic/Equiv/Option.lean
@[simp]
theorem optionSubtype_symm_apply_symm_apply [DecidableEq β] (x : β) (e : α ≃ { y : β // y ≠ x })
    (b : { y : β // y ≠ x }) : ((optionSubtype x).symm e : Option α ≃ β).symm b = e.symm b
-- Mathlib/Algebra/Homology/ComplexShapeSigns.lean
lemma prev_π₂ (i₁ : I₁) {i₂ i₂' : I₂} (h : c₂.Rel i₂ i₂') :
    c₁₂.prev (π c₁ c₂ c₁₂ ⟨i₁, i₂'⟩) = π c₁ c₂ c₁₂ ⟨i₁, i₂⟩
-- Mathlib/Analysis/SpecialFunctions/Trigonometric/Angle.lean
@[simp]
theorem cos_coe (x : ℝ) : cos (x : Angle) = Real.cos x
-- Mathlib/Algebra/Order/CauSeq/Basic.lean
@[simp, norm_cast]
theorem coe_one : ⇑(1 : CauSeq β abv) = 1
-- Mathlib/Order/Antichain.lean
theorem preimage_relEmbedding {t : Set β} (ht : IsAntichain r' t) (φ : r ↪r r') :
    IsAntichain r (φ ⁻¹' t)
-- Mathlib/Algebra/Order/CauSeq/Completion.lean
theorem inv_zero : (0 : (Cauchy abv))⁻¹ = 0
-- Mathlib/Algebra/Module/Equiv/Basic.lean
/-- Restriction from `R`-linear automorphisms of `M` to `R`-linear endomorphisms of `M`,
promoted to a monoid hom. -/
@[simps]
def automorphismGroup.toLinearMapMonoidHom : (M ≃ₗ[R] M) →* M →ₗ[R] M
-- Mathlib/RingTheory/PowerSeries/Derivative.lean
theorem trunc_derivative' (f : R⟦X⟧) (n : ℕ) :
    trunc (n-1) (d⁄dX R f) = Polynomial.derivative (trunc n f)