@[measurability]
lemma measurable_discrete (f : α → β) : Measurable f

{α : Type u_1}
{β : Type u_2}
[MeasurableSpace α]
[MeasurableSpace β]
[DiscreteMeasurableSpace α]
(f : α → β)


/-- A subring is closed under negation. -/
protected theorem neg_mem {x : R} : x ∈ s → -x ∈ s

{R : Type u}
[Ring R]
(s : Subring R)
{x : R}


lemma iSup_iInf_eq (f : ∀ i, κ i → α) :
    let _ := minAx.toCompleteLattice
    ⨆ i, ⨅ j, f i j = ⨅ g : ∀ i, κ i, ⨆ i, f i (g i)

(minAx : CompletelyDistribLattice.MinimalAxioms α)

let x := minAx.toCompleteLattice;
⨆ i, ⨅ j, f i j = ⨅ g, ⨆ i, f i (g i)


@[to_additive]
lemma prod_preimage_of_bij (f : ι → κ) (s : Finset κ) (hf : Set.BijOn f (f ⁻¹' ↑s) ↑s) (g : κ → β) :
    ∏ x ∈ s.preimage f hf.injOn, g (f x) = ∏ x ∈ s, g x

{ι : Type u_1}
{κ : Type u_2}
{β : Type u_4}
[AddCommMonoid β]
(f : ι → κ)
(s : Finset κ)
(hf : Set.BijOn f (f ⁻¹' ↑s) ↑s)
(g : κ → β)

∑ x ∈ s.preimage f ⋯, g (f x) = ∑ x ∈ s, g x


theorem Flat.mono {S T : ConvexCone 𝕜 E} (h : S ≤ T) : S.Flat → T.Flat

{𝕜 : Type u_1}
{E : Type u_2}
[OrderedSemiring 𝕜]
[AddCommGroup E]
[SMul 𝕜 E]
{S T : ConvexCone 𝕜 E}
(h : S ≤ T)


lemma comap_injective (f : C(X, Y)) (hfs : f.1.Surjective) :
    (comap (Z := Z) f).Injective

{X : Type u_1}
{Y : Type u_2}
{Z : Type u_3}
[TopologicalSpace X]
[TopologicalSpace Y]
(f : C(X, Y))
(hfs : Function.Surjective f.toFun)


/-- When `g` preserves addition, `mapRange` and `mapDomain` commute. -/
theorem mapDomain_mapRange [AddCommMonoid N] (f : α → β) (v : α →₀ M) (g : M → N) (h0 : g 0 = 0)
    (hadd : ∀ x y, g (x + y) = g x + g y) :
    mapDomain f (mapRange g h0 v) = mapRange g h0 (mapDomain f v)

(hadd : ∀ (x y : M), g (x + y) = g x + g y)

Finsupp.mapDomain f (Finsupp.mapRange g h0 v) = Finsupp.mapRange g h0 (Finsupp.mapDomain f v)


@[simp] lemma subset_supClosure {s : Set α} : s ⊆ supClosure s

{α : Type u_2}
[SemilatticeSup α]
{s : Set α}


theorem pderiv_one {i : σ} : pderiv i (1 : MvPolynomial σ R) = 0

{R : Type u}
{σ : Type v}
[CommSemiring R]
{i : σ}


theorem isInt_rpow_neg {a b : ℝ} {nb ne : ℕ}
    (pb : IsInt b (Int.negOfNat nb)) (pe' : IsInt (a ^ (Int.negOfNat nb)) (Int.negOfNat ne)) :
    IsInt (a ^ b) (Int.negOfNat ne)

(pb : Mathlib.Meta.NormNum.IsInt b (Int.negOfNat nb))

(pe' : Mathlib.Meta.NormNum.IsInt (a ^ Int.negOfNat nb) (Int.negOfNat ne))

Mathlib.Meta.NormNum.IsInt (a ^ b) (Int.negOfNat ne)


theorem Continuous.strictAnti_of_inj_boundedOrder [BoundedOrder α] {f : α → δ}
    (hf_c : Continuous f) (hf : f ⊤ ≤ f ⊥) (hf_i : Injective f) : StrictAnti f

{α : Type u}
[ConditionallyCompleteLinearOrder α]
[TopologicalSpace α]
[OrderTopology α]
[DenselyOrdered α]
{δ : Type u_1}
[LinearOrder δ]
[TopologicalSpace δ]
[OrderClosedTopology δ]
[BoundedOrder α]
{f : α → δ}
(hf_c : Continuous f)
(hf : f ⊤ ≤ f ⊥)
(hf_i : Function.Injective f)


@[to_additive]
theorem ne_one_of_nnnorm_ne_zero {a : E} : ‖a‖₊ ≠ 0 → a ≠ 1

{E : Type u_6}
[SeminormedGroup E]
{a : E}

‖a‖₊ ≠ 0 → a ≠ 1


protected lemma LocallyLinear.edgeDisjointTriangles : G.LocallyLinear → G.EdgeDisjointTriangles


lemma schnirelmannDensity_setOf_even : schnirelmannDensity (setOf Even) = 0


@[simp]
theorem differentiableOn_neg_iff : DifferentiableOn 𝕜 (fun y => -f y) s ↔ DifferentiableOn 𝕜 f s

{𝕜 : Type u_1}
[NontriviallyNormedField 𝕜]
{E : Type u_2}
[NormedAddCommGroup E]
[NormedSpace 𝕜 E]
{F : Type u_3}
[NormedAddCommGroup F]
[NormedSpace 𝕜 F]
{f : E → F}
{s : Set E}


@[to_additive (attr := simp)]
theorem lift_eval_of (f : α → M) (x : α) : lift f (of x) = f x

{α : Type u_1}
{M : Type u_4}
[Monoid M]
(f : α → M)
(x : α)

(FreeMonoid.lift f) (FreeMonoid.of x) = f x


@[to_additive]
theorem update_div [∀ i, Div (f i)] [DecidableEq I] (f₁ f₂ : ∀ i, f i) (i : I) (x₁ : f i)
    (x₂ : f i) : update (f₁ / f₂) i (x₁ / x₂) = update f₁ i x₁ / update f₂ i x₂

{I : Type u}
{f : I → Type v}
[(i : I) → Sub (f i)]
[DecidableEq I]
(f₁ f₂ : (i : I) → f i)
(i : I)
(x₁ x₂ : f i)

Function.update (f₁ - f₂) i (x₁ - x₂) = Function.update f₁ i x₁ - Function.update f₂ i x₂


theorem geometric_hahn_banach_open_point (hs₁ : Convex ℝ s) (hs₂ : IsOpen s) (disj : x ∉ s) :
    ∃ f : E →L[ℝ] ℝ, ∀ a ∈ s, f a < f x

{E : Type u_2}
[TopologicalSpace E]
[AddCommGroup E]
[TopologicalAddGroup E]
[Module ℝ E]
[ContinuousSMul ℝ E]
{s : Set E}
{x : E}
(hs₁ : Convex ℝ s)
(hs₂ : IsOpen s)
(disj : x ∉ s)


@[simp]
theorem ofLeftInverse'_apply {g : S → R} {f : R →ₙ+* S} (h : Function.LeftInverse g f) (x : R) :
    ↑(ofLeftInverse' h x) = f x

{R : Type u}
{S : Type v}
[NonUnitalRing R]
[NonUnitalRing S]
{g : S → R}
{f : R →ₙ+* S}
(h : Function.LeftInverse g ⇑f)
(x : R)


@[simp, reassoc]
theorem pullbackP1Iso_inv_snd (i : 𝒰.J) :
    (pullbackP1Iso 𝒰 f g i).inv ≫ pullback.snd _ _ = pullback.fst _ _

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

(AlgebraicGeometry.Scheme.Pullback.pullbackP1Iso 𝒰 f g i).inv ≫
    CategoryTheory.Limits.pullback.snd (AlgebraicGeometry.Scheme.Pullback.p1 𝒰 f g) (𝒰.map i) =
  CategoryTheory.Limits.pullback.fst (𝒰.map i ≫ f) g


theorem coeFn_neg (f : Lp E p μ) : ⇑(-f) =ᵐ[μ] -f

{α : Type u_1}
{E : Type u_2}
{m0 : MeasurableSpace α}
{p : ℝ≥0∞}
{μ : MeasureTheory.Measure α}
[NormedAddCommGroup E]
(f : ↥(MeasureTheory.Lp E p μ))


theorem image_subset_infs_right : a ∈ s → (a ⊓ ·) '' t ⊆ s ⊼ t

{α : Type u_2}
[SemilatticeInf α]
{s t : Set α}
{a : α}


theorem BilinForm.toMatrix_basisFun :
    BilinForm.toMatrix (Pi.basisFun R₂ n) = BilinForm.toMatrix'

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

BilinForm.toMatrix (Pi.basisFun R₂ n) = LinearMap.BilinForm.toMatrix'


@[deprecated disintegrate (since := "2024-07-26")]
lemma compProd_fst_condKernelUnitBorel (κ : Kernel Unit (α × Ω)) [IsFiniteKernel κ] :
    fst κ ⊗ₖ condKernelUnitBorel κ = κ

(κ : ProbabilityTheory.Kernel Unit (α × Ω))


@[deprecated getElem_append_right (since := "2024-06-12")]
theorem get_append_right (as bs : List α) (h : ¬ i < as.length) {h' h''} : (as ++ bs).get ⟨i, h'⟩ = bs.get ⟨i - as.length, h''⟩

{α : Type u_1}
{i : Nat}
(as bs : List α)
(h : ¬i < as.length)
{h' : i < (as ++ bs).length}
{h'' : i - as.length < bs.length}


theorem measure_iUnionNotConvergentSeq (hε : 0 < ε) (hf : ∀ n, StronglyMeasurable (f n))
    (hg : StronglyMeasurable g) (hsm : MeasurableSet s) (hs : μ s ≠ ∞)
    (hfg : ∀ᵐ x ∂μ, x ∈ s → Tendsto (fun n => f n x) atTop (𝓝 (g x))) :
    μ (iUnionNotConvergentSeq hε hf hg hsm hs hfg) ≤ ENNReal.ofReal ε

{f : ι → α → β}

(hf : ∀ (n : ι), MeasureTheory.StronglyMeasurable (f n))

(hg : MeasureTheory.StronglyMeasurable g)

(hfg : ∀ᵐ (x : α) ∂μ, x ∈ s → Filter.Tendsto (fun n => f n x) Filter.atTop (𝓝 (g x)))

μ (MeasureTheory.Egorov.iUnionNotConvergentSeq hε hf hg hsm hs hfg) ≤ ENNReal.ofReal ε


/-- Upgrading `PiTensorProduct.map` to a `MonoidHom` when `s = t`. -/
@[simps]
def mapMonoidHom : (Π i, s i →ₗ[R] s i) →* ((⨂[R] i, s i) →ₗ[R] ⨂[R] i, s i)

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

PiTensorProduct.mapMonoidHom f = PiTensorProduct.map f


@[to_additive]
theorem inv_injective : Function.Injective (Inv.inv : G → G)


lemma odd_two_mul_add_one (a : α) : Odd (2 * a + 1)


theorem nonnegg_cases_left {c d} {b : ℕ} {a : ℤ} (h : ∀ x : ℕ, a = -x → SqLe x d b c) :
    Nonnegg c d a b

(h : ∀ (x : ℕ), a = -↑x → Zsqrtd.SqLe x d b c)


@[to_additive]
theorem _root_.Multiset.periodic_prod [Add α] [CommMonoid β] (s : Multiset (α → β))
    (hs : ∀ f ∈ s, Periodic f c) : Periodic s.prod c

{α : Type u_1}
{β : Type u_2}
{c : α}
[Add α]
[CommMonoid β]
(s : Multiset (α → β))
(hs : ∀ f ∈ s, Function.Periodic f c)


theorem indexOf_append_of_not_mem {a : α} (h : a ∉ l₁) :
    indexOf a (l₁ ++ l₂) = l₁.length + indexOf a l₂

{α : Type u}
{l₁ l₂ : List α}
[DecidableEq α]
{a : α}
(h : ¬a ∈ l₁)

List.indexOf a (l₁ ++ l₂) = l₁.length + List.indexOf a l₂


@[simp]
theorem mul_left_apply_same (b : n) (M : Matrix n n α) :
    (stdBasisMatrix i j c * M) i b = c * M j b

{n : Type u_3}
{α : Type u_5}
[DecidableEq n]
[Semiring α]
(i j : n)
(c : α)
[Fintype n]
(b : n)
(M : Matrix n n α)

(Matrix.stdBasisMatrix i j c * M) i b = c * M j b


@[simp] theorem congr_tmul (f : M ≃ₗ[A] P) (g : N ≃ₗ[R] Q) (m : M) (n : N) :
    congr f g (m ⊗ₜ n) = f m ⊗ₜ g n

{R : Type uR}
{A : Type uA}
{M : Type uM}
{N : Type uN}
{P : Type uP}
{Q : Type uQ}
[CommSemiring R]
[Semiring A]
[Algebra R A]
[AddCommMonoid M]
[Module R M]
[Module A M]
[IsScalarTower R A M]
[AddCommMonoid N]
[Module R N]
[AddCommMonoid P]
[Module R P]
[Module A P]
[IsScalarTower R A P]
[AddCommMonoid Q]
[Module R Q]
(f : M ≃ₗ[A] P)
(g : N ≃ₗ[R] Q)
(m : M)
(n : N)

(TensorProduct.AlgebraTensorModule.congr f g) (m ⊗ₜ[R] n) = f m ⊗ₜ[R] g n


@[to_additive]
theorem mem_mul {x : α} : x ∈ s * t ↔ ∃ y ∈ s, ∃ z ∈ t, y * z = x

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


@[to_additive (attr := fun_prop) sub]
theorem ContinuousAt.div' {f g : α → G} {x : α} (hf : ContinuousAt f x) (hg : ContinuousAt g x) :
    ContinuousAt (fun x => f x / g x) x

{G : Type w}
{α : Type u}
[TopologicalSpace G]
[Sub G]
[ContinuousSub G]
[TopologicalSpace α]
{f g : α → G}
{x : α}
(hf : ContinuousAt f x)
(hg : ContinuousAt g x)


/-- `le_of_add_le_add_left` is normally applicable to `OrderedCancelAddCommMonoid`,
but it holds for measures with the additional assumption that μ is finite. -/
theorem Measure.le_of_add_le_add_left [IsFiniteMeasure μ] (A2 : μ + ν₁ ≤ μ + ν₂) : ν₁ ≤ ν₂

{α : Type u_1}
{m0 : MeasurableSpace α}
{μ ν₁ ν₂ : MeasureTheory.Measure α}
[MeasureTheory.IsFiniteMeasure μ]
(A2 : μ + ν₁ ≤ μ + ν₂)


@[to_additive]
theorem MonoidHomClass.isometry_iff_norm [MonoidHomClass 𝓕 E F] (f : 𝓕) :
    Isometry f ↔ ∀ x, ‖f x‖ = ‖x‖

{𝓕 : Type u_1}
{E : Type u_3}
{F : Type u_4}
[SeminormedGroup E]
[SeminormedGroup F]
[FunLike 𝓕 E F]
[MonoidHomClass 𝓕 E F]
(f : 𝓕)


/-- Uniform convergence on a set `s` to a constant function is equivalent to convergence in
`p ×ˢ 𝓟 s`. -/
theorem tendsto_prod_principal_iff {c : β} :
    Tendsto (↿F) (p ×ˢ 𝓟 s) (𝓝 c) ↔ TendstoUniformlyOn F (fun _ => c) p s

{α : Type u}
{β : Type v}
{ι : Type x}
[UniformSpace β]
{F : ι → α → β}
{s : Set α}
{p : Filter ι}
{c : β}

Filter.Tendsto (↿F) (p ×ˢ 𝓟 s) (𝓝 c) ↔ TendstoUniformlyOn F (fun x => c) p s


/-- A family of equivalences `Π a, β₁ a ≃ β₂ a` generates an equivalence between `Σ' a, β₁ a` and
`Σ' a, β₂ a`. -/
@[simps apply]
def psigmaCongrRight {β₁ β₂ : α → Sort*} (F : ∀ a, β₁ a ≃ β₂ a) : (Σ' a, β₁ a) ≃ Σ' a, β₂ a

{α : Sort u}
{β₁ : α → Sort u_1}
{β₂ : α → Sort u_2}
(F : (a : α) → β₁ a ≃ β₂ a)
(a : (a : α) ×' β₁ a)

(Equiv.psigmaCongrRight F) a = ⟨a.fst, (F a.fst) a.snd⟩


theorem coeff_C_ne_zero (h : n ≠ 0) : (C a).coeff n = 0

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


@[simp]
lemma le_mul_iff_one_le_left [MulPosMono α] [MulPosReflectLE α] (a0 : 0 < a) : a ≤ b * a ↔ 1 ≤ b

{α : Type u_1}
{a b : α}
[MulOneClass α]
[Zero α]
[Preorder α]
[MulPosMono α]
[MulPosReflectLE α]
(a0 : 0 < a)


@[simp]
theorem flipₗᵢ'_symm : (flipₗᵢ' E F G σ₂₃ σ₁₃).symm = flipₗᵢ' F E G σ₁₃ σ₂₃

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

(ContinuousLinearMap.flipₗᵢ' E F G σ₂₃ σ₁₃).symm = ContinuousLinearMap.flipₗᵢ' F E G σ₁₃ σ₂₃


@[simp]
theorem coe_compAlternatingMap (g : N →ₗ[R] N₂) (f : M [⋀^ι]→ₗ[R] N) :
    ⇑(g.compAlternatingMap f) = g ∘ f

{R : Type u_1}
[Semiring R]
{M : Type u_2}
[AddCommMonoid M]
[Module R M]
{N : Type u_3}
[AddCommMonoid N]
[Module R N]
{ι : Type u_7}
{N₂ : Type u_10}
[AddCommMonoid N₂]
[Module R N₂]
(g : N →ₗ[R] N₂)
(f : M [⋀^ι]→ₗ[R] N)


theorem tendsto_dist_right_cocompact_atTop [ProperSpace α] (x : α) :
    Tendsto (dist · x) (cocompact α) atTop

{α : Type u}
[PseudoMetricSpace α]
[ProperSpace α]
(x : α)

Filter.Tendsto (fun x_1 => dist x_1 x) (Filter.cocompact α) Filter.atTop


@[to_additive]
theorem mul_inv_self (a : G) : a * a⁻¹ = 1


lemma eq_zero_of_double_le (h : 2 * n ≤ n) : n = 0


@[simp]
theorem zero_apply (x) : (0 : Poly α) x = 0


/-- Face of a box in `ℝⁿ⁺¹ = Fin (n + 1) → ℝ`: the box in `ℝⁿ = Fin n → ℝ` with corners at
`I.lower ∘ Fin.succAbove i` and `I.upper ∘ Fin.succAbove i`. -/
@[simps (config := { simpRhs := true })]
def face {n} (I : Box (Fin (n + 1))) (i : Fin (n + 1)) : Box (Fin n)

{n : ℕ}
(I : BoxIntegral.Box (Fin (n + 1)))
(i : Fin (n + 1))

∀ (a : Fin n), (I.face i).upper a = I.upper (i.succAbove a)


/-- `DomMulAct.mk` as a homeomorphism. -/
@[to_additive (attr := simps toEquiv) "`DomAddAct.mk` as a homeomorphism"]
def mkHomeomorph : M ≃ₜ Mᵈᵐᵃ


theorem le_def [FaithfulSMul M X] (P Q : { P : M // IsLprojection X P }) :
    P ≤ Q ↔ (P : M) = ↑(P ⊓ Q)

{X : Type u_1}
[NormedAddCommGroup X]
{M : Type u_2}
[Ring M]
[Module M X]
[FaithfulSMul M X]
(P Q : { P // IsLprojection X P })


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

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

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


/-- The angle between the negation of a vector and another vector. -/
theorem angle_neg_left (x y : V) : angle (-x) y = π - angle x y

{V : Type u_1}
[NormedAddCommGroup V]
[InnerProductSpace ℝ V]
(x y : V)

InnerProductGeometry.angle (-x) y = π - InnerProductGeometry.angle x y


theorem inter_biInter {ι α : Type*} {s : Set ι} (hs : s.Nonempty) (f : ι → Set α) (t : Set α) :
    ⋂ i ∈ s, t ∩ f i = t ∩ ⋂ i ∈ s, f i

{ι : Type u_11}
{α : Type u_12}
{s : Set ι}
(hs : s.Nonempty)
(f : ι → Set α)
(t : Set α)


theorem val_comp_inclusion (h : s ⊆ t) : Subtype.val ∘ inclusion h = Subtype.val

{α : Type u_1}
{s t : Set α}
(h : s ⊆ t)

Subtype.val ∘ Set.inclusion h = Subtype.val


@[to_additive Iic_add_Iic_subset]
theorem Iic_mul_Iic_subset' (a b : α) : Iic a * Iic b ⊆ Iic (a * b)

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

[CovariantClass α α (Function.swap HAdd.hAdd) LE.le]


@[to_additive (attr := simp)]
theorem subgroupOf_map_subtype (H K : Subgroup G) : (H.subgroupOf K).map K.subtype = H ⊓ K

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

AddSubgroup.map K.subtype (H.addSubgroupOf K) = H ⊓ K


theorem support_eq_symm_image :
    support f = (extChartAt I c).symm '' (ball (extChartAt I c c) f.rOut ∩ range I)

{E : Type uE}
[NormedAddCommGroup E]
[NormedSpace ℝ E]
[FiniteDimensional ℝ E]
{H : Type uH}
[TopologicalSpace H]
{I : ModelWithCorners ℝ E H}
{M : Type uM}
[TopologicalSpace M]
[ChartedSpace H M]
{c : M}
(f : SmoothBumpFunction I c)

Function.support ↑f = ↑(extChartAt I c).symm '' (Metric.ball (↑(extChartAt I c) c) f.rOut ∩ Set.range ↑I)


@[simp] lemma map_base_iff (M : Matroid α) (f : α → β) (hf) {B : Set β} :
    (M.map f hf).Base B ↔ ∃ B₀, M.Base B₀ ∧ B = f '' B₀

{α : Type u_1}
{β : Type u_2}
(M : Matroid α)
(f : α → β)
(hf : Set.InjOn f M.E)
{B : Set β}


theorem sInter_eq_compl_sUnion_compl (S : Set (Set α)) : ⋂₀ S = (⋃₀(compl '' S))ᶜ


/-- **Equational criterion for vanishing**
[A. Altman and S. Kleiman, *A term of commutative algebra* (Lemma 8.16)][altman2021term],
forward direction, generalization.

Assume that the submodule $M' \subseteq M$ generated by the $m_i$
satisfies the property that the map $M' \otimes N \to M \otimes N$ is injective. If the expression
$\sum_i m_i \otimes n_i$ vanishes, then it vanishes trivially. -/
theorem vanishesTrivially_of_sum_tmul_eq_zero_of_rTensor_injective
    (hm : Injective (rTensor N (span R (Set.range m)).subtype))
    (hmn : ∑ i, m i ⊗ₜ n i = (0 : M ⊗[R] N)) : VanishesTrivially R m n

(hm : Function.Injective ⇑(LinearMap.rTensor N (Submodule.span R (Set.range m)).subtype))


theorem length_sym2 {xs : List α} : xs.sym2.length = Nat.choose (xs.length + 1) 2

xs.sym2.length = (xs.length + 1).choose 2


@[simp]
protected theorem one_lt_inv : 1 < a⁻¹ ↔ a < 1


@[to_additive (attr := simp)]
theorem univ_mul_univ [Fintype α] : (univ : Finset α) * univ = univ

{α : Type u_2}
[DecidableEq α]
[Monoid α]
[Fintype α]


theorem eventually_filterAt_subset_closedBall (x : α) {ε : ℝ} (hε : 0 < ε) :
    ∀ᶠ a : Set α in v.filterAt x, a ⊆ closedBall x ε

{α : Type u_1}
[MetricSpace α]
{m0 : MeasurableSpace α}
{μ : MeasureTheory.Measure α}
(v : VitaliFamily μ)
(x : α)
{ε : ℝ}
(hε : 0 < ε)

∀ᶠ (a : Set α) in v.filterAt x, a ⊆ Metric.closedBall x ε


/-- A morphism of monads is a natural transformation compatible with η and μ. -/
@[ext]
structure MonadHom (T₁ T₂ : Monad C) extends NatTrans (T₁ : C ⥤ C) T₂ where
  app_η : ∀ X, T₁.η.app X ≫ app X = T₂.η.app X := by aesop_cat
  app_μ : ∀ X, T₁.μ.app X ≫ app X = (T₁.map (app X) ≫ app _) ≫ T₂.μ.app X := by
    aesop_cat

{C : Type u₁}
[CategoryTheory.Category.{v₁, u₁} C]
{T₁ T₂ : CategoryTheory.Monad C}
(self : CategoryTheory.MonadHom T₁ T₂)
(X : C)

CategoryTheory.CategoryStruct.comp (T₁.η.app X) (self.app X) = T₂.η.app X


theorem Filter.EventuallyEq.deriv_eq (hL : f₁ =ᶠ[𝓝 x] f) : deriv f₁ x = deriv f x

{𝕜 : Type u}
[NontriviallyNormedField 𝕜]
{F : Type v}
[NormedAddCommGroup F]
[NormedSpace 𝕜 F]
{f f₁ : 𝕜 → F}
{x : 𝕜}
(hL : f₁ =ᶠ[𝓝 x] f)


@[reassoc (attr := simp)]
lemma ι₁_desc : ι₁ K ≫ desc φ₀ φ₁ h = φ₁

[∀ (i : ι), CategoryTheory.Limits.HasBinaryBiproduct (K.X i) (K.X i)]

[HomologicalComplex.HasHomotopyCofiber (CategoryTheory.Limits.biprod.lift (𝟙 K) (-𝟙 K))]

(φ₀ φ₁ : K ⟶ F)

HomologicalComplex.cylinder.ι₁ K ≫ HomologicalComplex.cylinder.desc φ₀ φ₁ h = φ₁


@[simp]
theorem sign_finRotate (n : ℕ) : Perm.sign (finRotate (n + 1)) = (-1) ^ n

Equiv.Perm.sign (finRotate (n + 1)) = (-1) ^ n


@[simp] theorem count_true (n : ℕ) : count (fun _ ↦ True) n = n


/-- A bimodule object for a pair of monoid objects, all internal to some monoidal category. -/
structure Bimod (A B : Mon_ C) where
  X : C
  actLeft : A.X ⊗ X ⟶ X
  one_actLeft : (A.one ▷ X) ≫ actLeft = (λ_ X).hom := by aesop_cat
  left_assoc :
    (A.mul ▷ X) ≫ actLeft = (α_ A.X A.X X).hom ≫ (A.X ◁ actLeft) ≫ actLeft := by aesop_cat
  actRight : X ⊗ B.X ⟶ X
  actRight_one : (X ◁ B.one) ≫ actRight = (ρ_ X).hom := by aesop_cat
  right_assoc :
    (X ◁ B.mul) ≫ actRight = (α_ X B.X B.X).inv ≫ (actRight ▷ B.X) ≫ actRight := by
    aesop_cat
  middle_assoc :
    (actLeft ▷ B.X) ≫ actRight = (α_ A.X X B.X).hom ≫ (A.X ◁ actRight) ≫ actLeft := by
    aesop_cat

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

self.X ◁ B.one ≫ self.actRight = (ρ_ self.X).hom


/-- Two equivalent partial equivs have coinciding inverses on the target. -/
theorem EqOnSource.symm_eqOn {e e' : PartialEquiv α β} (h : e ≈ e') :
    EqOn e.symm e'.symm e.target

{α : Type u_1}
{β : Type u_2}
{e e' : PartialEquiv α β}
(h : e ≈ e')


@[to_additive]
theorem le_closure_toSubmonoid (S : Set G) : Submonoid.closure S ≤ (closure S).toSubmonoid

AddSubmonoid.closure S ≤ (AddSubgroup.closure S).toAddSubmonoid


theorem symm_apply_mem_iff (h : e.IsImage s t) : ∀ ⦃y⦄, y ∈ e.target → (e.symm y ∈ s ↔ y ∈ t)

{α : Type u_1}
{β : Type u_2}
{e : PartialEquiv α β}
{s : Set α}
{t : Set β}
(h : e.IsImage s t)
⦃y : β⦄


theorem comap_smul (f : V →ₗ[K] V₂) (p : Submodule K V₂) (a : K) (h : a ≠ 0) :
    p.comap (a • f) = p.comap f

{K : Type u_9}
{V : Type u_10}
{V₂ : Type u_11}
[Semifield K]
[AddCommMonoid V]
[Module K V]
[AddCommMonoid V₂]
[Module K V₂]
(f : V →ₗ[K] V₂)
(p : Submodule K V₂)
(a : K)
(h : a ≠ 0)

Submodule.comap (a • f) p = Submodule.comap f p


/-- The image of a submonoid under a monoid hom is a submonoid of the codomain. -/
@[to_additive
      "The image of an `AddSubmonoid` under an `AddMonoid` hom is an `AddSubmonoid` of the
      codomain."]
theorem IsSubmonoid.image {γ : Type*} [Monoid γ] {f : M → γ} (hf : IsMonoidHom f) {s : Set M}
    (hs : IsSubmonoid s) : IsSubmonoid (f '' s)

{M : Type u_1}
[AddMonoid M]
{γ : Type u_3}
[AddMonoid γ]
{f : M → γ}
(hf : IsAddMonoidHom f)
{s : Set M}
(hs : IsAddSubmonoid s)


theorem inv_pow_le_inv_pow_of_le (a1 : 1 ≤ a) {m n : ℕ} (mn : m ≤ n) : (a ^ n)⁻¹ ≤ (a ^ m)⁻¹

{α : Type u_2}
[LinearOrderedSemifield α]
{a : α}
(a1 : 1 ≤ a)
{m n : ℕ}
(mn : m ≤ n)


theorem ωSup_def (c : Chain (α →𝒄 β)) (x : α) : ωSup c x = ContinuousHom.ωSup c x

(c : OmegaCompletePartialOrder.Chain (α →𝒄 β))

(OmegaCompletePartialOrder.ωSup c) x = (OmegaCompletePartialOrder.ContinuousHom.ωSup c) x


lemma sInf_eq_zero_iff {s : Set Cardinal} : sInf s = 0 ↔ s = ∅ ∨ ∃ a ∈ s, a = 0


lemma zeroLocus_singleton {U : X.Opens} (f : Γ(X, U)) :
    X.zeroLocus {f} = (X.basicOpen f).carrierᶜ

(X : AlgebraicGeometry.Scheme)
{U : X.Opens}
(f : ↑(X.presheaf.obj (Opposite.op U)))


@[symm]
protected theorem IsFormalAdjoint.symm (h : T.IsFormalAdjoint S) :
    S.IsFormalAdjoint T

{𝕜 : Type u_1}
{E : Type u_2}
{F : Type u_3}
[RCLike 𝕜]
[NormedAddCommGroup E]
[InnerProductSpace 𝕜 E]
[NormedAddCommGroup F]
[InnerProductSpace 𝕜 F]
{T : E →ₗ.[𝕜] F}
{S : F →ₗ.[𝕜] E}
(h : T.IsFormalAdjoint S)


/-- The continuous homomorphism given by inversion. -/
@[to_additive (attr := simps!) "The continuous homomorphism given by negation."]
def inv : ContinuousMonoidHom E E

(E : Type u_6)
[CommGroup E]
[TopologicalSpace E]
[TopologicalGroup E]

∀ (a : E), (ContinuousMonoidHom.inv E) a = a⁻¹


/-- A map to the vertex of a cone induces a cone by composition. -/
@[simps]
def extend (c : Cone F) {X : C} (f : X ⟶ c.pt) : Cone F

{J : Type u₁}
[CategoryTheory.Category.{v₁, u₁} J]
{C : Type u₃}
[CategoryTheory.Category.{v₃, u₃} C]
{F : J ⥤ C}
(c : CategoryTheory.Limits.Cone F)
{X : C}
(f : X ⟶ c.pt)


/-- If `h : X → Y` is a homeomorphism, `h(s)` is path-connected iff `s` is. -/
@[simp]
theorem Homeomorph.isPathConnected_image {s : Set X} (h : X ≃ₜ Y) :
    IsPathConnected (h '' s) ↔ IsPathConnected s

{X : Type u_1}
{Y : Type u_2}
[TopologicalSpace X]
[TopologicalSpace Y]
{s : Set X}
(h : X ≃ₜ Y)

IsPathConnected (⇑h '' s) ↔ IsPathConnected s


/-- The isomorphism between the short complex attached to
two isomorphic distinguished triangles. -/
@[simps!]
def shortComplexOfDistTriangleIsoOfIso {T T' : Triangle C} (e : T ≅ T') (hT : T ∈ distTriang C) :
    shortComplexOfDistTriangle T hT ≅ shortComplexOfDistTriangle T'
      (isomorphic_distinguished _ hT _ e.symm)

[∀ (n : ℤ), (CategoryTheory.shiftFunctor C n).Additive]

{T T' : CategoryTheory.Pretriangulated.Triangle C}

(hT : T ∈ CategoryTheory.Pretriangulated.distinguishedTriangles)

(CategoryTheory.Pretriangulated.shortComplexOfDistTriangleIsoOfIso e hT).hom.τ₁ = e.hom.hom₁


@[to_additive]
theorem one_def : (1 : S) = ⟨1, S.one_mem⟩

{M : Type u_1}
[AddZeroClass M]
(S : AddSubmonoid M)


@[to_additive]
theorem inv_def [∀ i, Inv <| f i] : x⁻¹ = fun i => (x i)⁻¹

{I : Type u}
{f : I → Type v₁}
(x : (i : I) → f i)
[(i : I) → Neg (f i)]


lemma map_truncatedInf (e : α ≃o β) (s : Finset α) (a : α) :
    e (truncatedInf s a) = truncatedInf (s.map e.toEquiv.toEmbedding) (e a)

{α : Type u_1}
{β : Type u_2}
[SemilatticeInf α]
[BoundedOrder α]
[DecidableRel fun x x_1 => x ≤ x_1]
[SemilatticeInf β]
[BoundedOrder β]
[DecidableRel fun x x_1 => x ≤ x_1]
(e : α ≃o β)
(s : Finset α)
(a : α)

e (s.truncatedInf a) = (Finset.map e.toEmbedding s).truncatedInf (e a)


theorem tan_nonneg_of_nonneg_of_le_pi_div_two {x : ℝ} (h0x : 0 ≤ x) (hxp : x ≤ π / 2) : 0 ≤ tan x

{x : ℝ}
(h0x : 0 ≤ x)
(hxp : x ≤ Real.pi / 2)


@[to_additive (attr := simp)]
theorem Red.step_invRev_iff :
    Red.Step (FreeGroup.invRev L₁) (FreeGroup.invRev L₂) ↔ Red.Step L₁ L₂

FreeGroup.Red.Step (FreeGroup.invRev L₁) (FreeGroup.invRev L₂) ↔ FreeGroup.Red.Step L₁ L₂


{A : Type u_1}
{M : Type u_3}
[AddMonoid A]
[Monoid M]
{ψ : AddChar A M}

ψ ≠ 1 ↔ ∃ x, ψ x ≠ 1


lemma toNatHom_apply (n : ℕ) : toNatHom n = toNat n


{𝕜 : Type u_1}
{A : Type u_2}
[NontriviallyNormedField 𝕜]
[NonUnitalNormedRing A]
[NormedSpace 𝕜 A]
[SMulCommClass 𝕜 A A]
[IsScalarTower 𝕜 A A]


@[simp]
theorem join_map_ret (s : WSeq α) : join (map ret s) ~ʷ s

(Stream'.WSeq.map Stream'.WSeq.ret s).join ~ʷ s


@[to_additive (attr := aesop safe 20 apply (rule_sets := [Measurable]))]
theorem AEMeasurable.div' [MeasurableDiv₂ G] (hf : AEMeasurable f μ) (hg : AEMeasurable g μ) :
    AEMeasurable (f / g) μ

{G : Type u_2}
{α : Type u_3}
[MeasurableSpace G]
[Div G]
{m : MeasurableSpace α}
{f g : α → G}
{μ : MeasureTheory.Measure α}
[MeasurableDiv₂ G]
(hf : AEMeasurable f μ)
(hg : AEMeasurable g μ)


lemma trace_eq_trace_restrict_of_le_idealizer
    (hy' : ∀ m ∈ N, (φ x ∘ₗ φ y) m ∈ N := fun m _ ↦ N.lie_mem (N.mem_idealizer.mp (h hy) m)) :
    trace R M (φ x ∘ₗ φ y) = trace R N ((φ x ∘ₗ φ y).restrict hy')

(hy' : ∀ m ∈ N, (φ x ∘ₗ φ y) m ∈ N := ⋯)

(LinearMap.trace R M) (φ x ∘ₗ φ y) = (LinearMap.trace R ↥↑N) ((φ x ∘ₗ φ y).restrict hy')


theorem vecMul_diagonal [Fintype m] [DecidableEq m] (v w : m → α) (x : m) :
    (v ᵥ* diagonal w) x = v x * w x

{m : Type u_2}
{α : Type v}
[NonUnitalNonAssocSemiring α]
[Fintype m]
[DecidableEq m]
(v w : m → α)
(x : m)


/-- Rewrite `ContinuousLinearMap.inCoordinates` in a `VectorBundleCore`. -/
protected theorem _root_.VectorBundleCore.inCoordinates_eq {ι ι'} (Z : VectorBundleCore 𝕜₁ B F ι)
    (Z' : VectorBundleCore 𝕜₂ B' F' ι') {x₀ x : B} {y₀ y : B'} (ϕ : F →SL[σ] F')
    (hx : x ∈ Z.baseSet (Z.indexAt x₀)) (hy : y ∈ Z'.baseSet (Z'.indexAt y₀)) :
    inCoordinates F Z.Fiber F' Z'.Fiber x₀ x y₀ y ϕ =
      (Z'.coordChange (Z'.indexAt y) (Z'.indexAt y₀) y).comp
        (ϕ.comp <| Z.coordChange (Z.indexAt x₀) (Z.indexAt x) x)

{B : Type u_2}
{F : Type u_3}
[NormedAddCommGroup F]
[TopologicalSpace B]
{𝕜₁ : Type u_5}
{𝕜₂ : Type u_6}
[NontriviallyNormedField 𝕜₁]
[NontriviallyNormedField 𝕜₂]
{σ : 𝕜₁ →+* 𝕜₂}
{B' : Type u_7}
[TopologicalSpace B']
[NormedSpace 𝕜₁ F]
{F' : Type u_8}
[NormedAddCommGroup F']
[NormedSpace 𝕜₂ F']
{ι : Type u_10}
{ι' : Type u_11}
(Z : VectorBundleCore 𝕜₁ B F ι)
(Z' : VectorBundleCore 𝕜₂ B' F' ι')
{x₀ x : B}
{y₀ y : B'}
(ϕ : F →SL[σ] F')
(hx : x ∈ Z.baseSet (Z.indexAt x₀))
(hy : y ∈ Z'.baseSet (Z'.indexAt y₀))

ContinuousLinearMap.inCoordinates F Z.Fiber F' Z'.Fiber x₀ x y₀ y ϕ =
  (Z'.coordChange (Z'.indexAt y) (Z'.indexAt y₀) y).comp (ϕ.comp (Z.coordChange (Z.indexAt x₀) (Z.indexAt x) x))


@[simp]
theorem covBy_add_one (z : ℤ) : z ⋖ z + 1


/-- The hypotheses also imply that `G` is final, see `final_of_comp_full_faithful'`. -/
theorem final_of_comp_full_faithful [Full G] [Faithful G] [Final (F ⋙ G)] : Final F

{C : Type u₁}
[CategoryTheory.Category.{v₁, u₁} C]
{D : Type u₂}
[CategoryTheory.Category.{v₂, u₂} D]
{E : Type u₃}
[CategoryTheory.Category.{v₃, u₃} E]
(F : CategoryTheory.Functor C D)
(G : CategoryTheory.Functor D E)
[G.Full]
[G.Faithful]
[(F.comp G).Final]


@[simp]
theorem map_le_map_iff {f : α → β} (hf : Function.Injective f) {s t : Multiset α} :
    s.map f ≤ t.map f ↔ s ≤ t

{α : Type u_1}
{β : Type v}
{f : α → β}
(hf : Function.Injective f)
{s t : Multiset α}

Multiset.map f s ≤ Multiset.map f t ↔ s ≤ t


@[simp]
theorem mapEquiv_symm [CommSemiring S₁] [CommSemiring S₂] (e : S₁ ≃+* S₂) :
    (mapEquiv σ e).symm = mapEquiv σ e.symm

{S₁ : Type v}
{S₂ : Type w}
(σ : Type u_1)
[CommSemiring S₁]
[CommSemiring S₂]
(e : S₁ ≃+* S₂)

(MvPolynomial.mapEquiv σ e).symm = MvPolynomial.mapEquiv σ e.symm


/-- The `Kleisli` category of a `Control.Monad` is equivalent to the `Kleisli` category of its
category-theoretic version, provided the monad is lawful.
-/
@[simps]
def eq : KleisliCat m ≌ Kleisli (ofTypeMonad m)

(m : Type u → Type u)
[Monad m]
[LawfulMonad m]

∀ {X Y : CategoryTheory.Kleisli (CategoryTheory.ofTypeMonad m)} (f : X ⟶ Y) (a : X),
  (CategoryTheory.eq m).inverse.map f a = f a


@[to_additive (attr := simp)]
theorem prod_replicate (n : ℕ) (a : α) : (replicate n a).prod = a ^ n

{α : Type u_3}
[CommMonoid α]
(n : ℕ)
(a : α)


theorem eval_whiskerRight
    {η η' : f ⟶ g} {θ : f ⊗ h ⟶ g ⊗ h}
    (pf_η : η = η') (pf_θ : η' ▷ h = θ) :
    η ▷ h = θ

{θ : CategoryTheory.MonoidalCategory.tensorObj f h ⟶ CategoryTheory.MonoidalCategory.tensorObj g h}

(pf_θ : CategoryTheory.MonoidalCategory.whiskerRight η' h = θ)

CategoryTheory.MonoidalCategory.whiskerRight η h = θ


@[to_additive (attr := continuity, fun_prop)]
theorem continuous_mk_symm : Continuous (@mk M).symm


lemma evalLatticeHom_apply (i : ι) (f : ∀ i, α i) : evalLatticeHom i f = f i

{ι : Type u_7}
{α : ι → Type u_8}
[(i : ι) → Lattice (α i)]
(i : ι)
(f : (i : ι) → α i)


theorem one_rmatch_iff (x : List α) : rmatch 1 x ↔ x = []

{α : Type u_1}
[dec : DecidableEq α]
(x : List α)

RegularExpression.rmatch 1 x = true ↔ x = []


@[refl]
theorem BlankRel.refl {Γ} [Inhabited Γ] (l : List Γ) : BlankRel l l

{Γ : Type u_1}
[Inhabited Γ]
(l : List Γ)


/-- Dividing by an element is the same as multiplying by its inverse.

This is a duplicate of `DivInvMonoid.div_eq_mul_inv` ensuring that the types unfold better.
-/
@[to_additive "Subtracting an element is the same as adding by its negative.
This is a duplicate of `SubNegMonoid.sub_eq_mul_neg` ensuring that the types unfold better."]
theorem div_eq_mul_inv (a b : G) : a / b = a * b⁻¹

{G : Type u_1}
[SubNegMonoid G]
(a b : G)


/-- `Fin.castAdd` as an `OrderEmbedding`.

`castAddEmb m i` embeds `i : Fin n` in `Fin (n+m)`. See also `Fin.natAddEmb` and `Fin.addNatEmb`. -/
@[simps! apply toEmbedding]
def castAddOrderEmb (m) : Fin n ↪o Fin (n + m)

∀ (a : Fin n), (Fin.castAddOrderEmb m) a = Fin.castAdd m a


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


@[simp]
theorem Colimit.ι_map_apply' {F G : J ⥤ Type v} (α : F ⟶ G) (j : J) (x) :
    colim.map α (colimit.ι F j x) = colimit.ι G j (α.app j x)

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

CategoryTheory.Limits.colim.map α (CategoryTheory.Limits.colimit.ι F j x) =
  CategoryTheory.Limits.colimit.ι G j (α.app j x)


theorem strictConvex_Iic (r : β) : StrictConvex 𝕜 (Iic r)

{𝕜 : Type u_1}
{β : Type u_5}
[OrderedSemiring 𝕜]
[TopologicalSpace β]
[LinearOrderedCancelAddCommMonoid β]
[OrderTopology β]
[Module 𝕜 β]
[OrderedSMul 𝕜 β]
(r : β)


theorem StableUnderBaseChange.snd {P : MorphismProperty C} (hP : StableUnderBaseChange P)
    {X Y S : C} (f : X ⟶ S) (g : Y ⟶ S) [HasPullback f g] (H : P f) :
    P (pullback.snd f g)

{C : Type u}
[CategoryTheory.Category.{v, u} C]
{P : CategoryTheory.MorphismProperty C}
(hP : P.StableUnderBaseChange)
{X Y S : C}
(f : X ⟶ S)
(g : Y ⟶ S)
[CategoryTheory.Limits.HasPullback f g]
(H : P f)

P (CategoryTheory.Limits.pullback.snd f g)


theorem rpow_sub {x : ℝ≥0} (hx : x ≠ 0) (y z : ℝ) : x ^ (y - z) = x ^ y / x ^ z


@[simp]
theorem equivQuotient_index_apply (x : α) : hs.equivQuotient (hs.index x) = hs.proj x

{ι : Type u_1}
{α : Type u_2}
{s : ι → Set α}
(hs : IndexedPartition s)
(x : α)


theorem list_append : Computable₂ ((· ++ ·) : List α → List α → List α)


lemma zero_le_mk {x : PGame.{u}} {hx} : 0 ≤ mk x hx ↔ 0 ≤ x


@[simp] theorem smul_const {lc : LinearCombo} {i : Int} : (i * lc).const = i * lc.const


@[simp]
theorem coe_pmap {p : α → Prop} (f : ∀ a, p a → β) (l : List α) (H : ∀ a ∈ l, p a) :
    pmap f l H = l.pmap f H

{α : Type u_1}
{β : Type v}
{p : α → Prop}
(f : (a : α) → p a → β)
(l : List α)
(H : ∀ a ∈ l, p a)

Multiset.pmap f (↑l) H = ↑(List.pmap f l H)


protected theorem sub_eq_zero_iff_le {a b : Ordinal} : a - b = 0 ↔ a ≤ b


/-- Continuity from below: the measure of the union of an increasing sequence of (not necessarily
measurable) sets is the limit of the measures. -/
theorem tendsto_measure_iUnion [Preorder ι] [IsDirected ι (· ≤ ·)] [Countable ι]
    {s : ι → Set α} (hm : Monotone s) : Tendsto (μ ∘ s) atTop (𝓝 (μ (⋃ n, s n)))

{α : Type u_1}
{ι : Type u_5}
{m : MeasurableSpace α}
{μ : MeasureTheory.Measure α}
[Preorder ι]
[IsDirected ι fun x x_1 => x ≤ x_1]
[Countable ι]
{s : ι → Set α}
(hm : Monotone s)

Filter.Tendsto (⇑μ ∘ s) Filter.atTop (nhds (μ (⋃ n, s n)))


@[continuity, fun_prop]
theorem Continuous.codRestrict {f : X → Y} {s : Set Y} (hf : Continuous f) (hs : ∀ a, f a ∈ s) :
    Continuous (s.codRestrict f hs)

{X : Type u}
{Y : Type v}
[TopologicalSpace X]
[TopologicalSpace Y]
{f : X → Y}
{s : Set Y}
(hf : Continuous f)
(hs : ∀ (a : X), f a ∈ s)


theorem map_add (f : E →ₗ.[R] F) (x y : f.domain) : f (x + y) = f x + f y

{R : Type u_1}
[Ring R]
{E : Type u_2}
[AddCommGroup E]
[Module R E]
{F : Type u_3}
[AddCommGroup F]
[Module R F]
(f : E →ₗ.[R] F)
(x y : ↥f.domain)


@[simp, norm_cast]
lemma MonoidHom.coe_toAdditive'' [AddZeroClass α] [MulOneClass β] (f : Multiplicative α →* β) :
    ⇑(toAdditive'' f) = ofMul ∘ f ∘ ofAdd

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

⇑(MonoidHom.toAdditive'' f) = ⇑Additive.ofMul ∘ ⇑f ∘ ⇑Multiplicative.ofAdd


@[to_additive Ioi_add_Ici_subset]
theorem Ioi_mul_Ici_subset' [LocallyFiniteOrderTop α] (a b : α) : Ioi a * Ici b ⊆ Ioi (a * b)

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

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

Finset.Ioi a + Finset.Ici b ⊆ Finset.Ioi (a + b)


@[simp]
theorem rank_submatrix [Fintype m] (A : Matrix m m R) (e₁ e₂ : n ≃ m) :
    rank (A.submatrix e₁ e₂) = rank A

{m : Type u_2}
{n : Type u_3}
{R : Type u_5}
[Fintype n]
[CommRing R]
[Fintype m]
(A : Matrix m m R)
(e₁ e₂ : n ≃ m)


@[fun_prop]
theorem ContinuousOn.fst {f : α → β × γ} {s : Set α} (hf : ContinuousOn f s) :
    ContinuousOn (fun x => (f x).1) s

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


/-- A closed ball is closed in the weak-* topology. We don't have a name for `E →SL[σ] F` with
weak-* topology in `mathlib`, so we use an equivalent condition (see `isClosed_induced_iff'`). -/
theorem is_weak_closed_closedBall (f₀ : E' →SL[σ₁₂] F) (r : ℝ) ⦃f : E' →SL[σ₁₂] F⦄
    (hf : ⇑f ∈ closure (((↑) : (E' →SL[σ₁₂] F) → E' → F) '' closedBall f₀ r)) :
    f ∈ closedBall f₀ r

{σ₁₂ : 𝕜 →+* 𝕜₂}

(hf : ⇑f ∈ closure (DFunLike.coe '' Metric.closedBall f₀ r))


theorem ediam_range : EMetric.diam (range f) = EMetric.diam (univ : Set P)

{𝕜 : Type u_1}
{V : Type u_2}
{V₂ : Type u_5}
{P : Type u_10}
{P₂ : Type u_11}
[NormedField 𝕜]
[SeminormedAddCommGroup V]
[NormedSpace 𝕜 V]
[PseudoMetricSpace P]
[NormedAddTorsor V P]
[SeminormedAddCommGroup V₂]
[NormedSpace 𝕜 V₂]
[PseudoMetricSpace P₂]
[NormedAddTorsor V₂ P₂]
(f : P →ᵃⁱ[𝕜] P₂)

EMetric.diam (Set.range ⇑f) = EMetric.diam Set.univ


theorem nonpos_of_mul_nonpos_right [PosMulStrictMono α]
    (h : a * b ≤ 0) (ha : 0 < a) : b ≤ 0

{α : Type u}
[Semiring α]
[LinearOrder α]
{a b : α}
[PosMulStrictMono α]
(h : a * b ≤ 0)
(ha : 0 < a)


protected theorem one_ne_zero : 1 ≠ (0 : Nat)


/-- The iterated derivative of a function multiplied by `(L v ⬝) ^ n` can be controlled in terms
of the iterated derivatives of the initial function. -/
lemma norm_iteratedFDeriv_fourierPowSMulRight
    {f : V → E} {K : ℕ∞} {C : ℝ} (hf : ContDiff ℝ K f) {n : ℕ} {k : ℕ} (hk : k ≤ K)
    {v : V} (hv : ∀ i ≤ k, ∀ j ≤ n, ‖v‖ ^ j * ‖iteratedFDeriv ℝ i f v‖ ≤ C) :
    ‖iteratedFDeriv ℝ k (fun v ↦ fourierPowSMulRight L f v n) v‖ ≤
      (2 * π) ^ n * (2 * n + 2) ^ k * ‖L‖ ^ n * C

‖iteratedFDeriv ℝ k (fun v => VectorFourier.fourierPowSMulRight L f v n) v‖ ≤
  (2 * π) ^ n * (2 * ↑n + 2) ^ k * ‖L‖ ^ n * C


/-- If a point of `Spec R[x]` is not contained in the vanishing set of `f`, then its image in
`Spec R` is contained in the open set where at least one of the coefficients of `f` is non-zero.
This lemma is a reformulation of `exists_C_coeff_not_mem`. -/
theorem comap_C_mem_imageOfDf {I : PrimeSpectrum R[X]}
    (H : I ∈ (zeroLocus {f} : Set (PrimeSpectrum R[X]))ᶜ) :
    PrimeSpectrum.comap (Polynomial.C : R →+* R[X]) I ∈ imageOfDf f

(H : I ∈ (PrimeSpectrum.zeroLocus {f})ᶜ)

(PrimeSpectrum.comap Polynomial.C) I ∈ AlgebraicGeometry.Polynomial.imageOfDf f


theorem rtakeWhile_idempotent (p : α → Bool) (l : List α) :
    rtakeWhile p (rtakeWhile p l) = rtakeWhile p l

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

List.rtakeWhile p (List.rtakeWhile p l) = List.rtakeWhile p l


lemma AnalyticWithinOn.prod {f : E → F} {g : E → G} {s : Set E}
    (hf : AnalyticWithinOn 𝕜 f s) (hg : AnalyticWithinOn 𝕜 g s) :
    AnalyticWithinOn 𝕜 (fun x ↦ (f x, g x)) s

{𝕜 : Type u_2}
[NontriviallyNormedField 𝕜]
{E : Type u_3}
{F : Type u_4}
{G : Type u_5}
[NormedAddCommGroup E]
[NormedSpace 𝕜 E]
[NormedAddCommGroup F]
[NormedSpace 𝕜 F]
[NormedAddCommGroup G]
[NormedSpace 𝕜 G]
{f : E → F}
{g : E → G}
{s : Set E}
(hf : AnalyticWithinOn 𝕜 f s)
(hg : AnalyticWithinOn 𝕜 g s)

AnalyticWithinOn 𝕜 (fun x => (f x, g x)) s


protected theorem map_smul [Module R E₂] (f : E →ₗᵢ[R] E₂) (c : R) (x : E) : f (c • x) = c • f x

{R : Type u_1}
{E : Type u_5}
{E₂ : Type u_6}
[Semiring R]
[SeminormedAddCommGroup E]
[SeminormedAddCommGroup E₂]
[Module R E]
[Module R E₂]
(f : E →ₗᵢ[R] E₂)
(c : R)
(x : E)


theorem IsCompact.closure_eq_biUnion_inseparable {K : Set X} (hK : IsCompact K) :
    closure K = ⋃ x ∈ K, {y | Inseparable x y}

{X : Type u_1}
[TopologicalSpace X]
[R1Space X]
{K : Set X}
(hK : IsCompact K)


theorem smulTower_leftMulMatrix_algebraMap (x : S) :
    leftMulMatrix (b.smulTower c) (algebraMap _ _ x) = blockDiagonal fun _ ↦ leftMulMatrix b x

{R : Type u_1}
{S : Type u_2}
{T : Type u_3}
[CommRing R]
[CommRing S]
[Ring T]
[Algebra R S]
[Algebra S T]
[Algebra R T]
[IsScalarTower R S T]
{m : Type u_4}
{n : Type u_5}
[Fintype m]
[Fintype n]
[DecidableEq m]
[DecidableEq n]
(b : Basis m R S)
(c : Basis n S T)
(x : S)

(Algebra.leftMulMatrix (b.smulTower c)) ((algebraMap S T) x) =
  Matrix.blockDiagonal fun x_1 => (Algebra.leftMulMatrix b) x


@[simp]
theorem SL_slash (γ : SL(2, ℤ)) : f ∣[k] γ = f ∣[k] (γ : GL(2, ℝ)⁺)


@[simp]
theorem sum_obj_inr (F : A ⥤ B) (G : C ⥤ D) (c : C) : (F.sum G).obj (inr c) = inr (G.obj c)

{A : Type u₁}
[CategoryTheory.Category.{v₁, u₁} A]
{B : Type u₁}
[CategoryTheory.Category.{v₁, u₁} B]
{C : Type u₁}
[CategoryTheory.Category.{v₁, u₁} C]
{D : Type u₁}
[CategoryTheory.Category.{v₁, u₁} D]
(F : CategoryTheory.Functor A B)
(G : CategoryTheory.Functor C D)
(c : C)

(F.sum G).obj (Sum.inr c) = Sum.inr (G.obj c)


theorem span_singleton_sup_orthogonal_eq_top {B : BilinForm K V} {x : V} (hx : ¬B.IsOrtho x x) :
    (K ∙ x) ⊔ B.orthogonal (K ∙ x) = ⊤

{V : Type u_5}
{K : Type u_6}
[Field K]
[AddCommGroup V]
[Module K V]
{B : LinearMap.BilinForm K V}
{x : V}
(hx : ¬B.IsOrtho x x)

Submodule.span K {x} ⊔ B.orthogonal (Submodule.span K {x}) = ⊤


/-- Given `R`-modules `A, B` with comultiplication maps `Δ_A, Δ_B` and counit maps
`ε_A, ε_B`, an `R`-coalgebra homomorphism `A →ₗc[R] B` is an `R`-linear map `f` such that
`ε_B ∘ f = ε_A` and `(f ⊗ f) ∘ Δ_A = Δ_B ∘ f`. -/
structure CoalgHom (R A B : Type*) [CommSemiring R]
    [AddCommMonoid A] [Module R A] [AddCommMonoid B] [Module R B]
    [CoalgebraStruct R A] [CoalgebraStruct R B] extends A →ₗ[R] B where
  counit_comp : counit ∘ₗ toLinearMap = counit
  map_comp_comul : TensorProduct.map toLinearMap toLinearMap ∘ₗ comul = comul ∘ₗ toLinearMap

{R : Type u_1}
{A : Type u_2}
{B : Type u_3}
[CommSemiring R]
[AddCommMonoid A]
[Module R A]
[AddCommMonoid B]
[Module R B]
[CoalgebraStruct R A]
[CoalgebraStruct R B]
(self : A →ₗc[R] B)

Coalgebra.counit ∘ₗ self.toLinearMap = Coalgebra.counit


@[simp]
theorem toDual_lt_toDual_iff {a b : WithTop α} : WithTop.toDual a < WithTop.toDual b ↔ b < a


/-- The set of points of a face. -/
@[simp]
theorem range_face_points {n : ℕ} (s : Simplex k P n) {fs : Finset (Fin (n + 1))} {m : ℕ}
    (h : fs.card = m + 1) : Set.range (s.face h).points = s.points '' ↑fs

{k : Type u_1}
{V : Type u_2}
{P : Type u_3}
[Ring k]
[AddCommGroup V]
[Module k V]
[AffineSpace V P]
{n : ℕ}
(s : Affine.Simplex k P n)
{fs : Finset (Fin (n + 1))}
{m : ℕ}
(h : fs.card = m + 1)


/-- `c.toUnder` is a lift of `c` under the forgetful functor. -/
@[simps!]
def Cone.mapConeToUnder {F : J ⥤ C} (c : Cone F) : (Under.forget c.pt).mapCone c.toUnder ≅ c

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

c.mapConeToUnder.hom.hom = CategoryTheory.CategoryStruct.id c.pt


theorem ack_succ_right_le_ack_succ_left (m n : ℕ) : ack m (n + 1) ≤ ack (m + 1) n


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

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

(F.mapHomotopyEquiv h).homotopyInvHomId = ⋯.mpr (⋯.mpr (F.mapHomotopy h.homotopyInvHomId))


theorem msb_zeroExtend (x : BitVec w) : (x.zeroExtend v).msb = (decide (0 < v) && x.getLsb (v - 1))

(BitVec.zeroExtend v x).msb = (decide (0 < v) && x.getLsb (v - 1))


@[simp]
theorem comp_hom {X Y Z : Core C} (f : X ⟶ Y) (g : Y ⟶ Z) : (f ≫ g).hom = f.hom ≫ g.hom

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

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


theorem associated_one_of_associated_mul_one [CommMonoid α] {a b : α} : a * b ~ᵤ 1 → a ~ᵤ 1


theorem iInf_neBot_iff_of_directed' {f : ι → Filter α} [Nonempty ι] (hd : Directed (· ≥ ·) f) :
    NeBot (iInf f) ↔ ∀ i, NeBot (f i)

(hd : Directed (fun x x_1 => x ≥ x_1) f)


theorem negSucc_coe' (n : Nat) : -[n+1] = -↑n - 1


theorem WCovBy.wcovBy_iff_le (hab : a ⩿ b) : b ⩿ a ↔ b ≤ a

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


@[simp]
theorem _root_.LinearIsometryEquiv.piLpCongrLeft_symm (e : ι ≃ ι') :
    (LinearIsometryEquiv.piLpCongrLeft p 𝕜 E e).symm =
      LinearIsometryEquiv.piLpCongrLeft p 𝕜 E e.symm

{p : ℝ≥0∞}
{𝕜 : Type u_1}
{ι : Type u_2}
[Fact (1 ≤ p)]
[Fintype ι]
[Semiring 𝕜]
{ι' : Type u_5}
[Fintype ι']
{E : Type u_6}
[SeminormedAddCommGroup E]
[Module 𝕜 E]
(e : ι ≃ ι')


/-- The cardinal of the general linear group over a finite field. -/
theorem card_GL_field :
    Nat.card (GL (Fin n) 𝔽) = ∏ i : (Fin n), (q ^ n - q ^ ( i : ℕ ))

{𝔽 : Type u_1}
[Field 𝔽]
[Fintype 𝔽]
(n : ℕ)

Nat.card (GL (Fin n) 𝔽) = ∏ i : Fin n, (Fintype.card 𝔽 ^ n - Fintype.card 𝔽 ^ ↑i)


/-- If `K` is an uncountable algebraically closed field, then its
cardinality is the same as that of a transcendence basis. -/
theorem cardinal_eq_cardinal_transcendence_basis_of_aleph0_lt [Nontrivial R]
    (hv : IsTranscendenceBasis R v) (hR : #R ≤ ℵ₀) (hK : ℵ₀ < #K) : #K = #ι

{R K : Type u}
[CommRing R]
[Field K]
[Algebra R K]
[IsAlgClosed K]
{ι : Type u}
(v : ι → K)
[Nontrivial R]
(hv : IsTranscendenceBasis R v)
(hR : #R ≤ ℵ₀)
(hK : ℵ₀ < #K)


theorem two_cos : 2 * cos x = exp (x * I) + exp (-x * I)

2 * Complex.cos x = Complex.exp (x * Complex.I) + Complex.exp (-x * Complex.I)


@[simp]
lemma commutator_coe_linear_map : ↑⁅D1, D2⁆ = ⁅(D1 : Module.End R L), (D2 : Module.End R L)⁆

{R : Type u_1}
{L : Type u_2}
[CommRing R]
[LieRing L]
[LieAlgebra R L]
{D1 D2 : LieDerivation R L L}


protected theorem iff_le_add_mul {f : α → ℝ} {K : ℝ≥0} :
    LipschitzOnWith K f s ↔ ∀ x ∈ s, ∀ y ∈ s, f x ≤ f y + K * dist x y

{α : Type u}
[PseudoMetricSpace α]
{s : Set α}
{f : α → ℝ}
{K : ℝ≥0}

LipschitzOnWith K f s ↔ ∀ x ∈ s, ∀ y ∈ s, f x ≤ f y + ↑K * dist x y


theorem IsSymmOp.flip_eq (op) [IsSymmOp α β op] : flip op = op

{α : Sort u_1}
{β : Sort u_2}
(op : α → α → β)
[IsSymmOp α β op]


@[simp]
theorem mk_neg : (mk (-x) : M ⧸ p) = -(mk x : M ⧸ p)

{R : Type u_1}
{M : Type u_2}
{x : M}
[Ring R]
[AddCommGroup M]
[Module R M]
(p : Submodule R M)

Submodule.Quotient.mk (-x) = -Submodule.Quotient.mk x


@[to_additive]
theorem map_ne_zero_iff_ne_one : f x ≠ 0 ↔ x ≠ 1

{F : Type u_2}
{α : Type u_3}
{β : Type u_4}
[FunLike F α β]
[AddGroup α]
[OrderedAddCommMonoid β]
[AddGroupNormClass F α β]
(f : F)
{x : α}


theorem Exact.split_tfae' (h : Function.Exact f g) :
    List.TFAE [
      Function.Injective f ∧ ∃ l, g ∘ₗ l = LinearMap.id,
      Function.Surjective g ∧ ∃ l, l ∘ₗ f = LinearMap.id,
      ∃ e : N ≃ₗ[R] M × P, f = e.symm ∘ₗ LinearMap.inl R M P ∧ g = LinearMap.snd R M P ∘ₗ e]

{R : Type u_1}
{M : Type u_2}
{N : Type u_4}
{P : Type u_6}
[Semiring R]
[AddCommGroup M]
[AddCommGroup N]
[AddCommGroup P]
[Module R M]
[Module R N]
[Module R P]
{f : M →ₗ[R] N}
{g : N →ₗ[R] P}
(h : Function.Exact ⇑f ⇑g)

[Function.Injective ⇑f ∧ ∃ l, g ∘ₗ l = LinearMap.id, Function.Surjective ⇑g ∧ ∃ l, l ∘ₗ f = LinearMap.id,
    ∃ e, f = ↑e.symm ∘ₗ LinearMap.inl R M P ∧ g = LinearMap.snd R M P ∘ₗ ↑e].TFAE


@[simp]
theorem realize_inf : (φ ⊓ ψ).Realize v ↔ φ.Realize v ∧ ψ.Realize v

{L : FirstOrder.Language}
{M : Type w}
[L.Structure M]
{α : Type u'}
{φ ψ : L.Formula α}
{v : α → M}


@[to_additive]
theorem map_zpow' [DivInvMonoid G] [DivInvMonoid H] [MonoidHomClass F G H]
    (f : F) (hf : ∀ x : G, f x⁻¹ = (f x)⁻¹) (a : G) : ∀ n : ℤ, f (a ^ n) = f a ^ n

{G : Type u_7}
{H : Type u_8}
{F : Type u_9}
[FunLike F G H]
[SubNegMonoid G]
[SubNegMonoid H]
[AddMonoidHomClass F G H]
(f : F)
(hf : ∀ (x : G), f (-x) = -f x)
(a : G)
(n : ℤ)


@[reassoc]
lemma shiftFunctorAdd'_assoc_hom_app (a₁ a₂ a₃ a₁₂ a₂₃ a₁₂₃ : A)
    (h₁₂ : a₁ + a₂ = a₁₂) (h₂₃ : a₂ + a₃ = a₂₃) (h₁₂₃ : a₁ + a₂ + a₃ = a₁₂₃) (X : C) :
    (shiftFunctorAdd' C a₁₂ a₃ a₁₂₃ (by rw [← h₁₂, h₁₂₃])).hom.app X ≫
      ((shiftFunctorAdd' C a₁ a₂ a₁₂ h₁₂).hom.app X)⟦a₃⟧' =
    (shiftFunctorAdd' C a₁ a₂₃ a₁₂₃ (by rw [← h₂₃, ← add_assoc, h₁₂₃])).hom.app X ≫
      (shiftFunctorAdd' C a₂ a₃ a₂₃ h₂₃).hom.app (X⟦a₁⟧)

{C : Type u}
{A : Type u_1}
[CategoryTheory.Category.{v, u} C]
[AddMonoid A]
[CategoryTheory.HasShift C A]
(a₁ a₂ a₃ a₁₂ a₂₃ a₁₂₃ : A)
(h₁₂ : a₁ + a₂ = a₁₂)
(h₂₃ : a₂ + a₃ = a₂₃)
(h₁₂₃ : a₁ + a₂ + a₃ = a₁₂₃)
(X : C)

CategoryTheory.CategoryStruct.comp ((CategoryTheory.shiftFunctorAdd' C a₁₂ a₃ a₁₂₃ ⋯).hom.app X)
    ((CategoryTheory.shiftFunctor C a₃).map ((CategoryTheory.shiftFunctorAdd' C a₁ a₂ a₁₂ h₁₂).hom.app X)) =
  CategoryTheory.CategoryStruct.comp ((CategoryTheory.shiftFunctorAdd' C a₁ a₂₃ a₁₂₃ ⋯).hom.app X)
    ((CategoryTheory.shiftFunctorAdd' C a₂ a₃ a₂₃ h₂₃).hom.app ((CategoryTheory.shiftFunctor C a₁).obj X))


@[simp] theorem next'_eq (s : String) (p : Pos) (h) : next' s p h = next s p

(s : String)
(p : String.Pos)
(h : ¬s.atEnd p = true)


theorem Monic.geom_sum' {P : R[X]} (hP : P.Monic) (hdeg : 0 < P.degree) {n : ℕ} (hn : n ≠ 0) :
    (∑ i ∈ range n, P ^ i).Monic

{R : Type u}
[Semiring R]
{P : R[X]}
(hP : P.Monic)
(hdeg : 0 < P.degree)
{n : ℕ}
(hn : n ≠ 0)


theorem infinitePos_def {x : ℝ*} : InfinitePos x ↔ ∀ r : ℝ, ↑r < x


@[simp]
theorem Fintype.range_total :
    LinearMap.range (Fintype.total R S v) = Submodule.span R (Set.range v)

{α : Type u_1}
{M : Type u_2}
(R : Type u_3)
[Fintype α]
[Semiring R]
[AddCommMonoid M]
[Module R M]
{S : Type u_4}
[Semiring S]
[Module S M]
[SMulCommClass R S M]
(v : α → M)

LinearMap.range ((Fintype.total R S) v) = Submodule.span R (Set.range v)


@[to_additive (attr := simp)]
theorem pow_period_add_smul (n : ℕ) (m : M) (a : α) :
    m ^ (period m a + n) • a = m ^ n • a

{α : Type v}
{M : Type u}
[AddMonoid M]
[AddAction M α]
(n : ℕ)
(m : M)
(a : α)

(AddAction.period m a + n) • m +ᵥ a = n • m +ᵥ a


lemma tendsto_density_fst_atTop_ae_of_monotone [IsFiniteKernel κ]
    (a : α) (seq : ℕ → Set β) (hseq : Monotone seq) (hseq_iUnion : ⋃ i, seq i = univ)
    (hseq_meas : ∀ m, MeasurableSet (seq m)) :
    ∀ᵐ x ∂(fst κ a), Tendsto (fun m ↦ density κ (fst κ) a x (seq m)) atTop (𝓝 1)

{κ : ProbabilityTheory.Kernel α (γ × β)}

(hseq_meas : ∀ (m : ℕ), MeasurableSet (seq m))

∀ᵐ (x : γ) ∂κ.fst a, Filter.Tendsto (fun m => κ.density κ.fst a x (seq m)) Filter.atTop (𝓝 1)


@[reassoc]
theorem additiveObjIsoBiproduct_naturality (F : Mat_ C ⥤ D) [Functor.Additive F] {M N : Mat_ C}
    (f : M ⟶ N) :
    F.map f ≫ (additiveObjIsoBiproduct F N).hom =
      (additiveObjIsoBiproduct F M).hom ≫
        biproduct.matrix fun i j => F.map ((embedding C).map (f i j))

F.map f ≫ (CategoryTheory.Mat_.additiveObjIsoBiproduct F N).hom =
  (CategoryTheory.Mat_.additiveObjIsoBiproduct F M).hom ≫
    CategoryTheory.Limits.biproduct.matrix fun i j => F.map ((CategoryTheory.Mat_.embedding C).map (f i j))


theorem normalize_eq_mk' (n : Int) (d : Nat) (h : d ≠ 0) (c : Nat.gcd (Int.natAbs n) d = 1) :
    normalize n d h = mk' n d h c

(n : ℤ)
(d : ℕ)
(h : d ≠ 0)
(c : n.natAbs.gcd d = 1)

Rat.normalize n d h = { num := n, den := d, den_nz := h, reduced := c }


lemma addXYZ_of_Z_eq_zero_right {P Q : Fin 3 → R} (hQ : W'.Equation Q) (hQz : Q z = 0) :
    W'.addXYZ P Q = -(Q x * P z) • P

{R : Type u}
[CommRing R]
{W' : WeierstrassCurve.Jacobian R}
{P Q : Fin 3 → R}
(hQ : W'.Equation Q)
(hQz : Q z = 0)


theorem top_factors {A B : C} (f : A ⟶ B) : (⊤ : Subobject B).Factors f

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


@[simp]
theorem isometryEquivMap.coe_apply (φ : P₁' →ᵃⁱ[𝕜] P₂) (E : AffineSubspace 𝕜 P₁') [Nonempty E]
    (g : E) : ↑(E.isometryEquivMap φ g) = φ g

{𝕜 : Type u_1}
{V₁' : Type u_4}
{V₂ : Type u_5}
{P₁' : Type u_9}
{P₂ : Type u_11}
[NormedField 𝕜]
[SeminormedAddCommGroup V₁']
[NormedSpace 𝕜 V₁']
[MetricSpace P₁']
[NormedAddTorsor V₁' P₁']
[SeminormedAddCommGroup V₂]
[NormedSpace 𝕜 V₂]
[PseudoMetricSpace P₂]
[NormedAddTorsor V₂ P₂]
(φ : P₁' →ᵃⁱ[𝕜] P₂)
(E : AffineSubspace 𝕜 P₁')
[Nonempty ↥E]
(g : ↥E)

↑((AffineSubspace.isometryEquivMap φ E) g) = φ ↑g


/-- The projection from a fiber bundle with a nonempty fiber to its base is a surjective
map. -/
theorem surjective_proj [Nonempty F] : Function.Surjective (π F E)

[TopologicalSpace (Bundle.TotalSpace F E)]


@[simp]
lemma PrelaxFunctor.map₂_eqToHom (F : PrelaxFunctor B C) {a b : B} {f g : a ⟶ b} (h : f = g) :
    F.map₂ (eqToHom h) = eqToHom (F.congr_map h)

{B : Type u₁}
[CategoryTheory.Bicategory B]
{C : Type u₂}
[CategoryTheory.Bicategory C]
(F : CategoryTheory.PrelaxFunctor B C)
{a b : B}
{f g : a ⟶ b}
(h : f = g)

F.map₂ (CategoryTheory.eqToHom h) = CategoryTheory.eqToHom ⋯


theorem mem_inv_pointwise_smul_iff {a : α} {S : Submonoid M} {x : M} : x ∈ a⁻¹ • S ↔ a • x ∈ S

{α : Type u_1}
{M : Type u_3}
[Monoid M]
[Group α]
[MulDistribMulAction α M]
{a : α}
{S : Submonoid M}
{x : M}

x ∈ a⁻¹ • S ↔ a • x ∈ S


theorem get?_mem {l : List α} {n a} (e : l.get? n = some a) : a ∈ l

{α : Type u_1}
{l : List α}
{n : Nat}
{a : α}
(e : l.get? n = some a)


@[to_additive]
theorem tprod_mul_tprod_compl {s : Set β} (hs : Multipliable (f ∘ (↑) : s → α))
    (hsc : Multipliable (f ∘ (↑) : ↑sᶜ → α)) : (∏' x : s, f x) * ∏' x : ↑sᶜ, f x = ∏' x, f x

{α : Type u_1}
{β : Type u_2}
[AddCommMonoid α]
[TopologicalSpace α]
{f : β → α}
[T2Space α]
[ContinuousAdd α]
{s : Set β}
(hs : Summable (f ∘ Subtype.val))
(hsc : Summable (f ∘ Subtype.val))

∑' (x : ↑s), f ↑x + ∑' (x : ↑sᶜ), f ↑x = ∑' (x : β), f x


@[simp] lemma map_fst_le_of_subset_toEnumFinset {s : Finset (α × ℕ)} (hsm : s ⊆ m.toEnumFinset) :
    s.1.map Prod.fst ≤ m

{α : Type u_1}
[DecidableEq α]
{m : Multiset α}
{s : Finset (α × ℕ)}
(hsm : s ⊆ m.toEnumFinset)


theorem map_sup (hf : LeftOrdContinuous f) (x y : α) : f (x ⊔ y) = f x ⊔ f y

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


theorem mem_closure_iff {s : Set K} {x} :
    x ∈ closure s ↔ ∃ y ∈ Subring.closure s, ∃ z ∈ Subring.closure s, y / z = x

{K : Type u}
[Field K]
{s : Set K}
{x : K}

x ∈ Subfield.closure s ↔ ∃ y ∈ Subring.closure s, ∃ z ∈ Subring.closure s, y / z = x


lemma mem_segment_iff_wbtw {x y z : V} : y ∈ segment R x z ↔ Wbtw R x y z

{R : Type u_1}
{V : Type u_2}
[OrderedRing R]
[AddCommGroup V]
[Module R V]
{x y z : V}


@[reassoc]
lemma comp_liftCycles {A' : C} (α : A' ⟶ A) :
    α ≫ S.liftCycles k hk = S.liftCycles (α ≫ k) (by rw [assoc, hk, comp_zero])

(hk : CategoryTheory.CategoryStruct.comp k S.g = 0)

CategoryTheory.CategoryStruct.comp α (S.liftCycles k hk) = S.liftCycles (CategoryTheory.CategoryStruct.comp α k) ⋯


theorem integrable_stoppedProcess [LocallyFiniteOrderBot ι] (hτ : IsStoppingTime ℱ τ)
    (hu : ∀ n, Integrable (u n) μ) (n : ι) : Integrable (stoppedProcess u τ n) μ

(hu : ∀ (n : ι), MeasureTheory.Integrable (u n) μ)

MeasureTheory.Integrable (MeasureTheory.stoppedProcess u τ n) μ


lemma IsEquipartition.card_biUnion_offDiag_le (hε : 0 < ε) (hP : P.IsEquipartition)
    (hP' : 4 / ε ≤ P.parts.card) : (P.parts.biUnion offDiag).card ≤ ε / 2 * A.card ^ 2

{α : Type u_1}
{𝕜 : Type u_2}
[LinearOrderedField 𝕜]
[DecidableEq α]
{A : Finset α}
{P : Finpartition A}
{ε : 𝕜}
(hε : 0 < ε)
(hP : P.IsEquipartition)
(hP' : 4 / ε ≤ ↑P.parts.card)

↑(P.parts.biUnion Finset.offDiag).card ≤ ε / 2 * ↑A.card ^ 2


@[to_additive]
theorem _root_.hasCompactMulSupport_iff_eventuallyEq :
    HasCompactMulSupport f ↔ f =ᶠ[coclosedCompact α] 1

{α : Type u_2}
{β : Type u_4}
[TopologicalSpace α]
[Zero β]
{f : α → β}

HasCompactSupport f ↔ f =ᶠ[Filter.coclosedCompact α] 0


protected lemma Monotone.sSup (hs : ∀ f ∈ s, Monotone f) : Monotone (sSup s)

{α : Type u_1}
{β : Type u_2}
[Preorder α]
[CompleteLattice β]
{s : Set (α → β)}
(hs : ∀ f ∈ s, Monotone f)


/-- Coercion to function `fun h : M ≃ₘ^n⟮I, I'⟯ M' ↦ (h : M → M')` is injective. -/
theorem coeFn_injective : Injective ((↑) : (M ≃ₘ^n⟮I, I'⟯ M') → (M → M'))

{𝕜 : Type u_1}
[NontriviallyNormedField 𝕜]
{E : Type u_2}
[NormedAddCommGroup E]
[NormedSpace 𝕜 E]
{E' : Type u_3}
[NormedAddCommGroup E']
[NormedSpace 𝕜 E']
{H : Type u_5}
[TopologicalSpace H]
{H' : Type u_6}
[TopologicalSpace H']
{I : ModelWithCorners 𝕜 E H}
{I' : ModelWithCorners 𝕜 E' H'}
{M : Type u_9}
[TopologicalSpace M]
[ChartedSpace H M]
{M' : Type u_10}
[TopologicalSpace M']
[ChartedSpace H' M']
{n : ℕ∞}


/-- A base change of a flat module is flat. -/
theorem isBaseChange [Module.Flat R M] (N : Type t) [AddCommGroup N] [Module R N] [Module S N]
    [IsScalarTower R S N] {f : M →ₗ[R] N} (h : IsBaseChange S f) :
    Module.Flat S N

(R : Type u)
(S : Type v)
(M : Type w)
[CommRing R]
[CommRing S]
[Algebra R S]
[AddCommGroup M]
[Module R M]
[Module.Flat R M]
(N : Type t)
[AddCommGroup N]
[Module R N]
[Module S N]
[IsScalarTower R S N]
{f : M →ₗ[R] N}
(h : IsBaseChange S f)


theorem rank_pos_iff_nontrivial : 0 < Module.rank R M ↔ Nontrivial M

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


@[simp]
lemma equivPolynomial_single {S : Type*} [CommRing S] [Algebra R S] (n : ℕ) (x : S) :
    equivPolynomial (single R n x) = monomial n x

{R : Type u_1}
[CommRing R]
{S : Type u_4}
[CommRing S]
[Algebra R S]
(n : ℕ)
(x : S)

PolynomialModule.equivPolynomial ((PolynomialModule.single R n) x) = (Polynomial.monomial n) x


/-- If an element `x` is a root of a nonzero polynomial `p`, then the degree of `p` is at least the
degree of the minimal polynomial of `x`. See also `minpoly.IsIntegrallyClosed.degree_le_of_ne_zero`
which relaxes the assumptions on `A` in exchange for stronger assumptions on `B`. -/
theorem degree_le_of_ne_zero {p : A[X]} (pnz : p ≠ 0) (hp : Polynomial.aeval x p = 0) :
    degree (minpoly A x) ≤ degree p

(A : Type u_1)
{B : Type u_2}
[Field A]
[Ring B]
[Algebra A B]
(x : B)
{p : A[X]}
(pnz : p ≠ 0)
(hp : (Polynomial.aeval x) p = 0)


lemma normalClosure_eq_iSup_adjoin_of_splits :
    normalClosure F K L = ⨆ x : K, IntermediateField.adjoin F ((minpoly F x).rootSet L)

(splits : ∀ (x : K), Polynomial.Splits (algebraMap F L) (minpoly F x))

normalClosure F K L = ⨆ x, IntermediateField.adjoin F ((minpoly F x).rootSet L)


theorem toSubring_subtype_eq_subtype (S : Subfield K) :
    S.toSubring.subtype = S.subtype

(K : Type u)
[DivisionRing K]
(S : Subfield K)


theorem supIndep_univ_bool (f : Bool → α) :
    (Finset.univ : Finset Bool).SupIndep f ↔ Disjoint (f false) (f true)

{α : Type u_1}
[Lattice α]
[OrderBot α]
(f : Bool → α)

Finset.univ.SupIndep f ↔ Disjoint (f false) (f true)


theorem card_fintypeIio : Fintype.card (Set.Iio b) = b


theorem edist_pi_le_iff [∀ b, EDist (π b)] {f g : ∀ b, π b} {d : ℝ≥0∞} :
    edist f g ≤ d ↔ ∀ b, edist (f b) (g b) ≤ d

{β : Type v}
{π : β → Type u_2}
[Fintype β]
[(b : β) → EDist (π b)]
{f g : (b : β) → π b}
{d : ℝ≥0∞}

edist f g ≤ d ↔ ∀ (b : β), edist (f b) (g b) ≤ d


@[to_additive (attr := simp)]
theorem range_subtype (s : Subsemigroup M) : (MulMemClass.subtype s).srange = s

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


theorem coe_eq_coe_fn : (DFunLike.coe (F := F)) = (fun f => ↑f)

{F : Sort u_1}
{α : Sort u_2}
{β : α → Sort u_3}
[i : DFunLike F α β]


theorem lowerBounds_Ioc {a b : γ} (hab : a < b) : lowerBounds (Ioc a b) = Iic a

{γ : Type w}
[SemilatticeSup γ]
[DenselyOrdered γ]
{a b : γ}
(hab : a < b)


theorem sub_lt_of_sub_lt (h₂ : c ≤ a) (h₃ : a ≠ ∞ ∨ b ≠ ∞) (h₁ : a - b < c) : a - c < b

{a b c : ℝ≥0∞}
(h₂ : c ≤ a)
(h₃ : a ≠ ⊤ ∨ b ≠ ⊤)
(h₁ : a - b < c)


@[simp]
theorem ofList_cons (a : α) (l : List α) : ofList (a::l) = cons a (ofList l)


theorem get?_iterate (f : α → α) (a : α) (n i : ℕ) (h : i < n) :
    get? (iterate f a n) i = f^[i] a

{α : Type u_1}
(f : α → α)
(a : α)
(n i : ℕ)
(h : i < n)

(List.iterate f a n).get? i = some (f^[i] a)


lemma preimage_val_image_val_eq_self : A ↓∩ ↑D = D


@[to_additive]
lemma piFinset_mul [∀ i, Mul (α i)] (s t : ∀ i, Finset (α i)) :
    piFinset (fun i ↦ s i * t i) = piFinset s * piFinset t

{ι : Type u_5}
{α : ι → Type u_6}
[Fintype ι]
[DecidableEq ι]
[(i : ι) → DecidableEq (α i)]
[(i : ι) → Add (α i)]
(s t : (i : ι) → Finset (α i))

(Fintype.piFinset fun i => s i + t i) = Fintype.piFinset s + Fintype.piFinset t


theorem of_isBigO_im_re_pow (hre : Tendsto re l atTop) (n : ℕ) (hr : im =O[l] fun z => z.re ^ n) :
    IsExpCmpFilter l

(hre : Filter.Tendsto Complex.re l Filter.atTop)

(hr : Complex.im =O[l] fun z => z.re ^ n)


@[measurability]
theorem measurableSet_blimsup {s : ℕ → Set α} {p : ℕ → Prop} (h : ∀ n, p n → MeasurableSet (s n)) :
    MeasurableSet <| blimsup s atTop p

(h : ∀ (n : ℕ), p n → MeasurableSet (s n))

MeasurableSet (Filter.blimsup s Filter.atTop p)


theorem IsPushout.IsVanKampen.flip {H : IsPushout f g h i} (H' : H.IsVanKampen) :
    H.flip.IsVanKampen

{C : Type u}
[CategoryTheory.Category.{v, u} C]
{W X Y Z : C}
{f : W ⟶ X}
{g : W ⟶ Y}
{h : X ⟶ Z}
{i : Y ⟶ Z}
{H : CategoryTheory.IsPushout f g h i}
(H' : H.IsVanKampen)


theorem snd_sInf [InfSet α] [InfSet β] (s : Set (α × β)) : (sInf s).snd = sInf (Prod.snd '' s)

{α : Type u_1}
{β : Type u_2}
[InfSet α]
[InfSet β]
(s : Set (α × β))


theorem equivPair_tail_eq_inv_smul {G : ι → Type*} [∀ i, Group (G i)]
    [∀i, DecidableEq (G i)] {i} (w : Word G) :
    (equivPair i w).tail = (of (equivPair i w).head)⁻¹ • w

{ι : Type u_1}
[DecidableEq ι]
{G : ι → Type u_4}
[(i : ι) → Group (G i)]
[(i : ι) → DecidableEq (G i)]
{i : ι}
(w : Monoid.CoprodI.Word G)

((Monoid.CoprodI.Word.equivPair i) w).tail = (Monoid.CoprodI.of ((Monoid.CoprodI.Word.equivPair i) w).head)⁻¹ • w


@[simp]
theorem embedding_mk_eq_of_isReal {φ : K →+* ℂ} (h : ComplexEmbedding.IsReal φ) :
    embedding (mk φ) = φ

(h : NumberField.ComplexEmbedding.IsReal φ)

(NumberField.InfinitePlace.mk φ).embedding = φ


theorem is_invariant_const (A : SL(2, ℤ)) (x : ℂ) :
    Function.const ℍ x ∣[(0 : ℤ)] A = Function.const ℍ x

Function.const ℍ x ∣[0] A = Function.const ℍ x


/-- The right inverse unitor `C ⥤ C × 1` -/
@[simps]
def rightInverseUnitor : C ⥤ C × Discrete (PUnit : Type w)

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

∀ {X Y : C} (f : X ⟶ Y),
  (CategoryTheory.prod.rightInverseUnitor C).map f = (f, 𝟙 ((fun X => (X, { as := PUnit.unit })) X).2)


theorem isSeparator_coprod_of_isSeparator_left (G H : C) [HasBinaryCoproduct G H]
    (hG : IsSeparator G) : IsSeparator (G ⨿ H)


/-- Construct an adjunction between `F` and `G` out of a natural bijection between each
`F.obj X ⟶ Y` and `X ⟶ G.obj Y`. -/
@[simps]
def mkOfHomEquiv (adj : CoreHomEquiv F G) : F ⊣ G

(adj : CategoryTheory.Adjunction.CoreHomEquiv F G)

(CategoryTheory.Adjunction.mkOfHomEquiv adj).unit.app X =
  (adj.homEquiv X (F.obj X)) (CategoryTheory.CategoryStruct.id (F.obj X))


theorem of_mul_t (b : B) :
    (of (b : G) : HNNExtension G A B φ) * t = t * of (φ.symm b : G)

{G : Type u_1}
[Group G]
{A B : Subgroup G}
{φ : ↥A ≃* ↥B}
(b : ↥B)

HNNExtension.of ↑b * HNNExtension.t = HNNExtension.t * HNNExtension.of ↑(φ.symm b)


@[simp]
theorem coe_contLinear (f : P →ᴬ[R] Q) : (f.contLinear : V → W) = f.linear

{R : Type u_2}
{V : Type u_3}
{W : Type u_4}
{P : Type u_6}
{Q : Type u_7}
[NormedAddCommGroup V]
[MetricSpace P]
[NormedAddTorsor V P]
[NormedAddCommGroup W]
[MetricSpace Q]
[NormedAddTorsor W Q]
[NormedField R]
[NormedSpace R V]
[NormedSpace R W]
(f : P →ᴬ[R] Q)


@[simp]
theorem zero_eq_nndist {x y : γ} : 0 = nndist x y ↔ x = y


@[to_additive]
theorem map_sup_comap_of_surjective (S T : Submonoid N) : (S.comap f ⊔ T.comap f).map f = S ⊔ T

{M : Type u_1}
{N : Type u_2}
[MulOneClass M]
[MulOneClass N]
{F : Type u_4}
[FunLike F M N]
[mc : MonoidHomClass F M N]
{f : F}
(hf : Function.Surjective ⇑f)
(S T : Submonoid N)

Submonoid.map f (Submonoid.comap f S ⊔ Submonoid.comap f T) = S ⊔ T


/-- Given a colimit cocone over `F ⋙ G` we can construct a colimit cocone over `G`. -/
@[simps]
def colimitCoconeOfComp (t : ColimitCocone (F ⋙ G)) : ColimitCocone G

(t : CategoryTheory.Limits.ColimitCocone (F.comp G))

(CategoryTheory.Functor.Final.colimitCoconeOfComp F t).cocone = CategoryTheory.Functor.Final.extendCocone.obj t.cocone


@[to_additive (attr := simp) Even.zsmul']
lemma Even.isSquare_zpow [Group α] {n : ℤ} : Even n → ∀ a : α, IsSquare (a ^ n)


protected theorem id_map {α : TypeVec n} (x : F α) : TypeVec.id <$$> x = x

{n : ℕ}
{F : TypeVec.{u} n → Type u_1}
[q : MvQPF F]
{α : TypeVec.{u} n}
(x : F α)


/-- This lemma is only intended as a helper for `Definable.image_comp`. -/
theorem Definable.image_comp_sum_inl_fin (m : ℕ) {s : Set (Sum α (Fin m) → M)}
    (h : A.Definable L s) : A.Definable L ((fun g : Sum α (Fin m) → M => g ∘ Sum.inl) '' s)

{M : Type w}
{A : Set M}
{L : FirstOrder.Language}
[L.Structure M]
{α : Type u₁}
(m : ℕ)
{s : Set (α ⊕ Fin m → M)}
(h : A.Definable L s)

A.Definable L ((fun g => g ∘ Sum.inl) '' s)


@[simp]
protected theorem star_apply (f : lp E p) (i : α) : star f i = star (f i)

{α : Type u_1}
{E : α → Type u_2}
{p : ℝ≥0∞}
[(i : α) → NormedAddCommGroup (E i)]
[(i : α) → StarAddMonoid (E i)]
[∀ (i : α), NormedStarGroup (E i)]
(f : ↥(lp E p))
(i : α)


@[to_additive]
theorem Pi.mulSingle_mul_mulSingle_eq_mulSingle_mul_mulSingle {M : Type*} [CommMonoid M]
    {k l m n : I} {u v : M} (hu : u ≠ 1) (hv : v ≠ 1) :
    (mulSingle k u : I → M) * mulSingle l v = mulSingle m u * mulSingle n v ↔
      k = m ∧ l = n ∨ u = v ∧ k = n ∧ l = m ∨ u * v = 1 ∧ k = l ∧ m = n

{I : Type u}
[DecidableEq I]
{M : Type u_3}
[CommMonoid M]
{k l m n : I}
{u v : M}
(hu : u ≠ 1)
(hv : v ≠ 1)

Pi.mulSingle k u * Pi.mulSingle l v = Pi.mulSingle m u * Pi.mulSingle n v ↔
  k = m ∧ l = n ∨ u = v ∧ k = n ∧ l = m ∨ u * v = 1 ∧ k = l ∧ m = n


lemma negAddY_of_Z_eq_zero_left {P Q : Fin 3 → R} (hP : W'.Equation P) (hPz : P z = 0) :
    W'.negAddY P Q = (P x * Q z) ^ 3 * W'.negY Q

{R : Type u}
[CommRing R]
{W' : WeierstrassCurve.Jacobian R}
{P Q : Fin 3 → R}
(hP : W'.Equation P)
(hPz : P z = 0)


@[to_additive]
theorem Multipliable.sigma' {γ : β → Type*} {f : (Σb : β, γ b) → α} (ha : Multipliable f)
    (hf : ∀ b, Multipliable fun c ↦ f ⟨b, c⟩) : Multipliable fun b ↦ ∏' c, f ⟨b, c⟩

(hf : ∀ (b : β), Summable fun c => f ⟨b, c⟩)

Summable fun b => ∑' (c : γ b), f ⟨b, c⟩


theorem hasCompactSupport_normed : HasCompactSupport (f.normed μ)


@[simp]
lemma const_apply (x y : SimplexCategory) (i : Fin (y.len + 1)) (a : Fin (x.len + 1)) :
    (const x y i).toOrderHom a = i

(SimplexCategory.Hom.toOrderHom (x.const y i)) a = i


/-- Local instance for `TransOrd (oα.lex' oβ)`. -/
theorem TransOrd.instOrdLex' (ord₁ ord₂ : Ord α) [@TransOrd _ ord₁] [@TransOrd _ ord₂] :
    @TransOrd _ (ord₁.lex' ord₂)

{α : Type u_1}
(ord₁ ord₂ : Ord α)
[Batteries.TransOrd α]
[Batteries.TransOrd α]


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

(Bipointed.swapEquiv.functor.obj X).toProd = X.toProd.swap


@[simp]
theorem abs_lt_one_iff {a : ℤ} : |a| < 1 ↔ a = 0


@[simp]
theorem range_const (α) [MeasurableSpace α] [Nonempty α] (b : β) : (const α b).range = {b}

{β : Type u_2}
(α : Type u_5)
[MeasurableSpace α]
[Nonempty α]
(b : β)

(MeasureTheory.SimpleFunc.const α b).range = {b}


theorem IsNatPowT.run
    (p : IsNatPowT (Nat.pow a (nat_lit 1) = a) a b c) : Nat.pow a b = c

(p : Mathlib.Meta.NormNum.IsNatPowT (a.pow 1 = a) a b c)


@[to_additive]
theorem Function.Injective.isOfFinOrder_iff [Monoid H] {f : G →* H} (hf : Injective f) :
    IsOfFinOrder (f x) ↔ IsOfFinOrder x

{G : Type u_1}
{H : Type u_2}
[AddMonoid G]
{x : G}
[AddMonoid H]
{f : G →+ H}
(hf : Function.Injective ⇑f)

IsOfFinAddOrder (f x) ↔ IsOfFinAddOrder x


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


/-- A linear independent set of `finrank K V` vectors forms a basis. -/
@[simps! repr_apply]
noncomputable def setBasisOfLinearIndependentOfCardEqFinrank {s : Set V} [Nonempty s] [Fintype s]
    (lin_ind : LinearIndependent K ((↑) : s → V)) (card_eq : s.toFinset.card = finrank K V) :
    Basis s K V

(lin_ind : LinearIndependent (ι := { x // x ∈ s }) K Subtype.val)

(card_eq : s.toFinset.card = FiniteDimensional.finrank K V)

∀ (a : V),
  (setBasisOfLinearIndependentOfCardEqFinrank lin_ind card_eq).repr a =
    lin_ind.repr ((LinearMap.codRestrict (Submodule.span K (Set.range Subtype.val)) LinearMap.id ⋯) a)


/-- We compute the absolute discriminant of a `p ^ (k + 1)`-th cyclotomic field.
  Beware that in the case `p ^ k = 2` the formula uses `1 / 2 = 0`. See also the results below. -/
theorem absdiscr_prime_pow_succ [IsCyclotomicExtension {p ^ (k + 1)} ℚ K] :
    haveI : NumberField K := IsCyclotomicExtension.numberField {p ^ (k + 1)} ℚ K
    NumberField.discr K =
    (-1) ^ ((p : ℕ) ^ k * (p - 1) / 2) * p ^ ((p : ℕ) ^ k * ((p - 1) * (k + 1) - 1))


@[to_additive (attr := continuity, fun_prop)]
theorem Continuous.mul {f g : X → M} (hf : Continuous f) (hg : Continuous g) :
    Continuous fun x => f x * g x

{M : Type u_3}
{X : Type u_5}
[TopologicalSpace X]
[TopologicalSpace M]
[Add M]
[ContinuousAdd M]
{f g : X → M}
(hf : Continuous f)
(hg : Continuous g)


/-- Structure recording good behavior of a property of a triple `(f, s, x)` where `f` is a function,
`s` a set and `x` a point. Good behavior here means locality and invariance under given groupoids
(both in the source and in the target). Given such a good behavior, the lift of this property
to charted spaces admitting these groupoids will inherit the good behavior. -/
structure LocalInvariantProp (P : (H → H') → Set H → H → Prop) : Prop where
  is_local : ∀ {s x u} {f : H → H'}, IsOpen u → x ∈ u → (P f s x ↔ P f (s ∩ u) x)
  right_invariance' : ∀ {s x f} {e : PartialHomeomorph H H},
    e ∈ G → x ∈ e.source → P f s x → P (f ∘ e.symm) (e.symm ⁻¹' s) (e x)
  congr_of_forall : ∀ {s x} {f g : H → H'}, (∀ y ∈ s, f y = g y) → f x = g x → P f s x → P g s x
  left_invariance' : ∀ {s x f} {e' : PartialHomeomorph H' H'},
    e' ∈ G' → s ⊆ f ⁻¹' e'.source → f x ∈ e'.source → P f s x → P (e' ∘ f) s x

{H : Type u_1}
{H' : Type u_3}
[TopologicalSpace H]
[TopologicalSpace H']
{G : StructureGroupoid H}
{G' : StructureGroupoid H'}
{P : (H → H') → Set H → H → Prop}
(self : G.LocalInvariantProp G' P)
{s : Set H}
{x : H}
{f : H → H'}
{e' : PartialHomeomorph H' H'}

e' ∈ G' → s ⊆ f ⁻¹' e'.source → f x ∈ e'.source → P f s x → P (↑e' ∘ f) s x


@[nontriviality]
theorem Subsingleton.of_subsingleton [Subsingleton α] : l.Subsingleton

{α : Type u_1}
{l : Filter α}
[Subsingleton α]


theorem normalCore_eq_iSup (H : Subgroup G) :
    H.normalCore = ⨆ (N : Subgroup G) (_ : Normal N) (_ : N ≤ H), N

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

H.normalCore = ⨆ N, ⨆ (_ : N.Normal), ⨆ (_ : N ≤ H), N


@[simp, norm_cast] lemma coe_neg [NegZeroClass G] (g : α →₀ G) : ⇑(-g) = -g

{α : Type u_1}
{G : Type u_9}
[NegZeroClass G]
(g : α →₀ G)


@[to_additive]
theorem isNormalSubgroup_of_commGroup [CommGroup G] {s : Set G} (hs : IsSubgroup s) :
    IsNormalSubgroup s

{G : Type u_1}
[AddCommGroup G]
{s : Set G}
(hs : IsAddSubgroup s)


@[to_additive]
theorem le_of_mul_le_of_one_le_left [CovariantClass α α (· * ·) (· ≤ ·)] {a b c : α} (h : a * b ≤ c)
    (hle : 1 ≤ b) :
    a ≤ c

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


theorem Valid'.mono_left {x y : α} (xy : x ≤ y) {t : Ordnode α} {o} (h : Valid' y t o) :
    Valid' x t o

{α : Type u_1}
[Preorder α]
{x y : α}
(xy : x ≤ y)
{t : Ordnode α}
{o : WithTop α}
(h : Ordnode.Valid' (↑y) t o)


theorem cbiSup_eq_of_forall {p : ι → Prop} {f : Subtype p → α} (hp : ∀ i, p i) :
    ⨆ (i) (h : p i), f ⟨i, h⟩ = iSup f

{α : Type u_1}
{ι : Sort u_4}
[ConditionallyCompleteLattice α]
{p : ι → Prop}
{f : Subtype p → α}
(hp : ∀ (i : ι), p i)


@[simp]
theorem lift_unique (f : M →ₗ[R] A) (cond : ∀ m : M, f m * f m = algebraMap _ _ (Q m))
    (g : CliffordAlgebra Q →ₐ[R] A) : g.toLinearMap.comp (ι Q) = f ↔ g = lift Q ⟨f, cond⟩

(cond : ∀ (m : M), f m * f m = (algebraMap R A) (Q m))

g.toLinearMap ∘ₗ CliffordAlgebra.ι Q = f ↔ g = (CliffordAlgebra.lift Q) ⟨f, cond⟩


theorem of_a_eq_zero' : toPoly ⟨0, b, c, d⟩ = C b * X ^ 2 + C c * X + C d

{ a := 0, b := b, c := c, d := d }.toPoly =
  Polynomial.C b * Polynomial.X ^ 2 + Polynomial.C c * Polynomial.X + Polynomial.C d


theorem stereo_left_inv (hv : ‖v‖ = 1) {x : sphere (0 : E) 1} (hx : (x : E) ≠ v) :
    stereoInvFun hv (stereoToFun v x) = x

{E : Type u_1}
[NormedAddCommGroup E]
[InnerProductSpace ℝ E]
{v : E}
(hv : ‖v‖ = 1)
{x : ↑(Metric.sphere 0 1)}
(hx : ↑x ≠ v)


@[simp] lemma ofZeros_f' (hf : S.f = 0) (hg : S.g = 0) :
    (ofZeros S hf hg).f' = 0

(CategoryTheory.ShortComplex.LeftHomologyData.ofZeros S hf hg).f' = 0


@[simp]
theorem lintegral_add_measure {m : MeasurableSpace α} (f : α → ℝ≥0∞) (μ ν : Measure α) :
    ∫⁻ a, f a ∂(μ + ν) = ∫⁻ a, f a ∂μ + ∫⁻ a, f a ∂ν

{α : Type u_1}
{m : MeasurableSpace α}
(f : α → ℝ≥0∞)
(μ ν : MeasureTheory.Measure α)

∫⁻ (a : α), f a ∂(μ + ν) = ∫⁻ (a : α), f a ∂μ + ∫⁻ (a : α), f a ∂ν


@[to_additive]
theorem mk'_eq_iff_mk'_eq (g : LocalizationMap S P) {x₁ x₂} {y₁ y₂ : S} :
    f.mk' x₁ y₁ = f.mk' x₂ y₂ ↔ g.mk' x₁ y₁ = g.mk' x₂ y₂

{M : Type u_1}
[AddCommMonoid M]
{S : AddSubmonoid M}
{N : Type u_2}
[AddCommMonoid N]
{P : Type u_3}
[AddCommMonoid P]
(f : S.LocalizationMap N)
(g : S.LocalizationMap P)
{x₁ x₂ : M}
{y₁ y₂ : ↥S}


@[simp]
theorem lsub_unique {ι} [Unique ι] (f : ι → Ordinal) : lsub f = succ (f default)

{ι : Type u_4}
[Unique ι]
(f : ι → Ordinal.{max u_5 u_4})


@[to_additive (attr := simp)]
theorem mul_div_mul_right_eq_div (a b c : G) : a * c / (b * c) = a / b


theorem gcd_eq_zero_iff (a : ℤ√d) : Int.gcd a.re a.im = 0 ↔ a = 0


lemma _root_.NumberField.ComplexEmbedding.IsConj.coe_stabilzer_mk
    {φ : K →+* ℂ} (h : ComplexEmbedding.IsConj φ σ) :
    (Stab (mk φ) : Set (K ≃ₐ[k] K)) = {1, σ}

(h : NumberField.ComplexEmbedding.IsConj φ σ)

↑(MulAction.stabilizer (K ≃ₐ[k] K) (NumberField.InfinitePlace.mk φ)) = {1, σ}


theorem fderivWithin_congr_set (h : s =ᶠ[𝓝 x] t) : fderivWithin 𝕜 f s x = fderivWithin 𝕜 f t x

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


theorem comp_surjective {f : A →+* B} {g : B →+* C} (hf : f.FiniteType) (hg : Surjective g) :
    (g.comp f).FiniteType

{A : Type u_1}
{B : Type u_2}
{C : Type u_3}
[CommRing A]
[CommRing B]
[CommRing C]
{f : A →+* B}
{g : B →+* C}
(hf : f.FiniteType)
(hg : Function.Surjective ⇑g)


theorem himp_triangle (a b c : α) : (a ⇨ b) ⊓ (b ⇨ c) ≤ a ⇨ c

{α : Type u_2}
[GeneralizedHeytingAlgebra α]
(a b c : α)


theorem equitableOn_singleton (a : α) (f : α → β) : Set.EquitableOn {a} f

{α : Type u_1}
{β : Type u_2}
[OrderedSemiring β]
(a : α)
(f : α → β)


theorem tendsto_toReal {a : ℝ≥0∞} (ha : a ≠ ∞) : Tendsto ENNReal.toReal (𝓝 a) (𝓝 a.toReal)

Filter.Tendsto ENNReal.toReal (𝓝 a) (𝓝 a.toReal)


theorem geom_sum_neg_iff [LinearOrderedRing α] (hn : n ≠ 0) :
    ∑ i ∈ range n, x ^ i < 0 ↔ Even n ∧ x + 1 < 0

{α : Type u}
{n : ℕ}
{x : α}
[LinearOrderedRing α]
(hn : n ≠ 0)

∑ i ∈ Finset.range n, x ^ i < 0 ↔ Even n ∧ x + 1 < 0


@[to_additive (attr := measurability)]
protected theorem Measurable.mabs : Measurable fun x ↦ mabs (f x)

{α : Type u_1}
{β : Type u_2}
[Lattice α]
[Group α]
[MeasurableSpace α]
[MeasurableSpace β]
{f : β → α}
(hf : Measurable f)
[MeasurableInv α]
[MeasurableSup₂ α]


theorem IsCofiltered.isConnected [IsCofiltered C] : IsConnected C

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


@[to_additive (attr := simp)]
theorem coprod_comp_inl : (f.coprod g).comp (inl M N) = f

{M : Type u_5}
{N : Type u_6}
{P : Type u_7}
[MulOneClass M]
[MulOneClass N]
[CommMonoid P]
(f : M →* P)
(g : N →* P)

(f.coprod g).comp (MonoidHom.inl M N) = f


theorem symm_bijective : Function.Bijective (Homeomorph.symm : (X ≃ₜ Y) → Y ≃ₜ X)

{X : Type u_1}
{Y : Type u_2}
[TopologicalSpace X]
[TopologicalSpace Y]


@[simp]
theorem liftNC_one {g_hom : Type*} [FunLike g_hom G R] [OneHomClass g_hom G R]
    (f : k →+* R) (g : g_hom) :
    liftNC (f : k →+ R) g 1 = 1

{k : Type u₁}
{G : Type u₂}
{R : Type u_2}
[NonAssocSemiring R]
[Semiring k]
[One G]
{g_hom : Type u_3}
[FunLike g_hom G R]
[OneHomClass g_hom G R]
(f : k →+* R)
(g : g_hom)


@[simp, deprecated get_inits (since := "2024-04-16")]
theorem nth_le_inits (l : List α) (n : ℕ) (hn : n < length (inits l)) :
    nthLe (inits l) n hn = l.take n

{α : Type u_1}
(l : List α)
(n : ℕ)
(hn : n < l.inits.length)


@[simp]
theorem map_val (f : α ↪ β) (s : Finset α) : (map f s).1 = s.1.map f

{α : Type u_1}
{β : Type u_2}
(f : α ↪ β)
(s : Finset α)

(Finset.map f s).val = Multiset.map (⇑f) s.val


@[simp] theorem cast_addNat_zero {n n' : Nat} (i : Fin n) (h : n + 0 = n') :
    cast h (addNat i 0) = cast ((Nat.add_zero _).symm.trans h) i


theorem Filter.Eventually.self_of_nhdsSet {p : X → Prop} (h : ∀ᶠ x in 𝓝ˢ s, p x) : ∀ x ∈ s, p x

{X : Type u_1}
[TopologicalSpace X]
{s : Set X}
{p : X → Prop}
(h : ∀ᶠ (x : X) in 𝓝ˢ s, p x)
(x : X)


@[simp]
theorem subtypeDomain_add [∀ i, AddZeroClass (β i)] {p : ι → Prop} [DecidablePred p]
    (v v' : Π₀ i, β i) : (v + v').subtypeDomain p = v.subtypeDomain p + v'.subtypeDomain p

{ι : Type u}
{β : ι → Type v}
[(i : ι) → AddZeroClass (β i)]
{p : ι → Prop}
[DecidablePred p]
(v v' : Π₀ (i : ι), β i)

DFinsupp.subtypeDomain p (v + v') = DFinsupp.subtypeDomain p v + DFinsupp.subtypeDomain p v'


theorem normalize_num_den (h : normalize n d z = ⟨n', d', z', c⟩) :
    ∃ m : Nat, m ≠ 0 ∧ n = n' * m ∧ d = d' * m

(h : Rat.normalize n d z = { num := n', den := d', den_nz := z', reduced := c })


theorem mul_inv (t : TransvectionStruct n R) : t.toMatrix * t.inv.toMatrix = 1

{n : Type u_1}
{R : Type u₂}
[DecidableEq n]
[CommRing R]
[Fintype n]
(t : Matrix.TransvectionStruct n R)


/-- An antitone function sending `bot` to `top` is continuous at the indexed supremum over
a `Sort`, then it sends this indexed supremum to the indexed supremum of the composition. -/
theorem Antitone.map_iSup_of_continuousAt {ι : Sort*} {f : α → β} {g : ι → α}
    (Cf : ContinuousAt f (iSup g)) (Af : Antitone f) (fbot : f ⊥ = ⊤) :
    f (⨆ i, g i) = ⨅ i, f (g i)

{α : Type u_1}
{β : Type u_2}
[CompleteLinearOrder α]
[TopologicalSpace α]
[OrderTopology α]
[CompleteLinearOrder β]
[TopologicalSpace β]
[OrderClosedTopology β]
{ι : Sort u_4}
{f : α → β}
{g : ι → α}
(Cf : ContinuousAt f (iSup g))
(Af : Antitone f)
(fbot : f ⊥ = ⊤)


theorem ker_toLin_eq_bot [DecidableEq n] (A : Matrix n n R) (hA : IsUnit A.det) :
    LinearMap.ker (toLin b b A) = ⊥

{n : Type u_1}
[Fintype n]
{R : Type u_2}
{M : Type u_3}
[CommRing R]
[AddCommGroup M]
[Module R M]
(b : Basis n R M)
[DecidableEq n]
(A : Matrix n n R)
(hA : IsUnit A.det)

LinearMap.ker ((Matrix.toLin b b) A) = ⊥


theorem mem_coe_iff : a ∈ (s : Set α) ↔ a ∈ s

{α : Type u_1}
[LE α]
{s : Flag α}
{a : α}

a ∈ ↑s ↔ a ∈ s


@[simp]
theorem erase_apply {i j : ι} {f : Π₀ i, β i} : (f.erase i) j = if j = i then 0 else f j

{ι : Type u}
{β : ι → Type v}
[DecidableEq ι]
[(i : ι) → Zero (β i)]
{i j : ι}
{f : Π₀ (i : ι), β i}

(DFinsupp.erase i f) j = if j = i then 0 else f j


theorem sSameSide_lineMap_left {s : AffineSubspace R P} {x y : P} (hx : x ∈ s) (hy : y ∉ s) {t : R}
    (ht : 0 < t) : s.SSameSide (lineMap x y t) y

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

s.SSameSide ((AffineMap.lineMap x y) t) y


theorem scaled_exp_map_periodic : Function.Periodic (fun x => expMapCircle (2 * π / T * x)) T


@[simp]
theorem dual_comp (g : sInfHom β γ) (f : sInfHom α β) :
    sInfHom.dual (g.comp f) = (sInfHom.dual g).comp (sInfHom.dual f)

{α : Type u_2}
{β : Type u_3}
{γ : Type u_4}
[InfSet α]
[InfSet β]
[InfSet γ]
(g : sInfHom β γ)
(f : sInfHom α β)


theorem map_map (g : β → γ) (h : γ → δ) (f : α →ₛ β) : (f.map g).map h = f.map (h ∘ g)

{α : Type u_1}
{β : Type u_2}
{γ : Type u_3}
{δ : Type u_4}
[MeasurableSpace α]
(g : β → γ)
(h : γ → δ)
(f : MeasureTheory.SimpleFunc α β)

MeasureTheory.SimpleFunc.map h (MeasureTheory.SimpleFunc.map g f) = MeasureTheory.SimpleFunc.map (h ∘ g) f


theorem ae_bdd_liminf_atTop_of_eLpNorm_bdd {p : ℝ≥0∞} (hp : p ≠ 0) {f : ℕ → α → E}
    (hfmeas : ∀ n, Measurable (f n)) (hbdd : ∀ n, eLpNorm (f n) p μ ≤ R) :
    ∀ᵐ x ∂μ, liminf (fun n => (‖f n x‖₊ : ℝ≥0∞)) atTop < ∞

(hbdd : ∀ (n : ℕ), MeasureTheory.eLpNorm (f n) p μ ≤ ↑R)

∀ᵐ (x : α) ∂μ, Filter.liminf (fun n => ↑‖f n x‖₊) Filter.atTop < ⊤


/-- Version of `HasProd.update` for `CommMonoid` rather than `CommGroup`.
Rather than showing that `f.update` has a specific product in terms of `HasProd`,
it gives a relationship between the products of `f` and `f.update` given that both exist. -/
@[to_additive "Version of `HasSum.update` for `AddCommMonoid` rather than `AddCommGroup`.
Rather than showing that `f.update` has a specific sum in terms of `HasSum`,
it gives a relationship between the sums of `f` and `f.update` given that both exist."]
theorem HasProd.update' {α β : Type*} [TopologicalSpace α] [CommMonoid α] [T2Space α]
    [ContinuousMul α] [DecidableEq β] {f : β → α} {a a' : α} (hf : HasProd f a) (b : β) (x : α)
    (hf' : HasProd (update f b x) a') : a * x = a' * f b

(hf' : HasProd (Function.update f b x) a')


protected theorem Decidable.mul_lt_mul'' [PosMulMono α] [PosMulStrictMono α] [MulPosStrictMono α]
    [@DecidableRel α (· ≤ ·)] (h1 : a < c) (h2 : b < d)
    (h3 : 0 ≤ a) (h4 : 0 ≤ b) : a * b < c * d

{α : Type u}
[Semiring α]
[PartialOrder α]
{a b c d : α}
[PosMulMono α]
[PosMulStrictMono α]
[MulPosStrictMono α]
[DecidableRel fun x x_1 => x ≤ x_1]
(h1 : a < c)
(h2 : b < d)
(h3 : 0 ≤ a)
(h4 : 0 ≤ b)


theorem norm_approxOn_zero_le [OpensMeasurableSpace E] {f : β → E} (hf : Measurable f) {s : Set E}
    (h₀ : (0 : E) ∈ s) [SeparableSpace s] (x : β) (n : ℕ) :
    ‖approxOn f hf s 0 h₀ n x‖ ≤ ‖f x‖ + ‖f x‖

{β : Type u_2}
{E : Type u_4}
[MeasurableSpace β]
[MeasurableSpace E]
[NormedAddCommGroup E]
[OpensMeasurableSpace E]
{f : β → E}
(hf : Measurable f)
{s : Set E}
(h₀ : 0 ∈ s)
[TopologicalSpace.SeparableSpace ↑s]
(x : β)
(n : ℕ)

‖↑(MeasureTheory.SimpleFunc.approxOn f hf s 0 h₀ n) x‖ ≤ ‖f x‖ + ‖f x‖


theorem le_one (x : ℝ) : smoothTransition x ≤ 1


lemma hasFDerivAt_fourierChar_neg_bilinear_right (v : V) (w : W) :
    HasFDerivAt (fun w ↦ (𝐞 (-L v w) : ℂ))
      ((-2 * π * I * 𝐞 (-L v w)) • (ofRealCLM ∘L (L v))) w

{V : Type u_1}
{W : Type u_2}
[NormedAddCommGroup V]
[NormedSpace ℝ V]
[NormedAddCommGroup W]
[NormedSpace ℝ W]
(L : V →L[ℝ] W →L[ℝ] ℝ)
(v : V)
(w : W)

HasFDerivAt (fun w => ↑(𝐞 (-(L v) w))) ((-2 * ↑π * Complex.I * ↑(𝐞 (-(L v) w))) • Complex.ofRealCLM.comp (L v)) w


@[simp]
theorem isOpenMap_sum_elim {f : X → Z} {g : Y → Z} :
    IsOpenMap (Sum.elim f g) ↔ IsOpenMap f ∧ IsOpenMap g

{X : Type u}
{Y : Type v}
{Z : Type u_1}
[TopologicalSpace X]
[TopologicalSpace Y]
[TopologicalSpace Z]
{f : X → Z}
{g : Y → Z}


lemma equivalenceLeftFractionRel (X Y : C) :
    @_root_.Equivalence (W.LeftFraction X Y) LeftFractionRel

{C : Type u_1}
[CategoryTheory.Category.{u_3, u_1} C]
(W : CategoryTheory.MorphismProperty C)
[W.HasLeftCalculusOfFractions]
(X Y : C)


@[to_additive (attr := simp)]
theorem comap_top (f : G →* N) : (⊤ : Subgroup N).comap f = ⊤

{G : Type u_1}
[AddGroup G]
{N : Type u_5}
[AddGroup N]
(f : G →+ N)


@[simp]
theorem restrictScalars_ball (p : Seminorm 𝕜' E) : (p.restrictScalars 𝕜).ball = p.ball

(𝕜 : Type u_3)
{E : Type u_7}
{𝕜' : Type u_13}
[NormedField 𝕜]
[SeminormedRing 𝕜']
[NormedAlgebra 𝕜 𝕜']
[NormOneClass 𝕜']
[AddCommGroup E]
[Module 𝕜' E]
[SMul 𝕜 E]
[IsScalarTower 𝕜 𝕜' E]
(p : Seminorm 𝕜' E)

(Seminorm.restrictScalars 𝕜 p).ball = p.ball


/-- The functor `SimplicialObject.Split C ⥤ SimplicialObject C` which forgets
the splitting. -/
@[simps]
def forget : Split C ⥤ SimplicialObject C

(C : Type u_1)
[CategoryTheory.Category.{u_2, u_1} C]
(S : SimplicialObject.Split C)

(SimplicialObject.Split.forget C).obj S = S.X


@[simp] lemma floorDiv_one [Nontrivial α] (b : β) : b ⌊/⌋ (1 : α) = b

{α : Type u_2}
{β : Type u_3}
[OrderedSemiring α]
[OrderedAddCommMonoid β]
[MulActionWithZero α β]
[FloorDiv α β]
[Nontrivial α]
(b : β)


/-- The inverse part of the equivalence `LightProfinite ≌ LightDiagram` -/
@[simps]
def lightDiagramToLightProfinite : LightDiagram.{u} ⥤ LightProfinite.{u}

lightDiagramToLightProfinite.obj X = LightProfinite.of ↑X.cone.pt.toTop


theorem posSemidef {M : Matrix n n R} (hM : M.PosDef) : M.PosSemidef

{n : Type u_2}
{R : Type u_3}
[Fintype n]
[CommRing R]
[PartialOrder R]
[StarRing R]
{M : Matrix n n R}
(hM : M.PosDef)


theorem coe_inj {f g : ArithmeticFunction R} : (f : ℕ → R) = g ↔ f = g

{R : Type u_1}
[Zero R]
{f g : ArithmeticFunction R}


theorem reflTransGen_of_equivalence {r' : α → α → Prop} (hr : Equivalence r) :
    (∀ a b, r' a b → r a b) → ReflTransGen r' a b → r a b

{α : Type u_1}
{r : α → α → Prop}
{a b : α}
{r' : α → α → Prop}
(hr : Equivalence r)

(∀ (a b : α), r' a b → r a b) → Relation.ReflTransGen r' a b → r a b


theorem fst_image_prod_subset (s : Set α) (t : Set β) : Prod.fst '' s ×ˢ t ⊆ s

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


theorem Coprime.mul {k m n : ℕ+} : m.Coprime k → n.Coprime k → (m * n).Coprime k


@[fun_prop]
theorem HasFDerivAt.smul_const (hc : HasFDerivAt c c' x) (f : F) :
    HasFDerivAt (fun y => c y • f) (c'.smulRight f) x

{𝕜 : Type u_1}
[NontriviallyNormedField 𝕜]
{E : Type u_2}
[NormedAddCommGroup E]
[NormedSpace 𝕜 E]
{F : Type u_3}
[NormedAddCommGroup F]
[NormedSpace 𝕜 F]
{x : E}
{𝕜' : Type u_6}
[NontriviallyNormedField 𝕜']
[NormedAlgebra 𝕜 𝕜']
[NormedSpace 𝕜' F]
[IsScalarTower 𝕜 𝕜' F]
{c : E → 𝕜'}
{c' : E →L[𝕜] 𝕜'}
(hc : HasFDerivAt c c' x)
(f : F)


theorem isClosedMap_toMul : IsClosedMap (toMul : Additive X → X)


lemma comp_id : ∀ {X Y : Σi, C i} (f : X ⟶ Y), f ≫ 𝟙 Y = f

[(i : I) → CategoryTheory.Category.{v₁, u₁} (C i)]

CategoryTheory.CategoryStruct.comp f (CategoryTheory.CategoryStruct.id Y) = f


theorem mem_span_latticeBasis (x : (E K)) :
    x ∈ Submodule.span ℤ (Set.range (latticeBasis K)) ↔
      x ∈ ((mixedEmbedding K).comp (algebraMap (𝓞 K) K)).range

(x : ({ w // w.IsReal } → ℝ) × ({ w // w.IsComplex } → ℂ))

x ∈ Submodule.span ℤ (Set.range ⇑(NumberField.mixedEmbedding.latticeBasis K)) ↔
  x ∈ ((NumberField.mixedEmbedding K).comp (algebraMap (NumberField.RingOfIntegers K) K)).range


theorem image_basicOpen {X Y : Scheme.{u}} (f : X ⟶ Y) [H : IsOpenImmersion f] {U : X.Opens}
    (r : Γ(X, U)) :
    f ''ᵁ X.basicOpen r = Y.basicOpen ((f.appIso U).inv r)

[H : AlgebraicGeometry.IsOpenImmersion f]

(AlgebraicGeometry.Scheme.Hom.opensFunctor f).obj (X.basicOpen r) =
  Y.basicOpen ((AlgebraicGeometry.Scheme.Hom.appIso f U).inv r)


@[norm_cast] lemma cast_sub_of_ne_zero (hp : (p.den : α) ≠ 0) (hq : (q.den : α) ≠ 0) :
    ↑(p - q) = (p - q : α)

{α : Type u_3}
[DivisionRing α]
{p q : ℚ}
(hp : ↑p.den ≠ 0)
(hq : ↑q.den ≠ 0)


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

{α : Type u_1}
{β : Type u_2}
[AddCommGroup α]
[UniformSpace α]
[UniformAddGroup α]
{f : β → α}
[CompleteSpace α]

Summable f ↔ ∀ e ∈ 𝓝 0, ∃ s, ∀ (t : Set β), Disjoint t ↑s → ∑' (b : ↑t), f ↑b ∈ e


@[norm_cast]
theorem coe_codRestrict (f : A →A[R] B) (p : Subalgebra R B) (h : ∀ x, f x ∈ p) :
    (f.codRestrict p h : A →ₐ[R] p) = (f : A →ₐ[R] B).codRestrict p h

{R : Type u_1}
[CommSemiring R]
{A : Type u_2}
[Semiring A]
[TopologicalSpace A]
{B : Type u_3}
[Semiring B]
[TopologicalSpace B]
[Algebra R A]
[Algebra R B]
(f : A →A[R] B)
(p : Subalgebra R B)
(h : ∀ (x : A), f x ∈ p)

↑(f.codRestrict p h) = (↑f).codRestrict p h


@[simp]
theorem dual_comp (g : sSupHom β γ) (f : sSupHom α β) :
    sSupHom.dual (g.comp f) = (sSupHom.dual g).comp (sSupHom.dual f)

{α : Type u_2}
{β : Type u_3}
{γ : Type u_4}
[SupSet α]
[SupSet β]
[SupSet γ]
(g : sSupHom β γ)
(f : sSupHom α β)


@[to_additive]
theorem smul_set_union : a • (t₁ ∪ t₂) = a • t₁ ∪ a • t₂

{α : Type u_2}
{β : Type u_3}
[SMul α β]
{t₁ t₂ : Set β}
{a : α}


/-- `ofAntisymmetrization` as an order embedding. -/
@[simps]
noncomputable def OrderEmbedding.ofAntisymmetrization : Antisymmetrization α (· ≤ ·) ↪o α

∀ (a : Antisymmetrization α fun x x_1 => x ≤ x_1),
  (OrderEmbedding.ofAntisymmetrization α) a = ofAntisymmetrization (fun x x_1 => x ≤ x_1) a


@[simp, norm_cast] lemma coe_inv (q : ℚ≥0) : ((q⁻¹ : ℚ≥0) : ℚ) = (q : ℚ)⁻¹

↑q⁻¹ = (↑q)⁻¹


protected theorem compactSpace [CompactSpace X] (h : X ≃ₜ Y) : CompactSpace Y

{X : Type u_1}
{Y : Type u_2}
[TopologicalSpace X]
[TopologicalSpace Y]
[CompactSpace X]
(h : X ≃ₜ Y)


lemma Finset.univ_of_card_le_two (h : Fintype.card R ≤ 2) :
    (univ : Finset R) = {0, 1}

{R : Type u_1}
[Ring R]
[Fintype R]
[DecidableEq R]
(h : Fintype.card R ≤ 2)


theorem integral_fun_fst (f : α → E) : ∫ z, f z.1 ∂μ.prod ν = (ν univ).toReal • ∫ x, f x ∂μ

{α : Type u_1}
{β : Type u_3}
{E : Type u_6}
[MeasurableSpace α]
[MeasurableSpace β]
{μ : MeasureTheory.Measure α}
{ν : MeasureTheory.Measure β}
[NormedAddCommGroup E]
[MeasureTheory.SFinite ν]
[NormedSpace ℝ E]
[MeasureTheory.SFinite μ]
(f : α → E)

∫ (z : α × β), f z.1 ∂μ.prod ν = (ν Set.univ).toReal • ∫ (x : α), f x ∂μ


/-- The composition of right homology map data. -/
@[simps]
def comp {φ : S₁ ⟶ S₂} {φ' : S₂ ⟶ S₃} {h₁ : S₁.RightHomologyData}
    {h₂ : S₂.RightHomologyData} {h₃ : S₃.RightHomologyData}
    (ψ : RightHomologyMapData φ h₁ h₂) (ψ' : RightHomologyMapData φ' h₂ h₃) :
    RightHomologyMapData (φ ≫ φ') h₁ h₃

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

(ψ : CategoryTheory.ShortComplex.RightHomologyMapData φ h₁ h₂)

(ψ' : CategoryTheory.ShortComplex.RightHomologyMapData φ' h₂ h₃)

(ψ.comp ψ').φQ = CategoryTheory.CategoryStruct.comp ψ.φQ ψ'.φQ


/-- Technical lemma stating how `p.apply_composition` commutes with updating variables. This
will be the key point to show that functions constructed from `apply_composition` retain
multilinearity. -/
theorem applyComposition_update (p : FormalMultilinearSeries 𝕜 E F) {n : ℕ} (c : Composition n)
    (j : Fin n) (v : Fin n → E) (z : E) :
    p.applyComposition c (Function.update v j z) =
      Function.update (p.applyComposition c v) (c.index j)
        (p (c.blocksFun (c.index j))
          (Function.update (v ∘ c.embedding (c.index j)) (c.invEmbedding j) z))

{𝕜 : Type u_1}
{E : Type u_2}
{F : Type u_3}
[CommRing 𝕜]
[AddCommGroup E]
[AddCommGroup F]
[Module 𝕜 E]
[Module 𝕜 F]
[TopologicalSpace E]
[TopologicalSpace F]
[TopologicalAddGroup E]
[ContinuousConstSMul 𝕜 E]
[TopologicalAddGroup F]
[ContinuousConstSMul 𝕜 F]
(p : FormalMultilinearSeries 𝕜 E F)
{n : ℕ}
(c : Composition n)
(j : Fin n)
(v : Fin n → E)
(z : E)

p.applyComposition c (Function.update v j z) =
  Function.update (p.applyComposition c v) (c.index j)
    ((p (c.blocksFun (c.index j))) (Function.update (v ∘ ⇑(c.embedding (c.index j))) (c.invEmbedding j) z))


lemma toAffine_add {P Q : Fin 3 → F} (hP : W.Nonsingular P) (hQ : W.Nonsingular Q) :
    toAffine W (W.add P Q) = toAffine W P + toAffine W Q

{F : Type v}
[Field F]
{W : WeierstrassCurve.Jacobian F}
{P Q : Fin 3 → F}
(hP : W.Nonsingular P)
(hQ : W.Nonsingular Q)

WeierstrassCurve.Jacobian.Point.toAffine W (W.add P Q) =
  WeierstrassCurve.Jacobian.Point.toAffine W P + WeierstrassCurve.Jacobian.Point.toAffine W Q


/-- To show that a compact set intersects the intersection of a family of closed sets,
  it is sufficient to show that it intersects every finite subfamily. -/
theorem IsCompact.inter_iInter_nonempty {ι : Type v} (hs : IsCompact s) (t : ι → Set X)
    (htc : ∀ i, IsClosed (t i)) (hst : ∀ u : Finset ι, (s ∩ ⋂ i ∈ u, t i).Nonempty) :
    (s ∩ ⋂ i, t i).Nonempty

(hst : ∀ (u : Finset ι), (s ∩ ⋂ i ∈ u, t i).Nonempty)


theorem IsGLB.nhdsWithin_neBot : ∀ {a : α} {s : Set α}, IsGLB s a → s.Nonempty → NeBot (𝓝[s] a)

{α : Type u_1}
[TopologicalSpace α]
[LinearOrder α]
[OrderTopology α]
{a : α}
{s : Set α}


theorem apply_mem_map₂ (f : M →ₗ[R] N →ₗ[R] P) {m : M} {n : N} {p : Submodule R M}
    {q : Submodule R N} (hm : m ∈ p) (hn : n ∈ q) : f m n ∈ map₂ f p q

{R : Type u_1}
{M : Type u_2}
{N : Type u_3}
{P : Type u_4}
[CommSemiring R]
[AddCommMonoid M]
[AddCommMonoid N]
[AddCommMonoid P]
[Module R M]
[Module R N]
[Module R P]
(f : M →ₗ[R] N →ₗ[R] P)
{m : M}
{n : N}
{p : Submodule R M}
{q : Submodule R N}
(hm : m ∈ p)
(hn : n ∈ q)


@[to_additive]
theorem closure_eq_of_le (h₁ : k ⊆ K) (h₂ : K ≤ closure k) : closure k = K

{G : Type u_1}
[AddGroup G]
(K : AddSubgroup G)
{k : Set G}
(h₁ : k ⊆ ↑K)
(h₂ : K ≤ AddSubgroup.closure k)


@[simp]
theorem eraseNone_union [DecidableEq (Option α)] [DecidableEq α] (s t : Finset (Option α)) :
    eraseNone (s ∪ t) = eraseNone s ∪ eraseNone t

{α : Type u_1}
[DecidableEq (Option α)]
[DecidableEq α]
(s t : Finset (Option α))

Finset.eraseNone (s ∪ t) = Finset.eraseNone s ∪ Finset.eraseNone t


theorem pi_zero : pi (fun _ => 0 : ∀ i, M →L[R] φ i) = 0

{R : Type u_1}
[Semiring R]
{M : Type u_2}
[TopologicalSpace M]
[AddCommMonoid M]
[Module R M]
{ι : Type u_4}
{φ : ι → Type u_5}
[(i : ι) → TopologicalSpace (φ i)]
[(i : ι) → AddCommMonoid (φ i)]
[(i : ι) → Module R (φ i)]


@[to_additive (attr := simp)]
theorem unop_div [DivInvMonoid α] (x y : αᵐᵒᵖ) : unop (x / y) = (unop y)⁻¹ * unop x

{α : Type u_1}
[SubNegMonoid α]
(x y : αᵃᵒᵖ)

AddOpposite.unop (x - y) = -AddOpposite.unop y + AddOpposite.unop x


lemma cfcₙHom_eq_cfcₙ_extend {a : A} (g : R → R) (ha : p a) (f : C(σₙ R a, R)₀) :
    cfcₙHom ha f = cfcₙ (Function.extend Subtype.val f g) a

(cfcₙHom ha) f = cfcₙ (Function.extend Subtype.val (⇑f) g) a


/-- An order is an `OrderBot` if it has a least element.
We state this using a data mixin, holding the value of `⊥` and the least element constraint. -/
class OrderBot (α : Type u) [LE α] extends Bot α where
  /-- `⊥` is the least element -/
  bot_le : ∀ a : α, ⊥ ≤ a

{α : Type u}
[LE α]
[self : OrderBot α]
(a : α)


@[to_additive]
theorem Submonoid.FG.map {M' : Type*} [Monoid M'] {P : Submonoid M} (h : P.FG) (e : M →* M') :
    (P.map e).FG

{M : Type u_1}
[AddMonoid M]
{M' : Type u_3}
[AddMonoid M']
{P : AddSubmonoid M}
(h : P.FG)
(e : M →+ M')


@[simp]
theorem logb_lt_logb_iff_of_base_lt_one (hx : 0 < x) (hy : 0 < y) :
    logb b x < logb b y ↔ y < x


theorem contDiffWithinAtProp_mono_of_mem (n : ℕ∞) ⦃s x t⦄ ⦃f : H → H'⦄ (hts : s ∈ 𝓝[t] x)
    (h : ContDiffWithinAtProp I I' n f s x) : ContDiffWithinAtProp I I' n f t x

{𝕜 : Type u_1}
[NontriviallyNormedField 𝕜]
{E : Type u_2}
[NormedAddCommGroup E]
[NormedSpace 𝕜 E]
{H : Type u_3}
[TopologicalSpace H]
(I : ModelWithCorners 𝕜 E H)
{E' : Type u_5}
[NormedAddCommGroup E']
[NormedSpace 𝕜 E']
{H' : Type u_6}
[TopologicalSpace H']
(I' : ModelWithCorners 𝕜 E' H')
(n : ℕ∞)
⦃s : Set H⦄
⦃x : H⦄
⦃t : Set H⦄
⦃f : H → H'⦄
(hts : s ∈ 𝓝[t] x)
(h : ContDiffWithinAtProp I I' n f s x)


/-- We may construct a glue data from a family of open sets. -/
@[simps! toGlueData_J toGlueData_U toGlueData_V toGlueData_t toGlueData_f]
def ofOpenSubsets : TopCat.GlueData.{u}

(i j :
  (TopCat.GlueData.MkCore.mk (fun i => (TopologicalSpace.Opens.toTopCat (TopCat.of α)).obj (U i))
      (fun i j => (TopologicalSpace.Opens.map (U i).inclusion).obj (U j))
      (fun i j => { toFun := fun x => ⟨⟨↑↑x, ⋯⟩, ⋯⟩, continuous_toFun := ⋯ }) ⋯ ⋯ ⋯ ⋯).J)

(TopCat.GlueData.ofOpenSubsets U).f i j = ((TopologicalSpace.Opens.map (U i).inclusion).obj (U j)).inclusion


/-- A crude upper bound on `n.factorization p` -/
theorem factorization_lt {n : ℕ} (p : ℕ) (hn : n ≠ 0) : n.factorization p < n


@[simp] theorem getElem_set_ne (a : Array α) (i : Fin a.size) (v : α) {j : Nat} (pj : j < (a.set i v).size)
    (h : i.val ≠ j) : (a.set i v)[j]'pj = a[j]'(size_set a i v ▸ pj)

{α : Type u_1}
(a : Array α)
(i : Fin a.size)
(v : α)
{j : Nat}
(pj : j < (a.set i v).size)
(h : ↑i ≠ j)


@[simp] theorem isCoatom_iff {p : Prop} : IsCoatom p ↔ ¬ p


/-- A structure designed to hold the hypotheses for the Mellin-functional-equation argument
(most general version: rapid decay at `∞` up to constant terms) -/
structure WeakFEPair where
  /-- The functions whose Mellin transform we study -/
  (f g : ℝ → E)
  /-- Weight (exponent in the functional equation) -/
  (k : ℝ)
  /-- Root number -/
  (ε : ℂ)
  /-- Constant terms at `∞` -/
  (f₀ g₀ : E)
  (hf_int : LocallyIntegrableOn f (Ioi 0))
  (hg_int : LocallyIntegrableOn g (Ioi 0))
  (hk : 0 < k)
  (hε : ε ≠ 0)
  (h_feq : ∀ x ∈ Ioi 0, f (1 / x) = (ε * ↑(x ^ k)) • g x)
  (hf_top (r : ℝ) : (f · - f₀) =O[atTop] (· ^ r))
  (hg_top (r : ℝ) : (g · - g₀) =O[atTop] (· ^ r))

{E : Type u_1}
[NormedAddCommGroup E]
[NormedSpace ℂ E]
(self : WeakFEPair E)
(x : ℝ)

x ∈ Set.Ioi 0 → self.f (1 / x) = (self.ε * ↑(x ^ self.k)) • self.g x


lemma IsTheta.isBigO_symm (h : f =Θ[l] g) : g =O[l] f

{α : Type u_1}
{E : Type u_3}
{F : Type u_4}
[Norm E]
[Norm F]
{f : α → E}
{g : α → F}
{l : Filter α}
(h : f =Θ[l] g)


theorem restrict_union (h : Disjoint s t) (ht : MeasurableSet t) :
    μ.restrict (s ∪ t) = μ.restrict s + μ.restrict t

{α : Type u_2}
{m0 : MeasurableSpace α}
{μ : MeasureTheory.Measure α}
{s t : Set α}
(h : Disjoint s t)
(ht : MeasurableSet t)


@[to_additive LipschitzWith.norm_le_mul]
theorem LipschitzWith.norm_le_mul' {f : E → F} {K : ℝ≥0} (h : LipschitzWith K f) (hf : f 1 = 1)
    (x) : ‖f x‖ ≤ K * ‖x‖

{E : Type u_3}
{F : Type u_4}
[SeminormedGroup E]
[SeminormedGroup F]
{f : E → F}
{K : ℝ≥0}
(h : LipschitzWith K f)
(hf : f 1 = 1)
(x : E)

‖f x‖ ≤ ↑K * ‖x‖


theorem tendsto_ceil_right_pure_add_one (n : ℤ) :
    Tendsto (ceil : α → ℤ) (𝓝[>] n) (pure (n + 1))

{α : Type u_1}
[LinearOrderedRing α]
[FloorRing α]
[TopologicalSpace α]
[OrderClosedTopology α]
(n : ℤ)

Filter.Tendsto Int.ceil (𝓝[>] ↑n) (pure (n + 1))


@[to_additive sum_eq_card_nsmul]
theorem prod_eq_pow_card {b : β} (hf : ∀ a ∈ s, f a = b) : ∏ a ∈ s, f a = b ^ s.card

{α : Type u_3}
{β : Type u_4}
{s : Finset α}
{f : α → β}
[CommMonoid β]
{b : β}
(hf : ∀ a ∈ s, f a = b)


/-- A monoid homomorphism between groups with zeros sending `0` to `0` sends `a⁻¹` to `(f a)⁻¹`. -/
@[simp]
theorem map_inv₀ : f a⁻¹ = (f a)⁻¹

{G₀ : Type u_3}
{G₀' : Type u_5}
{F : Type u_6}
[GroupWithZero G₀]
[GroupWithZero G₀']
[FunLike F G₀ G₀']
[MonoidWithZeroHomClass F G₀ G₀']
(f : F)
(a : G₀)


theorem IsIndObject.mk {A : Cᵒᵖ ⥤ Type v} (P : IndObjectPresentation A) : IsIndObject A

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

(P : CategoryTheory.Limits.IndObjectPresentation A)


/-- An isomorphism of differential objects gives an isomorphism of the underlying objects. -/
@[simps]
def isoApp {X Y : DifferentialObject S C} (f : X ≅ Y) : X.obj ≅ Y.obj

{X Y : CategoryTheory.DifferentialObject S C}

(CategoryTheory.DifferentialObject.isoApp f).hom = f.hom.f


theorem sin_ofReal_re (x : ℝ) : (sin x).re = Real.sin x


lemma sdiff_ne_right : x \ y ≠ y ↔ x ≠ ⊥ ∨ y ≠ ⊥

{α : Type u}
{x y : α}
[GeneralizedBooleanAlgebra α]

x \ y ≠ y ↔ x ≠ ⊥ ∨ y ≠ ⊥


theorem lieCharacter_apply_lie (χ : LieCharacter R L) (x y : L) : χ ⁅x, y⁆ = 0

{R : Type u}
{L : Type v}
[CommRing R]
[LieRing L]
[LieAlgebra R L]
(χ : LieAlgebra.LieCharacter R L)
(x y : L)


@[to_additive Set.AddAntidiagonal.finite_of_isWF]
theorem finite_of_isWF [LinearOrderedCancelCommMonoid α] {s t : Set α} (hs : s.IsWF) (ht : t.IsWF)
    (a) : (mulAntidiagonal s t a).Finite

{α : Type u_1}
[LinearOrderedCancelCommMonoid α]
{s t : Set α}
(hs : s.IsWF)
(ht : t.IsWF)
(a : α)


@[simp] theorem lcm_zero_left (m : Nat) : lcm 0 m = 0


theorem exists_coeff_ne_zero_iff_ne_zero : (∃ n : ℕ, coeff R n φ ≠ 0) ↔ φ ≠ 0

{R : Type u_1}
[Semiring R]
{φ : PowerSeries R}

(∃ n, (PowerSeries.coeff R n) φ ≠ 0) ↔ φ ≠ 0


@[simp, mfld_simps]
theorem pi_symm (ei : ∀ i, PartialEquiv (αi i) (βi i)) :
    (PartialEquiv.pi ei).symm = .pi fun i ↦ (ei i).symm

(ei : (i : ι) → PartialEquiv (αi i) (βi i))

(PartialEquiv.pi ei).symm = PartialEquiv.pi fun i => (ei i).symm


/--
If a functor `F : C ⥤ D` preserves exact sequences on the right hand side (i.e.
if `0 ⟶ A ⟶ B ⟶ C ⟶ 0` is exact then `F(A) ⟶ F(B) ⟶ F(C) ⟶ 0` is exact),
then it preserves epimorphisms.
-/
lemma preservesEpimorphisms_of_preserves_shortExact_right
    (h : ∀ (S : ShortComplex C), S.ShortExact → (S.map F).Exact ∧ Epi (F.map S.g)) :
    F.PreservesEpimorphisms

(h : ∀ (S : CategoryTheory.ShortComplex C), S.ShortExact → (S.map F).Exact ∧ CategoryTheory.Epi (F.map S.g))


/-- Like `Finsupp.mapDomain_zero`, but for the `1` we define in this file -/
@[simp]
theorem mapDomain_one {α : Type*} {β : Type*} {α₂ : Type*} [Semiring β] [Zero α] [Zero α₂]
    {F : Type*} [FunLike F α α₂] [ZeroHomClass F α α₂] (f : F) :
    (mapDomain f (1 : AddMonoidAlgebra β α) : AddMonoidAlgebra β α₂) =
      (1 : AddMonoidAlgebra β α₂)

{α : Type u_3}
{β : Type u_4}
{α₂ : Type u_5}
[Semiring β]
[Zero α]
[Zero α₂]
{F : Type u_6}
[FunLike F α α₂]
[ZeroHomClass F α α₂]
(f : F)


theorem differentiable_neg : Differentiable 𝕜 (Neg.neg : 𝕜 → 𝕜)

{𝕜 : Type u}
[NontriviallyNormedField 𝕜]


/-- `Multifork.toPiFork` as a functor. -/
@[simps]
noncomputable def toPiForkFunctor : Multifork I ⥤ Fork I.fstPiMap I.sndPiMap

(I : CategoryTheory.Limits.MulticospanIndex C)

{K₁ K₂ : CategoryTheory.Limits.Multifork I}


theorem Injective.subsingleton_image_iff (hf : Injective f) {s : Set α} :
    (f '' s).Subsingleton ↔ s.Subsingleton

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


/-- For every `x : R`, `seminormFromConst' hf1 hc hpm (c * x)` equals the product
  `seminormFromConst' hf1 hc hpm c * SeminormFromConst' hf1 hc hpm x`. -/
theorem seminormFromConst_const_mul (x : R) :
    seminormFromConst' hf1 hc hpm (c * x) =
      seminormFromConst' hf1 hc hpm c * seminormFromConst' hf1 hc hpm x

{R : Type u_1}
[CommRing R]
{c : R}
{f : RingSeminorm R}
(hf1 : f 1 ≤ 1)
(hc : f c ≠ 0)
(hpm : IsPowMul ⇑f)
(x : R)