@[simp]
theorem decode_inl (s : Sym (Option α) n) : decode (Sum.inl s) = none ::ₛ s

{α : Type u_1}
{n : ℕ}
(s : Sym (Option α) n)

SymOptionSuccEquiv.decode (Sum.inl s) = none ::ₛ s


theorem setLIntegral_nnnorm_condexpIndSMul_le (hm : m ≤ m0) (hs : MeasurableSet s) (hμs : μ s ≠ ∞)
    (x : G) {t : Set α} (ht : MeasurableSet[m] t) (hμt : μ t ≠ ∞) :
    (∫⁻ a in t, ‖condexpIndSMul hm hs hμs x a‖₊ ∂μ) ≤ μ (s ∩ t) * ‖x‖₊

{α : Type u_1}
{G : Type u_5}
[NormedAddCommGroup G]
{m m0 : MeasurableSpace α}
{μ : MeasureTheory.Measure α}
{s : Set α}
[NormedSpace ℝ G]
(hm : m ≤ m0)
(hs : MeasurableSet s)
(hμs : μ s ≠ ⊤)
(x : G)
{t : Set α}
(ht : MeasurableSet t)
(hμt : μ t ≠ ⊤)

∫⁻ (a : α) in t, ↑‖↑↑(MeasureTheory.condexpIndSMul hm hs hμs x) a‖₊ ∂μ ≤ μ (s ∩ t) * ↑‖x‖₊


/-- The bifunctor `Cᵒᵖ ⥤ C ⥤ SSet.{v}` which sends `K : Cᵒᵖ` and `L : C` to `sHom K.unop L`. -/
@[simps]
noncomputable def sHomFunctor : Cᵒᵖ ⥤ C ⥤ SSet.{v}

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

∀ {X Y : Cᵒᵖ} (φ : X ⟶ Y) (L : C),
  ((CategoryTheory.SimplicialCategory.sHomFunctor C).map φ).app L =
    CategoryTheory.SimplicialCategory.sHomWhiskerRight φ.unop L


theorem exists_forall_sphere_dist_add_le_two_sub (hε : 0 < ε) :
    ∃ δ, 0 < δ ∧ ∀ ⦃x : E⦄, ‖x‖ = 1 → ∀ ⦃y⦄, ‖y‖ = 1 → ε ≤ ‖x - y‖ → ‖x + y‖ ≤ 2 - δ

(E : Type u_1)
[SeminormedAddCommGroup E]
[UniformConvexSpace E]
{ε : ℝ}
(hε : 0 < ε)

∃ δ, 0 < δ ∧ ∀ ⦃x : E⦄, ‖x‖ = 1 → ∀ ⦃y : E⦄, ‖y‖ = 1 → ε ≤ ‖x - y‖ → ‖x + y‖ ≤ 2 - δ


theorem min_lt_of_right_lt (h : b < c) : min a b < c

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


lemma integral_le_liminf_integral_of_forall_isOpen_measure_le_liminf_measure
    {μ : Measure Ω} [IsProbabilityMeasure μ] {μs : ℕ → Measure Ω} [∀ i, IsProbabilityMeasure (μs i)]
    {f : Ω →ᵇ ℝ} (f_nn : 0 ≤ f)
    (h_opens : ∀ G, IsOpen G → μ G ≤ atTop.liminf (fun i ↦ μs i G)) :
    ∫ x, (f x) ∂μ ≤ atTop.liminf (fun i ↦ ∫ x, (f x) ∂ (μs i))

[∀ (i : ℕ), MeasureTheory.IsProbabilityMeasure (μs i)]

{f : Ω →ᵇ ℝ}

(h_opens : ∀ (G : Set Ω), IsOpen G → μ G ≤ Filter.liminf (fun i => (μs i) G) Filter.atTop)

∫ (x : Ω), f x ∂μ ≤ Filter.liminf (fun i => ∫ (x : Ω), f x ∂μs i) Filter.atTop


theorem formPerm_toList (f : Perm α) (x : α) : formPerm (toList f x) = f.cycleOf x

{α : Type u_1}
[Fintype α]
[DecidableEq α]
(f : Equiv.Perm α)
(x : α)


/-- Affine equivalences preserve affine independence of families of points. -/
theorem AffineEquiv.affineIndependent_iff {p : ι → P} (e : P ≃ᵃ[k] P₂) :
    AffineIndependent k (e ∘ p) ↔ AffineIndependent k p

{k : Type u_1}
{V : Type u_2}
{P : Type u_3}
[Ring k]
[AddCommGroup V]
[Module k V]
[AffineSpace V P]
{ι : Type u_4}
{V₂ : Type u_5}
{P₂ : Type u_6}
[AddCommGroup V₂]
[Module k V₂]
[AffineSpace V₂ P₂]
{p : ι → P}
(e : P ≃ᵃ[k] P₂)

AffineIndependent k (⇑e ∘ p) ↔ AffineIndependent k p


/-- An implication of predicates `P → P'` induces a braided functor between full braided
subcategories. -/
@[simps!]
def fullBraidedSubcategory.map (h : ∀ ⦃X⦄, P X → P' X) :
    BraidedFunctor (FullSubcategory P) (FullSubcategory P')

((CategoryTheory.MonoidalCategory.fullBraidedSubcategory.map h).obj X).obj = X.obj


/-- If `S` a finite-dimensional ring extension of a PID `R` which is free as an `R`-module,
then any nonzero `S`-ideal `I` is free as an `R`-submodule of `S`, and we can
find a basis for `S` and `I` such that the inclusion map is a square diagonal
matrix.

See also `Ideal.smithNormalForm` for a version of this theorem that returns
a `Basis.SmithNormalForm`.

The definitions `Ideal.ringBasis`, `Ideal.selfBasis`, `Ideal.smithCoeffs` are (noncomputable)
choices of values for this existential quantifier.
-/
theorem Ideal.exists_smith_normal_form (b : Basis ι R S) (I : Ideal S) (hI : I ≠ ⊥) :
    ∃ (b' : Basis ι R S) (a : ι → R) (ab' : Basis ι R I), ∀ i, (ab' i : S) = a i • b' i

{ι : Type u_1}
{R : Type u_2}
[CommRing R]
[IsDomain R]
[IsPrincipalIdealRing R]
{S : Type u_4}
[CommRing S]
[IsDomain S]
[Algebra R S]
[Finite ι]
(b : Basis ι R S)
(I : Ideal S)
(hI : I ≠ ⊥)

∃ b' a ab', ∀ (i : ι), ↑(ab' i) = a i • b' i


/-- A non_unital `k`-algebra homomorphism from `k[G]` is uniquely defined by its
values on the functions `single a 1`. -/
theorem nonUnitalAlgHom_ext [DistribMulAction k A] {φ₁ φ₂ : k[G] →ₙₐ[k] A}
    (h : ∀ x, φ₁ (single x 1) = φ₂ (single x 1)) : φ₁ = φ₂

(h : ∀ (x : G), φ₁ (AddMonoidAlgebra.single x 1) = φ₂ (AddMonoidAlgebra.single x 1))


theorem log_eq_one_iff' {b n : ℕ} : log b n = 1 ↔ b ≤ n ∧ n < b * b


theorem get?_push_eq (a : Array α) (x : α) : (a.push x)[a.size]? = some x


lemma integral_toReal_rnDeriv [SigmaFinite μ] [SigmaFinite ν] (hμν : μ ≪ ν) :
    ∫ x, (μ.rnDeriv ν x).toReal ∂ν = (μ Set.univ).toReal

{α : Type u_1}
{m : MeasurableSpace α}
{μ ν : MeasureTheory.Measure α}
[MeasureTheory.SigmaFinite μ]
[MeasureTheory.SigmaFinite ν]
(hμν : μ ≪ ν)

∫ (x : α), (μ.rnDeriv ν x).toReal ∂ν = (μ Set.univ).toReal


theorem coeff_add_eq_right_of_lt (pn : p.natDegree < n) : (p + q).coeff n = q.coeff n

{R : Type u}
{n : ℕ}
[Semiring R]
{p q : R[X]}
(pn : p.natDegree < n)


theorem mk_eq_mk' (s : S) (m : M) :
    LocalizedModule.mk m s = mk' (LocalizedModule.mkLinearMap S M) m s

{R : Type u_1}
[CommSemiring R]
{S : Submonoid R}
{M : Type u_2}
[AddCommMonoid M]
[Module R M]
(s : ↥S)
(m : M)

LocalizedModule.mk m s = IsLocalizedModule.mk' (LocalizedModule.mkLinearMap S M) m s


/-- The variable of the power series ring over an integral domain is prime. -/
theorem X_prime : Prime (X : R⟦X⟧)

{R : Type u_1}
[CommRing R]
[IsDomain R]


theorem isLimit_add_iff {a b} : IsLimit (a + b) ↔ IsLimit b ∨ b = 0 ∧ IsLimit a

(a + b).IsLimit ↔ b.IsLimit ∨ b = 0 ∧ a.IsLimit


@[to_additive]
theorem image_inter_mulSupport_eq {s : Set β} {g : β → α} :
    g '' s ∩ mulSupport f = g '' (s ∩ mulSupport (f ∘ g))

{α : Type u_1}
{β : Type u_2}
{M : Type u_3}
[Zero M]
{f : α → M}
{s : Set β}
{g : β → α}

g '' s ∩ Function.support f = g '' (s ∩ Function.support (f ∘ g))


@[simp]
theorem blockDiagonal'_one [∀ i, DecidableEq (m' i)] [One α] :
    blockDiagonal' (1 : ∀ i, Matrix (m' i) (m' i) α) = 1

{o : Type u_4}
{m' : o → Type u_7}
{α : Type u_12}
[DecidableEq o]
[Zero α]
[(i : o) → DecidableEq (m' i)]
[One α]


theorem append_eq_cons :
    a ++ b = x :: c ↔ (a = [] ∧ b = x :: c) ∨ (∃ a', a = x :: a' ∧ c = a' ++ b)

∀ {α : Type u_1} {a b : List α} {x : α} {c : List α},
  a ++ b = x :: c ↔ a = [] ∧ b = x :: c ∨ ∃ a', a = x :: a' ∧ c = a' ++ b


theorem IsClosed.reProdIm (hs : IsClosed s) (ht : IsClosed t) : IsClosed (s ×ℂ t)

{s t : Set ℝ}
(hs : IsClosed s)
(ht : IsClosed t)


@[simp]
theorem image_closedBall (h : α ≃ᵢ β) (x : α) (r : ℝ) :
    h '' Metric.closedBall x r = Metric.closedBall (h x) r

{α : Type u}
{β : Type v}
[PseudoMetricSpace α]
[PseudoMetricSpace β]
(h : α ≃ᵢ β)
(x : α)
(r : ℝ)

⇑h '' Metric.closedBall x r = Metric.closedBall (h x) r


/-- A measure `μ` on a measurable group is left invariant
  if the measure of left translations of a set are equal to the measure of the set itself. -/
@[to_additive existing]
class IsMulLeftInvariant [Mul G] (μ : Measure G) : Prop where
  map_mul_left_eq_self : ∀ g : G, map (g * ·) μ = μ

{G : Type u_2}
[MeasurableSpace G]
[Mul G]
{μ : MeasureTheory.Measure G}
[self : μ.IsMulLeftInvariant]
(g : G)

MeasureTheory.Measure.map (fun x => g * x) μ = μ


theorem EqOn.bijOn_iff (H : EqOn f₁ f₂ s) : BijOn f₁ s t ↔ BijOn f₂ s t

{α : Type u_1}
{β : Type u_2}
{s : Set α}
{t : Set β}
{f₁ f₂ : α → β}
(H : Set.EqOn f₁ f₂ s)


@[simp] lemma last_cons (p : RelSeries r) (newHead : α) (rel : r newHead p.head) :
    (p.cons newHead rel).last = p.last

{α : Type u_1}
{r : Rel α α}
(p : RelSeries r)
(newHead : α)
(rel : r newHead p.head)


@[to_additive (attr := simp)]
lemma map_comp_pow [Group G] [DivisionMonoid H] [MonoidHomClass F G H] (f : F) (g : ι → G) (n : ℕ) :
    f ∘ (g ^ n) = f ∘ g ^ n

{ι : Type u_1}
{G : Type u_7}
{H : Type u_8}
{F : Type u_9}
[FunLike F G H]
[AddGroup G]
[SubtractionMonoid H]
[AddMonoidHomClass F G H]
(f : F)
(g : ι → G)
(n : ℕ)


theorem LocallyCompactSpace.of_hasBasis {ι : X → Type*} {p : ∀ x, ι x → Prop}
    {s : ∀ x, ι x → Set X} (h : ∀ x, (𝓝 x).HasBasis (p x) (s x))
    (hc : ∀ x i, p x i → IsCompact (s x i)) : LocallyCompactSpace X

(h : ∀ (x : X), (𝓝 x).HasBasis (p x) (s x))

(hc : ∀ (x : X) (i : ι x), p x i → IsCompact (s x i))


@[to_additive (attr := simp)]
theorem map_comp (f : α →ₙ* β) (g : β →ₙ* γ) : map (g.comp f) = (map g).comp (map f)

{α : Type u}
{β : Type v}
{γ : Type w}
[Add α]
[Add β]
[Add γ]
(f : AddHom α β)
(g : AddHom β γ)

WithZero.map (g.comp f) = (WithZero.map g).comp (WithZero.map f)


/-- The symbol `J(a | 1)` has the value `1`. -/
@[simp]
theorem one_right (a : ℤ) : J(a | 1) = 1


theorem rpow_le_one {x z : ℝ} (hx1 : 0 ≤ x) (hx2 : x ≤ 1) (hz : 0 ≤ z) : x ^ z ≤ 1


lemma EquicontinuousAt.equicontinuousWithinAt {F : ι → X → α} {x₀ : X} (H : EquicontinuousAt F x₀)
    (S : Set X) : EquicontinuousWithinAt F S x₀

{ι : Type u_1}
{X : Type u_3}
{α : Type u_7}
[tX : TopologicalSpace X]
[uα : UniformSpace α]
{F : ι → X → α}
{x₀ : X}
(H : EquicontinuousAt F x₀)
(S : Set X)


@[simp]
theorem coe_copy (f : sInfHom α β) (f' : α → β) (h : f' = f) : ⇑(f.copy f' h) = f'

{α : Type u_2}
{β : Type u_3}
[InfSet α]
[InfSet β]
(f : sInfHom α β)
(f' : α → β)
(h : f' = ⇑f)


/-- The canonical map `DoubleCentralizer.toProd` as an additive group homomorphism. -/
@[simps]
def toProdHom : 𝓜(𝕜, A) →+ (A →L[𝕜] A) × (A →L[𝕜] A)

{𝕜 : Type u_1}
{A : Type u_2}
[NontriviallyNormedField 𝕜]
[NonUnitalNormedRing A]
[NormedSpace 𝕜 A]
[SMulCommClass 𝕜 A A]
[IsScalarTower 𝕜 A A]
(self : 𝓜(𝕜, A))

DoubleCentralizer.toProdHom self = self.toProd


@[ext]
theorem ext ⦃f g : r ↪r s⦄ (h : ∀ x, f x = g x) : f = g

{α : Type u_1}
{β : Type u_2}
{r : α → α → Prop}
{s : β → β → Prop}
⦃f g : r ↪r s⦄
(h : ∀ (x : α), f x = g x)


lemma separatesPoints_continuous_of_t35Space_Icc [T35Space X] :
    SeparatesPoints (Continuous : Set (X → I))

{X : Type u}
[TopologicalSpace X]
[T1Space X]
[T35Space X]


/-- The 'identity' equivalence between `Fin m` and `Fin n` when `m = n`. -/
@[simps]
def _root_.finCongr (eq : n = m) : Fin n ≃ Fin m


theorem foldrIdx_eq_foldr_enum (f : ℕ → α → β → β) (b : β) (as : List α) :
    foldrIdx f b as = foldr (uncurry f) b (enum as)

{α : Type u}
{β : Type v}
(f : ℕ → α → β → β)
(b : β)
(as : List α)

List.foldrIdx f b as = List.foldr (Function.uncurry f) b as.enum


@[to_additive (attr := simp)]
theorem prod_to_list (s : Finset α) (f : α → β) : (s.toList.map f).prod = s.prod f

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


@[simp]
theorem of_zero [Zero α] : of (0 : m → n → α) = 0

{m : Type u_2}
{n : Type u_3}
{α : Type v}
[Zero α]


@[reassoc (attr := simp)]
lemma _root_.CategoryTheory.Iso.inv_hom_id_triangle_hom₁ {A B : Triangle C} (e : A ≅ B) :
    e.inv.hom₁ ≫ e.hom.hom₁ = 𝟙 _

{A B : CategoryTheory.Pretriangulated.Triangle C}


theorem _root_.RingHom.map_det (f : R →+* S) (M : Matrix n n R) :
    f M.det = Matrix.det (f.mapMatrix M)

{n : Type u_2}
[DecidableEq n]
[Fintype n]
{R : Type v}
[CommRing R]
{S : Type w}
[CommRing S]
(f : R →+* S)
(M : Matrix n n R)


@[to_additive]
theorem ExponentExists.of_finite : ExponentExists G

{G : Type u}
[AddLeftCancelMonoid G]
[Finite G]


@[simp]
theorem continuousMultilinearCurryFin0_symm_apply (x : G') (v : Fin 0 → G) :
    (continuousMultilinearCurryFin0 𝕜 G G').symm x v = x

{𝕜 : Type u}
{G : Type wG}
{G' : Type wG'}
[NontriviallyNormedField 𝕜]
[NormedAddCommGroup G]
[NormedSpace 𝕜 G]
[NormedAddCommGroup G']
[NormedSpace 𝕜 G']
(x : G')
(v : Fin 0 → G)

((continuousMultilinearCurryFin0 𝕜 G G').symm x) v = x


@[to_additive (attr := simp)]
lemma UniformOnFun.ofFun_inv [Inv β] (f : α → β) : ofFun 𝔖 (f⁻¹) = (ofFun 𝔖 f)⁻¹

{α : Type u_1}
{β : Type u_2}
{𝔖 : Set (Set α)}
[Neg β]
(f : α → β)

(UniformOnFun.ofFun 𝔖) (-f) = -(UniformOnFun.ofFun 𝔖) f


theorem EqualizerCondition.mk (P : Cᵒᵖ ⥤ Type*)
    (hP : ∀ (X B : C) (π : X ⟶ B) [EffectiveEpi π] [HasPullback π π], Function.Bijective
    (MapToEqualizer P π (pullback.fst π π) (pullback.snd π π)
    pullback.condition)) : EqualizerCondition P

(P : CategoryTheory.Functor Cᵒᵖ (Type u_4))

(hP :
  ∀ (X B : C) (π : X ⟶ B) [inst : CategoryTheory.EffectiveEpi π] [inst : CategoryTheory.Limits.HasPullback π π],
    Function.Bijective
      (CategoryTheory.regularTopology.MapToEqualizer P π (CategoryTheory.Limits.pullback.fst π π)
        (CategoryTheory.Limits.pullback.snd π π) ⋯))


theorem sup_support_finset_prod_le (degb0 : degb 0 ≤ 0)
    (degbm : ∀ a b, degb (a + b) ≤ degb a + degb b) (s : Finset ι) (f : ι → R[A]) :
    (∏ i ∈ s, f i).support.sup degb ≤ ∑ i ∈ s, (f i).support.sup degb

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

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

(degbm : ∀ (a b : A), degb (a + b) ≤ degb a + degb b)


/-- (Impl) A preliminary definition to avoid timeouts. -/
@[simps]
def conesEquivInverseObj (B : C) {J : Type w} (F : Discrete J ⥤ Over B) (c : Cone F) :
    Cone (widePullbackDiagramOfDiagramOver B F)

(F : CategoryTheory.Discrete J ⥤ CategoryTheory.Over B)

(CategoryTheory.Over.ConstructProducts.conesEquivInverseObj B F c).pt = c.pt.left


protected lemma IsDiag.map : e.IsDiag → (e.map f).IsDiag

{α : Type u_1}
{β : Type u_2}
{e : Sym2 α}
{f : α → β}


@[to_additive]
theorem Step.to_red : Step L₁ L₂ → Red L₁ L₂

FreeGroup.Red.Step L₁ L₂ → FreeGroup.Red L₁ L₂


theorem lt_aleph0 {c : Cardinal} : c < ℵ₀ ↔ ∃ n : ℕ, c = n


@[simp]
theorem neg_mk (x : ℕ × K) : -mk K p x = mk K p (x.1, -x.2)

(K : Type u)
[CommRing K]
(p : ℕ)
[Fact (Nat.Prime p)]
[CharP K p]
(x : ℕ × K)

-PerfectClosure.mk K p x = PerfectClosure.mk K p (x.1, -x.2)


protected theorem finiteDimensional [Finite ι] (b : AffineBasis ι k P) : FiniteDimensional k V

{ι : Type u₁}
{k : Type u₂}
{V : Type u₃}
{P : Type u₄}
[AddCommGroup V]
[AffineSpace V P]
[DivisionRing k]
[Module k V]
[Finite ι]
(b : AffineBasis ι k P)


@[simp]
theorem toIcoDiv_sub_zsmul' (a b : α) (m : ℤ) :
    toIcoDiv hp (a - m • p) b = toIcoDiv hp a b + m

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


/-- If two linear maps are equal, they are equal at each point. -/
protected theorem congr_fun (h : f = g) (x : M) : f x = g x

{R : Type u_1}
{S : Type u_6}
{M : Type u_9}
{M₃ : Type u_12}
[Semiring R]
[Semiring S]
[AddCommMonoid M]
[AddCommMonoid M₃]
[Module R M]
[Module S M₃]
{σ : R →+* S}
{f g : M →ₛₗ[σ] M₃}
(h : f = g)
(x : M)


/-- "Precomposition" of `F : ComposableArrows C n` by a morphism `f : X ⟶ F.left`. -/
@[simps]
def precomp {X : C} (f : X ⟶ F.left) : ComposableArrows C (n + 1)

(F : CategoryTheory.ComposableArrows C n)

∀ (a : Fin (n + 1 + 1)), (F.precomp f).obj a = CategoryTheory.ComposableArrows.Precomp.obj F X a


theorem lhopital_zero_atBot_on_Iio (hdf : DifferentiableOn ℝ f (Iio a))
    (hg' : ∀ x ∈ Iio a, (deriv g) x ≠ 0) (hfbot : Tendsto f atBot (𝓝 0))
    (hgbot : Tendsto g atBot (𝓝 0)) (hdiv : Tendsto (fun x => (deriv f) x / (deriv g) x) atBot l) :
    Tendsto (fun x => f x / g x) atBot l

(hdf : DifferentiableOn ℝ f (Set.Iio a))

(hfbot : Filter.Tendsto f Filter.atBot (𝓝 0))

(hgbot : Filter.Tendsto g Filter.atBot (𝓝 0))

(hdiv : Filter.Tendsto (fun x => deriv f x / deriv g x) Filter.atBot l)

Filter.Tendsto (fun x => f x / g x) Filter.atBot l


@[to_additive (attr := continuity) continuous_sub_right]
lemma continuous_div_right' (a : G) : Continuous (· / a)

{G : Type w}
[TopologicalSpace G]
[Sub G]
[ContinuousSub G]
(a : G)


lemma mulSupport_add_one' [AddRightCancelMonoid R] (f : ι → R) : mulSupport (f + 1) = support f

{ι : Type u_1}
{R : Type u_5}
[One R]
[AddRightCancelMonoid R]
(f : ι → R)

Function.mulSupport (f + 1) = Function.support f


theorem exists_normalWord_prod_eq
    (d : TransversalPair G A B) (w : ReducedWord G A B) :
    ∃ w' : NormalWord d, w'.prod φ = w.prod φ ∧
      w'.toList.map Prod.fst = w.toList.map Prod.fst ∧
      ∀ u ∈ w.toList.head?.map Prod.fst,
      w'.head⁻¹ * w.head ∈ toSubgroup A B (-u)

(d : HNNExtension.NormalWord.TransversalPair G A B)

(w : HNNExtension.NormalWord.ReducedWord G A B)

∃ w',
  HNNExtension.NormalWord.ReducedWord.prod φ w'.toReducedWord = HNNExtension.NormalWord.ReducedWord.prod φ w ∧
    List.map Prod.fst w'.toList = List.map Prod.fst w.toList ∧
      ∀ u ∈ Option.map Prod.fst w.toList.head?, w'.head⁻¹ * w.head ∈ HNNExtension.toSubgroup A B (-u)


theorem image_source_eq_target : e '' e.source = e.target

{X : Type u_1}
{Y : Type u_3}
[TopologicalSpace X]
[TopologicalSpace Y]
(e : PartialHomeomorph X Y)


@[simp]
theorem coe_sum {ι : Type*} (s : Finset ι) (f : ι → α →ᵇ β) :
    ⇑(∑ i ∈ s, f i) = ∑ i ∈ s, (f i : α → β)

{α : Type u}
{β : Type v}
[TopologicalSpace α]
[PseudoMetricSpace β]
[AddCommMonoid β]
[BoundedAdd β]
[ContinuousAdd β]
{ι : Type u_2}
(s : Finset ι)
(f : ι → BoundedContinuousFunction α β)


/-- **Maximum modulus principle**: if `f : M → F` is complex differentiable in a neighborhood of `c`
and the norm `‖f z‖` has a local maximum at `c`, then `‖f z‖` is locally constant in a neighborhood
of `c`. This is a manifold version of `Complex.norm_eventually_eq_of_isLocalMax`. -/
theorem Complex.norm_eventually_eq_of_mdifferentiableAt_of_isLocalMax {f : M → F} {c : M}
    (hd : ∀ᶠ z in 𝓝 c, MDifferentiableAt I 𝓘(ℂ, F) f z) (hc : IsLocalMax (norm ∘ f) c) :
    ∀ᶠ y in 𝓝 c, ‖f y‖ = ‖f c‖

(hd : ∀ᶠ (z : M) in 𝓝 c, MDifferentiableAt I 𝓘(ℂ, F) f z)


/-- The autoequivalence `Cᵒᵖ ≌ Cᵒᵖ` whose functor is `shiftFunctor Cᵒᵖ n` and whose inverse
functor is `(shiftFunctor C n).op`. Do not unfold the definitions of the unit and counit
isomorphisms: the compatibilities they satisfy are stated as separate lemmas. -/
@[simps functor inverse]
noncomputable def opShiftFunctorEquivalence (n : ℤ) : Cᵒᵖ ≌ Cᵒᵖ

(C : Type u_1)
[CategoryTheory.Category.{u_2, u_1} C]
[CategoryTheory.HasShift C ℤ]
(n : ℤ)

(CategoryTheory.Pretriangulated.opShiftFunctorEquivalence C n).functor = CategoryTheory.shiftFunctor Cᵒᵖ n


theorem eventually_inf_principal {f : Filter α} {p : α → Prop} {s : Set α} :
    (∀ᶠ x in f ⊓ 𝓟 s, p x) ↔ ∀ᶠ x in f, x ∈ s → p x

{α : Type u}
{f : Filter α}
{p : α → Prop}
{s : Set α}

(∀ᶠ (x : α) in f ⊓ 𝓟 s, p x) ↔ ∀ᶠ (x : α) in f, x ∈ s → p x


lemma mem_smul_iff_inv_mul_mem {S} [Field S] [Algebra R S] {x : S} {p : Submodule R S} {y : S}
    (hx : x ≠ 0) : y ∈ x • p ↔ x⁻¹ * y ∈ p

{R : Type u}
[CommSemiring R]
{S : Type u_1}
[Field S]
[Algebra R S]
{x : S}
{p : Submodule R S}
{y : S}
(hx : x ≠ 0)


/-- Property ensuring that the model with corners `I` defines manifolds without boundary. This
  differs from the more general `BoundarylessManifold`, which requires every point on the manifold
  to be an interior point.  -/
class ModelWithCorners.Boundaryless {𝕜 : Type*} [NontriviallyNormedField 𝕜] {E : Type*}
    [NormedAddCommGroup E] [NormedSpace 𝕜 E] {H : Type*} [TopologicalSpace H]
    (I : ModelWithCorners 𝕜 E H) : Prop where
  range_eq_univ : range I = univ

{𝕜 : Type u_1}
[NontriviallyNormedField 𝕜]
{E : Type u_2}
[NormedAddCommGroup E]
[NormedSpace 𝕜 E]
{H : Type u_3}
[TopologicalSpace H]
{I : ModelWithCorners 𝕜 E H}
[self : I.Boundaryless]


/-- Suppose an indexed family of points is given, along with a subset
of the index type.  A vector can be expressed as `weightedVSub` using
a `Finset` lying within that subset and with sum of weights 0 if and
only if it can be expressed as `weightedVSub` with sum of weights 0
for the corresponding indexed family whose index type is the subtype
corresponding to that subset. -/
theorem eq_weightedVSub_subset_iff_eq_weightedVSub_subtype {v : V} {s : Set ι} {p : ι → P} :
    (∃ fs : Finset ι, ↑fs ⊆ s ∧ ∃ w : ι → k, ∑ i ∈ fs, w i = 0 ∧
        v = fs.weightedVSub p w) ↔
      ∃ (fs : Finset s) (w : s → k), ∑ i ∈ fs, w i = 0 ∧
        v = fs.weightedVSub (fun i : s => p i) 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}
{v : V}
{s : Set ι}
{p : ι → P}

(∃ fs, ↑fs ⊆ s ∧ ∃ w, ∑ i ∈ fs, w i = 0 ∧ v = (fs.weightedVSub p) w) ↔
  ∃ fs w, ∑ i ∈ fs, w i = 0 ∧ v = (fs.weightedVSub fun i => p ↑i) w


theorem and_symm_left {α : Sort*} (a b : α) (p : Prop) : a = b ∧ p ↔ b = a ∧ p


theorem _root_.Function.Injective.injOn_range (h : Injective (g ∘ f)) : InjOn g (range f)

{α : Type u_1}
{β : Type u_2}
{γ : Type u_3}
{f : α → β}
{g : β → γ}
(h : Function.Injective (g ∘ f))


/-- Intermediate stage of assembling the counit. -/
@[simps]
def counitAuxAux (F : (CostructuredArrow yoneda A)ᵒᵖ ⥤ Type v) (s : CostructuredArrow yoneda A) :
    F.obj (op s) ≅ OverArrows (yonedaCollectionPresheafToA F) s.hom

{A : CategoryTheory.Functor Cᵒᵖ (Type v)}

(F : CategoryTheory.Functor (CategoryTheory.CostructuredArrow CategoryTheory.yoneda A)ᵒᵖ (Type v))

(s : CategoryTheory.CostructuredArrow CategoryTheory.yoneda A)

∀ (a : CategoryTheory.OverPresheafAux.OverArrows (CategoryTheory.OverPresheafAux.yonedaCollectionPresheafToA F) s.hom),
  (CategoryTheory.OverPresheafAux.counitAuxAux F s).inv a = CategoryTheory.OverPresheafAux.counitBackward F s a


theorem sign_apply_eq (r : ℝ) : sign r = -1 ∨ sign r = 0 ∨ sign r = 1


protected theorem isTopologicalBasis : TopologicalSpace.IsTopologicalBasis (lawsonBasis α)

(α : Type u_1)
[Preorder α]
[TopologicalSpace α]
[Topology.IsLawson α]


/-- Interpret a natural isomorphism of the underlying lax monoidal functors as an
isomorphism of the lax braided monoidal functors.
-/
@[simps]
def mkIso {F G : LaxBraidedFunctor C D} (i : F.toLaxMonoidalFunctor ≅ G.toLaxMonoidalFunctor) :
    F ≅ G

{F G : CategoryTheory.LaxBraidedFunctor C D}

(CategoryTheory.LaxBraidedFunctor.mkIso i).inv = i.inv


theorem integrable_withDensity_iff {f : α → ℝ≥0∞} (hf : Measurable f) (hflt : ∀ᵐ x ∂μ, f x < ∞)
    {g : α → ℝ} : Integrable g (μ.withDensity f) ↔ Integrable (fun x => g x * (f x).toReal) μ

{α : Type u_1}
{m : MeasurableSpace α}
{μ : MeasureTheory.Measure α}
{f : α → ℝ≥0∞}
(hf : Measurable f)
(hflt : ∀ᵐ (x : α) ∂μ, f x < ⊤)
{g : α → ℝ}

MeasureTheory.Integrable g (μ.withDensity f) ↔ MeasureTheory.Integrable (fun x => g x * (f x).toReal) μ


theorem extend_def (hf : UniformContinuous f) : pkg.extend f = pkg.denseInducing.extend f

{α : Type u_1}
[UniformSpace α]
(pkg : AbstractCompletion α)
{β : Type u_2}
[UniformSpace β]
{f : α → β}
(hf : UniformContinuous f)


/-- Reflection is its own inverse. -/
@[simp]
theorem reflection_symm (s : AffineSubspace ℝ P) [Nonempty s]
    [HasOrthogonalProjection s.direction] : (reflection s).symm = reflection s

{V : Type u_1}
{P : Type u_2}
[NormedAddCommGroup V]
[InnerProductSpace ℝ V]
[MetricSpace P]
[NormedAddTorsor V P]
(s : AffineSubspace ℝ P)
[Nonempty ↥s]
[HasOrthogonalProjection s.direction]

(EuclideanGeometry.reflection s).symm = EuclideanGeometry.reflection s


theorem _root_.Function.Injective.monic_map_iff (hf : Injective f) {p : R[X]} :
    p.Monic ↔ (p.map f).Monic

{R : Type u}
{S : Type v}
[Semiring R]
[Semiring S]
{f : R →+* S}
(hf : Function.Injective ⇑f)
{p : R[X]}


/-- Flipping a square by switching the top-right and the bottom-left objects. -/
@[simps]
def flip (sq : Square C) : Square C

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


@[simp]
theorem cast_zero {n' : ℕ} [NeZero n] {h : n = n'} : cast h (0 : Fin n) =
    by { haveI : NeZero n' := by {rw [← h]; infer_instance}; exact 0}


/-- The cocones for `CostructuredArrow.proj L Y ⋙ F`, as a functor from `LeftExtension L F`. -/
@[simps]
def coconeAtFunctor (Y : D) :
    LeftExtension L F ⥤ Cocone (CostructuredArrow.proj L Y ⋙ F)

{C : Type u_1}
{D : Type u_2}
{H : Type u_3}
[CategoryTheory.Category.{u_4, u_1} C]
[CategoryTheory.Category.{u_5, u_2} D]
[CategoryTheory.Category.{u_6, u_3} H]
(L : CategoryTheory.Functor C D)
(F : CategoryTheory.Functor C H)
(Y : D)
(E : L.LeftExtension F)

(CategoryTheory.Functor.LeftExtension.coconeAtFunctor L F Y).obj E = E.coconeAt Y


@[simp]
theorem den_smul (c : NumDenSameDeg 𝒜 x) (m : α) : ((m • c).den : A) = c.den

(c : HomogeneousLocalization.NumDenSameDeg 𝒜 x)


lemma Set.Finite.cofinite_inf_principal_diff {s t : Set α} (ht : t.Finite) :
    cofinite ⊓ 𝓟 (s \ t) = cofinite ⊓ 𝓟 s

{α : Type u_2}
{s t : Set α}
(ht : t.Finite)

Filter.cofinite ⊓ 𝓟 (s \ t) = Filter.cofinite ⊓ 𝓟 s


theorem add_mem_sup {S T : Submodule R M} {s t : M} (hs : s ∈ S) (ht : t ∈ T) : s + t ∈ S ⊔ T

{R : Type u_1}
{M : Type u_3}
[Semiring R]
[AddCommMonoid M]
[Module R M]
{S T : Submodule R M}
{s t : M}
(hs : s ∈ S)
(ht : t ∈ T)


{α : Type u}
[PseudoMetricSpace α]
{x : α}
{ε : ℝ}


@[simp]
theorem mk_zero_pow (a : A 0) (n : ℕ) : mk _ (a ^ n) = mk _ a ^ n

{ι : Type u_1}
{A : ι → Type u_2}
[AddMonoid ι]
[GradedMonoid.GMonoid A]
(a : A 0)
(n : ℕ)

GradedMonoid.mk 0 (a ^ n) = GradedMonoid.mk 0 a ^ n


/-- Values of a multiplicative norm of the rationals are determined by the values on the natural
numbers. -/
lemma eq_on_nat_iff_eq : (∀ n : ℕ , f n = g n) ↔ f = g


lemma commute_iff [Fintype n] {A B : Matrix n n α}
    (hA : A.IsHermitian) (hB : B.IsHermitian) : Commute A B ↔ (A * B).IsHermitian

{α : Type u_1}
{n : Type u_4}
[NonUnitalSemiring α]
[StarRing α]
[Fintype n]
{A B : Matrix n n α}
(hA : A.IsHermitian)
(hB : B.IsHermitian)


theorem lookupAll_eq_dlookup (a : α) {l : List (Sigma β)} (h : l.NodupKeys) :
    lookupAll a l = (dlookup a l).toList

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

List.lookupAll a l = (List.dlookup a l).toList


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


/-- A convenient restatement of corner-freeness in terms of an ambient product set. -/
lemma isCornerFree_iff (hAs : A ⊆ s ×ˢ s) :
    IsCornerFree A ↔ ∀ ⦃x₁⦄, x₁ ∈ s → ∀ ⦃y₁⦄, y₁ ∈ s → ∀ ⦃x₂⦄, x₂ ∈ s → ∀ ⦃y₂⦄, y₂ ∈ s →
      IsCorner A x₁ y₁ x₂ y₂ → x₁ = x₂

{G : Type u_1}
[AddCommMonoid G]
{A : Set (G × G)}
{s : Set G}
(hAs : A ⊆ s ×ˢ s)

IsCornerFree A ↔
  ∀ ⦃x₁ : G⦄, x₁ ∈ s → ∀ ⦃y₁ : G⦄, y₁ ∈ s → ∀ ⦃x₂ : G⦄, x₂ ∈ s → ∀ ⦃y₂ : G⦄, y₂ ∈ s → IsCorner A x₁ y₁ x₂ y₂ → x₁ = x₂


protected theorem lipschitz [SemilinearIsometryClass 𝓕 σ₁₂ E E₂] (f : 𝓕) : LipschitzWith 1 f

{R : Type u_1}
{R₂ : Type u_2}
{E : Type u_5}
{E₂ : Type u_6}
{𝓕 : Type u_10}
[Semiring R]
[Semiring R₂]
{σ₁₂ : R →+* R₂}
[SeminormedAddCommGroup E]
[SeminormedAddCommGroup E₂]
[Module R E]
[Module R₂ E₂]
[FunLike 𝓕 E E₂]
[SemilinearIsometryClass 𝓕 σ₁₂ E E₂]
(f : 𝓕)


theorem map_inj {f g : Filter α} {m : α → β} (hm : Injective m) : map m f = map m g ↔ f = g

{α : Type u}
{β : Type v}
{f g : Filter α}
{m : α → β}
(hm : Function.Injective m)


theorem TopologicalSpace.ext_iff_nhds {t t' : TopologicalSpace X} :
    t = t' ↔ ∀ x, @nhds _ t x = @nhds _ t' x

{X : Type u}
{t t' : TopologicalSpace X}


@[reassoc (attr := simp)]
lemma inr_desc :
    inr φ ≫ desc φ α hα = α

HomologicalComplex.homotopyCofiber.inr φ ≫ HomologicalComplex.homotopyCofiber.desc φ α hα = α


/-- The **extreme value theorem**: a continuous function realizes its maximum on a compact set. -/
theorem IsCompact.exists_isMaxOn [ClosedIciTopology α] {s : Set β} (hs : IsCompact s)
    (ne_s : s.Nonempty) {f : β → α} (hf : ContinuousOn f s) : ∃ x ∈ s, IsMaxOn f s x

{α : Type u_2}
{β : Type u_3}
[LinearOrder α]
[TopologicalSpace α]
[TopologicalSpace β]
[ClosedIciTopology α]
{s : Set β}
(hs : IsCompact s)
(ne_s : s.Nonempty)
{f : β → α}
(hf : ContinuousOn f s)


lemma mul_add_mod' (a b c : ℕ) : (a * b + c) % b = c % b


theorem bijOn_cos : BijOn cos (Icc 0 π) (Icc (-1) 1)

Set.BijOn Real.cos (Set.Icc 0 Real.pi) (Set.Icc (-1) 1)


theorem outerMeasure_lt_top_of_isCompact [WeaklyLocallyCompactSpace G]
    {K : Set G} (hK : IsCompact K) :
    μ.outerMeasure K < ∞

{G : Type w}
[TopologicalSpace G]
(μ : MeasureTheory.Content G)
[R1Space G]
[WeaklyLocallyCompactSpace G]
{K : Set G}
(hK : IsCompact K)


theorem setToSimpleFunc_zero' {T : Set α → E →L[ℝ] F'}
    (h_zero : ∀ s, MeasurableSet s → μ s < ∞ → T s = 0) (f : α →ₛ E) (hf : Integrable f μ) :
    setToSimpleFunc T f = 0

(h_zero : ∀ (s : Set α), MeasurableSet s → μ s < ⊤ → T s = 0)

MeasureTheory.SimpleFunc.setToSimpleFunc T f = 0


theorem isClosed_polar (s : Set E) : IsClosed (polar 𝕜 s)

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


@[deprecated map_sum (since := "2024-06-26")]
protected theorem map_sum {ι : Type*} (f : ι → A) (s : Finset ι) :
    φ (∑ x ∈ s, f x) = ∑ x ∈ s, φ (f x)

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


@[to_additive (attr := gcongr)]
lemma mulEnergy_mono (hs : s₁ ⊆ s₂) (ht : t₁ ⊆ t₂) : Eₘ[s₁, t₁] ≤ Eₘ[s₂, t₂]

{α : Type u_1}
[DecidableEq α]
[Mul α]
{s₁ s₂ t₁ t₂ : Finset α}
(hs : s₁ ⊆ s₂)
(ht : t₁ ⊆ t₂)


@[simp] lemma isUnit_transpose : IsUnit Aᵀ ↔ IsUnit A

{n : Type u_2}
{α : Type u_3}
[Fintype n]
[DecidableEq n]
[CommSemiring α]
(A : Matrix n n α)


@[simp]
theorem add_one_of_aleph0_le {c} (h : ℵ₀ ≤ c) : c + 1 = c


@[reassoc (attr := simp)]
theorem biprod.inl_desc {W X Y : C} [HasBinaryBiproduct X Y] (f : X ⟶ W) (g : Y ⟶ W) :
    biprod.inl ≫ biprod.desc f g = f

CategoryTheory.Limits.biprod.inl ≫ CategoryTheory.Limits.biprod.desc f g = f


/-- `(p → q) ∧ p → q` -/
theorem himp_inf_le : (a ⇨ b) ⊓ a ≤ b

{α : Type u_2}
[GeneralizedHeytingAlgebra α]
{a b : α}


theorem subset_sdiff : s ⊆ t \ u ↔ s ⊆ t ∧ Disjoint s u

{α : Type u_1}
[DecidableEq α]
{s t u : Finset α}


@[simp]
theorem WithZero.valued_def {x : RatFunc K} :
    @Valued.v (RatFunc K) _ _ _ _ x = (idealX K).valuation x

(K : Type u_1)
[Field K]
{x : RatFunc K}

Valued.v x = (Polynomial.idealX K).valuation x


/-- If an integer with larger absolute value divides an integer, it is zero. -/
lemma eq_zero_of_dvd_of_natAbs_lt_natAbs (hmn : m ∣ n) (hnm : natAbs n < natAbs m) : n = 0

{m n : ℤ}
(hmn : m ∣ n)
(hnm : n.natAbs < m.natAbs)


@[simp] theorem coe_iInf : (↑(⨅ i, f i) : α) = a ⊓ ⨅ i, (f i : α)

{ι : Sort u_1}
{α : Type u_2}
[CompleteLattice α]
{a : α}
(f : ι → ↑(Set.Iic a))


theorem lift.unique (φ : Abelianization G →* A)
    -- hφ : φ agrees with f on the image of G in Gᵃᵇ
    (hφ : ∀ x : G, φ (Abelianization.of x) = f x)
    {x : Abelianization G} : φ x = lift f x

(hφ : ∀ (x : G), φ (Abelianization.of x) = f x)


@[simp]
theorem kerase_cons_ne {a} {s : Sigma β} {l : List (Sigma β)} (h : a ≠ s.1) :
    kerase a (s :: l) = s :: kerase a l

{α : Type u}
{β : α → Type v}
[DecidableEq α]
{a : α}
{s : Sigma β}
{l : List (Sigma β)}
(h : a ≠ s.fst)

List.kerase a (s :: l) = s :: List.kerase a l


@[simp]
theorem map_neg (f : L₁ →ₗ⁅R⁆ L₂) (x : L₁) : f (-x) = -f x

{R : Type u}
{L₁ : Type v}
{L₂ : Type w}
[CommRing R]
[LieRing L₁]
[LieAlgebra R L₁]
[LieRing L₂]
[LieAlgebra R L₂]
(f : L₁ →ₗ⁅R⁆ L₂)
(x : L₁)


theorem IsOpen.mono (hs : IsOpen[t₂] s) (h : t₁ ≤ t₂) : IsOpen[t₁] s

{α : Type u_1}
{t₁ t₂ : TopologicalSpace α}
{s : Set α}
(hs : IsOpen s)
(h : t₁ ≤ t₂)


theorem mdifferentiableWithinAt_inter' (ht : t ∈ 𝓝[s] x) :
    MDifferentiableWithinAt I I' f (s ∩ t) x ↔ MDifferentiableWithinAt I I' f s x

{𝕜 : Type u_1}
[NontriviallyNormedField 𝕜]
{E : Type u_2}
[NormedAddCommGroup E]
[NormedSpace 𝕜 E]
{H : Type u_3}
[TopologicalSpace H]
{I : ModelWithCorners 𝕜 E H}
{M : Type u_4}
[TopologicalSpace M]
[ChartedSpace H M]
{E' : Type u_5}
[NormedAddCommGroup E']
[NormedSpace 𝕜 E']
{H' : Type u_6}
[TopologicalSpace H']
{I' : ModelWithCorners 𝕜 E' H'}
{M' : Type u_7}
[TopologicalSpace M']
[ChartedSpace H' M']
{f : M → M'}
{x : M}
{s t : Set M}
(ht : t ∈ 𝓝[s] x)


theorem congr_refl_right {α β : Sort*} {f g : α → β} (h : f = g) (a : α) :
    congr h (Eq.refl a) = congr_fun h a

{α : Sort u_1}
{β : Sort u_2}
{f g : α → β}
(h : f = g)
(a : α)


@[simps]
def Triangle.isoMk (A B : Triangle C)
    (iso₁ : A.obj₁ ≅ B.obj₁) (iso₂ : A.obj₂ ≅ B.obj₂) (iso₃ : A.obj₃ ≅ B.obj₃)
    (comm₁ : A.mor₁ ≫ iso₂.hom = iso₁.hom ≫ B.mor₁ := by aesop_cat)
    (comm₂ : A.mor₂ ≫ iso₃.hom = iso₂.hom ≫ B.mor₂ := by aesop_cat)
    (comm₃ : A.mor₃ ≫ iso₁.hom⟦1⟧' = iso₃.hom ≫ B.mor₃ := by aesop_cat) : A ≅ B

(A B : CategoryTheory.Pretriangulated.Triangle C)

(comm₃ : A.mor₃ ≫ (CategoryTheory.shiftFunctor C 1).map iso₁.hom = iso₃.hom ≫ B.mor₃ := by aesop_cat)

(A.isoMk B iso₁ iso₂ iso₃ comm₁ comm₂ comm₃).inv = B.homMk A iso₁.inv iso₂.inv iso₃.inv ⋯ ⋯ ⋯


/-- **Rearrangement Inequality**: Pointwise scalar multiplication of `f` and `g` is maximized when
`f` and `g` monovary together. Stated by permuting the entries of `g`. -/
theorem MonovaryOn.sum_smul_comp_perm_le_sum_smul (hfg : MonovaryOn f g s)
    (hσ : {x | σ x ≠ x} ⊆ s) : ∑ i ∈ s, f i • g (σ i) ≤ ∑ i ∈ s, f i • g i

{ι : Type u_1}
{α : Type u_2}
{β : Type u_3}
[LinearOrderedRing α]
[LinearOrderedAddCommGroup β]
[Module α β]
[OrderedSMul α β]
{s : Finset ι}
{σ : Equiv.Perm ι}
{f : ι → α}
{g : ι → β}
(hfg : MonovaryOn f g ↑s)
(hσ : {x | σ x ≠ x} ⊆ ↑s)


theorem setIntegral_congr₀ (hs : NullMeasurableSet s μ) (h : EqOn f g s) :
    ∫ x in s, f x ∂μ = ∫ x in s, g x ∂μ

(hs : MeasureTheory.NullMeasurableSet s μ)

∫ (x : X) in s, f x ∂μ = ∫ (x : X) in s, g x ∂μ


theorem shiftRight_add (m n : Nat) : ∀ k, m >>> (n + k) = (m >>> n) >>> k


lemma homologyMap_eq :
    homologyMap φ = h₁.homologyIso.hom ≫ γ.φH ≫ h₂.homologyIso.inv

(γ : CategoryTheory.ShortComplex.LeftHomologyMapData φ h₁ h₂)

CategoryTheory.ShortComplex.homologyMap φ =
  CategoryTheory.CategoryStruct.comp h₁.homologyIso.hom (CategoryTheory.CategoryStruct.comp γ.φH h₂.homologyIso.inv)


lemma «forall» {p : Sym α n → Prop} :
    (∀ s : Sym α n, p s) ↔ ∀ (s : Multiset α) (hs : Multiset.card s = n), p (Sym.mk s hs)

{α : Type u_1}
{n : ℕ}
{p : Sym α n → Prop}

(∀ (s : Sym α n), p s) ↔ ∀ (s : Multiset α) (hs : Multiset.card s = n), p (Sym.mk s hs)


theorem image_gaugeRescaleHomeomorph_closure {s t : Set E}
    (hsc : Convex ℝ s) (hs₀ : s ∈ 𝓝 0) (hsb : IsVonNBounded ℝ s)
    (htc : Convex ℝ t) (ht₀ : t ∈ 𝓝 0) (htb : IsVonNBounded ℝ t) :
    gaugeRescaleHomeomorph s t hsc hs₀ hsb htc ht₀ htb '' closure s = closure t

{E : Type u_1}
[AddCommGroup E]
[Module ℝ E]
[TopologicalSpace E]
[T1Space E]
[TopologicalAddGroup E]
[ContinuousSMul ℝ E]
{s t : Set E}
(hsc : Convex ℝ s)
(hs₀ : s ∈ 𝓝 0)
(hsb : Bornology.IsVonNBounded ℝ s)
(htc : Convex ℝ t)
(ht₀ : t ∈ 𝓝 0)
(htb : Bornology.IsVonNBounded ℝ t)

⇑(gaugeRescaleHomeomorph s t hsc hs₀ hsb htc ht₀ htb) '' closure s = closure t


@[simp]
theorem prodSumDistrib_symm_apply_left (a : α × β) :
    (prodSumDistrib α β γ).symm (inl a) = (a.1, inl a.2)

{α : Type u_1}
{β : Type u_2}
{γ : Type u_3}
(a : α × β)

(Equiv.prodSumDistrib α β γ).symm (Sum.inl a) = (a.1, Sum.inl a.2)


theorem Indep.base_of_forall_insert (hB : M.Indep B)
    (hBmax : ∀ e ∈ M.E \ B, ¬ M.Indep (insert e B)) : M.Base B

(hBmax : ∀ e ∈ M.E \ B, ¬M.Indep (insert e B))


@[to_additive]
theorem OrderedCancelCommMonoid.toContravariantClassRight :
    ContravariantClass α α (swap (· * ·)) (· < ·)

{α : Type u_1}
[OrderedCancelAddCommMonoid α]

ContravariantClass α α (Function.swap fun x x_1 => x + x_1) fun x x_1 => x < x_1


theorem Connected.map {G : SimpleGraph V} {H : SimpleGraph V'} (f : G →g H) (hf : Surjective f)
    (hG : G.Connected) : H.Connected

{V : Type u}
{V' : Type v}
{G : SimpleGraph V}
{H : SimpleGraph V'}
(f : G →g H)
(hf : Function.Surjective ⇑f)
(hG : G.Connected)


theorem smoothOn_iff_target :
    SmoothOn I I' f s ↔
      ContinuousOn f s ∧
        ∀ y : M', SmoothOn I 𝓘(𝕜, E') (extChartAt I' y ∘ f) (s ∩ f ⁻¹' (extChartAt I' y).source)

{𝕜 : Type u_1}
[NontriviallyNormedField 𝕜]
{E : Type u_2}
[NormedAddCommGroup E]
[NormedSpace 𝕜 E]
{H : Type u_3}
[TopologicalSpace H]
{I : ModelWithCorners 𝕜 E H}
{M : Type u_4}
[TopologicalSpace M]
[ChartedSpace H M]
[SmoothManifoldWithCorners I M]
{E' : Type u_5}
[NormedAddCommGroup E']
[NormedSpace 𝕜 E']
{H' : Type u_6}
[TopologicalSpace H']
{I' : ModelWithCorners 𝕜 E' H'}
{M' : Type u_7}
[TopologicalSpace M']
[ChartedSpace H' M']
[SmoothManifoldWithCorners I' M']
{f : M → M'}
{s : Set M}

SmoothOn I I' f s ↔
  ContinuousOn f s ∧ ∀ (y : M'), SmoothOn I 𝓘(𝕜, E') (↑(extChartAt I' y) ∘ f) (s ∩ f ⁻¹' (extChartAt I' y).source)


/-- Subtracting the second vector passed to `oangle` from the first vector negates the sign of
the angle. -/
theorem oangle_sign_sub_right_eq_neg (x y : V) :
    (o.oangle x (x - y)).sign = -(o.oangle x y).sign

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


theorem upperCrossingTime_eq_of_bound_le (hab : a < b) (hn : N ≤ n) :
    upperCrossingTime a b f N n ω = N

{Ω : Type u_1}
{a b : ℝ}
{f : ℕ → Ω → ℝ}
{N n : ℕ}
{ω : Ω}
(hab : a < b)
(hn : N ≤ n)

MeasureTheory.upperCrossingTime a b f N n ω = N


@[simp, norm_cast]
theorem coe_add (I J : FractionalIdeal S P) : (↑(I + J) : Submodule R P) = I + J

{R : Type u_1}
[CommRing R]
{S : Submonoid R}
{P : Type u_2}
[CommRing P]
[Algebra R P]
(I J : FractionalIdeal S P)


theorem takeWhile_prefix (p : α → Bool) : l.takeWhile p <+: l

{α : Type u_1}
{l : List α}
(p : α → Bool)


lemma dvd_sub_mod (k : ℕ) : n ∣ k - k % n


@[simp]
theorem one_rpow (x : ℝ) : (1 : ℝ) ^ x = 1


theorem tendsto_leftLim (x : α) : Tendsto f (𝓝[<] x) (𝓝 (leftLim f x))

{α : Type u_1}
{β : Type u_2}
[LinearOrder α]
[ConditionallyCompleteLinearOrder β]
[TopologicalSpace β]
[OrderTopology β]
{f : α → β}
(hf : Antitone f)
[TopologicalSpace α]
[OrderTopology α]
(x : α)

Filter.Tendsto f (𝓝[<] x) (𝓝 (Function.leftLim f x))


@[fun_prop]
lemma continuous_of_dual_apply_continuous {α : Type*} [TopologicalSpace α] {g : α → E →WOT[𝕜] F}
    (h : ∀ x (y : F⋆), Continuous fun a => y (g a x)) : Continuous g

(h : ∀ (x : E) (y : NormedSpace.Dual 𝕜 F), Continuous fun a => y ((g a) x))


@[to_additive]
theorem multipliable_mabs_iff [LinearOrderedCommGroup α] [UniformSpace α] [UniformGroup α]
    [CompleteSpace α] {f : ι → α} : (Multipliable fun x ↦ mabs (f x)) ↔ Multipliable f

{ι : Type u_1}
{α : Type u_3}
[LinearOrderedAddCommGroup α]
[UniformSpace α]
[UniformAddGroup α]
[CompleteSpace α]
{f : ι → α}


theorem uncurry_id_eq_ev (A X : C) [Exponentiable A] : uncurry (𝟙 (A ⟹ X)) = (exp.ev A).app X

CategoryTheory.CartesianClosed.uncurry (CategoryTheory.CategoryStruct.id (A ⟹ X)) = (CategoryTheory.exp.ev A).app X


@[simp, reassoc] lemma comp_f₂ : (f ≫ g).f₂ = f.f₂ ≫ g.f₂

{S₁ S₂ S₃ : CategoryTheory.ShortComplex.SnakeInput C}

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


theorem lt_castPred_succ {a : Fin (n + 1)} (ha : succ a ≠ last (n + 1)) :
    a < (succ a).castPred ha

{n : ℕ}
{a : Fin (n + 1)}
(ha : a.succ ≠ Fin.last (n + 1))


theorem powHalf_succ_rightMoves (n) : (powHalf (n + 1)).RightMoves = PUnit

(SetTheory.PGame.powHalf (n + 1)).RightMoves = PUnit.{u_1 + 1}


theorem cos_pos_iff_abs_toReal_lt_pi_div_two {θ : Angle} : 0 < cos θ ↔ |θ.toReal| < π / 2


{α : Type u_1}
[Preorder α]
{a b : α}
(h : a ⩿ b)


theorem getElem?_set_eq_of_lt (a : α) {n} {l : List α} (h : n < length l) :
    (set l n a)[n]? = some a

{α : Type u_1}
(a : α)
{n : Nat}
{l : List α}
(h : n < l.length)


@[simp]
theorem id_f {P : Karoubi C} : Hom.f (𝟙 P) = P.p

{P : CategoryTheory.Idempotents.Karoubi C}

(CategoryTheory.CategoryStruct.id P).f = P.p


theorem pi_univ_Ioc_update_left {x y : ∀ i, α i} {i₀ : ι} {m : α i₀} (hm : x i₀ ≤ m) :
    (pi univ fun i ↦ Ioc (update x i₀ m i) (y i)) =
      { z | m < z i₀ } ∩ pi univ fun i ↦ Ioc (x i) (y i)

{ι : Type u_1}
{α : ι → Type u_2}
[(i : ι) → Preorder (α i)]
[DecidableEq ι]
{x y : (i : ι) → α i}
{i₀ : ι}
{m : α i₀}
(hm : x i₀ ≤ m)

(Set.univ.pi fun i => Set.Ioc (Function.update x i₀ m i) (y i)) =
  {z | m < z i₀} ∩ Set.univ.pi fun i => Set.Ioc (x i) (y i)


@[simp] theorem USize.val_val_eq_toNat (x : USize) : x.val.val = x.toNat


/-- The functor which sends `S : SnakeInput C` to the auxiliary object `S.P`,
which is `pullback S.L₁.g S.v₀₁.τ₃`. -/
@[simps]
noncomputable def functorP : SnakeInput C ⥤ C

(S : CategoryTheory.ShortComplex.SnakeInput C)

CategoryTheory.ShortComplex.SnakeInput.functorP.obj S = S.P


@[simp]
theorem Fork.ι_postcompose {f' g' : X ⟶ Y} {α : parallelPair f g ⟶ parallelPair f' g'}
    {c : Fork f g} : Fork.ι ((Cones.postcompose α).obj c) = c.ι ≫ α.app _

{α : CategoryTheory.Limits.parallelPair f g ⟶ CategoryTheory.Limits.parallelPair f' g'}

CategoryTheory.Limits.Fork.ι ((CategoryTheory.Limits.Cones.postcompose α).obj c) =
  CategoryTheory.CategoryStruct.comp c.ι (α.app CategoryTheory.Limits.WalkingParallelPair.zero)


/-- Continuity at a point can be read under left composition with a partial homeomorphism if a
neighborhood of the initial point is sent to the source of the partial homeomorphism-/
theorem continuousAt_iff_continuousAt_comp_left {f : Z → X} {x : Z} (h : f ⁻¹' e.source ∈ 𝓝 x) :
    ContinuousAt f x ↔ ContinuousAt (e ∘ f) x

{X : Type u_1}
{Y : Type u_3}
{Z : Type u_5}
[TopologicalSpace X]
[TopologicalSpace Y]
[TopologicalSpace Z]
(e : PartialHomeomorph X Y)
{f : Z → X}
{x : Z}
(h : f ⁻¹' e.source ∈ 𝓝 x)

ContinuousAt f x ↔ ContinuousAt (↑e ∘ f) x


@[to_additive]
theorem mrange_inr : mrange (inr M N) = prod ⊥ ⊤

{M : Type u_1}
{N : Type u_2}
[MulOneClass M]
[MulOneClass N]

MonoidHom.mrange (MonoidHom.inr M N) = ⊥.prod ⊤


@[simp]
-- Porting note: `simp`-normal form of `coe_comp_sup_hom`
theorem coe_comp_sup_hom' (f : BoundedLatticeHom β γ) (g : BoundedLatticeHom α β) :
    ⟨f ∘ g, map_sup (f.comp g)⟩ = (f : SupHom β γ).comp g

{α : Type u_3}
{β : Type u_4}
{γ : Type u_5}
[Lattice α]
[Lattice β]
[Lattice γ]
[BoundedOrder α]
[BoundedOrder β]
[BoundedOrder γ]
(f : BoundedLatticeHom β γ)
(g : BoundedLatticeHom α β)

{ toFun := ⇑f ∘ ⇑g, map_sup' := ⋯ } = { toFun := ⇑f, map_sup' := ⋯ }.comp { toFun := ⇑g, map_sup' := ⋯ }


@[simp]
theorem filter_inter [DecidableEq α] (s t : Multiset α) :
    filter p (s ∩ t) = filter p s ∩ filter p t

{α : Type u_1}
(p : α → Prop)
[DecidablePred p]
[DecidableEq α]
(s t : Multiset α)

Multiset.filter p (s ∩ t) = Multiset.filter p s ∩ Multiset.filter p t


@[simp]
theorem isUpperSet_preimage_ofDual_iff : IsUpperSet (ofDual ⁻¹' s) ↔ IsLowerSet s

IsUpperSet (⇑OrderDual.ofDual ⁻¹' s) ↔ IsLowerSet s


@[simp]
theorem one_opow (a : Ordinal) : (1 : Ordinal) ^ a = 1


@[simp] lemma mk'_zero (d) (h : d ≠ 0) (w) : mk' 0 d h w = 0

(d : ℕ)
(h : d ≠ 0)
(w : (Int.natAbs 0).Coprime d)

{ num := 0, den := d, den_nz := h, reduced := w } = 0


theorem hasDerivAt_abs_rpow (x : ℝ) {p : ℝ} (hp : 1 < p) :
    HasDerivAt (fun x : ℝ ↦ |x| ^ p) (p * |x| ^ (p - 2) * x) x

HasDerivAt (fun x => |x| ^ p) (p * |x| ^ (p - 2) * x) x


/-- The standard triangle `K ⟶ L ⟶ mappingCone φ ⟶ K⟦(1 : ℤ)⟧` in `CochainComplex C ℤ`
attached to a morphism `φ : K ⟶ L`. It involves `φ`, `inr φ : L ⟶ mappingCone φ` and
the morphism induced by the `1`-cocycle `-mappingCone.fst φ`. -/
@[simps! obj₁ obj₂ obj₃ mor₁ mor₂]
noncomputable def triangle : Triangle (CochainComplex C ℤ)

(CochainComplex.mappingCone.triangle φ).mor₁ = φ


theorem inf_splitMany {I : Box ι} (π : Prepartition I) (s : Finset (ι × ℝ)) :
    π ⊓ splitMany I s = π.biUnion fun J => splitMany J s

{ι : Type u_1}
{I : BoxIntegral.Box ι}
(π : BoxIntegral.Prepartition I)
(s : Finset (ι × ℝ))

π ⊓ BoxIntegral.Prepartition.splitMany I s = π.biUnion fun J => BoxIntegral.Prepartition.splitMany J s


theorem RightInverse.iterate {g : α → α} (hg : RightInverse g f) (n : ℕ) :
    RightInverse g^[n] f^[n]

{α : Type u}
{f g : α → α}
(hg : Function.RightInverse g f)
(n : ℕ)


/-- Makes a multiplicative inverse from a bijection which preserves multiplication. -/
@[to_additive (attr := simps)
  "Makes an additive inverse from a bijection which preserves addition."]
def MulHom.inverse [Mul M] [Mul N] (f : M →ₙ* N) (g : N → M)
    (h₁ : Function.LeftInverse g f)
    (h₂ : Function.RightInverse g f) : N →ₙ* M

{M : Type u_6}
{N : Type u_7}
[Add M]
[Add N]
(f : AddHom M N)
(g : N → M)
(h₁ : Function.LeftInverse g ⇑f)
(h₂ : Function.RightInverse g ⇑f)


@[to_additive normal_of_eq_addCosets]
theorem normal_of_eq_cosets (h : ∀ g : α, g • (s : Set α) = op g • s) : s.Normal

(h : ∀ (g : α), g +ᵥ ↑s = AddOpposite.op g +ᵥ ↑s)


@[to_additive (attr := simp)]
theorem mulIndicator_of_mem (h : a ∈ s) (f : α → M) : mulIndicator s f a = f a

{α : Type u_1}
{M : Type u_4}
[One M]
{s : Set α}
{a : α}
(h : a ∈ s)
(f : α → M)


/-- Any `n`-th primitive root of unity is a root of `cyclotomic n R`. -/
theorem _root_.IsPrimitiveRoot.isRoot_cyclotomic (hpos : 0 < n) {μ : R} (h : IsPrimitiveRoot μ n) :
    IsRoot (cyclotomic n R) μ

{R : Type u_1}
[CommRing R]
{n : ℕ}
[IsDomain R]
(hpos : 0 < n)
{μ : R}
(h : IsPrimitiveRoot μ n)


@[simp]
theorem leftUnitor_inv_hom (X : Mon_ C) : (λ_ X).inv.hom = (λ_ X.X).inv

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


theorem Perm.bagInter {l₁ l₂ t₁ t₂ : List α} (hl : l₁ ~ l₂) (ht : t₁ ~ t₂) :
    l₁.bagInter t₁ ~ l₂.bagInter t₂

{α : Type u_1}
[DecidableEq α]
{l₁ l₂ t₁ t₂ : List α}
(hl : l₁.Perm l₂)
(ht : t₁.Perm t₂)


@[to_additive]
theorem smulAntidiagonal_mono_left {a : P} {hs : s.IsPWO} {ht : t.IsPWO} (h : u ⊆ s) :
    SMulAntidiagonal hu ht a ⊆ SMulAntidiagonal hs ht a

{G : Type u_1}
{P : Type u_2}
[PartialOrder G]
[PartialOrder P]
[VAdd G P]
[IsOrderedCancelVAdd G P]
{s : Set G}
{t : Set P}
{u : Set G}
{hu : u.IsPWO}
{a : P}
{hs : s.IsPWO}
{ht : t.IsPWO}
(h : u ⊆ s)

Finset.VAddAntidiagonal hu ht a ⊆ Finset.VAddAntidiagonal hs ht a


/-- The open sets containing `x` are a basis for the neighborhood filter. See `nhds_basis_opens'`
for a variant using open neighborhoods instead. -/
theorem nhds_basis_opens (x : X) :
    (𝓝 x).HasBasis (fun s : Set X => x ∈ s ∧ IsOpen s) fun s => s

{X : Type u}
[TopologicalSpace X]
(x : X)

(𝓝 x).HasBasis (fun s => x ∈ s ∧ IsOpen s) fun s => s


theorem IsBigO.eq_zero_of_norm_pow_within {f : E'' → F''} {s : Set E''} {x₀ : E''} {n : ℕ}
    (h : f =O[𝓝[s] x₀] fun x => ‖x - x₀‖ ^ n) (hx₀ : x₀ ∈ s) (hn : n ≠ 0) : f x₀ = 0


@[simp] protected theorem USize.sizeOf (a : USize) : sizeOf a = a.toNat + 2


private theorem mul_nonneg_of_pos_of_nonneg [OrderedSemiring α] {a b : α}
    (ha : 0 < a) (hb : 0 ≤ b) : 0 ≤ a * b

{α : Type u_1}
[OrderedSemiring α]
{a b : α}
(ha : 0 < a)
(hb : 0 ≤ b)


@[to_additive (attr := fun_prop)]
theorem ContinuousOn.const_smul (hg : ContinuousOn g s) (c : M) :
    ContinuousOn (fun x => c • g x) s

{M : Type u_1}
{α : Type u_2}
{β : Type u_3}
[TopologicalSpace α]
[SMul M α]
[ContinuousConstSMul M α]
[TopologicalSpace β]
{g : β → α}
{s : Set β}
(hg : ContinuousOn g s)
(c : M)


theorem ofScientific_def : Rat.ofScientific m s e =
    if s then mkRat m (10 ^ e) else (m * 10 ^ e : Nat)

Rat.ofScientific m s e = if s = true then mkRat (↑m) (10 ^ e) else ↑(m * 10 ^ e)


@[to_additive]
theorem ContMDiffWithinAt.div_const (hf : ContMDiffWithinAt I' I n f s x) :
    ContMDiffWithinAt I' I n (fun x ↦ f x / c) s x

{𝕜 : Type u_1}
[NontriviallyNormedField 𝕜]
{H : Type u_2}
[TopologicalSpace H]
{E : Type u_3}
[NormedAddCommGroup E]
[NormedSpace 𝕜 E]
{I : ModelWithCorners 𝕜 E H}
{G : Type u_4}
[SubNegMonoid G]
[TopologicalSpace G]
[ChartedSpace H G]
[SmoothAdd I G]
{E' : Type u_5}
[NormedAddCommGroup E']
[NormedSpace 𝕜 E']
{H' : Type u_6}
[TopologicalSpace H']
{I' : ModelWithCorners 𝕜 E' H'}
{M : Type u_7}
[TopologicalSpace M]
[ChartedSpace H' M]
{f : M → G}
{s : Set M}
{x : M}
{n : ℕ∞}
(c : G)
(hf : ContMDiffWithinAt I' I n f s x)

ContMDiffWithinAt I' I n (fun x => f x - c) s x


@[simp]
theorem lift.tprod (f : Π i, s i) : lift φ (tprod R f) = φ f

{ι : Type u_1}
{R : Type u_4}
[CommSemiring R]
{s : ι → Type u_7}
[(i : ι) → AddCommMonoid (s i)]
[(i : ι) → Module R (s i)]
{E : Type u_9}
[AddCommMonoid E]
[Module R E]
{φ : MultilinearMap R s E}
(f : (i : ι) → s i)

(PiTensorProduct.lift φ) ((PiTensorProduct.tprod R) f) = φ f


/-- A finite dimensional space is nontrivial if it has positive `finrank`. -/
theorem FiniteDimensional.nontrivial_of_finrank_pos (h : 0 < finrank R M) : Nontrivial M

{R : Type u}
{M : Type v}
[Ring R]
[AddCommGroup M]
[Module R M]
[Nontrivial R]
[NoZeroSMulDivisors R M]
(h : 0 < FiniteDimensional.finrank R M)


theorem normal_iff : Normal F K ↔ ∀ x : K, IsIntegral F x ∧ Splits (algebraMap F K) (minpoly F x)

{F : Type u_1}
{K : Type u_2}
[Field F]
[Field K]
[Algebra F K]

Normal F K ↔ ∀ (x : K), IsIntegral F x ∧ Polynomial.Splits (algebraMap F K) (minpoly F x)


lemma ringHomComp_ne_one_iff {f : R' →+* R''} (hf : Function.Injective f) {χ : MulChar R R'} :
    χ.ringHomComp f ≠ 1 ↔ χ ≠ 1

{R : Type u_1}
[CommMonoid R]
{R' : Type u_2}
[CommRing R']
{R'' : Type u_3}
[CommRing R'']
{f : R' →+* R''}
(hf : Function.Injective ⇑f)
{χ : MulChar R R'}


theorem Dart.ext_iff (d₁ d₂ : G.Dart) : d₁ = d₂ ↔ d₁.toProd = d₂.toProd

{V : Type u_1}
{G : SimpleGraph V}
(d₁ d₂ : G.Dart)


/-- Let `X` be a topological space, `𝔖` a family of compact subsets of `X` and
`α` a uniform space. An equicontinuous subset of `X → α` is closed in the topology of uniform
convergence on all `K ∈ 𝔖` iff it is closed in the topology of pointwise convergence on `⋃₀ 𝔖`. -/
theorem EquicontinuousOn.isClosed_range_pi_of_uniformOnFun'
    {𝔖 : Set (Set X)} (𝔖_compact : ∀ K ∈ 𝔖, IsCompact K)
    (F_eqcont : ∀ K ∈ 𝔖, EquicontinuousOn F K)
    (H : IsClosed (range <| UniformOnFun.ofFun 𝔖 ∘ F)) :
    IsClosed (range <| (⋃₀ 𝔖).restrict ∘ F)

(H : IsClosed (Set.range (⇑(UniformOnFun.ofFun 𝔖) ∘ F)))

IsClosed (Set.range ((⋃₀ 𝔖).restrict ∘ F))


lemma le_flip_dualSubmodule {N₁ N₂ : Submodule R M} :
    N₁ ≤ B.flip.dualSubmodule N₂ ↔ N₂ ≤ B.dualSubmodule N₁

{R : Type u_1}
{S : Type u_3}
{M : Type u_2}
[CommRing R]
[Field S]
[AddCommGroup M]
[Algebra R S]
[Module R M]
[Module S M]
[IsScalarTower R S M]
(B : LinearMap.BilinForm S M)
{N₁ N₂ : Submodule R M}


@[simp]
theorem toInvSubmonoid_mul (m : M) : (toInvSubmonoid M S m : S) * algebraMap R S m = 1

{R : Type u_1}
[CommRing R]
(M : Submonoid R)
(S : Type u_2)
[CommRing S]
[Algebra R S]
[IsLocalization M S]
(m : ↥M)

↑((IsLocalization.toInvSubmonoid M S) m) * (algebraMap R S) ↑m = 1


theorem inter_extremePoints_subset_extremePoints_of_subset (hBA : B ⊆ A) :
    B ∩ A.extremePoints 𝕜 ⊆ B.extremePoints 𝕜

{𝕜 : Type u_1}
{E : Type u_2}
[OrderedSemiring 𝕜]
[AddCommMonoid E]
[SMul 𝕜 E]
{A B : Set E}
(hBA : B ⊆ A)

B ∩ Set.extremePoints 𝕜 A ⊆ Set.extremePoints 𝕜 B


/-- If the domain is a ring `R`, then `χ (ringChar R) = 0`. -/
theorem map_ringChar {R : Type*} [CommRing R] [Nontrivial R] (χ : MulChar R R') :
    χ (ringChar R) = 0

{R' : Type u_2}
[CommMonoidWithZero R']
{R : Type u_3}
[CommRing R]
[Nontrivial R]
(χ : MulChar R R')


/-- Given a continuous `R`-alternating map `f` taking values in `R`, `f.smulRight z` is the
continuous alternating map sending `m` to `f m • z`. -/
@[simps! toContinuousMultilinearMap apply]
def smulRight : M [⋀^ι]→L[R] N

{R : Type u_1}
{M : Type u_3}
{N : Type u_4}
{ι : Type u_5}
[CommSemiring R]
[AddCommMonoid M]
[AddCommMonoid N]
[Module R M]
[Module R N]
[TopologicalSpace R]
[TopologicalSpace M]
[TopologicalSpace N]
[ContinuousSMul R N]
(f : M [⋀^ι]→L[R] R)
(z : N)

∀ (a : (i : ι) → (fun x => M) i), (f.smulRight z) a = f a • z


@[simp]
theorem eval_apply (v : M) (a : Dual R M) : eval R M v a = a v

(R : Type uR)
(M : Type uM)
[CommSemiring R]
[AddCommMonoid M]
[Module R M]
(v : M)
(a : Module.Dual R M)


theorem Continuous.integrableOn_uIcc [LinearOrder X] [CompactIccSpace X] [T2Space X]
    (hf : Continuous f) : IntegrableOn f [[a, b]] μ


@[mono]
theorem generateFrom_anti {α} {g₁ g₂ : Set (Set α)} (h : g₁ ⊆ g₂) :
    generateFrom g₂ ≤ generateFrom g₁

{α : Type u_1}
{g₁ g₂ : Set (Set α)}
(h : g₁ ⊆ g₂)

TopologicalSpace.generateFrom g₂ ≤ TopologicalSpace.generateFrom g₁


/-- Right unitor as a natural isomorphism. -/
@[simps!]
def rightUnitorNatIso (a b : B) : (postcomposing a _ _).obj (𝟙 b) ≅ 𝟭 (a ⟶ b)

{B : Type u}
[CategoryTheory.Bicategory B]
(a b : B)
(X : a ⟶ b)

(CategoryTheory.Bicategory.rightUnitorNatIso a b).hom.app X = (CategoryTheory.Bicategory.rightUnitor X).hom


@[simp]
theorem mk_ne_zero (α : Type u) [Nonempty α] : #α ≠ 0


@[simp]
theorem homTensorHomMap_apply (f : M →ₗ[R] P) (g : N →ₗ[R] Q) :
    homTensorHomMap R M N P Q (f ⊗ₜ g) = map f g

{R : Type u_1}
[CommSemiring R]
{M : Type u_4}
{N : Type u_5}
{P : Type u_6}
{Q : Type u_7}
[AddCommMonoid M]
[AddCommMonoid N]
[AddCommMonoid P]
[AddCommMonoid Q]
[Module R M]
[Module R N]
[Module R P]
[Module R Q]
(f : M →ₗ[R] P)
(g : N →ₗ[R] Q)

(TensorProduct.homTensorHomMap R M N P Q) (f ⊗ₜ[R] g) = TensorProduct.map f g


/-- `s`, coerced to a type, is a subsingleton type if and only if `s` is a subsingleton set. -/
@[simp, norm_cast]
theorem subsingleton_coe (s : Set α) : Subsingleton s ↔ s.Subsingleton


theorem le_trailingDegree_C_mul_X_pow (n : ℕ) (a : R) :
    (n : ℕ∞) ≤ trailingDegree (C a * X ^ n)

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

↑n ≤ (Polynomial.C a * Polynomial.X ^ n).trailingDegree


theorem add_apply (g₁ g₂ : PolynomialModule R M) (a : ℕ) : (g₁ + g₂) a = g₁ a + g₂ a

(R : Type u_1)
{M : Type u_2}
[CommRing R]
[AddCommGroup M]
[Module R M]
(g₁ g₂ : PolynomialModule R M)
(a : ℕ)


theorem isCompact_iff_isCompact_univ : IsCompact s ↔ IsCompact (univ : Set s)

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


@[simp]
lemma coeffs_zero : coeffs (0 : MvPolynomial σ R) = ∅

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


/-- The fundamental property of the operator norm of a continuous multilinear map:
`‖f m‖` is bounded by `‖f‖` times the product of the `‖m i‖`, `nnnorm` version. -/
theorem le_opNNNorm : ‖f m‖₊ ≤ ‖f‖₊ * ∏ i, ‖m i‖₊

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

‖f m‖₊ ≤ ‖f‖₊ * ∏ i : ι, ‖m i‖₊


@[to_additive (attr := simp)]
theorem mulSupport_subset_iff {f : α → M} {s : Set α} : mulSupport f ⊆ s ↔ ∀ x, f x ≠ 1 → x ∈ s

{α : Type u_1}
{M : Type u_5}
[One M]
{f : α → M}
{s : Set α}

Function.mulSupport f ⊆ s ↔ ∀ (x : α), f x ≠ 1 → x ∈ s


theorem MeasureTheory.IntegrableOn.intervalIntegrable (hf : IntegrableOn f [[a, b]] μ) :
    IntervalIntegrable f μ a b

(hf : MeasureTheory.IntegrableOn f [[a, b]] μ)


@[simp]
theorem mul_apply (e₁ e₂ : MulAut M) (m : M) : (e₁ * e₂) m = e₁ (e₂ m)

(M : Type u_2)
[Mul M]
(e₁ e₂ : MulAut M)
(m : M)


@[simp] theorem Function.const_apply {y : β} {x : α} : const α y x = y

{β : Sort u_1}
{α : Sort u_2}
{y : β}
{x : α}


theorem nil_infix (l : List α) : [] <:+: l


@[simp]
lemma natTransEquiv_comp_symm {F F' F'' : C ⥤ D} {G G' G'' : D ⥤ C}
    (adj1 : F ⊣ G) (adj2 : F' ⊣ G') (adj3 : F'' ⊣ G'') (f : F' ⟶ F) (g : F'' ⟶ F') :
    (natTransEquiv adj1 adj2).symm f ≫ (natTransEquiv adj2 adj3).symm g =
      (natTransEquiv adj1 adj3).symm (g ≫ f)

{C : Type u_1}
{D : Type u_2}
[CategoryTheory.Category.{u_3, u_1} C]
[CategoryTheory.Category.{u_4, u_2} D]
{F F' F'' : C ⥤ D}
{G G' G'' : D ⥤ C}
(adj1 : F ⊣ G)
(adj2 : F' ⊣ G')
(adj3 : F'' ⊣ G'')
(f : F' ⟶ F)
(g : F'' ⟶ F')

(adj1.natTransEquiv adj2).symm f ≫ (adj2.natTransEquiv adj3).symm g = (adj1.natTransEquiv adj3).symm (g ≫ f)


/-- **Maximum modulus principle** on a connected set. Let `U` be a (pre)connected open set in a
complex normed space.  Let `f : E → F` be a function that is complex differentiable on `U`. Suppose
that `‖f x‖` takes its maximum value on `U` at `c ∈ U`. Then `f x = f c` for all `x ∈ U`.

TODO: change assumption from `IsMaxOn` to `IsLocalMax`. -/
theorem eqOn_of_isPreconnected_of_isMaxOn_norm {f : E → F} {U : Set E} {c : E}
    (hc : IsPreconnected U) (ho : IsOpen U) (hd : DifferentiableOn ℂ f U) (hcU : c ∈ U)
    (hm : IsMaxOn (norm ∘ f) U c) : EqOn f (const E (f c)) U

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


theorem forall_mem_range {p : α → Prop} : (∀ a ∈ range f, p a) ↔ ∀ i, p (f i)

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

(∀ a ∈ Set.range f, p a) ↔ ∀ (i : ι), p (f i)


theorem sym_bijective : Bijective (sym : α → αˢʸᵐ)


theorem prod_preimage_left {f : γ → α} :
    (f ⁻¹' s) ×ˢ t = (fun p : γ × β => (f p.1, p.2)) ⁻¹' s ×ˢ t

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

(f ⁻¹' s) ×ˢ t = (fun p => (f p.1, p.2)) ⁻¹' s ×ˢ t


protected theorem congr_arg (f : P1 →ᵃ[k] P2) {x y : P1} (h : x = y) : f x = f y

{k : Type u_1}
{V1 : Type u_2}
{P1 : Type u_3}
{V2 : Type u_4}
{P2 : Type u_5}
[Ring k]
[AddCommGroup V1]
[Module k V1]
[AffineSpace V1 P1]
[AddCommGroup V2]
[Module k V2]
[AffineSpace V2 P2]
(f : P1 →ᵃ[k] P2)
{x y : P1}
(h : x = y)


/-- The functor `(Square C)ᵒᵖ ⥤ Square Cᵒᵖ`. -/
@[simps]
def opFunctor : (Square C)ᵒᵖ ⥤ Square Cᵒᵖ

{C : Type u}
[CategoryTheory.Category.{v, u} C]

∀ {X Y : (CategoryTheory.Square C)ᵒᵖ} (φ : X ⟶ Y), (CategoryTheory.Square.opFunctor.map φ).τ₃ = φ.unop.τ₃.op


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

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

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


theorem IsPurelyInseparable.minpoly_eq_X_pow_sub_C (q : ℕ) [ExpChar F q] [IsPurelyInseparable F E]
    (x : E) : ∃ (n : ℕ) (y : F), minpoly F x = X ^ q ^ n - C y

(F : Type u)
{E : Type v}
[Field F]
[Field E]
[Algebra F E]
(q : ℕ)
[ExpChar F q]
[IsPurelyInseparable F E]
(x : E)

∃ n y, minpoly F x = Polynomial.X ^ q ^ n - Polynomial.C y


/-- The upper and lower central series of `L` are orthogonal wrt the trace form of any Lie module
`M`. -/
lemma traceForm_eq_zero_if_mem_lcs_of_mem_ucs {x y : L} (k : ℕ)
    (hx : x ∈ (⊤ : LieIdeal R L).lcs L k) (hy : y ∈ (⊥ : LieIdeal R L).ucs k) :
    traceForm R L M x y = 0

(R : Type u_1)
(L : Type u_3)
(M : Type u_4)
[CommRing R]
[LieRing L]
[LieAlgebra R L]
[AddCommGroup M]
[Module R M]
[LieRingModule L M]
[LieModule R L M]
{x y : L}
(k : ℕ)
(hx : x ∈ ⊤.lcs L k)
(hy : y ∈ LieSubmodule.ucs k ⊥)


theorem vsub_subset_iff : s -ᵥ t ⊆ u ↔ ∀ x ∈ s, ∀ y ∈ t, x -ᵥ y ∈ u

{α : Type u_2}
{β : Type u_3}
[VSub α β]
[DecidableEq α]
{s t : Finset β}
{u : Finset α}


@[to_additive (attr := simp 1100)]
theorem closedBall_mul_singleton : closedBall x δ * {y} = closedBall (x * y) δ

{E : Type u_1}
[SeminormedCommGroup E]
(δ : ℝ)
(x y : E)

Metric.closedBall x δ * {y} = Metric.closedBall (x * y) δ


@[simp]
theorem normalizeObj_tensor (X Y : F C) (n : NormalMonoidalObject C) :
    normalizeObj (X ⊗ Y) n = normalizeObj Y (normalizeObj X n)

(X Y : CategoryTheory.FreeMonoidalCategory C)

(n : CategoryTheory.FreeMonoidalCategory.NormalMonoidalObject C)

(CategoryTheory.MonoidalCategory.tensorObj X Y).normalizeObj n = Y.normalizeObj (X.normalizeObj n)


@[bv_toNat] theorem toNat_zeroExtend (i : Nat) (x : BitVec n) :
    BitVec.toNat (zeroExtend i x) = x.toNat % 2^i

(BitVec.zeroExtend i x).toNat = x.toNat % 2 ^ i


theorem projIcc_of_mem (hx : x ∈ Icc a b) : projIcc a b h x = ⟨x, hx⟩

{α : Type u_1}
[LinearOrder α]
{a b : α}
(h : a ≤ b)
{x : α}
(hx : x ∈ Set.Icc a b)


@[simp]
theorem embDomain_coeff {f : Γ ↪o Γ'} {x : HahnSeries Γ R} {a : Γ} :
    (embDomain f x).coeff (f a) = x.coeff a

{Γ : Type u_1}
{R : Type u_2}
[PartialOrder Γ]
[Zero R]
{Γ' : Type u_3}
[PartialOrder Γ']
{f : Γ ↪o Γ'}
{x : HahnSeries Γ R}
{a : Γ}

(HahnSeries.embDomain f x).coeff (f a) = x.coeff a


theorem MonotoneOn.reflect_lt (hf : MonotoneOn f s) {a b : α} (ha : a ∈ s) (hb : b ∈ s)
    (h : f a < f b) : a < b

{α : Type u}
{β : Type v}
[LinearOrder α]
[Preorder β]
{f : α → β}
{s : Set α}
(hf : MonotoneOn f s)
{a b : α}
(ha : a ∈ s)
(hb : b ∈ s)
(h : f a < f b)


lemma toMvPolynomial_baseChange (f : M₁ →ₗ[R] M₂) (i : ι₂) (A : Type*) [CommRing A] [Algebra R A] :
    (f.baseChange A).toMvPolynomial (basis A b₁) (basis A b₂) i =
      MvPolynomial.map (algebraMap R A) (f.toMvPolynomial b₁ b₂ i)

{R : Type u_1}
{M₁ : Type u_2}
{M₂ : Type u_3}
{ι₁ : Type u_4}
{ι₂ : Type u_5}
[CommRing R]
[AddCommGroup M₁]
[AddCommGroup M₂]
[Module R M₁]
[Module R M₂]
[Fintype ι₁]
[Finite ι₂]
[DecidableEq ι₁]
(b₁ : Basis ι₁ R M₁)
(b₂ : Basis ι₂ R M₂)
(f : M₁ →ₗ[R] M₂)
(i : ι₂)
(A : Type u_6)
[CommRing A]
[Algebra R A]

LinearMap.toMvPolynomial (Algebra.TensorProduct.basis A b₁) (Algebra.TensorProduct.basis A b₂)
    (LinearMap.baseChange A f) i =
  (MvPolynomial.map (algebraMap R A)) (LinearMap.toMvPolynomial b₁ b₂ f i)


theorem norm_expSeries_summable' (x : 𝔸) : Summable fun n => ‖(n !⁻¹ : 𝕂) • x ^ n‖

{𝕂 : Type u_1}
{𝔸 : Type u_2}
[RCLike 𝕂]
[NormedRing 𝔸]
[NormedAlgebra 𝕂 𝔸]
(x : 𝔸)

Summable fun n => ‖(↑n.factorial)⁻¹ • x ^ n‖


@[simp]
theorem foldl_one (f : M →ₗ[R] N →ₗ[R] N) (hf) (n : N) : foldl Q f hf n 1 = n

((CliffordAlgebra.foldl Q f hf) n) 1 = n


/-- We can clear the denominators of a `Finset`-indexed family of fractions. -/
theorem exist_integer_multiples {ι : Type*} (s : Finset ι) (f : ι → S) :
    ∃ b : M, ∀ i ∈ s, IsLocalization.IsInteger R ((b : R) • f i)

{R : Type u_1}
[CommSemiring R]
(M : Submonoid R)
{S : Type u_2}
[CommSemiring S]
[Algebra R S]
[IsLocalization M S]
{ι : Type u_4}
(s : Finset ι)
(f : ι → S)

∃ b, ∀ i ∈ s, IsLocalization.IsInteger R (↑b • f i)


theorem opow_isNormal {a : Ordinal} (h : 1 < a) : IsNormal (a ^ ·)


@[simp]
theorem top_sub_coe {a : α} : (⊤ : WithTop α) - a = ⊤


/-- **Uniqueness of left-invariant measures**:
Given two left-invariant measures which are finite on compacts, they coincide in the following
sense: they give the same value to sets with compact closure, up to the multiplicative
constant `haarScalarFactor μ' μ`. -/
@[to_additive measure_isAddInvariant_eq_smul_of_isCompact_closure
"**Uniqueness of left-invariant measures**:
Given two left-invariant measures which are finite on compacts, they coincide in the following
sense: they give the same value to sets with compact closure, up to the multiplicative
constant `addHaarScalarFactor μ' μ`. "]
theorem measure_isMulInvariant_eq_smul_of_isCompact_closure [LocallyCompactSpace G]
    (μ' μ : Measure G) [IsHaarMeasure μ] [IsFiniteMeasureOnCompacts μ'] [IsMulLeftInvariant μ']
    {s : Set G} (h's : IsCompact (closure s)) :
    μ' s = haarScalarFactor μ' μ • μ s


theorem Pairwise.iff {S : α → α → Prop} (H : ∀ a b, R a b ↔ S a b) {l : List α} :
    Pairwise R l ↔ Pairwise S l

{α : Type u_1}
{R S : α → α → Prop}
(H : ∀ (a b : α), R a b ↔ S a b)
{l : List α}


/-- Asserts that `¬⟦f⟧_v` implies `p`. -/
structure Fmla.reify (v : Valuation) (f : Fmla) (p : Prop) : Prop where
  prop : ¬ v.satisfies_fmla f → p

{v : Sat.Valuation}
{f : Sat.Fmla}
{p : Prop}
(self : Sat.Fmla.reify v f p)


/-- The inclusion of the base ring in a topological algebra as a continuous linear map. -/
@[simps]
def algebraMapCLM : R →L[R] A

(R : Type u_1)
(A : Type u)
[CommSemiring R]
[Semiring A]
[Algebra R A]
[TopologicalSpace R]
[TopologicalSpace A]
[ContinuousSMul R A]
(a : R)

(algebraMapCLM R A) a = (algebraMap R A) a


/-- Suppose lines from two vertices of a triangle to interior points of the opposite side meet at
`p`. Then `p` lies in the interior of the first (and by symmetry the other) segment from a
vertex to the point on the opposite side. -/
theorem sbtw_of_sbtw_of_sbtw_of_mem_affineSpan_pair [NoZeroSMulDivisors R V]
    {t : Affine.Triangle R P} {i₁ i₂ i₃ : Fin 3} (h₁₂ : i₁ ≠ i₂) {p₁ p₂ p : P}
    (h₁ : Sbtw R (t.points i₂) p₁ (t.points i₃)) (h₂ : Sbtw R (t.points i₁) p₂ (t.points i₃))
    (h₁' : p ∈ line[R, t.points i₁, p₁]) (h₂' : p ∈ line[R, t.points i₂, p₂]) :
    Sbtw R (t.points i₁) p p₁

(h₁' : p ∈ affineSpan R {t.points i₁, p₁})

(h₂' : p ∈ affineSpan R {t.points i₂, p₂})


/-- `X ^ n - a` is monic. -/
theorem monic_X_pow_sub_C {R : Type u} [Ring R] (a : R) {n : ℕ} (h : n ≠ 0) :
    (X ^ n - C a).Monic

(Polynomial.X ^ n - Polynomial.C a).Monic


theorem M.bisim₀ {α : TypeVec n} (R : P.M α → P.M α → Prop) (h₀ : Equivalence R)
    (h : ∀ x y, R x y → (id ::: Quot.mk R) <$$> M.dest _ x = (id ::: Quot.mk R) <$$> M.dest _ y)
    (x y) (r : R x y) : x = y

(h :
  ∀ (x y : P.M α),
    R x y →
      (TypeVec.id ::: Quot.mk R) <$$> MvPFunctor.M.dest P x = (TypeVec.id ::: Quot.mk R) <$$> MvPFunctor.M.dest P y)


@[to_additive (attr := ext)]
lemma ext {X Y : Grp} {f g : X ⟶ Y} (w : ∀ x : X, f x = g x) : f = g

{X Y : AddGrp}
{f g : X ⟶ Y}
(w : ∀ (x : ↑X), f x = g x)


@[to_additive]
theorem isOpenMap_inv : IsOpenMap (Inv.inv : G → G)

(G : Type w)
[TopologicalSpace G]
[InvolutiveNeg G]
[ContinuousNeg G]


theorem subset_union_compl_iff_inter_subset {s t u : Set α} : s ⊆ t ∪ uᶜ ↔ s ∩ u ⊆ t

s ⊆ t ∪ uᶜ ↔ s ∩ u ⊆ t


/-- Let `f : ℝ → ℝ` be a differentiable function. If `f'` is negative, then
`f` is a strictly antitone function.
Note that we don't require differentiability explicitly as it already implied by the derivative
being strictly negative. -/
theorem strictAnti_of_deriv_neg {f : ℝ → ℝ} (hf' : ∀ x, deriv f x < 0) : StrictAnti f

{f : ℝ → ℝ}
(hf' : ∀ (x : ℝ), deriv f x < 0)


{𝕜 : Type u_1}
[NontriviallyNormedField 𝕜]
{E : Type u_2}
[NormedAddCommGroup E]
[NormedSpace 𝕜 E]
{H : Type u_3}
[TopologicalSpace H]
{I : ModelWithCorners 𝕜 E H}
{G : Type u_4}
[TopologicalSpace G]
[ChartedSpace H G]
[Monoid G]
[SmoothMul I G]
(X : LeftInvariantDerivation I G)


theorem pow_smul_le_pow_smul (i j k : ℕ) : I ^ (i + k) • F.N j ≤ I ^ k • F.N (i + j)

{R M : Type u}
[CommRing R]
[AddCommGroup M]
[Module R M]
{I : Ideal R}
(F : I.Filtration M)
(i j k : ℕ)


theorem merge' {f g} (hf : Nat.Partrec f) (hg : Nat.Partrec g) :
    ∃ h, Nat.Partrec h ∧
      ∀ a, (∀ x ∈ h a, x ∈ f a ∨ x ∈ g a) ∧ ((h a).Dom ↔ (f a).Dom ∨ (g a).Dom)

{f g : ℕ →. ℕ}
(hf : Nat.Partrec f)
(hg : Nat.Partrec g)

∃ h, Nat.Partrec h ∧ ∀ (a : ℕ), (∀ x ∈ h a, x ∈ f a ∨ x ∈ g a) ∧ ((h a).Dom ↔ (f a).Dom ∨ (g a).Dom)


theorem map_smul_of_tower {R'} [SMul R' A] [SMul R' B] [LinearMap.CompatibleSMul A B R' R] (r : R')
    (x : A) : φ (r • x) = r • φ x

{R : Type u_1}
{A : Type u_2}
{B : Type u_3}
[CommSemiring R]
[Semiring A]
[Algebra R A]
[Semiring B]
[Algebra R B]
[CoalgebraStruct R A]
[CoalgebraStruct R B]
(φ : A →ₐc[R] B)
{R' : Type u_6}
[SMul R' A]
[SMul R' B]
[LinearMap.CompatibleSMul A B R' R]
(r : R')
(x : A)


/-- The weighted sum is unaffected by adding the base point, whether
or not present, to the set of points. -/
@[simp (high)]
theorem weightedVSubOfPoint_insert [DecidableEq ι] (w : ι → k) (p : ι → P) (i : ι) :
    (insert i s).weightedVSubOfPoint p (p i) w = s.weightedVSubOfPoint p (p i) 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 ι)
[DecidableEq ι]
(w : ι → k)
(p : ι → P)
(i : ι)

((insert i s).weightedVSubOfPoint p (p i)) w = (s.weightedVSubOfPoint p (p i)) w


/-- Main theorem about strong FE pairs: if `(f, g)` are a strong FE pair, then the Mellin
transforms of `f` and `g` are related by `s ↦ k - s`.

This is proved by making a substitution `t ↦ t⁻¹` in the Mellin transform integral. -/
theorem functional_equation (s : ℂ) :
    P.Λ (P.k - s) = P.ε • P.symm.Λ s

{E : Type u_1}
[NormedAddCommGroup E]
[NormedSpace ℂ E]
(P : StrongFEPair E)
(s : ℂ)


theorem IsMaxOn.isLocalMax (hf : IsMaxOn f s a) (hs : s ∈ 𝓝 a) : IsLocalMax f a

{α : Type u}
{β : Type v}
[TopologicalSpace α]
[Preorder β]
{f : α → β}
{s : Set α}
{a : α}
(hf : IsMaxOn f s a)
(hs : s ∈ 𝓝 a)


theorem isLeftAdjoint_TFAE (f : a ⟶ b) :
    List.TFAE [
      IsLeftAdjoint f,
      HasAbsLeftKanExtension f (𝟙 a),
      ∃ _ : HasLeftKanExtension f (𝟙 a), Lan.CommuteWith f (𝟙 a) f]

{B : Type u}
[CategoryTheory.Bicategory B]
{a b : B}
(f : a ⟶ b)

[CategoryTheory.Bicategory.IsLeftAdjoint f,
    CategoryTheory.Bicategory.HasAbsLeftKanExtension f (CategoryTheory.CategoryStruct.id a),
    ∃ (x : CategoryTheory.Bicategory.HasLeftKanExtension f (CategoryTheory.CategoryStruct.id a)),
      CategoryTheory.Bicategory.Lan.CommuteWith f (CategoryTheory.CategoryStruct.id a) f].TFAE


theorem unop_sInf (S : Set (Subsemiring Rᵐᵒᵖ)) : (sInf S).unop = sInf (.op ⁻¹' S)

{R : Type u_2}
[NonAssocSemiring R]
(S : Set (Subsemiring Rᵐᵒᵖ))

(sInf S).unop = sInf (Subsemiring.op ⁻¹' S)


@[simp]
theorem singleton_eq_singleton_iff {x y : α} : {x} = ({y} : Set α) ↔ x = y


theorem wDest'_wMk {α : TypeVec n} (a : P.A) (f' : P.drop.B a ⟹ α) (f : P.last.B a → P.W α) :
    P.wDest' (P.wMk a f' f) = ⟨a, splitFun f' f⟩

{n : ℕ}
(P : MvPFunctor.{u} (n + 1))
{α : TypeVec.{u} n}
(a : P.A)
(f' : (P.drop.B a).Arrow α)
(f : P.last.B a → P.W α)

P.wDest' (P.wMk a f' f) = ⟨a, TypeVec.splitFun f' f⟩


theorem isOpen_range_inl : IsOpen (range (inl : X → X ⊕ Y))

{X : Type u}
{Y : Type v}
[TopologicalSpace X]
[TopologicalSpace Y]


@[simp]
lemma mem_zeroLocus_iff {U : Opens X} (s : Set (X.presheaf.obj (op U))) (x : X) :
    x ∈ X.zeroLocus s ↔ ∀ f ∈ s, x ∉ X.basicOpen f

{U : TopologicalSpace.Opens ↑↑X.toPresheafedSpace}

(s : Set ↑(X.presheaf.obj (Opposite.op U)))


theorem Subfield.le_topologicalClosure (s : Subfield α) : s ≤ s.topologicalClosure

{α : Type u_2}
[Field α]
[TopologicalSpace α]
[TopologicalDivisionRing α]
(s : Subfield α)


theorem le_iff_le : K ≤ fixedField H ↔ H ≤ fixingSubgroup K

{F : Type u_1}
[Field F]
{E : Type u_2}
[Field E]
[Algebra F E]
(H : Subgroup (E ≃ₐ[F] E))
(K : IntermediateField F E)

K ≤ IntermediateField.fixedField H ↔ H ≤ K.fixingSubgroup


@[reassoc (attr := simp)]
lemma XXIsoOfEq_inv_ιTotal {x₁ y₁ : I₁} (h₁ : x₁ = y₁) {x₂ y₂ : I₂} (h₂ : x₂ = y₂)
    (i₁₂ : I₁₂) (h : ComplexShape.π c₁ c₂ c₁₂ (x₁, x₂) = i₁₂) :
    (K.XXIsoOfEq h₁ h₂).inv ≫ K.ιTotal c₁₂ x₁ x₂ i₁₂ h =
      K.ιTotal c₁₂ y₁ y₂ i₁₂ (by rw [← h, h₁, h₂])

{C : Type u_1}
[CategoryTheory.Category.{u_5, u_1} C]
[CategoryTheory.Preadditive C]
{I₁ : Type u_2}
{I₂ : Type u_3}
{I₁₂ : Type u_4}
{c₁ : ComplexShape I₁}
{c₂ : ComplexShape I₂}
(K : HomologicalComplex₂ C c₁ c₂)
(c₁₂ : ComplexShape I₁₂)
[DecidableEq I₁₂]
[TotalComplexShape c₁ c₂ c₁₂]
[K.HasTotal c₁₂]
{x₁ y₁ : I₁}
(h₁ : x₁ = y₁)
{x₂ y₂ : I₂}
(h₂ : x₂ = y₂)
(i₁₂ : I₁₂)
(h : c₁.π c₂ c₁₂ (x₁, x₂) = i₁₂)

(HomologicalComplex₂.XXIsoOfEq C c₁ c₂ K h₁ h₂).inv ≫ K.ιTotal c₁₂ x₁ x₂ i₁₂ h = K.ιTotal c₁₂ y₁ y₂ i₁₂ ⋯


theorem gcd_def (i j : ℤ) : gcd i j = Nat.gcd i.natAbs j.natAbs


lemma max_min_distrib_right (a b c : α) : max (min a b) c = min (max a c) (max b c)

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


/-- If `f_n → g` pointwise and the derivatives `(f_n)' → h` _uniformly_ converge, then
in fact for a fixed `y`, the difference quotients `‖z - y‖⁻¹ • (f_n z - f_n y)` converge
_uniformly_ to `‖z - y‖⁻¹ • (g z - g y)` -/
theorem difference_quotients_converge_uniformly (hf' : TendstoUniformlyOnFilter f' g' l (𝓝 x))
    (hf : ∀ᶠ n : ι × E in l ×ˢ 𝓝 x, HasFDerivAt (f n.1) (f' n.1 n.2) n.2)
    (hfg : ∀ᶠ y : E in 𝓝 x, Tendsto (fun n => f n y) l (𝓝 (g y))) :
    TendstoUniformlyOnFilter (fun n : ι => fun y : E => (‖y - x‖⁻¹ : 𝕜) • (f n y - f n x))
      (fun y : E => (‖y - x‖⁻¹ : 𝕜) • (g y - g x)) l (𝓝 x)

(hf : ∀ᶠ (n : ι × E) in l ×ˢ 𝓝 x, HasFDerivAt (f n.1) (f' n.1 n.2) n.2)

(hfg : ∀ᶠ (y : E) in 𝓝 x, Filter.Tendsto (fun n => f n y) l (𝓝 (g y)))

TendstoUniformlyOnFilter (fun n y => (↑‖y - x‖)⁻¹ • (f n y - f n x)) (fun y => (↑‖y - x‖)⁻¹ • (g y - g x)) l (𝓝 x)


/-- The right adjoint of evaluation. -/
@[simps]
def evaluationRightAdjoint (c : C) : D ⥤ C ⥤ D

[∀ (a b : C), CategoryTheory.Limits.HasProductsOfShape (a ⟶ b) D]

((CategoryTheory.evaluationRightAdjoint D c).obj d).obj t = ∏ᶜ fun x => d


@[to_additive]
theorem inv_iff_ker' {f : G → H} (hf : IsGroupHom f) (a b : G) : f a = f b ↔ a⁻¹ * b ∈ ker f

{G : Type u_1}
{H : Type u_2}
[Group G]
[Group H]
{f : G → H}
(hf : IsGroupHom f)
(a b : G)


@[simp]
theorem card_cons (a : α) (s : Multiset α) : card (a ::ₘ s) = card s + 1

Multiset.card (a ::ₘ s) = Multiset.card s + 1


theorem map_isPrime_of_equiv {F' : Type*} [EquivLike F' R S] [RingEquivClass F' R S]
    (f : F') {I : Ideal R} [IsPrime I] : IsPrime (map f I)

{R : Type u_1}
{S : Type u_2}
[Semiring R]
[Semiring S]
{F' : Type u_4}
[EquivLike F' R S]
[RingEquivClass F' R S]
(f : F')
{I : Ideal R}
[I.IsPrime]


/-- Change a `Cocone F.op` into a `Cone F`. -/
@[simps]
def Cocone.unop (c : Cocone F.op) : Cone F

{J : Type u₁}
[CategoryTheory.Category.{v₁, u₁} J]
{C : Type u₃}
[CategoryTheory.Category.{v₃, u₃} C]
{F : J ⥤ C}
(c : CategoryTheory.Limits.Cocone F.op)

c.unop.π = CategoryTheory.NatTrans.removeOp c.ι


theorem TendstoInMeasure.aemeasurable {u : Filter ι} [NeBot u] [IsCountablyGenerated u]
    {f : ι → α → E} {g : α → E} (hf : ∀ n, AEMeasurable (f n) μ)
    (h_tendsto : TendstoInMeasure μ f u g) : AEMeasurable g μ

(h_tendsto : MeasureTheory.TendstoInMeasure μ f u g)


theorem Prime.dvd_iff_one_le_factorization {p n : ℕ} (pp : Prime p) (hn : n ≠ 0) :
    p ∣ n ↔ 1 ≤ n.factorization p

{p n : ℕ}
(pp : Nat.Prime p)
(hn : n ≠ 0)


protected lemma le_of_mul_le_mul_right (h : a * c ≤ b * c) (hc : 0 < c) : a ≤ b

{a b c : ℕ}
(h : a * c ≤ b * c)
(hc : 0 < c)


@[to_additive]
theorem AntitoneOn.inv (hf : AntitoneOn f s) : MonotoneOn (fun x => (f x)⁻¹) s

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


/-- If `f` is a bijective function, then its domain is equivalent to its codomain. -/
@[simps apply]
noncomputable def ofBijective (f : α → β) (hf : Bijective f) : α ≃ β

{α : Sort u}
{β : Sort v}
(f : α → β)
(hf : Function.Bijective f)

∀ (a : α), (Equiv.ofBijective f hf) a = f a


@[simp]
theorem tensor_fst (X Y : Center C) : (X ⊗ Y).1 = X.1 ⊗ Y.1

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


@[simp]
theorem orElse_think (c₁ c₂ : Computation α) : (think c₁ <|> think c₂) = think (c₁ <|> c₂)

(HOrElse.hOrElse c₁.think fun x => c₂.think) = (HOrElse.hOrElse c₁ fun x => c₂).think


theorem IsEquivalent.sub_isLittleO (huv : u ~[l] v) (hwv : w =o[l] v) : u - w ~[l] v

{α : Type u_1}
{β : Type u_2}
[NormedAddCommGroup β]
{u v w : α → β}
{l : Filter α}
(huv : u ~[l] v)
(hwv : w =o[l] v)


theorem Ioo_inter_Ioc_of_right_lt (h : b₂ < b₁) : Ioo a₁ b₁ ∩ Ioc a₂ b₂ = Ioc (max a₁ a₂) b₂

{α : Type u_1}
[LinearOrder α]
{a₁ a₂ b₁ b₂ : α}
(h : b₂ < b₁)

Set.Ioo a₁ b₁ ∩ Set.Ioc a₂ b₂ = Set.Ioc (max a₁ a₂) b₂


/-- Given a colimit cocone for the family `f : J → (X ⟶ Y)`, for any `Z`, morphisms from the cocone
point to `Z` are in bijection with morphisms `h : Z ⟶ X` such that
`∀ j₁ j₂, f j₁ ≫ h = f j₂ ≫ h`.  Further, this bijection is natural in `Z`: see
`Cotrident.IsColimit.homIso_natural`.
-/
@[simps]
def Cotrident.IsColimit.homIso [Nonempty J] {t : Cotrident f} (ht : IsColimit t) (Z : C) :
    (t.pt ⟶ Z) ≃ { h : Y ⟶ Z // ∀ j₁ j₂, f j₁ ≫ h = f j₂ ≫ h }

(ht : CategoryTheory.Limits.IsColimit t)

↑((CategoryTheory.Limits.Cotrident.IsColimit.homIso ht Z) k) = CategoryTheory.CategoryStruct.comp t.π k


@[simp] theorem msb_cast (h : w = v) (x : BitVec w) : (cast h x).msb = x.msb


@[simp]
theorem ι_eq_zero_iff (x : M) : ι R x = 0 ↔ x = 0

{R : Type u1}
[CommRing R]
{M : Type u2}
[AddCommGroup M]
[Module R M]
(x : M)


theorem fourierIntegral_smul_const (e : AddChar 𝕜 𝕊) (μ : Measure 𝕜) (f : 𝕜 → E) (r : ℂ) :
    fourierIntegral e μ (r • f) = r • fourierIntegral e μ f

{𝕜 : Type u_1}
[CommRing 𝕜]
[MeasurableSpace 𝕜]
{E : Type u_2}
[NormedAddCommGroup E]
[NormedSpace ℂ E]
(e : AddChar 𝕜 ↥𝕊)
(μ : MeasureTheory.Measure 𝕜)
(f : 𝕜 → E)
(r : ℂ)

Fourier.fourierIntegral e μ (r • f) = r • Fourier.fourierIntegral e μ f


lemma rpow_add_int' (hx : 0 ≤ x) {n : ℤ} (h : y + n ≠ 0) : x ^ (y + n) = x ^ y * x ^ n


theorem toZ_iterate_pred_of_not_isMin (n : ℕ) (hn : ¬IsMin (pred^[n] i0)) :
    toZ i0 (pred^[n] i0) = -n

{ι : Type u_1}
[LinearOrder ι]
[SuccOrder ι]
[IsSuccArchimedean ι]
[PredOrder ι]
{i0 : ι}
(n : ℕ)
(hn : ¬IsMin (Order.pred^[n] i0))


lemma hf_modif_FE (x : ℝ) (hx : 0 < x) :
    P.f_modif (1 / x) = (P.ε * ↑(x ^ P.k)) • P.g_modif x

{E : Type u_1}
[NormedAddCommGroup E]
[NormedSpace ℂ E]
(P : WeakFEPair E)
(x : ℝ)
(hx : 0 < x)


@[simp]
theorem detAux_comp (b : Trunc <| Basis ι A M) (f g : M →ₗ[A] M) :
    LinearMap.detAux b (f.comp g) = LinearMap.detAux b f * LinearMap.detAux b g

{M : Type u_2}
[AddCommGroup M]
{ι : Type u_4}
[DecidableEq ι]
[Fintype ι]
{A : Type u_5}
[CommRing A]
[Module A M]
(b : Trunc (Basis ι A M))
(f g : M →ₗ[A] M)

(LinearMap.detAux b) (f ∘ₗ g) = (LinearMap.detAux b) f * (LinearMap.detAux b) g


theorem mono {t : Set X} (hf : IsLocalHomeomorphOn f t) (hst : s ⊆ t) : IsLocalHomeomorphOn f s

{X : Type u_1}
{Y : Type u_2}
[TopologicalSpace X]
[TopologicalSpace Y]
{f : X → Y}
{s t : Set X}
(hf : IsLocalHomeomorphOn f t)
(hst : s ⊆ t)


theorem isPreconnected_Ioi : IsPreconnected (Ioi a)

{α : Type u}
[ConditionallyCompleteLinearOrder α]
[TopologicalSpace α]
[OrderTopology α]
[DenselyOrdered α]
{a : α}


protected theorem monotone (hf : IsFundamentalSequence a o f) {i j : Ordinal} (hi : i < o)
    (hj : j < o) (hij : i ≤ j) : f i hi ≤ f j hj

{f : (b : Ordinal.{u}) → b < o → Ordinal.{u}}


/-- The composition of two strong epimorphisms is a strong epimorphism. -/
theorem strongEpi_comp [StrongEpi f] [StrongEpi g] : StrongEpi (f ≫ g)

{C : Type u}
[CategoryTheory.Category.{v, u} C]
{P Q R : C}
(f : P ⟶ Q)
(g : Q ⟶ R)
[CategoryTheory.StrongEpi f]
[CategoryTheory.StrongEpi g]

CategoryTheory.StrongEpi (CategoryTheory.CategoryStruct.comp f g)


theorem matPolyEquiv_eq_X_pow_sub_C {K : Type*} (k : ℕ) [Field K] (M : Matrix n n K) :
    matPolyEquiv ((expand K k : K[X] →+* K[X]).mapMatrix (charmatrix (M ^ k))) =
      X ^ k - C (M ^ k)

{n : Type v}
[DecidableEq n]
[Fintype n]
{K : Type u_1}
(k : ℕ)
[Field K]
(M : Matrix n n K)

matPolyEquiv ((↑(Polynomial.expand K k)).mapMatrix (M ^ k).charmatrix) = Polynomial.X ^ k - Polynomial.C (M ^ k)


theorem image_subtype_univ_ssubset_image_univ [Fintype α] [DecidableEq β] (k : β) (b : α → β)
    (hk : k ∈ Finset.image b univ) (p : β → Prop) [DecidablePred p] (hp : ¬p k) :
    image (fun i : { a // p (b a) } => b ↑i) univ ⊂ image b univ

{α : Type u_1}
{β : Type u_2}
[Fintype α]
[DecidableEq β]
(k : β)
(b : α → β)
(hk : k ∈ Finset.image b Finset.univ)
(p : β → Prop)
[DecidablePred p]
(hp : ¬p k)

Finset.image (fun i => b ↑i) Finset.univ ⊂ Finset.image b Finset.univ


theorem SatisfiesM_anyM [Monad m] [LawfulMonad m] (p : α → m Bool) (as : Array α) (start stop)
    (hstart : start ≤ min stop as.size) (tru : Prop) (fal : Nat → Prop) (h0 : fal start)
    (hp : ∀ i : Fin as.size, i.1 < stop → fal i.1 →
      SatisfiesM (bif · then tru else fal (i + 1)) (p as[i])) :
    SatisfiesM
      (fun res => bif res then tru else fal (min stop as.size))
      (anyM p as start stop)

(hp : ∀ (i : Fin as.size), ↑i < stop → fal ↑i → SatisfiesM (fun x => bif x then tru else fal (↑i + 1)) (p as[i]))

SatisfiesM (fun res => bif res then tru else fal stop) (Array.anyM.loop p as stop hstop j)


@[simp]
lemma equivProdNatSmoothNumbers_apply {p e m : ℕ} (hp : p.Prime) (hm : m ∈ p.smoothNumbers) :
    equivProdNatSmoothNumbers hp (e, ⟨m, hm⟩) = p ^ e * m

{p e m : ℕ}
(hp : Nat.Prime p)
(hm : m ∈ p.smoothNumbers)

↑((Nat.equivProdNatSmoothNumbers hp) (e, ⟨m, hm⟩)) = p ^ e * m


/-- The algebra version of `AddMonoidAlgebra.addMonoidAlgebraEquivDirectSum`. -/
@[simps (config := .asFn)]
def addMonoidAlgebraAlgEquivDirectSum [DecidableEq ι] [AddMonoid ι] [CommSemiring R] [Semiring A]
    [Algebra R A] [∀ m : A, Decidable (m ≠ 0)] : AddMonoidAlgebra A ι ≃ₐ[R] ⨁ _ : ι, A

{ι : Type u_1}
{R : Type u_2}
{A : Type u_4}
[DecidableEq ι]
[AddMonoid ι]
[CommSemiring R]
[Semiring A]
[Algebra R A]
[(m : A) → Decidable (m ≠ 0)]


lemma rpow_sub_int' (hx : 0 ≤ x) {n : ℤ} (h : y - n ≠ 0) : x ^ (y - n) = x ^ y / x ^ n


theorem ascPochhammer_succ_left (n : ℕ) :
    ascPochhammer S (n + 1) = X * (ascPochhammer S n).comp (X + 1)

ascPochhammer S (n + 1) = Polynomial.X * (ascPochhammer S n).comp (Polynomial.X + 1)


@[simp]
theorem isLimitEquivSections_apply {c : Cone F} (t : IsLimit c) (j : J)
    (x : c.pt) : (isLimitEquivSections t x : ∀ j, F.obj j) j = c.π.app j x

{J : Type v}
[CategoryTheory.Category.{w, v} J]
{F : J ⥤ Type u}
{c : CategoryTheory.Limits.Cone F}
(t : CategoryTheory.Limits.IsLimit c)
(j : J)
(x : c.pt)

↑((CategoryTheory.Limits.Types.isLimitEquivSections t) x) j = c.π.app j x


/-- The equivalence `Square C ≌ Arrow (Arrow C)` which sends a
commutative square `sq` to the obvious arrow from the left morphism of `sq`
to the right morphism of `sq`. -/
@[simps]
def arrowArrowEquivalence : Square C ≌ Arrow (Arrow C)

{C : Type u}
[CategoryTheory.Category.{v, u} C]

CategoryTheory.Square.arrowArrowEquivalence.unitIso =
  CategoryTheory.Iso.refl (CategoryTheory.Functor.id (CategoryTheory.Square C))


@[to_additive]
theorem div_mul_comm : a / b * c = c / b * a

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


/-- Given `Uᵢ ×[Z] Y`, this is the glued fibered product `X ×[Z] Y`. -/
@[simps U V f t t', simps (config := .lemmasOnly) J]
def gluing : Scheme.GlueData.{u}

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

(AlgebraicGeometry.Scheme.Pullback.gluing 𝒰 f g).f i j =
  CategoryTheory.Limits.pullback.fst (CategoryTheory.Limits.pullback.fst (𝒰.map i ≫ f) g ≫ 𝒰.map i) (𝒰.map j)


@[simp]
theorem cantorFunctionAux_true (h : f n = true) : cantorFunctionAux c f n = c ^ n

{c : ℝ}
{f : ℕ → Bool}
{n : ℕ}
(h : f n = true)

Cardinal.cantorFunctionAux c f n = c ^ n


@[simp]
theorem biUnion_of_singleton (s : Set α) : ⋃ x ∈ s, {x} = s


@[to_additive]
theorem MeasurableSet.inv {s : Set G} (hs : MeasurableSet s) : MeasurableSet s⁻¹

{G : Type u_2}
[Inv G]
[MeasurableSpace G]
[MeasurableInv G]
{s : Set G}
(hs : MeasurableSet s)


theorem IsEquivalent.tendsto_atBot_iff [OrderTopology β] (huv : u ~[l] v) :
    Tendsto u l atBot ↔ Tendsto v l atBot

{α : Type u_1}
{β : Type u_2}
[NormedLinearOrderedField β]
{u v : α → β}
{l : Filter α}
[OrderTopology β]
(huv : u ~[l] v)

Filter.Tendsto u l Filter.atBot ↔ Filter.Tendsto v l Filter.atBot


@[reassoc]
theorem prod.pentagon [HasBinaryProducts C] (W X Y Z : C) :
    prod.map (prod.associator W X Y).hom (𝟙 Z) ≫
        (prod.associator W (X ⨯ Y) Z).hom ≫ prod.map (𝟙 W) (prod.associator X Y Z).hom =
      (prod.associator (W ⨯ X) Y Z).hom ≫ (prod.associator W X (Y ⨯ Z)).hom

CategoryTheory.Limits.prod.map (CategoryTheory.Limits.prod.associator W X Y).hom (𝟙 Z) ≫
    (CategoryTheory.Limits.prod.associator W (X ⨯ Y) Z).hom ≫
      CategoryTheory.Limits.prod.map (𝟙 W) (CategoryTheory.Limits.prod.associator X Y Z).hom =
  (CategoryTheory.Limits.prod.associator (W ⨯ X) Y Z).hom ≫ (CategoryTheory.Limits.prod.associator W X (Y ⨯ Z)).hom


@[simp]
theorem carrier_inj : p.carrier = q.carrier ↔ p = q

{R : Type u}
{M : Type v}
[Semiring R]
[AddCommMonoid M]
[Module R M]
{p q : Submodule R M}


@[simp, norm_cast]
theorem nnnorm_nat (n : ℕ) : ‖(n : ℂ)‖₊ = n


theorem IsInt.to_isNat {α} [Ring α] : ∀ {a : α} {n}, IsInt a (.ofNat n) → IsNat a n

Mathlib.Meta.NormNum.IsInt a (Int.ofNat n) → Mathlib.Meta.NormNum.IsNat a n


theorem sdiff_sdiff_eq_sdiff_union (h : u ⊆ s) : s \ (t \ u) = s \ t ∪ u

{α : Type u_1}
[DecidableEq α]
{s t u : Finset α}
(h : u ⊆ s)


protected theorem eq : ∀ {a1 a2 : {x // p x}}, val a1 = val a2 → a1 = a2

{α : Type u}
{p : α → Prop}
{a1 a2 : Subtype fun x => p x}


/-- Compute `(f ⋆ g) x₀` if the support of the `f` is within `Metric.ball 0 R`, and `g` is constant
on `Metric.ball x₀ R`.

We can simplify the RHS further if we assume `f` is integrable, but also if `L = (•)` or more
generally if `L` has an `AntilipschitzWith`-condition. -/
theorem convolution_eq_right' {x₀ : G} {R : ℝ} (hf : support f ⊆ ball (0 : G) R)
    (hg : ∀ x ∈ ball x₀ R, g x = g x₀) : (f ⋆[L, μ] g) x₀ = ∫ t, L (f t) (g x₀) ∂μ

(hf : Function.support f ⊆ Metric.ball 0 R)

(hg : ∀ x ∈ Metric.ball x₀ R, g x = g x₀)

MeasureTheory.convolution f g L μ x₀ = ∫ (t : G), (L (f t)) (g x₀) ∂μ


lemma sdiff_ne_sdiff_iff : a \ b ≠ b \ a ↔ a ≠ b

{α : Type u_2}
[GeneralizedCoheytingAlgebra α]
{a b : α}


/-- A family `𝓕 : ι → β → α` is uniformly equicontinuous on `S` iff `range 𝓕` is uniformly
equicontinuous on `S`, i.e the family `(↑) : range F → β → α` is uniformly equicontinuous on `S`. -/
theorem uniformEquicontinuousOn_iff_range {F : ι → β → α} {S : Set β} :
    UniformEquicontinuousOn F S ↔ UniformEquicontinuousOn ((↑) : range F → β → α) S

{ι : Type u_1}
{α : Type u_7}
{β : Type u_9}
[uα : UniformSpace α]
[uβ : UniformSpace β]
{F : ι → β → α}
{S : Set β}

UniformEquicontinuousOn F S ↔ UniformEquicontinuousOn Subtype.val S


@[simp]
theorem floor_eq_zero : ⌊a⌋₊ = 0 ↔ a < 1

{α : Type u_2}
[LinearOrderedSemiring α]
[FloorSemiring α]
{a : α}


@[reassoc]
lemma homMap_comp (f : L₁.obj X ⟶ L₁.obj Y) (g : L₁.obj Y ⟶ L₁.obj Z) :
    Φ.homMap L₁ L₂ (f ≫ g) = Φ.homMap L₁ L₂ f ≫ Φ.homMap L₁ L₂ g

{W₁ : CategoryTheory.MorphismProperty C₁}

{W₂ : CategoryTheory.MorphismProperty C₂}

(Φ : CategoryTheory.LocalizerMorphism W₁ W₂)

Φ.homMap L₁ L₂ (CategoryTheory.CategoryStruct.comp f g) =
  CategoryTheory.CategoryStruct.comp (Φ.homMap L₁ L₂ f) (Φ.homMap L₁ L₂ g)


/-- A family indexed by a type with a unique element
is `MulEquiv` to the element at the single index. -/
@[to_additive (attr := simps!)
  "A family indexed by a type with a unique element
  is `AddEquiv` to the element at the single index."]
def piUnique {ι : Type*} (M : ι → Type*) [∀ j, Mul (M j)] [Unique ι] :
    (∀ j, M j) ≃* M default

{ι : Type u_12}
(M : ι → Type u_13)
[(j : ι) → Mul (M j)]
[Unique ι]
(x : M default)
(i : ι)

(MulEquiv.piUnique M).symm x i = uniqueElim x i


/-- A separable uniform space with countably generated uniformity filter is second countable:
one obtains a countable basis by taking the balls centered at points in a dense subset,
and with rational "radii" from a countable open symmetric antitone basis of `𝓤 α`. We do not
register this as an instance, as there is already an instance going in the other direction
from second countable spaces to separable spaces, and we want to avoid loops. -/
theorem secondCountable_of_separable [SeparableSpace α] : SecondCountableTopology α

(α : Type u)
[uniformSpace : UniformSpace α]
[(𝓤 α).IsCountablyGenerated]
[TopologicalSpace.SeparableSpace α]


/-- A family `{ eᵢ }` of idempotent elements is orthogonal if `eᵢ * eⱼ = 0` for all `i ≠ j`. -/
@[mk_iff]
structure OrthogonalIdempotents : Prop where
  idem : ∀ i, IsIdempotentElem (e i)
  ortho : ∀ i j, i ≠ j → e i * e j = 0

{R : Type u_1}
[Ring R]
{I : Type u_3}
{e : I → R}
(self : OrthogonalIdempotents e)
(i : I)


lemma IsLocallyClosed.preimage {s : Set Y} (hs : IsLocallyClosed s)
    {f : X → Y} (hf : Continuous f) :
    IsLocallyClosed (f ⁻¹' s)

{X : Type u_1}
{Y : Type u_2}
[TopologicalSpace X]
[TopologicalSpace Y]
{s : Set Y}
(hs : IsLocallyClosed s)
{f : X → Y}
(hf : Continuous f)


theorem isCompactElement_iff.{u} {α : Type u} [CompleteLattice α] (k : α) :
    CompleteLattice.IsCompactElement k ↔
      ∀ (ι : Type u) (s : ι → α), k ≤ iSup s → ∃ t : Finset ι, k ≤ t.sup s

CompleteLattice.IsCompactElement k ↔ ∀ (ι : Type u) (s : ι → α), k ≤ iSup s → ∃ t, k ≤ t.sup s


theorem of_eq {n} {f g : Vector ℕ n → ℕ} (hf : Primrec' f) (H : ∀ i, f i = g i) : Primrec' g

(H : ∀ (i : Mathlib.Vector ℕ n), f i = g i)


/-- Cauchy–Schwarz inequality with norm -/
theorem norm_inner_le_norm (x y : E) : ‖⟪x, y⟫‖ ≤ ‖x‖ * ‖y‖

{𝕜 : Type u_1}
{E : Type u_2}
[RCLike 𝕜]
[NormedAddCommGroup E]
[InnerProductSpace 𝕜 E]
(x y : E)

‖⟪x, y⟫_𝕜‖ ≤ ‖x‖ * ‖y‖


@[simp]
theorem extendScalars_restrictScalars : (extendScalars h).restrictScalars K = E

{K : Type u_1}
{L : Type u_2}
[Field K]
[Field L]
[Algebra K L]
{F E : IntermediateField K L}
(h : F ≤ E)

IntermediateField.restrictScalars K (IntermediateField.extendScalars h) = E


theorem eval_eq_sum_range' {p : R[X]} {n : ℕ} (hn : p.natDegree < n) (x : R) :
    p.eval x = ∑ i ∈ Finset.range n, p.coeff i * x ^ i

{R : Type u}
[Semiring R]
{p : R[X]}
{n : ℕ}
(hn : p.natDegree < n)
(x : R)

Polynomial.eval x p = ∑ i ∈ Finset.range n, p.coeff i * x ^ i


@[to_additive]
protected theorem inv_eq_of_mul_eq_one_right {a : α} (h : ↑u * a = 1) : ↑u⁻¹ = a

{α : Type u}
[AddMonoid α]
{u : AddUnits α}
{a : α}
(h : ↑u + a = 0)


theorem weightedTotalDegree_one (φ : MvPolynomial σ R) :
    weightedTotalDegree (1 : σ → ℕ) φ = φ.totalDegree

{σ : Type u_1}
{R : Type u_3}
[CommSemiring R]
(φ : MvPolynomial σ R)

MvPolynomial.weightedTotalDegree 1 φ = φ.totalDegree


theorem convex_zero : Convex 𝕜 (0 : Set E)

{𝕜 : Type u_1}
{E : Type u_2}
[OrderedSemiring 𝕜]
[AddCommMonoid E]
[Module 𝕜 E]


theorem sub_le_of_abs_sub_le_left (h : |a - b| ≤ c) : b - c ≤ a

{α : Type u_1}
[LinearOrderedAddCommGroup α]
{a b c : α}
(h : |a - b| ≤ c)


lemma ext_dual_iff {A B : E →WOT[𝕜] F} :
    A = B ↔ ∀ x (y : F⋆), y (A x) = y (B x)

{𝕜 : Type u_1}
{E : Type u_2}
{F : Type u_3}
[RCLike 𝕜]
[AddCommGroup E]
[TopologicalSpace E]
[Module 𝕜 E]
[NormedAddCommGroup F]
[NormedSpace 𝕜 F]
{A B : E →WOT[𝕜]F}

A = B ↔ ∀ (x : E) (y : NormedSpace.Dual 𝕜 F), y (A x) = y (B x)


@[to_additive (attr := simp) existing AddGroupSeminorm.smul_apply]
theorem smul_apply (r : R) (p : GroupSeminorm E) (x : E) : (r • p) x = r • p x

{R : Type u_2}
{E : Type u_4}
[Group E]
[SMul R ℝ]
[SMul R ℝ≥0]
[IsScalarTower R ℝ≥0 ℝ]
(r : R)
(p : GroupSeminorm E)
(x : E)


lemma subset_kernImage_iff {s : Set β} {t : Set α} {f : α → β} : s ⊆ kernImage f t ↔ f ⁻¹' s ⊆ t

{α : Type u}
{β : Type v}
{s : Set β}
{t : Set α}
{f : α → β}


@[simp] theorem cases_zero {n} {motive : Fin (n + 1) → Sort _} {zero succ} :
    @Fin.cases n motive zero succ 0 = zero

{n : Nat}
{motive : Fin (n + 1) → Sort u_1}
{zero : motive 0}
{succ : (i : Fin n) → motive i.succ}


theorem integral_non_aestronglyMeasurable {f : α → G} (h : ¬AEStronglyMeasurable f μ) :
    ∫ a, f a ∂μ = 0

(h : ¬MeasureTheory.AEStronglyMeasurable f μ)


/-- When `d` is negative, then `x` or `y` must be zero in a solution. -/
theorem eq_zero_of_d_neg (h₀ : d < 0) (a : Solution₁ d) : a.x = 0 ∨ a.y = 0

{d : ℤ}
(h₀ : d < 0)
(a : Pell.Solution₁ d)


theorem _root_.HasCompactSupport.contDiff_convolution_left [μ.IsAddLeftInvariant] [μ.IsNegInvariant]
    {n : ℕ∞} (hcf : HasCompactSupport f) (hf : ContDiff 𝕜 n f) (hg : LocallyIntegrable g μ) :
    ContDiff 𝕜 n (f ⋆[L, μ] g)

(hg : MeasureTheory.LocallyIntegrable g μ)

ContDiff 𝕜 n (MeasureTheory.convolution f g L μ)


protected theorem max_le {M : WithBot α} {s : Finset α} (st : ∀ a ∈ s, (a : WithBot α) ≤ M) :
    s.max ≤ M

{α : Type u_2}
[LinearOrder α]
{M : WithBot α}
{s : Finset α}
(st : ∀ a ∈ s, ↑a ≤ M)


@[to_additive]
theorem _root_.Fintype.prod_eq_prod_compl_mul [DecidableEq α] [Fintype α] (a : α) (f : α → β) :
    ∏ i, f i = (∏ i ∈ {a}ᶜ, f i) * f a

{α : Type u_3}
{β : Type u_4}
[AddCommMonoid β]
[DecidableEq α]
[Fintype α]
(a : α)
(f : α → β)


@[to_additive (attr := simp) Fintype.sum_prod_type]
theorem Fintype.prod_prod_type [CommMonoid γ] {f : α₁ × α₂ → γ} :
    ∏ x, f x = ∏ x, ∏ y, f (x, y)

{γ : Type u_3}
{α₁ : Type u_4}
{α₂ : Type u_5}
[Fintype α₁]
[Fintype α₂]
[CommMonoid γ]
{f : α₁ × α₂ → γ}

∏ x : α₁ × α₂, f x = ∏ x : α₁, ∏ y : α₂, f (x, y)


theorem isOpen_sUnion {s : Set (Set X)} (h : ∀ t ∈ s, IsOpen t) : IsOpen (⋃₀ s)

{X : Type u}
[TopologicalSpace X]
{s : Set (Set X)}
(h : ∀ (t : Set X), t ∈ s → IsOpen t)


/-- **Jacobi identity**: For a cross product of three vectors,
    their sum over the three even permutations is equal to the zero vector. -/
theorem jacobi_cross (u v w : Fin 3 → R) : u ×₃ (v ×₃ w) + v ×₃ (w ×₃ u) + w ×₃ (u ×₃ v) = 0

{R : Type u_1}
[CommRing R]
(u v w : Fin 3 → R)

(crossProduct u) ((crossProduct v) w) + (crossProduct v) ((crossProduct w) u) + (crossProduct w) ((crossProduct u) v) =
  0


protected theorem zero_lt_one : 0 < (1:Nat)


/-- (Impl) Construct the lifted cocone in `Algebra T` which will be colimiting. -/
@[simps]
def liftedCocone : Cocone D

{D : CategoryTheory.Functor J T.Algebra}

(c : CategoryTheory.Limits.Cocone (D.comp T.forget))

[CategoryTheory.Limits.PreservesColimit (D.comp T.forget) T.toFunctor]

[CategoryTheory.Limits.PreservesColimit ((D.comp T.forget).comp T.toFunctor) T.toFunctor]

((CategoryTheory.Monad.ForgetCreatesColimits.liftedCocone c t).ι.app j).f = c.ι.app j


@[to_additive (attr := simp)]
theorem coe_bot : ((⊥ : Subgroup G) : Set G) = {1}


/-- `preimage_smul_setₛₗ` in the context of a groups -/
theorem Group.preimage_smul_setₛₗ
    {R S : Type*} [Group R] [Group S] (σ : R → S)
    [MulAction R M] [MulAction S N]
    {F : Type*} [FunLike F M N] [MulActionSemiHomClass F σ M N] (h : F)
    (c : R) (t : Set N) :
    h ⁻¹' (σ c • t) = c • h ⁻¹' t

(M : Type u_3)
(N : Type u_6)
{R : Type u_8}
{S : Type u_9}
[Group R]
[Group S]
(σ : R → S)
[MulAction R M]
[MulAction S N]
{F : Type u_10}
[FunLike F M N]
[MulActionSemiHomClass F σ M N]
(h : F)
(c : R)
(t : Set N)


/-- See the note on `eqToHom_map` regarding using this as a `simp` lemma.
-/
theorem eqToIso_map (F : C ⥤ D) {X Y : C} (p : X = Y) :
    F.mapIso (eqToIso p) = eqToIso (congr_arg F.obj p)

{C : Type u₁}
[CategoryTheory.Category.{v₁, u₁} C]
{D : Type u₂}
[CategoryTheory.Category.{v₂, u₂} D]
(F : CategoryTheory.Functor C D)
{X Y : C}
(p : X = Y)

F.mapIso (CategoryTheory.eqToIso p) = CategoryTheory.eqToIso ⋯


@[simp] theorem erase_replicate_self [LawfulBEq α] {a : α} :
    (replicate n a).erase a = replicate (n - 1) a

{α : Type u_1}
[BEq α]
{n : Nat}
[LawfulBEq α]
{a : α}

(List.replicate n a).erase a = List.replicate (n - 1) a


@[simp]
theorem fullSubcategoryInclusion_map_lift_map (F : C ⥤ D) (hF : ∀ X, P (F.obj X)) {X Y : C}
    (f : X ⟶ Y) :
    (fullSubcategoryInclusion P).map ((FullSubcategory.lift P F hF).map f) = F.map f

{C : Type u₁}
[CategoryTheory.Category.{v, u₁} C]
{D : Type u₂}
[CategoryTheory.Category.{v₂, u₂} D]
(P : D → Prop)
(F : CategoryTheory.Functor C D)
(hF : ∀ (X : C), P (F.obj X))
{X Y : C}
(f : X ⟶ Y)

(CategoryTheory.fullSubcategoryInclusion P).map ((CategoryTheory.FullSubcategory.lift P F hF).map f) = F.map f


theorem right_of_add (hn : IsPeriodicPt f (n + m) x) (hm : IsPeriodicPt f n x) :
    IsPeriodicPt f m x

(hn : Function.IsPeriodicPt f (n + m) x)


@[to_additive]
protected theorem inj [Mul α] [PartialOrder α] {a b c : α} (ha : MulLECancellable a) :
    a * b = a * c ↔ b = c

{α : Type u_1}
[Add α]
[PartialOrder α]
{a b c : α}
(ha : AddLECancellable a)


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


/-- The assertion that the short complex `S : ShortComplex C` is exact. -/
structure Exact : Prop where
  /-- the condition that there exists an homology data whose `left.H` field is zero -/
  condition : ∃ (h : S.HomologyData), IsZero h.left.H

∃ h, CategoryTheory.Limits.IsZero h.left.H


@[to_additive]
theorem multipliable_iff_vanishing :
    Multipliable f ↔
    ∀ e ∈ 𝓝 (1 : α), ∃ s : Finset β, ∀ t, Disjoint t s → (∏ b ∈ t, f b) ∈ e

{α : Type u_1}
{β : Type u_2}
[CommGroup α]
[UniformSpace α]
[UniformGroup α]
{f : β → α}
[CompleteSpace α]

Multipliable f ↔ ∀ e ∈ 𝓝 1, ∃ s, ∀ (t : Finset β), Disjoint t s → ∏ b ∈ t, f b ∈ e


theorem deterministic_comp_eq_map (hf : Measurable f) (κ : Kernel α β) :
    deterministic f hf ∘ₖ κ = map κ f hf

{α : Type u_1}
{β : Type u_2}
{mα : MeasurableSpace α}
{mβ : MeasurableSpace β}
{γ : Type u_4}
{mγ : MeasurableSpace γ}
{f : β → γ}
(hf : Measurable f)
(κ : ProbabilityTheory.Kernel α β)

(ProbabilityTheory.Kernel.deterministic f hf).comp κ = κ.map f hf


@[continuity, fun_prop]
protected theorem continuous (f : M₁ →SL[σ₁₂] M₂) : Continuous f

{R₁ : Type u_1}
{R₂ : Type u_2}
[Semiring R₁]
[Semiring R₂]
{σ₁₂ : R₁ →+* R₂}
{M₁ : Type u_4}
[TopologicalSpace M₁]
[AddCommMonoid M₁]
{M₂ : Type u_6}
[TopologicalSpace M₂]
[AddCommMonoid M₂]
[Module R₁ M₁]
[Module R₂ M₂]
(f : M₁ →SL[σ₁₂] M₂)


/-- Given `I : S.Arrow` and a morphism `g : Z ⟶ I.Y`, this is the arrow in `S.Arrow`
corresponding to `g ≫ I.f`. -/
@[simps]
def Arrow.precomp {S : J.Cover X} (I : S.Arrow) {Z : C} (g : Z ⟶ I.Y) : S.Arrow

{J : CategoryTheory.GrothendieckTopology C}

(I.precomp g).f = CategoryTheory.CategoryStruct.comp g I.f


theorem setIntegral_dirac' {mα : MeasurableSpace α} {f : α → E} (hf : StronglyMeasurable f) (a : α)
    {s : Set α} (hs : MeasurableSet s) [Decidable (a ∈ s)] :
    ∫ x in s, f x ∂Measure.dirac a = if a ∈ s then f a else 0

(hf : MeasureTheory.StronglyMeasurable f)

∫ (x : α) in s, f x ∂MeasureTheory.Measure.dirac a = if a ∈ s then f a else 0


@[simp]
theorem apply_symm_apply (e : L₁ ≃ₗ⁅R⁆ L₂) : ∀ x, e (e.symm x) = x

{R : Type u}
{L₁ : Type v}
{L₂ : Type w}
[CommRing R]
[LieRing L₁]
[LieRing L₂]
[LieAlgebra R L₁]
[LieAlgebra R L₂]
(e : L₁ ≃ₗ⁅R⁆ L₂)
(x : L₂)


theorem fderiv_norm_rpow (x : E) {p : ℝ} (hp : 1 < p) :
    fderiv ℝ (fun x ↦ ‖x‖ ^ p) x = (p * ‖x‖ ^ (p - 2)) • innerSL ℝ x

{E : Type u_1}
[NormedAddCommGroup E]
[InnerProductSpace ℝ E]
(x : E)
{p : ℝ}
(hp : 1 < p)

fderiv ℝ (fun x => ‖x‖ ^ p) x = (p * ‖x‖ ^ (p - 2)) • (innerSL ℝ) x


/-- A monoid homomorphism preserves multiplication. -/
@[to_additive "An additive monoid homomorphism preserves addition."]
theorem map_mul' (x y) : f (x * y) = f x * f y

{α : Type u}
{β : Type v}
[AddZeroClass α]
[AddZeroClass β]
{f : α → β}
(hf : IsAddMonoidHom f)
(x y : α)


theorem comap_map_eq (f : F) (p : Submodule R M) : comap f (map f p) = p ⊔ LinearMap.ker f

{R : Type u_1}
{R₂ : Type u_2}
{M : Type u_4}
{M₂ : Type u_5}
[Semiring R]
[Semiring R₂]
[AddCommGroup M]
[Module R M]
[AddCommGroup M₂]
[Module R₂ M₂]
{τ₁₂ : R →+* R₂}
[RingHomSurjective τ₁₂]
{F : Type u_8}
[FunLike F M M₂]
[SemilinearMapClass F τ₁₂ M M₂]
(f : F)
(p : Submodule R M)

Submodule.comap f (Submodule.map f p) = p ⊔ LinearMap.ker f


@[simp] theorem lcm_self {a : Int} : lcm a a = a.natAbs


@[simp]
theorem ite_compl (t s s' : Set α) : tᶜ.ite s s' = t.ite s' s


theorem IsBigOWith.prod_left_snd (h : IsBigOWith c l (fun x => (f' x, g' x)) k') :
    IsBigOWith c l g' k'

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


@[to_additive] lemma mulEnergy_mono_left (hs : s₁ ⊆ s₂) : Eₘ[s₁, t] ≤ Eₘ[s₂, t]

{α : Type u_1}
[DecidableEq α]
[Mul α]
{s₁ s₂ t : Finset α}
(hs : s₁ ⊆ s₂)


@[simp]
theorem LinearMap.toMatrixAlgEquiv'_apply (f : (n → R) →ₗ[R] n → R) (i j) :
    LinearMap.toMatrixAlgEquiv' f i j = f (fun j' ↦ if j' = j then 1 else 0) i

{R : Type u_1}
[CommSemiring R]
{n : Type u_5}
[DecidableEq n]
[Fintype n]
(f : (n → R) →ₗ[R] n → R)
(i j : n)

LinearMap.toMatrixAlgEquiv' f i j = f (fun j' => if j' = j then 1 else 0) i


lemma ext {A B : E →WOT[𝕜] F} (h : ∀ x, A x = B x) : A = B

{𝕜 : Type u_1}
{E : Type u_2}
{F : Type u_3}
[RCLike 𝕜]
[AddCommGroup E]
[TopologicalSpace E]
[Module 𝕜 E]
[NormedAddCommGroup F]
[NormedSpace 𝕜 F]
{A B : E →WOT[𝕜]F}
(h : ∀ (x : E), A x = B x)


theorem mem_bot {x : R} : x ∈ (⊥ : Subring R) ↔ ∃ n : ℤ, ↑n = x


theorem epi_iff_epi_left [HasPushouts A] [PreservesColimitsOfShape WalkingSpan G]
    {Y Z : CostructuredArrow G X} (f : Y ⟶ Z) : Epi f ↔ Epi f.left

{Y Z : CategoryTheory.CostructuredArrow G X}

CategoryTheory.Epi f ↔ CategoryTheory.Epi f.left


theorem Antivary.dual_left : Antivary f g → Monovary (toDual ∘ f) g

{ι : Type u_1}
{α : Type u_3}
{β : Type u_4}
[Preorder α]
[Preorder β]
{f : ι → α}
{g : ι → β}

Antivary f g → Monovary (⇑OrderDual.toDual ∘ f) g


lemma hasLeftHomology_of_epi_of_isIso_of_mono' (φ : S₁ ⟶ S₂) [HasLeftHomology S₂]
    [Epi φ.τ₁] [IsIso φ.τ₂] [Mono φ.τ₃] : HasLeftHomology S₁


@[simp]
theorem toRealLinearIsometryEquiv_apply (f : E ≃ᵢ F) (x : E) :
    (f.toRealLinearIsometryEquiv : E → F) x = f x - f 0

{E : Type u_1}
{F : Type u_3}
[NormedAddCommGroup E]
[NormedSpace ℝ E]
[NormedAddCommGroup F]
[NormedSpace ℝ F]
(f : E ≃ᵢ F)
(x : E)

f.toRealLinearIsometryEquiv x = f x - f 0


/-- `f : α →+* β` has a trivial codomain iff it has a trivial range. -/
theorem codomain_trivial_iff_range_trivial : (0 : β) = 1 ↔ ∀ x, f x = 0

∀ {x : NonAssocSemiring α} {x_1 : NonAssocSemiring β} (f : α →+* β), 0 = 1 ↔ ∀ (x_2 : α), f x_2 = 0