File: Mathlib/Analysis/Convex/Basic.lean

full_name: Convex
code: /-- Convexity of sets. -/
def Convex : Prop 
goal: Prop

full_name: Convex.starConvex
code: theorem Convex.starConvex (hs : Convex 𝕜 s) (hx : x ∈ s) : StarConvex 𝕜 x s 
goal: StarConvex 𝕜 x s

full_name: convex_iff_segment_subset
code: theorem convex_iff_segment_subset : Convex 𝕜 s ↔ ∀ ⦃x⦄, x ∈ s → ∀ ⦃y⦄, y ∈ s → [x -[𝕜] y] ⊆ s 
goal: Convex 𝕜 s ↔ ∀ ⦃x : E⦄, x ∈ s → ∀ ⦃y : E⦄, y ∈ s → [x-[𝕜]y] ⊆ s

full_name: Convex.segment_subset
code: theorem Convex.segment_subset (h : Convex 𝕜 s) {x y : E} (hx : x ∈ s) (hy : y ∈ s) :
    [x -[𝕜] y] ⊆ s 
goal: [x-[𝕜]y] ⊆ s

full_name: Convex.openSegment_subset
code: theorem Convex.openSegment_subset (h : Convex 𝕜 s) {x y : E} (hx : x ∈ s) (hy : y ∈ s) :
    openSegment 𝕜 x y ⊆ s 
goal: openSegment 𝕜 x y ⊆ s

full_name: convex_iff_pointwise_add_subset
code: /-- Alternative definition of set convexity, in terms of pointwise set operations. -/
theorem convex_iff_pointwise_add_subset :
    Convex 𝕜 s ↔ ∀ ⦃a b : 𝕜⦄, 0 ≤ a → 0 ≤ b → a + b = 1 → a • s + b • s ⊆ s 
goal: Convex 𝕜 s ↔ ∀ ⦃a b : 𝕜⦄, 0 ≤ a → 0 ≤ b → a + b = 1 → a • s + b • s ⊆ s

full_name: convex_empty
code: theorem convex_empty : Convex 𝕜 (∅ : Set E) 
goal: Convex 𝕜 ∅

full_name: convex_univ
code: theorem convex_univ : Convex 𝕜 (Set.univ : Set E) 
goal: Convex 𝕜 Set.univ

full_name: Convex.inter
code: theorem Convex.inter {t : Set E} (hs : Convex 𝕜 s) (ht : Convex 𝕜 t) : Convex 𝕜 (s ∩ t) 
goal: Convex 𝕜 (s ∩ t)

full_name: convex_sInter
code: theorem convex_sInter {S : Set (Set E)} (h : ∀ s ∈ S, Convex 𝕜 s) : Convex 𝕜 (⋂₀ S) 
goal: Convex 𝕜 (⋂₀ S)

full_name: convex_iInter
code: theorem convex_iInter {ι : Sort*} {s : ι → Set E} (h : ∀ i, Convex 𝕜 (s i)) :
    Convex 𝕜 (⋂ i, s i) 
goal: Convex 𝕜 (⋂ i, s i)

full_name: convex_iInter₂
code: theorem convex_iInter₂ {ι : Sort*} {κ : ι → Sort*} {s : ∀ i, κ i → Set E}
    (h : ∀ i j, Convex 𝕜 (s i j)) : Convex 𝕜 (⋂ (i) (j), s i j) 
goal: Convex 𝕜 (⋂ i, ⋂ j, s i j)

full_name: Convex.prod
code: theorem Convex.prod {s : Set E} {t : Set F} (hs : Convex 𝕜 s) (ht : Convex 𝕜 t) :
    Convex 𝕜 (s ×ˢ t) 
goal: Convex 𝕜 (s ×ˢ t)

full_name: convex_pi
code: theorem convex_pi {ι : Type*} {E : ι → Type*} [∀ i, AddCommMonoid (E i)] [∀ i, SMul 𝕜 (E i)]
    {s : Set ι} {t : ∀ i, Set (E i)} (ht : ∀ ⦃i⦄, i ∈ s → Convex 𝕜 (t i)) : Convex 𝕜 (s.pi t) 
goal: Convex 𝕜 (s.pi t)

full_name: Directed.convex_iUnion
code: theorem Directed.convex_iUnion {ι : Sort*} {s : ι → Set E} (hdir : Directed (· ⊆ ·) s)
    (hc : ∀ ⦃i : ι⦄, Convex 𝕜 (s i)) : Convex 𝕜 (⋃ i, s i) 
goal: Convex 𝕜 (⋃ i, s i)

full_name: DirectedOn.convex_sUnion
code: theorem DirectedOn.convex_sUnion {c : Set (Set E)} (hdir : DirectedOn (· ⊆ ·) c)
    (hc : ∀ ⦃A : Set E⦄, A ∈ c → Convex 𝕜 A) : Convex 𝕜 (⋃₀ c) 
goal: Convex 𝕜 (⋃₀ c)

full_name: convex_iff_openSegment_subset
code: theorem convex_iff_openSegment_subset :
    Convex 𝕜 s ↔ ∀ ⦃x⦄, x ∈ s → ∀ ⦃y⦄, y ∈ s → openSegment 𝕜 x y ⊆ s 
goal: Convex 𝕜 s ↔ ∀ ⦃x : E⦄, x ∈ s → ∀ ⦃y : E⦄, y ∈ s → openSegment 𝕜 x y ⊆ s

full_name: convex_iff_forall_pos
code: theorem convex_iff_forall_pos :
    Convex 𝕜 s ↔
      ∀ ⦃x⦄, x ∈ s → ∀ ⦃y⦄, y ∈ s → ∀ ⦃a b : 𝕜⦄, 0 < a → 0 < b → a + b = 1 → a • x + b • y ∈ s 
goal: Convex 𝕜 s ↔ ∀ ⦃x : E⦄, x ∈ s → ∀ ⦃y : E⦄, y ∈ s → ∀ ⦃a b : 𝕜⦄, 0 < a → 0 < b → a + b = 1 → a • x + b • y ∈ s

full_name: convex_iff_pairwise_pos
code: theorem convex_iff_pairwise_pos : Convex 𝕜 s ↔
    s.Pairwise fun x y => ∀ ⦃a b : 𝕜⦄, 0 < a → 0 < b → a + b = 1 → a • x + b • y ∈ s 
goal: Convex 𝕜 s ↔ s.Pairwise fun x y => ∀ ⦃a b : 𝕜⦄, 0 < a → 0 < b → a + b = 1 → a • x + b • y ∈ s

full_name: Convex.starConvex_iff
code: theorem Convex.starConvex_iff (hs : Convex 𝕜 s) (h : s.Nonempty) : StarConvex 𝕜 x s ↔ x ∈ s 
goal: StarConvex 𝕜 x s ↔ x ∈ s

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

full_name: convex_singleton
code: theorem convex_singleton (c : E) : Convex 𝕜 ({c} : Set E) 
goal: Convex 𝕜 {c}

full_name: convex_zero
code: theorem convex_zero : Convex 𝕜 (0 : Set E) 
goal: Convex 𝕜 0

full_name: convex_segment
code: theorem convex_segment (x y : E) : Convex 𝕜 [x -[𝕜] y] 
goal: Convex 𝕜 [x-[𝕜]y]

full_name: Convex.linear_image
code: theorem Convex.linear_image (hs : Convex 𝕜 s) (f : E →ₗ[𝕜] F) : Convex 𝕜 (f '' s) 
goal: Convex 𝕜 (⇑f '' s)

full_name: Convex.is_linear_image
code: theorem Convex.is_linear_image (hs : Convex 𝕜 s) {f : E → F} (hf : IsLinearMap 𝕜 f) :
    Convex 𝕜 (f '' s) 
goal: Convex 𝕜 (f '' s)

full_name: Convex.linear_preimage
code: theorem Convex.linear_preimage {s : Set F} (hs : Convex 𝕜 s) (f : E →ₗ[𝕜] F) :
    Convex 𝕜 (f ⁻¹' s) 
goal: Convex 𝕜 (⇑f ⁻¹' s)

full_name: Convex.is_linear_preimage
code: theorem Convex.is_linear_preimage {s : Set F} (hs : Convex 𝕜 s) {f : E → F} (hf : IsLinearMap 𝕜 f) :
    Convex 𝕜 (f ⁻¹' s) 
goal: Convex 𝕜 (f ⁻¹' s)

full_name: Convex.add
code: theorem Convex.add {t : Set E} (hs : Convex 𝕜 s) (ht : Convex 𝕜 t) : Convex 𝕜 (s + t) 
goal: Convex 𝕜 (s + t)

full_name: convexAddSubmonoid
code: /-- The convex sets form an additive submonoid under pointwise addition. -/
def convexAddSubmonoid : AddSubmonoid (Set E) 
goal: AddSubmonoid (Set E)

full_name: coe_convexAddSubmonoid
code: @[simp, norm_cast]
theorem coe_convexAddSubmonoid : ↑(convexAddSubmonoid 𝕜 E) = {s : Set E | Convex 𝕜 s} 
goal: ↑(convexAddSubmonoid 𝕜 E) = {s | Convex 𝕜 s}

full_name: mem_convexAddSubmonoid
code: @[simp]
theorem mem_convexAddSubmonoid {s : Set E} : s ∈ convexAddSubmonoid 𝕜 E ↔ Convex 𝕜 s 
goal: s ∈ convexAddSubmonoid 𝕜 E ↔ Convex 𝕜 s

full_name: convex_list_sum
code: theorem convex_list_sum {l : List (Set E)} (h : ∀ i ∈ l, Convex 𝕜 i) : Convex 𝕜 l.sum 
goal: Convex 𝕜 l.sum

full_name: convex_multiset_sum
code: theorem convex_multiset_sum {s : Multiset (Set E)} (h : ∀ i ∈ s, Convex 𝕜 i) : Convex 𝕜 s.sum 
goal: Convex 𝕜 s.sum

full_name: convex_sum
code: theorem convex_sum {ι} {s : Finset ι} (t : ι → Set E) (h : ∀ i ∈ s, Convex 𝕜 (t i)) :
    Convex 𝕜 (∑ i ∈ s, t i) 
goal: Convex 𝕜 (∑ i ∈ s, t i)

full_name: Convex.vadd
code: theorem Convex.vadd (hs : Convex 𝕜 s) (z : E) : Convex 𝕜 (z +ᵥ s) 
goal: Convex 𝕜 (z +ᵥ s)

full_name: Convex.translate
code: theorem Convex.translate (hs : Convex 𝕜 s) (z : E) : Convex 𝕜 ((fun x => z + x) '' s) 
goal: Convex 𝕜 ((fun x => z + x) '' s)

full_name: Convex.translate_preimage_right
code: /-- The translation of a convex set is also convex. -/
theorem Convex.translate_preimage_right (hs : Convex 𝕜 s) (z : E) :
    Convex 𝕜 ((fun x => z + x) ⁻¹' s) 
goal: Convex 𝕜 ((fun x => z + x) ⁻¹' s)

full_name: Convex.translate_preimage_left
code: /-- The translation of a convex set is also convex. -/
theorem Convex.translate_preimage_left (hs : Convex 𝕜 s) (z : E) :
    Convex 𝕜 ((fun x => x + z) ⁻¹' s) 
goal: Convex 𝕜 ((fun x => x + z) ⁻¹' s)

full_name: convex_Iic
code: theorem convex_Iic (r : β) : Convex 𝕜 (Iic r) 
goal: Convex 𝕜 (Set.Iic r)

full_name: convex_Ici
code: theorem convex_Ici (r : β) : Convex 𝕜 (Ici r) 
goal: Convex 𝕜 (Set.Ici r)

full_name: convex_Icc
code: theorem convex_Icc (r s : β) : Convex 𝕜 (Icc r s) 
goal: Convex 𝕜 (Set.Icc r s)

full_name: convex_halfspace_le
code: theorem convex_halfspace_le {f : E → β} (h : IsLinearMap 𝕜 f) (r : β) : Convex 𝕜 { w | f w ≤ r } 
goal: Convex 𝕜 {w | f w ≤ r}

full_name: convex_halfspace_ge
code: theorem convex_halfspace_ge {f : E → β} (h : IsLinearMap 𝕜 f) (r : β) : Convex 𝕜 { w | r ≤ f w } 
goal: Convex 𝕜 {w | r ≤ f w}

full_name: convex_hyperplane
code: theorem convex_hyperplane {f : E → β} (h : IsLinearMap 𝕜 f) (r : β) : Convex 𝕜 { w | f w = r } 
goal: Convex 𝕜 {w | f w = r}

full_name: convex_Iio
code: theorem convex_Iio (r : β) : Convex 𝕜 (Iio r) 
goal: Convex 𝕜 (Set.Iio r)

full_name: convex_Ioi
code: theorem convex_Ioi (r : β) : Convex 𝕜 (Ioi r) 
goal: Convex 𝕜 (Set.Ioi r)

full_name: convex_Ioo
code: theorem convex_Ioo (r s : β) : Convex 𝕜 (Ioo r s) 
goal: Convex 𝕜 (Set.Ioo r s)

full_name: convex_Ico
code: theorem convex_Ico (r s : β) : Convex 𝕜 (Ico r s) 
goal: Convex 𝕜 (Set.Ico r s)

full_name: convex_Ioc
code: theorem convex_Ioc (r s : β) : Convex 𝕜 (Ioc r s) 
goal: Convex 𝕜 (Set.Ioc r s)

full_name: convex_halfspace_lt
code: theorem convex_halfspace_lt {f : E → β} (h : IsLinearMap 𝕜 f) (r : β) : Convex 𝕜 { w | f w < r } 
goal: Convex 𝕜 {w | f w < r}

full_name: convex_halfspace_gt
code: theorem convex_halfspace_gt {f : E → β} (h : IsLinearMap 𝕜 f) (r : β) : Convex 𝕜 { w | r < f w } 
goal: Convex 𝕜 {w | r < f w}

full_name: convex_uIcc
code: theorem convex_uIcc (r s : β) : Convex 𝕜 (uIcc r s) 
goal: Convex 𝕜 (Set.uIcc r s)

full_name: MonotoneOn.convex_le
code: theorem MonotoneOn.convex_le (hf : MonotoneOn f s) (hs : Convex 𝕜 s) (r : β) :
    Convex 𝕜 ({ x ∈ s | f x ≤ r }) 
goal: Convex 𝕜 {x | x ∈ s ∧ f x ≤ r}

full_name: MonotoneOn.convex_lt
code: theorem MonotoneOn.convex_lt (hf : MonotoneOn f s) (hs : Convex 𝕜 s) (r : β) :
    Convex 𝕜 ({ x ∈ s | f x < r }) 
goal: Convex 𝕜 {x | x ∈ s ∧ f x < r}

full_name: MonotoneOn.convex_ge
code: theorem MonotoneOn.convex_ge (hf : MonotoneOn f s) (hs : Convex 𝕜 s) (r : β) :
    Convex 𝕜 ({ x ∈ s | r ≤ f x }) 
goal: Convex 𝕜 {x | x ∈ s ∧ r ≤ f x}

full_name: MonotoneOn.convex_gt
code: theorem MonotoneOn.convex_gt (hf : MonotoneOn f s) (hs : Convex 𝕜 s) (r : β) :
    Convex 𝕜 ({ x ∈ s | r < f x }) 
goal: Convex 𝕜 {x | x ∈ s ∧ r < f x}

full_name: AntitoneOn.convex_le
code: theorem AntitoneOn.convex_le (hf : AntitoneOn f s) (hs : Convex 𝕜 s) (r : β) :
    Convex 𝕜 ({ x ∈ s | f x ≤ r }) 
goal: Convex 𝕜 {x | x ∈ s ∧ f x ≤ r}

full_name: AntitoneOn.convex_lt
code: theorem AntitoneOn.convex_lt (hf : AntitoneOn f s) (hs : Convex 𝕜 s) (r : β) :
    Convex 𝕜 ({ x ∈ s | f x < r }) 
goal: Convex 𝕜 {x | x ∈ s ∧ f x < r}

full_name: AntitoneOn.convex_ge
code: theorem AntitoneOn.convex_ge (hf : AntitoneOn f s) (hs : Convex 𝕜 s) (r : β) :
    Convex 𝕜 ({ x ∈ s | r ≤ f x }) 
goal: Convex 𝕜 {x | x ∈ s ∧ r ≤ f x}

full_name: AntitoneOn.convex_gt
code: theorem AntitoneOn.convex_gt (hf : AntitoneOn f s) (hs : Convex 𝕜 s) (r : β) :
    Convex 𝕜 ({ x ∈ s | r < f x }) 
goal: Convex 𝕜 {x | x ∈ s ∧ r < f x}

full_name: Monotone.convex_le
code: theorem Monotone.convex_le (hf : Monotone f) (r : β) : Convex 𝕜 { x | f x ≤ r } 
goal: Convex 𝕜 {x | f x ≤ r}

full_name: Monotone.convex_lt
code: theorem Monotone.convex_lt (hf : Monotone f) (r : β) : Convex 𝕜 { x | f x ≤ r } 
goal: Convex 𝕜 {x | f x ≤ r}

full_name: Monotone.convex_ge
code: theorem Monotone.convex_ge (hf : Monotone f) (r : β) : Convex 𝕜 { x | r ≤ f x } 
goal: Convex 𝕜 {x | r ≤ f x}

full_name: Monotone.convex_gt
code: theorem Monotone.convex_gt (hf : Monotone f) (r : β) : Convex 𝕜 { x | f x ≤ r } 
goal: Convex 𝕜 {x | f x ≤ r}

full_name: Antitone.convex_le
code: theorem Antitone.convex_le (hf : Antitone f) (r : β) : Convex 𝕜 { x | f x ≤ r } 
goal: Convex 𝕜 {x | f x ≤ r}

full_name: Antitone.convex_lt
code: theorem Antitone.convex_lt (hf : Antitone f) (r : β) : Convex 𝕜 { x | f x < r } 
goal: Convex 𝕜 {x | f x < r}

full_name: Antitone.convex_ge
code: theorem Antitone.convex_ge (hf : Antitone f) (r : β) : Convex 𝕜 { x | r ≤ f x } 
goal: Convex 𝕜 {x | r ≤ f x}

full_name: Antitone.convex_gt
code: theorem Antitone.convex_gt (hf : Antitone f) (r : β) : Convex 𝕜 { x | r < f x } 
goal: Convex 𝕜 {x | r < f x}

full_name: Convex.smul
code: theorem Convex.smul (hs : Convex 𝕜 s) (c : 𝕜) : Convex 𝕜 (c • s) 
goal: Convex 𝕜 (c • s)

full_name: Convex.smul_preimage
code: theorem Convex.smul_preimage (hs : Convex 𝕜 s) (c : 𝕜) : Convex 𝕜 ((fun z => c • z) ⁻¹' s) 
goal: Convex 𝕜 ((fun z => c • z) ⁻¹' s)

full_name: Convex.affinity
code: theorem Convex.affinity (hs : Convex 𝕜 s) (z : E) (c : 𝕜) :
    Convex 𝕜 ((fun x => z + c • x) '' s) 
goal: Convex 𝕜 ((fun x => z + c • x) '' s)

full_name: convex_openSegment
code: theorem convex_openSegment (a b : E) : Convex 𝕜 (openSegment 𝕜 a b) 
goal: Convex 𝕜 (openSegment 𝕜 a b)

full_name: convex_vadd
code: @[simp]
theorem convex_vadd (a : E) : Convex 𝕜 (a +ᵥ s) ↔ Convex 𝕜 s 
goal: Convex 𝕜 (a +ᵥ s) ↔ Convex 𝕜 s

full_name: Convex.add_smul_mem
code: theorem Convex.add_smul_mem (hs : Convex 𝕜 s) {x y : E} (hx : x ∈ s) (hy : x + y ∈ s) {t : 𝕜}
    (ht : t ∈ Icc (0 : 𝕜) 1) : x + t • y ∈ s 
goal: x + t • y ∈ s

full_name: Convex.smul_mem_of_zero_mem
code: theorem Convex.smul_mem_of_zero_mem (hs : Convex 𝕜 s) {x : E} (zero_mem : (0 : E) ∈ s) (hx : x ∈ s)
    {t : 𝕜} (ht : t ∈ Icc (0 : 𝕜) 1) : t • x ∈ s 
goal: t • x ∈ s

full_name: Convex.mapsTo_lineMap
code: theorem Convex.mapsTo_lineMap (h : Convex 𝕜 s) {x y : E} (hx : x ∈ s) (hy : y ∈ s) :
    MapsTo (AffineMap.lineMap x y) (Icc (0 : 𝕜) 1) s 
goal: Set.MapsTo (⇑(AffineMap.lineMap x y)) (Set.Icc 0 1) s

full_name: Convex.lineMap_mem
code: theorem Convex.lineMap_mem (h : Convex 𝕜 s) {x y : E} (hx : x ∈ s) (hy : y ∈ s) {t : 𝕜}
    (ht : t ∈ Icc 0 1) : AffineMap.lineMap x y t ∈ s 
goal: (AffineMap.lineMap x y) t ∈ s

full_name: Convex.add_smul_sub_mem
code: theorem Convex.add_smul_sub_mem (h : Convex 𝕜 s) {x y : E} (hx : x ∈ s) (hy : y ∈ s) {t : 𝕜}
    (ht : t ∈ Icc (0 : 𝕜) 1) : x + t • (y - x) ∈ s 
goal: x + t • (y - x) ∈ s

full_name: AffineSubspace.convex
code: /-- Affine subspaces are convex. -/
theorem AffineSubspace.convex (Q : AffineSubspace 𝕜 E) : Convex 𝕜 (Q : Set E) 
goal: Convex 𝕜 ↑Q

full_name: Convex.affine_preimage
code: /-- The preimage of a convex set under an affine map is convex. -/
theorem Convex.affine_preimage (f : E →ᵃ[𝕜] F) {s : Set F} (hs : Convex 𝕜 s) : Convex 𝕜 (f ⁻¹' s) 
goal: Convex 𝕜 (⇑f ⁻¹' s)

full_name: Convex.affine_image
code: /-- The image of a convex set under an affine map is convex. -/
theorem Convex.affine_image (f : E →ᵃ[𝕜] F) (hs : Convex 𝕜 s) : Convex 𝕜 (f '' s) 
goal: Convex 𝕜 (⇑f '' s)

full_name: Convex.neg
code: theorem Convex.neg (hs : Convex 𝕜 s) : Convex 𝕜 (-s) 
goal: Convex 𝕜 (-s)

full_name: Convex.sub
code: theorem Convex.sub (hs : Convex 𝕜 s) (ht : Convex 𝕜 t) : Convex 𝕜 (s - t) 
goal: Convex 𝕜 (s - t)

full_name: Convex_subadditive_le
code: theorem Convex_subadditive_le [SMul 𝕜 E] {f : E → 𝕜} (hf1 : ∀ x y, f (x + y) ≤ (f x) + (f y))
    (hf2 : ∀ ⦃c⦄ x, 0 ≤ c → f (c • x) ≤ c * f x) (B : 𝕜) :
    Convex 𝕜 { x | f x ≤ B } 
goal: Convex 𝕜 {x | f x ≤ B}

full_name: convex_iff_div
code: /-- Alternative definition of set convexity, using division. -/
theorem convex_iff_div :
    Convex 𝕜 s ↔ ∀ ⦃x⦄, x ∈ s → ∀ ⦃y⦄, y ∈ s →
      ∀ ⦃a b : 𝕜⦄, 0 ≤ a → 0 ≤ b → 0 < a + b → (a / (a + b)) • x + (b / (a + b)) • y ∈ s 
goal: Convex 𝕜 s ↔
  ∀ ⦃x : E⦄,
    x ∈ s → ∀ ⦃y : E⦄, y ∈ s → ∀ ⦃a b : 𝕜⦄, 0 ≤ a → 0 ≤ b → 0 < a + b → (a / (a + b)) • x + (b / (a + b)) • y ∈ s

full_name: Convex.mem_smul_of_zero_mem
code: theorem Convex.mem_smul_of_zero_mem (h : Convex 𝕜 s) {x : E} (zero_mem : (0 : E) ∈ s) (hx : x ∈ s)
    {t : 𝕜} (ht : 1 ≤ t) : x ∈ t • s 
goal: x ∈ t • s

full_name: Convex.exists_mem_add_smul_eq
code: theorem Convex.exists_mem_add_smul_eq (h : Convex 𝕜 s) {x y : E} {p q : 𝕜} (hx : x ∈ s) (hy : y ∈ s)
    (hp : 0 ≤ p) (hq : 0 ≤ q) : ∃ z ∈ s, (p + q) • z = p • x + q • y 
goal: ∃ z ∈ s, (p + q) • z = p • x + q • y

full_name: Convex.add_smul
code: theorem Convex.add_smul (h_conv : Convex 𝕜 s) {p q : 𝕜} (hp : 0 ≤ p) (hq : 0 ≤ q) :
    (p + q) • s = p • s + q • s 
goal: (p + q) • s = p • s + q • s

full_name: Set.OrdConnected.convex_of_chain
code: theorem Set.OrdConnected.convex_of_chain [OrderedSemiring 𝕜] [OrderedAddCommMonoid E] [Module 𝕜 E]
    [OrderedSMul 𝕜 E] {s : Set E} (hs : s.OrdConnected) (h : IsChain (· ≤ ·) s) : Convex 𝕜 s 
goal: Convex 𝕜 s

full_name: Set.OrdConnected.convex
code: theorem Set.OrdConnected.convex [OrderedSemiring 𝕜] [LinearOrderedAddCommMonoid E] [Module 𝕜 E]
    [OrderedSMul 𝕜 E] {s : Set E} (hs : s.OrdConnected) : Convex 𝕜 s 
goal: Convex 𝕜 s

full_name: convex_iff_ordConnected
code: theorem convex_iff_ordConnected [LinearOrderedField 𝕜] {s : Set 𝕜} :
    Convex 𝕜 s ↔ s.OrdConnected 
goal: Convex 𝕜 s ↔ s.OrdConnected

full_name: Submodule.convex
code: protected theorem convex (K : Submodule 𝕜 E) : Convex 𝕜 (↑K : Set E) 
goal: Convex 𝕜 ↑K

full_name: Submodule.starConvex
code: protected theorem starConvex (K : Submodule 𝕜 E) : StarConvex 𝕜 (0 : E) K 
goal: StarConvex 𝕜 0 ↑K

full_name: stdSimplex
code: /-- The standard simplex in the space of functions `ι → 𝕜` is the set of vectors with non-negative
coordinates with total sum `1`. This is the free object in the category of convex spaces. -/
def stdSimplex : Set (ι → 𝕜) 
goal: Set (ι → 𝕜)

full_name: stdSimplex_eq_inter
code: theorem stdSimplex_eq_inter : stdSimplex 𝕜 ι = (⋂ x, { f | 0 ≤ f x }) ∩ { f | ∑ x, f x = 1 } 
goal: stdSimplex 𝕜 ι = (⋂ x, {f | 0 ≤ f x}) ∩ {f | ∑ x : ι, f x = 1}

full_name: convex_stdSimplex
code: theorem convex_stdSimplex : Convex 𝕜 (stdSimplex 𝕜 ι) 
goal: Convex 𝕜 (stdSimplex 𝕜 ι)

full_name: stdSimplex_of_subsingleton
code: @[nontriviality] lemma stdSimplex_of_subsingleton [Subsingleton 𝕜] : stdSimplex 𝕜 ι = univ 
goal: stdSimplex 𝕜 ι = Set.univ

full_name: stdSimplex_of_isEmpty_index
code: /-- The standard simplex in the zero-dimensional space is empty. -/
lemma stdSimplex_of_isEmpty_index [IsEmpty ι] [Nontrivial 𝕜] : stdSimplex 𝕜 ι = ∅ 
goal: stdSimplex 𝕜 ι = ∅

full_name: stdSimplex_unique
code: lemma stdSimplex_unique [Unique ι] : stdSimplex 𝕜 ι = {fun _ ↦ 1} 
goal: stdSimplex 𝕜 ι = {fun x => 1}

full_name: single_mem_stdSimplex
code: theorem single_mem_stdSimplex (i : ι) : Pi.single i 1 ∈ stdSimplex 𝕜 ι 
goal: Pi.single i 1 ∈ stdSimplex 𝕜 ι

full_name: ite_eq_mem_stdSimplex
code: theorem ite_eq_mem_stdSimplex (i : ι) : (if i = · then (1 : 𝕜) else 0) ∈ stdSimplex 𝕜 ι 
goal: (fun x => if i = x then 1 else 0) ∈ stdSimplex 𝕜 ι

full_name: segment_single_subset_stdSimplex
code: /-- The edges are contained in the simplex. -/
lemma segment_single_subset_stdSimplex (i j : ι) :
    ([Pi.single i 1 -[𝕜] Pi.single j 1] : Set (ι → 𝕜)) ⊆ stdSimplex 𝕜 ι 
goal: [Pi.single i 1-[𝕜]Pi.single j 1] ⊆ stdSimplex 𝕜 ι

full_name: stdSimplex_fin_two
code: lemma stdSimplex_fin_two :
    stdSimplex 𝕜 (Fin 2) = ([Pi.single 0 1 -[𝕜] Pi.single 1 1] : Set (Fin 2 → 𝕜)) 
goal: stdSimplex 𝕜 (Fin 2) = [Pi.single 0 1-[𝕜]Pi.single 1 1]

full_name: stdSimplexEquivIcc_apply_coe
code: /-- The standard one-dimensional simplex in `Fin 2 → 𝕜` is equivalent to the unit interval. -/
@[simps (config := .asFn)]
def stdSimplexEquivIcc : stdSimplex 𝕜 (Fin 2) ≃ Icc (0 : 𝕜) 1 
goal: ↑((stdSimplexEquivIcc 𝕜) f) = ↑f 0

full_name: stdSimplexEquivIcc
code: /-- The standard one-dimensional simplex in `Fin 2 → 𝕜` is equivalent to the unit interval. -/
@[simps (config := .asFn)]
def stdSimplexEquivIcc : stdSimplex 𝕜 (Fin 2) ≃ Icc (0 : 𝕜) 1 
goal: ↑(stdSimplex 𝕜 (Fin 2)) ≃ ↑(Set.Icc 0 1)

full_name: stdSimplexEquivIcc_symm_apply_coe
code: /-- The standard one-dimensional simplex in `Fin 2 → 𝕜` is equivalent to the unit interval. -/
@[simps (config := .asFn)]
def stdSimplexEquivIcc : stdSimplex 𝕜 (Fin 2) ≃ Icc (0 : 𝕜) 1 
goal: ↑((stdSimplexEquivIcc 𝕜).symm x) = ![↑x, 1 - ↑x]