ruc-ai4math/mathlib_handler_benchmark_410 huggingface dataset:
-- Mathlib/Topology/Compactness/Lindelof.lean
theorem countable_cover_nhds [LindelofSpace X] {U : X → Set X} (hU : ∀ x, U x ∈ 𝓝 x) :
    ∃ t : Set X, t.Countable ∧ ⋃ x ∈ t, U x = univ
-- Mathlib/Data/ZMod/Basic.lean
theorem val_lt {n : ℕ} [NeZero n] (a : ZMod n) : a.val < n
-- Mathlib/Analysis/NormedSpace/OperatorNorm/Asymptotics.lean
theorem isBigO_sub_rev (l : Filter E) (x : E) : (fun x' => x' - x) =O[l] fun x' => e (x' - x)
-- Mathlib/CategoryTheory/MorphismProperty/Composition.lean
theorem respectsIso_of_isStableUnderComposition {P : MorphismProperty C}
    [P.IsStableUnderComposition] (hP : isomorphisms C ≤ P) :
    RespectsIso P
-- Mathlib/MeasureTheory/Measure/Lebesgue/EqHaar.lean
theorem addHaar_parallelepiped (b : Basis ι ℝ G) (v : ι → G) :
    b.addHaar (parallelepiped v) = ENNReal.ofReal |b.det v|
-- Mathlib/Algebra/BigOperators/NatAntidiagonal.lean
theorem sum_antidiagonal_succ' {n : ℕ} {f : ℕ × ℕ → N} :
    (∑ p ∈ antidiagonal (n + 1), f p) = f (n + 1, 0) + ∑ p ∈ antidiagonal n, f (p.1, p.2 + 1)
-- Mathlib/CategoryTheory/Limits/Shapes/Pullback/HasPullback.lean
@[reassoc]
theorem pushout.inl_desc {W X Y Z : C} {f : X ⟶ Y} {g : X ⟶ Z} [HasPushout f g] (h : Y ⟶ W)
    (k : Z ⟶ W) (w : f ≫ h = g ≫ k) : pushout.inl _ _ ≫ pushout.desc h k w = h
-- Mathlib/Order/Filter/AtTopBot.lean
theorem not_tendsto_const_atTop [Preorder α] [NoMaxOrder α] (x : α) (l : Filter β) [l.NeBot] :
    ¬Tendsto (fun _ => x) l atTop
-- Mathlib/RingTheory/PowerSeries/Order.lean
/-- The order of the formal power series `X` is `1`. -/
@[simp]
theorem order_X : order (X : R⟦X⟧) = 1
-- Mathlib/Computability/TuringMachine.lean
@[simp]
theorem Tape.move_left_mk' {Γ} [Inhabited Γ] (L R : ListBlank Γ) :
    (Tape.mk' L R).move Dir.left = Tape.mk' L.tail (R.cons L.head)
-- Mathlib/Topology/Algebra/Monoid.lean
theorem Filter.TendstoNhdsWithinIio.mul_const [MulPosStrictMono 𝕜] [MulPosReflectLT 𝕜]
    (h : Tendsto f l (𝓝[<] c)) : Tendsto (fun a => f a * b) l (𝓝[<] (c * b))
-- Mathlib/CategoryTheory/Sites/Subsheaf.lean
theorem Subpresheaf.eq_top_iff_isIso : G = ⊤ ↔ IsIso G.ι
-- Mathlib/Algebra/Ring/Parity.lean
lemma iterate_even (hf : Involutive f) (hn : Even n) : f^[n] = id
-- Mathlib/CategoryTheory/Subobject/Basic.lean
/-- Isomorphic functors become equal when lowered to `Subobject`.
(It's not as evil as usual to talk about equality between functors
because the categories are thin and skeletal.) -/
theorem lower_iso (F₁ F₂ : MonoOver X ⥤ MonoOver Y) (h : F₁ ≅ F₂) : lower F₁ = lower F₂
-- Mathlib/Algebra/Star/Unitary.lean
theorem mem_iff_star_mul_self {U : R} : U ∈ unitary R ↔ star U * U = 1
-- Mathlib/Data/Finset/Basic.lean
theorem Nonempty.mono {s t : Finset α} (hst : s ⊆ t) (hs : s.Nonempty) : t.Nonempty
-- .lake/packages/lean4/src/lean/Init/Data/Fin/Lemmas.lean
/-- Version of `succ_one_eq_two` to be used by `dsimp` -/
@[simp] theorem succ_one_eq_two : Fin.succ (1 : Fin (n + 2)) = 2
-- Mathlib/Topology/DenseEmbedding.lean
@[elab_as_elim]
theorem DenseRange.induction_on [TopologicalSpace β] {e : α → β} (he : DenseRange e) {p : β → Prop}
    (b₀ : β) (hp : IsClosed { b | p b }) (ih : ∀ a : α, p <| e a) : p b₀
-- Mathlib/Order/Atoms.lean
theorem isAtomic_iff_forall_isAtomic_Iic [OrderBot α] :
    IsAtomic α ↔ ∀ x : α, IsAtomic (Set.Iic x)
-- Mathlib/Topology/MetricSpace/Thickening.lean
theorem diam_cthickening_le {α : Type*} [PseudoMetricSpace α] (s : Set α) (hε : 0 ≤ ε) :
    diam (cthickening ε s) ≤ diam s + 2 * ε
-- Mathlib/MeasureTheory/MeasurableSpace/Basic.lean
theorem measurable_of_empty [IsEmpty α] (f : α → β) : Measurable f
-- Mathlib/NumberTheory/LSeries/HurwitzZetaEven.lean
/-- The trivial zeroes of the cosine zeta function. -/
theorem cosZeta_neg_two_mul_nat_add_one (a : UnitAddCircle) (n : ℕ) :
    cosZeta a (-2 * (n + 1)) = 0
-- Mathlib/Analysis/SpecialFunctions/Exp.lean
lemma summable_exp_neg_nat : Summable fun n : ℕ ↦ exp (-n)
-- Mathlib/CategoryTheory/Sites/Grothendieck.lean
@[simp]
theorem coe_pullback {Z : C} (f : Y ⟶ X) (g : Z ⟶ Y) (S : J.Cover X) :
    (S.pullback f) g ↔ S (g ≫ f)
-- Mathlib/Data/Bool/Basic.lean
theorem coe_false : ↑false = False
-- Mathlib/Combinatorics/SimpleGraph/Density.lean
theorem mk_mem_interedges_comm : (a, b) ∈ G.interedges s t ↔ (b, a) ∈ G.interedges t s
-- Mathlib/Data/Nat/Defs.lean
@[simp] lemma sqrt_one : sqrt 1 = 1
-- Mathlib/ModelTheory/Semantics.lean
theorem realize_relabel_sum_inr (φ : L.Formula (Fin n)) {v : Empty → M} {x : Fin n → M} :
    (BoundedFormula.relabel Sum.inr φ).Realize v x ↔ φ.Realize x
-- Mathlib/Geometry/Euclidean/Angle/Oriented/Affine.lean
/-- The angle ∡AAB at a point. -/
@[simp]
theorem oangle_self_left (p₁ p₂ : P) : ∡ p₁ p₁ p₂ = 0
-- Mathlib/Data/Countable/Defs.lean
@[simp]
lemma not_uncountable [Countable α] : ¬Uncountable α
-- Mathlib/RingTheory/PowerSeries/Basic.lean
@[simp]
theorem rescale_zero : rescale 0 = (C R).comp (constantCoeff R)
-- Mathlib/Combinatorics/SimpleGraph/Hamiltonian.lean
lemma IsHamiltonianCycle.isCycle (hp : p.IsHamiltonianCycle) : p.IsCycle
-- Mathlib/RingTheory/PowerBasis.lean
theorem exists_smodEq (pb : PowerBasis A B) (b : B) :
    ∃ a, SModEq (Ideal.span ({pb.gen})) b (algebraMap A B a)
-- Mathlib/Algebra/BigOperators/Finprod.lean
@[to_additive]
theorem MonoidHom.map_finprod_of_injective (g : M →* N) (hg : Injective g) (f : α → M) :
    g (∏ᶠ i, f i) = ∏ᶠ i, g (f i)
-- Mathlib/Data/Finsupp/Basic.lean
theorem filter_eq_sum (p : α → Prop) [DecidablePred p] (f : α →₀ M) :
    f.filter p = ∑ i ∈ f.support.filter p, single i (f i)
-- Mathlib/Deprecated/Submonoid.lean
theorem Additive.isAddSubmonoid {s : Set M} :
    IsSubmonoid s → @IsAddSubmonoid (Additive M) _ s
-- Mathlib/Analysis/InnerProductSpace/TwoDim.lean
@[simp]
theorem kahler_apply_self (x : E) : o.kahler x x = ‖x‖ ^ 2
-- Mathlib/Analysis/SpecialFunctions/Trigonometric/Angle.lean
@[simp]
theorem coe_pi_add_coe_pi : (π : Real.Angle) + π = 0
-- Mathlib/Algebra/Group/TypeTags.lean
@[simp]
theorem ofAdd_zsmul [SubNegMonoid α] (z : ℤ) (a : α) : ofAdd (z • a) = ofAdd a ^ z
-- Mathlib/Data/Finset/Basic.lean
theorem toFinset_eq_singleton_iff (s : Multiset α) (a : α) :
    s.toFinset = {a} ↔ card s ≠ 0 ∧ s = card s • {a}
-- Mathlib/Logic/Equiv/Defs.lean
@[simp, mfld_simps] theorem toFun_as_coe (e : α ≃ β) : e.toFun = e
-- Mathlib/Probability/Kernel/RadonNikodym.lean
lemma not_mem_mutuallySingularSetSlice (κ η : Kernel α γ) (a : α) (x : γ) :
    x ∉ mutuallySingularSetSlice κ η a ↔ rnDerivAux κ (κ + η) a x < 1
-- Mathlib/NumberTheory/ModularForms/SlashInvariantForms.lean
/-- `SlashInvariantFormClass F Γ k` asserts `F` is a type of bundled functions that are invariant
under the `SlashAction`. -/
class SlashInvariantFormClass [FunLike F ℍ ℂ] : Prop where
  slash_action_eq : ∀ (f : F) (γ : Γ), (f : ℍ → ℂ) ∣[k] γ = f
-- Mathlib/Data/Setoid/Basic.lean
theorem le_def {r s : Setoid α} : r ≤ s ↔ ∀ {x y}, r.Rel x y → s.Rel x y
-- Mathlib/Order/Hom/Bounded.lean
@[simp]
theorem symm_dual_id : BotHom.dual.symm (TopHom.id _) = BotHom.id α
-- Mathlib/Data/Seq/Computation.lean
theorem has_map_eq_map {β} (f : α → β) (c : Computation α) : f <$> c = map f c
-- Mathlib/Combinatorics/Additive/Energy.lean
@[to_additive (attr := simp)] lemma mulEnergy_pos_iff : 0 < Eₘ[s, t] ↔ s.Nonempty ∧ t.Nonempty
-- Mathlib/Analysis/Distribution/SchwartzSpace.lean
theorem iteratedPDeriv_eq_iteratedFDeriv {n : ℕ} {m : Fin n → E} {f : 𝓢(E, F)} {x : E} :
    iteratedPDeriv 𝕜 m f x = iteratedFDeriv ℝ n f x m
-- Mathlib/Algebra/Lie/Basic.lean
/-- A Lie module is a module over a commutative ring, together with a linear action of a Lie
algebra on this module, such that the Lie bracket acts as the commutator of endomorphisms. -/
class LieModule (R : Type u) (L : Type v) (M : Type w) [CommRing R] [LieRing L] [LieAlgebra R L]
  [AddCommGroup M] [Module R M] [LieRingModule L M] : Prop where
  /-- A Lie module bracket is compatible with scalar multiplication in its first argument. -/
  protected smul_lie : ∀ (t : R) (x : L) (m : M), ⁅t • x, m⁆ = t • ⁅x, m⁆
  /-- A Lie module bracket is compatible with scalar multiplication in its second argument. -/
  protected lie_smul : ∀ (t : R) (x : L) (m : M), ⁅x, t • m⁆ = t • ⁅x, m⁆
-- Mathlib/Algebra/Homology/ShortComplex/RightHomology.lean
/-- When the first map `S.f` is zero, this is the right homology data on `S` given
by any limit kernel fork of `S.g` -/
@[simps]
def ofIsLimitKernelFork (hf : S.f = 0) (c : KernelFork S.g) (hc : IsLimit c) :
    S.RightHomologyData
-- Mathlib/Data/Fin/Basic.lean
lemma predAbove_castPred_of_lt (p i : Fin (n + 1)) (h : p < i) (hp := Fin.ne_last_of_lt h)
  (hi := Fin.ne_zero_of_lt h) : (castPred p hp).predAbove i = pred i hi
-- Mathlib/Topology/Order/Monotone.lean
/-- An antitone function continuous at the indexed infimum over a nonempty `Sort` sends this indexed
infimum to the indexed supremum of the composition. -/
theorem Antitone.map_iInf_of_continuousAt' {ι : Sort*} [Nonempty ι] {f : α → β} {g : ι → α}
    (Cf : ContinuousAt f (iInf g)) (Af : Antitone f)
    (bdd : BddBelow (range g) := by bddDefault) : f (⨅ i, g i) = ⨆ i, f (g i)
-- Mathlib/CategoryTheory/Limits/Shapes/Equalizers.lean
@[reassoc (attr := simp)]
theorem ι_comp_coequalizerComparison [HasCoequalizer f g] [HasCoequalizer (G.map f) (G.map g)] :
    coequalizer.π _ _ ≫ coequalizerComparison f g G = G.map (coequalizer.π _ _)
-- Mathlib/Order/SymmDiff.lean
theorem Codisjoint.bihimp_eq_inf {a b : α} (h : Codisjoint a b) : a ⇔ b = a ⊓ b
-- Mathlib/MeasureTheory/Function/LpSeminorm/Basic.lean
theorem Memℒp.re (hf : Memℒp f p μ) : Memℒp (fun x => RCLike.re (f x)) p μ
-- Mathlib/Topology/Connected/Clopen.lean
@[simp]
theorem coe_eq_coe {x y : α} :
    (x : ConnectedComponents α) = y ↔ connectedComponent x = connectedComponent y
-- Mathlib/MeasureTheory/Function/StronglyMeasurable/Basic.lean
@[to_additive (attr := aesop safe 20 apply (rule_sets := [Measurable]))]
protected theorem smul {𝕜} [TopologicalSpace 𝕜] [SMul 𝕜 β] [ContinuousSMul 𝕜 β] {f : α → 𝕜}
    {g : α → β} (hf : StronglyMeasurable f) (hg : StronglyMeasurable g) :
    StronglyMeasurable fun x => f x • g x
-- Mathlib/Algebra/Group/Opposite.lean
/-- An additive semigroup homomorphism `AddHom M N` can equivalently be viewed as an additive
homomorphism `AddHom Mᵐᵒᵖ Nᵐᵒᵖ`. This is the action of the (fully faithful) `ᵐᵒᵖ`-functor on
morphisms. -/
@[simps]
def AddHom.mulOp {M N} [Add M] [Add N] : AddHom M N ≃ AddHom Mᵐᵒᵖ Nᵐᵒᵖ
-- Mathlib/Data/Nat/Factorization/Root.lean
lemma floorRoot_ne_zero : floorRoot n a ≠ 0 ↔ n ≠ 0 ∧ a ≠ 0
-- Mathlib/Order/Interval/Finset/Basic.lean
theorem Ioi_disjUnion_Iio (a : α) :
    (Ioi a).disjUnion (Iio a) (disjoint_Ioi_Iio a) = ({a} : Finset α)ᶜ
-- Mathlib/FieldTheory/PurelyInseparable.lean
/-- If `E / F` is algebraic, then `E` is purely inseparable over the
separable closure of `F` in `E`. -/
theorem separableClosure.isPurelyInseparable [Algebra.IsAlgebraic F E] :
    IsPurelyInseparable (separableClosure F E) E
-- Mathlib/Analysis/Normed/Module/Dual.lean
/-- If `x'` is a dual element such that the norms `‖x' z‖` are bounded for `z ∈ s`, then a
small scalar multiple of `x'` is in `polar 𝕜 s`. -/
theorem smul_mem_polar {s : Set E} {x' : Dual 𝕜 E} {c : 𝕜} (hc : ∀ z, z ∈ s → ‖x' z‖ ≤ ‖c‖) :
    c⁻¹ • x' ∈ polar 𝕜 s
-- Mathlib/Data/Set/Sups.lean
theorem sups_subset_right : s₁ ⊆ s₂ → s₁ ⊻ t ⊆ s₂ ⊻ t
-- Mathlib/Order/CompleteLattice.lean
@[simp]
theorem iSup_neg {p : Prop} {f : p → α} (hp : ¬p) : ⨆ h : p, f h = ⊥
-- Mathlib/Data/Finset/Pointwise.lean
@[to_additive (attr := simp, norm_cast)]
theorem coe_inv (s : Finset α) : ↑s⁻¹ = (s : Set α)⁻¹
-- Mathlib/Algebra/Star/Unitary.lean
/-- The unitary elements embed into the units. -/
@[simps]
def toUnits : unitary R →* Rˣ
-- Mathlib/Analysis/Normed/Field/UnitBall.lean
@[simp, norm_cast]
theorem coe_mul_unitSphere [NormedDivisionRing 𝕜] (x y : sphere (0 : 𝕜) 1) :
    ↑(x * y) = (x * y : 𝕜)
-- Mathlib/Order/CompleteLattice.lean
@[gcongr]
theorem sInf_le_sInf (h : s ⊆ t) : sInf t ≤ sInf s
-- Mathlib/Topology/Constructions.lean
theorem Pi.continuous_postcomp [TopologicalSpace Y] {g : X → Y} (hg : Continuous g) :
    Continuous (g ∘ · : (ι → X) → (ι → Y))
-- Mathlib/Data/Multiset/Basic.lean
lemma filter_attach (s : Multiset α) (p : α → Prop) [DecidablePred p] :
    (s.attach.filter fun a : {a // a ∈ s} ↦ p ↑a) =
      (s.filter p).attach.map (Subtype.map id fun _ ↦ Multiset.mem_of_mem_filter)
-- Mathlib/NumberTheory/NumberField/CanonicalEmbedding/ConvexBody.lean
theorem convexBodySum_mem {x : K} :
    mixedEmbedding K x ∈ (convexBodySum K B) ↔
      ∑ w : InfinitePlace K, (mult w) * w.val x ≤ B
-- Mathlib/Analysis/Calculus/BumpFunction/Normed.lean
theorem measure_closedBall_le_integral : (μ (closedBall c f.rIn)).toReal ≤ ∫ x, f x ∂μ
-- Mathlib/CategoryTheory/DiscreteCategory.lean
/-- Extract the equation from a morphism in a discrete category. -/
theorem eq_of_hom {X Y : Discrete α} (i : X ⟶ Y) : X.as = Y.as
-- Mathlib/Order/LiminfLimsup.lean
@[simp, nolint simpNF]
theorem limsup_nat_add (f : ℕ → α) (k : ℕ) : limsup (fun i => f (i + k)) atTop = limsup f atTop
-- Mathlib/Analysis/InnerProductSpace/Basic.lean
theorem DirectSum.IsInternal.collectedBasis_orthonormal [DecidableEq ι] {V : ι → Submodule 𝕜 E}
    (hV : OrthogonalFamily 𝕜 (fun i => V i) fun i => (V i).subtypeₗᵢ)
    (hV_sum : DirectSum.IsInternal fun i => V i) {α : ι → Type*}
    {v_family : ∀ i, Basis (α i) 𝕜 (V i)} (hv_family : ∀ i, Orthonormal 𝕜 (v_family i)) :
    Orthonormal 𝕜 (hV_sum.collectedBasis v_family)
-- Mathlib/Order/CompleteBooleanAlgebra.lean
theorem iSup_inf_of_monotone {ι : Type*} [Preorder ι] [IsDirected ι (· ≤ ·)] {f g : ι → α}
    (hf : Monotone f) (hg : Monotone g) : ⨆ i, f i ⊓ g i = (⨆ i, f i) ⊓ ⨆ i, g i
-- Mathlib/Data/Real/Hyperreal.lean
theorem infinitesimal_sub_st {x : ℝ*} (hx : ¬Infinite x) : Infinitesimal (x - ↑(st x))
-- Mathlib/Algebra/Homology/ShortComplex/LeftHomology.lean
@[reassoc (attr := simp)]
lemma iCycles_g : S.iCycles ≫ S.g = 0
-- Mathlib/Analysis/Convex/Cone/Basic.lean
theorem mem_top (x : E) : x ∈ (⊤ : ConvexCone 𝕜 E)
-- Mathlib/Algebra/MvPolynomial/Degrees.lean
theorem degreeOf_mul_X_eq (j : σ) (f : MvPolynomial σ R) :
    degreeOf j (f * X j) ≤ degreeOf j f + 1
-- Mathlib/RingTheory/NonUnitalSubring/Basic.lean
theorem range_eq_map (f : R →ₙ+* S) : f.range = NonUnitalSubring.map f ⊤
-- Mathlib/Algebra/Ring/Hom/Basic.lean
theorem isUnit_map (f : α →+* β) {a : α} : IsUnit a → IsUnit (f a)
-- Mathlib/Analysis/SpecialFunctions/Trigonometric/Series.lean
theorem Complex.sin_eq_tsum (z : ℂ) :
    Complex.sin z = ∑' n : ℕ, (-1) ^ n * z ^ (2 * n + 1) / ↑(2 * n + 1)!
-- Mathlib/LinearAlgebra/Matrix/Determinant/Basic.lean
/-- Permuting the rows changes the sign of the determinant. -/
theorem det_permute' (σ : Perm n) (M : Matrix n n R) :
    (M.submatrix id σ).det = Perm.sign σ * M.det
-- Mathlib/LinearAlgebra/TensorProduct/Basic.lean
@[simp]
theorem lTensor_neg (f : N →ₗ[R] P) : (-f).lTensor M = -f.lTensor M
-- Mathlib/Analysis/BoxIntegral/Partition/Split.lean
@[simp]
theorem splitLower_eq_self : I.splitLower i x = I ↔ I.upper i ≤ x
-- Mathlib/Analysis/Fourier/AddCircle.lean
/-- For each `1 ≤ p < ∞`, the linear span of the monomials `fourier n` is dense in
`Lp ℂ p haarAddCircle`. -/
theorem span_fourierLp_closure_eq_top {p : ℝ≥0∞} [Fact (1 ≤ p)] (hp : p ≠ ∞) :
    (span ℂ (range (@fourierLp T _ p _))).topologicalClosure = ⊤
-- Mathlib/Algebra/Polynomial/Div.lean
theorem ker_evalRingHom (x : R) : RingHom.ker (evalRingHom x) = Ideal.span {X - C x}
-- Mathlib/Order/Basic.lean
protected theorem gt [LT α] {x y : α} (h : x < y) : y > x
-- Mathlib/Order/Bounds/Basic.lean
/-- In a directed order, the union of two sets is bounded above if and only if both sets are. -/
theorem bddAbove_union [IsDirected α (· ≤ ·)] {s t : Set α} :
    BddAbove (s ∪ t) ↔ BddAbove s ∧ BddAbove t
-- Mathlib/Analysis/Calculus/IteratedDeriv/Defs.lean
/-- If the first `n` derivatives within a set of a function are continuous, and its first `n-1`
derivatives are differentiable, then the function is `C^n`. This is not an equivalence in general,
but this is an equivalence when the set has unique derivatives, see
`contDiffOn_iff_continuousOn_differentiableOn_deriv`. -/
theorem contDiffOn_of_continuousOn_differentiableOn_deriv {n : ℕ∞}
    (Hcont : ∀ m : ℕ, (m : ℕ∞) ≤ n → ContinuousOn (fun x => iteratedDerivWithin m f s x) s)
    (Hdiff : ∀ m : ℕ, (m : ℕ∞) < n → DifferentiableOn 𝕜 (fun x => iteratedDerivWithin m f s x) s) :
    ContDiffOn 𝕜 n f s
-- Mathlib/MeasureTheory/Function/StronglyMeasurable/Inner.lean
protected theorem inner {𝕜 : Type*} {E : Type*} [RCLike 𝕜] [NormedAddCommGroup E]
    [InnerProductSpace 𝕜 E] {_ : MeasurableSpace α} {f g : α → E} (hf : StronglyMeasurable f)
    (hg : StronglyMeasurable g) : StronglyMeasurable fun t => @inner 𝕜 _ _ (f t) (g t)
-- Mathlib/Topology/ContinuousOn.lean
theorem OpenEmbedding.map_nhdsWithin_preimage_eq {f : α → β} (hf : OpenEmbedding f) (s : Set β)
    (x : α) : map f (𝓝[f ⁻¹' s] x) = 𝓝[s] f x
-- Mathlib/Algebra/Algebra/Defs.lean
/-- `mul_comm` for `Algebra`s when one element is from the base ring. -/
theorem commutes (r : R) (x : A) : algebraMap R A r * x = x * algebraMap R A r
-- Mathlib/Data/List/DropRight.lean
@[simp]
theorem rtake_zero : rtake l 0 = []
-- .lake/packages/lean4/src/lean/Init/Data/String/Basic.lean
theorem utf8SetAux_of_gt (c' : Char) : ∀ (cs : List Char) {i p : Pos}, i > p → utf8SetAux c' cs i p = cs
-- Mathlib/Data/Prod/Basic.lean
theorem snd_injective [Subsingleton α] : Function.Injective (@snd α β)
-- Mathlib/SetTheory/Game/Nim.lean
/-- The Grundy value of the sum of two nim games with natural numbers of piles equals their bitwise
xor. -/
@[simp]
theorem grundyValue_nim_add_nim (n m : ℕ) :
    grundyValue (nim.{u} n + nim.{u} m) = n ^^^ m
-- Mathlib/CategoryTheory/EssentiallySmall.lean
/-- Constructor for `EssentiallySmall C` from an explicit small category witness. -/
theorem EssentiallySmall.mk' {C : Type u} [Category.{v} C] {S : Type w} [SmallCategory S]
    (e : C ≌ S) : EssentiallySmall.{w} C
-- Mathlib/Logic/Relation.lean
/-- A sufficient condition for the Church-Rosser property. -/
theorem church_rosser (h : ∀ a b c, r a b → r a c → ∃ d, ReflGen r b d ∧ ReflTransGen r c d)
    (hab : ReflTransGen r a b) (hac : ReflTransGen r a c) : Join (ReflTransGen r) b c
-- Mathlib/Tactic/ReduceModChar.lean
lemma CharP.neg_eq_sub_one_mul {α : Type _} [Ring α] (n : ℕ) (inst : CharP α n) (b : α)
    (a : ℕ) (a' : α) (p : IsNat (n - 1 : α) a) (pa : a = a') :
    -b = a' * b
-- .lake/packages/lean4/src/lean/Init/Data/BitVec/Lemmas.lean
@[simp]
theorem getLsb_rotateLeft {x : BitVec w} {r i : Nat}  :
    (x.rotateLeft r).getLsb i =
      cond (i < r % w)
      (x.getLsb (w - (r % w) + i))
      (decide (i < w) && x.getLsb (i - (r % w)))
-- Mathlib/Data/Nat/Order/Lemmas.lean
theorem Subtype.coe_bot {s : Set ℕ} [DecidablePred (· ∈ s)] [h : Nonempty s] :
    ((⊥ : s) : ℕ) = Nat.find (nonempty_subtype.1 h)
-- Mathlib/CategoryTheory/Limits/IsLimit.lean
/-- Colimit cocones on `F` are unique up to isomorphism. -/
@[simps]
def uniqueUpToIso {s t : Cocone F} (P : IsColimit s) (Q : IsColimit t) : s ≅ t
-- Mathlib/Order/RelSeries.lean
/--
Given a series `a₀ -r→ a₁ -r→ ... -r→ aₙ` and an `a` such that `a₀ -r→ a` holds, there is
a series of length `n+1`: `a -r→ a₀ -r→ a₁ -r→ ... -r→ aₙ`.
-/
@[simps! length]
def cons (p : RelSeries r) (newHead : α) (rel : r newHead p.head) : RelSeries r
-- Mathlib/Order/Filter/Basic.lean
theorem mem_generate_iff {s : Set <| Set α} {U : Set α} :
    U ∈ generate s ↔ ∃ t ⊆ s, Set.Finite t ∧ ⋂₀ t ⊆ U
-- Mathlib/NumberTheory/Bernoulli.lean
/-- Odd Bernoulli numbers (greater than 1) are zero. -/
theorem bernoulli'_odd_eq_zero {n : ℕ} (h_odd : Odd n) (hlt : 1 < n) : bernoulli' n = 0
-- Mathlib/Topology/Basic.lean
@[fun_prop]
theorem Continuous.continuousAt (h : Continuous f) : ContinuousAt f x
-- Mathlib/Topology/DiscreteQuotient.lean
@[simp]
theorem ofLE_map (cond : LEComap f A B) (h : B ≤ B') (a : A) :
    ofLE h (map f cond a) = map f (cond.mono le_rfl h) a
-- Mathlib/Probability/Independence/Basic.lean
lemma IndepFun_iff_Indep [mβ : MeasurableSpace β]
    [mγ : MeasurableSpace γ] (f : Ω → β) (g : Ω → γ) (μ : Measure Ω) :
    IndepFun f g μ ↔ Indep (MeasurableSpace.comap f mβ) (MeasurableSpace.comap g mγ) μ
-- Mathlib/Order/Bounds/Basic.lean
theorem isLUB_Icc (h : a ≤ b) : IsLUB (Icc a b) b
-- Mathlib/Topology/Algebra/ProperAction.lean
/-- Proper group action in the sense of Bourbaki:
the map `G × X → X × X` is a proper map (see `IsProperMap`). -/
@[to_additive existing (attr := mk_iff)]
class ProperSMul (G X : Type*) [TopologicalSpace G] [TopologicalSpace X] [Group G]
    [MulAction G X] : Prop where
  /-- Proper group action in the sense of Bourbaki:
  the map `G × X → X × X` is a proper map (see `IsProperMap`). -/
  isProperMap_smul_pair : IsProperMap (fun gx ↦ (gx.1 • gx.2, gx.2) : G × X → X × X)
-- Mathlib/Logic/Function/Basic.lean
/-- A relation `r : α → β → Prop` is "function-like"
(for each `a` there exists a unique `b` such that `r a b`)
if and only if it is `(f · = ·)` for some function `f`. -/
lemma forall_existsUnique_iff' {r : α → β → Prop} :
    (∀ a, ∃! b, r a b) ↔ ∃ f : α → β, r = (f · = ·)
-- Mathlib/Data/Finset/Pointwise.lean
@[to_additive (attr := simp)]
theorem singletonOneHom_apply (a : α) : singletonOneHom a = {a}
-- Mathlib/Algebra/Homology/ShortComplex/Linear.lean
@[simp]
lemma cyclesMap'_smul :
    cyclesMap' (a • φ) h₁ h₂ = a • cyclesMap' φ h₁ h₂
-- .lake/packages/lean4/src/lean/Init/Ext.lean
@[ext] theorem Sigma.ext : {x y : Sigma β} → x.fst = y.fst → HEq x.snd y.snd → x = y
-- Mathlib/NumberTheory/NumberField/Units/DirichletTheorem.lean
@[simp]
theorem logEmbedding_component (x : (𝓞 K)ˣ) (w : {w : InfinitePlace K // w ≠ w₀}) :
    (logEmbedding K x) w = mult w.val * Real.log (w.val x)
-- Mathlib/Topology/Support.lean
@[to_additive]
theorem HasCompactMulSupport.mul (hf : HasCompactMulSupport f) (hf' : HasCompactMulSupport f') :
    HasCompactMulSupport (f * f')
-- Mathlib/Analysis/Convex/Radon.lean
/-- **Helly's theorem** for sets of compact convex sets in its classical version.

If `F` is a (possibly infinite) set of more than `d + 1` compact convex sets in a vector space of
finite dimension `d`, and any `d + 1` sets from `F` intersect nontrivially,
then all sets from `F` intersect nontrivially. -/
theorem helly_theorem_set_compact [TopologicalSpace E] [T2Space E] {F : Set (Set E)}
    (h_card : finrank 𝕜 E + 1 ≤ F.encard)
    (h_convex : ∀ X ∈ F, Convex 𝕜 X) (h_compact : ∀ X ∈ F, IsCompact X)
    (h_inter : ∀ G : Finset (Set E), (G : Set (Set E)) ⊆ F → G.card = finrank 𝕜 E + 1 →
    (⋂₀ G : Set E).Nonempty) :
    (⋂₀ (F : Set (Set E))).Nonempty
-- Mathlib/Logic/Equiv/Basic.lean
theorem Perm.extendDomain_apply_not_subtype {b : β'} (h : ¬p b) : e.extendDomain f b = b
-- Mathlib/MeasureTheory/Function/AEEqFun.lean
theorem coeFn_comp₂Measurable (g : β → γ → δ) (hg : Measurable (uncurry g)) (f₁ : α →ₘ[μ] β)
    (f₂ : α →ₘ[μ] γ) : comp₂Measurable g hg f₁ f₂ =ᵐ[μ] fun a => g (f₁ a) (f₂ a)
-- Mathlib/Order/Filter/AtTopBot.lean
theorem Eventually.atTop_of_arithmetic {p : ℕ → Prop} {n : ℕ} (hn : n ≠ 0)
    (hp : ∀ k < n, ∀ᶠ a in atTop, p (n * a + k)) : ∀ᶠ a in atTop, p a
-- Mathlib/Order/Booleanisation.lean
@[simp] lemma compl_comp (a : α) : (comp a)ᶜ = lift a
-- Mathlib/Analysis/InnerProductSpace/Adjoint.lean
theorem inner_map_map (u : unitary (H →L[𝕜] H)) (x y : H) :
    ⟪(u : H →L[𝕜] H) x, (u : H →L[𝕜] H) y⟫_𝕜 = ⟪x, y⟫_𝕜
-- Mathlib/Order/Heyting/Hom.lean
@[simp]
theorem coe_comp (f : CoheytingHom β γ) (g : CoheytingHom α β) : ⇑(f.comp g) = f ∘ g
-- Mathlib/Data/Sym/Basic.lean
theorem replicate_right_injective {n : ℕ} (h : n ≠ 0) :
    Function.Injective (replicate n : α → Sym α n)
-- .lake/packages/lean4/src/lean/Init/Data/List/Lemmas.lean
theorem lookup_replicate_of_pos {k : α} (h : 0 < n) :
    (replicate n (a,b)).lookup k = if k == a then some b else none
-- Mathlib/Topology/Connected/PathConnected.lean
theorem IsPathConnected.isConnected (hF : IsPathConnected F) : IsConnected F
-- Mathlib/MeasureTheory/Measure/WithDensityFinite.lean
lemma toFiniteAux_apply (μ : Measure α) [SFinite μ] (s : Set α) :
    μ.toFiniteAux s = ∑' n, (2 ^ (n + 1) * sFiniteSeq μ n Set.univ)⁻¹ * sFiniteSeq μ n s
-- Mathlib/Tactic/LinearCombination.lean
theorem pf_mul_c [Mul α] (p : a = b) (c : α) : a * c = b * c