ruc-ai4math/mathlib_handler_benchmark_410 huggingface dataset:
-- Mathlib/LinearAlgebra/Dimension/RankNullity.lean
lemma exists_set_linearIndependent :
    ∃ s : Set M, #s = Module.rank R M ∧ LinearIndependent (ι := s) R Subtype.val
-- Mathlib/LinearAlgebra/Dimension/DivisionRing.lean
theorem rank_lt_rank_dual' {V : Type u} [AddCommGroup V] [Module K V] (h : ℵ₀ ≤ Module.rank K V) :
    Module.rank K V < Module.rank Kᵐᵒᵖ (V →ₗ[K] K)
-- Mathlib/Algebra/BigOperators/Group/Finset.lean
theorem prod_dvd_prod_of_subset {ι M : Type*} [CommMonoid M] (s t : Finset ι) (f : ι → M)
    (h : s ⊆ t) : (∏ i ∈ s, f i) ∣ ∏ i ∈ t, f i
-- Mathlib/Data/Set/Basic.lean
theorem nonempty_coe_sort {s : Set α} : Nonempty (↥s) ↔ s.Nonempty
-- .lake/packages/lean4/src/lean/Init/Data/Nat/Basic.lean
protected theorem not_lt_of_ge : ∀{a b : Nat}, b ≥ a → ¬(b < a)
-- Mathlib/Combinatorics/SimpleGraph/Connectivity/Subgraph.lean
lemma preconnected_iff_forall_exists_walk_subgraph (H : G.Subgraph) :
    H.Preconnected ↔ ∀ {u v}, u ∈ H.verts → v ∈ H.verts → ∃ p : G.Walk u v, p.toSubgraph ≤ H
-- Mathlib/Algebra/Star/NonUnitalSubalgebra.lean
@[simp]
theorem mem_star_iff (S : NonUnitalSubalgebra R A) (x : A) : x ∈ star S ↔ star x ∈ S
-- Mathlib/RingTheory/SurjectiveOnStalks.lean
lemma surjectiveOnStalks_iff_forall_maximal' :
    f.SurjectiveOnStalks ↔ ∀ I : Ideal S, I.IsMaximal →
      ∀ s : S, ∃ x r : R, ∃ c ∉ I, f r ∉ I ∧ c * f r * s = c * f x
-- Mathlib/Data/List/Perm.lean
private theorem DecEq_eq [DecidableEq α] :
    List.instBEq = @instBEqOfDecidableEq (List α) instDecidableEqList
-- Mathlib/Data/List/Basic.lean
theorem getLast_cons_cons (a₁ a₂ : α) (l : List α) :
    getLast (a₁ :: a₂ :: l) (cons_ne_nil _ _) = getLast (a₂ :: l) (cons_ne_nil a₂ l)
-- Mathlib/Algebra/Algebra/NonUnitalSubalgebra.lean
theorem mem_iInf {ι : Sort*} {S : ι → NonUnitalSubalgebra R A} {x : A} :
    (x ∈ ⨅ i, S i) ↔ ∀ i, x ∈ S i
-- Mathlib/LinearAlgebra/QuadraticForm/TensorProduct/Isometries.lean
@[simp]
theorem _root_.QuadraticMap.Isometry.tmul_apply
    {Q₁ : QuadraticForm R M₁} {Q₂ : QuadraticForm R M₂}
    {Q₃ : QuadraticForm R M₃} {Q₄ : QuadraticForm R M₄}
    (f : Q₁ →qᵢ Q₂) (g : Q₃ →qᵢ Q₄) (x : M₁ ⊗[R] M₃) :
    f.tmul g x = TensorProduct.map f.toLinearMap g.toLinearMap x
-- Mathlib/Data/Set/Basic.lean
@[simp]
theorem inclusion_self (x : s) : inclusion Subset.rfl x = x
-- Mathlib/RingTheory/Noetherian.lean
theorem isNoetherian_of_submodule_of_noetherian (R M) [Semiring R] [AddCommMonoid M] [Module R M]
    (N : Submodule R M) (h : IsNoetherian R M) : IsNoetherian R N
-- .lake/packages/batteries/Batteries/Data/String/Lemmas.lean
theorem extract_of_valid (l m r : List Char) :
    extract ⟨l ++ m ++ r⟩ ⟨utf8Len l⟩ ⟨utf8Len l + utf8Len m⟩ = ⟨m⟩
-- Mathlib/LinearAlgebra/AffineSpace/ContinuousAffineEquiv.lean
@[simp]
theorem refl_apply (x : P₁) : refl k P₁ x = x
-- Mathlib/LinearAlgebra/Prod.lean
@[simp, deprecated (since := "2024-06-05")]
theorem tailings_succ (f : M × N →ₗ[R] M) (i : Injective f) (n : ℕ) :
    tailings f i (n + 1) = tailings f i n ⊔ tailing f i (n + 1)
-- Mathlib/Analysis/Calculus/FDeriv/Basic.lean
/-- Converse to the mean value inequality: if `f` is differentiable at `x₀` and `C`-lipschitz
on a neighborhood of `x₀` then its derivative at `x₀` has norm bounded by `C`. This version
only assumes that `‖f x - f x₀‖ ≤ C * ‖x - x₀‖` in a neighborhood of `x`. -/
theorem HasFDerivAt.le_of_lip' {f : E → F} {f' : E →L[𝕜] F} {x₀ : E} (hf : HasFDerivAt f f' x₀)
    {C : ℝ} (hC₀ : 0 ≤ C) (hlip : ∀ᶠ x in 𝓝 x₀, ‖f x - f x₀‖ ≤ C * ‖x - x₀‖) : ‖f'‖ ≤ C
-- Mathlib/Topology/Instances/Matrix.lean
@[continuity]
theorem Continuous.matrix_transpose {A : X → Matrix m n R} (hA : Continuous A) :
    Continuous fun x => (A x)ᵀ
-- Mathlib/LinearAlgebra/AffineSpace/FiniteDimensional.lean
theorem Affine.Simplex.span_eq_top [FiniteDimensional k V] {n : ℕ} (T : Affine.Simplex k V n)
    (hrank : finrank k V = n) : affineSpan k (Set.range T.points) = ⊤
-- Mathlib/Analysis/Convex/Segment.lean
theorem sameRay_of_mem_segment [StrictOrderedCommRing 𝕜] [AddCommGroup E] [Module 𝕜 E] {x y z : E}
    (h : x ∈ [y -[𝕜] z]) : SameRay 𝕜 (x - y) (z - x)
-- Mathlib/Algebra/Order/Floor.lean
theorem ceil_lt_add_one (a : α) : (⌈a⌉ : α) < a + 1
-- Mathlib/Algebra/Category/ModuleCat/ChangeOfRings.lean
/--
Given `R`-module X and `S`-module Y and a map `g : (extendScalars f).obj X ⟶ Y`, i.e. `S`-linear
map `S ⨂ X → Y`, there is a `X ⟶ (restrictScalars f).obj Y`, i.e. `R`-linear map `X ⟶ Y` by
`x ↦ g (1 ⊗ x)`.
-/
@[simps apply]
def HomEquiv.toRestrictScalars {X Y} (g : (extendScalars f).obj X ⟶ Y) :
    X ⟶ (restrictScalars f).obj Y
-- Mathlib/Probability/ProbabilityMassFunction/Monad.lean
theorem bind_comm (p : PMF α) (q : PMF β) (f : α → β → PMF γ) :
    (p.bind fun a => q.bind (f a)) = q.bind fun b => p.bind fun a => f a b
-- Mathlib/Topology/Basic.lean
theorem isOpen_fold {t : TopologicalSpace X} : t.IsOpen s = IsOpen[t] s
-- Mathlib/AlgebraicTopology/DoldKan/FunctorN.lean
@[simp]
lemma toKaroubiCompN₂IsoN₁_inv_app (X : SimplicialObject C) :
    (toKaroubiCompN₂IsoN₁.inv.app X).f = PInfty
-- Mathlib/Algebra/EuclideanDomain/Basic.lean
@[simp]
theorem mod_eq_zero {a b : R} : a % b = 0 ↔ b ∣ a
-- Mathlib/Topology/MetricSpace/Infsep.lean
theorem Subsingleton.infsep_zero (hs : s.Subsingleton) : s.infsep = 0
-- Mathlib/Geometry/Manifold/MFDeriv/SpecificFunctions.lean
theorem tangentMapWithin_prod_snd {s : Set (M × M')} {p : TangentBundle (I.prod I') (M × M')}
    (hs : UniqueMDiffWithinAt (I.prod I') s p.proj) :
    tangentMapWithin (I.prod I') I' Prod.snd s p = ⟨p.proj.2, p.2.2⟩
-- Mathlib/Algebra/Algebra/Prod.lean
/-- The `Pi.prod` of two morphisms is a morphism. -/
@[simps!]
def prod (f : A →ₐ[R] B) (g : A →ₐ[R] C) : A →ₐ[R] B × C
-- Mathlib/Topology/Order.lean
theorem continuous_iSup_rng {t₁ : TopologicalSpace α} {t₂ : ι → TopologicalSpace β} {i : ι}
    (h : Continuous[t₁, t₂ i] f) : Continuous[t₁, iSup t₂] f
-- Mathlib/Algebra/Order/Floor.lean
private theorem nat_ceil_pos [LinearOrderedSemiring α] [FloorSemiring α] {a : α} :
    0 < a → 0 < ⌈a⌉₊
-- Mathlib/Algebra/GroupWithZero/Defs.lean
@[simp] lemma mul_div_cancel_right₀ (a : M₀) (hb : b ≠ 0) : a * b / b = a
-- Mathlib/RingTheory/LaurentSeries.lean
@[norm_cast]
theorem coe_neg : ((-f' : PowerSeries R') : LaurentSeries R') = -f'
-- Mathlib/LinearAlgebra/AffineSpace/Ordered.lean
/-- Given `c = lineMap a b r`, `a < c`, the point `(c, f c)` is strictly above the
segment `[(a, f a), (b, f b)]` if and only if `slope f a b < slope f a c`. -/
theorem lineMap_lt_map_iff_slope_lt_slope_left (h : 0 < r * (b - a)) :
    lineMap (f a) (f b) r < f c ↔ slope f a b < slope f a c
-- Mathlib/Topology/Homotopy/HSpaces.lean
theorem qRight_one_right (t : I) : qRight (t, 1) = t
-- Mathlib/MeasureTheory/MeasurableSpace/Defs.lean
/-- A typeclass mixin for `MeasurableSpace`s such that all sets are measurable. -/
class DiscreteMeasurableSpace (α : Type*) [MeasurableSpace α] : Prop where
  /-- Do not use this. Use `measurableSet_discrete` instead. -/
  forall_measurableSet : ∀ s : Set α, MeasurableSet s
-- Mathlib/Topology/Order/OrderClosed.lean
theorem eventually_le_of_tendsto_lt {l : Filter γ} {f : γ → α} {u v : α} (hv : v < u)
    (h : Tendsto f l (𝓝 v)) : ∀ᶠ a in l, f a ≤ u
-- Mathlib/Analysis/Normed/Group/Seminorm.lean
theorem smul_sup (r : R) (p q : NonarchAddGroupSeminorm E) : r • (p ⊔ q) = r • p ⊔ r • q
-- Mathlib/Logic/Nontrivial/Basic.lean
@[nontriviality]
protected theorem Subsingleton.le [Preorder α] [Subsingleton α] (x y : α) : x ≤ y
-- Mathlib/CategoryTheory/Preadditive/Basic.lean
@[simp]
theorem kernelForkOfFork_ofι {P : C} (ι : P ⟶ X) (w : ι ≫ f = ι ≫ g) :
    kernelForkOfFork (Fork.ofι ι w) = KernelFork.ofι ι (by simp [w])
-- Mathlib/Algebra/CharP/Algebra.lean
/-- If the algebra map `R →+* A` is injective then `A` has the same characteristic as `R`. -/
theorem charP_of_injective_algebraMap {R A : Type*} [CommSemiring R] [Semiring A] [Algebra R A]
    (h : Function.Injective (algebraMap R A)) (p : ℕ) [CharP R p] : CharP A p
-- Mathlib/Data/Ordmap/Ordset.lean
theorem Valid'.rotateR {l} {x : α} {r o₁ o₂} (hl : Valid' o₁ l x) (hr : Valid' x r o₂)
    (H1 : ¬size l + size r ≤ 1) (H2 : delta * size r < size l)
    (H3 : 2 * size l ≤ 9 * size r + 5 ∨ size l ≤ 3) : Valid' o₁ (@rotateR α l x r) o₂
-- Mathlib/CategoryTheory/Monoidal/FunctorCategory.lean
@[simp]
theorem tensorHom_app {F G F' G' : C ⥤ D} {α : F ⟶ G} {β : F' ⟶ G'} {X} :
    (α ⊗ β).app X = α.app X ⊗ β.app X
-- Mathlib/Probability/Kernel/Basic.lean
theorem integral_deterministic' {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E]
    [CompleteSpace E] {f : β → E} {g : α → β} {a : α} (hg : Measurable g)
    (hf : StronglyMeasurable f) : ∫ x, f x ∂deterministic g hg a = f (g a)
-- Mathlib/Data/Set/Basic.lean
theorem Nonempty.inl (hs : s.Nonempty) : (s ∪ t).Nonempty
-- Mathlib/Computability/Primrec.lean
theorem unpaired' {f : ℕ → ℕ → ℕ} : Nat.Primrec (Nat.unpaired f) ↔ Primrec₂ f
-- Mathlib/Geometry/Manifold/BumpFunction.lean
@[simp]
theorem eq_one : f c = 1
-- Mathlib/MeasureTheory/Measure/Haar/NormedSpace.lean
theorem Integrable.comp_div {g : ℝ → F} (hg : Integrable g) {R : ℝ} (hR : R ≠ 0) :
    Integrable fun x => g (x / R)
-- Mathlib/Topology/Homotopy/Product.lean
/-- Products commute with path composition.
    This is `trans_prod_eq_prod_trans` descended to the quotient. -/
theorem comp_prod_eq_prod_comp : prod q₁ q₂ ⬝ prod r₁ r₂ = prod (q₁ ⬝ r₁) (q₂ ⬝ r₂)
-- Mathlib/Data/Vector/MapLemmas.lean
/--
  If an accumulation function `f`, produces the same output bits regardless of accumulation state,
  then the state is redundant and can be optimized out
-/
@[simp]
theorem mapAccumr_eq_map_of_unused_state (f : α → σ → σ × β) (s : σ)
    (h : ∀ a s s', (f a s).snd = (f a s').snd) :
    (mapAccumr f xs s).snd = (map (fun x => (f x s).snd) xs)
-- Mathlib/Analysis/NormedSpace/MStructure.lean
theorem mul_compl_self {P : { P : M // IsLprojection X P }} : (↑P : M) * ↑Pᶜ = 0
-- Mathlib/LinearAlgebra/Matrix/NonsingularInverse.lean
theorem inv_reindex (e₁ e₂ : n ≃ m) (A : Matrix n n α) : (reindex e₁ e₂ A)⁻¹ = reindex e₂ e₁ A⁻¹
-- Mathlib/CategoryTheory/Limits/Shapes/Terminal.lean
/-- Any morphism between initial objects is an isomorphism. -/
lemma isIso_of_isInitial {X Y : C} (hX : IsInitial X) (hY : IsInitial Y) (f : X ⟶ Y) :
    IsIso f
-- Mathlib/Algebra/Order/Interval/Finset.lean
@[simp] lemma map_add_left_Ioc (a b c : α) :
    (Ioc a b).map (addLeftEmbedding c) = Ioc (c + a) (c + b)
-- Mathlib/AlgebraicGeometry/Morphisms/Basic.lean
theorem iff_of_openCover (𝒰 : Y.OpenCover) [∀ i, IsAffine (𝒰.obj i)] :
    P f ↔ ∀ i, Q (𝒰.pullbackHom f i)
-- Mathlib/MeasureTheory/OuterMeasure/Basic.lean
/-- If `s : ℕ → Set α` is a monotone sequence of sets such that `∑' k, m (s (k + 1) \ s k) ≠ ∞`,
then `m (⋃ n, s n) = ⨆ n, m (s n)`. -/
theorem iUnion_nat_of_monotone_of_tsum_ne_top (m : OuterMeasure α) {s : ℕ → Set α}
    (h_mono : ∀ n, s n ⊆ s (n + 1)) (h0 : (∑' k, m (s (k + 1) \ s k)) ≠ ∞) :
    m (⋃ n, s n) = ⨆ n, m (s n)
-- Mathlib/LinearAlgebra/LinearIndependent.lean
/-- If `v` is a linearly independent family of vectors and the kernel of a linear map `f` is
disjoint with the submodule spanned by the vectors of `v`, then `f ∘ v` is a linearly independent
family of vectors. See also `LinearIndependent.map'` for a special case assuming `ker f = ⊥`. -/
theorem LinearIndependent.map (hv : LinearIndependent R v) {f : M →ₗ[R] M'}
    (hf_inj : Disjoint (span R (range v)) (LinearMap.ker f)) : LinearIndependent R (f ∘ v)
-- Mathlib/Algebra/Category/Ring/Basic.lean
@[ext] theorem ext_of {X Y : Type u} [CommRing X] [CommRing Y] (f g : X →+* Y)
    (h : ∀ x, f x = g x) :
    @Eq (CommRingCat.of X ⟶ CommRingCat.of Y) f g
-- Mathlib/Data/Rat/Defs.lean
@[simp]
lemma divInt_mul_divInt' (n₁ d₁ n₂ d₂ : ℤ) : (n₁ /. d₁) * (n₂ /. d₂) = (n₁ * n₂) /. (d₁ * d₂)
-- Mathlib/Logic/Embedding/Basic.lean
/-- `Sigma.mk` as a `Function.Embedding`. -/
@[simps apply]
def sigmaMk (a : α) : β a ↪ Σx, β x
-- Mathlib/AlgebraicTopology/SimplexCategory.lean
theorem isIso_of_bijective {x y : SimplexCategory} {f : x ⟶ y}
    (hf : Function.Bijective f.toOrderHom.toFun) : IsIso f
-- Mathlib/Algebra/Order/Ring/Rat.lean
@[simp] lemma mkRat_nonneg {a : ℤ} (ha : 0 ≤ a) (b : ℕ) : 0 ≤ mkRat a b
-- Mathlib/Geometry/Manifold/MFDeriv/Basic.lean
theorem HasMFDerivAt.mdifferentiableAt (h : HasMFDerivAt I I' f x f') :
    MDifferentiableAt I I' f x
-- Mathlib/AlgebraicGeometry/Scheme.lean
lemma presheaf_map_eqToHom_op (X : Scheme) (U V : X.Opens) (i : U = V) :
    X.presheaf.map (eqToHom i).op = eqToHom (i ▸ rfl)
-- Mathlib/Combinatorics/SimpleGraph/Walk.lean
theorem dart_fst_mem_support_of_mem_darts {u v : V} :
    ∀ (p : G.Walk u v) {d : G.Dart}, d ∈ p.darts → d.fst ∈ p.support
-- Mathlib/Data/Finset/Basic.lean
@[simp]
theorem insert_inter_of_not_mem {s₁ s₂ : Finset α} {a : α} (h : a ∉ s₂) :
    insert a s₁ ∩ s₂ = s₁ ∩ s₂
-- Mathlib/MeasureTheory/Measure/VectorMeasure.lean
theorem measurable_of_not_zero_le_restrict (hi : ¬0 ≤[i] v) : MeasurableSet i
-- Mathlib/LinearAlgebra/TensorProduct/Basic.lean
@[simp] theorem rTensor_tmul : f.rTensor M (n ⊗ₜ m) = f n ⊗ₜ m
-- Mathlib/RingTheory/RootsOfUnity/Basic.lean
@[simp]
theorem primitiveRoots_zero : primitiveRoots 0 R = ∅
-- Mathlib/CategoryTheory/Limits/Shapes/Terminal.lean
/-- Any two morphisms from an initial object are equal. -/
theorem IsInitial.hom_ext {X Y : C} (t : IsInitial X) (f g : X ⟶ Y) : f = g
-- Mathlib/SetTheory/Ordinal/Arithmetic.lean
theorem comp_bfamilyOfFamily' {ι : Type u} (r : ι → ι → Prop) [IsWellOrder ι r] (f : ι → α)
    (g : α → β) : (fun i hi => g (bfamilyOfFamily' r f i hi)) = bfamilyOfFamily' r (g ∘ f)
-- Mathlib/Computability/ContextFreeGrammar.lean
/-- Add extra postfix to context-free rewriting. -/
lemma Rewrites.append_right {r : ContextFreeRule T N} {v w : List (Symbol T N)}
    (hvw : r.Rewrites v w) (p : List (Symbol T N)) : r.Rewrites (v ++ p) (w ++ p)
-- .lake/packages/batteries/Batteries/Data/String/Lemmas.lean
theorem setCurr : ∀ {it}, Valid it → Valid (it.setCurr c)
-- Mathlib/Probability/Independence/Kernel.lean
theorem iIndepSet.indep_generateFrom_le_nat [IsMarkovKernel κ] {s : ℕ → Set Ω}
    (hsm : ∀ n, MeasurableSet (s n)) (hs : iIndepSet s κ μ) (n : ℕ) :
    Indep (generateFrom {s (n + 1)}) (generateFrom { t | ∃ k ≤ n, s k = t }) κ μ
-- Mathlib/Algebra/Order/Kleene.lean
theorem kstar_mul_le_self : a * b ≤ b → a∗ * b ≤ b
-- .lake/packages/batteries/Batteries/Data/List/Lemmas.lean
theorem modifyNthTail_eq_take_drop (f : List α → List α) (H : f [] = []) :
    ∀ n l, modifyNthTail f n l = take n l ++ f (drop n l)
-- Mathlib/Order/Filter/Basic.lean
@[refl, simp]
theorem EventuallyEq.refl (l : Filter α) (f : α → β) : f =ᶠ[l] f
-- Mathlib/Analysis/Normed/Field/Basic.lean
/-- Multiplication on the left by a nonzero element of a normed division ring tends to infinity at
infinity. -/
theorem tendsto_mul_left_cobounded {a : α} (ha : a ≠ 0) :
    Tendsto (a * ·) (cobounded α) (cobounded α)
-- Mathlib/CategoryTheory/Localization/StructuredArrow.lean
private lemma induction_structuredArrow' (g : StructuredArrow (W.Q.obj X) W.Q) : P g
-- Mathlib/Algebra/Polynomial/Mirror.lean
theorem mirror_neg : (-p).mirror = -p.mirror
-- Mathlib/GroupTheory/CoprodI.lean
@[simp]
theorem inv_prod {i j} (w : NeWord G i j) : w.inv.prod = w.prod⁻¹
-- Mathlib/Analysis/Convex/EGauge.lean
lemma le_egauge_closedBall_one (x : E) : ‖x‖₊ ≤ egauge 𝕜 (closedBall 0 1) x
-- .lake/packages/lean4/src/lean/Init/Data/Int/DivModLemmas.lean
protected theorem eq_mul_of_div_eq_right {a b c : Int}
    (H1 : b ∣ a) (H2 : a.div b = c) : a = b * c
-- Mathlib/GroupTheory/Perm/Basic.lean
@[simp]
theorem subtypePerm_one (p : α → Prop) (h := fun _ => Iff.rfl) : @subtypePerm α p 1 h = 1
-- Mathlib/Order/Filter/Basic.lean
@[mono]
theorem comap_mono : Monotone (comap m)
-- Mathlib/MeasureTheory/Function/SimpleFuncDense.lean
theorem tendsto_nearestPt {e : ℕ → α} {x : α} (hx : x ∈ closure (range e)) :
    Tendsto (fun N => nearestPt e N x) atTop (𝓝 x)
-- Mathlib/CategoryTheory/Limits/Opposites.lean
@[reassoc (attr := simp)]
theorem pushoutIsoUnopPullback_inr_hom {X Y Z : C} (f : X ⟶ Z) (g : X ⟶ Y) [HasPushout f g]
    [HasPullback f.op g.op] :
    pushout.inr _ _ ≫ (pushoutIsoUnopPullback f g).hom = (pullback.snd f.op g.op).unop
-- Mathlib/Order/SuccPred/Basic.lean
theorem succ_lt_succ_iff : succ a < succ b ↔ a < b
-- Mathlib/FieldTheory/Perfect.lean
theorem roots_expand_map_frobenius_le :
    (expand R p f).roots.map (frobenius R p) ≤ p • f.roots
-- Mathlib/NumberTheory/RamificationInertia.lean
/-- The inclusion `(P^(i + 1) / P^e) ⊂ (P^i / P^e)`. -/
@[simps]
def powQuotSuccInclusion (i : ℕ) :
    Ideal.map (Ideal.Quotient.mk (P ^ e)) (P ^ (i + 1)) →ₗ[R ⧸ p]
    Ideal.map (Ideal.Quotient.mk (P ^ e)) (P ^ i)
-- Mathlib/Probability/CondCount.lean
/-- A version of the law of total probability for counting probabilities. -/
theorem condCount_add_compl_eq (u t : Set Ω) (hs : s.Finite) :
    condCount (s ∩ u) t * condCount s u + condCount (s ∩ uᶜ) t * condCount s uᶜ =
      condCount s t
-- Mathlib/Analysis/SpecialFunctions/JapaneseBracket.lean
theorem finite_integral_rpow_sub_one_pow_aux {r : ℝ} (n : ℕ) (hnr : (n : ℝ) < r) :
    (∫⁻ x : ℝ in Ioc 0 1, ENNReal.ofReal ((x ^ (-r⁻¹) - 1) ^ n)) < ∞
-- Mathlib/Algebra/Polynomial/Basic.lean
@[simp]
theorem toFinsupp_zero : (0 : R[X]).toFinsupp = 0
-- .lake/packages/lean4/src/lean/Init/SimpLemmas.lean
theorem eq_false' (h : p → False) : p = False
-- Mathlib/Algebra/Quaternion.lean
@[simp]
theorem star_mk (a₁ a₂ a₃ a₄ : R) : star (mk a₁ a₂ a₃ a₄ : ℍ[R,c₁,c₂]) = ⟨a₁, -a₂, -a₃, -a₄⟩
-- Mathlib/Analysis/SpecialFunctions/Complex/Arg.lean
@[simp]
theorem arg_neg_one : arg (-1) = π
-- Mathlib/Analysis/Fourier/Inversion.lean
/-- **Fourier inversion formula**: If a function `f` on a finite-dimensional real inner product
space is continuous, integrable, and its Fourier transform `𝓕 f` is also integrable,
then `𝓕 (𝓕⁻ f) = f`. -/
theorem Continuous.fourier_inversion_inv (h : Continuous f)
    (hf : Integrable f) (h'f : Integrable (𝓕 f)) :
    𝓕 (𝓕⁻ f) = f
-- Mathlib/Data/Nat/Defs.lean
@[simp] lemma div_div_div_eq_div (dvd : b ∣ a) (dvd2 : a ∣ c) : c / (a / b) / b = c / a
-- Mathlib/MeasureTheory/Integral/IntervalIntegral.lean
theorem continuousOn_mul {f g : ℝ → A} (hf : IntervalIntegrable f μ a b)
    (hg : ContinuousOn g [[a, b]]) : IntervalIntegrable (fun x => g x * f x) μ a b
-- Mathlib/Data/ENNReal/Operations.lean
theorem pow_lt_top : a < ∞ → ∀ n : ℕ, a ^ n < ∞
-- Mathlib/Analysis/Convex/Join.lean
theorem segment_subset_convexJoin (hx : x ∈ s) (hy : y ∈ t) : segment 𝕜 x y ⊆ convexJoin 𝕜 s t
-- Mathlib/CategoryTheory/Limits/Shapes/Equalizers.lean
theorem Fork.IsLimit.hom_ext {s : Fork f g} (hs : IsLimit s) {W : C} {k l : W ⟶ s.pt}
    (h : k ≫ Fork.ι s = l ≫ Fork.ι s) : k = l
-- Mathlib/Analysis/Normed/Group/Completion.lean
@[simp]
theorem norm_coe {E} [SeminormedAddCommGroup E] (x : E) : ‖(x : Completion E)‖ = ‖x‖
-- Mathlib/RingTheory/AdicCompletion/Basic.lean
@[simp]
lemma eval_lift_apply (f : ∀ (n : ℕ), M →ₗ[R] N ⧸ (I ^ n • ⊤ : Submodule R N))
    (h : ∀ {m n : ℕ} (hle : m ≤ n), transitionMap I N hle ∘ₗ f n = f m)
    (n : ℕ) (x : M) : (lift I f h x).val n = f n x
-- Mathlib/Probability/Kernel/RadonNikodym.lean
lemma rnDeriv_eq_top_iff' (κ η : Kernel α γ) (a : α) (x : γ) :
    rnDeriv κ η a x = ∞ ↔ x ∈ mutuallySingularSetSlice κ η a
-- Mathlib/Algebra/Polynomial/Smeval.lean
@[simp]
theorem smeval_X_pow {n : ℕ} :
    (X ^ n : R[X]).smeval x = x ^ n
-- Mathlib/Algebra/Polynomial/Eval.lean
@[simp]
protected theorem map_natCast (n : ℕ) : (n : R[X]).map f = n
-- .lake/packages/lean4/src/lean/Init/Data/Int/Order.lean
protected theorem neg_lt_neg {a b : Int} (h : a < b) : -b < -a
-- Mathlib/CategoryTheory/Bicategory/Extension.lean
@[reassoc (attr := simp)]
theorem w (h : s ⟶ t) : s.unit ≫ h.right ▷ f = t.unit
-- Mathlib/Analysis/Normed/Operator/BoundedLinearMaps.lean
/-- The composition of a continuous linear map with a continuous multilinear map is a bounded
bilinear operation. -/
theorem isBoundedBilinearMap_compMultilinear {ι : Type*} {E : ι → Type*} [Fintype ι]
    [∀ i, NormedAddCommGroup (E i)] [∀ i, NormedSpace 𝕜 (E i)] :
    IsBoundedBilinearMap 𝕜 fun p : (F →L[𝕜] G) × ContinuousMultilinearMap 𝕜 E F =>
      p.1.compContinuousMultilinearMap p.2
-- Mathlib/CategoryTheory/Triangulated/Basic.lean
@[reassoc (attr := simp)]
lemma _root_.CategoryTheory.Iso.hom_inv_id_triangle_hom₁ {A B : Triangle C} (e : A ≅ B) :
    e.hom.hom₁ ≫ e.inv.hom₁ = 𝟙 _
-- .lake/packages/lean4/src/lean/Init/Data/Nat/Lemmas.lean
protected theorem add_lt_add_of_lt_of_le {a b c d : Nat} (hlt : a < b) (hle : c ≤ d) :
    a + c < b + d
-- Mathlib/CategoryTheory/Monoidal/Rigid/Basic.lean
theorem tensorLeftHomEquiv_naturality {X Y Y' Z Z' : C} [ExactPairing Y Y'] (f : Y' ⊗ X ⟶ Z)
    (g : Z ⟶ Z') :
    (tensorLeftHomEquiv X Y Y' Z') (f ≫ g) = (tensorLeftHomEquiv X Y Y' Z) f ≫ Y ◁ g
-- Mathlib/LinearAlgebra/Alternating/Basic.lean
/-- Composition with a linear map before and after alternatization are equivalent. -/
theorem compMultilinearMap_alternatization (g : N' →ₗ[R] N'₂)
    (f : MultilinearMap R (fun _ : ι => M) N') :
    MultilinearMap.alternatization (g.compMultilinearMap f)
      = g.compAlternatingMap (MultilinearMap.alternatization f)
-- Mathlib/Data/Nat/Bitwise.lean
@[simp]
theorem ldiff_bit : ∀ a m b n, ldiff (bit a m) (bit b n) = bit (a && not b) (ldiff m n)
-- Mathlib/Algebra/Order/GroupWithZero/Unbundled.lean
theorem mul_le_of_mul_le_of_nonneg_right [MulPosMono α] (h : a * b ≤ c) (hle : d ≤ a) (b0 : 0 ≤ b) :
    d * b ≤ c
-- Mathlib/Topology/LocalAtTarget.lean
theorem isOpen_iff_inter_of_iSup_eq_top (s : Set β) : IsOpen s ↔ ∀ i, IsOpen (s ∩ U i)
-- Mathlib/Data/Nat/Defs.lean
lemma add_eq_one_iff : m + n = 1 ↔ m = 0 ∧ n = 1 ∨ m = 1 ∧ n = 0
-- Mathlib/Topology/Algebra/Constructions/DomMulAct.lean
@[to_additive (attr := simp)]
theorem coe_mkHomeomorph_symm : ⇑(mkHomeomorph : M ≃ₜ Mᵈᵐᵃ).symm = mk.symm
-- Mathlib/Geometry/Manifold/ContMDiff/Defs.lean
theorem ContMDiffWithinAt.mono_of_mem (hf : ContMDiffWithinAt I I' n f s x) (hts : s ∈ 𝓝[t] x) :
    ContMDiffWithinAt I I' n f t x
-- .lake/packages/lean4/src/lean/Init/Data/BitVec/Lemmas.lean
@[simp] theorem zeroExtend_eq (x : BitVec n) : zeroExtend n x = x
-- Mathlib/Topology/Constructions.lean
theorem ULift.closedEmbedding_down [TopologicalSpace X] :
    ClosedEmbedding (ULift.down : ULift.{v, u} X → X)
-- Mathlib/Analysis/Convex/Function.lean
theorem ConcaveOn.comp_convexOn (hg : ConcaveOn 𝕜 (f '' s) g) (hf : ConvexOn 𝕜 s f)
    (hg' : AntitoneOn g (f '' s)) : ConcaveOn 𝕜 s (g ∘ f)
-- Mathlib/CategoryTheory/Limits/Shapes/Diagonal.lean
@[reassoc (attr := simp)]
theorem diagonalObjPullbackFstIso_inv_snd_snd {X Y Z : C} (f : X ⟶ Z) (g : Y ⟶ Z) :
    (diagonalObjPullbackFstIso f g).inv ≫ pullback.snd _ _ ≫ pullback.snd _ _ =
      pullback.fst _ _ ≫ pullback.snd _ _
-- Mathlib/Analysis/SpecialFunctions/Gaussian/FourierTransform.lean
theorem _root_.fourierIntegral_gaussian_pi' (hb : 0 < b.re) (c : ℂ) :
    (𝓕 fun x : ℝ => cexp (-π * b * x ^ 2 + 2 * π * c * x)) = fun t : ℝ =>
    1 / b ^ (1 / 2 : ℂ) * cexp (-π / b * (t + I * c) ^ 2)
-- Mathlib/Combinatorics/Colex.lean
/-- Strictly monotone functions preserve the colex ordering. -/
lemma toColex_image_le_toColex_image (hf : StrictMono f) :
    toColex (s.image f) ≤ toColex (t.image f) ↔ toColex s ≤ toColex t
-- Mathlib/Topology/MetricSpace/Pseudo/Defs.lean
/-- A compact set is separable. -/
theorem IsCompact.isSeparable {s : Set α} (hs : IsCompact s) : IsSeparable s
-- .lake/packages/lean4/src/lean/Init/Data/Int/DivModLemmas.lean
@[simp] protected theorem div_left_inj {a b d : Int}
    (hda : d ∣ a) (hdb : d ∣ b) : a.div d = b.div d ↔ a = b
-- Mathlib/Algebra/Homology/HomologicalComplex.lean
theorem of_d_ne {i j : α} (h : i + 1 ≠ j) : (of X d sq).d i j = 0
-- Mathlib/Data/Finset/NAry.lean
theorem Nonempty.of_image₂_left (h : (s.image₂ f t).Nonempty) : s.Nonempty
-- Mathlib/RingTheory/MvPowerSeries/Basic.lean
@[simp]
theorem monomial_zero_eq_C : ⇑(monomial R (0 : σ →₀ ℕ)) = C σ R
-- Mathlib/AlgebraicTopology/SimplicialObject.lean
@[reassoc]
theorem δ_comp_σ_of_gt' {n} {i : Fin (n + 3)} {j : Fin (n + 2)} (H : j.succ < i) :
    X.δ i ≫ X.σ j =
      X.σ (j.castLT ((add_lt_add_iff_right 1).mp (lt_of_lt_of_le H i.is_le))) ≫
        X.δ (i.pred <|
          fun (hi : i = 0) => by simp only [Fin.not_lt_zero, hi] at H)