ruc-ai4math/mathlib_handler_benchmark_410 huggingface dataset:
-- Mathlib/Data/Ordmap/Ordset.lean
theorem balance_sz_dual {l r}
    (H : (∃ l', Raised (@size α l) l' ∧ BalancedSz l' (@size α r)) ∨
        ∃ r', Raised r' (size r) ∧ BalancedSz (size l) r') :
    (∃ l', Raised l' (size (dual r)) ∧ BalancedSz l' (size (dual l))) ∨
      ∃ r', Raised (size (dual l)) r' ∧ BalancedSz (size (dual r)) r'
-- Mathlib/Computability/AkraBazzi/AkraBazzi.lean
lemma eventually_deriv_rpow_p_mul_one_sub_smoothingFn (p : ℝ) :
    deriv (fun z => z ^ p * (1 - ε z))
      =ᶠ[atTop] fun z => p * z ^ (p-1) * (1 - ε z) + z ^ (p-1) / (log z ^ 2)
-- Mathlib/Analysis/InnerProductSpace/Calculus.lean
theorem ContDiff.inner (hf : ContDiff ℝ n f) (hg : ContDiff ℝ n g) :
    ContDiff ℝ n fun x => ⟪f x, g x⟫
-- Mathlib/CategoryTheory/Limits/Shapes/Products.lean
lemma Pi.map'_eq {f : α → C} {g : β → C} [HasProduct f] [HasProduct g] {p p' : β → α}
    {q : ∀ (b : β), f (p b) ⟶ g b} {q' : ∀ (b : β), f (p' b) ⟶ g b} (hp : p = p')
    (hq : ∀ (b : β), eqToHom (hp ▸ rfl) ≫ q b = q' b) : Pi.map' p q = Pi.map' p' q'
-- Mathlib/Analysis/Analytic/Inverse.lean
@[simp]
theorem leftInv_coeff_one (p : FormalMultilinearSeries 𝕜 E F) (i : E ≃L[𝕜] F) :
    p.leftInv i 1 = (continuousMultilinearCurryFin1 𝕜 F E).symm i.symm
-- .lake/packages/lean4/src/lean/Init/Data/Int/Lemmas.lean
theorem mul_eq_mul_left_iff {a b c : Int} (h : c ≠ 0) : c * a = c * b ↔ a = b
-- Mathlib/Data/ENNReal/Basic.lean
@[simp] theorem zero_toReal : (0 : ℝ≥0∞).toReal = 0
-- Mathlib/Data/Seq/WSeq.lean
@[simp]
theorem append_assoc (s t u : WSeq α) : append (append s t) u = append s (append t u)
-- Mathlib/MeasureTheory/MeasurableSpace/Embedding.lean
protected theorem bijective (e : α ≃ᵐ β) : Bijective e
-- Mathlib/NumberTheory/Cyclotomic/Three.lean
/-- If a unit `u` is congruent to an integer modulo `λ ^ 2`, then `u = 1` or `u = -1`.

This is a special case of the so-called *Kummer's lemma*. -/
theorem eq_one_or_neg_one_of_unit_of_congruent (hcong : ∃ n : ℤ, λ ^ 2 ∣ (u - n : 𝓞 K)) :
    u = 1 ∨ u = -1
-- Mathlib/CategoryTheory/Sites/CoverLifting.lean
/-- `G.sheafPushforwardCocontinuous A J K : Sheaf J A ⥤ Sheaf K A` is induced
by the right Kan extension functor `G.op.ran` on presheaves. -/
@[simps! hom inv]
def Functor.sheafPushforwardCocontinuousCompSheafToPresheafIso :
    G.sheafPushforwardCocontinuous A J K ⋙ sheafToPresheaf K A ≅
      sheafToPresheaf J A ⋙ G.op.ran
-- Mathlib/Topology/Algebra/FilterBasis.lean
theorem mul_right (x₀ : R) {U : Set R} (hU : U ∈ B) : ∃ V ∈ B, V ⊆ (fun x ↦ x * x₀) ⁻¹' U
-- Mathlib/RingTheory/Regular/RegularSequence.lean
lemma _root_.LinearEquiv.isWeaklyRegular_congr (e : M ≃ₗ[R] M₂) (rs : List R) :
    IsWeaklyRegular M rs ↔ IsWeaklyRegular M₂ rs
-- Mathlib/CategoryTheory/Functor/Const.lean
/-- The canonical isomorphism
`F ⋙ Functor.const J ≅ Functor.const F ⋙ (whiskeringRight J _ _).obj L`. -/
@[simps!]
def compConstIso (F : C ⥤ D) :
    F ⋙ Functor.const J ≅ Functor.const J ⋙ (whiskeringRight J C D).obj F
-- .lake/packages/lean4/src/lean/Init/Data/Array/Lemmas.lean
theorem extract_loop_eq (as bs : Array α) (size start : Nat) (h : start + size ≤ as.size) :
  extract.loop as size start bs = bs ++ as.extract start (start + size)
-- Mathlib/Analysis/Asymptotics/Asymptotics.lean
theorem isLittleO_iff_nat_mul_le : f =o[l] g' ↔ ∀ n : ℕ, ∀ᶠ x in l, ↑n * ‖f x‖ ≤ ‖g' x‖
-- Mathlib/Data/List/Basic.lean
@[simp]
theorem attach_eq_nil (l : List α) : l.attach = [] ↔ l = []
-- Mathlib/Algebra/BigOperators/Associated.lean
theorem Multiset.prod_primes_dvd [CancelCommMonoidWithZero α]
    [∀ a : α, DecidablePred (Associated a)] {s : Multiset α} (n : α) (h : ∀ a ∈ s, Prime a)
    (div : ∀ a ∈ s, a ∣ n) (uniq : ∀ a, s.countP (Associated a) ≤ 1) : s.prod ∣ n
-- Mathlib/Algebra/GCDMonoid/Basic.lean
theorem normalize_associated_iff {x y : α} : Associated (normalize x) y ↔ Associated x y
-- Mathlib/Data/Real/Hyperreal.lean
theorem abs_lt_real_iff_infinitesimal {x : ℝ*} : Infinitesimal x ↔ ∀ r : ℝ, r ≠ 0 → |x| < |↑r|
-- Mathlib/Data/Complex/Basic.lean
@[simp]
theorem normSq_ofNat (n : ℕ) [n.AtLeastTwo] :
    normSq (no_index (OfNat.ofNat n : ℂ)) = OfNat.ofNat n * OfNat.ofNat n
-- Mathlib/Data/Set/Pointwise/SMul.lean
@[simp high]
theorem singleton_vsub_singleton : ({b} : Set β) -ᵥ {c} = {b -ᵥ c}
-- Mathlib/Analysis/Convex/Basic.lean
theorem Convex.sub (hs : Convex 𝕜 s) (ht : Convex 𝕜 t) : Convex 𝕜 (s - t)
-- Mathlib/Algebra/Group/Semiconj/Basic.lean
@[to_additive (attr := simp)]
theorem inv_inv_symm_iff : SemiconjBy a⁻¹ x⁻¹ y⁻¹ ↔ SemiconjBy a y x
-- Mathlib/CategoryTheory/Preadditive/Basic.lean
/-- A preadditive category has a coequalizer for `f` and `g` if it has a cokernel for `f - g`. -/
theorem hasCoequalizer_of_hasCokernel [HasCokernel (f - g)] : HasCoequalizer f g
-- Mathlib/Topology/Algebra/InfiniteSum/Basic.lean
/-- Version of `hasProd_ite_div_hasProd` for `CommMonoid` rather than `CommGroup`.
Rather than showing that the `ite` expression has a specific product in terms of `HasProd`, it gives
a relationship between the products of `f` and `ite (n = b) 0 (f n)` given that both exist. -/
@[to_additive "Version of `hasSum_ite_sub_hasSum` for `AddCommMonoid` rather than `AddCommGroup`.
Rather than showing that the `ite` expression has a specific sum in terms of `HasSum`,
it gives a relationship between the sums of `f` and `ite (n = b) 0 (f n)` given that both exist."]
theorem eq_mul_of_hasProd_ite {α β : Type*} [TopologicalSpace α] [CommMonoid α] [T2Space α]
    [ContinuousMul α] [DecidableEq β] {f : β → α} {a : α} (hf : HasProd f a) (b : β) (a' : α)
    (hf' : HasProd (fun n ↦ ite (n = b) 1 (f n)) a') : a = a' * f b
-- Mathlib/Algebra/MvPolynomial/Variables.lean
theorem vars_eq_support_biUnion_support [DecidableEq σ] :
    p.vars = p.support.biUnion Finsupp.support
-- Mathlib/CategoryTheory/Subobject/MonoOver.lean
/-- Isomorphic objects have equivalent `MonoOver` categories.
-/
@[simps]
def mapIso {A B : C} (e : A ≅ B) : MonoOver A ≌ MonoOver B
-- Mathlib/AlgebraicGeometry/Cover/Open.lean
/-- We construct an open cover from another, by providing the needed fields and showing that the
provided fields are isomorphic with the original open cover. -/
@[simps J obj map]
def OpenCover.copy {X : Scheme.{u}} (𝒰 : OpenCover X) (J : Type*) (obj : J → Scheme)
    (map : ∀ i, obj i ⟶ X) (e₁ : J ≃ 𝒰.J) (e₂ : ∀ i, obj i ≅ 𝒰.obj (e₁ i))
    (e₂ : ∀ i, map i = (e₂ i).hom ≫ 𝒰.map (e₁ i)) : OpenCover X
-- Mathlib/GroupTheory/Perm/Cycle/Type.lean
@[simp] -- Porting note: new attr
theorem lcm_cycleType (σ : Perm α) : σ.cycleType.lcm = orderOf σ
-- Mathlib/Order/BooleanAlgebra.lean
theorem inf_sdiff : (x ⊓ y) \ z = x \ z ⊓ y \ z
-- .lake/packages/lean4/src/lean/Init/Data/Nat/Basic.lean
protected theorem add_le_add_right {n m : Nat} (h : n ≤ m) (k : Nat) : n + k ≤ m + k
-- Mathlib/Algebra/Homology/ShortComplex/Homology.lean
lemma congr_left_φH {γ₁ γ₂ : HomologyMapData φ h₁ h₂} (eq : γ₁ = γ₂) :
    γ₁.left.φH = γ₂.left.φH
-- Mathlib/Data/NNReal/Basic.lean
theorem mul_eq_mul_left {a b c : ℝ≥0} (h : a ≠ 0) : a * b = a * c ↔ b = c
-- Mathlib/CategoryTheory/Comma/Presheaf.lean
@[simp]
lemma map₁_comp {G H : (CostructuredArrow yoneda A)ᵒᵖ ⥤ Type v} (η : F ⟶ G) (μ : G ⟶ H) :
    YonedaCollection.map₁ (η ≫ μ) (X := X) =
      YonedaCollection.map₁ μ (X := X) ∘ YonedaCollection.map₁ η (X := X)
-- Mathlib/Combinatorics/Colex.lean
lemma toColex_le_toColex :
    toColex s ≤ toColex t ↔ ∀ ⦃a⦄, a ∈ s → a ∉ t → ∃ b, b ∈ t ∧ b ∉ s ∧ a ≤ b
-- Mathlib/Data/Set/NAry.lean
/-- Symmetric statement to `Set.image_image2_right_anticomm`. -/
theorem image_image2_antidistrib_right {g : γ → δ} {f' : β → α' → δ} {g' : α → α'}
    (h_antidistrib : ∀ a b, g (f a b) = f' b (g' a)) :
    (image2 f s t).image g = image2 f' t (s.image g')
-- Mathlib/Analysis/Calculus/FDeriv/Prod.lean
@[fun_prop]
theorem differentiableWithinAt_pi'' (hφ : ∀ i, DifferentiableWithinAt 𝕜 (fun x => Φ x i) s x) :
    DifferentiableWithinAt 𝕜 Φ s x
-- Mathlib/CategoryTheory/Subobject/Basic.lean
@[simp]
theorem mk_arrow (P : Subobject X) : mk P.arrow = P
-- Mathlib/Geometry/Euclidean/Inversion/Calculus.lean
protected theorem Differentiable.inversion (hc : Differentiable ℝ c)
    (hR : Differentiable ℝ R) (hx : Differentiable ℝ x) (hne : ∀ a, x a ≠ c a) :
    Differentiable ℝ (fun a ↦ inversion (c a) (R a) (x a))
-- Mathlib/Algebra/Group/Prod.lean
@[to_additive prod_comp_prodMap]
theorem prod_comp_prodMap (f : P →ₙ* M) (g : P →ₙ* N) (f' : M →ₙ* M') (g' : N →ₙ* N') :
    (f'.prodMap g').comp (f.prod g) = (f'.comp f).prod (g'.comp g)
-- Mathlib/Algebra/Order/Monoid/Unbundled/Basic.lean
/-- The product of an antitone function and a strictly antitone function is strictly antitone. -/
@[to_additive add_strictAnti "The sum of an antitone function and a strictly antitone function is
strictly antitone."]
theorem Antitone.mul_strictAnti' [CovariantClass α α (· * ·) (· < ·)]
    [CovariantClass α α (swap (· * ·)) (· ≤ ·)] {f g : β → α} (hf : Antitone f)
    (hg : StrictAnti g) :
    StrictAnti fun x => f x * g x
-- Mathlib/Geometry/Manifold/VectorBundle/SmoothSection.lean
@[ext]
theorem ext (h : ∀ x, s x = t x) : s = t
-- Mathlib/Analysis/Complex/Circle.lean
@[simp]
theorem expMapCircle_apply (t : ℝ) : ↑(expMapCircle t) = Complex.exp (t * Complex.I)
-- Mathlib/Topology/ContinuousOn.lean
theorem ite_inter_closure_compl_eq_of_inter_frontier_eq {s s' t : Set α}
    (ht : s ∩ frontier t = s' ∩ frontier t) : t.ite s s' ∩ closure tᶜ = s' ∩ closure tᶜ
-- Mathlib/AlgebraicGeometry/PrimeSpectrum/Basic.lean
theorem zeroLocus_vanishingIdeal_eq_closure (t : Set (PrimeSpectrum R)) :
    zeroLocus (vanishingIdeal t : Set R) = closure t
-- Mathlib/Algebra/Group/Subgroup/Basic.lean
theorem Normal.of_map_subtype {K : Subgroup G} {L : Subgroup K}
    (n : (Subgroup.map K.subtype L).Normal) : L.Normal
-- Mathlib/Analysis/InnerProductSpace/Basic.lean
protected theorem Continuous.inner {α : Type*} [TopologicalSpace α] {f g : α → Completion E}
    (hf : Continuous f) (hg : Continuous g) : Continuous (fun x : α => inner (f x) (g x) : α → 𝕜)
-- Mathlib/SetTheory/Ordinal/Arithmetic.lean
@[simp]
theorem mod_mod (a b : Ordinal) : a % b % b = a % b
-- Mathlib/RingTheory/FractionalIdeal/Operations.lean
theorem mem_singleton_mul {x y : P} {I : FractionalIdeal S P} :
    y ∈ spanSingleton S x * I ↔ ∃ y' ∈ I, y = x * y'
-- Mathlib/Data/Sym/Sym2.lean
theorem other_invol' [DecidableEq α] {a : α} {z : Sym2 α} (ha : a ∈ z) (hb : Mem.other' ha ∈ z) :
    Mem.other' hb = a
-- Mathlib/CategoryTheory/Monoidal/Opposite.lean
/-- The equivalence between `C` and its monoidal opposite's monoidal opposite. -/
@[simps!] def MonoidalOpposite.mopMopEquivalence : Cᴹᵒᵖᴹᵒᵖ ≌ C
-- Mathlib/Algebra/Order/Monoid/Unbundled/Defs.lean
theorem covariant_lt_iff_contravariant_le [LinearOrder N] :
    Covariant M N μ (· < ·) ↔ Contravariant M N μ (· ≤ ·)
-- Mathlib/GroupTheory/Finiteness.lean
theorem Submonoid.fg_iff_add_fg (P : Submonoid M) : P.FG ↔ P.toAddSubmonoid.FG
-- Mathlib/Topology/Algebra/Group/Basic.lean
@[to_additive]
protected theorem Specializes.zpow {G : Type*} [DivInvMonoid G] [TopologicalSpace G]
    [ContinuousMul G] [ContinuousInv G] {x y : G} (h : x ⤳ y) : ∀ m : ℤ, (x ^ m) ⤳ (y ^ m)
-- Mathlib/Topology/DerivedSet.lean
/-- In a `T1Space`, the `derivedSet` of the closure of a set is equal to the derived set of the
set itself.

Note: this doesn't hold in a space with the indiscrete topology. For example, if `X` is a type with
two elements, `x` and `y`, and `A := {x}`, then `closure A = Set.univ` and `derivedSet A = {y}`,
but `derivedSet Set.univ = Set.univ`. -/
lemma derivedSet_closure [T1Space X] (A : Set X) : derivedSet (closure A) = derivedSet A
-- Mathlib/Algebra/Lie/SkewAdjoint.lean
@[simp]
theorem skewAdjointMatricesLieSubalgebraEquivTranspose_apply {m : Type w} [DecidableEq m]
    [Fintype m] (e : Matrix n n R ≃ₐ[R] Matrix m m R) (h : ∀ A, (e A)ᵀ = e Aᵀ)
    (A : skewAdjointMatricesLieSubalgebra J) :
    (skewAdjointMatricesLieSubalgebraEquivTranspose J e h A : Matrix m m R) = e A
-- Mathlib/Algebra/Homology/DerivedCategory/Ext.lean
@[simp]
lemma comp_hom {a b : ℕ} (α : Ext X Y a) (β : Ext Y Z b) {c : ℕ} (h : a + b = c) :
    (α.comp β h).hom = α.hom.comp β.hom (by omega)
-- Mathlib/RingTheory/FiniteType.lean
/-- An element of `MonoidAlgebra R M` is in the subalgebra generated by its support. -/
theorem mem_adjoin_support (f : MonoidAlgebra R M) : f ∈ adjoin R (of R M '' f.support)
-- Mathlib/Computability/Primrec.lean
/-- To show a function `f : α → ℕ` is primitive recursive, it is enough to show that the function
  is bounded by a primitive recursive function and that its graph is primitive recursive -/
theorem of_graph {f : α → ℕ} (h₁ : PrimrecBounded f)
    (h₂ : PrimrecRel fun a b => f a = b) : Primrec f
-- Mathlib/Order/LiminfLimsup.lean
theorem iInf_le_liminf {f : Filter β} {u : β → α} : ⨅ n, u n ≤ liminf u f
-- Mathlib/Algebra/Order/GroupWithZero/Unbundled.lean
theorem PosMulMono.toPosMulReflectLT [PosMulMono α] : PosMulReflectLT α
-- Mathlib/GroupTheory/MonoidLocalization/Basic.lean
@[to_additive]
theorem sec_spec {f : LocalizationMap S N} (z : N) :
    z * f.toMap (f.sec z).2 = f.toMap (f.sec z).1
-- .lake/packages/lean4/src/lean/Init/Data/Int/Order.lean
theorem natAbs_eq : ∀ (a : Int), a = natAbs a ∨ a = -↑(natAbs a)
-- Mathlib/Analysis/SpecialFunctions/Arsinh.lean
theorem HasFDerivAt.arsinh (hf : HasFDerivAt f f' a) :
    HasFDerivAt (fun x => arsinh (f x)) ((√(1 + f a ^ 2))⁻¹ • f') a
-- Mathlib/Topology/MetricSpace/Pseudo/Defs.lean
theorem eventually_nhds_iff {p : α → Prop} :
    (∀ᶠ y in 𝓝 x, p y) ↔ ∃ ε > 0, ∀ ⦃y⦄, dist y x < ε → p y
-- .lake/packages/lean4/src/lean/Init/Data/BitVec/Lemmas.lean
@[simp] theorem getMsb_zero : (0#w).getMsb i = false
-- Mathlib/Geometry/Manifold/Instances/UnitsOfNormedAlgebra.lean
/-- For a complete normed ring `R`, the embedding of the units `Rˣ` into `R` is a smooth map between
manifolds. -/
lemma contMDiff_val {m : ℕ∞} : ContMDiff 𝓘(𝕜, R) 𝓘(𝕜, R) m (val : Rˣ → R)
-- Mathlib/Order/CompleteLattice.lean
theorem Antitone.le_map_iInf₂ [CompleteLattice β] {f : α → β} (hf : Antitone f) (s : ∀ i, κ i → α) :
    ⨆ (i) (j), f (s i j) ≤ f (⨅ (i) (j), s i j)
-- Mathlib/Algebra/Periodic.lean
theorem Antiperiodic.mul_const_inv [DivisionSemiring α] [Neg β] (h : Antiperiodic f c) {a : α}
    (ha : a ≠ 0) : Antiperiodic (fun x => f (x * a⁻¹)) (c * a)
-- Mathlib/Topology/Category/Profinite/Nobeling.lean
theorem contained_proj (o : Ordinal) : contained (π C (ord I · < o)) o
-- Mathlib/CategoryTheory/MorphismProperty/Basic.lean
theorem unop_op (P : MorphismProperty C) : P.op.unop = P
-- Mathlib/Algebra/Order/ToIntervalMod.lean
theorem iUnion_Ico_zsmul : ⋃ n : ℤ, Ico (n • p) ((n + 1) • p) = univ
-- Mathlib/Data/Nat/Pairing.lean
theorem iUnion_unpair_prod {α β} {s : ℕ → Set α} {t : ℕ → Set β} :
    ⋃ n : ℕ, s n.unpair.fst ×ˢ t n.unpair.snd = (⋃ n, s n) ×ˢ ⋃ n, t n
-- Mathlib/Algebra/Order/Module/Defs.lean
@[gcongr] lemma smul_le_smul_of_nonneg_left [PosSMulMono α β] (hb : b₁ ≤ b₂) (ha : 0 ≤ a) :
    a • b₁ ≤ a • b₂
-- Mathlib/LinearAlgebra/BilinearMap.lean
theorem domRestrict₁₂_apply (f : M →ₛₗ[ρ₁₂] N →ₛₗ[σ₁₂] P) (p : Submodule R M) (q : Submodule S N)
    (x : p) (y : q) : f.domRestrict₁₂ p q x y = f x y
-- Mathlib/Algebra/Category/ModuleCat/Differentials/Presheaf.lean
/-- The postcomposition of a derivation by a morphism of presheaves of modules. -/
@[simps! d_apply]
def postcomp (f : M ⟶ N) : N.Derivation φ
-- Mathlib/InformationTheory/Hamming.lean
/-- Corresponds to `norm_zero`. -/
@[simp]
theorem hammingNorm_zero : hammingNorm (0 : ∀ i, β i) = 0
-- Mathlib/MeasureTheory/Measure/MeasureSpace.lean
lemma map_symm (e : β ≃ᵐ α) : μ.map e.symm = μ.comap e
-- Mathlib/Data/List/FinRange.lean
theorem finRange_succ_eq_map (n : ℕ) : finRange n.succ = 0 :: (finRange n).map Fin.succ
-- Mathlib/Algebra/Polynomial/Degree/Definitions.lean
theorem leadingCoeff_add_of_degree_lt' (h : degree q < degree p) :
    leadingCoeff (p + q) = leadingCoeff p
-- Mathlib/Order/RelClasses.lean
/-- Inducts on a well-founded `<` relation. -/
theorem induction {C : α → Prop} : ∀ a, (∀ x, (∀ y, y < x → C y) → C x) → C a
-- Mathlib/AlgebraicGeometry/Pullbacks.lean
@[simp, reassoc]
theorem t'_snd_fst_snd (i j k : 𝒰.J) :
    t' 𝒰 f g i j k ≫ pullback.snd _ _ ≫ pullback.fst _ _ ≫ pullback.snd _ _ =
      pullback.fst _ _ ≫ pullback.fst _ _ ≫ pullback.snd _ _
-- .lake/packages/lean4/src/lean/Init/SimpLemmas.lean
@[simp] theorem Bool.not_beq_true  (b : Bool) : (!(b == true)) = (b == false)
-- Mathlib/Analysis/Calculus/ContDiff/Defs.lean
theorem ContDiffWithinAt.contDiffOn' {m : ℕ} (hm : (m : ℕ∞) ≤ n)
    (h : ContDiffWithinAt 𝕜 n f s x) :
    ∃ u, IsOpen u ∧ x ∈ u ∧ ContDiffOn 𝕜 m f (insert x s ∩ u)
-- Mathlib/Topology/PartialHomeomorph.lean
/-- Precompose a partial homeomorphism with a homeomorphism.
We modify the source and target to have better definitional behavior. -/
@[simps! (config := .asFn)]
def transPartialHomeomorph (e : X ≃ₜ Y) (f' : PartialHomeomorph Y Z) : PartialHomeomorph X Z
-- Mathlib/Data/Fin/Basic.lean
@[norm_cast, simp]
theorem coe_eq_castSucc {a : Fin n} : (a : Fin (n + 1)) = castSucc a
-- Mathlib/Algebra/Star/Order.lean
lemma star_lt_iff {x y : R} : star x < y ↔ x < star y
-- Mathlib/Algebra/Group/Submonoid/Operations.lean
@[to_additive (attr := simp)]
theorem mk_mul_mk (x y : M) (hx : x ∈ S) (hy : y ∈ S) :
    (⟨x, hx⟩ : S) * ⟨y, hy⟩ = ⟨x * y, S.mul_mem hx hy⟩
-- Mathlib/Topology/PartitionOfUnity.lean
theorem mem_fintsupport_iff (i : ι) : i ∈ ρ.fintsupport x₀ ↔ x₀ ∈ tsupport (ρ i)
-- Mathlib/Topology/VectorBundle/Hom.lean
theorem continuousLinearMap_apply (p : TotalSpace (F₁ →SL[σ] F₂) fun x => E₁ x →SL[σ] E₂ x) :
    (continuousLinearMap σ e₁ e₂) p =
      ⟨p.1, .comp (e₂.continuousLinearMapAt 𝕜₂ p.1) (p.2.comp (e₁.symmL 𝕜₁ p.1))⟩
-- Mathlib/Dynamics/OmegaLimit.lean
theorem omegaLimit_def : ω f ϕ s = ⋂ u ∈ f, closure (image2 ϕ u s)
-- Mathlib/Algebra/Order/Interval/Set/Monoid.lean
@[simp]
theorem image_const_add_Ioc : (fun x => a + x) '' Ioc b c = Ioc (a + b) (a + c)
-- Mathlib/Analysis/SpecialFunctions/Trigonometric/Angle.lean
@[simp]
theorem tan_add_pi (θ : Angle) : tan (θ + π) = tan θ
-- Mathlib/Topology/Semicontinuous.lean
theorem UpperSemicontinuousWithinAt.mono (h : UpperSemicontinuousWithinAt f s x) (hst : t ⊆ s) :
    UpperSemicontinuousWithinAt f t x
-- .lake/packages/lean4/src/lean/Init/Data/Array/Lemmas.lean
theorem size_append (as bs : Array α) : (as ++ bs).size = as.size + bs.size
-- Mathlib/Analysis/Calculus/Deriv/Comp.lean
/-- The composition `l ∘ f` where `l : F → E` and `f : 𝕜 → F`, has a derivative equal to the
Fréchet derivative of `l` applied to the derivative of `f`. -/
theorem HasFDerivAt.comp_hasDerivAt (hl : HasFDerivAt l l' (f x)) (hf : HasDerivAt f f' x) :
    HasDerivAt (l ∘ f) (l' f') x
-- Mathlib/Algebra/Star/NonUnitalSubalgebra.lean
@[simp]
theorem mem_map {S : NonUnitalStarSubalgebra R A} {f : F} {y : B} :
    y ∈ map f S ↔ ∃ x ∈ S, f x = y
-- Mathlib/Geometry/Manifold/ChartedSpace.lean
/-- A structure groupoid is a set of partial homeomorphisms of a topological space stable under
composition and inverse. They appear in the definition of the smoothness class of a manifold. -/
structure StructureGroupoid (H : Type u) [TopologicalSpace H] where
  /-- Members of the structure groupoid are partial homeomorphisms. -/
  members : Set (PartialHomeomorph H H)
  /-- Structure groupoids are stable under composition. -/
  trans' : ∀ e e' : PartialHomeomorph H H, e ∈ members → e' ∈ members → e ≫ₕ e' ∈ members
  /-- Structure groupoids are stable under inverse. -/
  symm' : ∀ e : PartialHomeomorph H H, e ∈ members → e.symm ∈ members
  /-- The identity morphism lies in the structure groupoid. -/
  id_mem' : PartialHomeomorph.refl H ∈ members
  /-- Let `e` be a partial homeomorphism. If for every `x ∈ e.source`, the restriction of e to some
  open set around `x` lies in the groupoid, then `e` lies in the groupoid. -/
  locality' : ∀ e : PartialHomeomorph H H,
    (∀ x ∈ e.source, ∃ s, IsOpen s ∧ x ∈ s ∧ e.restr s ∈ members) → e ∈ members
  /-- Membership in a structure groupoid respects the equivalence of partial homeomorphisms. -/
  mem_of_eqOnSource' : ∀ e e' : PartialHomeomorph H H, e ∈ members → e' ≈ e → e' ∈ members
-- Mathlib/GroupTheory/Perm/Sign.lean
theorem eq_sign_of_surjective_hom {s : Perm α →* ℤˣ} (hs : Surjective s) : s = sign
-- Mathlib/Data/Set/Image.lean
theorem subset_preimage_univ {s : Set α} : s ⊆ f ⁻¹' univ
-- Mathlib/Data/DFinsupp/Order.lean
@[simp]
theorem single_le_iff {f : Π₀ i, α i} {i : ι} {a : α i} : single i a ≤ f ↔ a ≤ f i
-- Mathlib/LinearAlgebra/AffineSpace/AffineSubspace.lean
theorem span_eq_top_of_surjective {s : Set P₁} (hf : Function.Surjective f)
    (h : affineSpan k s = ⊤) : affineSpan k (f '' s) = ⊤
-- Mathlib/Analysis/SpecialFunctions/Trigonometric/Angle.lean
theorem cos_eq_zero_iff {θ : Angle} : cos θ = 0 ↔ θ = (π / 2 : ℝ) ∨ θ = (-π / 2 : ℝ)
-- Mathlib/Data/Matrix/RowCol.lean
@[simp]
theorem diag_col_mul_row [Mul α] [AddCommMonoid α] [Unique ι] (a b : n → α) :
    diag (col ι a * row ι b) = a * b
-- Mathlib/RingTheory/DiscreteValuationRing/Basic.lean
/-- An integral domain is a DVR iff it's a PID with a unique non-zero prime ideal. -/
theorem iff_pid_with_one_nonzero_prime (R : Type u) [CommRing R] [IsDomain R] :
    DiscreteValuationRing R ↔ IsPrincipalIdealRing R ∧ ∃! P : Ideal R, P ≠ ⊥ ∧ IsPrime P
-- Mathlib/MeasureTheory/Measure/Restrict.lean
theorem ae_eq_restrict_biUnion_finset_iff (s : ι → Set α) (t : Finset ι) (f g : α → δ) :
    f =ᵐ[μ.restrict (⋃ i ∈ t, s i)] g ↔ ∀ i ∈ t, f =ᵐ[μ.restrict (s i)] g
-- Mathlib/Probability/Martingale/OptionalSampling.lean
theorem stoppedValue_ae_eq_restrict_eq (h : Martingale f ℱ μ) (hτ : IsStoppingTime ℱ τ)
    (hτ_le : ∀ x, τ x ≤ n) [SigmaFinite (μ.trim (hτ.measurableSpace_le_of_le hτ_le))] (i : ι) :
    stoppedValue f τ =ᵐ[μ.restrict {x | τ x = i}] μ[f n|hτ.measurableSpace]
-- Mathlib/LinearAlgebra/CliffordAlgebra/Conjugation.lean
/-- Like `Submodule.map_pow` -/
theorem submodule_map_pow_reverse (p : Submodule R (CliffordAlgebra Q)) (n : ℕ) :
    (p ^ n).map (reverse : CliffordAlgebra Q →ₗ[R] CliffordAlgebra Q) =
      p.map (reverse : CliffordAlgebra Q →ₗ[R] CliffordAlgebra Q) ^ n
-- Mathlib/RingTheory/MvPolynomial/Homogeneous.lean
private
lemma exists_eval_ne_zero_of_coeff_finSuccEquiv_ne_zero_aux
    {N : ℕ} {F : MvPolynomial (Fin (Nat.succ N)) R} {n : ℕ} (hF : IsHomogeneous F n)
    (hFn : ((finSuccEquiv R N) F).coeff n ≠ 0) :
    ∃ r, eval r F ≠ 0
-- Mathlib/RingTheory/Binomial.lean
theorem choose_zero_right [NatPowAssoc R] (r : R) : choose r 0 = 1
-- Mathlib/CategoryTheory/Monoidal/Braided/Basic.lean
/-- A lax braided functor between braided monoidal categories is a lax monoidal functor
which preserves the braiding.
-/
structure LaxBraidedFunctor extends LaxMonoidalFunctor C D where
  braided : ∀ X Y : C, μ X Y ≫ map (β_ X Y).hom = (β_ (obj X) (obj Y)).hom ≫ μ Y X := by aesop_cat
-- Mathlib/Data/Bundle.lean
theorem TotalSpace.eta (z : TotalSpace F E) : TotalSpace.mk z.proj z.2 = z
-- Mathlib/Algebra/BigOperators/Associated.lean
theorem prod_mk {p : Multiset α} : (p.map Associates.mk).prod = Associates.mk p.prod
-- Mathlib/Algebra/Star/StarAlgHom.lean
@[simp]
theorem symm_apply_apply (e : A ≃⋆ₐ[R] B) : ∀ x, e.symm (e x) = x
-- Mathlib/Data/Finset/Prod.lean
theorem product_inter [DecidableEq α] [DecidableEq β] : s ×ˢ (t ∩ t') = s ×ˢ t ∩ s ×ˢ t'
-- Mathlib/Algebra/Algebra/Operations.lean
theorem mul_toAddSubmonoid (M N : Submodule R A) :
    (M * N).toAddSubmonoid = M.toAddSubmonoid * N.toAddSubmonoid
-- Mathlib/Algebra/Order/Group/Abs.lean
theorem abs_le : |a| ≤ b ↔ -b ≤ a ∧ a ≤ b
-- Mathlib/MeasureTheory/Group/Arithmetic.lean
@[to_additive (attr := measurability)]
theorem AEMeasurable.const_smul' (hg : AEMeasurable g μ) (c : M) :
    AEMeasurable (fun x => c • g x) μ
-- Mathlib/Analysis/CstarAlgebra/ContinuousFunctionalCalculus/Unital.lean
lemma cfc_const_one : cfc (fun _ : R ↦ 1) a = 1
-- Mathlib/Data/ENNReal/Operations.lean
protected theorem add_lt_add_of_le_of_lt : a ≠ ∞ → a ≤ b → c < d → a + c < b + d
-- Mathlib/Topology/UniformSpace/Basic.lean
theorem uniformContinuousOn_iff_restrict [UniformSpace α] [UniformSpace β] {f : α → β} {s : Set α} :
    UniformContinuousOn f s ↔ UniformContinuous (s.restrict f)
-- Mathlib/Order/Heyting/Basic.lean
@[simp]
theorem fst_sdiff [SDiff α] [SDiff β] (a b : α × β) : (a \ b).1 = a.1 \ b.1