ruc-ai4math/mathlib_handler_benchmark_410 huggingface dataset:
-- Mathlib/RingTheory/MvPolynomial/WeightedHomogeneous.lean
theorem weightedDecomposition.decompose'_eq [DecidableEq M] :
    (weightedDecomposition R w).decompose' = fun φ : MvPolynomial σ R =>
      DirectSum.mk (fun i : M => ↥(weightedHomogeneousSubmodule R w i))
        (Finset.image (weight w) φ.support) fun m =>
          ⟨weightedHomogeneousComponent w m φ, weightedHomogeneousComponent_mem w φ m⟩
-- Mathlib/Algebra/Module/LinearMap/Defs.lean
protected theorem map_sub (x y : M) : f (x - y) = f x - f y
-- .lake/packages/batteries/Batteries/Data/Rat/Lemmas.lean
@[simp, norm_cast] theorem intCast_inj {a b : Int} : (a : Rat) = (b : Rat) ↔ a = b
-- Mathlib/Algebra/AddTorsor.lean
/-- Adding a group element to the point `p` is an injective
function. -/
theorem vadd_right_injective (p : P) : Function.Injective ((· +ᵥ p) : G → P)
-- Mathlib/AlgebraicGeometry/Pullbacks.lean
@[simp, reassoc]
theorem t'_fst_snd (i j k : 𝒰.J) :
    t' 𝒰 f g i j k ≫ pullback.fst _ _ ≫ pullback.snd _ _ =
      pullback.snd _ _ ≫ pullback.snd _ _
-- Mathlib/NumberTheory/LucasLehmer.lean
theorem mersenne_int_pos {p : ℕ} (hp : p ≠ 0) : (0 : ℤ) < 2 ^ p - 1
-- Mathlib/Data/Nat/Digits.lean
theorem head!_digits {b n : ℕ} (h : b ≠ 1) : (Nat.digits b n).head! = n % b
-- Mathlib/LinearAlgebra/Basis.lean
@[simp]
theorem coe_finTwoProd_repr {R : Type*} [Semiring R] (x : R × R) :
    ⇑((Basis.finTwoProd R).repr x) = ![x.fst, x.snd]
-- Mathlib/Tactic/Ring/Basic.lean
theorem natCast_add {a₁ a₂ : ℕ}
    (_ : ((a₁ : ℕ) : R) = b₁) (_ : ((a₂ : ℕ) : R) = b₂) : ((a₁ + a₂ : ℕ) : R) = b₁ + b₂
-- Mathlib/Algebra/GCDMonoid/Basic.lean
@[simp 1100]
theorem normalize_out (a : Associates α) : normalize a.out = a.out
-- Mathlib/Data/Fintype/Card.lean
theorem one_lt_card [h : Nontrivial α] : 1 < Fintype.card α
-- Mathlib/Algebra/Order/Group/Unbundled/Basic.lean
@[to_additive]
theorem lt_inv_iff_mul_lt_one' : a < b⁻¹ ↔ b * a < 1
-- Mathlib/Algebra/Algebra/Subalgebra/Basic.lean
@[simp, norm_cast]
theorem coe_smul [Semiring R'] [SMul R' R] [Module R' A] [IsScalarTower R' R A] (r : R') (x : S) :
    (↑(r • x) : A) = r • (x : A)
-- Mathlib/Data/Matroid/Basic.lean
theorem Basis'.subset (hI : M.Basis' I X) : I ⊆ X
-- Mathlib/Topology/Instances/RealVectorSpace.lean
@[simp]
theorem coe_toRealLinearMap (f : E →+ F) (hf : Continuous f) : ⇑(f.toRealLinearMap hf) = f
-- Mathlib/Topology/OmegaCompletePartialOrder.lean
theorem IsOpen.isUpperSet {s : Set α} (hs : IsOpen α s) : IsUpperSet s
-- .lake/packages/batteries/Batteries/Data/Rat/Lemmas.lean
theorem ofScientific_false_def : Rat.ofScientific m false e = (m * 10 ^ e : Nat)
-- .lake/packages/lean4/src/lean/Init/Data/List/Impl.lean
theorem replicateTR_loop_replicate_eq (a : α) (m n : Nat) :
  replicateTR.loop a n (replicate m a) = replicate (n + m) a
-- Mathlib/RepresentationTheory/Invariants.lean
@[simp]
theorem mem_invariants (v : V) : v ∈ invariants ρ ↔ ∀ g : G, ρ g v = v
-- Mathlib/MeasureTheory/Function/LpSpace.lean
theorem lipschitzWith_pos_part : LipschitzWith 1 fun x : ℝ => max x 0
-- Mathlib/CategoryTheory/Limits/Shapes/BinaryProducts.lean
/-- If `s` is a colimit binary cofan over `X` and `Y`,, then every pair of morphisms `f : X ⟶ W` and
    `g : Y ⟶ W` induces a morphism `l : s.pt ⟶ W` satisfying `s.inl ≫ l = f` and `s.inr ≫ l = g`.
    -/
@[simps]
def BinaryCofan.IsColimit.desc' {W X Y : C} {s : BinaryCofan X Y} (h : IsColimit s) (f : X ⟶ W)
    (g : Y ⟶ W) : { l : s.pt ⟶ W // s.inl ≫ l = f ∧ s.inr ≫ l = g }
-- Mathlib/CategoryTheory/Preadditive/AdditiveFunctor.lean
@[simp]
theorem map_add {X Y : C} {f g : X ⟶ Y} : F.map (f + g) = F.map f + F.map g
-- Mathlib/Topology/UniformSpace/UniformConvergence.lean
/-- A sequence of functions `Fₙ` converges uniformly on a set `s` to a limiting function `f` w.r.t.
filter `p` iff the function `(n, x) ↦ (f x, Fₙ x)` converges along `p ×ˢ 𝓟 s` to the uniformity.
In other words: one knows nothing about the behavior of `x` in this limit besides it being in `s`.
-/
theorem tendstoUniformlyOn_iff_tendsto {F : ι → α → β} {f : α → β} {p : Filter ι} {s : Set α} :
    TendstoUniformlyOn F f p s ↔
    Tendsto (fun q : ι × α => (f q.2, F q.1 q.2)) (p ×ˢ 𝓟 s) (𝓤 β)
-- Mathlib/RingTheory/Adjoin/Basic.lean
theorem mem_adjoin_of_map_mul {s} {x : A} {f : A →ₗ[R] B} (hf : ∀ a₁ a₂, f (a₁ * a₂) = f a₁ * f a₂)
    (h : x ∈ adjoin R s) : f x ∈ adjoin R (f '' (s ∪ {1}))
-- Mathlib/Analysis/Calculus/FDeriv/Mul.lean
/--
Auxiliary lemma for `hasStrictFDerivAt_multiset_prod`.

For `NormedCommRing 𝔸'`, can rewrite as `Multiset` using `Multiset.prod_coe`.
-/
@[fun_prop]
theorem hasStrictFDerivAt_list_prod [DecidableEq ι] [Fintype ι] {l : List ι} {x : ι → 𝔸'} :
    HasStrictFDerivAt (𝕜 := 𝕜) (fun x ↦ (l.map x).prod)
      (l.map fun i ↦ ((l.erase i).map x).prod • proj i).sum x
-- Mathlib/Topology/Algebra/Algebra.lean
/-- If two continuous algebra maps are equal on a set `s`, then they are equal on the closure
of the `Algebra.adjoin` of this set. -/
theorem eqOn_closure_adjoin [T2Space B] {s : Set A} {f g : A →A[R] B} (h : Set.EqOn f g s) :
    Set.EqOn f g (closure (Algebra.adjoin R s : Set A))
-- Mathlib/NumberTheory/Liouville/LiouvilleWith.lean
theorem sub_int (h : LiouvilleWith p x) (m : ℤ) : LiouvilleWith p (x - m)
-- Mathlib/MeasureTheory/Function/L1Space.lean
theorem Integrable.smul [NormedAddCommGroup 𝕜] [SMulZeroClass 𝕜 β] [BoundedSMul 𝕜 β] (c : 𝕜)
    {f : α → β} (hf : Integrable f μ) : Integrable (c • f) μ
-- Mathlib/Topology/Compactification/OnePoint.lean
@[simp, norm_cast]
theorem inseparable_coe {x y : X} : Inseparable (x : OnePoint X) y ↔ Inseparable x y
-- Mathlib/Topology/Instances/Matrix.lean
theorem Matrix.diagonal_tsum [DecidableEq n] [T2Space R] {f : X → n → R} :
    diagonal (∑' x, f x) = ∑' x, diagonal (f x)
-- Mathlib/Data/Fin/Basic.lean
/-- Embedding `i : Fin n` into `Fin (n + 1)` with a hole around `p : Fin (n + 1)`
embeds `i` by `castSucc` when the resulting `i.castSucc < p`. -/
lemma succAbove_of_castSucc_lt (p : Fin (n + 1)) (i : Fin n) (h : castSucc i < p) :
    p.succAbove i = castSucc i
-- Mathlib/Analysis/Calculus/LHopital.lean
theorem lhopital_zero_right_on_Ico (hdf : DifferentiableOn ℝ f (Ioo a b))
    (hcf : ContinuousOn f (Ico a b)) (hcg : ContinuousOn g (Ico a b))
    (hg' : ∀ x ∈ Ioo a b, (deriv g) x ≠ 0) (hfa : f a = 0) (hga : g a = 0)
    (hdiv : Tendsto (fun x => (deriv f) x / (deriv g) x) (𝓝[>] a) l) :
    Tendsto (fun x => f x / g x) (𝓝[>] a) l
-- Mathlib/RingTheory/WittVector/Basic.lean
theorem add : mapFun f (x + y) = mapFun f x + mapFun f y
-- Mathlib/Analysis/NormedSpace/Connected.lean
/-- In a real vector space of dimension `> 1`, any sphere of nonnegative radius is connected. -/
theorem isConnected_sphere (h : 1 < Module.rank ℝ E) (x : E) {r : ℝ} (hr : 0 ≤ r) :
    IsConnected (sphere x r)
-- .lake/packages/batteries/Batteries/Data/UInt.lean
theorem UInt64.toNat_sub (x y : UInt64) :
    (x - y).toNat = (UInt64.size - y.toNat + x.toNat) % UInt64.size
-- Mathlib/MeasureTheory/Constructions/BorelSpace/Real.lean
theorem borel_eq_generateFrom_Iio_rat : borel ℝ = .generateFrom (⋃ a : ℚ, {Iio (a : ℝ)})
-- Mathlib/Analysis/Asymptotics/AsymptoticEquivalent.lean
@[trans]
theorem IsEquivalent.trans {l : Filter α} {u v w : α → β} (huv : u ~[l] v) (hvw : v ~[l] w) :
    u ~[l] w
-- Mathlib/Data/Matrix/Basic.lean
@[simp]
theorem diagonal_add [AddZeroClass α] (d₁ d₂ : n → α) :
    diagonal d₁ + diagonal d₂ = diagonal fun i => d₁ i + d₂ i
-- Mathlib/Algebra/CubicDiscriminant.lean
theorem C_mul_prod_X_sub_C_eq [CommRing S] {w x y z : S} :
    C w * (X - C x) * (X - C y) * (X - C z) =
      toPoly ⟨w, w * -(x + y + z), w * (x * y + x * z + y * z), w * -(x * y * z)⟩
-- Mathlib/LinearAlgebra/AffineSpace/AffineSubspace.lean
/-- A vector lies in the `vectorSpan` of two points if and only if it is a multiple of their
difference. -/
theorem mem_vectorSpan_pair {p₁ p₂ : P} {v : V} :
    v ∈ vectorSpan k ({p₁, p₂} : Set P) ↔ ∃ r : k, r • (p₁ -ᵥ p₂) = v
-- .lake/packages/lean4/src/lean/Init/Core.lean
theorem refl (a : α) : a ≈ a
-- Mathlib/Topology/Compactness/Lindelof.lean
theorem isLindelof_iff_isLindelof_univ : IsLindelof s ↔ IsLindelof (univ : Set s)
-- Mathlib/LinearAlgebra/TensorProduct/RightExactness.lean
/-- Right-exactness of tensor product (`rTensor`) -/
lemma rTensor_mkQ (N : Submodule R M) :
    ker (rTensor Q (N.mkQ)) = range (rTensor Q N.subtype)
-- Mathlib/LinearAlgebra/Basis/VectorSpace.lean
/-- Any linear map `f : p →ₗ[K] V'` defined on a subspace `p` can be extended to the whole
space. -/
theorem LinearMap.exists_extend {p : Submodule K V} (f : p →ₗ[K] V') :
    ∃ g : V →ₗ[K] V', g.comp p.subtype = f
-- Mathlib/Data/List/Rotate.lean
theorem cyclicPermutations_injective : Function.Injective (@cyclicPermutations α)
-- Mathlib/MeasureTheory/OuterMeasure/Basic.lean
@[deprecated measure_mono_null (since := "2024-05-14")]
theorem mono_null (m : OuterMeasure α) {s t} (h : s ⊆ t) (ht : m t = 0) : m s = 0
-- Mathlib/Topology/Algebra/UniformGroup.lean
@[to_additive]
theorem uniformGroup_sInf {us : Set (UniformSpace β)} (h : ∀ u ∈ us, @UniformGroup β u _) :
    @UniformGroup β (sInf us) _
-- Mathlib/LinearAlgebra/Matrix/NonsingularInverse.lean
theorem mulVec_surjective_iff_exists_right_inverse [Finite m] [Fintype n] {A : Matrix m n R} :
    Function.Surjective A.mulVec ↔ ∃ B : Matrix n m R, A * B = 1
-- Mathlib/Algebra/Group/Submonoid/Operations.lean
@[to_additive coe_prod]
theorem coe_prod (s : Submonoid M) (t : Submonoid N) :
    (s.prod t : Set (M × N)) = (s : Set M) ×ˢ (t : Set N)
-- Mathlib/Algebra/Homology/ShortComplex/RightHomology.lean
lemma hasLeftHomology_iff_op (S : ShortComplex C) :
    S.HasLeftHomology ↔ S.op.HasRightHomology
-- Mathlib/Analysis/InnerProductSpace/Basic.lean
@[simp]
theorem LinearMap.isometryOfInner_toLinearMap (f : E →ₗ[𝕜] E') (h) :
    (f.isometryOfInner h).toLinearMap = f
-- Mathlib/Computability/TuringMachine.lean
theorem Tape.map_mk₂ {Γ Γ'} [Inhabited Γ] [Inhabited Γ'] (f : PointedMap Γ Γ') (L R : List Γ) :
    (Tape.mk₂ L R).map f = Tape.mk₂ (L.map f) (R.map f)
-- Mathlib/Algebra/Lie/Weights/Basic.lean
lemma isZero_iff_eq_zero [Nontrivial (weightSpace M (0 : L → R))] {χ : Weight R L M} :
    χ.IsZero ↔ χ = 0
-- Mathlib/Analysis/RCLike/Basic.lean
@[simp, rclike_simps]
theorem I_im' (z : K) : im (I : K) * im z = im z
-- Mathlib/RingTheory/LocalProperties.lean
lemma Module.Finite_of_isLocalization (R S Rₚ Sₚ) [CommSemiring R] [CommRing S] [CommRing Rₚ]
    [CommRing Sₚ] [Algebra R S] [Algebra R Rₚ] [Algebra R Sₚ] [Algebra S Sₚ] [Algebra Rₚ Sₚ]
    [IsScalarTower R S Sₚ] [IsScalarTower R Rₚ Sₚ] (M : Submonoid R) [IsLocalization M Rₚ]
    [IsLocalization (Algebra.algebraMapSubmonoid S M) Sₚ] [hRS : Module.Finite R S] :
    Module.Finite Rₚ Sₚ
-- Mathlib/Analysis/Normed/Group/Constructions.lean
@[to_additive pi_nnnorm_lt_iff]
lemma pi_nnnorm_lt_iff' {r : ℝ≥0} (hr : 0 < r) : ‖x‖₊ < r ↔ ∀ i, ‖x i‖₊ < r
-- Mathlib/Geometry/Manifold/Algebra/LieGroup.lean
@[to_additive]
theorem ContMDiffOn.inv {f : M → G} {s : Set M} (hf : ContMDiffOn I' I n f s) :
    ContMDiffOn I' I n (fun x => (f x)⁻¹) s
-- Mathlib/LinearAlgebra/Alternating/Basic.lean
private theorem alternization_map_eq_zero_of_eq_aux (m : MultilinearMap R (fun _ : ι => M) N')
    (v : ι → M) (i j : ι) (i_ne_j : i ≠ j) (hv : v i = v j) :
    (∑ σ : Perm ι, Equiv.Perm.sign σ • m.domDomCongr σ) v = 0
-- Mathlib/CategoryTheory/Closed/Monoidal.lean
@[simp]
theorem pre_map {A₁ A₂ A₃ : C} [Closed A₁] [Closed A₂] [Closed A₃] (f : A₁ ⟶ A₂) (g : A₂ ⟶ A₃) :
    pre (f ≫ g) = pre g ≫ pre f
-- Mathlib/Algebra/BigOperators/Finsupp.lean
@[to_additive]
theorem prod_sum_index [AddCommMonoid M] [AddCommMonoid N] [CommMonoid P] {f : α →₀ M}
    {g : α → M → β →₀ N} {h : β → N → P} (h_zero : ∀ a, h a 0 = 1)
    (h_add : ∀ a b₁ b₂, h a (b₁ + b₂) = h a b₁ * h a b₂) :
    (f.sum g).prod h = f.prod fun a b => (g a b).prod h
-- Mathlib/RingTheory/Jacobson.lean
lemma Subring.mem_closure_image_of {S T : Type*} [CommRing S] [CommRing T] (g : S →+* T)
    (u : Set S) (x : S) (hx : x ∈ Subring.closure u) : g x ∈ Subring.closure (g '' u)
-- Mathlib/RingTheory/GradedAlgebra/HomogeneousLocalization.lean
@[simp]
theorem deg_smul (c : NumDenSameDeg 𝒜 x) (m : α) : (m • c).deg = c.deg
-- Mathlib/Algebra/MvPolynomial/Monad.lean
@[simp]
theorem join₂_comp_map (f : R →+* MvPolynomial σ S) : join₂.comp (map f) = bind₂ f
-- Mathlib/Algebra/Group/Prod.lean
/-- Four-way commutativity of `Prod`. The name matches `mul_mul_mul_comm`. -/
@[to_additive (attr := simps apply) prodProdProdComm
    "Four-way commutativity of `Prod`.\nThe name matches `mul_mul_mul_comm`"]
def prodProdProdComm : (M × N) × M' × N' ≃* (M × M') × N × N'
-- Mathlib/CategoryTheory/Abelian/ProjectiveResolution.lean
/-- In any abelian category with enough projectives,
`ProjectiveResolution.of Z` constructs an projective resolution of the object `Z`.
-/
irreducible_def of : ProjectiveResolution Z
-- Mathlib/NumberTheory/Padics/PadicIntegers.lean
@[simp]
theorem norm_units (u : ℤ_[p]ˣ) : ‖(u : ℤ_[p])‖ = 1
-- Mathlib/MeasureTheory/Measure/Restrict.lean
/-- If two measurable sets are ae_eq then any proposition that is almost everywhere true on one
is almost everywhere true on the other -/
theorem ae_restrict_of_ae_eq_of_ae_restrict {s t} (hst : s =ᵐ[μ] t) {p : α → Prop} :
    (∀ᵐ x ∂μ.restrict s, p x) → ∀ᵐ x ∂μ.restrict t, p x
-- Mathlib/Topology/Instances/ENNReal.lean
theorem openEmbedding_coe : OpenEmbedding ((↑) : ℝ≥0 → ℝ≥0∞)
-- Mathlib/Algebra/Algebra/Subalgebra/Basic.lean
theorem range_le : Set.range (algebraMap R A) ≤ S
-- .lake/packages/lean4/src/lean/Init/Data/Nat/Simproc.lean
theorem sub_add_eq_comm (a b c : Nat) : a - (b + c) = a - c - b
-- Mathlib/GroupTheory/GroupAction/SubMulAction.lean
/-- `SMulMemClass S R M` says `S` is a type of subsets `s ≤ M` that are closed under the
scalar action of `R` on `M`.

Note that only `R` is marked as an `outParam` here, since `M` is supplied by the `SetLike`
class instead.
-/
class SMulMemClass (S : Type*) (R : outParam Type*) (M : Type*) [SMul R M] [SetLike S M] :
    Prop where
  /-- Multiplication by a scalar on an element of the set remains in the set. -/
  smul_mem : ∀ {s : S} (r : R) {m : M}, m ∈ s → r • m ∈ s
-- Mathlib/Analysis/Normed/Module/Ray.lean
/-- Two vectors `x y` in a real normed space are on the ray if and only if one of them is zero or
the unit vectors `‖x‖⁻¹ • x` and `‖y‖⁻¹ • y` are equal. -/
theorem sameRay_iff_inv_norm_smul_eq : SameRay ℝ x y ↔ x = 0 ∨ y = 0 ∨ ‖x‖⁻¹ • x = ‖y‖⁻¹ • y
-- Mathlib/Data/Real/Archimedean.lean
/-- A nonempty, bounded below set of real numbers has a greatest lower bound. -/
theorem exists_isGLB {S : Set ℝ} (hne : S.Nonempty) (hbdd : BddBelow S) : ∃ x, IsGLB S x
-- Mathlib/Data/Rat/Lemmas.lean
theorem isSquare_iff {q : ℚ} : IsSquare q ↔ IsSquare q.num ∧ IsSquare q.den
-- Mathlib/Algebra/Polynomial/Div.lean
theorem not_isField : ¬IsField R[X]
-- Mathlib/MeasureTheory/Constructions/Pi.lean
theorem measurePreserving_finTwoArrow_vec {α : Type u} {m : MeasurableSpace α} (μ ν : Measure α)
    [SigmaFinite μ] [SigmaFinite ν] :
    MeasurePreserving MeasurableEquiv.finTwoArrow (Measure.pi ![μ, ν]) (μ.prod ν)
-- Mathlib/Algebra/Lie/Weights/Linear.lean
@[simp] lemma coe_coe : (↑(χ : L →ₗ[R] R) : L → R) = (χ : L → R)
-- .lake/packages/batteries/Batteries/Data/String/Lemmas.lean
theorem _root_.String.validFor_toSubstring (s : String) : ValidFor [] s.1 [] s
-- Mathlib/Algebra/Algebra/Subalgebra/Basic.lean
theorem inclusion_right {S T : Subalgebra R A} (h : S ≤ T) (x : T) (m : (x : A) ∈ S) :
    inclusion h ⟨x, m⟩ = x
-- Mathlib/Order/Lattice.lean
/-- Pointwise minimum of two monotone functions is a monotone function. -/
protected theorem min [Preorder α] [LinearOrder β] {f g : α → β} (hf : Monotone f)
    (hg : Monotone g) :
    Monotone fun x => min (f x) (g x)
-- Mathlib/LinearAlgebra/FiniteDimensional/Defs.lean
/-- A submodule is finitely generated if and only if it is finite-dimensional -/
theorem fg_iff_finiteDimensional (s : Submodule K V) : s.FG ↔ FiniteDimensional K s
-- Mathlib/CategoryTheory/Limits/Cones.lean
/-- Change a cocone on `F : Jᵒᵖ ⥤ Cᵒᵖ` into a cone on `F.unop : J ⥤ C`. -/
@[simps]
def coneUnopOfCocone (c : Cocone F) : Cone F.unop
-- Mathlib/Algebra/Group/Subgroup/Basic.lean
@[to_additive]
theorem le_normalizer_of_normal [hK : (H.subgroupOf K).Normal] (HK : H ≤ K) : K ≤ H.normalizer
-- Mathlib/Order/BooleanAlgebra.lean
@[simp] lemma himp_le_iff : x ⇨ y ≤ x ↔ x = ⊤
-- Mathlib/FieldTheory/Normal.lean
/-- If `K₁/E/F` is a tower of fields with `E/F` normal then `AlgHom.restrictNormal'` is an
 equivalence. -/
@[simps]
def Normal.algHomEquivAut [Normal F E] : (E →ₐ[F] K₁) ≃ E ≃ₐ[F] E
-- Mathlib/Algebra/Category/ModuleCat/Differentials/Presheaf.lean
/-- The universal property that a derivation `d : M.Derivation φ` must
satisfy so that the presheaf of modules `M` can be considered as the presheaf of
(relative) differentials of a presheaf of commutative rings `φ : S ⟶ F.op ⋙ R`. -/
structure Universal where
  /-- An absolyte derivation of `M'` descends as a morphism `M ⟶ M'`. -/
  desc {M' : PresheafOfModules (R ⋙ forget₂ CommRingCat RingCat)}
    (d' : M'.Derivation φ) : M ⟶ M'
  fac {M' : PresheafOfModules (R ⋙ forget₂ CommRingCat RingCat)}
    (d' : M'.Derivation φ) : d.postcomp (desc d') = d' := by aesop_cat
  postcomp_injective {M' : PresheafOfModules (R ⋙ forget₂ CommRingCat RingCat)}
    (φ φ' : M ⟶ M') (h : d.postcomp φ = d.postcomp φ') : φ = φ' := by aesop_cat
-- Mathlib/Data/ENNReal/Inv.lean
theorem div_le_of_le_mul' (h : a ≤ b * c) : a / b ≤ c
-- Mathlib/Data/Finset/Lattice.lean
theorem inf_sdiff_right (hs : s.Nonempty) (f : ι → α) (a : α) :
    (s.inf fun b => f b \ a) = s.inf f \ a
-- .lake/packages/lean4/src/lean/Init/Data/Nat/Linear.lean
theorem Poly.denote_reverse (ctx : Context) (p : Poly) : denote ctx (List.reverse p) = denote ctx p
-- .lake/packages/lean4/src/lean/Init/Data/BitVec/Lemmas.lean
@[bv_toNat] theorem toNat_sub' {n} (x y : BitVec n) :
    (x - y).toNat = ((x.toNat + (2^n - y.toNat)) % 2^n)
-- Mathlib/Order/Category/Preord.lean
/-- The embedding of `Preord` into `Cat`.
-/
@[simps]
def preordToCat : Preord.{u} ⥤ Cat
-- Mathlib/Analysis/Fourier/ZMod.lean
lemma dft_apply (Φ : ZMod N → ℂ) (k : ZMod N) :
    𝓕 Φ k = ∑ j : ZMod N, toCircle (-(j * k)) • Φ j
-- Mathlib/SetTheory/Game/PGame.lean
@[simp]
theorem neg_lf_zero_iff {x : PGame} : -x ⧏ 0 ↔ 0 ⧏ x
-- Mathlib/CategoryTheory/Limits/HasLimits.lean
/-- `hasColimitsOfSizeShrink.{v u} C` tries to obtain `HasColimitsOfSize.{v u} C`
from some other `HasColimitsOfSize C`.
-/
theorem hasColimitsOfSizeShrink [HasColimitsOfSize.{max v₁ v₂, max u₁ u₂} C] :
    HasColimitsOfSize.{v₁, u₁} C
-- Mathlib/LinearAlgebra/Matrix/PosDef.lean
theorem isHermitian {M : Matrix n n R} (hM : M.PosDef) : M.IsHermitian
-- Mathlib/CategoryTheory/Localization/Predicate.lean
@[simp]
lemma isoOfHom_id_inv (X : C) (hX : W (𝟙 X)) :
    (isoOfHom L W (𝟙 X) hX).inv = 𝟙 _
-- Mathlib/Logic/Basic.lean
theorem ite_ite_comm (h : P → ¬Q) :
    (if P then a else if Q then b else c) =
     if Q then b else if P then a else c
-- Mathlib/Topology/EMetricSpace/Basic.lean
theorem diam_pair : diam ({x, y} : Set α) = edist x y
-- Mathlib/MeasureTheory/Integral/IntegrableOn.lean
theorem ContinuousAt.stronglyMeasurableAtFilter [TopologicalSpace α] [OpensMeasurableSpace α]
    [SecondCountableTopologyEither α E] {f : α → E} {s : Set α} {μ : Measure α} (hs : IsOpen s)
    (hf : ∀ x ∈ s, ContinuousAt f x) : ∀ x ∈ s, StronglyMeasurableAtFilter f (𝓝 x) μ
-- Mathlib/Analysis/Asymptotics/Asymptotics.lean
theorem isBigO_const_smul_left {c : 𝕜} (hc : c ≠ 0) : (fun x => c • f' x) =O[l] g ↔ f' =O[l] g
-- Mathlib/LinearAlgebra/Trace.lean
@[simp]
theorem trace_transpose : trace R (Module.Dual R M) ∘ₗ Module.Dual.transpose = trace R M
-- Mathlib/Combinatorics/Additive/PluenneckeRuzsa.lean
/-- The **Plünnecke-Ruzsa inequality**. Division version. -/
@[to_additive "The **Plünnecke-Ruzsa inequality**. Subtraction version."]
theorem pluennecke_ruzsa_inequality_pow_div_pow_div (hA : A.Nonempty) (B : Finset α) (m n : ℕ) :
    (B ^ m / B ^ n).card ≤ ((A / B).card / A.card : ℚ≥0) ^ (m + n) * A.card
-- Mathlib/Topology/Algebra/Equicontinuity.lean
@[to_additive]
theorem uniformEquicontinuous_of_equicontinuousAt_one {ι G M hom : Type*} [UniformSpace G]
    [UniformSpace M] [Group G] [Group M] [UniformGroup G] [UniformGroup M]
    [FunLike hom G M] [MonoidHomClass hom G M]
    (F : ι → hom) (hf : EquicontinuousAt ((↑) ∘ F) (1 : G)) :
    UniformEquicontinuous ((↑) ∘ F)
-- Mathlib/MeasureTheory/Integral/IntervalIntegral.lean
theorem norm (h : IntervalIntegrable f μ a b) : IntervalIntegrable (fun x => ‖f x‖) μ a b
-- Mathlib/Algebra/BigOperators/WithTop.lean
/-- A sum of finite terms is finite. -/
lemma sum_lt_top (h : ∀ i ∈ s, f i ≠ ⊤) : ∑ i ∈ s, f i < ⊤
-- Mathlib/Analysis/ODE/PicardLindelof.lean
theorem dist_iterate_next_apply_le (f₁ f₂ : FunSpace v) (n : ℕ) (t : Icc v.tMin v.tMax) :
    dist (next^[n] f₁ t) (next^[n] f₂ t) ≤ (v.L * |t.1 - v.t₀|) ^ n / n ! * dist f₁ f₂
-- Mathlib/Data/List/Basic.lean
@[gcongr] protected theorem Sublist.tail : ∀ {l₁ l₂ : List α}, l₁ <+ l₂ → tail l₁ <+ tail l₂
-- Mathlib/CategoryTheory/Limits/Shapes/StrongEpi.lean
/-- If `f ≫ g` is a strong monomorphism, then so is `f`. -/
theorem strongMono_of_strongMono [StrongMono (f ≫ g)] : StrongMono f
-- Mathlib/Data/Finset/Sort.lean
@[simp]
theorem coe_orderIsoOfFin_apply (s : Finset α) {k : ℕ} (h : s.card = k) (i : Fin k) :
    ↑(orderIsoOfFin s h i) = orderEmbOfFin s h i
-- .lake/packages/lean4/src/lean/Init/SimpLemmas.lean
theorem Eq.mpr_prop {p q : Prop} (h₁ : p = q) (h₂ : q)  : p
-- Mathlib/Order/ConditionallyCompleteLattice/Basic.lean
@[simp]
theorem ciSup_const [hι : Nonempty ι] {a : α} : ⨆ _ : ι, a = a
-- Mathlib/Analysis/InnerProductSpace/Basic.lean
/-- Polarization identity: The real inner product, in terms of the norm. -/
theorem real_inner_eq_norm_mul_self_add_norm_mul_self_sub_norm_sub_mul_self_div_two (x y : F) :
    ⟪x, y⟫_ℝ = (‖x‖ * ‖x‖ + ‖y‖ * ‖y‖ - ‖x - y‖ * ‖x - y‖) / 2
-- Mathlib/Order/Disjoint.lean
theorem Disjoint.mono (h₁ : a ≤ b) (h₂ : c ≤ d) : Disjoint b d → Disjoint a c
-- Mathlib/Tactic/NormNum/Basic.lean
theorem ble_eq_false {x y : ℕ} : x.ble y = false ↔ y < x
-- Mathlib/Algebra/AddConstMap/Basic.lean
@[scoped simp]
theorem map_add_ofNat' [AddMonoidWithOne G] [AddMonoid H] [AddConstMapClass F G H 1 b]
    (f : F) (x : G) (n : ℕ) [n.AtLeastTwo] :
    f (x + no_index (OfNat.ofNat n)) = f x + (OfNat.ofNat n : ℕ) • b
-- Mathlib/Computability/DFA.lean
theorem pumping_lemma [Fintype σ] {x : List α} (hx : x ∈ M.accepts)
    (hlen : Fintype.card σ ≤ List.length x) :
    ∃ a b c,
      x = a ++ b ++ c ∧
        a.length + b.length ≤ Fintype.card σ ∧ b ≠ [] ∧ {a} * {b}∗ * {c} ≤ M.accepts
-- Mathlib/Analysis/Asymptotics/Asymptotics.lean
theorem IsBigOWith.sub_isLittleO (h₁ : IsBigOWith c₁ l f₁ g) (h₂ : f₂ =o[l] g) (hc : c₁ < c₂) :
    IsBigOWith c₂ l (fun x => f₁ x - f₂ x) g
-- Mathlib/MeasureTheory/Measure/Haar/OfBasis.lean
theorem parallelepiped_orthonormalBasis_one_dim (b : OrthonormalBasis ι ℝ ℝ) :
    parallelepiped b = Icc 0 1 ∨ parallelepiped b = Icc (-1) 0
-- Mathlib/Topology/Algebra/ConstMulAction.lean
@[to_additive]
theorem isClosedMap_smul (c : G) : IsClosedMap fun x : α => c • x
-- .lake/packages/lean4/src/lean/Init/Data/List/Basic.lean
@[simp] theorem isEqv_nil_cons : isEqv ([] : List α) (a::as) eqv = false
-- Mathlib/MeasureTheory/Function/StronglyMeasurable/Basic.lean
theorem _root_.Continuous.comp_stronglyMeasurable {_ : MeasurableSpace α} [TopologicalSpace β]
    [TopologicalSpace γ] {g : β → γ} {f : α → β} (hg : Continuous g) (hf : StronglyMeasurable f) :
    StronglyMeasurable fun x => g (f x)
-- Mathlib/Algebra/Algebra/Equiv.lean
@[simp]
theorem toLinearEquiv_trans (e₁ : A₁ ≃ₐ[R] A₂) (e₂ : A₂ ≃ₐ[R] A₃) :
    (e₁.trans e₂).toLinearEquiv = e₁.toLinearEquiv.trans e₂.toLinearEquiv
-- Mathlib/Topology/MetricSpace/HausdorffDistance.lean
theorem infDist_eq_iInf : infDist x s = ⨅ y : s, dist x y
-- Mathlib/CategoryTheory/Sites/Grothendieck.lean
/-- Pull back a cover along a morphism. -/
@[simps obj]
def pullback (f : Y ⟶ X) : J.Cover X ⥤ J.Cover Y
-- Mathlib/GroupTheory/Perm/Option.lean
theorem Equiv.Perm.decomposeOption_symm_of_none_apply {α : Type*} [DecidableEq α] (e : Perm α)
    (i : Option α) : Equiv.Perm.decomposeOption.symm (none, e) i = i.map e