@[simp]
theorem valMinAbs_zero : ∀ n, (0 : ZMod n).valMinAbs = 0


theorem directedOn_sUnion {r} {S : Set (Set α)} (hd : DirectedOn (· ⊆ ·) S)
    (h : ∀ x ∈ S, DirectedOn r x) : DirectedOn r (⋃₀ S)

(hd : DirectedOn (fun x x_1 => x ⊆ x_1) S)


theorem Commute.minimalPeriod_of_comp_dvd_lcm {g : α → α} (h : Commute f g) :
    minimalPeriod (f ∘ g) x ∣ Nat.lcm (minimalPeriod f x) (minimalPeriod g x)

{α : Type u_1}
{f : α → α}
{x : α}
{g : α → α}
(h : Function.Commute f g)

Function.minimalPeriod (f ∘ g) x ∣ (Function.minimalPeriod f x).lcm (Function.minimalPeriod g x)


theorem dual_solid (a b : α) (h : b ⊓ -b ≤ a ⊓ -a) : ‖a‖ ≤ ‖b‖

{α : Type u_1}
[NormedLatticeAddCommGroup α]
(a b : α)
(h : b ⊓ -b ≤ a ⊓ -a)


theorem extendDomain_subtypeDomain (f : α →₀ M) (hf : ∀ a ∈ f.support, P a) :
    (subtypeDomain P f).extendDomain = f

{α : Type u_1}
{M : Type u_13}
[Zero M]
{P : α → Prop}
[DecidablePred P]
(f : α →₀ M)
(hf : ∀ a ∈ f.support, P a)

(Finsupp.subtypeDomain P f).extendDomain = f


theorem list_prod_map_mem_graded {ι'} (l : List ι') (i : ι' → ι) (r : ι' → R)
    (h : ∀ j ∈ l, r j ∈ A (i j)) : (l.map r).prod ∈ A (l.map i).sum

{ι : Type u_1}
{R : Type u_2}
{S : Type u_3}
[SetLike S R]
[Monoid R]
[AddMonoid ι]
{A : ι → S}
[SetLike.GradedMonoid A]
{ι' : Type u_4}
(l : List ι')
(i : ι' → ι)
(r : ι' → R)
(h : ∀ j ∈ l, r j ∈ A (i j))

(List.map r l).prod ∈ A (List.map i l).sum


@[mono]
theorem toAddSubgroup_mono : Monotone (toAddSubgroup : Submodule R M → AddSubgroup M)

{R : Type u}
{M : Type v}
[Ring R]
[AddCommGroup M]
{module_M : Module R M}


theorem map_apply {f : α → β} (hf : Measurable f) {s : Set β} (hs : MeasurableSet s) :
    v.map f s = v (f ⁻¹' s)

{α : Type u_1}
{β : Type u_2}
[MeasurableSpace α]
[MeasurableSpace β]
{M : Type u_3}
[AddCommMonoid M]
[TopologicalSpace M]
(v : MeasureTheory.VectorMeasure α M)
{f : α → β}
(hf : Measurable f)
{s : Set β}
(hs : MeasurableSet s)


theorem commProb_prod (M' : Type*) [Mul M'] : commProb (M × M') = commProb M * commProb M'

(M : Type u_1)
[Mul M]
(M' : Type u_2)
[Mul M']


@[to_additive]
lemma smul_smul_smul_comm [SMul α β] [SMul α γ] [SMul β δ] [SMul α δ] [SMul γ δ]
    [IsScalarTower α β δ] [IsScalarTower α γ δ] [SMulCommClass β γ δ] (a : α) (b : β) (c : γ)
    (d : δ) : (a • b) • c • d = (a • c) • b • d

{α : Type u_7}
{β : Type u_8}
{γ : Type u_9}
{δ : Type u_10}
[VAdd α β]
[VAdd α γ]
[VAdd β δ]
[VAdd α δ]
[VAdd γ δ]
[VAddAssocClass α β δ]
[VAddAssocClass α γ δ]
[VAddCommClass β γ δ]
(a : α)
(b : β)
(c : γ)
(d : δ)


/-- Interpret a `Homeomorph` as a `PartialHomeomorph` by restricting it
to an open set `s` in the domain and to `t` in the codomain. -/
@[simps! (config := .asFn) apply symm_apply toPartialEquiv,
  simps! (config := .lemmasOnly) source target]
def _root_.Homeomorph.toPartialHomeomorphOfImageEq (e : X ≃ₜ Y) (s : Set X) (hs : IsOpen s)
    (t : Set Y) (h : e '' s = t) : PartialHomeomorph X Y

{X : Type u_1}
{Y : Type u_3}
[TopologicalSpace X]
[TopologicalSpace Y]
(e : X ≃ₜ Y)
(s : Set X)
(hs : IsOpen s)
(t : Set Y)
(h : ⇑e '' s = t)

↑(e.toPartialHomeomorphOfImageEq s hs t h) = ⇑e


@[simp]
theorem coe_projKerOfRightInverse_apply [TopologicalAddGroup M] (f₁ : M →SL[σ₁₂] M₂)
    (f₂ : M₂ →SL[σ₂₁] M) (h : Function.RightInverse f₂ f₁) (x : M) :
    (f₁.projKerOfRightInverse f₂ h x : M) = x - f₂ (f₁ x)

{R : Type u_1}
[Ring R]
{R₂ : Type u_2}
[Ring R₂]
{M : Type u_4}
[TopologicalSpace M]
[AddCommGroup M]
{M₂ : Type u_5}
[TopologicalSpace M₂]
[AddCommGroup M₂]
[Module R M]
[Module R₂ M₂]
{σ₁₂ : R →+* R₂}
{σ₂₁ : R₂ →+* R}
[RingHomInvPair σ₁₂ σ₂₁]
[TopologicalAddGroup M]
(f₁ : M →SL[σ₁₂] M₂)
(f₂ : M₂ →SL[σ₂₁] M)
(h : Function.RightInverse ⇑f₂ ⇑f₁)
(x : M)

↑((f₁.projKerOfRightInverse f₂ h) x) = x - f₂ (f₁ x)


@[to_additive] lemma topology_eq_inf :
    instTopologicalSpaceUnits =
      .induced (val : Mˣ → M) ‹_› ⊓ .induced (fun u ↦ ↑u⁻¹ : Mˣ → M) ‹_›

{M : Type u_1}
[TopologicalSpace M]
[AddMonoid M]

AddUnits.instTopologicalSpaceAddUnits =
  TopologicalSpace.induced AddUnits.val inst✝ ⊓ TopologicalSpace.induced (fun u => ↑(-u)) inst✝


@[to_additive]
theorem inv_mem_Ioc_iff : a⁻¹ ∈ Set.Ioc c d ↔ a ∈ Set.Ico d⁻¹ c⁻¹

{α : Type u_1}
[OrderedAddCommGroup α]
{a c d : α}

-a ∈ Set.Ioc c d ↔ a ∈ Set.Ico (-d) (-c)


lemma ne_iff {f g : α →₀ M} : f ≠ g ↔ ∃ a, f a ≠ g a

{α : Type u_1}
{M : Type u_5}
[Zero M]
{f g : α →₀ M}


/-- The left unitor, a natural isomorphism `((𝟭 _) ⋙ F) ≅ F`.
-/
@[simps]
def leftUnitor (F : A ⥤ B) :
    𝟭 A ⋙ F ≅ F

{A : Type u₁}
[CategoryTheory.Category.{v₁, u₁} A]
{B : Type u₂}
[CategoryTheory.Category.{v₂, u₂} B]
(F : CategoryTheory.Functor A B)
(X : A)

F.leftUnitor.inv.app X = CategoryTheory.CategoryStruct.id (F.obj X)


@[simp]
lemma egauge_zero_right (hs : s.Nonempty) : egauge 𝕜 s 0 = 0

(𝕜 : Type u_1)
[NormedDivisionRing 𝕜]
{E : Type u_3}
[AddCommGroup E]
[Module 𝕜 E]
{s : Set E}
(hs : s.Nonempty)


/-- For every family of closed sets whose intersection avoids a compact set,
there exists a finite subfamily whose intersection avoids this compact set. -/
theorem IsCompact.elim_finite_subfamily_closed {ι : Type v} (hs : IsCompact s)
    (t : ι → Set X) (htc : ∀ i, IsClosed (t i)) (hst : (s ∩ ⋂ i, t i) = ∅) :
    ∃ u : Finset ι, (s ∩ ⋂ i ∈ u, t i) = ∅

{X : Type u}
[TopologicalSpace X]
{s : Set X}
{ι : Type v}
(hs : IsCompact s)
(t : ι → Set X)
(htc : ∀ (i : ι), IsClosed (t i))
(hst : s ∩ ⋂ i, t i = ∅)


private theorem card_mem_cof {o} : ∃ (ι : _) (f : ι → Ordinal), lsub.{u, u} f = o ∧ #ι = o.card


/-- If `f` is a partial homeomorphism defined on a neighbourhood of `f.symm a`, and `f` has an
invertible derivative `f'` in the sense of strict differentiability at `f.symm a`, then `f.symm` has
the derivative `f'⁻¹` at `a`.

This is one of the easy parts of the inverse function theorem: it assumes that we already have
an inverse function. -/
theorem PartialHomeomorph.hasStrictFDerivAt_symm (f : PartialHomeomorph E F) {f' : E ≃L[𝕜] F}
    {a : F} (ha : a ∈ f.target) (htff' : HasStrictFDerivAt f (f' : E →L[𝕜] F) (f.symm a)) :
    HasStrictFDerivAt f.symm (f'.symm : F →L[𝕜] E) a

(htff' : HasStrictFDerivAt (↑f) (↑f') (↑f.symm a))

HasStrictFDerivAt (↑f.symm) (↑f'.symm) a


theorem isGLB_image' {s : Set α} {x : α} : IsGLB (f '' s) (f x) ↔ IsGLB s x

{α : Type u_1}
{β : Type u_2}
[Preorder α]
[Preorder β]
(f : α ≃o β)
{s : Set α}
{x : α}


theorem filter_congr {s : Finset α} (H : ∀ x ∈ s, p x ↔ q x) : filter p s = filter q s

{α : Type u_1}
{p q : α → Prop}
[DecidablePred p]
[DecidablePred q]
{s : Finset α}
(H : ∀ x ∈ s, p x ↔ q x)


@[reassoc, simp]
theorem whiskerLeft_rightUnitor (X Y : C) :
    X ◁ (ρ_ Y).hom = (α_ X Y (𝟙_ C)).inv ≫ (ρ_ (X ⊗ Y)).hom

{C : Type u}
[CategoryTheory.Category.{v, u} C]
[CategoryTheory.MonoidalCategory C]
(X Y : C)

CategoryTheory.MonoidalCategory.whiskerLeft X (CategoryTheory.MonoidalCategory.rightUnitor Y).hom =
  CategoryTheory.CategoryStruct.comp (CategoryTheory.MonoidalCategory.associator X Y (𝟙_ C)).inv
    (CategoryTheory.MonoidalCategory.rightUnitor (CategoryTheory.MonoidalCategory.tensorObj X Y)).hom


@[simp]
theorem reverse_cons {u v w : V} (h : G.Adj u v) (p : G.Walk v w) :
    (cons h p).reverse = p.reverse.append (cons (G.symm h) nil)

{V : Type u}
{G : SimpleGraph V}
{u v w : V}
(h : G.Adj u v)
(p : G.Walk v w)

(SimpleGraph.Walk.cons h p).reverse = p.reverse.append (SimpleGraph.Walk.cons ⋯ SimpleGraph.Walk.nil)


@[simp]
theorem ennreal_coeFn_eq_coeFn_toMeasure (ν : ProbabilityMeasure Ω) (s : Set Ω) :
    (ν s : ℝ≥0∞) = (ν : Measure Ω) s

(ν : MeasureTheory.ProbabilityMeasure Ω)


theorem toIocDiv_sub_eq_toIocDiv_add (a b c : α) :
    toIocDiv hp a (b - c) = toIocDiv hp (a + c) b

{α : Type u_1}
[LinearOrderedAddCommGroup α]
[hα : Archimedean α]
{p : α}
(hp : 0 < p)
(a b c : α)


theorem sorted_zero_eq_min' {s : Finset α} {h : 0 < (s.sort (· ≤ ·)).length} :
    (s.sort (· ≤ ·)).get ⟨0, h⟩ = s.min' (card_pos.1 <| by rwa [length_sort] at h)

{h : 0 < (Finset.sort (fun x x_1 => x ≤ x_1) s).length}

(Finset.sort (fun x x_1 => x ≤ x_1) s).get ⟨0, h⟩ = s.min' ⋯


@[simp] theorem get_eq_getElem (l : List α) (i : Fin l.length) : l.get i = l[i.1]'i.2

{α : Type u_1}
(l : List α)
(i : Fin l.length)


lemma quasispectrum_eq_spectrum_union_zero (R : Type*) {A : Type*} [Semifield R] [Ring A]
    [Algebra R A] (a : A) : quasispectrum R a = spectrum R a ∪ {0}

(R : Type u_3)
{A : Type u_4}
[Semifield R]
[Ring A]
[Algebra R A]
(a : A)


@[to_additive]
theorem SeminormedGroup.tendstoUniformlyOn_one {f : ι → κ → G} {s : Set κ} {l : Filter ι} :
    TendstoUniformlyOn f 1 l s ↔ ∀ ε > 0, ∀ᶠ i in l, ∀ x ∈ s, ‖f i x‖ < ε

{ι : Type u_4}
{κ : Type u_5}
{G : Type u_8}
[SeminormedGroup G]
{f : ι → κ → G}
{s : Set κ}
{l : Filter ι}

TendstoUniformlyOn f 1 l s ↔ ∀ ε > 0, ∀ᶠ (i : ι) in l, ∀ x ∈ s, ‖f i x‖ < ε


/-- Given a `CompositionSeries`, `s`, and an element `x`
such that `x` is maximal inside `s.last` there is a series, `t`,
such that `t.last = x`, `t.head = s.head`
and `snoc t s.last _` is equivalent to `s`. -/
theorem exists_last_eq_snoc_equivalent (s : CompositionSeries X) (x : X) (hm : IsMaximal x s.last)
    (hb : s.head ≤ x) :
    ∃ t : CompositionSeries X,
      t.head = s.head ∧ t.length + 1 = s.length ∧
      ∃ htx : t.last = x,
        Equivalent s (snoc t s.last (show IsMaximal t.last _ from htx.symm ▸ hm))

(hm : JordanHolderLattice.IsMaximal x (RelSeries.last s))

∃ t,
  RelSeries.head t = RelSeries.head s ∧
    t.length + 1 = s.length ∧ ∃ (htx : RelSeries.last t = x), s.Equivalent (RelSeries.snoc t (RelSeries.last s) ⋯)


/-- The diameter of a set is always nonnegative -/
theorem diam_nonneg : 0 ≤ diam s

{α : Type u}
[PseudoMetricSpace α]
{s : Set α}


{R : Type u}
{L : Type v}
[CommRing R]
[LieRing L]
[LieAlgebra R L]
(I J : LieIdeal R L)


/-- Given a pair of monoid homomorphisms `f`, `g` such that `g.comp f = id` and `f.comp g = id`,
returns a multiplicative equivalence with `toFun = f` and `invFun = g`.  This constructor is
useful if the underlying type(s) have specialized `ext` lemmas for monoid homomorphisms. -/
@[to_additive (attr := simps (config := .asFn))
  "Given a pair of additive monoid homomorphisms `f`, `g` such that `g.comp f = id`
  and `f.comp g = id`, returns an additive equivalence with `toFun = f` and `invFun = g`.  This
  constructor is useful if the underlying type(s) have specialized `ext` lemmas for additive
  monoid homomorphisms."]
def MonoidHom.toMulEquiv [MulOneClass M] [MulOneClass N] (f : M →* N) (g : N →* M)
    (h₁ : g.comp f = MonoidHom.id _) (h₂ : f.comp g = MonoidHom.id _) : M ≃* N

{M : Type u_6}
{N : Type u_7}
[MulOneClass M]
[MulOneClass N]
(f : M →* N)
(g : N →* M)
(h₁ : g.comp f = MonoidHom.id M)
(h₂ : f.comp g = MonoidHom.id N)


@[to_additive AddCommute.zsmul_add]
protected lemma mul_zpow (h : Commute a b) : ∀ n : ℤ, (a * b) ^ n = a ^ n * b ^ n

{G : Type u_1}
[DivisionMonoid G]
{a b : G}
(h : Commute a b)
(n : ℤ)


@[simp]
theorem map_exp : map (f : A →+* A') (exp A) = exp A'

{A : Type u_1}
{A' : Type u_2}
[Ring A]
[Ring A']
[Algebra ℚ A]
[Algebra ℚ A']
(f : A →+* A')

(PowerSeries.map f) (PowerSeries.exp A) = PowerSeries.exp A'


protected theorem add_lt_add_left (a b : ℤ√d) (h : a < b) (c) : c + a < c + b

{d : ℕ}
(a b : ℤ√↑d)
(h : a < b)
(c : ℤ√↑d)


theorem insert_sdiff_of_mem (s : Finset α) {x : α} (h : x ∈ t) : insert x s \ t = s \ t

{α : Type u_1}
[DecidableEq α]
{t : Finset α}
(s : Finset α)
{x : α}
(h : x ∈ t)


@[simp] theorem mod_neg (a b : Int) : mod a (-b) = mod a b


@[simp]
theorem ceil_int : (Int.ceil : ℤ → ℤ) = id


theorem card_interedges_finpartition_left [DecidableEq α] (P : Finpartition s) (t : Finset β) :
    (interedges r s t).card = ∑ a ∈ P.parts, (interedges r a t).card

{α : Type u_4}
{β : Type u_5}
(r : α → β → Prop)
[(a : α) → DecidablePred (r a)]
{s : Finset α}
[DecidableEq α]
(P : Finpartition s)
(t : Finset β)

(Rel.interedges r s t).card = ∑ a ∈ P.parts, (Rel.interedges r a t).card


theorem Submodule.exists_isCompl (p : Submodule K V) : ∃ q : Submodule K V, IsCompl p q

{K : Type u_3}
{V : Type u_4}
[DivisionRing K]
[AddCommGroup V]
[Module K V]
(p : Submodule K V)


@[simp]
theorem orderIsoPUnitSumLex_symm_inr (a : α) : orderIsoPUnitSumLex.symm (toLex <| inr a) = a

WithBot.orderIsoPUnitSumLex.symm (toLex (Sum.inr a)) = ↑a


/-- The real inner product of two vectors, divided by the product of their
norms, has absolute value at most 1. -/
theorem abs_real_inner_div_norm_mul_norm_le_one (x y : F) : |⟪x, y⟫_ℝ / (‖x‖ * ‖y‖)| ≤ 1

{F : Type u_3}
[NormedAddCommGroup F]
[InnerProductSpace ℝ F]
(x y : F)


/-- This mixin class describes an order where all intervals bounded below are finite. This is
slightly weaker than `LocallyFiniteOrder` + `OrderTop` as it allows empty types. -/
class LocallyFiniteOrderTop (α : Type*) [Preorder α] where
  /-- Left-open right-infinite interval -/
  finsetIoi : α → Finset α
  /-- Left-closed right-infinite interval -/
  finsetIci : α → Finset α
  /-- `x ∈ finsetIci a ↔ a ≤ x` -/
  finset_mem_Ici : ∀ a x : α, x ∈ finsetIci a ↔ a ≤ x
  /-- `x ∈ finsetIoi a ↔ a < x` -/
  finset_mem_Ioi : ∀ a x : α, x ∈ finsetIoi a ↔ a < x

{α : Type u_1}
[Preorder α]
[self : LocallyFiniteOrderTop α]
(a x : α)

x ∈ LocallyFiniteOrderTop.finsetIoi a ↔ a < x


theorem liftPropWithinAt_mono_of_mem
    (mono_of_mem : ∀ ⦃s x t⦄ ⦃f : H → H'⦄, s ∈ 𝓝[t] x → P f s x → P f t x)
    (h : LiftPropWithinAt P g s x) (hst : s ∈ 𝓝[t] x) : LiftPropWithinAt P g t x

(mono_of_mem : ∀ ⦃s : Set H⦄ ⦃x : H⦄ ⦃t : Set H⦄ ⦃f : H → H'⦄, s ∈ 𝓝[t] x → P f s x → P f t x)

(h : ChartedSpace.LiftPropWithinAt P g s x)


lemma adjoin_eq (s : NonUnitalStarSubalgebra R A) : adjoin R (s : Set A) = s

{R : Type u}
{A : Type v}
[CommSemiring R]
[StarRing R]
[NonUnitalSemiring A]
[StarRing A]
[Module R A]
[IsScalarTower R A A]
[SMulCommClass R A A]
[StarModule R A]
(s : NonUnitalStarSubalgebra R A)


protected theorem mul_tsub (h : AddLECancellable (a * c)) : a * (b - c) = a * b - a * c

{α : Type u}
[CanonicallyOrderedCommSemiring α]
{a b c : α}
[Sub α]
[OrderedSub α]
[IsTotal α fun x x_1 => x ≤ x_1]
(h : AddLECancellable (a * c))


@[to_additive (attr := simp)] theorem MonoidHom.comp_id_grp
    {G : Grp.{u}} {H : Type u} [Group H] (f : G →* H) : f.comp (𝟙 G) = f

{G : Grp}
{H : Type u}
[Group H]
(f : ↑G →* H)


theorem max_eq_left {a b : α} (h : b ≤ a) : max a b = a

{α : Type u}
[LinearOrder α]
{a b : α}
(h : b ≤ a)


@[simp]
theorem equalizer_same (φ : F) : equalizer φ φ = ⊤

{R : Type u_1}
{A : Type u_2}
{B : Type u_3}
[CommSemiring R]
[Semiring A]
[Algebra R A]
[Semiring B]
[Algebra R B]
{F : Type u_4}
[FunLike F A B]
[AlgHomClass F R A B]
(φ : F)


theorem eq_star_of_eq_star [InvolutiveStar R] {r s : R} (h : r = star s) : s = star r

{R : Type u}
[InvolutiveStar R]
{r s : R}
(h : r = star s)


/-- An equivalence of groups, from the center of the special linear group to the roots of unity. -/
@[simps]
def center_equiv_rootsOfUnity' (i : n) :
    center (SpecialLinearGroup n R) ≃* rootsOfUnity (Fintype.card n).toPNat' R

(a : ↥(rootsOfUnity (Fintype.card n).toPNat' R))

↑↑((Matrix.SpecialLinearGroup.center_equiv_rootsOfUnity' i).symm a) = a • 1


/-- Given `G` acting on `X`, a functor from the corresponding action groupoid to a group `H`
    can be curried to a group homomorphism `G →* (X → H) ⋊ G`. -/
@[simps]
def curry (F : ActionCategory G X ⥤ SingleObj H) : G →* (X → H) ⋊[mulAutArrow] G

(F : CategoryTheory.Functor (CategoryTheory.ActionCategory G X) (CategoryTheory.SingleObj H))

((CategoryTheory.ActionCategory.curry F) g).left b = F.map (CategoryTheory.ActionCategory.homOfPair b g)


lemma quasispectrum_eq_spectrum_union (R : Type*) {A : Type*} [CommSemiring R]
    [Ring A] [Algebra R A] (a : A) : quasispectrum R a = spectrum R a ∪ {r : R | ¬ IsUnit r}

(R : Type u_3)
{A : Type u_4}
[CommSemiring R]
[Ring A]
[Algebra R A]
(a : A)

quasispectrum R a = spectrum R a ∪ {r | ¬IsUnit r}


@[csimp] private theorem pmap_eq_pmapImpl : @pmap = @pmapImpl


theorem image_coe_Ioo : (some : α → WithTop α) '' Ioo a b = Ioo (a : WithTop α) b

WithTop.some '' Set.Ioo a b = Set.Ioo ↑a ↑b


/-- `weightedVSubOfPoint` gives equal results for two families of weights and two families of
points that are equal on `s`. -/
theorem weightedVSubOfPoint_congr {w₁ w₂ : ι → k} (hw : ∀ i ∈ s, w₁ i = w₂ i) {p₁ p₂ : ι → P}
    (hp : ∀ i ∈ s, p₁ i = p₂ i) (b : P) :
    s.weightedVSubOfPoint p₁ b w₁ = s.weightedVSubOfPoint p₂ b w₂

{k : Type u_1}
{V : Type u_2}
{P : Type u_3}
[Ring k]
[AddCommGroup V]
[Module k V]
[S : AffineSpace V P]
{ι : Type u_4}
(s : Finset ι)
{w₁ w₂ : ι → k}
(hw : ∀ i ∈ s, w₁ i = w₂ i)
{p₁ p₂ : ι → P}
(hp : ∀ i ∈ s, p₁ i = p₂ i)
(b : P)

(s.weightedVSubOfPoint p₁ b) w₁ = (s.weightedVSubOfPoint p₂ b) w₂


theorem map_injective (hf : Function.Injective f) :
    Function.Injective (map f : MvPolynomial σ R → MvPolynomial σ S₁)

{R : Type u}
{S₁ : Type v}
{σ : Type u_1}
[CommSemiring R]
[CommSemiring S₁]
(f : R →+* S₁)
(hf : Function.Injective ⇑f)


/-- The first projection on a domain in a product is `C^∞`. -/
theorem contDiffOn_fst {s : Set (E × F)} : ContDiffOn 𝕜 n (Prod.fst : E × F → E) s

{𝕜 : Type u_1}
[NontriviallyNormedField 𝕜]
{E : Type uE}
[NormedAddCommGroup E]
[NormedSpace 𝕜 E]
{F : Type uF}
[NormedAddCommGroup F]
[NormedSpace 𝕜 F]
{n : ℕ∞}
{s : Set (E × F)}


theorem pow_le_pow_right {m n : ℕ} (h : m ≤ n) : I ^ n ≤ I ^ m

{R : Type u}
[CommSemiring R]
{I : Ideal R}
{m n : ℕ}
(h : m ≤ n)


theorem congr_fun {f g : MultilinearMap R M₁ M₂} (h : f = g) (x : ∀ i, M₁ i) : f x = g x

{R : Type uR}
{ι : Type uι}
{M₁ : ι → Type v₁}
{M₂ : Type v₂}
[Semiring R]
[(i : ι) → AddCommMonoid (M₁ i)]
[AddCommMonoid M₂]
[(i : ι) → Module R (M₁ i)]
[Module R M₂]
{f g : MultilinearMap R M₁ M₂}
(h : f = g)
(x : (i : ι) → M₁ i)


@[to_additive (attr := simp)]
theorem mem_op {x : Mᵐᵒᵖ} {S : Submonoid M} : x ∈ S.op ↔ x.unop ∈ S

{M : Type u_2}
[MulOneClass M]
{x : Mᵐᵒᵖ}
{S : Submonoid M}


lemma exact_of_iso (e : S₁ ≅ S₂) (h : S₁.Exact) : S₂.Exact


@[simp]
theorem colimitCurrySwapCompColimIsoColimitCurryCompColim_ι_ι_inv {j} {k} :
    colimit.ι _ k ≫ colimit.ι (curry.obj G ⋙ colim) j ≫
      (colimitCurrySwapCompColimIsoColimitCurryCompColim G).inv =
        (colimit.ι _ j ≫
          colimit.ι (curry.obj _ ⋙ colim) k :
            _ ⟶ colimit (curry.obj (Prod.swap K J ⋙ G) ⋙ colim))

{J K : Type v}
[CategoryTheory.SmallCategory J]
[CategoryTheory.SmallCategory K]
{C : Type u}
[CategoryTheory.Category.{v, u} C]
(G : J × K ⥤ C)
[CategoryTheory.Limits.HasColimits C]
{j : J}
{k : K}

CategoryTheory.Limits.colimit.ι ((CategoryTheory.curry.obj G).obj j) k ≫
    CategoryTheory.Limits.colimit.ι (CategoryTheory.curry.obj G ⋙ CategoryTheory.Limits.colim) j ≫
      (CategoryTheory.Limits.colimitCurrySwapCompColimIsoColimitCurryCompColim G).inv =
  CategoryTheory.Limits.colimit.ι ((CategoryTheory.curry.obj (CategoryTheory.Prod.swap K J ⋙ G)).obj k) j ≫
    CategoryTheory.Limits.colimit.ι
      (CategoryTheory.curry.obj (CategoryTheory.Prod.swap K J ⋙ G) ⋙ CategoryTheory.Limits.colim) k


/-- `CentroidHomClass F α` states that `F` is a type of centroid homomorphisms.

You should extend this class when you extend `CentroidHom`. -/
class CentroidHomClass (F α : Type*) [NonUnitalNonAssocSemiring α] [FunLike F α α] extends
  AddMonoidHomClass F α α : Prop where
  /-- Commutativity of centroid homomorphims with left multiplication. -/
  map_mul_left (f : F) (a b : α) : f (a * b) = a * f b
  /-- Commutativity of centroid homomorphims with right multiplication. -/
  map_mul_right (f : F) (a b : α) : f (a * b) = f a * b

{F : Type u_6}
{α : Type u_7}
[NonUnitalNonAssocSemiring α]
[FunLike F α α]
[self : CentroidHomClass F α]
(f : F)
(a b : α)


@[simp]
theorem mem_neLocus {f g : α →₀ N} {a : α} : a ∈ f.neLocus g ↔ f a ≠ g a

{α : Type u_1}
{N : Type u_3}
[DecidableEq α]
[DecidableEq N]
[Zero N]
{f g : α →₀ N}
{a : α}


theorem Measurable.map_prod_mk_left [SFinite ν] :
    Measurable fun x : α => map (Prod.mk x) ν

{α : Type u_1}
{β : Type u_3}
[MeasurableSpace α]
[MeasurableSpace β]
{ν : MeasureTheory.Measure β}
[MeasureTheory.SFinite ν]

Measurable fun x => MeasureTheory.Measure.map (Prod.mk x) ν


theorem isRotated_next_eq {l l' : List α} (h : l ~r l') (hn : Nodup l) {x : α} (hx : x ∈ l) :
    l.next x hx = l'.next x (h.mem_iff.mp hx)

{α : Type u_1}
[DecidableEq α]
{l l' : List α}
(h : l ~r l')
(hn : l.Nodup)
{x : α}
(hx : x ∈ l)


theorem coe_injective : Function.Injective (Coe.coe : R[X] → PowerSeries R)


@[simp]
theorem mapAction_μ_inv_hom (X Y : Action V G) :
    (inv ((F.mapAction G).μ X Y)).hom = inv (F.μ X.V Y.V)

(F : CategoryTheory.MonoidalFunctor V W)

(CategoryTheory.inv ((F.mapAction G).μ X Y)).hom = CategoryTheory.inv (F.μ X.V Y.V)


@[simp]
theorem support_zero : (0 : MvPolynomial σ R).support = ∅

{R : Type u}
{σ : Type u_1}
[CommSemiring R]


/-- If `f` has a local max on `s` at `a` and `y` belongs to the positive tangent cone
of `s` at `a`, then `f' y ≤ 0`. -/
theorem IsLocalMaxOn.fderivWithin_nonpos (h : IsLocalMaxOn f s a)
    (hy : y ∈ posTangentConeAt s a) : (fderivWithin ℝ f s a : E → ℝ) y ≤ 0

{E : Type u}
[NormedAddCommGroup E]
[NormedSpace ℝ E]
{f : E → ℝ}
{s : Set E}
{a y : E}
(h : IsLocalMaxOn f s a)
(hy : y ∈ posTangentConeAt s a)


@[simp]
theorem mul_smul [Fintype n] [Monoid R] [DistribMulAction R α] [SMulCommClass R α α]
    (M : Matrix m n α) (a : R) (N : Matrix n l α) : M * (a • N) = a • (M * N)

{l : Type u_1}
{m : Type u_2}
{n : Type u_3}
{R : Type u_7}
{α : Type v}
[AddCommMonoid α]
[Mul α]
[Fintype n]
[Monoid R]
[DistribMulAction R α]
[SMulCommClass R α α]
(M : Matrix m n α)
(a : R)
(N : Matrix n l α)


@[simp]
theorem div'_to_nat (n d) : (div' n d : ℕ) = n / d


lemma eq_of_mem_uIoc_of_mem_uIoc' : b ∈ Ι a c → c ∈ Ι a b → b = c

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


theorem two_nsmul_ne_zero_iff {θ : Angle} : (2 : ℕ) • θ ≠ 0 ↔ θ ≠ 0 ∧ θ ≠ π

2 • θ ≠ 0 ↔ θ ≠ 0 ∧ θ ≠ ↑π


theorem monotone_gen : Monotone (gen : Set (α × α) → _)


@[simp]
theorem coe_mk {f h h₀ h₁ h₂ h₃ h₄ h₅} :
    (⟨⟨⟨⟨f, h⟩, h₀⟩, h₁, h₂⟩, h₃, h₄, h₅⟩ : A ≃ₗc[R] B) = f

{h : ∀ (x y : A), f (x + y) = f x + f y}

{h₀ :
  ∀ (m : R) (x : A),
    { toFun := f, map_add' := h }.toFun (m • x) = (RingHom.id R) m • { toFun := f, map_add' := h }.toFun x}

{h₁ : Coalgebra.counit ∘ₗ { toFun := f, map_add' := h, map_smul' := h₀ } = Coalgebra.counit}

{h₂ :
  TensorProduct.map { toFun := f, map_add' := h, map_smul' := h₀ } { toFun := f, map_add' := h, map_smul' := h₀ } ∘ₗ
      Coalgebra.comul =
    Coalgebra.comul ∘ₗ { toFun := f, map_add' := h, map_smul' := h₀ }}

{h₄ :
  Function.LeftInverse h₃ { toFun := f, map_add' := h, map_smul' := h₀, counit_comp := h₁, map_comp_comul := h₂ }.toFun}

{h₅ :
  Function.RightInverse h₃
    { toFun := f, map_add' := h, map_smul' := h₀, counit_comp := h₁, map_comp_comul := h₂ }.toFun}

⇑{ toFun := f, map_add' := h, map_smul' := h₀, counit_comp := h₁, map_comp_comul := h₂, invFun := h₃, left_inv := h₄,
      right_inv := h₅ } =
  f


@[simp]
theorem srange_subtype (s : NonUnitalSubsemiring R) : NonUnitalRingHom.srange (subtype s) = s

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

NonUnitalRingHom.srange (NonUnitalSubsemiringClass.subtype s) = s


@[simp]
theorem mem_onTheory {g : L →ᴸ L'} {T : L.Theory} {φ : L'.Sentence} :
    φ ∈ g.onTheory T ↔ ∃ φ₀, φ₀ ∈ T ∧ g.onSentence φ₀ = φ

{L : FirstOrder.Language}
{L' : FirstOrder.Language}
{g : L →ᴸ L'}
{T : L.Theory}
{φ : L'.Sentence}

φ ∈ g.onTheory T ↔ ∃ φ₀ ∈ T, g.onSentence φ₀ = φ


@[simp]
theorem smul_testAgainstNN_apply (c : ℝ≥0) (μ : FiniteMeasure Ω) (f : Ω →ᵇ ℝ≥0) :
    (c • μ).testAgainstNN f = c • μ.testAgainstNN f

{Ω : Type u_1}
[MeasurableSpace Ω]
[TopologicalSpace Ω]
(c : ℝ≥0)
(μ : MeasureTheory.FiniteMeasure Ω)
(f : Ω →ᵇ ℝ≥0)


theorem ModelWithCorners.range_prod : range (I.prod J) = range I ×ˢ range J

{𝕜 : Type u_1}
[NontriviallyNormedField 𝕜]
{E : Type u_2}
[NormedAddCommGroup E]
[NormedSpace 𝕜 E]
{F : Type u_4}
[NormedAddCommGroup F]
[NormedSpace 𝕜 F]
{H : Type u_6}
[TopologicalSpace H]
{G : Type u_8}
[TopologicalSpace G]
{I : ModelWithCorners 𝕜 E H}
{J : ModelWithCorners 𝕜 F G}

Set.range ↑(I.prod J) = Set.range ↑I ×ˢ Set.range ↑J


@[simp]
theorem toFinsupp_apply (s : Multiset α) (a : α) : toFinsupp s a = s.count a

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

(Multiset.toFinsupp s) a = Multiset.count a s


@[ext]
protected theorem ext {s t : Closeds α} (h : (s : Set α) = t) : s = t

{α : Type u_2}
[TopologicalSpace α]
{s t : TopologicalSpace.Closeds α}
(h : ↑s = ↑t)


theorem rayleigh_smul (x : E) {c : 𝕜} (hc : c ≠ 0) :
    rayleighQuotient T (c • x) = rayleighQuotient T x

{𝕜 : Type u_1}
[RCLike 𝕜]
{E : Type u_2}
[NormedAddCommGroup E]
[InnerProductSpace 𝕜 E]
(T : E →L[𝕜] E)
(x : E)
{c : 𝕜}
(hc : c ≠ 0)

T.rayleighQuotient (c • x) = T.rayleighQuotient x


@[simp]
theorem toMul_zero [One α] : toMul (0 : Additive α) = 1


@[simp]
theorem antisymm_symm [IsWellOrder α r] [IsWellOrder β s] (f : r ≼i s) (g : s ≼i r) :
    (antisymm f g).symm = antisymm g f

{α : Type u_1}
{β : Type u_2}
{r : α → α → Prop}
{s : β → β → Prop}
[IsWellOrder α r]
[IsWellOrder β s]
(f : r ≼i s)
(g : s ≼i r)


theorem st_inv (x : ℝ*) : st x⁻¹ = (st x)⁻¹


theorem derivWithin_ccos (hf : DifferentiableWithinAt ℂ f s x) (hxs : UniqueDiffWithinAt ℂ s x) :
    derivWithin (fun x => Complex.cos (f x)) s x = -Complex.sin (f x) * derivWithin f s x

{f : ℂ → ℂ}
{x : ℂ}
{s : Set ℂ}
(hf : DifferentiableWithinAt ℂ f s x)
(hxs : UniqueDiffWithinAt ℂ s x)


@[simp]
theorem toNNRat_le_toNNRat_iff (hp : 0 ≤ p) : toNNRat q ≤ toNNRat p ↔ q ≤ p


/-- A split equalizer diagram consists of morphisms

```
      ι   f
    W → X ⇉ Y
          g
```

satisfying `ι ≫ f = ι ≫ g` together with morphisms

```
      r   t
    W ← X ← Y
```

satisfying `ι ≫ r = 𝟙 W`, `g ≫ t = 𝟙 X` and `f ≫ t = r ≫ ι`.

The name "equalizer" is appropriate, since any split equalizer is a equalizer, see
`CategoryTheory.IsSplitEqualizer.isEqualizer`.
Split equalizers are also absolute, since a functor preserves all the structure above.
-/
structure IsSplitEqualizer {W : C} (ι : W ⟶ X) where
  /-- A map from `X` to the equalizer -/
  leftRetraction : X ⟶ W
  /-- A map in the opposite direction to `f` and `g` -/
  rightRetraction : Y ⟶ X
  /-- Composition of `ι` with `f` and with `g` agree -/
  condition : ι ≫ f = ι ≫ g := by aesop_cat
  /-- `leftRetraction` splits `ι` -/
  ι_leftRetraction : ι ≫ leftRetraction = 𝟙 W := by aesop_cat
  /-- `rightRetraction` splits `g` -/
  bottom_rightRetraction : g ≫ rightRetraction = 𝟙 X := by aesop_cat
  /-- `f` composed with `rightRetraction` is `leftRetraction` composed with `ι` -/
  top_rightRetraction : f ≫ rightRetraction = leftRetraction ≫ ι := by aesop_cat

(self : CategoryTheory.IsSplitEqualizer f g ι)

CategoryTheory.CategoryStruct.comp ι self.leftRetraction = CategoryTheory.CategoryStruct.id W


@[symm]
protected theorem Reachable.symm {u v : V} (huv : G.Reachable u v) : G.Reachable v u

{V : Type u}
{G : SimpleGraph V}
{u v : V}
(huv : G.Reachable u v)


theorem principal_mul_isLimit {o : Ordinal.{u}} (ho₂ : 2 < o) (ho : Principal (· * ·) o) :
    o.IsLimit

(ho : Ordinal.Principal (fun x x_1 => x * x_1) o)


@[to_additive (attr := simp, norm_cast)]
theorem coe_toOpens : ((U : Opens G) : Set G) = U

{G : Type u_1}
[Group G]
[TopologicalSpace G]
{U : OpenSubgroup G}


@[to_additive]
theorem IsUpperSet.mul_left (ht : IsUpperSet t) : IsUpperSet (s * t)

{α : Type u_1}
[OrderedAddCommGroup α]
{s t : Set α}
(ht : IsUpperSet t)


@[to_additive (attr := simp)]
theorem quotientiInfSubgroupOfEmbedding_apply_mk {ι : Type*} (f : ι → Subgroup α) (H : Subgroup α)
    (g : H) (i : ι) :
    quotientiInfSubgroupOfEmbedding f H (QuotientGroup.mk g) i =
      (QuotientGroup.mk g : { x // x ∈ H } ⧸ subgroupOf (f i) H)

{α : Type u_1}
[AddGroup α]
{ι : Type u_2}
(f : ι → AddSubgroup α)
(H : AddSubgroup α)
(g : ↥H)
(i : ι)

(AddSubgroup.quotientiInfAddSubgroupOfEmbedding f H) (↑g) i = ↑g


@[simp]
theorem MapsTo.val_restrict_apply (h : MapsTo f s t) (x : s) : (h.restrict f s t x : β) = f x

{α : Type u_1}
{β : Type u_2}
{s : Set α}
{t : Set β}
{f : α → β}
(h : Set.MapsTo f s t)
(x : ↑s)


@[simp]
lemma inv_top : (⊤ : EReal)⁻¹ = 0


theorem StrictAnti.lt_iff_lt (hf : StrictAnti f) {a b : α} : f a < f b ↔ b < a

{α : Type u}
{β : Type v}
[LinearOrder α]
[Preorder β]
{f : α → β}
(hf : StrictAnti f)
{a b : α}


theorem desc_op_comp_opCoproductIsoProduct'_hom {c : Cofan Z} {f : Fan (op <| Z ·)}
    (hc : IsColimit c) (hf : IsLimit f) (c' : Cofan Z) :
    (hc.desc c').op ≫ (opCoproductIsoProduct' hc hf).hom = hf.lift c'.op

{f : CategoryTheory.Limits.Fan fun x => Opposite.op (Z x)}

(hc : CategoryTheory.Limits.IsColimit c)

(hc.desc c').op ≫ (CategoryTheory.Limits.opCoproductIsoProduct' hc hf).hom = hf.lift c'.op


@[simp, norm_cast]
theorem coe_bipartiteAbove : (t.bipartiteAbove r a : Set β) = { b ∈ t | r a b }

{α : Type u_1}
{β : Type u_2}
(r : α → β → Prop)
(t : Finset β)
(a : α)
[DecidablePred (r a)]

↑(Finset.bipartiteAbove r t a) = {b | b ∈ t ∧ r a b}


theorem cauchy_map_iff' {l : Filter β} [hl : NeBot l] {f : β → α} :
    Cauchy (l.map f) ↔ Tendsto (fun p : β × β => (f p.1, f p.2)) (l ×ˢ l) (𝓤 α)

{α : Type u}
{β : Type v}
[uniformSpace : UniformSpace α]
{l : Filter β}
[hl : l.NeBot]
{f : β → α}

Cauchy (Filter.map f l) ↔ Filter.Tendsto (fun p => (f p.1, f p.2)) (l ×ˢ l) (𝓤 α)


@[measurability]
theorem AEMeasurable.const_sup (hf : AEMeasurable f μ) (c : M) :
    AEMeasurable (fun x => c ⊔ f x) μ

{M : Type u_1}
[MeasurableSpace M]
{α : Type u_2}
{m : MeasurableSpace α}
{μ : MeasureTheory.Measure α}
{f : α → M}
[Sup M]
[MeasurableSup M]
(hf : AEMeasurable f μ)
(c : M)


theorem IsLocallyInjective.comp_right {f : X → Y} (hf : IsLocallyInjective f) {g : A → X}
    (cont : Continuous g) (hg : g.Injective) : IsLocallyInjective (f ∘ g)

{X : Type u_1}
{Y : Type u_2}
{A : Type u_3}
[TopologicalSpace X]
[TopologicalSpace A]
{f : X → Y}
(hf : IsLocallyInjective f)
{g : A → X}
(cont : Continuous g)
(hg : Function.Injective g)


/-- Precomposing `f` with `Prod.snd` is continuous at `(x, y)` -/
theorem ContinuousAt.snd' {f : Y → Z} {x : X} {y : Y} (hf : ContinuousAt f y) :
    ContinuousAt (fun x : X × Y => f x.snd) (x, y)

{X : Type u}
{Y : Type v}
{Z : Type u_1}
[TopologicalSpace X]
[TopologicalSpace Y]
[TopologicalSpace Z]
{f : Y → Z}
{x : X}
{y : Y}
(hf : ContinuousAt f y)


theorem choose_spec (hp : ∃ a, a ∈ l ∧ p a) : choose p l hp ∈ l ∧ p (choose p l hp)

{α : Type u}
(p : α → Prop)
[DecidablePred p]
(l : List α)
(hp : ∃ a, a ∈ l ∧ p a)

List.choose p l hp ∈ l ∧ p (List.choose p l hp)


theorem exists_eq_mul_left_of_dvd (h : a ∣ b) : ∃ c, b = c * a

{α : Type u_1}
[CommSemigroup α]
{a b : α}
(h : a ∣ b)


@[to_additive Nat.Coprime.nsmul_right_bijective]
lemma Nat.Coprime.pow_left_bijective (hn : (Nat.card G).Coprime n) : Bijective (· ^ n : G → G)

{G : Type u_1}
[Group G]
{n : ℕ}
(hn : (Nat.card G).Coprime n)


@[trans]
theorem mem_of_mem_of_le {x : P} {I J : Ideal P} : x ∈ I → I ≤ J → x ∈ J

{P : Type u_1}
[LE P]
{x : P}
{I J : Order.Ideal P}


theorem epi_inl_of_is_pushout_of_epi {t : PushoutCocone f g} (ht : IsColimit t) [Epi g] :
    Epi t.inl

{t : CategoryTheory.Limits.PushoutCocone f g}

(ht : CategoryTheory.Limits.IsColimit t)


/-- Given two bifunctors `F : C₁ ⥤ C₂₃ ⥤ C₄` and `G₂₃ : C₂ ⥤ C₃ ⥤ C₄`, this is
the trifunctor `C₁ ⥤ C₂ ⥤ C₃ ⥤ C₄` obtained by composition. -/
@[simps]
def bifunctorComp₂₃ : C₁ ⥤ C₂ ⥤ C₃ ⥤ C₄

(F : CategoryTheory.Functor C₁ (CategoryTheory.Functor C₂₃ C₄))

(G₂₃ : CategoryTheory.Functor C₂ (CategoryTheory.Functor C₃ C₂₃))

(((CategoryTheory.bifunctorComp₂₃ F G₂₃).map φ).app X₂).app X₃ = (F.map φ).app ((G₂₃.obj X₂).obj X₃)


theorem sum_apply [AddCommMonoid α] (i : m) (j : n) (s : Finset β) (g : β → Matrix m n α) :
    (∑ c ∈ s, g c) i j = ∑ c ∈ s, g c i j

{m : Type u_2}
{n : Type u_3}
{α : Type v}
{β : Type w}
[AddCommMonoid α]
(i : m)
(j : n)
(s : Finset β)
(g : β → Matrix m n α)


theorem image₂_subset (hs : s ⊆ s') (ht : t ⊆ t') : image₂ f s t ⊆ image₂ f s' t'

{α : Type u_1}
{β : Type u_3}
{γ : Type u_5}
[DecidableEq γ]
{f : α → β → γ}
{s s' : Finset α}
{t t' : Finset β}
(hs : s ⊆ s')
(ht : t ⊆ t')

Finset.image₂ f s t ⊆ Finset.image₂ f s' t'


@[simp]
theorem updateColumn_eq_self [DecidableEq n] (A : Matrix m n α) (i : n) :
    (A.updateColumn i fun j => A j i) = A

{m : Type u_2}
{n : Type u_3}
{α : Type v}
[DecidableEq n]
(A : Matrix m n α)
(i : n)


@[simp]
theorem image_eq_iff_eq {α β} (e : α ≃ β) (s t : Set α) : e '' s = e '' t ↔ s = t

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


@[to_additive] lemma card_le_card_div_right (ht : t.Nonempty) : s.card ≤ (s / t).card

{α : Type u_2}
[AddGroup α]
[DecidableEq α]
{s t : Finset α}
(ht : t.Nonempty)


@[simp]
theorem isometryEquivMap.apply_symm_apply {E : AffineSubspace 𝕜 P₁'} [Nonempty E]
    {φ : P₁' →ᵃⁱ[𝕜] P₂} (x : E.map φ.toAffineMap) : φ ((E.isometryEquivMap φ).symm x) = x

(x : ↥(AffineSubspace.map φ.toAffineMap E))

φ ↑((AffineSubspace.isometryEquivMap φ E).symm x) = ↑x


@[to_additive]
theorem min_mul_mul_left (a b c : α) : min (a * b) (a * c) = a * min b c

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


@[simp]
lemma pullback.map_id {X Y Z : C}
    {f : X ⟶ Z} {g : Y ⟶ Z} [HasPullback f g] :
    pullback.map f g f g (𝟙 _) (𝟙 _) (𝟙 _) (by simp) (by simp) = 𝟙 _

{C : Type u}
[CategoryTheory.Category.{v, u} C]
{X Y Z : C}
{f : X ⟶ Z}
{g : Y ⟶ Z}
[CategoryTheory.Limits.HasPullback f g]

CategoryTheory.Limits.pullback.map f g f g (𝟙 X) (𝟙 Y) (𝟙 Z) ⋯ ⋯ = 𝟙 (CategoryTheory.Limits.pullback f g)


@[reassoc (attr := simp)]
theorem colimit.isoColimitCocone_ι_hom {F : J ⥤ C} [HasColimit F] (t : ColimitCocone F) (j : J) :
    colimit.ι F j ≫ (colimit.isoColimitCocone t).hom = t.cocone.ι.app j

(t : CategoryTheory.Limits.ColimitCocone F)

CategoryTheory.Limits.colimit.ι F j ≫ (CategoryTheory.Limits.colimit.isoColimitCocone t).hom = t.cocone.ι.app j


@[simp]
lemma coeff_preΨ (n : ℤ) : (W.preΨ n).coeff ((n.natAbs ^ 2 - if Even n then 4 else 1) / 2) =
    if Even n then n / 2 else n

{R : Type u}
[CommRing R]
(W : WeierstrassCurve R)
(n : ℤ)

(W.preΨ n).coeff ((n.natAbs ^ 2 - if Even n then 4 else 1) / 2) = ↑(if Even n then n / 2 else n)


@[simp]
theorem not_ite_eq_false_eq_true (p : Prop) [h : Decidable p] (b c : Bool) :
  ¬(ite p (b = false) (c = true)) ↔ (ite p (b = true) (c = false))

(¬if p then b = false else c = true) ↔ if p then b = true else c = false


@[simp] theorem beq_cons_nil [BEq α] [BEq β] : ((.cons a b t : AssocList α β) == .nil) = false

{α : Type u_1}
{β : Type u_2}
{a : α}
{b : β}
{t : Batteries.AssocList α β}
[BEq α]
[BEq β]

(Batteries.AssocList.cons a b t == Batteries.AssocList.nil) = false


protected theorem sub_neg_of_lt {a b : Int} (h : a < b) : a - b < 0


theorem tendsto_zero_iff_abs_tendsto_zero (f : α → G) :
    Tendsto f l (𝓝 0) ↔ Tendsto (abs ∘ f) l (𝓝 0)

{α : Type u_1}
{G : Type u_2}
[TopologicalSpace G]
[LinearOrderedAddCommGroup G]
[OrderTopology G]
{l : Filter α}
(f : α → G)

Filter.Tendsto f l (𝓝 0) ↔ Filter.Tendsto (abs ∘ f) l (𝓝 0)


@[simp]
theorem Quotient.liftOn₂_mk {α : Sort*} {β : Sort*} [Setoid α] (f : α → α → β)
    (h : ∀ a₁ a₂ b₁ b₂ : α, a₁ ≈ b₁ → a₂ ≈ b₂ → f a₁ a₂ = f b₁ b₂) (x y : α) :
    Quotient.liftOn₂ (Quotient.mk _ x) (Quotient.mk _ y) f h = f x y

(f : α → α → β)

(h : ∀ (a₁ a₂ b₁ b₂ : α), a₁ ≈ b₁ → a₂ ≈ b₂ → f a₁ a₂ = f b₁ b₂)


theorem Prime.dvd_of_dvd_pow {p m n : ℕ} (pp : Prime p) (h : p ∣ m ^ n) : p ∣ m

{p m n : ℕ}
(pp : Nat.Prime p)
(h : p ∣ m ^ n)


@[simp, norm_cast]
theorem cast_one : ((1 : ℚ) : α) = 1


@[to_additive (attr := simp)]
theorem closure_univ : closure (univ : Set G) = ⊤


@[simp]
theorem antipode_eq_id : antipode (R := R) (A := R) = .id


theorem coe_ne_zero {x : ℝ} : (x : EReal) ≠ 0 ↔ x ≠ 0

↑x ≠ 0 ↔ x ≠ 0


theorem pos_of_mul_neg_right [ExistsAddOfLE α] [MulPosMono α]
    [CovariantClass α α (swap (· + ·)) (· ≤ ·)] [ContravariantClass α α (swap (· + ·)) (· ≤ ·)]
    {a b : α} (h : a * b < 0) (ha : a ≤ 0) : 0 < b

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

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


theorem Finite.infsep_exists_of_nontrivial (hsf : s.Finite) (hs : s.Nontrivial) :
    ∃ x ∈ s, ∃ y ∈ s, x ≠ y ∧ s.infsep = dist x y

{α : Type u_1}
[PseudoMetricSpace α]
{s : Set α}
(hsf : s.Finite)
(hs : s.Nontrivial)


theorem toNNReal_add {r₁ r₂ : ℝ≥0∞} (h₁ : r₁ ≠ ∞) (h₂ : r₂ ≠ ∞) :
    (r₁ + r₂).toNNReal = r₁.toNNReal + r₂.toNNReal

{r₁ r₂ : ℝ≥0∞}
(h₁ : r₁ ≠ ⊤)
(h₂ : r₂ ≠ ⊤)


/-- Reinterpret `α →+ Additive β` as `Multiplicative α →* β`. -/
@[simps]
def AddMonoidHom.toMultiplicative'' [AddZeroClass α] [MulOneClass β] :
    (α →+ Additive β) ≃ (Multiplicative α →* β)

{α : Type u}
{β : Type v}
[AddZeroClass α]
[MulOneClass β]
(f : Multiplicative α →* β)
(a : α)

(AddMonoidHom.toMultiplicative''.symm f) a = Additive.ofMul (f (Multiplicative.ofAdd a))


/-- The polar `polar 𝕜 s` of a set `s : E` is a closed subset when the weak star topology
is used. -/
theorem isClosed_polar (s : Set E) : IsClosed (polar 𝕜 s)

(𝕜 : Type u_1)
[NontriviallyNormedField 𝕜]
{E : Type u_2}
[SeminormedAddCommGroup E]
[NormedSpace 𝕜 E]
(s : Set E)


@[simp]
theorem HomogeneousIdeal.toIdeal_homogeneousCore_eq_self (I : HomogeneousIdeal 𝒜) :
    I.toIdeal.homogeneousCore 𝒜 = I

{ι : Type u_1}
{σ : Type u_2}
{A : Type u_4}
[Semiring A]
[SetLike σ A]
[AddSubmonoidClass σ A]
{𝒜 : ι → σ}
[DecidableEq ι]
[AddMonoid ι]
[GradedRing 𝒜]
(I : HomogeneousIdeal 𝒜)


@[to_additive]
lemma continuous_mulIndicator (hs : ∀ a ∈ frontier s, f a = 1) (hf : ContinuousOn f (closure s)) :
    Continuous (mulIndicator s f)

{α : Type u_1}
{β : Type u_2}
[TopologicalSpace α]
[TopologicalSpace β]
[Zero β]
{f : α → β}
{s : Set α}
(hs : ∀ a ∈ frontier s, f a = 0)
(hf : ContinuousOn f (closure s))


@[to_additive]
theorem alternatingProd_append :
    ∀ l₁ l₂ : List α,
      alternatingProd (l₁ ++ l₂) = alternatingProd l₁ * alternatingProd l₂ ^ (-1 : ℤ) ^ length l₁

{α : Type u_2}
[AddCommGroup α]
(l₁ l₂ : List α)

(l₁ ++ l₂).alternatingSum = l₁.alternatingSum + (-1) ^ l₁.length • l₂.alternatingSum


@[simp]
lemma productEquiv_symm_apply_π (x : ∀ j, F j) (j : J) :
    Pi.π F j ((productEquiv F).symm x) = x j

[CategoryTheory.Limits.PreservesLimit (CategoryTheory.Discrete.functor F) (CategoryTheory.forget C)]

(x : (j : J) → (CategoryTheory.forget C).obj (F j))

(CategoryTheory.Limits.Pi.π F j) ((CategoryTheory.Limits.Concrete.productEquiv F).symm x) = x j


@[to_additive (attr := simp) fst_comp_prod]
theorem fst_comp_prod (f : M →ₙ* N) (g : M →ₙ* P) : (fst N P).comp (f.prod g) = f

{M : Type u_5}
{N : Type u_6}
{P : Type u_7}
[Add M]
[Add N]
[Add P]
(f : AddHom M N)
(g : AddHom M P)


/-- The inclusion of locally-constant functions into continuous functions as a multiplicative
monoid hom. -/
@[to_additive (attr := simps)
"The inclusion of locally-constant functions into continuous functions as an additive monoid hom."]
def toContinuousMapMonoidHom [Monoid Y] [ContinuousMul Y] : LocallyConstant X Y →* C(X, Y)

{X : Type u_1}
{Y : Type u_2}
[TopologicalSpace X]
[TopologicalSpace Y]
[AddMonoid Y]
[ContinuousAdd Y]
(f : LocallyConstant X Y)

LocallyConstant.toContinuousMapAddMonoidHom f = ↑f


theorem closure_iUnion {ι} (s : ι → Set R) : closure (⋃ i, s i) = ⨆ i, closure (s i)

{R : Type u}
[NonUnitalNonAssocRing R]
{ι : Sort u_2}
(s : ι → Set R)

NonUnitalSubring.closure (⋃ i, s i) = ⨆ i, NonUnitalSubring.closure (s i)


lemma uIoc_eq_union : Ι a b = Ioc a b ∪ Ioc b a

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


@[to_additive (attr := simp)]
theorem inv_eq_empty : s⁻¹ = ∅ ↔ s = ∅

{α : Type u_2}
[DecidableEq α]
[Inv α]
{s : Finset α}

s⁻¹ = ∅ ↔ s = ∅


theorem initiallySmall_of_small_weakly_initial_set [IsCofilteredOrEmpty J] (s : Set J) [Small.{v} s]
    (hs : ∀ i, ∃ j ∈ s, Nonempty (j ⟶ i)) : InitiallySmall.{v} J

(hs : ∀ (i : J), ∃ j ∈ s, Nonempty (j ⟶ i))


/-- The equivalence `Karoubi (ChainComplex C α) ≌ ChainComplex (Karoubi C) α`. -/
@[simps!]
def karoubiChainComplexEquivalence : Karoubi (ChainComplex C α) ≌ ChainComplex (Karoubi C) α

(C : Type u_1)
[CategoryTheory.Category.{u_4, u_1} C]
[CategoryTheory.Preadditive C]
(α : Type u_3)
[AddRightCancelSemigroup α]
[One α]

∀ {X Y : HomologicalComplex (CategoryTheory.Idempotents.Karoubi C) (ComplexShape.down α)} (f : X ⟶ Y) (n : α),
  ((CategoryTheory.Idempotents.karoubiChainComplexEquivalence C α).inverse.map f).f.f n = (f.f n).f


/-- See also `Filter.Tendsto.atBot_mul_const_of_neg` for a version of this lemma for
`LinearOrderedField`s which does not require the `Archimedean` assumption. -/
theorem Tendsto.atBot_mul_const_of_neg' (hr : r < 0) (hf : Tendsto f l atBot) :
    Tendsto (fun x => f x * r) l atTop

{α : Type u_1}
{R : Type u_2}
{l : Filter α}
{f : α → R}
{r : R}
[LinearOrderedRing R]
[Archimedean R]
(hr : r < 0)
(hf : Filter.Tendsto f l Filter.atBot)

Filter.Tendsto (fun x => f x * r) l Filter.atTop


theorem mem_symmDiff : a ∈ s ∆ t ↔ a ∈ s ∧ a ∉ t ∨ a ∈ t ∧ a ∉ s

a ∈ symmDiff s t ↔ a ∈ s ∧ a ∉ t ∨ a ∈ t ∧ a ∉ s


@[mono]
theorem eLpNormEssSup_mono_measure (f : α → F) (hμν : ν ≪ μ) :
    eLpNormEssSup f ν ≤ eLpNormEssSup f μ

{α : Type u_1}
{F : Type u_3}
{m0 : MeasurableSpace α}
{μ ν : MeasureTheory.Measure α}
[NormedAddCommGroup F]
(f : α → F)
(hμν : ν ≪ μ)

MeasureTheory.eLpNormEssSup f ν ≤ MeasureTheory.eLpNormEssSup f μ


theorem det_toSquareBlock_id (M : Matrix m m R) (i : m) : (M.toSquareBlock id i).det = M i i

{m : Type u_3}
{R : Type v}
[CommRing R]
[DecidableEq m]
[Fintype m]
(M : Matrix m m R)
(i : m)


/-- Closure of a subgroup `K` equals `K`. -/
@[to_additive (attr := simp) "Additive closure of an additive subgroup `K` equals `K`"]
theorem closure_eq : closure (K : Set G) = K

{G : Type u_1}
[AddGroup G]
(K : AddSubgroup G)


@[simp]
theorem map_eq_id : algebraMap R R = RingHom.id _


@[simp]
theorem comp_ι_sq_scalar (g : CliffordAlgebra Q →ₐ[R] A) (m : M) :
    g (ι Q m) * g (ι Q m) = algebraMap _ _ (Q m)

{R : Type u_1}
[CommRing R]
{M : Type u_2}
[AddCommGroup M]
[Module R M]
{Q : QuadraticForm R M}
{A : Type u_3}
[Semiring A]
[Algebra R A]
(g : CliffordAlgebra Q →ₐ[R] A)
(m : M)

g ((CliffordAlgebra.ι Q) m) * g ((CliffordAlgebra.ι Q) m) = (algebraMap R A) (Q m)


theorem div_le_one_of_ge (h : b ≤ a) (hb : b ≤ 0) : a / b ≤ 1

{α : Type u_2}
[LinearOrderedField α]
{a b : α}
(h : b ≤ a)
(hb : b ≤ 0)


theorem div_cases (h : Irrational (x / y)) : Irrational x ∨ Irrational y


lemma pullback.hom_ext {Z : CompHaus.{u}} (a b : Z ⟶ pullback f g)
    (hfst : a ≫ pullback.fst f g = b ≫ pullback.fst f g)
    (hsnd : a ≫ pullback.snd f g = b ≫ pullback.snd f g) : a = b

(hfst :
  CategoryTheory.CategoryStruct.comp a (CompHaus.pullback.fst f g) =
    CategoryTheory.CategoryStruct.comp b (CompHaus.pullback.fst f g))

(hsnd :
  CategoryTheory.CategoryStruct.comp a (CompHaus.pullback.snd f g) =
    CategoryTheory.CategoryStruct.comp b (CompHaus.pullback.snd f g))


/-- `seminormFromConst_seq c f 0` is the constant sequence zero. -/
theorem seminormFromConst_seq_zero (hf : f 0 = 0) : seminormFromConst_seq c f 0 = 0

{R : Type u_1}
[CommRing R]
(c : R)
{f : RingSeminorm R}
(hf : f 0 = 0)


theorem measurableSpace_min_const (hτ : IsStoppingTime f τ) {i : ι} :
    (hτ.min_const i).measurableSpace = hτ.measurableSpace ⊓ f i

{Ω : Type u_1}
{ι : Type u_3}
{m : MeasurableSpace Ω}
[LinearOrder ι]
{f : MeasureTheory.Filtration ι m}
{τ : Ω → ι}
(hτ : MeasureTheory.IsStoppingTime f τ)
{i : ι}

⋯.measurableSpace = hτ.measurableSpace ⊓ ↑f i


/-- In a semigroup, the product of left-regular elements is left-regular. -/
@[to_additive "In an additive semigroup, the sum of add-left-regular elements is add-left.regular."]
theorem IsLeftRegular.mul (lra : IsLeftRegular a) (lrb : IsLeftRegular b) : IsLeftRegular (a * b)

{R : Type u_1}
[AddSemigroup R]
{a b : R}
(lra : IsAddLeftRegular a)
(lrb : IsAddLeftRegular b)


@[simp]
theorem preimage_mul_const_Iic_of_neg (a : α) {c : α} (h : c < 0) :
    (fun x => x * c) ⁻¹' Iic a = Ici (a / c)

{α : Type u_1}
[LinearOrderedField α]
(a : α)
{c : α}
(h : c < 0)

(fun x => x * c) ⁻¹' Set.Iic a = Set.Ici (a / c)


@[simp]
theorem sum_of_isEmpty [IsEmpty ι] (μ : ι → Measure α) : sum μ = 0

{α : Type u_1}
{ι : Type u_5}
{m0 : MeasurableSpace α}
[IsEmpty ι]
(μ : ι → MeasureTheory.Measure α)


theorem surjOn (h : LeftInvOn f' f s) (hf : MapsTo f s t) : SurjOn f' t s

{α : Type u_1}
{β : Type u_2}
{s : Set α}
{t : Set β}
{f : α → β}
{f' : β → α}
(h : Set.LeftInvOn f' f s)
(hf : Set.MapsTo f s t)


/-- The map `Square C → Square Cᵒᵖ` which switches `X₁` and `X₃`, but
does not move `X₂` and `X₃`. -/
@[simps]
protected def op (sq : Square C) : Square Cᵒᵖ

{C : Type u}
[CategoryTheory.Category.{v, u} C]
(sq : CategoryTheory.Square C)


@[simp]
theorem coe_comp (f : β →Co γ) (g : α →Co β) : (f.comp g : α → γ) = f ∘ g

{α : Type u_2}
{β : Type u_3}
{γ : Type u_4}
[TopologicalSpace α]
[Preorder α]
[TopologicalSpace β]
[Preorder β]
[TopologicalSpace γ]
[Preorder γ]
(f : β →Co γ)
(g : α →Co β)


(K : Type u_1)
[Field K]
[NumberField K]
{β : Type u_3}
(x : β × (K →+* ℂ) → ℤ)
(hxl : x ≠ 0)


theorem mem_smul_span_singleton {I : Ideal R} {m : M} {x : M} :
    x ∈ I • span R ({m} : Set M) ↔ ∃ y ∈ I, y • m = x

{R : Type u}
{M : Type v}
[CommSemiring R]
[AddCommMonoid M]
[Module R M]
{I : Ideal R}
{m x : M}

x ∈ I • Submodule.span R {m} ↔ ∃ y ∈ I, y • m = x


theorem valAux_zero : valAux K v O hv p 0 = 0

{K : Type u₁}
[Field K]
{v : Valuation K ℝ≥0}
{O : Type u₂}
[CommRing O]
[Algebra O K]
{hv : v.Integers O}
{p : ℕ}
[hp : Fact (Nat.Prime p)]
[hvp : Fact (v ↑p ≠ 1)]


@[to_additive]
theorem Step.append_left : ∀ {L₁ L₂ L₃ : List (α × Bool)}, Step L₂ L₃ → Step (L₁ ++ L₂) (L₁ ++ L₃)

{α : Type u}
{L₁ L₂ L₃ : List (α × Bool)}

FreeAddGroup.Red.Step L₂ L₃ → FreeAddGroup.Red.Step (L₁ ++ L₂) (L₁ ++ L₃)


@[to_additive]
theorem index_comap (f : G' →* G) :
    (H.comap f).index = H.relindex f.range

{G : Type u_1}
{G' : Type u_2}
[Group G]
[Group G']
(H : Subgroup G)
(f : G' →* G)

(Subgroup.comap f H).index = H.relindex f.range


protected theorem hasFPowerSeriesOnBall_bilinear (f : E →L[𝕜] F →L[𝕜] G) (x : E × F) :
    HasFPowerSeriesOnBall (fun x : E × F => f x.1 x.2) (f.fpowerSeriesBilinear x) 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]
(f : E →L[𝕜] F →L[𝕜] G)
(x : E × F)

HasFPowerSeriesOnBall (fun x => (f x.1) x.2) (f.fpowerSeriesBilinear x) x ⊤


theorem IsNormal.le_iff {f} (H : IsNormal f) {a b} : f a ≤ f b ↔ a ≤ b

{f : Ordinal.{u_4} → Ordinal.{u_5}}
(H : Ordinal.IsNormal f)
{a b : Ordinal.{u_4}}


@[simp]
theorem edist_le_ofReal {x y : α} {r : ℝ} (hr : 0 ≤ r) :
    edist x y ≤ ENNReal.ofReal r ↔ dist x y ≤ r

{α : Type u}
[PseudoMetricSpace α]
{x y : α}
{r : ℝ}
(hr : 0 ≤ r)


theorem integrable_indicatorConstLp {E} [NormedAddCommGroup E] {p : ℝ≥0∞} {s : Set α}
    (hs : MeasurableSet s) (hμs : μ s ≠ ∞) (c : E) :
    Integrable (indicatorConstLp p hs hμs c) μ

{α : Type u_1}
[MeasurableSpace α]
{μ : MeasureTheory.Measure α}
{E : Type u_5}
[NormedAddCommGroup E]
{p : ℝ≥0∞}
{s : Set α}
(hs : MeasurableSet s)
(hμs : μ s ≠ ⊤)
(c : E)

MeasureTheory.Integrable (↑↑(MeasureTheory.indicatorConstLp p hs hμs c)) μ


theorem eq_reverse_iff [h : HasInvolutiveReverse V] {a b : V} (f : a ⟶ b)
    (g : b ⟶ a) : f = reverse g ↔ reverse f = g

{V : Type u_2}
[Quiver V]
[h : Quiver.HasInvolutiveReverse V]
{a b : V}
(f : a ⟶ b)
(g : b ⟶ a)

f = Quiver.reverse g ↔ Quiver.reverse f = g


theorem withDensity_mul (μ : Measure α) {f g : α → ℝ≥0∞} (hf : Measurable f) (hg : Measurable g) :
    μ.withDensity (f * g) = (μ.withDensity f).withDensity g

{α : Type u_1}
{m0 : MeasurableSpace α}
(μ : MeasureTheory.Measure α)
{f g : α → ℝ≥0∞}
(hf : Measurable f)
(hg : Measurable g)


theorem infinite_iff_in_all_ranges {K : Finset V} (C : G.ComponentCompl K) :
    C.supp.Infinite ↔ ∀ (L) (h : K ⊆ L), ∃ D : G.ComponentCompl L, D.hom h = C

{V : Type u}
{G : SimpleGraph V}
{K : Finset V}
(C : G.ComponentCompl ↑K)

C.supp.Infinite ↔ ∀ (L : Finset V) (h : K ⊆ L), ∃ D, SimpleGraph.ComponentCompl.hom h D = C


@[simp]
theorem decompose_smul (r : R) (x : M) : decompose ℳ (r • x) = r • decompose ℳ x

{ι : Type u_1}
{R : Type u_2}
{M : Type u_3}
[DecidableEq ι]
[Semiring R]
[AddCommMonoid M]
[Module R M]
(ℳ : ι → Submodule R M)
[DirectSum.Decomposition ℳ]
(r : R)
(x : M)

(DirectSum.decompose ℳ) (r • x) = r • (DirectSum.decompose ℳ) x


@[simp]
theorem liftHom_mk {g : R[X]} : liftHom f a hfx (mk f g) = aeval a g

{R : Type u}
{S : Type v}
[CommRing R]
(f : R[X])
[CommRing S]
{a : S}
[Algebra R S]
(hfx : (Polynomial.aeval a) f = 0)
{g : R[X]}

(AdjoinRoot.liftHom f a hfx) ((AdjoinRoot.mk f) g) = (Polynomial.aeval a) g


theorem apply_symm_apply {x : B × F} (hx : x ∈ e.target) : e (e.toPartialEquiv.symm x) = x

{B : Type u_2}
{F : Type u_3}
{Z : Type u_5}
[TopologicalSpace B]
[TopologicalSpace F]
{proj : Z → B}
(e : Pretrivialization F proj)
{x : B × F}
(hx : x ∈ e.target)


theorem mem_normalizedFactors_iff [Unique αˣ] {p x : α} (hx : x ≠ 0) :
    p ∈ normalizedFactors x ↔ Prime p ∧ p ∣ x

{α : Type u_1}
[CancelCommMonoidWithZero α]
[NormalizationMonoid α]
[UniqueFactorizationMonoid α]
[Unique αˣ]
{p x : α}
(hx : x ≠ 0)

p ∈ UniqueFactorizationMonoid.normalizedFactors x ↔ Prime p ∧ p ∣ x


theorem nontrivial_of_invariantBasisNumber : Nontrivial R

(R : Type u)
[Semiring R]
[InvariantBasisNumber R]


@[simp]
lemma comp_as {a b c : LocallyDiscrete C} (f : a ⟶ b) (g : b ⟶ c) : (f ≫ g).as = f.as ≫ g.as

{a b c : CategoryTheory.LocallyDiscrete C}

(CategoryTheory.CategoryStruct.comp f g).as = CategoryTheory.CategoryStruct.comp f.as g.as


lemma fermatLastTheoremFor_zero : FermatLastTheoremFor 0


@[to_additive]
theorem one_mk_mul_one_mk [Monoid M] [Mul N] (b₁ b₂ : N) :
    ((1 : M), b₁) * (1, b₂) = (1, b₁ * b₂)

{M : Type u_5}
{N : Type u_6}
[Monoid M]
[Mul N]
(b₁ b₂ : N)


{C : Type u₁}
[CategoryTheory.Category.{v₁, u₁} C]
{X Y : C}
(f : Y ⟶ X)


lemma limsup_comp (u : β → α) (v : γ → β) (f : Filter γ) :
    limsup (u ∘ v) f = limsup u (map v f)

{α : Type u_1}
{β : Type u_2}
{γ : Type u_3}
[ConditionallyCompleteLattice α]
(u : β → α)
(v : γ → β)
(f : Filter γ)

Filter.limsup (u ∘ v) f = Filter.limsup u (Filter.map v f)


theorem isEquivalent_of_tendsto_one' (hz : ∀ x, v x = 0 → u x = 0) (huv : Tendsto (u / v) l (𝓝 1)) :
    u ~[l] v

(huv : Filter.Tendsto (u / v) l (nhds 1))


@[simp] theorem sum_cons : sum (x::xs : IntList) = x + sum xs

Lean.Omega.IntList.sum (x :: xs) = x + Lean.Omega.IntList.sum xs


protected theorem add_le_add_left {a b : Int} (h : a ≤ b) (c : Int) : c + a ≤ c + b


theorem Chain'.suffix (h : Chain' R l) (h' : l₁ <:+ l) : Chain' R l₁

{α : Type u}
{R : α → α → Prop}
{l l₁ : List α}
(h : List.Chain' R l)
(h' : l₁ <:+ l)


/-- Taking only the first `i+1` elements in a list, and then dropping the first `i` ones, one is
left with a list of length `1` made of the `i`-th element of the original list. -/
@[deprecated drop_take_succ_eq_cons_get (since := "2023-01-10")]
theorem drop_take_succ_eq_cons_nthLe (L : List α) {i : ℕ} (hi : i < L.length) :
    (L.take (i + 1)).drop i = [nthLe L i hi]

{α : Type u_1}
(L : List α)
{i : ℕ}
(hi : i < L.length)

List.drop i (List.take (i + 1) L) = [L.nthLe i hi]


/-- If a finset has cardinality larger than the rank of a module,
then there is a nontrivial linear relation amongst its elements. -/
theorem Module.exists_nontrivial_relation_of_finrank_lt_card {t : Finset M}
    (h : finrank R M < t.card) : ∃ f : M → R, ∑ e ∈ t, f e • e = 0 ∧ ∃ x ∈ t, f x ≠ 0

(h : FiniteDimensional.finrank R M < t.card)

∃ f, ∑ e ∈ t, f e • e = 0 ∧ ∃ x ∈ t, f x ≠ 0


theorem sigmaCongrRight_refl {α} {β : α → Type*} :
    (sigmaCongrRight fun a => Equiv.refl (β a)) = Equiv.refl (Σ a, β a)

(Equiv.sigmaCongrRight fun a => Equiv.refl (β a)) = Equiv.refl ((a : α) × β a)


theorem factors_eq_top_iff_zero {a : Associates α} : a.factors = ⊤ ↔ a = 0

{α : Type u_1}
[CancelCommMonoidWithZero α]
[UniqueFactorizationMonoid α]
{a : Associates α}


@[simp]
theorem diag_sub [Sub α] (A B : Matrix n n α) : diag (A - B) = diag A - diag B

{n : Type u_3}
{α : Type v}
[Sub α]
(A B : Matrix n n α)


@[simp] protected theorem min_self_assoc' {m n : Nat} : min n (min m n) = min n m


theorem ConvolutionExistsAt.integrable_swap (h : ConvolutionExistsAt f g x L μ) :
    Integrable (fun t => L (f (x - t)) (g t)) μ

(h : MeasureTheory.ConvolutionExistsAt f g x L μ)

MeasureTheory.Integrable (fun t => (L (f (x - t))) (g t)) μ


/--
If `B` is a strict bicategory and `I` is a (1-)category, any functor (of 1-categories) `I ⥤ B` can
be promoted to an oplax functor from `LocallyDiscrete I` to `B`.
-/
@[simps]
def Functor.toOplaxFunctor (F : I ⥤ B) : OplaxFunctor (LocallyDiscrete I) B

{I : Type u₁}
[CategoryTheory.Category.{v₁, u₁} I]
{B : Type u₂}
[CategoryTheory.Bicategory B]
[CategoryTheory.Bicategory.Strict B]
(F : CategoryTheory.Functor I B)
(i : CategoryTheory.LocallyDiscrete I)


@[simp]
theorem rightOp_id : NatTrans.rightOp (𝟙 F : F ⟶ F) = 𝟙 F.rightOp

{C : Type u₁}
[CategoryTheory.Category.{v₁, u₁} C]
{D : Type u₂}
[CategoryTheory.Category.{v₂, u₂} D]
{F : CategoryTheory.Functor Cᵒᵖ D}

CategoryTheory.NatTrans.rightOp (CategoryTheory.CategoryStruct.id F) = CategoryTheory.CategoryStruct.id F.rightOp


/-- *McCoy theorem*: a polynomial `P : R[X]` is a zerodivisor if and only if there is `a : R`
such that `a ≠ 0` and `a • P = 0`. -/
theorem nmem_nonZeroDivisors_iff {P : R[X]} : P ∉ R[X]⁰ ↔ ∃ a : R, a ≠ 0 ∧ a • P = 0

{R : Type u}
[CommSemiring R]
{P : R[X]}

P ∉ nonZeroDivisors R[X] ↔ ∃ a, a ≠ 0 ∧ a • P = 0


@[simp]
theorem id_apply (a : α) : HeytingHom.id α a = a

{α : Type u_2}
[HeytingAlgebra α]
(a : α)


protected theorem add_left_comm (a b c : Int) : a + (b + c) = b + (a + c)


theorem norm_comp_le_of_le' {g : NormedAddGroupHom V₂ V₃} (C₁ C₂ C₃ : ℝ) (h : C₃ = C₂ * C₁)
    (hg : ‖g‖ ≤ C₂) (hf : ‖f‖ ≤ C₁) : ‖g.comp f‖ ≤ C₃

{V₁ : Type u_2}
{V₂ : Type u_3}
{V₃ : Type u_4}
[SeminormedAddCommGroup V₁]
[SeminormedAddCommGroup V₂]
[SeminormedAddCommGroup V₃]
{f : NormedAddGroupHom V₁ V₂}
{g : NormedAddGroupHom V₂ V₃}
(C₁ C₂ C₃ : ℝ)
(h : C₃ = C₂ * C₁)
(hg : ‖g‖ ≤ C₂)
(hf : ‖f‖ ≤ C₁)


theorem differentiableAt' (h : DiffContOnCl 𝕜 f s) (hx : s ∈ 𝓝 x) : DifferentiableAt 𝕜 f x

{𝕜 : Type u_1}
{E : Type u_2}
{F : Type u_3}
[NontriviallyNormedField 𝕜]
[NormedAddCommGroup E]
[NormedAddCommGroup F]
[NormedSpace 𝕜 E]
[NormedSpace 𝕜 F]
{f : E → F}
{s : Set E}
{x : E}
(h : DiffContOnCl 𝕜 f s)
(hx : s ∈ 𝓝 x)


theorem minimals_Icc (hab : a ≤ b) : minimals (· ≤ ·) (Icc a b) = {a}

{α : Type u_1}
[PartialOrder α]
{a b : α}
(hab : a ≤ b)

minimals (fun x x_1 => x ≤ x_1) (Set.Icc a b) = {a}


lemma _root_.Set.Finite.absorbs_sInter (hS : S.Finite) :
    Absorbs G₀ (⋂₀ S) t ↔ ∀ s ∈ S, Absorbs G₀ s t

{G₀ : Type u_1}
{α : Type u_2}
[GroupWithZero G₀]
[Bornology G₀]
[MulAction G₀ α]
{t : Set α}
{S : Set (Set α)}
(hS : S.Finite)


theorem isNat_add {α} [AddMonoidWithOne α] : ∀ {f : α → α → α} {a b : α} {a' b' c : ℕ},
    f = HAdd.hAdd → IsNat a a' → IsNat b b' → Nat.add a' b' = c → IsNat (f a b) c

{α : Type u_1}
[AddMonoidWithOne α]
{f : α → α → α}
{a b : α}
{a' b' c : ℕ}

f = HAdd.hAdd →
  Mathlib.Meta.NormNum.IsNat a a' →
    Mathlib.Meta.NormNum.IsNat b b' → a'.add b' = c → Mathlib.Meta.NormNum.IsNat (f a b) c


/-- The identification `unmop X ⊗ - = unmop (mop - ⊗ X)` as a natural isomorphism. -/
@[simps!]
def MonoidalOpposite.tensorLeftUnmopIso (X : Cᴹᵒᵖ) :
    tensorLeft (unmop X) ≅ mopFunctor C ⋙ tensorRight X ⋙ unmopFunctor C

{C : Type u₁}
[CategoryTheory.Category.{v₁, u₁} C]
[CategoryTheory.MonoidalCategory C]
(X : Cᴹᵒᵖ)

∀ (X_1 : C), X.tensorLeftUnmopIso.inv.app X_1 = 𝟙 (CategoryTheory.MonoidalCategory.tensorObj X.unmop X_1)


theorem Antiperiodic.smul [Add α] [Monoid γ] [AddGroup β] [DistribMulAction γ β]
    (h : Antiperiodic f c) (a : γ) : Antiperiodic (a • f) c

{α : Type u_1}
{β : Type u_2}
{γ : Type u_3}
{f : α → β}
{c : α}
[Add α]
[Monoid γ]
[AddGroup β]
[DistribMulAction γ β]
(h : Function.Antiperiodic f c)
(a : γ)


/-- Coproduct of two `MonoidHom`s with the same codomain,
  with a commutation assumption:
  `f.noncommCoprod g _ (p : M × N) = f p.1 * g p.2`.
  (Noncommutative case; in the commutative case, use `MonoidHom.coprod`.)-/
@[to_additive (attr := simps)
    "Coproduct of two `AddMonoidHom`s with the same codomain,
    with a commutation assumption:
    `f.noncommCoprod g (p : M × N) = f p.1 + g p.2`.
    (Noncommutative case; in the commutative case, use `AddHom.coprod`.)"]
def noncommCoprod : M × N →* P

(comm : ∀ (m : M) (n : N), AddCommute (f m) (g n))

(f.noncommCoprod g comm) mn = f mn.1 + g mn.2


/-- The inverse of a quadratic character is itself. →  -/
theorem IsQuadratic.inv {χ : MulChar R R'} (hχ : χ.IsQuadratic) : χ⁻¹ = χ

{R : Type u_1}
[CommMonoid R]
{R' : Type u_2}
[CommRing R']
{χ : MulChar R R'}
(hχ : χ.IsQuadratic)


theorem add_congr_right {x y z : PGame} : (y ≈ z) → (x + y ≈ x + z)


/-- A morphism `f` is a monomorphism if it can be cancelled when postcomposed:
`g ≫ f = h ≫ f` implies `g = h`.

See <https://stacks.math.columbia.edu/tag/003B>.
-/
class Mono (f : X ⟶ Y) : Prop where
  /-- A morphism `f` is a monomorphism if it can be cancelled when postcomposed. -/
  right_cancellation : ∀ {Z : C} (g h : Z ⟶ X), g ≫ f = h ≫ f → g = h

{C : Type u}
[CategoryTheory.Category.{v, u} C]
{X Y : C}
{f : X ⟶ Y}
[self : CategoryTheory.Mono f]
{Z : C}
(g h : Z ⟶ X)

CategoryTheory.CategoryStruct.comp g f = CategoryTheory.CategoryStruct.comp h f → g = h


/-- The equivalence between `Bipointed` and itself induced by `Prod.swap` both ways. -/
@[simps!]
def swapEquiv : Bipointed ≌ Bipointed

∀ {X Y : Bipointed} (f : X ⟶ Y) (a : X.X), (Bipointed.swapEquiv.functor.map f).toFun a = f.toFun a


theorem infinitePos_mul_infiniteNeg {x y : ℝ*} :
    InfinitePos x → InfiniteNeg y → InfiniteNeg (x * y)

x.InfinitePos → y.InfiniteNeg → (x * y).InfiniteNeg


protected theorem max_eq_right {a b : Int} (h : a ≤ b) : max a b = b


/-- The diameter of a closed ball of radius `r` is at most `2 r`. -/
theorem diam_closedBall {r : ℝ} (h : 0 ≤ r) : diam (closedBall x r) ≤ 2 * r

{α : Type u}
[PseudoMetricSpace α]
{x : α}
{r : ℝ}
(h : 0 ≤ r)

Metric.diam (Metric.closedBall x r) ≤ 2 * r


@[simp]
lemma image_coe_Iio (x : ℝ) : Real.toEReal '' Iio x = Ioo ⊥ ↑x

Real.toEReal '' Set.Iio x = Set.Ioo ⊥ ↑x


@[simp] theorem Subsequent.moveRight_mk_right {xL : xl → PGame} {i : xr} (xR : xr → PGame) (j) :
    Subsequent ((xR i).moveRight j) (mk xl xr xL xR)

{xl xr : Type u}
{xL : xl → SetTheory.PGame}
{i : xr}
(xR : xr → SetTheory.PGame)
(j : (xR i).RightMoves)

((xR i).moveRight j).Subsequent (SetTheory.PGame.mk xl xr xL xR)


lemma IsLocalizedModule.surj [IsLocalizedModule S f] (y : M') : ∃ x : M × S, x.2 • y = f x.1

{R : Type u_1}
[CommSemiring R]
(S : Submonoid R)
{M : Type u_2}
{M' : Type u_3}
[AddCommMonoid M]
[AddCommMonoid M']
[Module R M]
[Module R M']
(f : M →ₗ[R] M')
[IsLocalizedModule S f]
(y : M')


theorem of_primrec {f : ℕ → ℕ} (hf : Nat.Primrec f) : Partrec f


theorem invOf_add_invOf [Semiring α] (a b : α) [Invertible a] [Invertible b] :
    ⅟a + ⅟b = ⅟a * (a + b) * ⅟b

{α : Type u}
[Semiring α]
(a b : α)
[Invertible a]
[Invertible b]


@[to_additive (attr := simp)]
theorem preimage_mul_right_closedBall [IsometricSMul Gᵐᵒᵖ G] (a b : G) (r : ℝ≥0∞) :
    (fun x => x * a) ⁻¹' closedBall b r = closedBall (b / a) r

{G : Type v}
[AddGroup G]
[PseudoEMetricSpace G]
[IsometricVAdd Gᵃᵒᵖ G]
(a b : G)
(r : ℝ≥0∞)

(fun x => x + a) ⁻¹' EMetric.closedBall b r = EMetric.closedBall (b - a) r


@[to_additive (attr := simp)]
theorem subtype_comp_inclusion {H K : S} (hH : H ≤ K) :
    (SubgroupClass.subtype K).comp (inclusion hH) = SubgroupClass.subtype H

{G : Type u_1}
[Group G]
{S : Type u_6}
[SetLike S G]
[SubgroupClass S G]
{H K : S}
(hH : H ≤ K)

(↑K).comp (SubgroupClass.inclusion hH) = ↑H


theorem sorted_last_eq_max' {s : Finset α}
    {h : (s.sort (· ≤ ·)).length - 1 < (s.sort (· ≤ ·)).length} :
    (s.sort (· ≤ ·)).get ⟨(s.sort (· ≤ ·)).length - 1, h⟩ =
      s.max' (by rw [length_sort] at h; exact card_pos.1 (lt_of_le_of_lt bot_le h))

{h : (Finset.sort (fun x x_1 => x ≤ x_1) s).length - 1 < (Finset.sort (fun x x_1 => x ≤ x_1) s).length}

(Finset.sort (fun x x_1 => x ≤ x_1) s).get ⟨(Finset.sort (fun x x_1 => x ≤ x_1) s).length - 1, h⟩ = s.max' ⋯


theorem gcd_assoc (m n k : Nat) : gcd (gcd m n) k = gcd m (gcd n k)


theorem nodup_sup_iff {α : Type*} [DecidableEq α] {m : Multiset (Multiset α)} :
    m.sup.Nodup ↔ ∀ a : Multiset α, a ∈ m → a.Nodup

{α : Type u_2}
[DecidableEq α]
{m : Multiset (Multiset α)}


/-- A partial homeomorphism is an open map on its source:
  the image of an open subset of the source is open. -/
lemma isOpen_image_of_subset_source {s : Set X} (hs : IsOpen s) (hse : s ⊆ e.source) :
    IsOpen (e '' s)

{X : Type u_1}
{Y : Type u_3}
[TopologicalSpace X]
[TopologicalSpace Y]
(e : PartialHomeomorph X Y)
{s : Set X}
(hs : IsOpen s)
(hse : s ⊆ e.source)


@[simp]
theorem boxProd_connected : (G □ H).Connected ↔ G.Connected ∧ H.Connected

{α : Type u_1}
{β : Type u_2}
{G : SimpleGraph α}
{H : SimpleGraph β}


@[to_additive]
theorem inv_mul_eq_of_eq_mul (h : b = a * c) : a⁻¹ * b = c

{G : Type u_3}
[AddGroup G]
{a b c : G}
(h : b = a + c)


@[continuity, fun_prop]
theorem continuous_quot_mk : Continuous (@Quot.mk X r)

{X : Type u}
[TopologicalSpace X]
{r : X → X → Prop}


@[fun_prop]
theorem hasStrictFDerivAt_fst : HasStrictFDerivAt (@Prod.fst E F) (fst 𝕜 E F) p

{𝕜 : Type u_1}
[NontriviallyNormedField 𝕜]
{E : Type u_2}
[NormedAddCommGroup E]
[NormedSpace 𝕜 E]
{F : Type u_3}
[NormedAddCommGroup F]
[NormedSpace 𝕜 F]
{p : E × F}

HasStrictFDerivAt Prod.fst (ContinuousLinearMap.fst 𝕜 E F) p


theorem not_surjective_finite_infinite {α β} [Finite α] [Infinite β] (f : α → β) : ¬Surjective f

{α : Sort u_4}
{β : Sort u_5}
[Finite α]
[Infinite β]
(f : α → β)


/-- The natural isomorphism `mapTrifunctor F I₁ I₂ I₃ ≅ mapTrifunctor F' I₁ I₂ I₃`
induced by a natural isomorphism `F ≅ F` of trifunctors. -/
@[simps]
def mapTrifunctorMapIso (e : F ≅ F') (I₁ I₂ I₃ : Type*) :
    mapTrifunctor F I₁ I₂ I₃ ≅ mapTrifunctor F' I₁ I₂ I₃

{F F' : CategoryTheory.Functor C₁ (CategoryTheory.Functor C₂ (CategoryTheory.Functor C₃ C₄))}

(CategoryTheory.GradedObject.mapTrifunctorMapIso e I₁ I₂ I₃).inv =
  CategoryTheory.GradedObject.mapTrifunctorMapNatTrans e.inv I₁ I₂ I₃


/-- When `V` is monoidal the forgetful functor `Action V G` to `V` is monoidal. -/
@[simps]
def forgetMonoidal : MonoidalFunctor (Action V G) V

(V : Type (u + 1))
[CategoryTheory.LargeCategory V]
(G : MonCat)
[CategoryTheory.MonoidalCategory V]
(X Y : Action V G)

(Action.forgetMonoidal V G).μ X Y =
  𝟙 (CategoryTheory.MonoidalCategory.tensorObj ((Action.forget V G).obj X) ((Action.forget V G).obj Y))


protected theorem mul_assoc (x y z : BitVec w) : x * y * z = x * (y * z)


theorem subsingleton_iff_forall_eq (x : α) : Subsingleton α ↔ ∀ y, y = x


@[simp, norm_cast] lemma ofENat_ofNat (n : ℕ) [n.AtLeastTwo] :
    ((no_index (OfNat.ofNat n : ℕ∞)) : Cardinal) = OfNat.ofNat n


/-- **Fundamental theorem of calculus-1**: if `f : ℝ → E` is integrable on `a..b` and `f x` has a
finite limit `c` almost surely at `a`, then `u ↦ ∫ x in u..b, f x` has derivative `-c` at `a`. -/
theorem integral_hasDerivAt_of_tendsto_ae_left (hf : IntervalIntegrable f volume a b)
    (hmeas : StronglyMeasurableAtFilter f (𝓝 a)) (ha : Tendsto f (𝓝 a ⊓ ae volume) (𝓝 c)) :
    HasDerivAt (fun u => ∫ x in u..b, f x) (-c) a

(hf : IntervalIntegrable f MeasureTheory.volume a b)

(hmeas : StronglyMeasurableAtFilter f (𝓝 a) MeasureTheory.volume)

(ha : Filter.Tendsto f (𝓝 a ⊓ MeasureTheory.ae MeasureTheory.volume) (𝓝 c))

HasDerivAt (fun u => ∫ (x : ℝ) in u..b, f x) (-c) a


theorem lowerSemicontinuousOn_ciSup {f : ι → α → δ'}
    (bdd : ∀ x ∈ s, BddAbove (range fun i => f i x)) (h : ∀ i, LowerSemicontinuousOn (f i) s) :
    LowerSemicontinuousOn (fun x' => ⨆ i, f i x') s

{f : ι → α → δ'}

(bdd : ∀ x ∈ s, BddAbove (Set.range fun i => f i x))

(h : ∀ (i : ι), LowerSemicontinuousOn (f i) s)


@[simp]
theorem coe_val : (val s : s → A) = ((↑) : s → A)

{S : Type u_1}
{R : Type u_2}
{A : Type u_3}
[CommSemiring R]
[Semiring A]
[Algebra R A]
[SetLike S A]
[SubsemiringClass S A]
[hSR : SMulMemClass S R A]
(s : S)


@[simp]
theorem singleton_nonempty (a : α) : ({a} : Set α).Nonempty


@[to_additive (attr := simp)]
theorem elim_one_mulSingle [DecidableEq α] [DecidableEq β] [One γ] (i : β) (c : γ) :
    Sum.elim (1 : α → γ) (Pi.mulSingle i c) = Pi.mulSingle (Sum.inr i) c

{α : Type u_1}
{β : Type u_2}
{γ : Type u_3}
[DecidableEq α]
[DecidableEq β]
[One γ]
(i : β)
(c : γ)

Sum.elim 1 (Pi.mulSingle i c) = Pi.mulSingle (Sum.inr i) c


@[simp, fun_prop]
protected theorem Differentiable.snd (h : Differentiable 𝕜 f₂) :
    Differentiable 𝕜 fun x => (f₂ x).2

{𝕜 : 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]
{f₂ : E → F × G}
(h : Differentiable 𝕜 f₂)


/-- The sequence of real eigenvalues associated to the standard orthonormal basis of eigenvectors
for a self-adjoint operator `T` on `E`.

TODO Postcompose with a permutation so that these eigenvalues are listed in increasing order. -/
noncomputable irreducible_def eigenvalues (i : Fin n) : ℝ

(hn : FiniteDimensional.finrank 𝕜 E = n)

hT.eigenvalues hn i = RCLike.re (↑T (DirectSum.IsInternal.subordinateOrthonormalBasisIndex hn ⋯ i ⋯))


@[simp]
theorem ucs_eq_self_of_isCartanSubalgebra (H : LieSubalgebra R L) [H.IsCartanSubalgebra] (k : ℕ) :
    H.toLieSubmodule.ucs k = H.toLieSubmodule

{R : Type u}
{L : Type v}
[CommRing R]
[LieRing L]
[LieAlgebra R L]
(H : LieSubalgebra R L)
[H.IsCartanSubalgebra]
(k : ℕ)

LieSubmodule.ucs k H.toLieSubmodule = H.toLieSubmodule


theorem tendsto_norm_zero' {𝕜 : Type*} [NormedAddCommGroup 𝕜] :
    Tendsto (norm : 𝕜 → ℝ) (𝓝[≠] 0) (𝓝[>] 0)


/-- If `C` has finite coproducts and filtered colimits, we can construct arbitrary coproducts by
    taking the colimit of the diagram formed by the coproducts of finite sets over the indexing
    type. -/
@[simps!]
def liftToFinsetColimitCocone [HasFiniteCoproducts C] [HasFilteredColimitsOfSize.{w, w} C]
    (F : Discrete α ⥤ C) : ColimitCocone F

[CategoryTheory.Limits.HasFilteredColimitsOfSize.{w, w, v, u} C]

(CategoryTheory.Limits.CoproductsFromFiniteFiltered.liftToFinsetColimitCocone F).cocone.ι.app j =
  CategoryTheory.Limits.Sigma.ι (fun x => F.obj ↑x) ⟨j, ⋯⟩ ≫
    CategoryTheory.Limits.colimit.ι (CategoryTheory.Limits.CoproductsFromFiniteFiltered.liftToFinset F) {j}


theorem extract_loop_of_ge (as bs : Array α) (size start : Nat) (h : start ≥ as.size) :
    extract.loop as size start bs = bs

{α : Type u_1}
(as bs : Array α)
(size start : Nat)
(h : start ≥ as.size)

Array.extract.loop as size start bs = bs


theorem addHaar_sphere_of_ne_zero (x : E) {r : ℝ} (hr : r ≠ 0) : μ (sphere x r) = 0

{E : Type u_1}
[NormedAddCommGroup E]
[NormedSpace ℝ E]
[MeasurableSpace E]
[BorelSpace E]
[FiniteDimensional ℝ E]
(μ : MeasureTheory.Measure E)
[μ.IsAddHaarMeasure]
(x : E)
{r : ℝ}
(hr : r ≠ 0)


protected theorem Set.Subsingleton.convex {s : Set E} (h : s.Subsingleton) : Convex 𝕜 s

{𝕜 : Type u_1}
{E : Type u_2}
[OrderedSemiring 𝕜]
[AddCommMonoid E]
[Module 𝕜 E]
{s : Set E}
(h : s.Subsingleton)


theorem measurableSet_pi {s : Set δ} {t : ∀ i, Set (π i)} (hs : s.Countable) :
    MeasurableSet (pi s t) ↔ (∀ i ∈ s, MeasurableSet (t i)) ∨ pi s t = ∅

{δ : Type u_4}
{π : δ → Type u_6}
[(a : δ) → MeasurableSpace (π a)]
{s : Set δ}
{t : (i : δ) → Set (π i)}
(hs : s.Countable)

MeasurableSet (s.pi t) ↔ (∀ i ∈ s, MeasurableSet (t i)) ∨ s.pi t = ∅


theorem hasStrictDerivAt_arctan (x : ℝ) : HasStrictDerivAt arctan (1 / (1 + x ^ 2)) x

HasStrictDerivAt Real.arctan (1 / (1 + x ^ 2)) x


theorem l_csSup' (gc : GaloisConnection l u) {s : Set α} (hne : s.Nonempty) (hbdd : BddAbove s) :
    l (sSup s) = sSup (l '' s)

{α : Type u_1}
{β : Type u_2}
[ConditionallyCompleteLattice α]
[ConditionallyCompleteLattice β]
{l : α → β}
{u : β → α}
(gc : GaloisConnection l u)
{s : Set α}
(hne : s.Nonempty)
(hbdd : BddAbove s)


@[simp]
theorem cast_inv_nat (n : ℕ) : ((n⁻¹ : ℚ) : α) = (n : α)⁻¹

↑(↑n)⁻¹ = (↑n)⁻¹


@[simp, norm_cast]
theorem val_smul [SMul R A] [StarModule R A] (r : R) (x : selfAdjoint A) : ↑(r • x) = r • (x : A)

{R : Type u_1}
{A : Type u_2}
[Star R]
[TrivialStar R]
[AddGroup A]
[StarAddMonoid A]
[SMul R A]
[StarModule R A]
(r : R)
(x : ↥(selfAdjoint A))


theorem subset_ite {t s s' u : Set α} : u ⊆ t.ite s s' ↔ u ∩ t ⊆ s ∧ u \ t ⊆ s'


theorem measurableSet_Ioi {c : ℝ} : MeasurableSet[f.outer.caratheodory] (Ioi c)


/-- To construct an isomorphism of costructured arrows,
we need an isomorphism of the objects underlying the source,
and to check that the triangle commutes.
-/
@[simps!]
def isoMk {f f' : CostructuredArrow S T} (g : f.left ≅ f'.left)
    (w : S.map g.hom ≫ f'.hom = f.hom := by aesop_cat) : f ≅ f'

{f f' : CategoryTheory.CostructuredArrow S T}

(w : CategoryTheory.CategoryStruct.comp (S.map g.hom) f'.hom = f.hom := by aesop_cat)

(CategoryTheory.CostructuredArrow.isoMk g w).hom.left = g.hom


/-- Sends a topological space to its specialisation order. -/
@[simps]
def alexDiscEquivPreord : AlexDisc ≌ Preord

alexDiscEquivPreord.inverse.obj X = AlexDisc.of (Topology.WithUpperSet ↑X)


theorem cpow_neg_one (x : ℂ) : x ^ (-1 : ℂ) = x⁻¹


theorem generate_discretePresieve_mem (α : Type u) :
    Sieve.generate (discretePresieve α) ∈ typesGrothendieckTopology α

CategoryTheory.Sieve.generate (CategoryTheory.discretePresieve α) ∈ CategoryTheory.typesGrothendieckTopology.sieves α


theorem isConj_iff_conjugatesOf_eq {a b : α} : IsConj a b ↔ conjugatesOf a = conjugatesOf b


theorem prod_le [Nontrivial α] {a b : FactorSet α} : a.prod ≤ b.prod ↔ a ≤ b

{α : Type u_1}
[CancelCommMonoidWithZero α]
[UniqueFactorizationMonoid α]
[Nontrivial α]
{a b : Associates.FactorSet α}


theorem recDiag_zero_succ {motive : Nat → Nat → Sort _} (zero_zero : motive 0 0)
    (zero_succ : ∀ n, motive 0 n → motive 0 (n+1)) (succ_zero : ∀ m, motive m 0 → motive (m+1) 0)
    (succ_succ : ∀ m n, motive m n → motive (m+1) (n+1)) (n) :
    Nat.recDiag zero_zero zero_succ succ_zero succ_succ 0 (n+1)
      = zero_succ n (Nat.recDiag zero_zero zero_succ succ_zero succ_succ 0 n)

(zero_succ : (n : Nat) → motive 0 n → motive 0 (n + 1))

(succ_zero : (m : Nat) → motive m 0 → motive (m + 1) 0)

(succ_succ : (m n : Nat) → motive m n → motive (m + 1) (n + 1))

Nat.recDiag zero_zero zero_succ succ_zero succ_succ 0 (n + 1) =
  zero_succ n (Nat.recDiag zero_zero zero_succ succ_zero succ_succ 0 n)


@[simp]
theorem trunc_one (n : σ →₀ ℕ) (hnn : n ≠ 0) : trunc R n 1 = 1

{σ : Type u_1}
{R : Type u_2}
[CommSemiring R]
(n : σ →₀ ℕ)
(hnn : n ≠ 0)


lemma tendsto_nat_ceil_atTop {α : Type*} [LinearOrderedSemiring α] [FloorSemiring α] :
    Tendsto (fun x : α ↦ ⌈x⌉₊) atTop atTop

{α : Type u_4}
[LinearOrderedSemiring α]
[FloorSemiring α]

Filter.Tendsto (fun x => ⌈x⌉₊) Filter.atTop Filter.atTop


theorem not_nontrivial (α) [Subsingleton α] : ¬Nontrivial α


lemma map_apply : Relation.Map r f g c d ↔ ∃ a b, r a b ∧ f a = c ∧ g b = d

{α : Type u_1}
{β : Type u_2}
{γ : Type u_3}
{δ : Type u_4}
{r : α → β → Prop}
{f : α → γ}
{g : β → δ}
{c : γ}
{d : δ}


/-- Given a total orthonormal family `v : ι → E`, `E` is a Hilbert sum of `fun i : ι => 𝕜`
relative to the family of linear isometries `fun i k => k • v i`. -/
theorem Orthonormal.isHilbertSum {v : ι → E} (hv : Orthonormal 𝕜 v)
    (hsp : ⊤ ≤ (span 𝕜 (Set.range v)).topologicalClosure) :
    IsHilbertSum 𝕜 (fun _ : ι => 𝕜) fun i => LinearIsometry.toSpanSingleton 𝕜 E (hv.1 i)

(hsp : ⊤ ≤ (Submodule.span 𝕜 (Set.range v)).topologicalClosure)

IsHilbertSum 𝕜 (fun x => 𝕜) fun i => LinearIsometry.toSpanSingleton 𝕜 E ⋯


theorem ker_le_iff [RingHomSurjective τ₁₂] {p : Submodule R M} :
    ker f ≤ p ↔ ∃ y ∈ range f, f ⁻¹' {y} ⊆ p

{R : Type u_1}
{R₂ : Type u_2}
{M : Type u_6}
{M₂ : Type u_7}
[Ring R]
[Ring R₂]
[AddCommGroup M]
[AddCommGroup M₂]
[Module R M]
[Module R₂ M₂]
{τ₁₂ : R →+* R₂}
{F : Type u_11}
[FunLike F M M₂]
[SemilinearMapClass F τ₁₂ M M₂]
{f : F}
[RingHomSurjective τ₁₂]
{p : Submodule R M}

LinearMap.ker f ≤ p ↔ ∃ y ∈ LinearMap.range f, ⇑f ⁻¹' {y} ⊆ ↑p


@[to_additive]
theorem smul_inter_ne_empty_iff {s t : Set α} {x : α} :
    x • s ∩ t ≠ ∅ ↔ ∃ a b, (a ∈ t ∧ b ∈ s) ∧ a * b⁻¹ = x

{α : Type u_2}
[AddGroup α]
{s t : Set α}
{x : α}

(x +ᵥ s) ∩ t ≠ ∅ ↔ ∃ a b, (a ∈ t ∧ b ∈ s) ∧ a + -b = x


@[to_additive]
theorem prod_coe_sort : ∏ i : s, f i = ∏ i ∈ s, f i

{α : Type u_3}
{β : Type u_4}
(s : Finset α)
(f : α → β)
[CommMonoid β]

∏ i : { x // x ∈ s }, f ↑i = ∏ i ∈ s, f i


theorem toIocDiv_sub_eq_toIocDiv_add' (a b c : α) :
    toIocDiv hp (a - c) b = toIocDiv hp a (b + c)

{α : Type u_1}
[LinearOrderedAddCommGroup α]
[hα : Archimedean α]
{p : α}
(hp : 0 < p)
(a b c : α)


/-- In a Banach-algebra `𝔸` over `𝕂 = ℝ` or `𝕂 = ℂ`, if a family of elements `f i` mutually
commute then `exp 𝕂 (∑ i, f i) = ∏ i, exp 𝕂 (f i)`. -/
theorem exp_sum_of_commute {ι} (s : Finset ι) (f : ι → 𝔸)
    (h : (s : Set ι).Pairwise fun i j => Commute (f i) (f j)) :
    exp 𝕂 (∑ i ∈ s, f i) =
      s.noncommProd (fun i => exp 𝕂 (f i)) fun i hi j hj _ => (h.of_refl hi hj).exp 𝕂

(h : (↑s).Pairwise fun i j => Commute (f i) (f j))

NormedSpace.exp 𝕂 (∑ i ∈ s, f i) = s.noncommProd (fun i => NormedSpace.exp 𝕂 (f i)) ⋯


@[simp]
theorem lookupFinsupp_apply [DecidableEq α] (l : AList fun _x : α => M) (a : α) :
    l.lookupFinsupp a = (l.lookup a).getD 0

{α : Type u_1}
{M : Type u_2}
[Zero M]
[DecidableEq α]
(l : AList fun _x => M)
(a : α)

l.lookupFinsupp a = (AList.lookup a l).getD 0


theorem injective_codRestrict (f : F) (S : NonUnitalStarSubalgebra R B) (hf : ∀ x : A, f x ∈ S) :
    Function.Injective (NonUnitalStarAlgHom.codRestrict f S hf) ↔ Function.Injective f

{F : Type v'}
{R : Type u}
{A : Type v}
{B : Type w}
[CommSemiring R]
[NonUnitalNonAssocSemiring A]
[Module R A]
[Star A]
[NonUnitalNonAssocSemiring B]
[Module R B]
[Star B]
[FunLike F A B]
[NonUnitalAlgHomClass F R A B]
[NonUnitalStarAlgHomClass F R A B]
(f : F)
(S : NonUnitalStarSubalgebra R B)
(hf : ∀ (x : A), f x ∈ S)

Function.Injective ⇑(NonUnitalStarAlgHom.codRestrict f S hf) ↔ Function.Injective ⇑f


/-- If `M ≤ N` are submonoids of `R`, then `N⁻¹S` is also the localization of `M⁻¹S` at `N`. -/
theorem isLocalization_of_submonoid_le (M N : Submonoid R) (h : M ≤ N) [IsLocalization M S]
    [IsLocalization N T] [Algebra S T] [IsScalarTower R S T] :
    IsLocalization (N.map (algebraMap R S)) T

{R : Type u_1}
[CommSemiring R]
(S : Type u_2)
[CommSemiring S]
[Algebra R S]
(T : Type u_4)
[CommSemiring T]
[Algebra R T]
(M N : Submonoid R)
(h : M ≤ N)
[IsLocalization M S]
[IsLocalization N T]
[Algebra S T]
[IsScalarTower R S T]

IsLocalization (Submonoid.map (algebraMap R S) N) T


/-- The (degenerate) subsimplex of `Λ[n+2, i]` concentrated in vertex `k`. -/
@[simps]
def const (n : ℕ) (i k : Fin (n+3)) (m : SimplexCategoryᵒᵖ) : Λ[n+2, i].obj m

(n : ℕ)
(i k : Fin (n + 3))
(m : SimplexCategoryᵒᵖ)

↑(SSet.horn.const n i k m) = SSet.standardSimplex.const (n + 2) k m


@[simp] theorem Bool.false_or (b : Bool) : (false || b) = b


/-- A *cycle* at `u : V` is a circuit at `u` whose only repeating vertex
is `u` (which appears exactly twice). -/
structure IsCycle {u : V} (p : G.Walk u u) extends IsCircuit p : Prop where
  support_nodup : p.support.tail.Nodup

{V : Type u}
{G : SimpleGraph V}
{u : V}
{p : G.Walk u u}
(self : p.IsCycle)


@[ext]
theorem MeasurableSpace.ext {m₁ m₂ : MeasurableSpace α}
    (h : ∀ s : Set α, MeasurableSet[m₁] s ↔ MeasurableSet[m₂] s) : m₁ = m₂

(h : ∀ (s : Set α), MeasurableSet s ↔ MeasurableSet s)


/-- If `f` and `g` are Lipschitz on `s`, so is the induced map `f × g` to the product type. -/
protected theorem prod {g : α → γ} {Kf Kg : ℝ≥0} (hf : LipschitzOnWith Kf f s)
    (hg : LipschitzOnWith Kg g s) : LipschitzOnWith (max Kf Kg) (fun x => (f x, g x)) s

{α : Type u}
{β : Type v}
{γ : Type w}
[PseudoEMetricSpace α]
[PseudoEMetricSpace β]
[PseudoEMetricSpace γ]
{s : Set α}
{f : α → β}
{g : α → γ}
{Kf Kg : ℝ≥0}
(hf : LipschitzOnWith Kf f s)
(hg : LipschitzOnWith Kg g s)


@[simp]
theorem le_prevFixed_iff {x : α} (hx : f x ≤ x) {y : fixedPoints f} :
    y ≤ f.prevFixed x hx ↔ ↑y ≤ x

{α : Type u}
[CompleteLattice α]
(f : α →o α)
{x : α}
(hx : f x ≤ x)
{y : ↑(Function.fixedPoints ⇑f)}


@[to_additive exists_FS_of_large]
theorem exists_FP_of_large {M} [Semigroup M] (U : Ultrafilter M) (U_idem : U * U = U) (s₀ : Set M)
    (sU : s₀ ∈ U) : ∃ a, FP a ⊆ s₀

{M : Type u_1}
[Semigroup M]
(U : Ultrafilter M)
(U_idem : U * U = U)
(s₀ : Set M)
(sU : s₀ ∈ U)


/-- The `p`-primary component is the submonoid of elements with order prime-power of `p`. -/
@[to_additive (attr := simps)
      "The `p`-primary component is the submonoid of elements with additive
      order prime-power of `p`."]
def primaryComponent : Submonoid G

(G : Type u_1)
[AddCommMonoid G]
(p : ℕ)
[hp : Fact (Nat.Prime p)]

↑(AddCommMonoid.primaryComponent G p) = {g | ∃ n, addOrderOf g = p ^ n}


/-- If `μ` is inner regular for finite measure sets with respect to compact sets,
then any measurable set of finite measure can be approximated by a
compact subset. See also `MeasurableSet.exists_isCompact_lt_add`. -/
theorem _root_.MeasurableSet.exists_lt_isCompact_of_ne_top [InnerRegularCompactLTTop μ] ⦃A : Set α⦄
    (hA : MeasurableSet A) (h'A : μ A ≠ ∞) {r : ℝ≥0∞} (hr : r < μ A) :
    ∃ K, K ⊆ A ∧ IsCompact K ∧ r < μ K

{α : Type u_1}
[MeasurableSpace α]
[TopologicalSpace α]
{μ : MeasureTheory.Measure α}
[μ.InnerRegularCompactLTTop]
⦃A : Set α⦄
(hA : MeasurableSet A)
(h'A : μ A ≠ ⊤)
{r : ℝ≥0∞}
(hr : r < μ A)


lemma RightHomologyData.mapRightHomologyIso_eq [S.HasRightHomology]
    [F.PreservesRightHomologyOf S] :
    S.mapRightHomologyIso F = (hr.map F).rightHomologyIso ≪≫
      F.mapIso hr.rightHomologyIso.symm


theorem Sublist.count_le (h : l₁ <+ l₂) (a : α) : count a l₁ ≤ count a l₂

{α : Type u_1}
[DecidableEq α]
{l₁ l₂ : List α}
(h : l₁ <+ l₂)
(a : α)


theorem IsRelPrime.prod_left_iff : IsRelPrime (∏ i ∈ t, s i) x ↔ ∀ i ∈ t, IsRelPrime (s i) x

{α : Type u_1}
{I : Type u_2}
[CommMonoid α]
[DecompositionMonoid α]
{x : α}
{s : I → α}
{t : Finset I}


private lemma selfProdProj_fiber (x : F.obj X) :
    F.map (selfProdProj u x) a = x

{F : CategoryTheory.Functor C FintypeCat}

{u : A ⟶ CategoryTheory.PreGaloisCategory.selfProd F X}

(h : F.map u a = CategoryTheory.PreGaloisCategory.mkSelfProdFib F X)

F.map (CategoryTheory.PreGaloisCategory.selfProdProj u x) a = x


@[to_additive] lemma val_inv_unit' (h : IsUnit a) : ↑(h.unit'⁻¹) = a⁻¹

{α : Type u}
[SubtractionMonoid α]
{a : α}
(h : IsAddUnit a)


theorem pow_subset_pow {n : ℕ} : (↑M : Set A) ^ n ⊆ ↑(M ^ n : Submodule R A)

{R : Type u}
[CommSemiring R]
{A : Type v}
[Semiring A]
[Algebra R A]
(M : Submodule R A)
{n : ℕ}


@[simp]
theorem aeval_X_left : aeval (X : R[X]) = AlgHom.id R R[X]

Polynomial.aeval Polynomial.X = AlgHom.id R R[X]


/-- For the identity map, all points are periodic. -/
theorem is_periodic_id (n : ℕ) (x : α) : IsPeriodicPt id n x


@[simp]
theorem mapRange_zero {f : M →+ N} (hf : Continuous f) :
    mapRange (0 : VectorMeasure α M) f hf = 0

{α : Type u_1}
[MeasurableSpace α]
{M : Type u_3}
[AddCommMonoid M]
[TopologicalSpace M]
{N : Type u_4}
[AddCommMonoid N]
[TopologicalSpace N]
{f : M →+ N}
(hf : Continuous ⇑f)

MeasureTheory.VectorMeasure.mapRange 0 f hf = 0


theorem bddBelow_projectiveSemiNormAux (x : ⨂[𝕜] i, E i) :
    BddBelow (Set.range (fun (p : lifts x) ↦ projectiveSeminormAux p.1))

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

BddBelow (Set.range fun p => PiTensorProduct.projectiveSeminormAux ↑p)


theorem borel_eq_top_of_discrete [TopologicalSpace α] [DiscreteTopology α] : borel α = ⊤

{α : Type u_1}
[TopologicalSpace α]
[DiscreteTopology α]


@[reassoc (attr := simp)]
lemma cyclesMap'_i : cyclesMap' φ h₁ h₂ ≫ h₂.i = h₁.i ≫ φ.τ₂

CategoryTheory.CategoryStruct.comp (CategoryTheory.ShortComplex.cyclesMap' φ h₁ h₂) h₂.i =
  CategoryTheory.CategoryStruct.comp h₁.i φ.τ₂


theorem comap_comp {S₁ : Type*} {S₂ : Type*} [Ring S₁] [Ring S₂] (f : S₁ →+* S₂) (g : S₂ →+* R) :
    v.comap (g.comp f) = (v.comap g).comap f

{R : Type u_3}
{Γ₀ : Type u_4}
[Ring R]
[LinearOrderedAddCommMonoidWithTop Γ₀]
(v : AddValuation R Γ₀)
{S₁ : Type u_6}
{S₂ : Type u_7}
[Ring S₁]
[Ring S₂]
(f : S₁ →+* S₂)
(g : S₂ →+* R)

AddValuation.comap (g.comp f) v = AddValuation.comap f (AddValuation.comap g v)


theorem gcd_eq_normalize [NormalizedGCDMonoid α] {a b c : α} (habc : gcd a b ∣ c)
    (hcab : c ∣ gcd a b) : gcd a b = normalize c

{α : Type u_1}
[CancelCommMonoidWithZero α]
[NormalizedGCDMonoid α]
{a b c : α}
(habc : gcd a b ∣ c)
(hcab : c ∣ gcd a b)


theorem eventually_lift'_iff (hh : Monotone h) {p : β → Prop} :
    (∀ᶠ y in f.lift' h, p y) ↔ ∃ t ∈ f, ∀ y ∈ h t, p y

{α : Type u_1}
{β : Type u_2}
{f : Filter α}
{h : Set α → Set β}
(hh : Monotone h)
{p : β → Prop}

(∀ᶠ (y : β) in f.lift' h, p y) ↔ ∃ t ∈ f, ∀ y ∈ h t, p y


@[to_additive EventuallyLE.add_le_add]
theorem EventuallyLE.mul_le_mul' [Mul β] [Preorder β] [CovariantClass β β (· * ·) (· ≤ ·)]
    [CovariantClass β β (swap (· * ·)) (· ≤ ·)] {l : Filter α} {f₁ f₂ g₁ g₂ : α → β}
    (hf : f₁ ≤ᶠ[l] f₂) (hg : g₁ ≤ᶠ[l] g₂) : f₁ * g₁ ≤ᶠ[l] f₂ * g₂

[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]

{f₁ f₂ g₁ g₂ : α → β}


protected theorem id {_m0 : MeasurableSpace α} (μ : Measure α) : QuasiMeasurePreserving id μ μ

{α : Type u_1}
{_m0 : MeasurableSpace α}
(μ : MeasureTheory.Measure α)

MeasureTheory.Measure.QuasiMeasurePreserving id μ μ


@[to_additive (attr := simp)]
theorem curry_mul [∀ a b, Mul (γ a b)] (x y : (i : Σ a, β a) → γ i.1 i.2) :
    Sigma.curry (x * y) = Sigma.curry x * Sigma.curry y

(x y : (i : (a : α) × β a) → γ i.fst i.snd)


lemma ltByCases_eq_iff {h₁ : x < y → P} {h₂ : x = y → P} {h₃ : y < x → P} {p : P} :
    ltByCases x y h₁ h₂ h₃ = p ↔ (∃ h, h₁ h = p) ∨ (∃ h, h₂ h = p) ∨ (∃ h, h₃ h = p)

{α : Type u_2}
[LinearOrder α]
{P : Sort u_5}
{x y : α}
{h₁ : x < y → P}
{h₂ : x = y → P}
{h₃ : y < x → P}
{p : P}

ltByCases x y h₁ h₂ h₃ = p ↔ (∃ h, h₁ h = p) ∨ (∃ h, h₂ h = p) ∨ ∃ h, h₃ h = p


@[simp, norm_cast]
theorem val_pow (x : selfAdjoint R) (n : ℕ) : ↑(x ^ n) = (x : R) ^ n

{R : Type u_1}
[Ring R]
[StarRing R]
(x : ↥(selfAdjoint R))
(n : ℕ)


@[to_additive]
theorem image_mulSingle_Ioo (i : ι) (a b : α i) :
    Pi.mulSingle i '' Ioo a b = Ioo (Pi.mulSingle i a) (Pi.mulSingle i b)

{ι : Type u_1}
{α : ι → Type u_2}
[DecidableEq ι]
[(i : ι) → PartialOrder (α i)]
[(i : ι) → Zero (α i)]
(i : ι)
(a b : α i)

Pi.single i '' Set.Ioo a b = Set.Ioo (Pi.single i a) (Pi.single i b)


@[to_additive]
theorem Step.cons {x} (H : Red.Step L₁ L₂) : Red.Step (x :: L₁) (x :: L₂)

{α : Type u}
{L₁ L₂ : List (α × Bool)}
{x : α × Bool}
(H : FreeGroup.Red.Step L₁ L₂)


lemma hasRightResolutions_iff_op : Φ.HasRightResolutions ↔ Φ.op.HasLeftResolutions

{W₁ : CategoryTheory.MorphismProperty C₁}

{W₂ : CategoryTheory.MorphismProperty C₂}

(Φ : CategoryTheory.LocalizerMorphism W₁ W₂)


@[to_additive (attr := measurability)]
theorem measurableSet_mulSupport [One β] [MeasurableSingletonClass β] (hf : Measurable f) :
    MeasurableSet (mulSupport f)

{α : Type u_1}
{β : Type u_2}
{f : α → β}
{m : MeasurableSpace α}
{mβ : MeasurableSpace β}
[One β]
[MeasurableSingletonClass β]
(hf : Measurable f)


theorem isAcyclic_iff_forall_edge_isBridge :
    G.IsAcyclic ↔ ∀ ⦃e⦄, e ∈ (G.edgeSet) → G.IsBridge e

G.IsAcyclic ↔ ∀ ⦃e : Sym2 V⦄, e ∈ G.edgeSet → G.IsBridge e


@[simp]
theorem quot_mk_to_coe'' (l : List α) : @Eq (Multiset α) (Quot.mk Setoid.r l) l


theorem MeasurableSet.image_inclusion {s t : Set α} (h : s ⊆ t) {u : Set s}
    (hs : MeasurableSet s) (hu : MeasurableSet u) :
    MeasurableSet (inclusion h '' u)

{α : Type u_1}
{m : MeasurableSpace α}
{s t : Set α}
(h : s ⊆ t)
{u : Set ↑s}
(hs : MeasurableSet s)
(hu : MeasurableSet u)


/-- If the union of disjoint measurable sets has finite measure, then there are only
countably many members of the union whose measure is positive. -/
theorem countable_meas_pos_of_disjoint_of_meas_iUnion_ne_top {ι : Type*} {_ : MeasurableSpace α}
    (μ : Measure α) {As : ι → Set α} (As_mble : ∀ i : ι, MeasurableSet (As i))
    (As_disj : Pairwise (Disjoint on As)) (Union_As_finite : μ (⋃ i, As i) ≠ ∞) :
    Set.Countable { i : ι | 0 < μ (As i) }

∀ {x : MeasurableSpace α} (μ : MeasureTheory.Measure α) {As : ι → Set α},
  (∀ (i : ι), MeasurableSet (As i)) → Pairwise (Disjoint on As) → μ (⋃ i, As i) ≠ ⊤ → {i | 0 < μ (As i)}.Countable


/-- Left multiplication by an element of a type with distributive multiplication is an `AddHom`. -/
@[simps (config := .asFn)]
def mulRight [Distrib R] (r : R) : AddHom R R


theorem coe_top [OrderTop α] [OrderTop (Subtype p)] (htop : p ⊤) : ((⊤ : Subtype p) : α) = ⊤

{α : Type u}
{p : α → Prop}
[PartialOrder α]
[OrderTop α]
[OrderTop (Subtype p)]
(htop : p ⊤)


/-- If a subset of a real vector space contains a segment, then the direction of this
segment belongs to the tangent cone at its endpoints. -/
theorem mem_tangentCone_of_segment_subset {s : Set G} {x y : G} (h : segment ℝ x y ⊆ s) :
    y - x ∈ tangentConeAt ℝ s x

{G : Type u_4}
[NormedAddCommGroup G]
[NormedSpace ℝ G]
{s : Set G}
{x y : G}
(h : segment ℝ x y ⊆ s)


/-- The `stepRet` function respects the `then k'` homomorphism. Note that this is an exact
equality, not a simulation; the original and embedded machines move in lock-step until the
embedded machine reaches the halt state. -/
theorem stepRet_then {k k' : Cont} {v} : stepRet (k.then k') v = (stepRet k v).then k'

{k k' : Turing.ToPartrec.Cont}
{v : List ℕ}

Turing.ToPartrec.stepRet (k.then k') v = (Turing.ToPartrec.stepRet k v).then k'


@[simp] theorem mkCoinductiveAux₂_zero :
    mkCoinductiveAux₂ e zero comm_zero one comm_one succ 0 =
      ⟨0, (P.xNextIso rfl).hom ≫ zero, mkCoinductiveAux₂.proof_2 e zero comm_zero⟩

(comm_one : e.f 1 = zero ≫ Q.d 0 1 + P.d 1 2 ≫ one)

Homotopy.mkCoinductiveAux₂ e zero comm_zero one comm_one succ 0 = ⟨0, ⟨(HomologicalComplex.xNextIso P ⋯).hom ≫ zero, ⋯⟩⟩


theorem iSup_singleton {f : β → α} {b : β} : ⨆ x ∈ (singleton b : Set β), f x = f b

{α : Type u_1}
{β : Type u_2}
[CompleteLattice α]
{f : β → α}
{b : β}


@[simp] lemma birkhoffFinset_sup (a b : α) :
    birkhoffFinset (a ⊔ b) = birkhoffFinset a ∪ birkhoffFinset b

{α : Type u_1}
[DistribLattice α]
[Fintype α]
[DecidablePred SupIrred]
[DecidableEq α]
(a b : α)

OrderEmbedding.birkhoffFinset (a ⊔ b) = OrderEmbedding.birkhoffFinset a ∪ OrderEmbedding.birkhoffFinset b


/-- If `M` is a `CanonicallyOrderedAddCommMonoid`, then the `weightedHomogeneousComponent`
  of weighted degree `0` of a polynomial is its constant coefficient. -/
@[simp]
theorem weightedHomogeneousComponent_zero [NoZeroSMulDivisors ℕ M] (hw : ∀ i : σ, w i ≠ 0) :
    weightedHomogeneousComponent w 0 φ = C (coeff 0 φ)

{R : Type u_1}
{M : Type u_2}
[CommSemiring R]
{σ : Type u_3}
[CanonicallyOrderedAddCommMonoid M]
{w : σ → M}
(φ : MvPolynomial σ R)
[NoZeroSMulDivisors ℕ M]
(hw : ∀ (i : σ), w i ≠ 0)

(MvPolynomial.weightedHomogeneousComponent w 0) φ = MvPolynomial.C (MvPolynomial.coeff 0 φ)


theorem nontrivial_pair {x y} (hxy : x ≠ y) : ({x, y} : Set α).Nontrivial


protected theorem map_eq_zero_iff : f x = 0 ↔ x = 0

{R : Type u_4}
{S : Type u_5}
[NonUnitalNonAssocSemiring R]
[NonUnitalNonAssocSemiring S]
(f : R ≃+* S)
{x : R}


@[to_additive]
theorem prod_mapDomain_index_inj [CommMonoid N] {f : α → β} {s : α →₀ M} {h : β → M → N}
    (hf : Function.Injective f) : (s.mapDomain f).prod h = s.prod fun a b => h (f a) b

{α : Type u_1}
{β : Type u_2}
{M : Type u_5}
{N : Type u_7}
[AddCommMonoid M]
[AddCommMonoid N]
{f : α → β}
{s : α →₀ M}
{h : β → M → N}
(hf : Function.Injective f)

(Finsupp.mapDomain f s).sum h = s.sum fun a b => h (f a) b


theorem lintegral_biUnion_finset {s : Finset β} {t : β → Set α} (hd : Set.PairwiseDisjoint (↑s) t)
    (hm : ∀ b ∈ s, MeasurableSet (t b)) (f : α → ℝ≥0∞) :
    ∫⁻ a in ⋃ b ∈ s, t b, f a ∂μ = ∑ b ∈ s, ∫⁻ a in t b, f a ∂μ

{α : Type u_1}
{β : Type u_2}
{m : MeasurableSpace α}
{μ : MeasureTheory.Measure α}
{s : Finset β}
{t : β → Set α}
(hd : (↑s).PairwiseDisjoint t)
(hm : ∀ b ∈ s, MeasurableSet (t b))
(f : α → ℝ≥0∞)

∫⁻ (a : α) in ⋃ b ∈ s, t b, f a ∂μ = ∑ b ∈ s, ∫⁻ (a : α) in t b, f a ∂μ


/-- The product of a function `g` defined only on a set `s` is equal to
the product of a function `f` defined everywhere,
as long as `f` and `g` agree on `s`, and `f = 1` off `s`. -/
@[to_additive "The sum of a function `g` defined only on a set `s` is equal to
the sum of a function `f` defined everywhere,
as long as `f` and `g` agree on `s`, and `f = 0` off `s`."]
theorem prod_congr_set {α : Type*} [CommMonoid α] {β : Type*} [Fintype β] (s : Set β)
    [DecidablePred (· ∈ s)] (f : β → α) (g : s → α) (w : ∀ (x : β) (h : x ∈ s), f x = g ⟨x, h⟩)
    (w' : ∀ x : β, x ∉ s → f x = 1) : Finset.univ.prod f = Finset.univ.prod g


@[simp]
lemma exists_subset_image_iff {p : Set β → Prop} : (∃ t ⊆ f '' s, p t) ↔ ∃ t ⊆ s, p (f '' t)

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


theorem xgcdAux_rec {r s t r' s' t'} (h : 0 < r) :
    xgcdAux r s t r' s' t' = xgcdAux (r' % r) (s' - r' / r * s) (t' - r' / r * t) r s t

r.xgcdAux s t r' s' t' = (r' % r).xgcdAux (s' - ↑r' / ↑r * s) (t' - ↑r' / ↑r * t) r s t


theorem dvd_of_mod_eq_zero {a b : Ordinal} (H : a % b = 0) : b ∣ a


theorem dist_conj_comm (z w : ℂ) : dist (conj z) w = dist z (conj w)

dist ((starRingEnd ℂ) z) w = dist z ((starRingEnd ℂ) w)


theorem mul_lt_top [LT α] {a b : WithTop α} (ha : a ≠ ⊤) (hb : b ≠ ⊤) : a * b < ⊤

{α : Type u_1}
[DecidableEq α]
[MulZeroClass α]
[LT α]
{a b : WithTop α}
(ha : a ≠ ⊤)
(hb : b ≠ ⊤)


/-- A side of a right-angled triangle divided by the cosine of the adjacent angle equals the
hypotenuse. -/
theorem dist_div_cos_angle_of_angle_eq_pi_div_two {p₁ p₂ p₃ : P} (h : ∠ p₁ p₂ p₃ = π / 2)
    (h0 : p₁ = p₂ ∨ p₃ ≠ p₂) : dist p₃ p₂ / Real.cos (∠ p₂ p₃ p₁) = dist p₁ p₃

{V : Type u_1}
{P : Type u_2}
[NormedAddCommGroup V]
[InnerProductSpace ℝ V]
[MetricSpace P]
[NormedAddTorsor V P]
{p₁ p₂ p₃ : P}
(h : ∠ p₁ p₂ p₃ = π / 2)
(h0 : p₁ = p₂ ∨ p₃ ≠ p₂)


theorem HasBasis.to_subset (hl : l.HasBasis p s) {t : ι → Set α} (h : ∀ i, p i → t i ⊆ s i)
    (ht : ∀ i, p i → t i ∈ l) : l.HasBasis p t

{α : Type u_1}
{ι : Sort u_4}
{l : Filter α}
{p : ι → Prop}
{s : ι → Set α}
(hl : l.HasBasis p s)
{t : ι → Set α}
(h : ∀ (i : ι), p i → t i ⊆ s i)
(ht : ∀ (i : ι), p i → t i ∈ l)


@[to_additive]
lemma norm_div_le_norm_div_add_norm_div (a b c : E) : ‖a / c‖ ≤ ‖a / b‖ + ‖b / c‖

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


theorem IsBigO.prod_rightl (h : f =O[l] g') : f =O[l] fun x => (g' x, k' x)

{α : Type u_1}
{E : Type u_3}
{F' : Type u_7}
{G' : Type u_8}
[Norm E]
[SeminormedAddCommGroup F']
[SeminormedAddCommGroup G']
{f : α → E}
{g' : α → F'}
(k' : α → G')
{l : Filter α}
(h : f =O[l] g')


@[simp]
theorem unbot'_coe {α} (d x : α) : unbot' d x = x


/-- A monotone function on `ω`-continuous partial orders is said to be continuous
if for every chain `c : chain α`, `f (⊔ i, c i) = ⊔ i, f (c i)`.
This is just the bundled version of `OrderHom.continuous`. -/
structure ContinuousHom extends OrderHom α β where
  /-- The underlying function of a `ContinuousHom` is continuous, i.e. it preserves `ωSup` -/
  cont : Continuous toOrderHom

{α : Type u}
{β : Type v}
[OmegaCompletePartialOrder α]
[OmegaCompletePartialOrder β]
(self : α →𝒄 β)


theorem mulMap_eq_mul'_comp_mapIncl : mulMap M N = .mul' R S ∘ₗ TensorProduct.mapIncl M N

{R : Type u}
{S : Type v}
[CommSemiring R]
[Semiring S]
[Algebra R S]
(M N : Submodule R S)

M.mulMap N = LinearMap.mul' R S ∘ₗ TensorProduct.mapIncl M N


theorem det_fin_one_of (a : R) : det !![a] = a


lemma iInf_sup_eq (f : ι → α) (a : α) : (⨅ i, f i) ⊔ a = ⨅ i, f i ⊔ a

{α : Type u}
{ι : Sort w}
(minAx : Order.Coframe.MinimalAxioms α)
(f : ι → α)
(a : α)


theorem dualBasis_equivFun [Finite ι] (l : Dual R M) (i : ι) :
    b.dualBasis.equivFun l i = l (b i)

{R : Type uR}
{M : Type uM}
{ι : Type uι}
[CommRing R]
[AddCommGroup M]
[Module R M]
[DecidableEq ι]
(b : Basis ι R M)
[Finite ι]
(l : Module.Dual R M)
(i : ι)


@[simp]
theorem prodProdProdComm_toEquiv :
    (prodProdProdComm R R' S S' : _ ≃ _) = Equiv.prodProdProdComm R R' S S'

(R : Type u_3)
(R' : Type u_4)
(S : Type u_5)
(S' : Type u_6)
[NonAssocSemiring R]
[NonAssocSemiring S]
[NonAssocSemiring R']
[NonAssocSemiring S']

↑(RingEquiv.prodProdProdComm R R' S S') = Equiv.prodProdProdComm R R' S S'


@[simp]
theorem comap_incl_self : comap I.incl I = ⊤

{R : Type u}
{L : Type v}
[CommRing R]
[LieRing L]
[LieAlgebra R L]
(I : LieIdeal R L)


/-- The composition of morphisms in `Φ.RightResolution X₂`. -/
@[simps]
def Hom.comp {R R' R'' : Φ.RightResolution X₂}
    (φ : Hom R R') (ψ : Hom R' R'') :
    Hom R R''

{W₁ : CategoryTheory.MorphismProperty C₁}

{W₂ : CategoryTheory.MorphismProperty C₂}

{Φ : CategoryTheory.LocalizerMorphism W₁ W₂}

(φ.comp ψ).f = CategoryTheory.CategoryStruct.comp φ.f ψ.f


/-- An additive functor preserves homotopy equivalences. -/
@[simps]
def Functor.mapHomotopyEquiv (F : V ⥤ W) [F.Additive] (h : HomotopyEquiv C D) :
    HomotopyEquiv ((F.mapHomologicalComplex c).obj C) ((F.mapHomologicalComplex c).obj D)

{ι : Type u_1}
{V : Type u}
[CategoryTheory.Category.{v, u} V]
[CategoryTheory.Preadditive V]
{c : ComplexShape ι}
{C D : HomologicalComplex V c}
{W : Type u_2}
[CategoryTheory.Category.{u_3, u_2} W]
[CategoryTheory.Preadditive W]
(F : V ⥤ W)
[F.Additive]
(h : HomotopyEquiv C D)

(F.mapHomotopyEquiv h).hom = (F.mapHomologicalComplex c).map h.hom


theorem Wbtw.sameRay_vsub_left {x y z : P} (h : Wbtw R x y z) : SameRay R (y -ᵥ x) (z -ᵥ x)

{R : Type u_1}
{V : Type u_2}
{P : Type u_4}
[StrictOrderedCommRing R]
[AddCommGroup V]
[Module R V]
[AddTorsor V P]
{x y z : P}
(h : Wbtw R x y z)


/-- Simplification of the integral of `sin x ^ m * cos x ^ n`, case `n` is odd. -/
theorem integral_sin_pow_mul_cos_pow_odd (m n : ℕ) :
    (∫ x in a..b, sin x ^ m * cos x ^ (2 * n + 1)) = ∫ u in sin a..sin b, u^m * (↑1 - u ^ 2) ^ n

∫ (x : ℝ) in a..b, Real.sin x ^ m * Real.cos x ^ (2 * n + 1) =
  ∫ (u : ℝ) in Real.sin a..Real.sin b, u ^ m * (1 - u ^ 2) ^ n


private theorem glueDist_comm (Φ : Z → X) (Ψ : Z → Y) (ε : ℝ) :
    ∀ x y, glueDist Φ Ψ ε x y = glueDist Φ Ψ ε y x

{X : Type u}
{Y : Type v}
{Z : Type w}
[MetricSpace X]
[MetricSpace Y]
(Φ : Z → X)
(Ψ : Z → Y)
(ε : ℝ)
(x y : X ⊕ Y)

Metric.glueDist Φ Ψ ε x y = Metric.glueDist Φ Ψ ε y x


theorem HEq.trans (h₁ : HEq a b) (h₂ : HEq b c) : HEq a c

{α β φ : Sort u}
{a : α}
{b : β}
{c : φ}
(h₁ : HEq a b)
(h₂ : HEq b c)


@[simp]
theorem inertiaDeg_of_subsingleton [hp : p.IsMaximal] [hQ : Subsingleton (S ⧸ P)] :
    inertiaDeg f p P = 0

{R : Type u}
[CommRing R]
{S : Type v}
[CommRing S]
(f : R →+* S)
(p : Ideal R)
(P : Ideal S)
[hp : p.IsMaximal]
[hQ : Subsingleton (S ⧸ P)]


@[simp]
theorem symm_trans_self (f : M₁ ≃ₛₗ[σ₁₂] M₂) : f.symm.trans f = LinearEquiv.refl R₂ M₂

{R₁ : Type u_2}
{R₂ : Type u_3}
{M₁ : Type u_9}
{M₂ : Type u_10}
[Semiring R₁]
[Semiring R₂]
[AddCommMonoid M₁]
[AddCommMonoid M₂]
{module_M₁ : Module R₁ M₁}
{module_M₂ : Module R₂ M₂}
{σ₁₂ : R₁ →+* R₂}
{σ₂₁ : R₂ →+* R₁}
{re₁₂ : RingHomInvPair σ₁₂ σ₂₁}
{re₂₁ : RingHomInvPair σ₂₁ σ₁₂}
(f : M₁ ≃ₛₗ[σ₁₂] M₂)


@[simp]
theorem LinearMap.toMatrixAlgEquiv_symm :
    (LinearMap.toMatrixAlgEquiv v₁).symm = Matrix.toLinAlgEquiv v₁

{R : Type u_1}
[CommSemiring R]
{n : Type u_4}
[Fintype n]
[DecidableEq n]
{M₁ : Type u_5}
[AddCommMonoid M₁]
[Module R M₁]
(v₁ : Basis n R M₁)


@[to_additive card_nsmul_le_sum]
lemma pow_card_le_prod (h : ∀ x ∈ s, a ≤ x) : a ^ card s ≤ s.prod

{α : Type u_2}
[OrderedAddCommMonoid α]
{s : Multiset α}
{a : α}
(h : ∀ x ∈ s, a ≤ x)


theorem slope_fun_def_field (f : k → k) (a : k) : slope f a = fun b => (f b - f a) / (b - a)

{k : Type u_1}
[Field k]
(f : k → k)
(a : k)


@[simp]
theorem invOfUnit_mul (φ : R⟦X⟧) (u : Rˣ) (h : constantCoeff R φ = u) :
    invOfUnit φ u * φ = 1

(h : (PowerSeries.constantCoeff R) φ = ↑u)


lemma rightUnshift_comp {m : ℤ} {a : ℤ} (γ' : Cochain L (M⟦a⟧) m) {nm : ℤ} (hnm : n + m = nm)
    (nm' : ℤ) (hnm' : nm + a = nm') (m' : ℤ) (hm' : m + a = m') :
    (γ.comp γ' hnm).rightUnshift nm' hnm' =
      γ.comp (γ'.rightUnshift m' hm') (by omega)

(γ : CochainComplex.HomComplex.Cochain K L n)

(γ' : CochainComplex.HomComplex.Cochain L ((CategoryTheory.shiftFunctor (CochainComplex C ℤ) a).obj M) m)

(γ.comp γ' hnm).rightUnshift nm' hnm' = γ.comp (γ'.rightUnshift m' hm') ⋯


protected theorem Perm.ext_iff {σ τ : Equiv.Perm α} : σ = τ ↔ ∀ x, σ x = τ x


lemma one_sub_inv_eq_geometric_of_summable_norm {f : ℕ →*₀ F} {p : ℕ} (hp : p.Prime)
    (hsum : Summable fun x ↦ ‖f x‖) :
    (1 - f p)⁻¹ = ∑' (e : ℕ), f (p ^ e)

{F : Type u_1}
[NormedField F]
[CompleteSpace F]
{f : ℕ →*₀ F}
{p : ℕ}
(hp : Nat.Prime p)
(hsum : Summable fun x => ‖f x‖)


theorem mem_adicCompletionIntegers {x : v.adicCompletion K} :
    x ∈ v.adicCompletionIntegers K ↔ (Valued.v x : ℤₘ₀) ≤ 1

(v : IsDedekindDomain.HeightOneSpectrum R)

{x : IsDedekindDomain.HeightOneSpectrum.adicCompletion K v}

x ∈ IsDedekindDomain.HeightOneSpectrum.adicCompletionIntegers K v ↔ Valued.v x ≤ 1


private theorem soln_dist_to_a : ‖soln - a‖ = ‖F.eval a‖ / ‖F.derivative.eval a‖

(hnorm : ‖Polynomial.eval a F‖ < ‖Polynomial.eval a (Polynomial.derivative F)‖ ^ 2)

‖soln_gen hnorm - a‖ = ‖Polynomial.eval a F‖ / ‖Polynomial.eval a (Polynomial.derivative F)‖


theorem Invariant.comp_const (hκ : Invariant κ μ) : κ ∘ₖ const α μ = const α μ

{α : Type u_1}
{mα : MeasurableSpace α}
{κ : ProbabilityTheory.Kernel α α}
{μ : MeasureTheory.Measure α}
(hκ : κ.Invariant μ)

κ ∘ₖ ProbabilityTheory.Kernel.const α μ = ProbabilityTheory.Kernel.const α μ


@[simp]
theorem coeFn_zero : ⇑(0 : lp E p) = 0

{α : Type u_1}
(E : α → Type u_2)
(p : ℝ≥0∞)
[(i : α) → NormedAddCommGroup (E i)]


/-- A continuous, periodic function is bounded. -/
theorem Periodic.isBounded_of_continuous [PseudoMetricSpace α] {f : ℝ → α} {c : ℝ}
    (hp : Periodic f c) (hc : c ≠ 0) (hf : Continuous f) : IsBounded (range f)

{α : Type u}
[PseudoMetricSpace α]
{f : ℝ → α}
{c : ℝ}
(hp : Function.Periodic f c)
(hc : c ≠ 0)
(hf : Continuous f)


theorem WellFounded.asymmetric {α : Sort*} {r : α → α → Prop} (h : WellFounded r) (a b) :
    r a b → ¬r b a

{α : Sort u_1}
{r : α → α → Prop}
(h : WellFounded r)
(a b : α)


theorem map_restrict_dom_evalₗ : (restrictDegree σ K (Fintype.card K - 1)).map (evalₗ K σ) = ⊤

(K : Type u_1)
(σ : Type u_2)
[Field K]
[Fintype K]
[Finite σ]

Submodule.map (MvPolynomial.evalₗ K σ) (MvPolynomial.restrictDegree σ K (Fintype.card K - 1)) = ⊤


@[reassoc (attr := simp)]
lemma opcyclesIsoSc'_inv_fromOpcycles :
    (K.opcyclesIsoSc' i j k hi hk).inv ≫ K.fromOpcycles j k =
      (K.sc' i j k).fromOpcycles


theorem wSameSide_and_wOppSide_iff {s : AffineSubspace R P} {x y : P} :
    s.WSameSide x y ∧ s.WOppSide x y ↔ x ∈ s ∨ y ∈ s

{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 y : P}


theorem IsBigOWith.congr_const (h : IsBigOWith c₁ l f g) (hc : c₁ = c₂) : IsBigOWith c₂ l f g

{α : Type u_1}
{E : Type u_3}
{F : Type u_4}
[Norm E]
[Norm F]
{c₁ c₂ : ℝ}
{f : α → E}
{g : α → F}
{l : Filter α}
(h : Asymptotics.IsBigOWith c₁ l f g)
(hc : c₁ = c₂)