theorem HasBasis.forall_mem_mem (h : HasBasis l p s) {x : α} :
    (∀ t ∈ l, x ∈ t) ↔ ∀ i, p i → x ∈ s i

{α : Type u_1}
{ι : Sort u_4}
{l : Filter α}
{p : ι → Prop}
{s : ι → Set α}
(h : l.HasBasis p s)
{x : α}

(∀ t ∈ l, x ∈ t) ↔ ∀ (i : ι), p i → x ∈ s i


theorem subset_image_symmDiff : (f '' s) ∆ (f '' t) ⊆ f '' s ∆ t

{α : Type u_1}
{β : Type u_2}
{f : α → β}
{s t : Set α}

symmDiff (f '' s) (f '' t) ⊆ f '' symmDiff s t


theorem LowerSemicontinuous.comp_continuous {f : α → β} {g : ι → α}
    (hf : LowerSemicontinuous f) (hg : Continuous g) : LowerSemicontinuous fun x ↦ f (g x)

{α : Type u_1}
[TopologicalSpace α]
{β : Type u_2}
[Preorder β]
{ι : Type u_5}
[TopologicalSpace ι]
{f : α → β}
{g : ι → α}
(hf : LowerSemicontinuous f)
(hg : Continuous g)


@[simp]
theorem coe_sub : ⇑(s - t) = s - t

{Γ : Type u_1}
{R : Type u_2}
[PartialOrder Γ]
[AddCommGroup R]
{α : Type u_3}
{s t : HahnSeries.SummableFamily Γ R α}


theorem inv_comp (r : Rel α β) (s : Rel β γ) : inv (r • s) = inv s • inv r

{α : Type u_1}
{β : Type u_2}
{γ : Type u_3}
(r : Rel α β)
(s : Rel β γ)


/-- Typeclass for multiplicative actions on multiplicative structures. This generalizes
conjugation actions. -/
@[ext]
class MulDistribMulAction (M : Type*) (A : Type*) [Monoid M] [Monoid A] extends
  MulAction M A where
  /-- Distributivity of `•` across `*` -/
  smul_mul : ∀ (r : M) (x y : A), r • (x * y) = r • x * r • y
  /-- Multiplying `1` by a scalar gives `1` -/
  smul_one : ∀ r : M, r • (1 : A) = 1

{M : Type u_10}
{A : Type u_11}
[Monoid M]
[Monoid A]
[self : MulDistribMulAction M A]
(r : M)


@[simp]
theorem eqToHom_refl (X : C) (p : X = X) : eqToHom p = 𝟙 X

{C : Type u₁}
[CategoryTheory.Category.{v₁, u₁} C]
(X : C)
(p : X = X)

CategoryTheory.eqToHom p = CategoryTheory.CategoryStruct.id X


theorem exists_not_acc_lt_of_not_acc {a : α} {r} (h : ¬Acc r a) : ∃ b, ¬Acc r b ∧ r b a

{α : Type u_1}
{a : α}
{r : α → α → Prop}
(h : ¬Acc r a)


theorem borel_eq_generateFrom_Iic :
    borel α = MeasurableSpace.generateFrom (range Iic)

(α : Type u_1)
[TopologicalSpace α]
[SecondCountableTopology α]
[LinearOrder α]
[OrderTopology α]

borel α = MeasurableSpace.generateFrom (Set.range Set.Iic)


lemma isDiscrete_iff_isIso_counit_app {L : A ⥤ Sheaf J A} (adj : L ⊣ (sheafSections J A).obj ⟨t⟩)
    (F : Sheaf J A) :
    IsDiscrete J ht F ↔ IsIso (adj.counit.app F)

(J : CategoryTheory.GrothendieckTopology C)

(ht : CategoryTheory.Limits.IsTerminal t)

(adj : L ⊣ (CategoryTheory.sheafSections J A).obj (Opposite.op t))

CategoryTheory.Sheaf.IsDiscrete J ht F ↔ CategoryTheory.IsIso (adj.counit.app F)


lemma isSeparatedMap_iff_disjoint_nhds {f : X → Y} : IsSeparatedMap f ↔
    ∀ x₁ x₂, f x₁ = f x₂ → x₁ ≠ x₂ → Disjoint (𝓝 x₁) (𝓝 x₂)

{X : Type u_1}
{Y : Sort u_2}
[TopologicalSpace X]
{f : X → Y}

IsSeparatedMap f ↔ ∀ (x₁ x₂ : X), f x₁ = f x₂ → x₁ ≠ x₂ → Disjoint (𝓝 x₁) (𝓝 x₂)


@[simp]
theorem pairwise_bot_iff : s.Pairwise (⊥ : α → α → Prop) ↔ (s : Set α).Subsingleton


@[simp]
theorem iteratedFDerivWithin_zero_fun (hs : UniqueDiffOn 𝕜 s) (hx : x ∈ s) {i : ℕ} :
    iteratedFDerivWithin 𝕜 i (fun _ : E ↦ (0 : F)) s x = 0

{𝕜 : Type u_1}
[NontriviallyNormedField 𝕜]
{E : Type uE}
[NormedAddCommGroup E]
[NormedSpace 𝕜 E]
{F : Type uF}
[NormedAddCommGroup F]
[NormedSpace 𝕜 F]
{s : Set E}
{x : E}
(hs : UniqueDiffOn 𝕜 s)
(hx : x ∈ s)
{i : ℕ}

iteratedFDerivWithin 𝕜 i (fun x => 0) s x = 0


theorem pred_succ [NoMaxOrder α] (a : α) : pred (succ a) = a

{α : Type u_1}
[PartialOrder α]
[SuccOrder α]
[PredOrder α]
[NoMaxOrder α]
(a : α)


@[simp]
theorem nsmul_apply (r : ℕ) (f : NormedAddGroupHom V₁ V₂) (v : V₁) : (r • f) v = r • f v

{V₁ : Type u_2}
{V₂ : Type u_3}
[SeminormedAddCommGroup V₁]
[SeminormedAddCommGroup V₂]
(r : ℕ)
(f : NormedAddGroupHom V₁ V₂)
(v : V₁)


theorem Nonempty.div_zero (hs : s.Nonempty) : s / 0 = 0

{α : Type u_2}
[DecidableEq α]
[GroupWithZero α]
{s : Finset α}
(hs : s.Nonempty)


@[simp, norm_cast]
theorem coe_inf (f g : CauSeq α abs) : ⇑(f ⊓ g) = (f : ℕ → α) ⊓ g

{α : Type u_1}
[LinearOrderedField α]
(f g : CauSeq α abs)


theorem IsBigOWith.prod_left_same (hf : IsBigOWith c l f' k') (hg : IsBigOWith c l g' k') :
    IsBigOWith c l (fun x => (f' x, g' x)) k'

{α : Type u_1}
{E' : Type u_6}
{F' : Type u_7}
{G' : Type u_8}
[SeminormedAddCommGroup E']
[SeminormedAddCommGroup F']
[SeminormedAddCommGroup G']
{c : ℝ}
{f' : α → E'}
{g' : α → F'}
{k' : α → G'}
{l : Filter α}
(hf : Asymptotics.IsBigOWith c l f' k')
(hg : Asymptotics.IsBigOWith c l g' k')

Asymptotics.IsBigOWith c l (fun x => (f' x, g' x)) k'


@[simp, norm_cast]
theorem isBigO_ofReal_right {f : α → E} {g : α → ℝ} : f =O[l] (g · : α → ℂ) ↔ f =O[l] g

{α : Type u_1}
{E : Type u_2}
[Norm E]
{l : Filter α}
{f : α → E}
{g : α → ℝ}


theorem lt_of_add_right_lt {n m k : Nat} (h : n + k < m) : n < m


@[fun_prop]
theorem ContinuousOn.prod {f : α → β} {g : α → γ} {s : Set α} (hf : ContinuousOn f s)
    (hg : ContinuousOn g s) : ContinuousOn (fun x => (f x, g x)) s

{α : Type u_1}
{β : Type u_2}
{γ : Type u_3}
[TopologicalSpace α]
[TopologicalSpace β]
[TopologicalSpace γ]
{f : α → β}
{g : α → γ}
{s : Set α}
(hf : ContinuousOn f s)
(hg : ContinuousOn g s)


theorem sym_mul_self [Semiring α] [Invertible (2 : α)] (a : α) : sym (a * a) = sym a * sym a

{α : Type u_1}
[Semiring α]
[Invertible 2]
(a : α)

SymAlg.sym (a * a) = SymAlg.sym a * SymAlg.sym a


theorem sSameSide_smul_vsub_vadd_right {s : AffineSubspace R P} {x p₁ p₂ : P} (hx : x ∉ s)
    (hp₁ : p₁ ∈ s) (hp₂ : p₂ ∈ s) {t : R} (ht : 0 < t) : s.SSameSide x (t • (x -ᵥ p₁) +ᵥ p₂)

{R : Type u_1}
{V : Type u_2}
{P : Type u_4}
[LinearOrderedField R]
[AddCommGroup V]
[Module R V]
[AddTorsor V P]
{s : AffineSubspace R P}
{x p₁ p₂ : P}
(hx : x ∉ s)
(hp₁ : p₁ ∈ s)
(hp₂ : p₂ ∈ s)
{t : R}
(ht : 0 < t)


theorem coe_intCast (a : ℤ) : cast (a : ZMod n) = a % n


@[simp]
theorem map_comp {f : T ⟶ T'} {f' : T' ⟶ T''} {h : CostructuredArrow S T} :
    (map (f ≫ f')).obj h = (map f').obj ((map f).obj h)

{h : CategoryTheory.CostructuredArrow S T}

(CategoryTheory.CostructuredArrow.map (CategoryTheory.CategoryStruct.comp f f')).obj h =
  (CategoryTheory.CostructuredArrow.map f').obj ((CategoryTheory.CostructuredArrow.map f).obj h)


/-- Let the group `G` be the union of finitely many left cosets `g i • H i`.
Then at least one subgroup `H i` has finite index in `G`. -/
@[to_additive]
theorem exists_finiteIndex_of_leftCoset_cover : ∃ k ∈ s, (H k).FiniteIndex

(hcovers : ⋃ i ∈ s, g i +ᵥ ↑(H i) = Set.univ)


@[simp]
theorem apply_same : stdBasisMatrix i j c i j = c

{m : Type u_2}
{n : Type u_3}
{α : Type u_5}
[DecidableEq m]
[DecidableEq n]
[Semiring α]
(i : m)
(j : n)
(c : α)


theorem card_orbit (a : α) [Finite (orbit G a)] : ∃ n : ℕ, Nat.card (orbit G a) = p ^ n

{p : ℕ}
{G : Type u_1}
[Group G]
(hG : IsPGroup p G)
[hp : Fact (Nat.Prime p)]
{α : Type u_2}
[MulAction G α]
(a : α)
[Finite ↑(MulAction.orbit G a)]

∃ n, Nat.card ↑(MulAction.orbit G a) = p ^ n


@[simp]
theorem update_le_update_iff' : update x i a ≤ update x i b ↔ a ≤ b

{ι : Type u_1}
{π : ι → Type u_4}
[DecidableEq ι]
[(i : ι) → Preorder (π i)]
{x : (i : ι) → π i}
{i : ι}
{a b : π i}

Function.update x i a ≤ Function.update x i b ↔ a ≤ b


theorem assoc_aux_2 : (TensorProduct.assoc R A B C) ((1 ⊗ₜ[R] 1) ⊗ₜ[R] 1) = 1

{R : Type uR}
{A : Type uA}
{B : Type uB}
{C : Type uC}
[CommSemiring R]
[Semiring A]
[Algebra R A]
[Semiring B]
[Algebra R B]
[Semiring C]
[Algebra R C]


@[to_additive (attr := simp)]
theorem smul_mem_smul_set_iff : a • x ∈ a • s ↔ x ∈ s

{α : Type u_2}
{β : Type u_3}
[AddGroup α]
[AddAction α β]
{s : Set β}
{a : α}
{x : β}


lemma uncurry_obj_curry_obj_flip_flip (F₁ : B ⥤ C) (F₂ : D ⥤ E) (G : C × E ⥤ H) :
    uncurry.obj (F₂ ⋙ (F₁ ⋙ curry.obj G).flip).flip = (F₁.prod F₂) ⋙ G

{B : Type u₁}
[CategoryTheory.Category.{v₁, u₁} B]
{C : Type u₂}
[CategoryTheory.Category.{v₂, u₂} C]
{D : Type u₃}
[CategoryTheory.Category.{v₃, u₃} D]
{E : Type u₄}
[CategoryTheory.Category.{v₄, u₄} E]
{H : Type u₅}
[CategoryTheory.Category.{v₅, u₅} H]
(F₁ : CategoryTheory.Functor B C)
(F₂ : CategoryTheory.Functor D E)
(G : CategoryTheory.Functor (C × E) H)

CategoryTheory.uncurry.obj (F₂.comp (F₁.comp (CategoryTheory.curry.obj G)).flip).flip = (F₁.prod F₂).comp G


@[to_additive addCHaar_empty]
theorem chaar_empty (K₀ : PositiveCompacts G) : chaar K₀ ⊥ = 0

(K₀ : TopologicalSpace.PositiveCompacts G)

MeasureTheory.Measure.haar.addCHaar K₀ ⊥ = 0


protected lemma id {p : 𝒳 ⥤ 𝒮} {R : 𝒮} {a : 𝒳} (ha : p.obj a = R) : p.IsHomLift (𝟙 R) (𝟙 a)

{𝒮 : Type u₁}
{𝒳 : Type u₂}
[CategoryTheory.Category.{v₁, u₂} 𝒳]
[CategoryTheory.Category.{v₂, u₁} 𝒮]
{p : 𝒳 ⥤ 𝒮}
{R : 𝒮}
{a : 𝒳}
(ha : p.obj a = R)


/-- The supremum of two congruence relations equals the smallest congruence relation containing
    the supremum of the underlying binary operations. -/
theorem sup_def {c d : RingCon R} : c ⊔ d = ringConGen (⇑c ⊔ ⇑d)

{R : Type u_2}
[Add R]
[Mul R]
{c d : RingCon R}


@[simp]
theorem preinclusion_map₂ {a b : B} (f g : Discrete (Path.{v + 1} a b)) (η : f ⟶ g) :
    (preinclusion B).map₂ η = eqToHom (congr_arg _ (Discrete.ext _ _ (Discrete.eq_of_hom η)))

(f g : CategoryTheory.Discrete (Quiver.Path a b))

(CategoryTheory.FreeBicategory.preinclusion B).map₂ η = CategoryTheory.eqToHom ⋯


/-- A functor `F : C ⥤ D` is faithful if for each `X Y : C`, `F.map` is injective.

See <https://stacks.math.columbia.edu/tag/001C>.
-/
class Faithful (F : C ⥤ D) : Prop where
  /-- `F.map` is injective for each `X Y : C`. -/
  map_injective : ∀ {X Y : C}, Function.Injective (F.map : (X ⟶ Y) → (F.obj X ⟶ F.obj Y)) := by
    aesop_cat

{C : Type u₁}
[CategoryTheory.Category.{v₁, u₁} C]
{D : Type u₂}
[CategoryTheory.Category.{v₂, u₂} D]
{F : CategoryTheory.Functor C D}
[self : F.Faithful]
{X Y : C}


theorem div_lt_div_of_neg_of_lt (hc : c < 0) (h : b < a) : a / c < b / c

{α : Type u_2}
[LinearOrderedField α]
{a b c : α}
(hc : c < 0)
(h : b < a)


theorem comap_map_mk_uniformity : comap (Prod.map mk mk) (map (Prod.map mk mk) (𝓤 α)) = 𝓤 α

Filter.comap (Prod.map SeparationQuotient.mk SeparationQuotient.mk)
    (Filter.map (Prod.map SeparationQuotient.mk SeparationQuotient.mk) (𝓤 α)) =
  𝓤 α


theorem QuotientMap.image_connectedComponent [TopologicalSpace β] {f : α → β} (hf : QuotientMap f)
    (h_fibers : ∀ y : β, IsConnected (f ⁻¹' {y})) (a : α) :
    f '' connectedComponent a = connectedComponent (f a)

(h_fibers : ∀ (y : β), IsConnected (f ⁻¹' {y}))


@[simp]
theorem self_comp_ofInjective_symm {α β} {f : α → β} (hf : Injective f) :
    f ∘ (ofInjective f hf).symm = Subtype.val

{α : Sort u_1}
{β : Type u_2}
{f : α → β}
(hf : Function.Injective f)

f ∘ ⇑(Equiv.ofInjective f hf).symm = Subtype.val


@[simp]
theorem comapDomain_apply [∀ i, Zero (β i)] (h : κ → ι) (hh : Function.Injective h) (f : Π₀ i, β i)
    (k : κ) : comapDomain h hh f k = f (h k)

{ι : Type u}
{β : ι → Type v}
{κ : Type u_1}
[(i : ι) → Zero (β i)]
(h : κ → ι)
(hh : Function.Injective h)
(f : Π₀ (i : ι), β i)
(k : κ)

(DFinsupp.comapDomain h hh f) k = f (h k)


protected theorem IsTrail.rotate {u v : V} {c : G.Walk v v} (hc : c.IsTrail) (h : u ∈ c.support) :
    (c.rotate h).IsTrail

{V : Type u}
{G : SimpleGraph V}
[DecidableEq V]
{u v : V}
{c : G.Walk v v}
(hc : c.IsTrail)
(h : u ∈ c.support)


@[simp]
theorem skewProd_symm_apply (e : M ≃L[R] M₂) (e' : M₃ ≃L[R] M₄) (f : M →L[R] M₄) (x) :
    (e.skewProd e' f).symm x = (e.symm x.1, e'.symm (x.2 - f (e.symm x.1)))

{R : Type u_1}
[Semiring R]
{M : Type u_2}
[TopologicalSpace M]
[AddCommGroup M]
{M₂ : Type u_3}
[TopologicalSpace M₂]
[AddCommGroup M₂]
{M₃ : Type u_4}
[TopologicalSpace M₃]
[AddCommGroup M₃]
{M₄ : Type u_5}
[TopologicalSpace M₄]
[AddCommGroup M₄]
[Module R M]
[Module R M₂]
[Module R M₃]
[Module R M₄]
[TopologicalAddGroup M₄]
(e : M ≃L[R] M₂)
(e' : M₃ ≃L[R] M₄)
(f : M →L[R] M₄)
(x : M₂ × M₄)


theorem floor_eq_on_Ico' (n : ℤ) : ∀ a ∈ Set.Ico (n : α) (n + 1), (⌊a⌋ : α) = n

{α : Type u_2}
[LinearOrderedRing α]
[FloorRing α]
(n : ℤ)
(a : α)


@[to_additive]
protected theorem NeBot.smul : NeBot f → NeBot g → NeBot (f • g)

{α : Type u_2}
{β : Type u_3}
[VAdd α β]
{f : Filter α}
{g : Filter β}


theorem morphismRestrict_app {X Y : Scheme.{u}} (f : X ⟶ Y) (U : Y.Opens) (V : U.toScheme.Opens) :
    (f ∣_ U).app V = f.app (U.ι ''ᵁ V) ≫
        X.presheaf.map (eqToHom (image_morphismRestrict_preimage f U V)).op

{X Y : AlgebraicGeometry.Scheme}
(f : X ⟶ Y)
(U : Y.Opens)
(V : (↑U).Opens)

AlgebraicGeometry.Scheme.Hom.app (f ∣_ U) V =
  AlgebraicGeometry.Scheme.Hom.app f ((AlgebraicGeometry.Scheme.Hom.opensFunctor U.ι).obj V) ≫
    X.presheaf.map (CategoryTheory.eqToHom ⋯).op


theorem le_add_congr {l₁ l₂ m₁ m₂ : Language α} : l₁ ≤ m₁ → l₂ ≤ m₂ → l₁ + l₂ ≤ m₁ + m₂

{α : Type u_1}
{l₁ l₂ m₁ m₂ : Language α}

l₁ ≤ m₁ → l₂ ≤ m₂ → l₁ + l₂ ≤ m₁ + m₂


@[to_additive]
theorem iUnion_div (s : ι → Set α) (t : Set α) : (⋃ i, s i) / t = ⋃ i, s i / t

{α : Type u_2}
{ι : Sort u_5}
[Sub α]
(s : ι → Set α)
(t : Set α)


@[trans]
theorem AntisymmRel.trans [IsTrans α r] {a b c : α} (hab : AntisymmRel r a b)
    (hbc : AntisymmRel r b c) : AntisymmRel r a c

{α : Type u_1}
{r : α → α → Prop}
[IsTrans α r]
{a b c : α}
(hab : AntisymmRel r a b)
(hbc : AntisymmRel r b c)


/-- If a vector `v₂` is on the same ray as a nonzero vector `v₁`, then it is equal to `c • v₁` for
some nonnegative `c`. -/
theorem exists_nonneg_left (h : SameRay R x y) (hx : x ≠ 0) : ∃ r : R, 0 ≤ r ∧ r • x = y

{R : Type u_1}
[LinearOrderedField R]
{M : Type u_2}
[AddCommGroup M]
[Module R M]
{x y : M}
(h : SameRay R x y)
(hx : x ≠ 0)


theorem im_eq_conj_sub (z : K) : ↑(im z) = I * (conj z - z) / 2

↑(RCLike.im z) = RCLike.I * ((starRingEnd K) z - z) / 2


@[simp] theorem isLeft_map (f : α → β) (g : γ → δ) (x : α ⊕ γ) :
    isLeft (x.map f g) = isLeft x

{α : Type u_1}
{β : Type u_2}
{γ : Type u_3}
{δ : Type u_4}
(f : α → β)
(g : γ → δ)
(x : α ⊕ γ)


@[simp]
theorem descPochhammer_natDegree (n : ℕ) [NoZeroDivisors R] [Nontrivial R] :
    (descPochhammer R n).natDegree = n

(R : Type u)
[Ring R]
(n : ℕ)
[NoZeroDivisors R]
[Nontrivial R]


@[simp]
theorem toIso_inv {e : X ≃ Y} : e.toIso.inv = e.symm


@[fun_prop]
theorem differentiableAt_inv' {x : R} (hx : x ≠ 0) : DifferentiableAt 𝕜 Inv.inv x

{𝕜 : Type u_1}
[NontriviallyNormedField 𝕜]
{R : Type u_6}
[NormedDivisionRing R]
[NormedAlgebra 𝕜 R]
[CompleteSpace R]
{x : R}
(hx : x ≠ 0)


@[simp]
theorem lcm_eq_zero_iff {x y : R} : lcm x y = 0 ↔ x = 0 ∨ y = 0

{R : Type u}
[EuclideanDomain R]
[DecidableEq R]
{x y : R}

EuclideanDomain.lcm x y = 0 ↔ x = 0 ∨ y = 0


@[simp]
theorem preimage_const_add_Ioi : (fun x => a + x) ⁻¹' Ioi b = Ioi (b - a)

{α : Type u_1}
[OrderedAddCommGroup α]
(a b : α)

(fun x => a + x) ⁻¹' Set.Ioi b = Set.Ioi (b - a)


protected theorem isIrreducible (h : IsGenericPoint x S) : IsIrreducible S

{α : Type u_1}
[TopologicalSpace α]
{x : α}
{S : Set α}
(h : IsGenericPoint x S)


@[simp]
theorem mapRange.zeroHom_id : mapRange.zeroHom (ZeroHom.id M) = ZeroHom.id (α →₀ M)

Finsupp.mapRange.zeroHom (ZeroHom.id M) = ZeroHom.id (α →₀ M)


theorem exp_sum {α : Type*} (s : Finset α) (f : α → ℂ) :
    exp (∑ x ∈ s, f x) = ∏ x ∈ s, exp (f x)

{α : Type u_1}
(s : Finset α)
(f : α → ℂ)

Complex.exp (∑ x ∈ s, f x) = ∏ x ∈ s, Complex.exp (f x)


theorem pos_pow_of_pos {n : Nat} (m : Nat) (h : 0 < n) : 0 < n^m


theorem singleton_eq (c : Char) : singleton c = ⟨[c]⟩

String.singleton c = { data := c :: List.nil }


@[simp, norm_cast] lemma coe_copy (L : Sublattice α) (s : Set α) (hs) : L.copy s hs = s

{α : Type u_2}
[Lattice α]
(L : Sublattice α)
(s : Set α)
(hs : s = ↑L)


theorem isTheta_exp_arg_mul_im (hl : IsBoundedUnder (· ≤ ·) l fun x => |(g x).im|) :
    (fun x => Real.exp (arg (f x) * im (g x))) =Θ[l] fun _ => (1 : ℝ)

(hl : Filter.IsBoundedUnder (fun x x_1 => x ≤ x_1) l fun x => |(g x).im|)

(fun x => rexp ((f x).arg * (g x).im)) =Θ[l] fun x => 1


@[to_additive]
lemma eq_finset_univ [Fintype G] [DecidableEq G]
    {x y : G} (hx : x ≠ 1) (hy : y ≠ 1) (hxy : x ≠ y) : {x * y, x, y, (1 : G)} = Finset.univ

{G : Type u_1}
[Group G]
[IsKleinFour G]
[Fintype G]
[DecidableEq G]
{x y : G}
(hx : x ≠ 1)
(hy : y ≠ 1)
(hxy : x ≠ y)


@[simp]
theorem sSup_diff_singleton_bot (s : Set α) : sSup (s \ {⊥}) = sSup s

{α : Type u_1}
[CompleteLattice α]
(s : Set α)


theorem mem_iff_one_sub_mem {t : ℝ} : t ∈ I ↔ 1 - t ∈ I


@[to_additive]
theorem uniformContinuous_div : UniformContinuous fun p : α × α => p.1 / p.2

{α : Type u_1}
[UniformSpace α]
[Group α]
[UniformGroup α]


@[simp]
theorem matrixEquivTensor_apply (M : Matrix n n A) :
    matrixEquivTensor R A n M = ∑ p : n × n, M p.1 p.2 ⊗ₜ stdBasisMatrix p.1 p.2 1

(R : Type u)
[CommSemiring R]
(A : Type v)
[Semiring A]
[Algebra R A]
(n : Type w)
[Fintype n]
[DecidableEq n]
(M : Matrix n n A)

(matrixEquivTensor R A n) M = ∑ p : n × n, M p.1 p.2 ⊗ₜ[R] Matrix.stdBasisMatrix p.1 p.2 1


@[to_additive]
theorem NormedCommGroup.nhds_basis_norm_lt (x : E) :
    (𝓝 x).HasBasis (fun ε : ℝ => 0 < ε) fun ε => { y | ‖y / x‖ < ε }

{E : Type u_6}
[SeminormedAddGroup E]
(x : E)

(𝓝 x).HasBasis (fun ε => 0 < ε) fun ε => {y | ‖y - x‖ < ε}


theorem max_mem_image_coe {s : Finset α} (hs : s.Nonempty) :
    s.max ∈ (s.image (↑) : Finset (WithBot α))

{α : Type u_2}
[LinearOrder α]
{s : Finset α}
(hs : s.Nonempty)


theorem not_sOppSide_self (s : AffineSubspace R P) (x : P) : ¬s.SOppSide x x

{R : Type u_1}
{V : Type u_2}
{P : Type u_4}
[LinearOrderedField R]
[AddCommGroup V]
[Module R V]
[AddTorsor V P]
(s : AffineSubspace R P)
(x : P)


lemma of_comp (W₃ : MorphismProperty C₁)
    [L₁.IsLocalization W₁] [(L₁ ⋙ L₂).IsLocalization W₃]
    (hW₁₃ : W₁ ≤ W₃) (hW₂₃ : W₂ = W₃.map L₁) :
    L₂.IsLocalization W₂

(W₁ : CategoryTheory.MorphismProperty C₁)

(W₂ : CategoryTheory.MorphismProperty C₂)

(W₃ : CategoryTheory.MorphismProperty C₁)


theorem biSup_measure_Iic [Preorder α] {s : Set α} (hsc : s.Countable)
    (hst : ∀ x : α, ∃ y ∈ s, x ≤ y) (hdir : DirectedOn (· ≤ ·) s) :
    ⨆ x ∈ s, μ (Iic x) = μ univ

(hdir : DirectedOn (fun x x_1 => x ≤ x_1) s)


@[simp]
theorem coeff_one_reverse (f : R[X]) : coeff (reverse f) 1 = nextCoeff f

{R : Type u_1}
[Semiring R]
(f : Polynomial R)


theorem notConvergentSeq_antitone [Preorder ι] : Antitone (notConvergentSeq f g n)

{α : Type u_1}
{β : Type u_2}
{ι : Type u_3}
[MetricSpace β]
{n : ℕ}
{f : ι → α → β}
{g : α → β}
[Preorder ι]

Antitone (MeasureTheory.Egorov.notConvergentSeq f g n)


@[simp]
theorem noncommFoldr_coe (l : List α) (comm) (b : β) :
    noncommFoldr f (l : Multiset α) comm b = l.foldr f b

(f : α → β → β)

(comm : {x | x ∈ ↑l}.Pairwise fun x y => ∀ (b : β), f x (f y b) = f y (f x b))

Multiset.noncommFoldr f (↑l) comm b = List.foldr f b l


theorem rpow_eq_rpow_iff {x y : ℝ≥0} {z : ℝ} (hz : z ≠ 0) : x ^ z = y ^ z ↔ x = y


theorem prod_mem_curry {α β : Type*} {l : Filter α} {m : Filter β} {s : Set α} {t : Set β}
    (hs : s ∈ l) (ht : t ∈ m) : s ×ˢ t ∈ l.curry m

{α : Type u_4}
{β : Type u_5}
{l : Filter α}
{m : Filter β}
{s : Set α}
{t : Set β}
(hs : s ∈ l)
(ht : t ∈ m)


@[fun_prop]
theorem continuous_rpow_const {q : ℝ} (h : 0 ≤ q) : Continuous (fun x : ℝ => x ^ q)


theorem contained_C1 : contained (π (C1 C ho) (ord I · < o)) o

(ho : o < Ordinal.type fun x x_1 => x < x_1)

Profinite.NobelingProof.contained
  (Profinite.NobelingProof.π (Profinite.NobelingProof.C1 C ho) fun x => Profinite.NobelingProof.ord I x < o) o


lemma Homeomorph.measurableEmbedding (h : γ ≃ₜ γ₂) : MeasurableEmbedding h

{γ : Type u_3}
{γ₂ : Type u_4}
[TopologicalSpace γ]
[MeasurableSpace γ]
[BorelSpace γ]
[TopologicalSpace γ₂]
[MeasurableSpace γ₂]
[BorelSpace γ₂]
(h : γ ≃ₜ γ₂)


theorem natCast_def (n : ℕ) : (n : k[G]) = single (0 : G) (n : k)

{k : Type u₁}
{G : Type u₂}
[Semiring k]
[AddZeroClass G]
(n : ℕ)


@[simp]
lemma hom_inv_id_apply {X Y : FintypeCat} (f : X ≅ Y) (x : X) : f.inv (f.hom x) = x


theorem closedUnderRestriction' {G : StructureGroupoid H} [ClosedUnderRestriction G]
    {e : PartialHomeomorph H H} (he : e ∈ G) {s : Set H} (hs : IsOpen s) : e.restr s ∈ G

{H : Type u}
[TopologicalSpace H]
{G : StructureGroupoid H}
[ClosedUnderRestriction G]
{e : PartialHomeomorph H H}
(he : e ∈ G)
{s : Set H}
(hs : IsOpen s)


/-- The canonical continuous multilinear map from `E = Πᵢ Eᵢ` to `⨂[𝕜] i, Eᵢ`.
-/
@[simps!]
noncomputable def tprodL : ContinuousMultilinearMap 𝕜 E (⨂[𝕜] i, E i)

[(i : ι) → SeminormedAddCommGroup (E i)]

∀ (a : (i : ι) → E i), (PiTensorProduct.tprodL 𝕜) a = (PiTensorProduct.tprod 𝕜) a


@[to_additive]
theorem orderOf_dvd_natCard {G : Type*} [Group G] (x : G) : orderOf x ∣ Nat.card G


@[to_additive]
theorem eq_inv_of_mul_eq_one_left (h : a * b = 1) : a = b⁻¹

{G : Type u_1}
[SubtractionMonoid G]
{a b : G}
(h : a + b = 0)


@[simp]
theorem zeroIsoInitial_inv [HasInitial C] : zeroIsoInitial.inv = (0 : ⊥_ C ⟶ 0)


@[simp]
theorem add_fst (x y : X q) : (x + y).1 = x.1 + y.1


theorem le_sup {s : Multiset α} {a : α} (h : a ∈ s) : a ≤ s.sup

{α : Type u_1}
[SemilatticeSup α]
[OrderBot α]
{s : Multiset α}
{a : α}
(h : a ∈ s)


private lemma uniformity_eq_seminorm :
    𝓤 (E →SL[σ₁₂] F) = ⨅ r > 0, 𝓟 {f | ‖f.1 - f.2‖ < r}

{𝕜 : Type u_1}
{𝕜₂ : Type u_2}
{E : Type u_4}
{F : Type u_6}
[SeminormedAddCommGroup E]
[SeminormedAddCommGroup F]
[NontriviallyNormedField 𝕜]
[NontriviallyNormedField 𝕜₂]
[NormedSpace 𝕜 E]
[NormedSpace 𝕜₂ F]
{σ₁₂ : 𝕜 →+* 𝕜₂}
[RingHomIsometric σ₁₂]


@[simp]
theorem mk_coe (f : A →⋆ₙₐ[R] B) (h₁ h₂ h₃ h₄ h₅) :
    (⟨⟨⟨⟨f, h₁⟩, h₂, h₃⟩, h₄⟩, h₅⟩ : A →⋆ₙₐ[R] B) = f

(h₁ : ∀ (m : R) (x : A), f (m • x) = (MonoidHom.id R) m • f x)

(h₂ : { toFun := ⇑f, map_smul' := h₁ }.toFun 0 = 0)

(h₃ :
  ∀ (x y : A),
    { toFun := ⇑f, map_smul' := h₁ }.toFun (x + y) =
      { toFun := ⇑f, map_smul' := h₁ }.toFun x + { toFun := ⇑f, map_smul' := h₁ }.toFun y)

(h₄ :
  ∀ (x y : A),
    { toFun := ⇑f, map_smul' := h₁, map_zero' := h₂, map_add' := h₃ }.toFun (x * y) =
      { toFun := ⇑f, map_smul' := h₁, map_zero' := h₂, map_add' := h₃ }.toFun x *
        { toFun := ⇑f, map_smul' := h₁, map_zero' := h₂, map_add' := h₃ }.toFun y)

(h₅ :
  ∀ (a : A),
    { toFun := ⇑f, map_smul' := h₁, map_zero' := h₂, map_add' := h₃, map_mul' := h₄ }.toFun (star a) =
      star ({ toFun := ⇑f, map_smul' := h₁, map_zero' := h₂, map_add' := h₃, map_mul' := h₄ }.toFun a))

{ toFun := ⇑f, map_smul' := h₁, map_zero' := h₂, map_add' := h₃, map_mul' := h₄, map_star' := h₅ } = f


theorem volume_apply (I : Box ι) :
    (volume : Measure (ι → ℝ)).toBoxAdditive I = ∏ i, (I.upper i - I.lower i)

{ι : Type u_1}
[Fintype ι]
(I : BoxIntegral.Box ι)

MeasureTheory.volume.toBoxAdditive I = ∏ i : ι, (I.upper i - I.lower i)


theorem powersetCardAux_perm {n} {l₁ l₂ : List α} (p : l₁ ~ l₂) :
    powersetCardAux n l₁ ~ powersetCardAux n l₂

{α : Type u_1}
{n : ℕ}
{l₁ l₂ : List α}
(p : l₁.Perm l₂)

(Multiset.powersetCardAux n l₁).Perm (Multiset.powersetCardAux n l₂)


/-- The function `fun x ↦ x⁻¹` is not integrable on any interval `(a, +∞)`. -/
theorem not_IntegrableOn_Ioi_inv {a : ℝ} :
    ¬ IntegrableOn (·⁻¹) (Ioi a)

¬MeasureTheory.IntegrableOn (fun x => x⁻¹) (Set.Ioi a) MeasureTheory.volume


@[to_additive card_le_one_iff_eq_bot]
theorem card_le_one_iff_eq_bot [Finite H] : Nat.card H ≤ 1 ↔ H = ⊥

{G : Type u_1}
[Group G]
(H : Subgroup G)
[Finite ↥H]


lemma gammaPDF_eq (a r x : ℝ) :
    gammaPDF a r x = ENNReal.ofReal (if 0 ≤ x then
    r ^ a / (Gamma a) * x ^ (a-1) * exp (-(r * x)) else 0)

ProbabilityTheory.gammaPDF a r x =
  ENNReal.ofReal (if 0 ≤ x then r ^ a / Real.Gamma a * x ^ (a - 1) * rexp (-(r * x)) else 0)


@[simp]
theorem minpoly_toMatrix (b : Basis n R N) (f : N →ₗ[R] N) :
    minpoly R (toMatrix b b f) = minpoly R f

{R : Type u}
[CommRing R]
{n : Type v}
[DecidableEq n]
[Fintype n]
{N : Type w}
[AddCommGroup N]
[Module R N]
(b : Basis n R N)
(f : N →ₗ[R] N)

minpoly R ((LinearMap.toMatrix b b) f) = minpoly R f


theorem swapAt!_def (a : Array α) (i : Nat) (v : α) (h : i < a.size) :
    a.swapAt! i v = (a[i], a.set ⟨i, h⟩ v)

{α : Type u_1}
(a : Array α)
(i : Nat)
(v : α)
(h : i < a.size)


theorem diagonal_comp_stdBasis (w : n → R) (i : n) :
    (diagonal w).toLin'.comp (LinearMap.stdBasis R (fun _ : n => R) i) =
      w i • LinearMap.stdBasis R (fun _ : n => R) i

{n : Type u_1}
[Fintype n]
[DecidableEq n]
{R : Type v}
[CommSemiring R]
(w : n → R)
(i : n)

Matrix.toLin' (Matrix.diagonal w) ∘ₗ LinearMap.stdBasis R (fun x => R) i = w i • LinearMap.stdBasis R (fun x => R) i


@[to_additive]
theorem quasiMeasurePreserving_div_left_of_right_invariant [IsMulRightInvariant μ] (g : G) :
    QuasiMeasurePreserving (fun h : G => g / h) μ μ

{G : Type u_1}
[MeasurableSpace G]
[Group G]
[MeasurableMul₂ G]
(μ : MeasureTheory.Measure G)
[MeasureTheory.SFinite μ]
[MeasurableInv G]
[μ.IsMulRightInvariant]
(g : G)

MeasureTheory.Measure.QuasiMeasurePreserving (fun h => g / h) μ μ


/-- `X ⨿ -` has a monad structure. This is sometimes called the either monad. -/
@[simps!]
def coprodMonad : Monad C

(CategoryTheory.coprodMonad X).map g = CategoryTheory.Limits.coprod.map (CategoryTheory.CategoryStruct.id X) g


@[to_additive (attr := simp)]
theorem dist_div_eq_dist_mul_right (a b c : E) : dist a (b / c) = dist (a * c) b

{E : Type u_3}
[SeminormedAddGroup E]
(a b c : E)


theorem dist_inv_inv₀ {z w : α} (hz : z ≠ 0) (hw : w ≠ 0) :
    dist z⁻¹ w⁻¹ = dist z w / (‖z‖ * ‖w‖)

{α : Type u_1}
[NormedDivisionRing α]
{z w : α}
(hz : z ≠ 0)
(hw : w ≠ 0)


@[to_additive]
theorem multipliable_subtype_iff_mulIndicator {s : Set β} :
    Multipliable (f ∘ (↑) : s → α) ↔ Multipliable (s.mulIndicator f)

{α : Type u_1}
{β : Type u_2}
[CommMonoid α]
[TopologicalSpace α]
{f : β → α}
{s : Set β}

Multipliable (f ∘ Subtype.val) ↔ Multipliable (s.mulIndicator f)


@[to_additive Ico_add_Icc_subset]
theorem Ico_mul_Icc_subset' (a b c d : α) : Ico a b * Icc c d ⊆ Ico (a * c) (b * d)

[CovariantClass α α (fun x x_1 => x + x_1) fun x x_1 => x < x_1]

[CovariantClass α α (Function.swap HAdd.hAdd) LT.lt]

Set.Ico a b + Set.Icc c d ⊆ Set.Ico (a + c) (b + d)


theorem Filter.Tendsto.div_const {x : G₀} (hf : Tendsto f l (𝓝 x)) (y : G₀) :
    Tendsto (fun a => f a / y) l (𝓝 (x / y))

{α : Type u_1}
{G₀ : Type u_3}
[DivInvMonoid G₀]
[TopologicalSpace G₀]
[ContinuousMul G₀]
{f : α → G₀}
{l : Filter α}
{x : G₀}
(hf : Filter.Tendsto f l (𝓝 x))
(y : G₀)

Filter.Tendsto (fun a => f a / y) l (𝓝 (x / y))


@[ext]
lemma hom_ext (f g : X ⟶ Y) (h₁ : f.left = g.left) (h₂ : f.right = g.right) : f = g

{A : Type u₁}
[CategoryTheory.Category.{v₁, u₁} A]
{B : Type u₂}
[CategoryTheory.Category.{v₂, u₂} B]
{T : Type u₃}
[CategoryTheory.Category.{v₃, u₃} T]
{L : CategoryTheory.Functor A T}
{R : CategoryTheory.Functor B T}
{X Y : CategoryTheory.Comma L R}
(f g : X ⟶ Y)
(h₁ : f.left = g.left)
(h₂ : f.right = g.right)


theorem hasseDeriv_C (r : R) (hk : 0 < k) : hasseDeriv k (C r) = 0

{R : Type u_1}
[Semiring R]
(k : ℕ)
(r : R)
(hk : 0 < k)

(Polynomial.hasseDeriv k) (Polynomial.C r) = 0


@[simp 1100]
theorem modifyHead_modifyHead (l : List α) (f g : α → α) :
    (l.modifyHead f).modifyHead g = l.modifyHead (g ∘ f)

List.modifyHead g (List.modifyHead f l) = List.modifyHead (g ∘ f) l


/-- A convex set is preconnected. -/
protected theorem Convex.isPreconnected {s : Set E} (h : Convex ℝ s) : IsPreconnected s

{E : Type u_3}
[AddCommGroup E]
[Module ℝ E]
[TopologicalSpace E]
[TopologicalAddGroup E]
[ContinuousSMul ℝ E]
{s : Set E}
(h : Convex ℝ s)


@[to_additive (attr := simp)]
theorem traverse_pure (x) : traverse F (pure x : FreeMagma α) = pure <$> F x

{α β : Type u}
{m : Type u → Type u}
[Applicative m]
(F : α → m β)
(x : α)


@[simp] theorem row_zero [Zero α] : row ι (0 : n → α) = 0

{n : Type u_3}
{α : Type v}
{ι : Type u_6}
[Zero α]


@[simp]
theorem Colimit.w_apply' {F : J ⥤ Type v} {j j' : J} {x : F.obj j} (f : j ⟶ j') :
    colimit.ι F j' (F.map f x) = colimit.ι F j x

{J : Type v}
[CategoryTheory.Category.{w, v} J]
{F : J ⥤ Type v}
{j j' : J}
{x : F.obj j}
(f : j ⟶ j')

CategoryTheory.Limits.colimit.ι F j' (F.map f x) = CategoryTheory.Limits.colimit.ι F j x


theorem map_iterate (f : α → α) (a : α) : iterate f (f a) = map f (iterate f a)

Stream'.iterate f (f a) = Stream'.map f (Stream'.iterate f a)


/-- If every element belongs to at most `n` Finsets, then the sum of their sizes is at most `n`
times how many they are. -/
theorem sum_card_inter_le (h : ∀ a ∈ s, (B.filter (a ∈ ·)).card ≤ n) :
    (∑ t ∈ B, (s ∩ t).card) ≤ s.card * n

(h : ∀ a ∈ s, (Finset.filter (fun x => a ∈ x) B).card ≤ n)


theorem memberSubfamily_inter (a : α) (𝒜 ℬ : Finset (Finset α)) :
    (𝒜 ∩ ℬ).memberSubfamily a = 𝒜.memberSubfamily a ∩ ℬ.memberSubfamily a

{α : Type u_1}
[DecidableEq α]
(a : α)
(𝒜 ℬ : Finset (Finset α))

Finset.memberSubfamily a (𝒜 ∩ ℬ) = Finset.memberSubfamily a 𝒜 ∩ Finset.memberSubfamily a ℬ


@[to_additive]
theorem tprod_finset_bUnion_disjoint {ι} {s : Finset ι} {t : ι → Set β}
    (hd : (s : Set ι).Pairwise (Disjoint on t)) (hf : ∀ i ∈ s, Multipliable (f ∘ (↑) : t i → α)) :
    ∏' x : ⋃ i ∈ s, t i, f x = ∏ i ∈ s, ∏' x : t i, f x

(hf : ∀ i ∈ s, Summable (f ∘ Subtype.val))

∑' (x : ↑(⋃ i ∈ s, t i)), f ↑x = ∑ i ∈ s, ∑' (x : ↑(t i)), f ↑x


theorem DifferentiableWithinAt.hasGradientWithinAt (h : DifferentiableWithinAt 𝕜 f s x) :
    HasGradientWithinAt f (gradientWithin f s x) s x

{𝕜 : Type u_1}
{F : Type u_2}
[RCLike 𝕜]
[NormedAddCommGroup F]
[InnerProductSpace 𝕜 F]
[CompleteSpace F]
{f : F → 𝕜}
{x : F}
{s : Set F}
(h : DifferentiableWithinAt 𝕜 f s x)


/-- A Fraïssé class is a nonempty, isomorphism-invariant, essentially countable class of structures
satisfying the hereditary, joint embedding, and amalgamation properties. -/
class IsFraisse : Prop where
  is_nonempty : K.Nonempty
  FG : ∀ M : Bundled.{w} L.Structure, M ∈ K → Structure.FG L M
  is_equiv_invariant : ∀ M N : Bundled.{w} L.Structure, Nonempty (M ≃[L] N) → (M ∈ K ↔ N ∈ K)
  is_essentially_countable : (Quotient.mk' '' K).Countable
  hereditary : Hereditary K
  jointEmbedding : JointEmbedding K
  amalgamation : Amalgamation K

{K : Set (CategoryTheory.Bundled L.Structure)}

[self : FirstOrder.Language.IsFraisse K]


protected theorem coe_iSup_eq {ι : Sort*} {p : ι → Seminorm 𝕜 E} (hp : BddAbove (range p)) :
    ↑(⨆ i, p i) = ⨆ i, ((p i : Seminorm 𝕜 E) : E → ℝ)

{𝕜 : Type u_3}
{E : Type u_7}
[NormedField 𝕜]
[AddCommGroup E]
[Module 𝕜 E]
{ι : Sort u_13}
{p : ι → Seminorm 𝕜 E}
(hp : BddAbove (Set.range p))


@[simp]
theorem codRestrict_apply {f : M →ₗ[S] M} (h : IsProj m f) (x : M) : ↑(h.codRestrict x) = f x

{S : Type u_5}
[Semiring S]
{M : Type u_6}
[AddCommMonoid M]
[Module S M]
{m : Submodule S M}
{f : M →ₗ[S] M}
(h : LinearMap.IsProj m f)
(x : M)


@[simp]
theorem coeff_mul_X (p : R[X]) (n : ℕ) : coeff (p * X) (n + 1) = coeff p n

{R : Type u}
[Semiring R]
(p : R[X])
(n : ℕ)

(p * Polynomial.X).coeff (n + 1) = p.coeff n


@[simp] theorem comp_const (f : β → φ) (b : β) : f ∘ const α b = const α (f b)

{α : Sort u₁}
{β : Sort u₂}
{φ : Sort u₃}
(f : β → φ)
(b : β)

f ∘ Function.const α b = Function.const α (f b)


@[simp] theorem nth_true (n : ℕ) : nth (fun _ ↦ True) n = n


theorem zorn_preorder₀ (s : Set α)
    (ih : ∀ c ⊆ s, IsChain (· ≤ ·) c → ∃ ub ∈ s, ∀ z ∈ c, z ≤ ub) :
    ∃ m ∈ s, ∀ z ∈ s, m ≤ z → z ≤ m

(ih : ∀ c ⊆ s, IsChain (fun x x_1 => x ≤ x_1) c → ∃ ub ∈ s, ∀ z ∈ c, z ≤ ub)


/-- A variant of `Matrix.det_neg` with scalar multiplication by `Units ℤ` instead of multiplication
by `R`. -/
theorem det_neg_eq_smul (A : Matrix n n R) :
    det (-A) = (-1 : Units ℤ) ^ Fintype.card n • det A

{n : Type u_2}
[DecidableEq n]
[Fintype n]
{R : Type v}
[CommRing R]
(A : Matrix n n R)

(-A).det = (-1) ^ Fintype.card n • A.det


/-- **Maximum modulus principle** on a connected set. Let `U` be a (pre)connected open set in a
complex normed space. Let `f : E → F` be a function that is complex differentiable on `U`. Suppose
that `‖f x‖` takes its maximum value on `U` at `c ∈ U`. Then `‖f x‖ = ‖f c‖` for all `x ∈ U`. -/
theorem norm_eqOn_of_isPreconnected_of_isMaxOn {f : E → F} {U : Set E} {c : E}
    (hc : IsPreconnected U) (ho : IsOpen U) (hd : DifferentiableOn ℂ f U) (hcU : c ∈ U)
    (hm : IsMaxOn (norm ∘ f) U c) : EqOn (norm ∘ f) (const E ‖f c‖) U

{E : Type u}
[NormedAddCommGroup E]
[NormedSpace ℂ E]
{F : Type v}
[NormedAddCommGroup F]
[NormedSpace ℂ F]
{f : E → F}
{U : Set E}
{c : E}
(hc : IsPreconnected U)
(ho : IsOpen U)
(hd : DifferentiableOn ℂ f U)
(hcU : c ∈ U)
(hm : IsMaxOn (norm ∘ f) U c)

Set.EqOn (norm ∘ f) (Function.const E ‖f c‖) U


/-- Construct limit data for a product in `AddCommGrp`, using
`AddCommGrp.of (∀ j, F.obj j)`.
-/
@[simps]
def productLimitCone : Limits.LimitCone (Discrete.functor f)

(AddCommGrp.HasLimit.productLimitCone f).cone.π =
  CategoryTheory.Discrete.natTrans fun j => Pi.evalAddMonoidHom (fun j => ↑(f j)) j.as


theorem IsHermitian.conjTranspose {A : Matrix n n α} (h : A.IsHermitian) : Aᴴ.IsHermitian

{α : Type u_1}
{n : Type u_4}
[Star α]
{A : Matrix n n α}
(h : A.IsHermitian)


theorem univ_le_of_forall_fin_meas_le {μ : Measure α} (hm : m ≤ m0) [SigmaFinite (μ.trim hm)]
    (C : ℝ≥0∞) {f : Set α → ℝ≥0∞} (hf : ∀ s, MeasurableSet[m] s → μ s ≠ ∞ → f s ≤ C)
    (h_F_lim :
      ∀ S : ℕ → Set α, (∀ n, MeasurableSet[m] (S n)) → Monotone S → f (⋃ n, S n) ≤ ⨆ n, f (S n)) :
    f univ ≤ C

(hf : ∀ (s : Set α), MeasurableSet s → μ s ≠ ⊤ → f s ≤ C)

(h_F_lim : ∀ (S : ℕ → Set α), (∀ (n : ℕ), MeasurableSet (S n)) → Monotone S → f (⋃ n, S n) ≤ ⨆ n, f (S n))


@[simp]
protected theorem neg_smul : -s • t = -(s • t)

{α : Type u_2}
{β : Type u_3}
[Ring α]
[AddCommGroup β]
[Module α β]
(s : Set α)
(t : Set β)


@[simp]
theorem refl_apply (x : M) : refl L M x = x

{L : FirstOrder.Language}
{M : Type u_1}
[L.Structure M]
(x : M)

(FirstOrder.Language.ElementaryEmbedding.refl L M) x = x


/-- Mapping by the identity morphism is just the identity functor. -/
theorem mapId_eq (Y : T) : map (𝟙 Y) = 𝟭 _

{T : Type u₁}
[CategoryTheory.Category.{v₁, u₁} T]
(Y : T)

CategoryTheory.Over.map (CategoryTheory.CategoryStruct.id Y) = CategoryTheory.Functor.id (CategoryTheory.Over Y)


@[simp]
theorem toFinsupp_pow (a : R[X]) (n : ℕ) : (a ^ n).toFinsupp = a.toFinsupp ^ n

{R : Type u}
[Semiring R]
(a : R[X])
(n : ℕ)


/-- `yoneda'` induces an equivalence of category between `Type u` and
`SheafOfTypes typesGrothendieckTopology`. -/
@[simps!]
noncomputable def typeEquiv : Type u ≌ SheafOfTypes typesGrothendieckTopology

(X : CategoryTheory.SheafOfTypes CategoryTheory.typesGrothendieckTopology)

∀ (X_1 : Type uᵒᵖ) (a : X.val.obj X_1),
  (CategoryTheory.typeEquiv.counitIso.inv.app X).val.app X_1 a =
    (CategoryTheory.evalEquiv X.val ⋯ (Opposite.unop X_1)) a


@[simp]
theorem apply_one (x : R) : (1 : MulRingSeminorm R) x = if x = 0 then 0 else 1

{R : Type u_2}
[NonAssocRing R]
[DecidableEq R]
[NoZeroDivisors R]
[Nontrivial R]
(x : R)


theorem _root_.Ideal.stableFiltration_stable (I : Ideal R) (N : Submodule R M) :
    (I.stableFiltration N).Stable

{R M : Type u}
[CommRing R]
[AddCommGroup M]
[Module R M]
(I : Ideal R)
(N : Submodule R M)


@[simp]
theorem X_ne_zero [Nontrivial R] : (X : R[X]) ≠ 0

{R : Type u}
[Semiring R]
[Nontrivial R]


theorem mem_row_iff {μ : YoungDiagram} {i : ℕ} {c : ℕ × ℕ} : c ∈ μ.row i ↔ c ∈ μ ∧ c.fst = i


@[to_additive sum_pos_iff_of_nonneg]
lemma one_lt_prod_iff_of_one_le (hf : 1 ≤ f) : 1 < ∏ i, f i ↔ 1 < f

{ι : Type u_1}
{M : Type u_4}
[Fintype ι]
[OrderedCancelCommMonoid M]
{f : ι → M}
(hf : 1 ≤ f)


/-- Augment a simplicial object with an object. -/
@[simps]
def augment (X : SimplicialObject C) (X₀ : C) (f : X _[0] ⟶ X₀)
    (w : ∀ (i : SimplexCategory) (g₁ g₂ : ([0] : SimplexCategory) ⟶ i),
      X.map g₁.op ≫ f = X.map g₂.op ≫ f) :
    SimplicialObject.Augmented C

(f : X.obj (Opposite.op (SimplexCategory.mk 0)) ⟶ X₀)

(w : ∀ (i : SimplexCategory) (g₁ g₂ : SimplexCategory.mk 0 ⟶ i), X.map g₁.op ≫ f = X.map g₂.op ≫ f)

(X.augment X₀ f w).hom.app i = X.map ((SimplexCategory.mk 0).const (Opposite.unop i) 0).op ≫ f


@[simp]
theorem transitionMap_comp {m n k : ℕ} (hmn : m ≤ n) (hnk : n ≤ k) :
    transitionMap I M hmn ∘ₗ transitionMap I M hnk = transitionMap I M (hmn.trans hnk)

{R : Type u_1}
[CommRing R]
(I : Ideal R)
(M : Type u_2)
[AddCommGroup M]
[Module R M]
{m n k : ℕ}
(hmn : m ≤ n)
(hnk : n ≤ k)

AdicCompletion.transitionMap I M hmn ∘ₗ AdicCompletion.transitionMap I M hnk = AdicCompletion.transitionMap I M ⋯


/-- A monoid object internal to a monoidal category.

When the monoidal category is preadditive, this is also sometimes called an "algebra object".
-/
structure Mon_ where
  X : C
  one : 𝟙_ C ⟶ X
  mul : X ⊗ X ⟶ X
  one_mul : (one ▷ X) ≫ mul = (λ_ X).hom := by aesop_cat
  mul_one : (X ◁ one) ≫ mul = (ρ_ X).hom := by aesop_cat
  -- Obviously there is some flexibility stating this axiom.
  -- This one has left- and right-hand sides matching the statement of `Monoid.mul_assoc`,
  -- and chooses to place the associator on the right-hand side.
  -- The heuristic is that unitors and associators "don't have much weight".
  mul_assoc : (mul ▷ X) ≫ mul = (α_ X X X).hom ≫ (X ◁ mul) ≫ mul := by aesop_cat

{C : Type u₁}
[CategoryTheory.Category.{v₁, u₁} C]
[CategoryTheory.MonoidalCategory C]
(self : Mon_ C)

self.one ▷ self.X ≫ self.mul = (λ_ self.X).hom


theorem comp_yonedaPresheaf' : yonedaPresheaf F Y = F.op ⋙ yonedaPresheaf' Y

{C : Type u}
[CategoryTheory.Category.{v, u} C]
(F : C ⥤ TopCat)
(Y : Type w')
[TopologicalSpace Y]

ContinuousMap.yonedaPresheaf F Y = F.op ⋙ ContinuousMap.yonedaPresheaf' Y


@[to_additive (attr := simp)]
theorem finprod_false (f : False → M) : ∏ᶠ i, f i = 1

{M : Type u_2}
[AddCommMonoid M]
(f : False → M)


@[to_additive] lemma Monovary.div_right (h₁ : Monovary f g₁) (h₂ : Antivary f g₂) :
    Monovary f (g₁ / g₂)

{ι : Type u_1}
{α : Type u_2}
{β : Type u_3}
[OrderedAddCommGroup α]
[LinearOrderedAddCommGroup β]
{f : ι → α}
{g₁ g₂ : ι → β}
(h₁ : Monovary f g₁)
(h₂ : Antivary f g₂)


@[deprecated map_add (since := "2024-06-26")]
protected theorem map_add (r s : A) : φ (r + s) = φ r + φ s

{R : Type u}
{A : Type v}
{B : Type w}
[CommSemiring R]
[Semiring A]
[Semiring B]
[Algebra R A]
[Algebra R B]
(φ : A →ₐ[R] B)
(r s : A)


@[to_additive (attr := simp)]
theorem mk_le_mk {s t : Set G} (h_one) (h_mul) (h_inv) (h_one') (h_mul') (h_inv') :
    mk ⟨⟨s, h_one⟩, h_mul⟩ h_inv ≤ mk ⟨⟨t, h_one'⟩, h_mul'⟩ h_inv' ↔ s ⊆ t

(h_one : ∀ {a b : G}, a ∈ s → b ∈ s → a + b ∈ s)

(h_inv :
  ∀ {x : G},
    x ∈ { carrier := s, add_mem' := h_one, zero_mem' := h_mul }.carrier →
      -x ∈ { carrier := s, add_mem' := h_one, zero_mem' := h_mul }.carrier)

(h_one' : ∀ {a b : G}, a ∈ t → b ∈ t → a + b ∈ t)

(h_inv' :
  ∀ {x : G},
    x ∈ { carrier := t, add_mem' := h_one', zero_mem' := h_mul' }.carrier →
      -x ∈ { carrier := t, add_mem' := h_one', zero_mem' := h_mul' }.carrier)

{ carrier := s, add_mem' := h_one, zero_mem' := h_mul, neg_mem' := h_inv } ≤
    { carrier := t, add_mem' := h_one', zero_mem' := h_mul', neg_mem' := h_inv' } ↔
  s ⊆ t


lemma rpow_le_rpow_of_nonpos (hx : 0 < x) (hxy : x ≤ y) (hz : z ≤ 0) : y ^ z ≤ x ^ z

{x y z : ℝ}
(hx : 0 < x)
(hxy : x ≤ y)
(hz : z ≤ 0)


theorem contained_C' : contained (C' C ho) o

(ho : o < Ordinal.type fun x x_1 => x < x_1)

Profinite.NobelingProof.contained (Profinite.NobelingProof.C' C ho) o


lemma comp_assoc (f : α →*₀ β) (g : β →*₀ γ) (h : γ →*₀ δ) :
    (h.comp g).comp f = h.comp (g.comp f)

{α : Type u_2}
{β : Type u_3}
{γ : Type u_4}
{δ : Type u_5}
[MulZeroOneClass α]
[MulZeroOneClass β]
[MulZeroOneClass γ]
[MulZeroOneClass δ]
(f : α →*₀ β)
(g : β →*₀ γ)
(h : γ →*₀ δ)


@[to_additive]
theorem Multipliable.update (hf : Multipliable f) (b : β) [DecidableEq β] (a : α) :
    Multipliable (update f b a)

{α : Type u_1}
{β : Type u_2}
[CommGroup α]
[TopologicalSpace α]
[TopologicalGroup α]
{f : β → α}
(hf : Multipliable f)
(b : β)
[DecidableEq β]
(a : α)


theorem norm_coe_units (e : ℤˣ) : ‖(e : ℤ)‖ = 1


@[simp]
theorem closure_Ici (a : α) : closure (Ici a) = Ici a

{α : Type u}
[TopologicalSpace α]
[Preorder α]
[ClosedIciTopology α]
(a : α)


@[simp]
theorem realize_liftAt_one_self {n : ℕ} {φ : L.BoundedFormula α n} {v : α → M}
    {xs : Fin (n + 1) → M} : (φ.liftAt 1 n).Realize v xs ↔ φ.Realize v (xs ∘ castSucc)

{L : FirstOrder.Language}
{M : Type w}
[L.Structure M]
{α : Type u'}
{n : ℕ}
{φ : L.BoundedFormula α n}
{v : α → M}
{xs : Fin (n + 1) → M}

(FirstOrder.Language.BoundedFormula.liftAt 1 n φ).Realize v xs ↔ φ.Realize v (xs ∘ Fin.castSucc)


theorem UniformSpace.comap_inf {α γ} {u₁ u₂ : UniformSpace γ} {f : α → γ} :
    (u₁ ⊓ u₂).comap f = u₁.comap f ⊓ u₂.comap f

{α : Type u_2}
{γ : Type u_3}
{u₁ u₂ : UniformSpace γ}
{f : α → γ}

UniformSpace.comap f (u₁ ⊓ u₂) = UniformSpace.comap f u₁ ⊓ UniformSpace.comap f u₂


theorem volume_singleton {a : ℝ} : volume ({a} : Set ℝ) = 0


theorem _root_.Set.Finite.isSeparable {s : Set α} (hs : s.Finite) : IsSeparable s

{α : Type u}
[t : TopologicalSpace α]
{s : Set α}
(hs : s.Finite)


theorem surjective_onto_range : Surjective (rangeFactorization f)

{α : Type u_1}
{ι : Sort u_4}
{f : ι → α}


theorem simple_iff_isSimpleModule' (M : ModuleCat R) : Simple M ↔ IsSimpleModule R M

{R : Type u_1}
[Ring R]
(M : ModuleCat R)

CategoryTheory.Simple M ↔ IsSimpleModule R ↑M


@[simp]
theorem unop_le_unop_iff {S₁ S₂ : Subalgebra R Aᵐᵒᵖ} : S₁.unop ≤ S₂.unop ↔ S₁ ≤ S₂

{R : Type u_2}
{A : Type u_3}
[CommSemiring R]
[Semiring A]
[Algebra R A]
{S₁ S₂ : Subalgebra R Aᵐᵒᵖ}


protected theorem PartiallyWellOrderedOn.prod {t : Set β} (hs : PartiallyWellOrderedOn s r)
    (ht : PartiallyWellOrderedOn t r') :
    PartiallyWellOrderedOn (s ×ˢ t) fun x y : α × β => r x.1 y.1 ∧ r' x.2 y.2

{α : Type u_2}
{β : Type u_3}
{r : α → α → Prop}
{r' : β → β → Prop}
{s : Set α}
[IsRefl α r]
[IsTrans α r]
{t : Set β}
(hs : s.PartiallyWellOrderedOn r)
(ht : t.PartiallyWellOrderedOn r')

(s ×ˢ t).PartiallyWellOrderedOn fun x y => r x.1 y.1 ∧ r' x.2 y.2


/-- `CliffordAlgebra.reverseEquiv` as an `AlgEquiv` to the opposite algebra -/
@[simps! apply]
def reverseOpEquiv : CliffordAlgebra Q ≃ₐ[R] (CliffordAlgebra Q)ᵐᵒᵖ

{R : Type u_1}
[CommRing R]
{M : Type u_2}
[AddCommGroup M]
[Module R M]
{Q : QuadraticForm R M}
(a : CliffordAlgebra Q)

CliffordAlgebra.reverseOpEquiv a = CliffordAlgebra.reverseOp a


@[simp]
theorem gcd_one_right [NormalizedGCDMonoid α] (a : α) : gcd a 1 = 1

{α : Type u_1}
[CancelCommMonoidWithZero α]
[NormalizedGCDMonoid α]
(a : α)


theorem StronglyMeasurable.integral_kernel_prod_left ⦃f : β → α → E⦄
    (hf : StronglyMeasurable (uncurry f)) : StronglyMeasurable fun y => ∫ x, f x y ∂κ y

⦃f : β → α → E⦄

(hf : MeasureTheory.StronglyMeasurable (Function.uncurry f))

MeasureTheory.StronglyMeasurable fun y => ∫ (x : β), f x y ∂κ y


theorem restrict_withDensity' [SFinite μ] (s : Set α) (f : α → ℝ≥0∞) :
    (μ.withDensity f).restrict s = (μ.restrict s).withDensity f

{α : Type u_1}
{m0 : MeasurableSpace α}
{μ : MeasureTheory.Measure α}
[MeasureTheory.SFinite μ]
(s : Set α)
(f : α → ℝ≥0∞)


theorem isCoprime_mul_unit_left_right : IsCoprime y (x * z) ↔ IsCoprime y z

{R : Type u_1}
[CommSemiring R]
{x : R}
(hu : IsUnit x)
(y z : R)


theorem eq_pow_of_mul_eq_pow {a b c : Associates α} (ha : a ≠ 0) (hb : b ≠ 0)
    (hab : ∀ d, d ∣ a → d ∣ b → ¬Prime d) {k : ℕ} (h : a * b = c ^ k) :
    ∃ d : Associates α, a = d ^ k

(hab : ∀ (d : Associates α), d ∣ a → d ∣ b → ¬Prime d)


/-- A variant of `limitIsoFlipCompLim` where the arguments of `F` are flipped. -/
@[simps!]
def limitFlipIsoCompLim [HasLimitsOfShape J C] (F : K ⥤ J ⥤ C) : limit F.flip ≅ F ⋙ lim

(CategoryTheory.Limits.limitFlipIsoCompLim F).inv.app X =
  (CategoryTheory.Limits.HasLimit.isoOfNatIso (CategoryTheory.flipCompEvaluation F X)).inv ≫
    (CategoryTheory.Limits.limitObjIsoLimitCompEvaluation F.flip X).inv


@[continuity, fun_prop]
theorem continuous_sqrt : Continuous sqrt


theorem dom_of_le_of_dom {x y : PartENat} : x ≤ y → y.Dom → x.Dom


@[simp]
theorem isLittleO_norm_left : (fun x => ‖f' x‖) =o[l] g ↔ f' =o[l] g

{α : Type u_1}
{F : Type u_4}
{E' : Type u_6}
[Norm F]
[SeminormedAddCommGroup E']
{g : α → F}
{f' : α → E'}
{l : Filter α}


@[simp (high)]
theorem fork_π_app_walkingParallelPair_one :
    (fork F U).π.app WalkingParallelPair.one = res F U ≫ leftRes F U

{C : Type u}
[CategoryTheory.Category.{v, u} C]
[CategoryTheory.Limits.HasProducts C]
{X : TopCat}
(F : TopCat.Presheaf C X)
{ι : Type v'}
(U : ι → TopologicalSpace.Opens ↑X)

(TopCat.Presheaf.SheafConditionEqualizerProducts.fork F U).π.app CategoryTheory.Limits.WalkingParallelPair.one =
  TopCat.Presheaf.SheafConditionEqualizerProducts.res F U ≫ TopCat.Presheaf.SheafConditionEqualizerProducts.leftRes F U


@[to_additive]
theorem mul_mem_upperBounds_mul {s t : Set M} {a b : M} (ha : a ∈ upperBounds s)
    (hb : b ∈ upperBounds t) : a * b ∈ upperBounds (s * t)

[CovariantClass M M (fun x x_1 => x * x_1) fun x x_1 => x ≤ x_1]

[CovariantClass M M (Function.swap fun x x_1 => x * x_1) fun x x_1 => x ≤ x_1]


theorem emod_eq_zero_of_dvd : ∀ {a b : Int}, a ∣ b → b % a = 0


/-- The identity morphism on a bimodule object. -/
@[simps]
def id' (M : Bimod A B) : Hom M M

{C : Type u₁}
[CategoryTheory.Category.{v₁, u₁} C]
[CategoryTheory.MonoidalCategory C]
{A B : Mon_ C}
(M : Bimod A B)


private theorem coprime_sq_sub_sq_add_of_odd_even {m n : ℤ} (h : Int.gcd m n = 1) (hm : m % 2 = 1)
    (hn : n % 2 = 0) : Int.gcd (m ^ 2 - n ^ 2) (m ^ 2 + n ^ 2) = 1


theorem cons_append_stream (a : α) (l : List α) (s : Stream' α) :
    appendStream' (a::l) s = a::appendStream' l s

{α : Type u}
(a : α)
(l : List α)
(s : Stream' α)


@[simp]
lemma stableUnderSpecialization_compl_iff {s : Set X} :
    StableUnderSpecialization sᶜ ↔ StableUnderGeneralization s

{X : Type u_1}
[TopologicalSpace X]
{s : Set X}


/-- The product of the prime factors of `n` that are in `s` is an `s`-factored number. -/
lemma prod_mem_factoredNumbers (s : Finset ℕ) (n : ℕ) :
    (n.primeFactorsList.filter (· ∈ s)).prod ∈ factoredNumbers s

(List.filter (fun x => decide (x ∈ s)) n.primeFactorsList).prod ∈ Nat.factoredNumbers s


theorem isTopologicalBasis_of_subbasis_of_inter {r : Set (Set α)} (hsg : t = generateFrom r)
    (hsi : ∀ ⦃s⦄, s ∈ r → ∀ ⦃t⦄, t ∈ r → s ∩ t ∈ r) : IsTopologicalBasis (insert univ r)

(hsg : t = TopologicalSpace.generateFrom r)

(hsi : ∀ ⦃s : Set α⦄, s ∈ r → ∀ ⦃t : Set α⦄, t ∈ r → s ∩ t ∈ r)

TopologicalSpace.IsTopologicalBasis (insert Set.univ r)


/-- Generalized eigenvalues are actually just eigenvalues. -/
@[simp]
theorem hasGenEigenvalue_iff_hasEigenvalue {f : End R M} {μ : R} {k : ℕ} (hk : 0 < k) :
    f.HasGenEigenvalue μ k ↔ f.HasEigenvalue μ

{R : Type v}
{M : Type w}
[CommRing R]
[AddCommGroup M]
[Module R M]
{f : Module.End R M}
{μ : R}
{k : ℕ}
(hk : 0 < k)


theorem dual_injective : Function.Injective (dual : Matroid α → Matroid α)


protected theorem eq_inv_iff_mul_eq_one {φ ψ : MvPowerSeries σ k} (h : constantCoeff σ k ψ ≠ 0) :
    φ = ψ⁻¹ ↔ φ * ψ = 1

(h : (MvPowerSeries.constantCoeff σ k) ψ ≠ 0)

φ = ψ⁻¹ ↔ φ * ψ = 1


theorem rank_eq_four [StrongRankCondition R] : Module.rank R ℍ[R] = 4

{R : Type u_3}
[CommRing R]
[StrongRankCondition R]


theorem eval_divByMonic_pow_rootMultiplicity_ne_zero {p : R[X]} (a : R) (hp : p ≠ 0) :
    eval a (p /ₘ (X - C a) ^ rootMultiplicity a p) ≠ 0

{R : Type u}
[CommRing R]
{p : R[X]}
(a : R)
(hp : p ≠ 0)

Polynomial.eval a (p /ₘ (Polynomial.X - Polynomial.C a) ^ Polynomial.rootMultiplicity a p) ≠ 0


@[simp]
theorem inner_rightAngleRotation_right (x y : E) : ⟪x, J y⟫ = -ω x y

[Fact (FiniteDimensional.finrank ℝ E = 2)]

⟪x, o.rightAngleRotation y⟫_ℝ = -(o.areaForm x) y


theorem inv_def (e : P₁ ≃ᵃ[k] P₁) : e⁻¹ = e.symm

{k : Type u_1}
{P₁ : Type u_2}
{V₁ : Type u_6}
[Ring k]
[AddCommGroup V₁]
[Module k V₁]
[AffineSpace V₁ P₁]
(e : P₁ ≃ᵃ[k] P₁)


theorem dist_pow_map_zero_mul_translationNumber_le (n : ℕ) :
    dist ((f ^ n) 0) (n * f.translationNumber) ≤ 1

dist ((f ^ n) 0) (↑n * f.translationNumber) ≤ 1


theorem coe_injective : Function.Injective (Coe.coe : MvPolynomial σ R → MvPowerSeries σ R)

(σ : Type u_1)
(R : Type u_2)
[CommSemiring R]


lemma traceForm_eq_zero_of_mem_ker_of_mem_span_coroot {α : Weight K H L} {x y : H}
    (hx : x ∈ α.ker) (hy : y ∈ K ∙ coroot α) :
    traceForm K H L x y = 0

(hy : y ∈ Submodule.span K {LieAlgebra.IsKilling.coroot α})

((LieModule.traceForm K (↥H) L) x) y = 0


theorem mem_mul_span_singleton {x y : A} : x ∈ P * span R {y} ↔ ∃ z ∈ P, z * y = x

{R : Type u}
[CommSemiring R]
{A : Type v}
[Semiring A]
[Algebra R A]
{P : Submodule R A}
{x y : A}

x ∈ P * Submodule.span R {y} ↔ ∃ z ∈ P, z * y = x


theorem adjunction_homEquiv (X : Scheme) (R : CommRingCatᵒᵖ) :
    ΓSpec.adjunction.homEquiv X R = locallyRingedSpaceAdjunction.homEquiv X.1 R

(X : AlgebraicGeometry.Scheme)
(R : CommRingCatᵒᵖ)

AlgebraicGeometry.ΓSpec.adjunction.homEquiv X R =
  AlgebraicGeometry.ΓSpec.locallyRingedSpaceAdjunction.homEquiv X.toLocallyRingedSpace R


lemma quarter_mem_preCantorSet (n : ℕ) : 1/4 ∈ preCantorSet n


@[to_additive]
theorem Multipliable.tendsto_atTop_one {f : ℕ → G} (hf : Multipliable f) :
    Tendsto f atTop (𝓝 1)

{G : Type u_2}
[AddCommGroup G]
[TopologicalSpace G]
[TopologicalAddGroup G]
{f : ℕ → G}
(hf : Summable f)


theorem Ideal.exists_minimalPrimes_le [J.IsPrime] (e : I ≤ J) : ∃ p ∈ I.minimalPrimes, p ≤ J

{R : Type u_1}
[CommSemiring R]
{I J : Ideal R}
[J.IsPrime]
(e : I ≤ J)


lemma embedding_iff_inducing [TopologicalSpace Y] [T0Space X] {f : X → Y} :
    Embedding f ↔ Inducing f

{X : Type u_1}
{Y : Type u_2}
[TopologicalSpace X]
[TopologicalSpace Y]
[T0Space X]
{f : X → Y}


@[simp]
theorem coe_trans : (f.trans g : C(α, γ)) = (g : C(β, γ)).comp f

{α : Type u_1}
{β : Type u_2}
{γ : Type u_3}
[TopologicalSpace α]
[TopologicalSpace β]
[TopologicalSpace γ]
(f : α ≃ₜ β)
(g : β ≃ₜ γ)

(f.trans g).toContinuousMap = g.toContinuousMap.comp f.toContinuousMap


/-- The identity isometry from a quadratic form to itself. -/
@[simps!]
def id (Q : QuadraticMap R M N) : Q →qᵢ Q

{R : Type u_2}
{M : Type u_3}
{N : Type u_8}
[CommSemiring R]
[AddCommMonoid M]
[AddCommMonoid N]
[Module R M]
[Module R N]
(Q : QuadraticMap R M N)
(a : M)


@[simp] theorem enumFrom_cons : (a::as).enumFrom i = (i, a) :: as.enumFrom (i+1)

∀ {α : Type u_1} {a : α} {as : List α} {i : Nat},
  List.enumFrom i (a :: as) = { fst := i, snd := a } :: List.enumFrom (i + 1) as


theorem exists_coeff_ne_zero_mem_comap_of_non_zero_divisor_root_mem {r : S}
    (r_non_zero_divisor : ∀ {x}, x * r = 0 → x = 0) (hr : r ∈ I) {p : R[X]} :
    p ≠ 0 → p.eval₂ f r = 0 → ∃ i, p.coeff i ≠ 0 ∧ p.coeff i ∈ I.comap f

(r_non_zero_divisor : ∀ {x : S}, x * r = 0 → x = 0)

p ≠ 0 → Polynomial.eval₂ f r p = 0 → ∃ i, p.coeff i ≠ 0 ∧ p.coeff i ∈ Ideal.comap f I


@[simp]
theorem recTopCoe_zero {C : ℕ∞ → Sort*} (d : C ⊤) (f : ∀ a : ℕ, C a) : @recTopCoe C d f 0 = f 0

{C : ℕ∞ → Sort u_1}
(d : C ⊤)
(f : (a : ℕ) → C ↑a)


@[to_additive]
theorem mul_singleton (a : α) : s * {a} = s.image (· * a)

{α : Type u_2}
[DecidableEq α]
[Mul α]
{s : Finset α}
(a : α)

s * {a} = Finset.image (fun x => x * a) s


@[simp]
theorem restrict_extend_compl_range (f : α → β) (g : α → γ) (g' : β → γ) :
    (range f)ᶜ.restrict (extend f g g') = g' ∘ Subtype.val

{α : Type u_1}
{β : Type u_2}
{γ : Type u_3}
(f : α → β)
(g : α → γ)
(g' : β → γ)

(Set.range f)ᶜ.restrict (Function.extend f g g') = g' ∘ Subtype.val


@[to_additive (attr := simp)]
theorem inv_pure : (pure a : Filter α)⁻¹ = pure a⁻¹


protected theorem dist_nonneg (x y : ∀ n, E n) : 0 ≤ dist x y

{E : ℕ → Type u_1}
(x y : (n : ℕ) → E n)


@[simp]
theorem preimage_Ici : ((↑) : ℤ → α) ⁻¹' Set.Ici a = Set.Ici ⌈a⌉

{α : Type u_2}
[LinearOrderedRing α]
[FloorRing α]
{a : α}


theorem succ_mul_catalan_eq_centralBinom (n : ℕ) : (n + 1) * catalan n = n.centralBinom


theorem not_isRightDescent_iff {w : W} {i : B} :
    ¬cs.IsRightDescent w i ↔ ℓ (w * s i) = ℓ w + 1

{B : Type u_1}
{W : Type u_2}
[Group W]
{M : CoxeterMatrix B}
(cs : CoxeterSystem M W)
{w : W}
{i : B}

¬cs.IsRightDescent w i ↔ cs.length (w * cs.simple i) = cs.length w + 1


@[simp, reassoc]
theorem t'_fst_fst_fst (i j k : 𝒰.J) :
    t' 𝒰 f g i j k ≫ pullback.fst _ _ ≫ pullback.fst _ _ ≫ pullback.fst _ _ =
      pullback.fst _ _ ≫ pullback.snd _ _

[∀ (i : 𝒰.J), CategoryTheory.Limits.HasPullback (𝒰.map i ≫ f) g]

AlgebraicGeometry.Scheme.Pullback.t' 𝒰 f g i j k ≫
    CategoryTheory.Limits.pullback.fst (AlgebraicGeometry.Scheme.Pullback.fV 𝒰 f g j k)
        (AlgebraicGeometry.Scheme.Pullback.fV 𝒰 f g j i) ≫
      CategoryTheory.Limits.pullback.fst (CategoryTheory.Limits.pullback.fst (𝒰.map j ≫ f) g ≫ 𝒰.map j) (𝒰.map k) ≫
        CategoryTheory.Limits.pullback.fst (𝒰.map j ≫ f) g =
  CategoryTheory.Limits.pullback.fst (AlgebraicGeometry.Scheme.Pullback.fV 𝒰 f g i j)
      (AlgebraicGeometry.Scheme.Pullback.fV 𝒰 f g i k) ≫
    CategoryTheory.Limits.pullback.snd (CategoryTheory.Limits.pullback.fst (𝒰.map i ≫ f) g ≫ 𝒰.map i) (𝒰.map j)


@[simp]
theorem mem_toSubring (x : K) : x ∈ A.toSubring ↔ x ∈ A

{K : Type u}
[Field K]
(A : ValuationSubring K)
(x : K)


/-- Closure of a non-unital subsemiring `S` equals `S`. -/
theorem closure_eq (s : NonUnitalSubsemiring R) : closure (s : Set R) = s

{R : Type u}
[NonUnitalNonAssocSemiring R]
(s : NonUnitalSubsemiring R)


@[to_additive]
theorem MonoidHomClass.antilipschitz_of_bound [MonoidHomClass 𝓕 E F] (f : 𝓕) {K : ℝ≥0}
    (h : ∀ x, ‖x‖ ≤ K * ‖f x‖) : AntilipschitzWith K f

{𝓕 : Type u_1}
{E : Type u_3}
{F : Type u_4}
[SeminormedAddGroup E]
[SeminormedAddGroup F]
[FunLike 𝓕 E F]
[AddMonoidHomClass 𝓕 E F]
(f : 𝓕)
{K : ℝ≥0}
(h : ∀ (x : E), ‖x‖ ≤ ↑K * ‖f x‖)


@[simp] theorem head_replicate (n : ℕ) (a : α) (h) : head (replicate n a) h = a

{α : Type u}
(n : ℕ)
(a : α)
(h : List.replicate n a ≠ [])


@[simp] lemma coe_toLinearMap_flip : e.flip = (↑e : N →ₗ[R] Dual R M).flip

{R : Type u_1}
{M : Type u_2}
{N : Type u_3}
[CommRing R]
[AddCommGroup M]
[Module R M]
[AddCommGroup N]
[Module R N]
[Module.IsReflexive R M]
(e : N ≃ₗ[R] Module.Dual R M)


@[to_additive (attr := simp)]
theorem coe_inf (p p' : Subsemigroup M) : ((p ⊓ p' : Subsemigroup M) : Set M) = (p : Set M) ∩ p'

{M : Type u_1}
[Mul M]
(p p' : Subsemigroup M)


@[simp]
theorem coeSubmodule_comap :
    (N'.comap f : Submodule R M) = (N' : Submodule R M').comap (f : M →ₗ[R] M')

{R : Type u}
{L : Type v}
{M : Type w}
{M' : Type w₁}
[CommRing R]
[LieRing L]
[AddCommGroup M]
[Module R M]
[LieRingModule L M]
[AddCommGroup M']
[Module R M']
[LieRingModule L M']
(f : M →ₗ⁅R,L⁆ M')
(N' : LieSubmodule R L M')

↑(LieSubmodule.comap f N') = Submodule.comap ↑f ↑N'


/-- Constant polynomials are weighted homogeneous of degree 0. -/
theorem isWeightedHomogeneous_C (w : σ → M) (r : R) :
    IsWeightedHomogeneous w (C r : MvPolynomial σ R) 0

{R : Type u_1}
{M : Type u_2}
[CommSemiring R]
{σ : Type u_3}
[AddCommMonoid M]
(w : σ → M)
(r : R)

MvPolynomial.IsWeightedHomogeneous w (MvPolynomial.C r) 0


theorem eq_false_iff : {b : Bool} → b = false ↔ b ≠ true


theorem Ico_subset_Icc_union_Ioo : Ico a c ⊆ Icc a b ∪ Ioo b c

{α : Type u_1}
[LinearOrder α]
{a b c : α}


/-- The `s -ᵥ s` lies within the `vectorSpan k s`. -/
theorem vsub_set_subset_vectorSpan (s : Set P) : s -ᵥ s ⊆ ↑(vectorSpan k s)

(k : Type u_1)
{V : Type u_2}
{P : Type u_3}
[Ring k]
[AddCommGroup V]
[Module k V]
[AffineSpace V P]
(s : Set P)


@[simp, reassoc]
lemma comp_hom₃ {X Y Z : Triangle C} (f : X ⟶ Y) (g : Y ⟶ Z) :
    (f ≫ g).hom₃ = f.hom₃ ≫ g.hom₃

{X Y Z : CategoryTheory.Pretriangulated.Triangle C}


@[simp] theorem zero_imJ : (0 : ℍ[R,c₁,c₂]).imJ = 0


theorem NodupKeys.kerase (a : α) : NodupKeys l → (kerase a l).NodupKeys

{α : Type u}
{β : α → Type v}
{l : List (Sigma β)}
[DecidableEq α]
(a : α)

l.NodupKeys → (List.kerase a l).NodupKeys


lemma hurwitzZetaOdd_neg (a : UnitAddCircle) (s : ℂ) :
    hurwitzZetaOdd (-a) s = -hurwitzZetaOdd a s

HurwitzZeta.hurwitzZetaOdd (-a) s = -HurwitzZeta.hurwitzZetaOdd a s


@[simp]
theorem apply_zero (F : Homotopy f₀ f₁) (x : X) : F (0, x) = f₀ x

{X : Type u}
{Y : Type v}
[TopologicalSpace X]
[TopologicalSpace Y]
{f₀ f₁ : C(X, Y)}
(F : f₀.Homotopy f₁)
(x : X)


theorem prod_range_range_eq {m₁ : α → γ} {m₂ : β → δ} :
    range m₁ ×ˢ range m₂ = range fun p : α × β => (m₁ p.1, m₂ p.2)

{α : Type u_1}
{β : Type u_2}
{γ : Type u_3}
{δ : Type u_4}
{m₁ : α → γ}
{m₂ : β → δ}

Set.range m₁ ×ˢ Set.range m₂ = Set.range fun p => (m₁ p.1, m₂ p.2)


theorem comp_differentiableWithinAt_iff {f : G → E} {s : Set G} {x : G} :
    DifferentiableWithinAt 𝕜 (iso ∘ f) s x ↔ DifferentiableWithinAt 𝕜 f s x

{𝕜 : Type u_1}
[NontriviallyNormedField 𝕜]
{E : Type u_2}
[NormedAddCommGroup E]
[NormedSpace 𝕜 E]
{F : Type u_3}
[NormedAddCommGroup F]
[NormedSpace 𝕜 F]
{G : Type u_4}
[NormedAddCommGroup G]
[NormedSpace 𝕜 G]
(iso : E ≃L[𝕜] F)
{f : G → E}
{s : Set G}
{x : G}

DifferentiableWithinAt 𝕜 (⇑iso ∘ f) s x ↔ DifferentiableWithinAt 𝕜 f s x


@[to_additive (attr := simp)]
theorem lift_eq (x : M) : f.lift hg (f.toMap x) = g x

{M : Type u_1}
[AddCommMonoid M]
{S : AddSubmonoid M}
{N : Type u_2}
[AddCommMonoid N]
{P : Type u_3}
[AddCommMonoid P]
(f : S.LocalizationMap N)
{g : M →+ P}
(hg : ∀ (y : ↥S), IsAddUnit (g ↑y))
(x : M)


theorem sum_schlomilch_le' (hf : ∀ ⦃m n⦄, 1 < m → m ≤ n → f n ≤ f m) (h_pos : ∀ n, 0 < u n)
    (hu : Monotone u) (n : ℕ) :
    (∑ k ∈ range n, (u (k + 1) - u k) • f (u (k + 1))) ≤ ∑ k ∈ Ico (u 0 + 1) (u n + 1), f k

(hf : ∀ ⦃m n : ℕ⦄, 1 < m → m ≤ n → f n ≤ f m)

∑ k ∈ Finset.range n, (u (k + 1) - u k) • f (u (k + 1)) ≤ ∑ k ∈ Finset.Ico (u 0 + 1) (u n + 1), f k


@[to_additive]
theorem op_surjective : Surjective (op : α → αᵐᵒᵖ)


theorem mem_segment_iff_sameRay : x ∈ [y -[𝕜] z] ↔ SameRay 𝕜 (x - y) (z - x)

{𝕜 : Type u_1}
{E : Type u_2}
[LinearOrderedField 𝕜]
[AddCommGroup E]
[Module 𝕜 E]
{x y z : E}

x ∈ [y-[𝕜]z] ↔ SameRay 𝕜 (x - y) (z - x)


lemma isBounded_mul [Bornology R] [Mul R] [BoundedMul R] {s t : Set R}
    (hs : Bornology.IsBounded s) (ht : Bornology.IsBounded t) :
    Bornology.IsBounded (s * t)

{R : Type u_1}
[Bornology R]
[Mul R]
[BoundedMul R]
{s t : Set R}
(hs : Bornology.IsBounded s)
(ht : Bornology.IsBounded t)


theorem filterMap_eq_bind_toList (f : α → Option β) (l : List α) :
    l.filterMap f = l.bind fun a ↦ (f a).toList

{α : Type u}
{β : Type v}
(f : α → Option β)
(l : List α)

List.filterMap f l = l.bind fun a => (f a).toList


@[to_additive]
theorem mem_closure_iff_nhds_one {x : G} {s : Set G} :
    x ∈ closure s ↔ ∀ U ∈ (𝓝 1 : Filter G), ∃ y ∈ s, y / x ∈ U

{G : Type w}
[TopologicalSpace G]
[Group G]
[TopologicalGroup G]
{x : G}
{s : Set G}

x ∈ closure s ↔ ∀ U ∈ 𝓝 1, ∃ y ∈ s, y / x ∈ U


theorem Matrix.toLinAlgEquiv'_one : Matrix.toLinAlgEquiv' (1 : Matrix n n R) = LinearMap.id

{R : Type u_1}
[CommSemiring R]
{n : Type u_5}
[DecidableEq n]
[Fintype n]


/-- `eval₂AddMonoidHom (f : R →+* S) (x : S)` is the `AddMonoidHom` from
`R[X]` to `S` obtained by evaluating the pushforward of `p` along `f` at `x`. -/
@[simps]
def eval₂AddMonoidHom : R[X] →+ S

{R : Type u}
{S : Type v}
[Semiring R]
[Semiring S]
(f : R →+* S)
(x : S)
(p : R[X])

(Polynomial.eval₂AddMonoidHom f x) p = Polynomial.eval₂ f x p


/-- A square has a lifting if and only if its (right) adjoint square has a lifting. -/
theorem right_adjoint_hasLift_iff : HasLift (sq.right_adjoint adj) ↔ HasLift sq

(sq : CategoryTheory.CommSq u (G.map i) p v)


@[simp]
theorem val_neg' {n : ZMod 0} : (-n).val = n.val


@[simp] theorem right_mem_perpBisector : p₂ ∈ perpBisector p₁ p₂ ↔ p₁ = p₂

{V : Type u_1}
{P : Type u_2}
[NormedAddCommGroup V]
[InnerProductSpace ℝ V]
[MetricSpace P]
[NormedAddTorsor V P]
{p₁ p₂ : P}

p₂ ∈ AffineSubspace.perpBisector p₁ p₂ ↔ p₁ = p₂


lemma SMulPosMono.lift [SMulPosMono α γ]
    (hf : ∀ {b₁ b₂}, f b₁ ≤ f b₂ ↔ b₁ ≤ b₂)
    (smul : ∀ (a : α) b, f (a • b) = a • f b)
    (zero : f 0 = 0) : SMulPosMono α β

(hf : ∀ {b₁ b₂ : β}, f b₁ ≤ f b₂ ↔ b₁ ≤ b₂)

(smul : ∀ (a : α) (b : β), f (a • b) = a • f b)


theorem le_mul_right {a b : Cardinal} (h : b ≠ 0) : a ≤ a * b


lemma natCast_succ (n : ℕ) : (Nat.succ n : ℤ) = Int.succ n


protected theorem mul_sub (a b c : Int) : a * (b - c) = a * b - a * c


{α : Type u_1}
{m : MeasurableSpace α}
{μ : MeasureTheory.Measure α}


theorem not_exists_not {p : α → Prop} : (¬∃ x, ¬p x) ↔ ∀ x, p x


theorem mem_factors'_iff_dvd {a p : α} (ha0 : a ≠ 0) (hp : Irreducible p) :
    Subtype.mk (Associates.mk p) (irreducible_mk.2 hp) ∈ factors' a ↔ p ∣ a

{α : Type u_1}
[CancelCommMonoidWithZero α]
[UniqueFactorizationMonoid α]
{a p : α}
(ha0 : a ≠ 0)
(hp : Irreducible p)

⟨Associates.mk p, ⋯⟩ ∈ Associates.factors' a ↔ p ∣ a


@[simp]
theorem toCon_coe_eq_coe : (c.toCon : R → R → Prop) = c

{R : Type u_2}
[Add R]
[Mul R]
(c : RingCon R)


theorem mapRange.zeroHom_comp (f : ZeroHom N P) (f₂ : ZeroHom M N) :
    (mapRange.zeroHom (f.comp f₂) : ZeroHom (α →₀ _) _) =
      (mapRange.zeroHom f).comp (mapRange.zeroHom f₂)

{α : Type u_1}
{M : Type u_5}
{N : Type u_7}
{P : Type u_8}
[Zero M]
[Zero N]
[Zero P]
(f : ZeroHom N P)
(f₂ : ZeroHom M N)

Finsupp.mapRange.zeroHom (f.comp f₂) = (Finsupp.mapRange.zeroHom f).comp (Finsupp.mapRange.zeroHom f₂)


@[simp]
theorem toQuadraticMap_list_sum (B : List (BilinMap R M N)) :
    B.sum.toQuadraticMap = (B.map toQuadraticMap).sum

{R : Type u_3}
{M : Type u_4}
{N : Type u_5}
[CommSemiring R]
[AddCommMonoid M]
[Module R M]
[AddCommMonoid N]
[Module R N]
(B : List (LinearMap.BilinMap R M N))

B.sum.toQuadraticMap = (List.map LinearMap.BilinMap.toQuadraticMap B).sum


theorem degree_mul_C (a0 : a ≠ 0) : (p * C a).degree = p.degree

{R : Type u}
[Semiring R]
[NoZeroDivisors R]
{p : R[X]}
{a : R}
(a0 : a ≠ 0)


@[norm_cast]
theorem coe_prod {ι : Type*} {s : Finset ι} (a : ι → R) :
    (↑(∏ i ∈ s, a i : R) : A) = ∏ i ∈ s, (↑(a i) : A)

{R : Type u_1}
{A : Type u_2}
[CommSemiring R]
[CommSemiring A]
[Algebra R A]
{ι : Type u_3}
{s : Finset ι}
(a : ι → R)


/-- An ordered variant of `primeSpectrumEquiv`. -/
@[simps!]
def primeSpectrumOrderEquiv : (PrimeSpectrum A)ᵒᵈ ≃o {S // A ≤ S}

{K : Type u}
[Field K]
(A : ValuationSubring K)
(P : PrimeSpectrum ↥A)

↑↑(A.primeSpectrumOrderEquiv P) =
  {x | ∃ a ∈ A, ∃ a_1, (∃ (x : a_1 ∈ A), ⟨a_1, ⋯⟩ ∈ P.asIdeal.primeCompl) ∧ x = a * a_1⁻¹}


theorem _root_.IsOpen.measure_zero_iff_eq_empty (hU : IsOpen U) :
    μ U = 0 ↔ U = ∅

{X : Type u_1}
[TopologicalSpace X]
{m : MeasurableSpace X}
{μ : MeasureTheory.Measure X}
[μ.IsOpenPosMeasure]
{U : Set X}
(hU : IsOpen U)


/-- The closure of the interval `[a, b)` is the closed interval `[a, b]`. -/
@[simp]
theorem closure_Ico {a b : α} (hab : a ≠ b) : closure (Ico a b) = Icc a b

{α : Type u_1}
[TopologicalSpace α]
[LinearOrder α]
[OrderTopology α]
[DenselyOrdered α]
{a b : α}
(hab : a ≠ b)


@[simp, nolint simpNF]
theorem Tape.write_move_right_n {Γ} [Inhabited Γ] (f : Γ → Γ) (L R : ListBlank Γ) (n : ℕ) :
    ((Tape.move Dir.right)^[n] (Tape.mk' L R)).write (f (R.nth n)) =
      (Tape.move Dir.right)^[n] (Tape.mk' L (R.modifyNth f n))

{Γ : Type u_1}
[Inhabited Γ]
(f : Γ → Γ)
(L R : Turing.ListBlank Γ)
(n : ℕ)

Turing.Tape.write (f (R.nth n)) ((Turing.Tape.move Turing.Dir.right)^[n] (Turing.Tape.mk' L R)) =
  (Turing.Tape.move Turing.Dir.right)^[n] (Turing.Tape.mk' L (Turing.ListBlank.modifyNth f n R))


/-- Given any `f : B →ₐ[A] B'` and any `x : L`, the minimal polynomial of `x` vanishes at `f x`. -/
@[simp]
theorem aeval_algHom (f : B →ₐ[A] B') (x : B) : (Polynomial.aeval (f x)) (minpoly A x) = 0

(A : Type u_1)
{B : Type u_2}
{B' : Type u_3}
[CommRing A]
[Ring B]
[Ring B']
[Algebra A B]
[Algebra A B']
(f : B →ₐ[A] B')
(x : B)


theorem Decidable.not_iff [Decidable b] : ¬(a ↔ b) ↔ (¬a ↔ b)


theorem minimum?_eq_some_iff [Min α] [LE α] [anti : Antisymm ((· : α) ≤ ·)]
    (le_refl : ∀ a : α, a ≤ a)
    (min_eq_or : ∀ a b : α, min a b = a ∨ min a b = b)
    (le_min_iff : ∀ a b c : α, a ≤ min b c ↔ a ≤ b ∧ a ≤ c) {xs : List α} :
    xs.minimum? = some a ↔ a ∈ xs ∧ ∀ b, b ∈ xs → a ≤ b

(min_eq_or : ∀ (a b : α), min a b = a ∨ min a b = b)

(le_min_iff : ∀ (a b c : α), a ≤ min b c ↔ a ≤ b ∧ a ≤ c)

xs.minimum? = some a ↔ a ∈ xs ∧ ∀ (b : α), b ∈ xs → a ≤ b


theorem UniqueMDiffOn.inter (hs : UniqueMDiffOn I s) (ht : IsOpen t) : UniqueMDiffOn I (s ∩ t)

{𝕜 : Type u_1}
[NontriviallyNormedField 𝕜]
{E : Type u_2}
[NormedAddCommGroup E]
[NormedSpace 𝕜 E]
{H : Type u_3}
[TopologicalSpace H]
{I : ModelWithCorners 𝕜 E H}
{M : Type u_4}
[TopologicalSpace M]
[ChartedSpace H M]
{s t : Set M}
(hs : UniqueMDiffOn I s)
(ht : IsOpen t)


theorem IsCoprime.pow (H : IsCoprime x y) : IsCoprime (x ^ m) (y ^ n)

{R : Type u}
[CommSemiring R]
{x y : R}
{m n : ℕ}
(H : IsCoprime x y)


theorem strongEpi_of_epi [StrongEpiCategory C] (f : P ⟶ Q) [Epi f] : StrongEpi f

{C : Type u}
[CategoryTheory.Category.{v, u} C]
{P Q : C}
[CategoryTheory.StrongEpiCategory C]
(f : P ⟶ Q)
[CategoryTheory.Epi f]


theorem map_Q {D : Type*} [Category D] [Preadditive D] (G : C ⥤ D) [G.Additive]
    (X : SimplicialObject C) (q n : ℕ) :
    G.map ((Q q : K[X] ⟶ _).f n) = (Q q : K[((whiskering C D).obj G).obj X] ⟶ _).f n

{C : Type u_1}
[CategoryTheory.Category.{u_4, u_1} C]
[CategoryTheory.Preadditive C]
{D : Type u_2}
[CategoryTheory.Category.{u_3, u_2} D]
[CategoryTheory.Preadditive D]
(G : C ⥤ D)
[G.Additive]
(X : CategoryTheory.SimplicialObject C)
(q n : ℕ)

G.map ((AlgebraicTopology.DoldKan.Q q).f n) = (AlgebraicTopology.DoldKan.Q q).f n


/-- The image of `Zsqrtd` in `ℝ`, using `Real.sqrt` which takes the positive root of `d`.

If the negative root is desired, use `toReal h (star a)`. -/
@[simps!]
noncomputable def toReal {d : ℤ} (h : 0 ≤ d) : ℤ√d →+* ℝ

(Zsqrtd.toReal h) a = ↑a.re + ↑a.im * √↑d


@[simp, norm_cast]
theorem coe_smul (n : M) (f : CentroidHom α) : ⇑(n • f) = n • ⇑f

{M : Type u_2}
{α : Type u_5}
[NonUnitalNonAssocSemiring α]
[Monoid M]
[DistribMulAction M α]
[SMulCommClass M α α]
[IsScalarTower M α α]
(n : M)
(f : CentroidHom α)


/-- A function applied to a `dite` is a `dite` of that function applied to each of the branches. -/
theorem apply_dite (f : α → β) (P : Prop) [Decidable P] (x : P → α) (y : ¬P → α) :
    f (dite P x y) = dite P (fun h => f (x h)) (fun h => f (y h))

{α : Sort u_1}
{β : Sort u_2}
(f : α → β)
(P : Prop)
[Decidable P]
(x : P → α)
(y : ¬P → α)

f (dite P x y) = if h : P then f (x h) else f (y h)


/-- Continuity from below: the measure of the union of a sequence of
(not necessarily measurable) sets is the supremum of the measures of the partial unions. -/
theorem measure_iUnion_eq_iSup' {α ι : Type*} [MeasurableSpace α] {μ : Measure α}
    [Countable ι] [Preorder ι] [IsDirected ι (· ≤ ·)]
    {f : ι → Set α} : μ (⋃ i, f i) = ⨆ i, μ (Accumulate f i)

{α : Type u_8}
{ι : Type u_9}
[MeasurableSpace α]
{μ : MeasureTheory.Measure α}
[Countable ι]
[Preorder ι]
[IsDirected ι fun x x_1 => x ≤ x_1]
{f : ι → Set α}

μ (⋃ i, f i) = ⨆ i, μ (Set.Accumulate f i)


theorem eq_image_iff_symm_image_eq {α β} (e : α ≃ β) (s : Set α) (t : Set β) :
    t = e '' s ↔ e.symm '' t = s

{α : Type u_1}
{β : Type u_2}
(e : α ≃ β)
(s : Set α)
(t : Set β)


{α : Type u_1}
[AddCommGroup α]
{p a : α}


theorem HasFDerivAtFilter.const_sub (hf : HasFDerivAtFilter f f' x L) (c : F) :
    HasFDerivAtFilter (fun x => c - f x) (-f') x L

{𝕜 : Type u_1}
[NontriviallyNormedField 𝕜]
{E : Type u_2}
[NormedAddCommGroup E]
[NormedSpace 𝕜 E]
{F : Type u_3}
[NormedAddCommGroup F]
[NormedSpace 𝕜 F]
{f : E → F}
{f' : E →L[𝕜] F}
{x : E}
{L : Filter E}
(hf : HasFDerivAtFilter f f' x L)
(c : F)


@[simp]
theorem zero_domain : (0 : E →ₗ.[R] F).domain = ⊤

{R : Type u_1}
[Ring R]
{E : Type u_2}
[AddCommGroup E]
[Module R E]
{F : Type u_3}
[AddCommGroup F]
[Module R F]


theorem Lex.acc (hbot : ∀ ⦃i a⦄, ¬s i a 0) (hs : ∀ i, WellFounded (s i))
    [DecidableEq ι] [∀ (i) (x : α i), Decidable (x ≠ 0)] (x : Π₀ i, α i)
    (h : ∀ i ∈ x.support, Acc (rᶜ ⊓ (· ≠ ·)) i) : Acc (DFinsupp.Lex r s) x

[(i : ι) → (x : α i) → Decidable (x ≠ 0)]

(h : ∀ i ∈ x.support, Acc (rᶜ ⊓ fun x x_1 => x ≠ x_1) i)


@[simp]
theorem dist_equiv_symm_single_same (i : ι) (b₁ b₂ : β i) :
    dist
        ((WithLp.equiv p (∀ i, β i)).symm (Pi.single i b₁))
        ((WithLp.equiv p (∀ i, β i)).symm (Pi.single i b₂)) =
      dist b₁ b₂

[(i : ι) → SeminormedAddCommGroup (β i)]

dist ((WithLp.equiv p ((i : ι) → β i)).symm (Pi.single i b₁)) ((WithLp.equiv p ((i : ι) → β i)).symm (Pi.single i b₂)) =
  dist b₁ b₂


theorem infinite_iff_abs_lt_abs {x : ℝ*} : Infinite x ↔ ∀ r : ℝ, (|r| : ℝ*) < |x|


/-- `M` as a submodule of `M × N` is isomorphic to `M`. -/
@[simps]
def fstEquiv : Submodule.fst R M M₂ ≃ₗ[R] M

(R : Type u)
(M : Type v)
(M₂ : Type w)
[Semiring R]
[AddCommMonoid M]
[AddCommMonoid M₂]
[Module R M]
[Module R M₂]
(x : ↥(Submodule.fst R M M₂))


@[simp]
theorem natCast_apply [NatCast β] (n : ℕ) (x : α) : (n : α →ᵇ β) x = n

{α : Type u}
[TopologicalSpace α]
{β : Type u_2}
[PseudoMetricSpace β]
[NatCast β]
(n : ℕ)
(x : α)


theorem ContMDiff.inv₀ (hf : ContMDiff I' I n f) (h0 : ∀ x, f x ≠ 0) :
    ContMDiff I' I n (fun x ↦ (f x)⁻¹)

{𝕜 : Type u_1}
[NontriviallyNormedField 𝕜]
{H : Type u_2}
[TopologicalSpace H]
{E : Type u_3}
[NormedAddCommGroup E]
[NormedSpace 𝕜 E]
{I : ModelWithCorners 𝕜 E H}
{G : Type u_4}
[TopologicalSpace G]
[ChartedSpace H G]
[Inv G]
[Zero G]
[SmoothInv₀ I G]
{E' : Type u_5}
[NormedAddCommGroup E']
[NormedSpace 𝕜 E']
{H' : Type u_6}
[TopologicalSpace H']
{I' : ModelWithCorners 𝕜 E' H'}
{M : Type u_7}
[TopologicalSpace M]
[ChartedSpace H' M]
{n : ℕ∞}
{f : M → G}
(hf : ContMDiff I' I n f)
(h0 : ∀ (x : M), f x ≠ 0)


@[simp] theorem ncard_subtype (P : α → Prop) (s : Set α) :
    { x : Subtype P | (x : α) ∈ s }.ncard = (s ∩ setOf P).ncard

{α : Type u_1}
(P : α → Prop)
(s : Set α)

{x | ↑x ∈ s}.ncard = (s ∩ setOf P).ncard


theorem exists_nonempty_countable_separating (α : Type*) {p : Set α → Prop} {s₀} (hp : p s₀)
    (t : Set α) [HasCountableSeparatingOn α p t] :
    ∃ S : Set (Set α), S.Nonempty ∧ S.Countable ∧ (∀ s ∈ S, p s) ∧
      ∀ x ∈ t, ∀ y ∈ t, (∀ s ∈ S, x ∈ s ↔ y ∈ s) → x = y

(α : Type u_1)
{p : Set α → Prop}
{s₀ : Set α}
(hp : p s₀)
(t : Set α)
[HasCountableSeparatingOn α p t]

∃ S, S.Nonempty ∧ S.Countable ∧ (∀ s ∈ S, p s) ∧ ∀ x ∈ t, ∀ y ∈ t, (∀ s ∈ S, x ∈ s ↔ y ∈ s) → x = y


theorem min_lt_max : min a b < max a b ↔ a ≠ b


@[simp]
theorem sum_elim_dotProduct_sum_elim : Sum.elim u x ⬝ᵥ Sum.elim v y = u ⬝ᵥ v + x ⬝ᵥ y

{m : Type u_2}
{n : Type u_3}
{α : Type v}
[Fintype m]
[Fintype n]
[NonUnitalNonAssocSemiring α]
(u v : m → α)
(x y : n → α)


@[simp]
theorem map_subtype_embedding_eq (p' : Submodule R p) :
    MapSubtype.orderEmbedding p p' = map p.subtype p'

{R : Type u_1}
{M : Type u_6}
[Semiring R]
[AddCommMonoid M]
[Module R M]
(p : Submodule R M)
(p' : Submodule R ↥p)

(Submodule.MapSubtype.orderEmbedding p) p' = Submodule.map p.subtype p'


@[ext]
theorem hom_ext [Ring R] {d : ℤ} (f g : ℤ√d →+* R) (h : f sqrtd = g sqrtd) : f = g

{R : Type}
[Ring R]
{d : ℤ}
(f g : ℤ√d →+* R)
(h : f Zsqrtd.sqrtd = g Zsqrtd.sqrtd)


@[simp]
theorem norm_map (x : E) : ‖e x‖ = ‖x‖

{R : Type u_1}
{R₂ : Type u_2}
{E : Type u_5}
{E₂ : Type u_6}
[Semiring R]
[Semiring R₂]
{σ₁₂ : R →+* R₂}
{σ₂₁ : R₂ →+* R}
[RingHomInvPair σ₁₂ σ₂₁]
[RingHomInvPair σ₂₁ σ₁₂]
[SeminormedAddCommGroup E]
[SeminormedAddCommGroup E₂]
[Module R E]
[Module R₂ E₂]
(e : E ≃ₛₗᵢ[σ₁₂] E₂)
(x : E)


theorem and_and_left  : a ∧ (b ∧ c) ↔ (a ∧ b) ∧ a ∧ c


@[simp]
theorem isSeparable_iUnion {ι : Sort*} [Countable ι] {s : ι → Set α} :
    IsSeparable (⋃ i, s i) ↔ ∀ i, IsSeparable (s i)

{α : Type u}
[t : TopologicalSpace α]
{ι : Sort u_2}
[Countable ι]
{s : ι → Set α}

TopologicalSpace.IsSeparable (⋃ i, s i) ↔ ∀ (i : ι), TopologicalSpace.IsSeparable (s i)


@[reassoc (attr := simp)]
lemma single_map_singleObjApplyIso_hom (j : J) {X Y : C} (f : X ⟶ Y) :
    (single j).map f j ≫ (singleObjApplyIso j Y).hom = (singleObjApplyIso j X).hom ≫ f

{J : Type u_1}
{C : Type u_2}
[CategoryTheory.Category.{u_3, u_2} C]
[CategoryTheory.Limits.HasInitial C]
[DecidableEq J]
(j : J)
{X Y : C}
(f : X ⟶ Y)

CategoryTheory.CategoryStruct.comp ((CategoryTheory.GradedObject.single j).map f j)
    (CategoryTheory.GradedObject.singleObjApplyIso j Y).hom =
  CategoryTheory.CategoryStruct.comp (CategoryTheory.GradedObject.singleObjApplyIso j X).hom f


@[simp]
theorem lift_t (f : G →* H) (x : H) (hx : ∀ a : A, x * f ↑a = f (φ a : G) * x) :
    lift f x hx t = x

(hx : ∀ (a : ↥A), x * f ↑a = f ↑(φ a) * x)

(HNNExtension.lift f x hx) HNNExtension.t = x


@[simp] theorem getMsb_zeroExtend' (ge : m ≥ n) (x : BitVec n) (i : Nat) :
    getMsb (zeroExtend' ge x) i = (decide (i ≥ m - n) && getMsb x (i - (m - n)))

{m n : Nat}
(ge : m ≥ n)
(x : BitVec n)
(i : Nat)

(BitVec.zeroExtend' ge x).getMsb i = (decide (i ≥ m - n) && x.getMsb (i - (m - n)))


theorem StrictConcaveOn.comp (hg : StrictConcaveOn 𝕜 (f '' s) g) (hf : StrictConcaveOn 𝕜 s f)
    (hg' : StrictMonoOn g (f '' s)) (hf' : s.InjOn f) : StrictConcaveOn 𝕜 s (g ∘ f)

{𝕜 : Type u_1}
{E : Type u_2}
{α : Type u_4}
{β : Type u_5}
[OrderedSemiring 𝕜]
[AddCommMonoid E]
[OrderedAddCommMonoid α]
[OrderedAddCommMonoid β]
[SMul 𝕜 E]
[SMul 𝕜 α]
[SMul 𝕜 β]
{s : Set E}
{f : E → β}
{g : β → α}
(hg : StrictConcaveOn 𝕜 (f '' s) g)
(hf : StrictConcaveOn 𝕜 s f)
(hg' : StrictMonoOn g (f '' s))
(hf' : Set.InjOn f s)


@[to_additive (attr := simp, norm_cast)]
theorem coe_inv [Inv α] (a : α) : ((a⁻¹ : α) : WithOne α) = (a : WithOne α)⁻¹


theorem eq_of_prime_pow_eq (hp₁ : Prime p₁) (hp₂ : Prime p₂) (hk₁ : 0 < k₁)
    (h : p₁ ^ k₁ = p₂ ^ k₂) : p₁ = p₂

{R : Type u_5}
[CancelCommMonoidWithZero R]
[Unique Rˣ]
{p₁ p₂ : R}
{k₁ k₂ : ℕ}
(hp₁ : Prime p₁)
(hp₂ : Prime p₂)
(hk₁ : 0 < k₁)
(h : p₁ ^ k₁ = p₂ ^ k₂)


@[to_additive]
theorem op_smul_finset_subset_mul : a ∈ t → op a • s ⊆ s * t

{α : Type u_2}
[Add α]
[DecidableEq α]
{s t : Finset α}
{a : α}


theorem smooth_id : Smooth I I (id : M → M)

{𝕜 : Type u_1}
[NontriviallyNormedField 𝕜]
{E : Type u_2}
[NormedAddCommGroup E]
[NormedSpace 𝕜 E]
{H : Type u_3}
[TopologicalSpace H]
{I : ModelWithCorners 𝕜 E H}
{M : Type u_4}
[TopologicalSpace M]
[ChartedSpace H M]


@[simp]
theorem AddMonoidHom.coe_toRatLinearMap [AddCommGroup M] [Module ℚ M] [AddCommGroup M₂]
    [Module ℚ M₂] (f : M →+ M₂) : ⇑f.toRatLinearMap = f

{M : Type u_1}
{M₂ : Type u_2}
[AddCommGroup M]
[Module ℚ M]
[AddCommGroup M₂]
[Module ℚ M₂]
(f : M →+ M₂)


private theorem pow_zero_pos [OrderedSemiring α] [Nontrivial α] (a : α) : 0 < a ^ 0

{α : Type u_1}
[OrderedSemiring α]
[Nontrivial α]
(a : α)


theorem nsmul_apply (n : ℕ) (f : M →ₗ⁅R,L⁆ N) (m : M) : (n • f) m = n • f m

{R : Type u}
{L : Type v}
{M : Type w}
{N : Type w₁}
[CommRing R]
[LieRing L]
[AddCommGroup M]
[AddCommGroup N]
[Module R M]
[Module R N]
[LieRingModule L M]
[LieRingModule L N]
(n : ℕ)
(f : M →ₗ⁅R,L⁆ N)
(m : M)


@[to_additive (attr := simp)]
theorem toDual_one [One α] : toDual (1 : α) = 1


/-- **Lévy's generalization of the Borel-Cantelli lemma**: given a sequence of sets `s` and a
filtration `ℱ` such that for all `n`, `s n` is `ℱ n`-measurable, `limsup s atTop` is almost
everywhere equal to the set for which `∑ k, ℙ(s (k + 1) | ℱ k) = ∞`. -/
theorem ae_mem_limsup_atTop_iff (μ : Measure Ω) [IsFiniteMeasure μ] {s : ℕ → Set Ω}
    (hs : ∀ n, MeasurableSet[ℱ n] (s n)) : ∀ᵐ ω ∂μ, ω ∈ limsup s atTop ↔
    Tendsto (fun n => ∑ k ∈ Finset.range n,
      (μ[(s (k + 1)).indicator (1 : Ω → ℝ)|ℱ k]) ω) atTop atTop

{Ω : Type u_1}
{m0 : MeasurableSpace Ω}
{ℱ : MeasureTheory.Filtration ℕ m0}
(μ : MeasureTheory.Measure Ω)
[MeasureTheory.IsFiniteMeasure μ]
{s : ℕ → Set Ω}
(hs : ∀ (n : ℕ), MeasurableSet (s n))

∀ᵐ (ω : Ω) ∂μ,
  ω ∈ Filter.limsup s Filter.atTop ↔
    Filter.Tendsto (fun n => ∑ k ∈ Finset.range n, (μ[(s (k + 1)).indicator 1|↑ℱ k]) ω) Filter.atTop Filter.atTop


/-- Conjugacy classes form a partition of G, stated in terms of cardinality. -/
theorem Group.sum_card_conj_classes_eq_card [Finite G] :
    ∑ᶠ x : ConjClasses G, x.carrier.ncard = Nat.card G

∑ᶠ (x : ConjClasses G), x.carrier.ncard = Nat.card G


@[to_additive (attr := simp)]
theorem smul_nonempty : (s • t).Nonempty ↔ s.Nonempty ∧ t.Nonempty

{α : Type u_2}
{β : Type u_3}
[SMul α β]
{s : Set α}
{t : Set β}


/-- The product of `f` over `insert a s` is the same as
the product over `s`, as long as `f a = 1`. -/
@[to_additive (attr := simp) "The sum of `f` over `insert a s` is the same as
the sum over `s`, as long as `f a = 0`."]
theorem prod_insert_one [DecidableEq α] (h : f a = 1) : ∏ x ∈ insert a s, f x = ∏ x ∈ s, f x

{α : Type u_3}
{β : Type u_4}
{s : Finset α}
{a : α}
{f : α → β}
[CommMonoid β]
[DecidableEq α]
(h : f a = 1)


theorem biUnion_parts : P.parts.biUnion id = s

{α : Type u_1}
[DecidableEq α]
{s : Finset α}
(P : Finpartition s)


/-- An outer measure is a countably subadditive monotone function that sends `∅` to `0`. -/
structure OuterMeasure (α : Type*) where
  /-- Outer measure function. Use automatic coercion instead. -/
  protected measureOf : Set α → ℝ≥0∞
  protected empty : measureOf ∅ = 0
  protected mono : ∀ {s₁ s₂}, s₁ ⊆ s₂ → measureOf s₁ ≤ measureOf s₂
  protected iUnion_nat : ∀ s : ℕ → Set α, Pairwise (Disjoint on s) →
    measureOf (⋃ i, s i) ≤ ∑' i, measureOf (s i)

{α : Type u_2}
(self : MeasureTheory.OuterMeasure α)
(s : ℕ → Set α)

Pairwise (Disjoint on s) → self.measureOf (⋃ i, s i) ≤ ∑' (i : ℕ), self.measureOf (s i)


/-- Right multiplication by a unit of a monoid is a permutation of the underlying type. -/
@[to_additive (attr := simps (config := .asFn) apply)
"Right addition of an additive unit is a permutation of the underlying type."]
def mulRight (u : Mˣ) : Equiv.Perm M

{M : Type u_6}
[AddMonoid M]
(u : AddUnits M)


@[simp] theorem UInt32.val_ofNat (n) :
    (no_index (OfNat.ofNat n) : UInt32).val = OfNat.ofNat n


theorem inf_attach (s : Finset β) (f : β → α) : (s.attach.inf fun x => f x) = s.inf f

{α : Type u_2}
{β : Type u_3}
[SemilatticeInf α]
[OrderTop α]
(s : Finset β)
(f : β → α)


theorem expSeries_sum_eq (x : 𝔸) : (expSeries 𝕂 𝔸).sum x = ∑' n : ℕ, (n !⁻¹ : 𝕂) • x ^ n

{𝕂 : Type u_1}
{𝔸 : Type u_2}
[Field 𝕂]
[Ring 𝔸]
[Algebra 𝕂 𝔸]
[TopologicalSpace 𝔸]
[TopologicalRing 𝔸]
(x : 𝔸)

(NormedSpace.expSeries 𝕂 𝔸).sum x = ∑' (n : ℕ), (↑n.factorial)⁻¹ • x ^ n


@[simp]
theorem proj_apply (i : ι) (f : ∀ i, P i) : @proj k _ ι V P _ _ _ i f = f i

{k : Type u_1}
[Ring k]
{ι : Type u_10}
{V : ι → Type u_11}
{P : ι → Type u_12}
[(i : ι) → AddCommGroup (V i)]
[(i : ι) → Module k (V i)]
[(i : ι) → AffineSpace (V i) (P i)]
(i : ι)
(f : (i : ι) → P i)


private lemma expDegree_rec (m : ℕ) :
    (expDegree (2 * (m + 3)) = 2 * expDegree (m + 2) + expDegree (m + 3) + expDegree (m + 5) ∧
    expDegree (2 * (m + 3)) = expDegree (m + 1) + expDegree (m + 3) + 2 * expDegree (m + 4)) ∧
    (expDegree (2 * (m + 2) + 1) =
      expDegree (m + 4) + 3 * expDegree (m + 2) + (if Even m then 2 * 3 else 0) ∧
    expDegree (2 * (m + 2) + 1) =
      expDegree (m + 1) + 3 * expDegree (m + 3) + (if Even m then 0 else 2 * 3))

(WeierstrassCurve.expDegree (2 * (m + 3)) =
      2 * WeierstrassCurve.expDegree (m + 2) + WeierstrassCurve.expDegree (m + 3) + WeierstrassCurve.expDegree (m + 5) ∧
    WeierstrassCurve.expDegree (2 * (m + 3)) =
      WeierstrassCurve.expDegree (m + 1) + WeierstrassCurve.expDegree (m + 3) +
        2 * WeierstrassCurve.expDegree (m + 4)) ∧
  (WeierstrassCurve.expDegree (2 * (m + 2) + 1) =
      WeierstrassCurve.expDegree (m + 4) + 3 * WeierstrassCurve.expDegree (m + 2) + if Even m then 2 * 3 else 0) ∧
    WeierstrassCurve.expDegree (2 * (m + 2) + 1) =
      WeierstrassCurve.expDegree (m + 1) + 3 * WeierstrassCurve.expDegree (m + 3) + if Even m then 0 else 2 * 3


theorem IsClosed.lowerSemicontinuousOn_indicator (hs : IsClosed s) (hy : y ≤ 0) :
    LowerSemicontinuousOn (indicator s fun _x => y) t

{α : Type u_1}
[TopologicalSpace α]
{β : Type u_2}
[Preorder β]
{s t : Set α}
{y : β}
[Zero β]
(hs : IsClosed s)
(hy : y ≤ 0)

LowerSemicontinuousOn (s.indicator fun _x => y) t


@[to_additive]
lemma isClosedMap_div_right (a : G) : IsClosedMap (· / a)

{G : Type w}
[Group G]
[TopologicalSpace G]
[TopologicalGroup G]
(a : G)


theorem contDiffAt_zero : ContDiffAt 𝕜 0 f x ↔ ∃ u ∈ 𝓝 x, ContinuousOn f u

{𝕜 : Type u}
[NontriviallyNormedField 𝕜]
{E : Type uE}
[NormedAddCommGroup E]
[NormedSpace 𝕜 E]
{F : Type uF}
[NormedAddCommGroup F]
[NormedSpace 𝕜 F]
{f : E → F}
{x : E}


/-- Transposing a matrix preserves the determinant. -/
@[simp]
theorem det_transpose (M : Matrix n n R) : Mᵀ.det = M.det

{n : Type u_2}
[DecidableEq n]
[Fintype n]
{R : Type v}
[CommRing R]
(M : Matrix n n R)


@[to_additive (attr := simp)]
theorem toFreeSemigroup_of (x : α) : toFreeSemigroup (of x) = FreeSemigroup.of x

FreeMagma.toFreeSemigroup (FreeMagma.of x) = FreeSemigroup.of x


theorem comap_map_eq_self_of_injective
    {f : R →+* S} (hf : Function.Injective f) (s : Subsemiring R) : (s.map f).comap f = s

{R : Type u}
{S : Type v}
[NonAssocSemiring R]
[NonAssocSemiring S]
{f : R →+* S}
(hf : Function.Injective ⇑f)
(s : Subsemiring R)

Subsemiring.comap f (Subsemiring.map f s) = s


theorem eventuallyMeasurableSet_of_mem_filter (hs : s ∈ l) : EventuallyMeasurableSet m l s

{α : Type u_1}
{m : MeasurableSpace α}
{l : Filter α}
[CountableInterFilter l]
{s : Set α}
(hs : s ∈ l)


/-- To cancel a common factor `c` from a `ModEq` we must divide the modulus `m` by `gcd m c`. -/
theorem cancel_right_div_gcd (hm : 0 < m) (h : a * c ≡ b * c [ZMOD m]) :
    a ≡ b [ZMOD m / gcd m c]

{m a b c : ℤ}
(hm : 0 < m)
(h : a * c ≡ b * c [ZMOD m])


@[to_additive (attr := simp)]
theorem mulIndicator_eq_self : s.mulIndicator f = f ↔ mulSupport f ⊆ s

{α : Type u_1}
{M : Type u_4}
[Zero M]
{s : Set α}
{f : α → M}

s.indicator f = f ↔ Function.support f ⊆ s


theorem toPartitionOfUnity_apply (i : ι) (x : X) :
    f.toPartitionOfUnity i x = f i x * ∏ᶠ (j) (_ : WellOrderingRel j i), (1 - f j x)

{ι : Type u}
{X : Type v}
[TopologicalSpace X]
{s : Set X}
(f : BumpCovering ι X s)
(i : ι)
(x : X)

(f.toPartitionOfUnity i) x = (f i) x * ∏ᶠ (j : ι) (_ : WellOrderingRel j i), (1 - (f j) x)


theorem add_inter_distrib (s t u : Multiset α) : s + t ∩ u = (s + t) ∩ (s + u)

{α : Type u_1}
[DecidableEq α]
(s t u : Multiset α)


theorem codisjoint_left_comm : Codisjoint a (b ⊔ c) ↔ Codisjoint b (a ⊔ c)

{α : Type u_1}
[SemilatticeSup α]
[OrderTop α]
{a b c : α}


@[simp]
theorem enum_cons (s : Seq α) (x : α) :
    enum (cons x s) = cons (0, x) (map (Prod.map Nat.succ id) (enum s))

{α : Type u}
(s : Stream'.Seq α)
(x : α)

(Stream'.Seq.cons x s).enum = Stream'.Seq.cons (0, x) (Stream'.Seq.map (Prod.map Nat.succ id) s.enum)


@[field_simps]
theorem add_div' (a b c : α) (hc : c ≠ 0) : b + a / c = (b * c + a) / c

{α : Type u_1}
[DivisionSemiring α]
(a b c : α)
(hc : c ≠ 0)


theorem content_eq_gcd_leadingCoeff_content_eraseLead (p : R[X]) :
    p.content = GCDMonoid.gcd p.leadingCoeff (eraseLead p).content

{R : Type u_1}
[CommRing R]
[IsDomain R]
[NormalizedGCDMonoid R]
(p : Polynomial R)

p.content = gcd p.leadingCoeff p.eraseLead.content


@[to_additive (attr := simp)]
lemma op_smul_coe_set [Group G] [SetLike S G] [SubgroupClass S G] {s : S} {a : G} (ha : a ∈ s) :
    MulOpposite.op a • (s : Set G) = s

{G : Type u_2}
{S : Type u_4}
[Group G]
[SetLike S G]
[SubgroupClass S G]
{s : S}
{a : G}
(ha : a ∈ s)


/-- The natural isomorphism expressing that functors `Karoubi C ⥤ Karoubi D` obtained
using `functorExtension₁` actually extends the original functors `C ⥤ Karoubi D`. -/
@[simps!]
def functorExtension₁CompWhiskeringLeftToKaroubiIso :
    functorExtension₁ C D ⋙ (whiskeringLeft C (Karoubi C) (Karoubi D)).obj (toKaroubi C) ≅ 𝟭 _

(X : CategoryTheory.Functor C (CategoryTheory.Idempotents.Karoubi D))

∀ (X_1 : C),
  (((CategoryTheory.Idempotents.functorExtension₁CompWhiskeringLeftToKaroubiIso C D).inv.app X).app X_1).f =
    (X.obj X_1).p


@[simp]
theorem mul_symm (e : Perm α) : e * e.symm = 1


theorem _root_.IsClosed.ae_eq_univ_iff_eq (hF : IsClosed F) :
    F =ᵐ[μ] univ ↔ F = univ

{X : Type u_1}
[TopologicalSpace X]
{m : MeasurableSpace X}
{μ : MeasureTheory.Measure X}
[μ.IsOpenPosMeasure]
{F : Set X}
(hF : IsClosed F)


@[simp]
theorem map_neg (x : R) : v (-x) = v x

{R : Type u_3}
{Γ₀ : Type u_4}
[LinearOrderedAddCommGroupWithTop Γ₀]
[Ring R]
(v : AddValuation R Γ₀)
(x : R)


theorem Iio_ae_eq_Iic' (ha : μ {a} = 0) : Iio a =ᵐ[μ] Iic a

{α : Type u_1}
{m0 : MeasurableSpace α}
{μ : MeasureTheory.Measure α}
[PartialOrder α]
{a : α}
(ha : μ {a} = 0)


@[simp]
theorem associated_zero_iff_eq_zero [MonoidWithZero α] (a : α) : a ~ᵤ 0 ↔ a = 0

{α : Type u_1}
[MonoidWithZero α]
(a : α)


/-- The conditional cdf is a strongly measurable function of `a : α` for all `x : ℝ`. -/
theorem stronglyMeasurable_condCDF (ρ : Measure (α × ℝ)) (x : ℝ) :
    StronglyMeasurable fun a ↦ condCDF ρ a x

{α : Type u_1}
{mα : MeasurableSpace α}
(ρ : MeasureTheory.Measure (α × ℝ))
(x : ℝ)

MeasureTheory.StronglyMeasurable fun a => ↑(ProbabilityTheory.condCDF ρ a) x


@[to_additive prodMap_def]
theorem prodMap_def : prodMap f g = (f.comp (fst M N)).prod (g.comp (snd M N))

{M : Type u_5}
{N : Type u_6}
{M' : Type u_8}
{N' : Type u_9}
[Mul M]
[Mul N]
[Mul M']
[Mul N']
(f : M →ₙ* M')
(g : N →ₙ* N')

f.prodMap g = (f.comp (MulHom.fst M N)).prod (g.comp (MulHom.snd M N))


/-- A special case of the **Matrix determinant lemma** for when `A = I`. -/
theorem det_one_add_col_mul_row {ι : Type*} [Unique ι] (u v : m → α) :
    det (1 + col ι u * row ι v) = 1 + v ⬝ᵥ u

{m : Type u_2}
{α : Type u_4}
[Fintype m]
[DecidableEq m]
[CommRing α]
{ι : Type u_5}
[Unique ι]
(u v : m → α)

(1 + Matrix.col ι u * Matrix.row ι v).det = 1 + Matrix.dotProduct v u


@[elab_as_elim]
theorem induction_on {C : Finmap β → Prop} (s : Finmap β) (H : ∀ a : AList β, C ⟦a⟧) : C s

{α : Type u}
{β : α → Type v}
{C : Finmap β → Prop}
(s : Finmap β)
(H : ∀ (a : AList β), C ⟦a⟧)


theorem perm_append_right_iff {l₁ l₂ : List α} (l) : l₁ ++ l ~ l₂ ++ l ↔ l₁ ~ l₂

{α : Type u_1}
{l₁ l₂ : List α}
(l : List α)


lemma lt_inv_smul_iff_of_pos [PosSMulStrictMono α β] [PosSMulReflectLT α β] (ha : 0 < a) :
    b₁ < a⁻¹ • b₂ ↔ a • b₁ < b₂

{α : Type u_1}
{β : Type u_2}
{a : α}
{b₁ b₂ : β}
[GroupWithZero α]
[Preorder α]
[Preorder β]
[MulAction α β]
[PosSMulStrictMono α β]
[PosSMulReflectLT α β]
(ha : 0 < a)

b₁ < a⁻¹ • b₂ ↔ a • b₁ < b₂


@[simp] lemma sum_zipWith_distrib_left [Semiring R] (f : ι → κ → R) (a : R) :
    ∀ (l₁ : List ι) (l₂ : List κ),
      (zipWith (fun i j ↦ a * f i j) l₁ l₂).sum = a * (zipWith f l₁ l₂).sum

{ι : Type u_1}
{κ : Type u_2}
{R : Type u_5}
[Semiring R]
(f : ι → κ → R)
(a : R)
(l₁ : List ι)
(l₂ : List κ)

(List.zipWith (fun i j => a * f i j) l₁ l₂).sum = a * (List.zipWith f l₁ l₂).sum


theorem some_inj {a b : α} : some a = some b ↔ a = b


theorem X_pow_eq (n : ℕ) : (X : R⟦X⟧) ^ n = monomial R n 1

PowerSeries.X ^ n = (PowerSeries.monomial R n) 1


theorem isSimpleModule_iff_isCoatom : IsSimpleModule R (M ⧸ m) ↔ IsCoatom m

{R : Type u_2}
[Ring R]
{M : Type u_4}
[AddCommGroup M]
[Module R M]
{m : Submodule R M}


@[reassoc (attr := simp)]
lemma fac : IsCartesian.map p f φ φ' ≫ φ = φ'

{𝒮 : Type u₁}
{𝒳 : Type u₂}
[CategoryTheory.Category.{v₁, u₁} 𝒮]
[CategoryTheory.Category.{v₂, u₂} 𝒳]
(p : 𝒳 ⥤ 𝒮)
{R S : 𝒮}
{a b : 𝒳}
(f : R ⟶ S)
(φ : a ⟶ b)
[p.IsCartesian f φ]
{a' : 𝒳}
(φ' : a' ⟶ b)
[p.IsHomLift f φ']

CategoryTheory.Functor.IsCartesian.map p f φ φ' ≫ φ = φ'


theorem zpow_apply_comm {α : Type*} (σ : Perm α) (m n : ℤ) {x : α} :
    (σ ^ m) ((σ ^ n) x) = (σ ^ n) ((σ ^ m) x)

{α : Type u_1}
(σ : Equiv.Perm α)
(m n : ℤ)
{x : α}


@[fun_prop]
theorem DifferentiableOn.smul (hc : DifferentiableOn 𝕜 c s) (hf : DifferentiableOn 𝕜 f s) :
    DifferentiableOn 𝕜 (fun y => c y • f y) s

{𝕜 : Type u_1}
[NontriviallyNormedField 𝕜]
{E : Type u_2}
[NormedAddCommGroup E]
[NormedSpace 𝕜 E]
{F : Type u_3}
[NormedAddCommGroup F]
[NormedSpace 𝕜 F]
{f : E → F}
{s : Set E}
{𝕜' : Type u_6}
[NontriviallyNormedField 𝕜']
[NormedAlgebra 𝕜 𝕜']
[NormedSpace 𝕜' F]
[IsScalarTower 𝕜 𝕜' F]
{c : E → 𝕜'}
(hc : DifferentiableOn 𝕜 c s)
(hf : DifferentiableOn 𝕜 f s)


@[to_additive]
theorem Filter.Tendsto.smul_const {f : α → M} {l : Filter α} {c : M} (hf : Tendsto f l (𝓝 c))
    (a : X) : Tendsto (fun x => f x • a) l (𝓝 (c • a))

{M : Type u_1}
{X : Type u_2}
{α : Type u_4}
[TopologicalSpace M]
[TopologicalSpace X]
[SMul M X]
[ContinuousSMul M X]
{f : α → M}
{l : Filter α}
{c : M}
(hf : Filter.Tendsto f l (𝓝 c))
(a : X)

Filter.Tendsto (fun x => f x • a) l (𝓝 (c • a))


theorem adapted_predictablePart : Adapted ℱ fun n => predictablePart f ℱ μ (n + 1)

{Ω : Type u_1}
{E : Type u_2}
{m0 : MeasurableSpace Ω}
{μ : MeasureTheory.Measure Ω}
[NormedAddCommGroup E]
[NormedSpace ℝ E]
[CompleteSpace E]
{f : ℕ → Ω → E}
{ℱ : MeasureTheory.Filtration ℕ m0}

MeasureTheory.Adapted ℱ fun n => MeasureTheory.predictablePart f ℱ μ (n + 1)


@[simp]
theorem preimage_comp (f : F.obj X ⟶ F.obj Y) (g : F.obj Y ⟶ F.obj Z) :
    F.preimage (f ≫ g) = F.preimage f ≫ F.preimage g

{C : Type u₁}
[CategoryTheory.Category.{v₁, u₁} C]
{D : Type u₂}
[CategoryTheory.Category.{v₂, u₂} D]
{F : CategoryTheory.Functor C D}
{X Y Z : C}
[F.Full]
[F.Faithful]
(f : F.obj X ⟶ F.obj Y)
(g : F.obj Y ⟶ F.obj Z)

F.preimage (CategoryTheory.CategoryStruct.comp f g) = CategoryTheory.CategoryStruct.comp (F.preimage f) (F.preimage g)


theorem Base.finiteRk_of_finite (hB : M.Base B) (hfin : B.Finite) : FiniteRk M

{α : Type u_1}
{M : Matroid α}
{B : Set α}
(hB : M.Base B)
(hfin : B.Finite)


@[to_additive (attr := gcongr) add_le_add]
theorem mul_le_mul' [CovariantClass α α (· * ·) (· ≤ ·)] [CovariantClass α α (swap (· * ·)) (· ≤ ·)]
    {a b c d : α} (h₁ : a ≤ b) (h₂ : c ≤ d) :
    a * c ≤ b * d

[CovariantClass α α (fun x x_1 => x + x_1) fun x x_1 => x ≤ x_1]

[CovariantClass α α (Function.swap fun x x_1 => x + x_1) fun x x_1 => x ≤ x_1]


lemma comap_map {f : α → β} (hf : f.Injective) : (M.map f hf.injOn).comap f = M

{α : Type u_1}
{β : Type u_2}
{M : Matroid α}
{f : α → β}
(hf : Function.Injective f)


run_cmd
  for typeName' in [`UInt8, `UInt16, `UInt32, `UInt64, `USize] do
  let typeName := Lean.mkIdent typeName'
  Lean.Elab.Command.elabCommand (← `(
    namespace $typeName
      instance neZero : NeZero size := ⟨by decide⟩

      instance : Neg $typeName where
        neg a := mk (-a.val)

      instance : Pow $typeName ℕ where
        pow a n := mk (a.val ^ n)

      instance : SMul ℕ $typeName where
        smul n a := mk (n • a.val)

      instance : SMul ℤ $typeName where
        smul z a := mk (z • a.val)

      lemma neg_def (a : $typeName) : -a = ⟨-a.val⟩ := rfl

      lemma pow_def (a : $typeName) (n : ℕ) : a ^ n = ⟨a.val ^ n⟩ := rfl

      lemma nsmul_def (n : ℕ) (a : $typeName) : n • a = ⟨n • a.val⟩ := rfl

      lemma zsmul_def (z : ℤ) (a : $typeName) : z • a = ⟨z • a.val⟩ := rfl

      open $typeName (eq_of_val_eq) in
      lemma val_injective : Function.Injective val := @eq_of_val_eq

      instance instCommMonoid : CommMonoid $typeName :=
        Function.Injective.commMonoid val val_injective
          rfl (fun _ _ => rfl) (fun _ _ => rfl)

      instance instNonUnitalCommRing : NonUnitalCommRing $typeName :=
        Function.Injective.nonUnitalCommRing val val_injective
          rfl (fun _ _ => rfl) (fun _ _ => rfl) (fun _ => rfl) (fun _ _ => rfl)
          (fun _ _ => rfl) (fun _ _ => rfl)

      local instance instNatCast : NatCast $typeName where
        natCast n := mk n

      local instance instIntCast : IntCast $typeName where
        intCast z := mk z

      lemma natCast_def (n : ℕ) : (n : $typeName) = ⟨n⟩ := rfl

      lemma intCast_def (z : ℤ) : (z : $typeName) = ⟨z⟩ := rfl

      local instance instCommRing : CommRing $typeName :=
        Function.Injective.commRing val val_injective
          rfl rfl (fun _ _ => rfl) (fun _ _ => rfl) (fun _ => rfl) (fun _ _ => rfl)
          (fun _ _ => rfl) (fun _ _ => rfl) (fun _ _ => rfl) (fun _ => rfl) (fun _ => rfl)

      namespace CommRing
      attribute [scoped instance] instCommRing instNatCast instIntCast
      end CommRing

    end $typeName
  ))
  -- interpolating docstrings above is more trouble than it's worth
  let docString :=
    s!"To use this instance, use `open scoped {typeName'}.CommRing`.\n\n" ++
    "See the module docstring for an explanation"
  Lean.addDocString (typeName'.mkStr "instCommRing") docString
  Lean.addDocString (typeName'.mkStr "instNatCast") docString
  Lean.addDocString (typeName'.mkStr "instIntCast") docString


theorem hasFiniteIntegral_norm_iff (f : α → β) :
    HasFiniteIntegral (fun a => ‖f a‖) μ ↔ HasFiniteIntegral f μ

{α : Type u_1}
{β : Type u_2}
{m : MeasurableSpace α}
{μ : MeasureTheory.Measure α}
[NormedAddCommGroup β]
(f : α → β)

MeasureTheory.HasFiniteIntegral (fun a => ‖f a‖) μ ↔ MeasureTheory.HasFiniteIntegral f μ


/-- The morphism of short complexes `S.map F ⟶ S.map G` induced by
a natural transformation `F ⟶ G`. -/
@[simps]
def mapNatTrans {F G : C ⥤ D} [F.PreservesZeroMorphisms] [G.PreservesZeroMorphisms] (τ : F ⟶ G) :
    S.map F ⟶ S.map G


lemma inv_smul_lt_iff_of_pos [PosSMulStrictMono α β] [PosSMulReflectLT α β] (ha : 0 < a) :
    a⁻¹ • b₁ < b₂ ↔ b₁ < a • b₂

a⁻¹ • b₁ < b₂ ↔ b₁ < a • b₂


theorem erase_of_not_mem [LawfulBEq α] {a : α} : ∀ {l : List α}, a ∉ l → l.erase a = l

{α : Type u_1}
[BEq α]
[LawfulBEq α]
{a : α}
{l : List α}


@[simp]
theorem presheafToType_map {T : Type v} {U V : (Opens X)ᵒᵖ} {i : U ⟶ V} {f} :
    (presheafToType X T).map i f = f ∘ i.unop

(X : TopCat)
{T : Type v}
{U V : (TopologicalSpace.Opens ↑X)ᵒᵖ}
{i : U ⟶ V}
{f : (X.presheafToType T).obj U}

(X.presheafToType T).map i f = f ∘ fun x => ⟨↑x, ⋯⟩


@[simp]
theorem Homeomorph.toMeasurableEquiv_symm_coe (h : γ ≃ₜ γ₂) :
    (h.toMeasurableEquiv.symm : γ₂ → γ) = h.symm

{γ : Type u_3}
{γ₂ : Type u_4}
[TopologicalSpace γ]
[MeasurableSpace γ]
[BorelSpace γ]
[TopologicalSpace γ₂]
[MeasurableSpace γ₂]
[BorelSpace γ₂]
(h : γ ≃ₜ γ₂)


@[simp] theorem symm_symm (e : α ≃ β) : e.symm.symm = e


@[simp]
theorem support_map : (p.map f).support = p.support.map f

{V : Type u}
{V' : Type v}
{G : SimpleGraph V}
{G' : SimpleGraph V'}
(f : G →g G')
{u v : V}
(p : G.Walk u v)

(SimpleGraph.Walk.map f p).support = List.map (⇑f) p.support


@[simp]
theorem continuousWithinAt_Ico_iff_Iio (h : a < b) :
    ContinuousWithinAt f (Ico a b) b ↔ ContinuousWithinAt f (Iio b) b

{α : Type u}
{β : Type v}
[TopologicalSpace α]
[LinearOrder α]
[ClosedIicTopology α]
[TopologicalSpace β]
{a b : α}
{f : α → β}
(h : a < b)

ContinuousWithinAt f (Set.Ico a b) b ↔ ContinuousWithinAt f (Set.Iio b) b


@[simp]
theorem mem_ofSubring (R : Subring K) (hR : ∀ x : K, x ∈ R ∨ x⁻¹ ∈ R) (x : K) :
    x ∈ ofSubring R hR ↔ x ∈ R

{K : Type u}
[Field K]
(R : Subring K)
(hR : ∀ (x : K), x ∈ R ∨ x⁻¹ ∈ R)
(x : K)

x ∈ ValuationSubring.ofSubring R hR ↔ x ∈ R


theorem nthRoots_eq {n : ℕ} {ζ : R} (hζ : IsPrimitiveRoot ζ n)
    {α a : R} (e : α ^ n = a) :
    nthRoots n a = (Multiset.range n).map (ζ ^ · * α)

{R : Type u_4}
[CommRing R]
[IsDomain R]
{n : ℕ}
{ζ : R}
(hζ : IsPrimitiveRoot ζ n)
{α a : R}
(e : α ^ n = a)

Polynomial.nthRoots n a = Multiset.map (fun x => ζ ^ x * α) (Multiset.range n)


theorem ofNat_shiftRight_eq_div_pow {x y : Nat} : (x >>> y : Int) = (x : Int) / (2 ^ y : Nat)


theorem surjOn_logb : SurjOn (logb b) (Ioi 0) univ

{b : ℝ}
(b_pos : 0 < b)
(b_ne_one : b ≠ 1)

Set.SurjOn (Real.logb b) (Set.Ioi 0) Set.univ


@[simp]
lemma ceilDiv_le_iff_le_smul (ha : 0 < a) : b ⌈/⌉ a ≤ c ↔ b ≤ a • c

{α : Type u_2}
{β : Type u_3}
[OrderedAddCommMonoid α]
[OrderedAddCommMonoid β]
[SMulZeroClass α β]
[CeilDiv α β]
{a : α}
{b c : β}
(ha : 0 < a)


@[to_additive (attr := simp)]
theorem OneHom.coe_copy {_ : One M} {_ : One N} (f : OneHom M N) (f' : M → N) (h : f' = f) :
    (f.copy f' h) = f'

∀ {x : Zero M} {x_1 : Zero N} (f : ZeroHom M N) (f' : M → N) (h : f' = ⇑f), ⇑(f.copy f' h) = f'


lemma ContinuousWithinAt.finset_sup
    (hs : ∀ i ∈ s, ContinuousWithinAt (f i) t x) : ContinuousWithinAt (s.sup f) t x


/-- Note: implementers of `SetLike` must copy this lemma in order to tag it with `@[ext]`. -/
theorem ext (h : ∀ x, x ∈ p ↔ x ∈ q) : p = q

{A : Type u_1}
{B : Type u_2}
[i : SetLike A B]
{p q : A}
(h : ∀ (x : B), x ∈ p ↔ x ∈ q)


theorem _root_.IsCoprime.add_eq (h : IsCoprime I J) : I + J = 1

{R : Type u}
[CommSemiring R]
{I J : Ideal R}
(h : IsCoprime I J)


@[simp]
theorem toFun_eq_coe_aux {f : HeytingHom α β} : (↑f.toLatticeHom) = ⇑f

{α : Type u_2}
{β : Type u_3}
[HeytingAlgebra α]
[HeytingAlgebra β]
{f : HeytingHom α β}


theorem integral_Iic_add_Ioi (h_left : IntegrableOn f (Iic b) μ)
    (h_right : IntegrableOn f (Ioi b) μ) :
    (∫ x in Iic b, f x ∂μ) + (∫ x in Ioi b, f x ∂μ) = ∫ (x : ℝ), f x ∂μ

(h_left : MeasureTheory.IntegrableOn f (Set.Iic b) μ)

(h_right : MeasureTheory.IntegrableOn f (Set.Ioi b) μ)

∫ (x : ℝ) in Set.Iic b, f x ∂μ + ∫ (x : ℝ) in Set.Ioi b, f x ∂μ = ∫ (x : ℝ), f x ∂μ


theorem continuousOn_smul [LocallyCompactSpace X] [T2Space X] {𝕜 : Type*} [NormedField 𝕜]
    [SecondCountableTopologyEither X 𝕜] [NormedSpace 𝕜 E] {f : X → E} {g : X → 𝕜} {s : Set X}
    (hs : IsOpen s) (hf : LocallyIntegrableOn f s μ) (hg : ContinuousOn g s) :
    LocallyIntegrableOn (fun x => g x • f x) s μ

(hf : MeasureTheory.LocallyIntegrableOn f s μ)

MeasureTheory.LocallyIntegrableOn (fun x => g x • f x) s μ


lemma map_posFittingComp_eq (e : M ≃ₗ⁅R,L⁆ M₂) :
    (posFittingComp R L M).map e = posFittingComp R L M₂

{R : Type u_2}
{L : Type u_3}
{M : Type u_4}
[CommRing R]
[LieRing L]
[LieAlgebra R L]
[LieAlgebra.IsNilpotent R L]
[AddCommGroup M]
[Module R M]
[LieRingModule L M]
[LieModule R L M]
{M₂ : Type u_5}
[AddCommGroup M₂]
[Module R M₂]
[LieRingModule L M₂]
[LieModule R L M₂]
(e : M ≃ₗ⁅R,L⁆ M₂)

LieSubmodule.map e.toLieModuleHom (LieModule.posFittingComp R L M) = LieModule.posFittingComp R L M₂


@[simp]
theorem fractRestrict_apply (x : E) : (fractRestrict b x : E) = fract b x

{E : Type u_1}
{ι : Type u_2}
{K : Type u_3}
[NormedLinearOrderedField K]
[NormedAddCommGroup E]
[NormedSpace K E]
(b : Basis ι K E)
[FloorRing K]
[Fintype ι]
(x : E)

↑(Zspan.fractRestrict b x) = Zspan.fract b x


@[simp]
theorem prev_nat_succ (i : ℕ) : (ComplexShape.up ℕ).prev (i + 1) = i


theorem IntegrableOn.mul_continuousOn_of_subset (hg : IntegrableOn g A μ) (hg' : ContinuousOn g' K)
    (hA : MeasurableSet A) (hK : IsCompact K) (hAK : A ⊆ K) :
    IntegrableOn (fun x => g x * g' x) A μ

{X : Type u_1}
{R : Type u_5}
[MeasurableSpace X]
[TopologicalSpace X]
{μ : MeasureTheory.Measure X}
[OpensMeasurableSpace X]
{A K : Set X}
[NormedRing R]
[SecondCountableTopologyEither X R]
{g g' : X → R}
(hg : MeasureTheory.IntegrableOn g A μ)
(hg' : ContinuousOn g' K)
(hA : MeasurableSet A)
(hK : IsCompact K)
(hAK : A ⊆ K)

MeasureTheory.IntegrableOn (fun x => g x * g' x) A μ


@[simp]
lemma DifferentiableAt.sub_iff_right (hg : DifferentiableAt 𝕜 f x) :
    DifferentiableAt 𝕜 (fun y => f y - g y) x ↔ DifferentiableAt 𝕜 g x

{𝕜 : Type u_1}
[NontriviallyNormedField 𝕜]
{E : Type u_2}
[NormedAddCommGroup E]
[NormedSpace 𝕜 E]
{F : Type u_3}
[NormedAddCommGroup F]
[NormedSpace 𝕜 F]
{f g : E → F}
{x : E}
(hg : DifferentiableAt 𝕜 f x)


theorem finrank_zero_iff_forall_zero [FiniteDimensional K V] : finrank K V = 0 ↔ ∀ x : V, x = 0

{K : Type u}
{V : Type v}
[DivisionRing K]
[AddCommGroup V]
[Module K V]
[FiniteDimensional K V]

FiniteDimensional.finrank K V = 0 ↔ ∀ (x : V), x = 0


@[simp] theorem getLeft?_swap (x : α ⊕ β) : x.swap.getLeft? = x.getRight?

{α : Type u_1}
{β : Type u_2}
(x : α ⊕ β)


theorem chain_linearPMap_of_chain_extensionOf {c : Set (ExtensionOf i f)}
    (hchain : IsChain (· ≤ ·) c) :
    IsChain (· ≤ ·) <| (fun x : ExtensionOf i f => x.toLinearPMap) '' c

(hchain : IsChain (fun x x_1 => x ≤ x_1) c)

IsChain (fun x x_1 => x ≤ x_1) ((fun x => x.toLinearPMap) '' c)