ruc-ai4math/mathlib_handler_benchmark_410 huggingface dataset:
-- Mathlib/Algebra/LinearRecurrence.lean
/-- The dimension of `E.solSpace` is `E.order`. -/
theorem solSpace_rank : Module.rank α E.solSpace = E.order
-- Mathlib/Algebra/Ring/BooleanRing.lean
@[simp]
theorem toBoolRing_ofBoolRing (a : AsBoolRing α) : toBoolRing (ofBoolRing a) = a
-- Mathlib/Analysis/PSeries.lean
theorem tsum_condensed_le (hf : ∀ ⦃m n⦄, 1 < m → m ≤ n → f n ≤ f m) :
    (∑' k : ℕ, 2 ^ k * f (2 ^ k)) ≤ f 1 + 2 * ∑' k, f k
-- Mathlib/Topology/UniformSpace/UniformConvergenceTopology.lean
protected lemma continuous_rng_iff {X : Type*} [TopologicalSpace X] {f : X → (α →ᵤ[𝔖] β)} :
    Continuous f ↔ ∀ s ∈ 𝔖,
      Continuous (UniformFun.ofFun ∘ s.restrict ∘ UniformOnFun.toFun 𝔖 ∘ f)
-- Mathlib/Algebra/Ring/Equiv.lean
protected theorem bijective (e : R ≃+* S) : Function.Bijective e
-- Mathlib/Data/Nat/Fib/Basic.lean
theorem fib_lt_fib_succ {n : ℕ} (hn : 2 ≤ n) : fib n < fib (n + 1)
-- Mathlib/FieldTheory/Adjoin.lean
theorem adjoin_simple_adjoin_simple (β : E) : F⟮α⟯⟮β⟯.restrictScalars F = F⟮α, β⟯
-- Mathlib/Order/Filter/Pointwise.lean
@[to_additive (attr := simp)]
theorem eventually_one {p : α → Prop} : (∀ᶠ x in 1, p x) ↔ p 1
-- .lake/packages/lean4/src/lean/Init/Data/Int/Order.lean
theorem natAbs_mul (a b : Int) : natAbs (a * b) = natAbs a * natAbs b
-- Mathlib/MeasureTheory/Constructions/Polish/Basic.lean
theorem Continuous.map_eq_borel {X Y : Type*} [TopologicalSpace X] [PolishSpace X]
    [MeasurableSpace X] [BorelSpace X] [TopologicalSpace Y] [T0Space Y] [SecondCountableTopology Y]
    {f : X → Y} (hf : Continuous f) (hsurj : Surjective f) :
    MeasurableSpace.map f ‹MeasurableSpace X› = borel Y
-- Mathlib/GroupTheory/GroupAction/Basic.lean
@[to_additive (attr := simp)]
theorem mem_fixedPoints {a : α} : a ∈ fixedPoints M α ↔ ∀ m : M, m • a = a
-- Mathlib/Analysis/Distribution/FourierSchwartz.lean
@[simp] lemma fourierTransformCLE_apply (f : 𝓢(V, E)) :
    fourierTransformCLE 𝕜 f = 𝓕 f
-- Mathlib/CategoryTheory/Elements.lean
/-- The reverse direction of the equivalence `F.Elementsᵒᵖ ≅ (yoneda, F)`,
given by `CategoryTheory.yonedaEquiv`.
-/
@[simps]
def fromCostructuredArrow (F : Cᵒᵖ ⥤ Type v) : (CostructuredArrow yoneda F)ᵒᵖ ⥤ F.Elements
-- Mathlib/Algebra/Star/Basic.lean
theorem starRingEnd_self_apply (x : R) : starRingEnd R (starRingEnd R x) = x
-- Mathlib/Analysis/Normed/Ring/SeminormFromBounded.lean
/-- If `f : R → ℝ` is a nonnegative, multiplicatively bounded function, then the kernel of
  `seminormFromBounded' f` equals the kernel of `f`. -/
theorem seminormFromBounded_ker (f_nonneg : 0 ≤ f)
    (f_mul : ∀ x y : R, f (x * y) ≤ c * f x * f y) :
    seminormFromBounded' f ⁻¹' {0} = f ⁻¹' {0}
-- Mathlib/CategoryTheory/Limits/Shapes/Products.lean
lemma Sigma.map'_comp_map' {f : α → C} {g : β → C} {h : γ → C} [HasCoproduct f] [HasCoproduct g]
    [HasCoproduct h] (p : α → β) (p' : β → γ) (q : ∀ (a : α), f a ⟶ g (p a))
    (q' : ∀ (b : β), g b ⟶ h (p' b)) :
    Sigma.map' p q ≫ Sigma.map' p' q' = Sigma.map' (p' ∘ p) (fun a => q a ≫ q' (p a))
-- Mathlib/Algebra/GCDMonoid/Basic.lean
theorem dvd_mul_gcd_iff_dvd_mul [GCDMonoid α] {m n k : α} : k ∣ m * gcd k n ↔ k ∣ m * n
-- Mathlib/Algebra/Ring/Subsemiring/Basic.lean
theorem mem_carrier {s : Subsemiring R} {x : R} : x ∈ s.carrier ↔ x ∈ s
-- Mathlib/Algebra/Group/Opposite.lean
@[to_additive (attr := simp)]
theorem semiconjBy_op [Mul α] {a x y : α} : SemiconjBy (op a) (op y) (op x) ↔ SemiconjBy a x y
-- Mathlib/Computability/Primrec.lean
protected theorem decode₂ : Primrec (decode₂ α)
-- Mathlib/RingTheory/PrincipalIdealDomain.lean
theorem _root_.IsRelPrime.isCoprime (h : IsRelPrime x y) : IsCoprime x y
-- Mathlib/Analysis/InnerProductSpace/TwoDim.lean
theorem areaForm_map {F : Type*} [NormedAddCommGroup F] [InnerProductSpace ℝ F]
    [hF : Fact (finrank ℝ F = 2)] (φ : E ≃ₗᵢ[ℝ] F) (x y : F) :
    (Orientation.map (Fin 2) φ.toLinearEquiv o).areaForm x y =
    o.areaForm (φ.symm x) (φ.symm y)
-- Mathlib/Topology/MetricSpace/Pseudo/Defs.lean
theorem uniformity_basis_dist_pow {r : ℝ} (h0 : 0 < r) (h1 : r < 1) :
    (𝓤 α).HasBasis (fun _ : ℕ => True) fun n : ℕ => { p : α × α | dist p.1 p.2 < r ^ n }
-- Mathlib/RingTheory/Multiplicity.lean
theorem multiplicity_ne_zero {a b : α} : multiplicity a b ≠ 0 ↔ a ∣ b
-- Mathlib/RingTheory/Valuation/ValuationSubring.lean
theorem eq_iff_unitGroup {A B : ValuationSubring K} : A = B ↔ A.unitGroup = B.unitGroup
-- .lake/packages/lean4/src/lean/Init/Data/Fin/Lemmas.lean
@[simp] theorem subNat_mk {i : Nat} (h₁ : i < n + m) (h₂ : m ≤ i) :
    subNat m ⟨i, h₁⟩ h₂ = ⟨i - m, Nat.sub_lt_right_of_lt_add h₂ h₁⟩
-- .lake/packages/lean4/src/lean/Init/Data/List/Lemmas.lean
@[simp] theorem mem_append {a : α} {s t : List α} : a ∈ s ++ t ↔ a ∈ s ∨ a ∈ t
-- Mathlib/Topology/Algebra/Monoid.lean
@[to_additive]
theorem continuousAt_pow (x : M) (n : ℕ) : ContinuousAt (fun (x : M) => x ^ n) x
-- Mathlib/RingTheory/SimpleModule.lean
/-- A module is semisimple iff it is generated by its simple submodules. -/
theorem sSup_simples_eq_top_iff_isSemisimpleModule :
    sSup { m : Submodule R M | IsSimpleModule R m } = ⊤ ↔ IsSemisimpleModule R M
-- Mathlib/Topology/LocallyConstant/Basic.lean
theorem eq_const [PreconnectedSpace X] {f : X → Y} (hf : IsLocallyConstant f) (x : X) :
    f = Function.const X (f x)
-- Mathlib/Order/Sublattice.lean
lemma map_le_iff_le_comap {f : LatticeHom α β} {M : Sublattice β} : L.map f ≤ M ↔ L ≤ M.comap f
-- Mathlib/LinearAlgebra/LinearPMap.lean
theorem graph_map_snd_eq_range (f : E →ₗ.[R] F) :
    f.graph.map (LinearMap.snd R E F) = LinearMap.range f.toFun
-- Mathlib/Order/SuccPred/Basic.lean
@[simp]
theorem Ioo_pred_left (a b : α) : Ioo (pred a) b = Ico a b
-- Mathlib/Analysis/SpecialFunctions/Complex/LogBounds.lean
/-- The difference of `log (1+z)` and its `(n+1)`st Taylor polynomial can be bounded in
terms of `‖z‖`. -/
lemma norm_log_sub_logTaylor_le (n : ℕ) {z : ℂ} (hz : ‖z‖ < 1) :
    ‖log (1 + z) - logTaylor (n + 1) z‖ ≤ ‖z‖ ^ (n + 1) * (1 - ‖z‖)⁻¹ / (n + 1)
-- Mathlib/Geometry/Manifold/ContMDiff/Defs.lean
theorem contMDiffWithinAt_inter' (ht : t ∈ 𝓝[s] x) :
    ContMDiffWithinAt I I' n f (s ∩ t) x ↔ ContMDiffWithinAt I I' n f s x
-- Mathlib/FieldTheory/Adjoin.lean
@[simp]
theorem inf_toSubfield (S T : IntermediateField F E) :
    (S ⊓ T).toSubfield = S.toSubfield ⊓ T.toSubfield
-- Mathlib/Algebra/Group/Pi/Lemmas.lean
@[to_additive]
theorem Set.piecewise_div [∀ i, Div (f i)] (s : Set I) [∀ i, Decidable (i ∈ s)]
    (f₁ f₂ g₁ g₂ : ∀ i, f i) :
    s.piecewise (f₁ / f₂) (g₁ / g₂) = s.piecewise f₁ g₁ / s.piecewise f₂ g₂
-- Mathlib/Algebra/ContinuedFractions/Computation/Translations.lean
theorem of_s_head_aux (v : K) : (of v).s.get? 0 = (IntFractPair.stream v 1).bind (some ∘ fun p =>
    { a := 1
      b := p.b })
-- Mathlib/Data/Set/Pairwise/Basic.lean
theorem Nonempty.pairwise_iff_exists_forall [IsEquiv α r] {s : Set ι} (hs : s.Nonempty) :
    s.Pairwise (r on f) ↔ ∃ z, ∀ x ∈ s, r (f x) z
-- Mathlib/Algebra/Polynomial/Eval.lean
@[simp]
protected theorem map_mul : (p * q).map f = p.map f * q.map f
-- Mathlib/Algebra/Module/Torsion.lean
@[simp]
theorem isTorsionBySet_singleton_iff : IsTorsionBySet R M {a} ↔ IsTorsionBy R M a
-- Mathlib/Data/Set/Finite.lean
protected lemma Infinite.mono {s t : Set α} (h : s ⊆ t) : s.Infinite → t.Infinite
-- Mathlib/Data/Finset/Basic.lean
theorem toList_insert [DecidableEq α] {a : α} {s : Finset α} (h : a ∉ s) :
    (insert a s).toList ~ a :: s.toList
-- Mathlib/Geometry/Manifold/Algebra/Monoid.lean
@[to_additive]
theorem contMDiffOn_finset_prod (h : ∀ i ∈ t, ContMDiffOn I' I n (f i) s) :
    ContMDiffOn I' I n (fun x => ∏ i ∈ t, f i x) s
-- Mathlib/Algebra/Homology/ShortComplex/Homology.lean
@[reassoc (attr := simp)]
lemma RightHomologyData.rightHomologyIso_hom_comp_homologyIso_inv (h : S.RightHomologyData) :
    h.rightHomologyIso.hom ≫ h.homologyIso.inv = S.rightHomologyIso.hom
-- Mathlib/Analysis/Normed/Lp/lpSpace.lean
theorem norm_apply_le_norm (hp : p ≠ 0) (f : lp E p) (i : α) : ‖f i‖ ≤ ‖f‖
-- Mathlib/Topology/Order.lean
theorem Continuous.le_induced (h : Continuous[t, t'] f) : t ≤ t'.induced f
-- Mathlib/MeasureTheory/Integral/IntervalIntegral.lean
theorem integral_zero_ae (h : ∀ᵐ x ∂μ, x ∈ Ι a b → f x = 0) : ∫ x in a..b, f x ∂μ = 0
-- Mathlib/Analysis/SpecialFunctions/Trigonometric/Basic.lean
@[simp]
theorem cos_pi_over_two_pow : ∀ n : ℕ, cos (π / 2 ^ (n + 1)) = sqrtTwoAddSeries 0 n / 2
-- Mathlib/SetTheory/Ordinal/Exponential.lean
theorem opow_lt_opow_iff_right {a b c : Ordinal} (a1 : 1 < a) : a ^ b < a ^ c ↔ b < c
-- Mathlib/Probability/Martingale/Upcrossing.lean
theorem lowerCrossingTime_lt_upperCrossingTime (hab : a < b)
    (hn : upperCrossingTime a b f N (n + 1) ω ≠ N) :
    lowerCrossingTime a b f N n ω < upperCrossingTime a b f N (n + 1) ω
-- Mathlib/NumberTheory/Cyclotomic/PrimitiveRoots.lean
/-- If `Irreducible (cyclotomic (p ^ (k + 1)) K)` (in particular for `K = ℚ`) and `p` is a prime,
then the norm of `(zeta (p ^ (k + 1)) K L) ^ (p ^ s) - 1` is `p ^ (p ^ s)`
if `p ^ (k - s + 1) ≠ 2`. -/
theorem norm_zeta_pow_sub_one_of_prime_pow_ne_two {k : ℕ} [Fact (p : ℕ).Prime]
    [IsCyclotomicExtension {p ^ (k + 1)} K L]
    (hirr : Irreducible (cyclotomic (↑(p ^ (k + 1)) : ℕ) K)) {s : ℕ} (hs : s ≤ k)
    (htwo : p ^ (k - s + 1) ≠ 2) :
    norm K (zeta (p ^ (k + 1)) K L ^ (p : ℕ) ^ s - 1) = (p : K) ^ (p : ℕ) ^ s
-- Mathlib/Logic/IsEmpty.lean
@[simp]
theorem forall_iff {p : α → Prop} : (∀ a, p a) ↔ True
-- Mathlib/RingTheory/Ideal/Basic.lean
theorem exists_max_ideal_of_mem_nonunits [CommSemiring α] (h : a ∈ nonunits α) :
    ∃ I : Ideal α, I.IsMaximal ∧ a ∈ I
-- Mathlib/CategoryTheory/Localization/CalculusOfFractions.lean
lemma inverts : W.IsInvertedBy (Q W)
-- Mathlib/Data/List/Dedup.lean
theorem count_dedup (l : List α) (a : α) : l.dedup.count a = if a ∈ l then 1 else 0
-- Mathlib/Algebra/Group/Units.lean
@[to_additive]
theorem copy_eq (u : αˣ) (val hv inv hi) : u.copy val hv inv hi = u
-- .lake/packages/batteries/Batteries/Data/LazyList.lean
theorem append_assoc {α} (xs ys zs : LazyList α) :
    (xs.append ys).append zs = xs.append (ys.append zs)
-- Mathlib/Topology/Algebra/InfiniteSum/Order.lean
@[to_additive]
theorem hasProd_of_isLUB_of_one_le [LinearOrderedCommMonoid α] [TopologicalSpace α]
    [OrderTopology α] {f : ι → α} (i : α) (h : ∀ i, 1 ≤ f i)
    (hf : IsLUB (Set.range fun s ↦ ∏ i ∈ s, f i) i) : HasProd f i
-- Mathlib/Analysis/Normed/Module/FiniteDimension.lean
theorem IsEquivalent.summable_iff {ι E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E]
    [FiniteDimensional ℝ E] {f : ι → E} {g : ι → E} (h : f ~[cofinite] g) :
    Summable f ↔ Summable g
-- Mathlib/Analysis/Asymptotics/Asymptotics.lean
theorem isLittleO_refl_left : (fun x => f' x - f' x) =o[l] g'
-- Mathlib/Topology/Sheaves/Sheafify.lean
theorem stalkToFiber_injective (x : X) : Function.Injective (F.stalkToFiber x)
-- Mathlib/Computability/Partrec.lean
theorem bind_decode_iff {f : α → β → Option σ} :
    (Computable₂ fun a n => (decode (α := β) n).bind (f a)) ↔ Computable₂ f
-- Mathlib/Dynamics/Circle/RotationNumber/TranslationNumber.lean
theorem le_iterate_of_add_int_le_map {x : ℝ} {m : ℤ} (h : x + m ≤ f x) (n : ℕ) :
    x + n * m ≤ f^[n] x
-- Mathlib/Data/Rat/Lemmas.lean
theorem inv_natCast_num_of_pos {a : ℕ} (ha0 : 0 < a) : (a : ℚ)⁻¹.num = 1
-- Mathlib/Data/Set/Subset.lean
lemma subset_of_image_val_subset_image_val (h : (↑D : Set α) ⊆ ↑E) : D ⊆ E
-- Mathlib/Data/Set/Basic.lean
@[simp]
theorem setOf_true : { _x : α | True } = univ
-- Mathlib/Analysis/RCLike/Basic.lean
theorem ofNat_mul_im (n : ℕ) [n.AtLeastTwo] (z : K) :
    im (OfNat.ofNat n * z) = OfNat.ofNat n * im z
-- Mathlib/Topology/Sheaves/Sheaf.lean
theorem isSheaf_iso_iff {F G : Presheaf C X} (α : F ≅ G) : F.IsSheaf ↔ G.IsSheaf
-- Mathlib/LinearAlgebra/CliffordAlgebra/Equivs.lean
/-- The quaternion conjugate maps to the "clifford conjugate" (aka `star`). -/
@[simp]
theorem ofQuaternion_star (q : ℍ[R,c₁,c₂]) : ofQuaternion (star q) = star (ofQuaternion q)
-- Mathlib/RingTheory/Polynomial/Content.lean
theorem content_primPart (p : R[X]) : p.primPart.content = 1
-- Mathlib/Topology/Algebra/Order/Compact.lean
/-- A compact set is bounded above -/
theorem IsCompact.bddAbove [ClosedIciTopology α] [Nonempty α] {s : Set α} (hs : IsCompact s) :
    BddAbove s
-- Mathlib/CategoryTheory/Limits/Shapes/Products.lean
/-- An iterated product is a product over a sigma type. -/
@[simps]
def piPiIso {ι : Type*} (f : ι → Type*) (g : (i : ι) → (f i) → C)
    [∀ i, HasProduct (g i)] [HasProduct fun i => ∏ᶜ g i] :
    (∏ᶜ fun i => ∏ᶜ g i) ≅ (∏ᶜ fun p : Σ i, f i => g p.1 p.2)
-- Mathlib/Order/Filter/Bases.lean
theorem mem_prod_self_iff {s} : s ∈ la ×ˢ la ↔ ∃ t ∈ la, t ×ˢ t ⊆ s
-- Mathlib/Algebra/Polynomial/Degree/Definitions.lean
theorem card_support_C_mul_X_pow_le_one {c : R} {n : ℕ} : card (support (C c * X ^ n)) ≤ 1
-- Mathlib/NumberTheory/LucasLehmer.lean
@[simp] theorem mersenne_zero : mersenne 0 = 0
-- Mathlib/Topology/Sheaves/SheafCondition/Sites.lean
theorem IsOpenMap.coverPreserving (hf : IsOpenMap f) :
    CoverPreserving (Opens.grothendieckTopology X) (Opens.grothendieckTopology Y) hf.functor
-- Mathlib/Analysis/RCLike/Basic.lean
theorem ofReal_eq_zero {x : ℝ} : (x : K) = 0 ↔ x = 0
-- Mathlib/Topology/Algebra/GroupWithZero.lean
theorem map_mul_left_nhds_one₀ (ha : a ≠ 0) : map (a * ·) (𝓝 1) = 𝓝 (a)
-- Mathlib/RingTheory/Derivation/Basic.lean
@[simp]
theorem coe_to_linearMap_comp : (f.compDer D : A →ₗ[R] N) = (f : M →ₗ[R] N).comp (D : A →ₗ[R] M)
-- Mathlib/Algebra/Polynomial/Reverse.lean
@[simp] lemma reverse_X_mul (p : R[X]) : reverse (X * p) = reverse p
-- Mathlib/Algebra/GroupWithZero/NonZeroDivisors.lean
lemma mem_nonZeroSMulDivisors_iff {x : R} : x ∈ R⁰[M] ↔ ∀ (m : M), x • m = 0 → m = 0
-- Mathlib/Data/Int/Bitwise.lean
@[simp]
theorem bodd_one : bodd 1 = true
-- Mathlib/Analysis/Convex/Combination.lean
theorem Set.Finite.convexHull_eq {s : Set E} (hs : s.Finite) : convexHull R s =
    { x : E | ∃ w : E → R, (∀ y ∈ s, 0 ≤ w y) ∧ ∑ y ∈ hs.toFinset, w y = 1 ∧
      hs.toFinset.centerMass w id = x }
-- Mathlib/Data/Num/Lemmas.lean
@[simp]
theorem cast_pos [LinearOrderedSemiring α] (n : PosNum) : 0 < (n : α)
-- Mathlib/Analysis/SpecialFunctions/Gaussian/FourierTransform.lean
theorem integrable_cexp_neg_mul_sum_add {ι : Type*} [Fintype ι] (hb : 0 < b.re) (c : ι → ℂ) :
    Integrable (fun (v : ι → ℝ) ↦ cexp (- b * ∑ i, (v i : ℂ) ^ 2 + ∑ i, c i * v i))
-- Mathlib/GroupTheory/SpecificGroups/Dihedral.lean
theorem nat_card : Nat.card (DihedralGroup n) = 2 * n
-- Mathlib/NumberTheory/LegendreSymbol/JacobiSymbol.lean
theorem div_four_left {a : ℤ} {b : ℕ} (ha4 : a % 4 = 0) (hb2 : b % 2 = 1) :
    J(a / 4 | b) = J(a | b)
-- Mathlib/CategoryTheory/WithTerminal.lean
/-- A variant of `lift_unique` with `Z` an initial object. -/
@[simps!]
def liftToInitialUnique {D : Type*} [Category D] {Z : D} (F : C ⥤ D) (hZ : Limits.IsInitial Z)
    (G : WithInitial C ⥤ D) (h : incl ⋙ G ≅ F) (hG : G.obj star ≅ Z) : G ≅ liftToInitial F hZ
-- Mathlib/Algebra/Order/Ring/WithTop.lean
lemma mul_def (a b : WithBot α) :
    a * b = if a = 0 ∨ b = 0 then 0 else WithBot.map₂ (· * ·) a b
-- Mathlib/Algebra/Algebra/Unitization.lean
/-- The canonical `R`-linear projection `Unitization R A → A`. -/
@[simps apply]
def sndHom [Semiring R] [AddCommMonoid A] [Module R A] : Unitization R A →ₗ[R] A
-- Mathlib/RingTheory/Regular/RegularSequence.lean
@[simp] lemma ofList_cons (r : R) (rs : List R) :
    ofList (r::rs) = span {r} ⊔ ofList rs
-- Mathlib/RingTheory/Polynomial/Cyclotomic/Basic.lean
/-- If there is a primitive `n`-th root of unity in `K`, then
`∏ i ∈ Nat.divisors n, cyclotomic' i K = X ^ n - 1`. -/
theorem prod_cyclotomic'_eq_X_pow_sub_one {K : Type*} [CommRing K] [IsDomain K] {ζ : K} {n : ℕ}
    (hpos : 0 < n) (h : IsPrimitiveRoot ζ n) :
    ∏ i ∈ Nat.divisors n, cyclotomic' i K = X ^ n - 1
-- Mathlib/Geometry/Manifold/Algebra/SmoothFunctions.lean
/-- Coercion to a function as a `RingHom`. -/
@[simps]
def coeFnRingHom {R : Type*} [CommRing R] [TopologicalSpace R] [ChartedSpace H' R]
    [SmoothRing I' R] : C^∞⟮I, N; I', R⟯ →+* N → R
-- Mathlib/Order/Filter/Prod.lean
theorem Tendsto.prod_map_coprod {δ : Type*} {f : α → γ} {g : β → δ} {a : Filter α} {b : Filter β}
    {c : Filter γ} {d : Filter δ} (hf : Tendsto f a c) (hg : Tendsto g b d) :
    Tendsto (Prod.map f g) (a.coprod b) (c.coprod d)
-- Mathlib/CategoryTheory/Limits/Shapes/Kernels.lean
/-- The isomorphism between points of limit kernel forks induced by an isomorphism
in the category of arrows. -/
@[simps]
def mapIsoOfIsLimit {kf : KernelFork f} {kf' : KernelFork f'}
    (hf : IsLimit kf) (hf' : IsLimit kf')
    (φ : Arrow.mk f ≅ Arrow.mk f') : kf.pt ≅ kf'.pt
-- Mathlib/Topology/MetricSpace/Pseudo/Constructions.lean
/-- An open ball in a product space is a product of open balls. See also `ball_pi`
for a version assuming `0 < r` instead of `Nonempty β`. -/
lemma ball_pi' [Nonempty β] (x : ∀ b, π b) (r : ℝ) :
    ball x r = Set.pi univ fun b => ball (x b) r
-- Mathlib/Data/Set/Finite.lean
theorem Finite.seq' {α β : Type u} {f : Set (α → β)} {s : Set α} (hf : f.Finite) (hs : s.Finite) :
    (f <*> s).Finite
-- Mathlib/FieldTheory/Finite/Polynomial.lean
theorem degrees_indicator (c : σ → K) :
    degrees (indicator c) ≤ ∑ s : σ, (Fintype.card K - 1) • {s}
-- Mathlib/Data/Matrix/ColumnRowPartitioned.lean
/-- Negating a matrix partitioned by rows is equivalent to negating each of the rows. -/
@[simp]
lemma fromRows_neg (A₁ : Matrix m₁ n R) (A₂ : Matrix m₂ n R) :
    -fromRows A₁ A₂ = fromRows (-A₁) (-A₂)
-- Mathlib/Logic/Relation.lean
theorem ReflTransGen.lift {p : β → β → Prop} {a b : α} (f : α → β)
    (h : ∀ a b, r a b → p (f a) (f b)) (hab : ReflTransGen r a b) : ReflTransGen p (f a) (f b)
-- Mathlib/Order/Height.lean
@[simp]
theorem one_le_chainHeight_iff : 1 ≤ s.chainHeight ↔ s.Nonempty
-- Mathlib/Data/Fin/Basic.lean
theorem castPred_lt_iff {j : Fin n} {i : Fin (n + 1)} (hi : i ≠ last n) :
    castPred i hi < j ↔ i < castSucc j
-- Mathlib/Data/Set/Function.lean
@[simp] lemma graphOn_empty (f : α → β) : graphOn f ∅ = ∅
-- Mathlib/Data/Finset/Union.lean
lemma inter_biUnion (t : Finset β) (s : Finset α) (f : α → Finset β) :
    t ∩ s.biUnion f = s.biUnion fun x ↦ t ∩ f x
-- Mathlib/RingTheory/Ideal/Colon.lean
theorem mem_colon {r} : r ∈ N.colon P ↔ ∀ p ∈ P, r • p ∈ N
-- Mathlib/Analysis/Calculus/Deriv/Pow.lean
theorem differentiableWithinAt_pow :
    DifferentiableWithinAt 𝕜 (fun x : 𝕜 => x ^ n) s x
-- Mathlib/CategoryTheory/Limits/Shapes/ZeroMorphisms.lean
@[simp]
theorem idZeroEquivIsoZero_apply_hom (X : C) (h : 𝟙 X = 0) : ((idZeroEquivIsoZero X) h).hom = 0
-- Mathlib/Data/Finmap.lean
@[simp]
theorem lookup_union_left {a} {s₁ s₂ : Finmap β} : a ∈ s₁ → lookup a (s₁ ∪ s₂) = lookup a s₁
-- .lake/packages/lean4/src/lean/Init/Data/List/Lemmas.lean
@[simp] theorem findSome?_cons_of_isSome (l) (h : (f a).isSome) : findSome? f (a :: l) = f a
-- Mathlib/RingTheory/Valuation/ValuationSubring.lean
/-- A valuation subring of a field `K` is a subring `A` such that for every `x : K`,
either `x ∈ A` or `x⁻¹ ∈ A`. -/
structure ValuationSubring extends Subring K where
  mem_or_inv_mem' : ∀ x : K, x ∈ carrier ∨ x⁻¹ ∈ carrier
-- .lake/packages/lean4/src/lean/Init/Prelude.lean
theorem Nat.eq_of_beq_eq_true : {n m : Nat} → Eq (beq n m) true → Eq n m
-- Mathlib/RingTheory/DedekindDomain/Ideal.lean
/-- Nonzero fractional ideals in a Dedekind domain are units.

This is also available as `_root_.mul_inv_cancel`, using the
`Semifield` instance defined below.
-/
protected theorem mul_inv_cancel [IsDedekindDomain A] {I : FractionalIdeal A⁰ K} (hne : I ≠ 0) :
    I * I⁻¹ = 1
-- Mathlib/MeasureTheory/Integral/SetToL1.lean
theorem setToL1_eq_setToL1SCLM (hT : DominatedFinMeasAdditive μ T C) (f : α →₁ₛ[μ] E) :
    setToL1 hT f = setToL1SCLM α E μ hT f
-- Mathlib/Algebra/Order/GroupWithZero/Unbundled.lean
/-- Assumes left covariance. -/
theorem Left.mul_pos [PosMulStrictMono α] (ha : 0 < a) (hb : 0 < b) : 0 < a * b
-- Mathlib/Algebra/Lie/Killing.lean
lemma ideal_eq_bot_of_isLieAbelian [IsDomain R] [IsPrincipalIdealRing R]
    (I : LieIdeal R L) [IsLieAbelian I] : I = ⊥
-- Mathlib/Geometry/Euclidean/Angle/Oriented/Basic.lean
/-- Negating the orientation negates the value of `oangle`. -/
theorem oangle_neg_orientation_eq_neg (x y : V) : (-o).oangle x y = -o.oangle x y
-- Mathlib/Logic/Equiv/Basic.lean
@[simp]
theorem subtypeQuotientEquivQuotientSubtype_mk (p₁ : α → Prop)
    [s₁ : Setoid α] [s₂ : Setoid (Subtype p₁)] (p₂ : Quotient s₁ → Prop) (hp₂ : ∀ a, p₁ a ↔ p₂ ⟦a⟧)
    (h : ∀ x y : Subtype p₁, @Setoid.r _ s₂ x y ↔ (x : α) ≈ y)
    (x hx) : subtypeQuotientEquivQuotientSubtype p₁ p₂ hp₂ h ⟨⟦x⟧, hx⟩ = ⟦⟨x, (hp₂ _).2 hx⟩⟧
-- Mathlib/RingTheory/NonUnitalSubring/Basic.lean
theorem closure_sUnion (s : Set (Set R)) : closure (⋃₀ s) = ⨆ t ∈ s, closure t
-- Mathlib/LinearAlgebra/CliffordAlgebra/Even.lean
/-- Two algebra morphisms from the even subalgebra are equal if they agree on pairs of generators.

See note [partially-applied ext lemmas]. -/
@[ext high]
theorem even.algHom_ext ⦃f g : even Q →ₐ[R] A⦄ (h : (even.ι Q).compr₂ f = (even.ι Q).compr₂ g) :
    f = g
-- Mathlib/GroupTheory/OrderOfElement.lean
@[to_additive (attr := norm_cast)] -- Porting note (#10618): simp can prove this (so removed simp)
lemma orderOf_coe (a : H) : orderOf (a : G) = orderOf a
-- Mathlib/Topology/EMetricSpace/Basic.lean
@[gcongr]
theorem ball_subset_ball (h : ε₁ ≤ ε₂) : ball x ε₁ ⊆ ball x ε₂
-- Mathlib/Order/Filter/AtTopBot.lean
theorem disjoint_atBot_principal_Ici [Preorder α] [NoMinOrder α] (x : α) :
    Disjoint atBot (𝓟 (Ici x))
-- Mathlib/RingTheory/Polynomial/Hermite/Basic.lean
@[simp]
theorem hermite_zero : hermite 0 = C 1
-- Mathlib/Algebra/Group/UniqueProds.lean
/-- Let `G` be a Type with addition. `TwoUniqueSums G` asserts that any two non-empty
finite subsets of `G`, at least one of which is not a singleton, possesses at least two pairs
of elements satisfying the `UniqueAdd` property. -/
class TwoUniqueSums (G) [Add G] : Prop where
/-- For `A B` two finite sets whose product has cardinality at least 2,
  we can find at least two unique pairs. -/
  uniqueAdd_of_one_lt_card : ∀ {A B : Finset G}, 1 < A.card * B.card →
    ∃ p1 ∈ A ×ˢ B, ∃ p2 ∈ A ×ˢ B, p1 ≠ p2 ∧ UniqueAdd A B p1.1 p1.2 ∧ UniqueAdd A B p2.1 p2.2
-- Mathlib/CategoryTheory/Sites/Sieves.lean
theorem pullback_monotone (f : Y ⟶ X) : Monotone (Sieve.pullback f)
-- Mathlib/Computability/Partrec.lean
theorem unpaired' {f : ℕ → ℕ →. ℕ} : Nat.Partrec (Nat.unpaired f) ↔ Partrec₂ f
-- Mathlib/LinearAlgebra/PiTensorProduct.lean
theorem lift_comp_map (h : MultilinearMap R t E) :
    lift h ∘ₗ map f = lift (h.compLinearMap f)
-- Mathlib/Topology/Separation.lean
protected theorem Inducing.regularSpace [TopologicalSpace Y] {f : Y → X} (hf : Inducing f) :
    RegularSpace Y
-- Mathlib/Algebra/Group/Subgroup/Basic.lean
/-- The top subgroup is isomorphic to the group.

This is the group version of `Submonoid.topEquiv`. -/
@[to_additive (attr := simps!)
      "The top additive subgroup is isomorphic to the additive group.

      This is the additive group version of `AddSubmonoid.topEquiv`."]
def topEquiv : (⊤ : Subgroup G) ≃* G
-- Mathlib/Analysis/Normed/Group/Basic.lean
/-- A seminormed group is a group endowed with a norm for which `dist x y = ‖x / y‖` defines a
pseudometric space structure. -/
@[to_additive]
class SeminormedGroup (E : Type*) extends Norm E, Group E, PseudoMetricSpace E where
  dist := fun x y => ‖x / y‖
  /-- The distance function is induced by the norm. -/
  dist_eq : ∀ x y, dist x y = ‖x / y‖ := by aesop
-- Mathlib/Algebra/Homology/ShortComplex/LeftHomology.lean
/-- The left homology map data associated to the zero morphism between two short complexes. -/
@[simps]
def zero (h₁ : S₁.LeftHomologyData) (h₂ : S₂.LeftHomologyData) :
    LeftHomologyMapData 0 h₁ h₂
-- Mathlib/Algebra/Homology/ShortComplex/LeftHomology.lean
@[ext]
lemma cycles_ext {A : C} (f₁ f₂ : A ⟶ S.cycles) (h : f₁ ≫ S.iCycles = f₂ ≫ S.iCycles) :
    f₁ = f₂
-- .lake/packages/batteries/Batteries/Data/UInt.lean
@[ext] theorem UInt16.ext : {x y : UInt16} → x.toNat = y.toNat → x = y
-- Mathlib/Data/Num/Lemmas.lean
@[simp]
theorem ofZNum_toNat : ∀ n : ZNum, (ofZNum n : ℕ) = Int.toNat n
-- Mathlib/SetTheory/Game/Nim.lean
theorem nim_add_nim_equiv {n m : ℕ} : nim n + nim m ≈ nim (n ^^^ m)