File: Mathlib/Order/Directed.lean

full_name: «_aux_Mathlib_Order_Directed___macroRules_term_≼__1»
code: /-- Local notation for a relation -/
local infixl:50 " ≼ " => r
goal: Lean.Macro

full_name: Directed
code: /-- A family of elements of α is directed (with respect to a relation `≼` on α)
  if there is a member of the family `≼`-above any pair in the family.  -/
def Directed (f : ι → α) 
goal: Prop

full_name: DirectedOn
code: /-- A subset of α is directed if there is an element of the set `≼`-above any
  pair of elements in the set. -/
def DirectedOn (s : Set α) 
goal: Prop

full_name: directedOn_iff_directed
code: theorem directedOn_iff_directed {s} : @DirectedOn α r s ↔ Directed r (Subtype.val : s → α) 
goal: DirectedOn r s ↔ Directed r Subtype.val

full_name: directedOn_range
code: theorem directedOn_range {f : ι → α} : Directed r f ↔ DirectedOn r (Set.range f) 
goal: Directed r f ↔ DirectedOn r (Set.range f)

full_name: directedOn_image
code: theorem directedOn_image {s : Set β} {f : β → α} :
    DirectedOn r (f '' s) ↔ DirectedOn (f ⁻¹'o r) s 
goal: DirectedOn r (f '' s) ↔ DirectedOn (f ⁻¹'o r) s

full_name: DirectedOn.mono'
code: theorem DirectedOn.mono' {s : Set α} (hs : DirectedOn r s)
    (h : ∀ ⦃a⦄, a ∈ s → ∀ ⦃b⦄, b ∈ s → r a b → r' a b) : DirectedOn r' s 
goal: DirectedOn r' s

full_name: DirectedOn.mono
code: theorem DirectedOn.mono {s : Set α} (h : DirectedOn r s) (H : ∀ ⦃a b⦄, r a b → r' a b) :
    DirectedOn r' s 
goal: DirectedOn r' s

full_name: directed_comp
code: theorem directed_comp {ι} {f : ι → β} {g : β → α} : Directed r (g ∘ f) ↔ Directed (g ⁻¹'o r) f 
goal: Directed r (g ∘ f) ↔ Directed (g ⁻¹'o r) f

full_name: Directed.mono
code: theorem Directed.mono {s : α → α → Prop} {ι} {f : ι → α} (H : ∀ a b, r a b → s a b)
    (h : Directed r f) : Directed s f 
goal: Directed s f

full_name: Directed.mono_comp
code: theorem Directed.mono_comp (r : α → α → Prop) {ι} {rb : β → β → Prop} {g : α → β} {f : ι → α}
    (hg : ∀ ⦃x y⦄, r x y → rb (g x) (g y)) (hf : Directed r f) : Directed rb (g ∘ f) 
goal: Directed rb (g ∘ f)

full_name: directedOn_of_sup_mem
code: /-- A set stable by supremum is `≤`-directed. -/
theorem directedOn_of_sup_mem [SemilatticeSup α] {S : Set α}
    (H : ∀ ⦃i j⦄, i ∈ S → j ∈ S → i ⊔ j ∈ S) : DirectedOn (· ≤ ·) S 
goal: DirectedOn (fun x x_1 => x ≤ x_1) S

full_name: Directed.extend_bot
code: theorem Directed.extend_bot [Preorder α] [OrderBot α] {e : ι → β} {f : ι → α}
    (hf : Directed (· ≤ ·) f) (he : Function.Injective e) :
    Directed (· ≤ ·) (Function.extend e f ⊥) 
goal: Directed (fun x x_1 => x ≤ x_1) (Function.extend e f ⊥)

full_name: directedOn_of_inf_mem
code: /-- A set stable by infimum is `≥`-directed. -/
theorem directedOn_of_inf_mem [SemilatticeInf α] {S : Set α}
    (H : ∀ ⦃i j⦄, i ∈ S → j ∈ S → i ⊓ j ∈ S) : DirectedOn (· ≥ ·) S 
goal: DirectedOn (fun x x_1 => x ≥ x_1) S

full_name: IsTotal.directed
code: theorem IsTotal.directed [IsTotal α r] (f : ι → α) : Directed r f 
goal: Directed r f

full_name: IsDirected.directed
code: /-- `IsDirected α r` states that for any elements `a`, `b` there exists an element `c` such that
`r a c` and `r b c`. -/
class IsDirected (α : Type*) (r : α → α → Prop) : Prop where
  /-- For every pair of elements `a` and `b` there is a `c` such that `r a c` and `r b c` -/
  directed (a b : α) : ∃ c, r a c ∧ r b c
goal: ∃ c, r a c ∧ r b c

full_name: IsDirected
code: /-- `IsDirected α r` states that for any elements `a`, `b` there exists an element `c` such that
`r a c` and `r b c`. -/
class IsDirected (α : Type*) (r : α → α → Prop) : Prop where
  /-- For every pair of elements `a` and `b` there is a `c` such that `r a c` and `r b c` -/
  directed (a b : α) : ∃ c, r a c ∧ r b c
goal: Prop

full_name: directed_of
code: theorem directed_of (r : α → α → Prop) [IsDirected α r] (a b : α) : ∃ c, r a c ∧ r b c 
goal: ∃ c, r a c ∧ r b c

full_name: directed_id
code: theorem directed_id [IsDirected α r] : Directed r id 
goal: Directed r id

full_name: directed_id_iff
code: theorem directed_id_iff : Directed r id ↔ IsDirected α r 
goal: Directed r id ↔ IsDirected α r

full_name: directedOn_univ
code: theorem directedOn_univ [IsDirected α r] : DirectedOn r Set.univ 
goal: DirectedOn r Set.univ

full_name: directedOn_univ_iff
code: theorem directedOn_univ_iff : DirectedOn r Set.univ ↔ IsDirected α r 
goal: DirectedOn r Set.univ ↔ IsDirected α r

full_name: IsTotal.to_isDirected
code: instance (priority := 100) IsTotal.to_isDirected [IsTotal α r] : IsDirected α r 
goal: IsDirected α r

full_name: isDirected_mono
code: theorem isDirected_mono [IsDirected α r] (h : ∀ ⦃a b⦄, r a b → s a b) : IsDirected α s 
goal: IsDirected α s

full_name: exists_ge_ge
code: theorem exists_ge_ge [LE α] [IsDirected α (· ≤ ·)] (a b : α) : ∃ c, a ≤ c ∧ b ≤ c 
goal: ∃ c, a ≤ c ∧ b ≤ c

full_name: exists_le_le
code: theorem exists_le_le [LE α] [IsDirected α (· ≥ ·)] (a b : α) : ∃ c, c ≤ a ∧ c ≤ b 
goal: ∃ c ≤ a, c ≤ b

full_name: OrderDual.isDirected_ge
code: instance OrderDual.isDirected_ge [LE α] [IsDirected α (· ≤ ·)] : IsDirected αᵒᵈ (· ≥ ·) 
goal: IsDirected αᵒᵈ fun x x_1 => x ≥ x_1

full_name: OrderDual.isDirected_le
code: instance OrderDual.isDirected_le [LE α] [IsDirected α (· ≥ ·)] : IsDirected αᵒᵈ (· ≤ ·) 
goal: IsDirected αᵒᵈ fun x x_1 => x ≤ x_1

full_name: directed_of_isDirected_le
code: /-- A monotone function on an upwards-directed type is directed. -/
theorem directed_of_isDirected_le [LE α] [IsDirected α (· ≤ ·)] {f : α → β} {r : β → β → Prop}
    (H : ∀ ⦃i j⦄, i ≤ j → r (f i) (f j)) : Directed r f 
goal: Directed r f

full_name: Monotone.directed_le
code: theorem Monotone.directed_le [Preorder α] [IsDirected α (· ≤ ·)] [Preorder β] {f : α → β} :
    Monotone f → Directed (· ≤ ·) f 
goal: Monotone f → Directed (fun x x_1 => x ≤ x_1) f

full_name: Antitone.directed_ge
code: theorem Antitone.directed_ge [Preorder α] [IsDirected α (· ≤ ·)] [Preorder β] {f : α → β}
    (hf : Antitone f) : Directed (· ≥ ·) f 
goal: Directed (fun x x_1 => x ≥ x_1) f

full_name: directed_of_isDirected_ge
code: /-- An antitone function on a downwards-directed type is directed. -/
theorem directed_of_isDirected_ge [LE α] [IsDirected α (· ≥ ·)] {r : β → β → Prop} {f : α → β}
    (hf : ∀ a₁ a₂, a₁ ≤ a₂ → r (f a₂) (f a₁)) : Directed r f 
goal: Directed r f

full_name: Monotone.directed_ge
code: theorem Monotone.directed_ge [Preorder α] [IsDirected α (· ≥ ·)] [Preorder β] {f : α → β}
    (hf : Monotone f) : Directed (· ≥ ·) f 
goal: Directed (fun x x_1 => x ≥ x_1) f

full_name: Antitone.directed_le
code: theorem Antitone.directed_le [Preorder α] [IsDirected α (· ≥ ·)] [Preorder β] {f : α → β}
    (hf : Antitone f) : Directed (· ≤ ·) f 
goal: Directed (fun x x_1 => x ≤ x_1) f

full_name: DirectedOn.insert
code: protected theorem DirectedOn.insert (h : Reflexive r) (a : α) {s : Set α} (hd : DirectedOn r s)
    (ha : ∀ b ∈ s, ∃ c ∈ s, a ≼ c ∧ b ≼ c) : DirectedOn r (insert a s) 
goal: DirectedOn r (insert a s)

full_name: directedOn_singleton
code: theorem directedOn_singleton (h : Reflexive r) (a : α) : DirectedOn r ({a} : Set α) 
goal: DirectedOn r {a}

full_name: directedOn_pair
code: theorem directedOn_pair (h : Reflexive r) {a b : α} (hab : a ≼ b) : DirectedOn r ({a, b} : Set α) 
goal: DirectedOn r {a, b}

full_name: directedOn_pair'
code: theorem directedOn_pair' (h : Reflexive r) {a b : α} (hab : a ≼ b) :
    DirectedOn r ({b, a} : Set α) 
goal: DirectedOn r {b, a}

full_name: IsMin.isBot
code: protected theorem IsMin.isBot [IsDirected α (· ≥ ·)] (h : IsMin a) : IsBot a 
goal: IsBot a

full_name: IsMax.isTop
code: protected theorem IsMax.isTop [IsDirected α (· ≤ ·)] (h : IsMax a) : IsTop a 
goal: IsTop a

full_name: DirectedOn.is_bot_of_is_min
code: lemma DirectedOn.is_bot_of_is_min {s : Set α} (hd : DirectedOn (· ≥ ·) s)
    {m} (hm : m ∈ s) (hmin : ∀ a ∈ s, a ≤ m → m ≤ a) : ∀ a ∈ s, m ≤ a 
goal: a ∈ s → m ≤ a

full_name: DirectedOn.is_top_of_is_max
code: lemma DirectedOn.is_top_of_is_max {s : Set α} (hd : DirectedOn (· ≤ ·) s)
    {m} (hm : m ∈ s) (hmax : ∀ a ∈ s, m ≤ a → a ≤ m) : ∀ a ∈ s, a ≤ m 
goal: a ∈ s → a ≤ m

full_name: isTop_or_exists_gt
code: theorem isTop_or_exists_gt [IsDirected α (· ≤ ·)] (a : α) : IsTop a ∨ ∃ b, a < b 
goal: IsTop a ∨ ∃ b, a < b

full_name: isBot_or_exists_lt
code: theorem isBot_or_exists_lt [IsDirected α (· ≥ ·)] (a : α) : IsBot a ∨ ∃ b, b < a 
goal: IsBot a ∨ ∃ b, b < a

full_name: isBot_iff_isMin
code: theorem isBot_iff_isMin [IsDirected α (· ≥ ·)] : IsBot a ↔ IsMin a 
goal: IsBot a ↔ IsMin a

full_name: isTop_iff_isMax
code: theorem isTop_iff_isMax [IsDirected α (· ≤ ·)] : IsTop a ↔ IsMax a 
goal: IsTop a ↔ IsMax a

full_name: exists_lt_of_directed_ge
code: theorem exists_lt_of_directed_ge [IsDirected β (· ≥ ·)] [Nontrivial β] : ∃ a b : β, a < b 
goal: ∃ a b, a < b

full_name: exists_lt_of_directed_le
code: theorem exists_lt_of_directed_le [IsDirected β (· ≤ ·)] [Nontrivial β] : ∃ a b : β, a < b 
goal: ∃ a b, a < b

full_name: constant_of_monotone_antitone
code: /-- If `f` is monotone and antitone on a directed order, then `f` is constant. -/
lemma constant_of_monotone_antitone [IsDirected α (· ≤ ·)] (hf : Monotone f) (hf' : Antitone f)
    (a b : α) : f a = f b 
goal: f a = f b

full_name: constant_of_monotoneOn_antitoneOn
code: /-- If `f` is monotone and antitone on a directed set `s`, then `f` is constant on `s`. -/
lemma constant_of_monotoneOn_antitoneOn (hf : MonotoneOn f s) (hf' : AntitoneOn f s)
    (hs : DirectedOn (· ≤ ·) s) : ∀ ⦃a⦄, a ∈ s → ∀ ⦃b⦄, b ∈ s → f a = f b 
goal: a ∈ s → ∀ ⦃b : α⦄, b ∈ s → f a = f b

full_name: SemilatticeSup.to_isDirected_le
code: instance (priority := 100) SemilatticeSup.to_isDirected_le [SemilatticeSup α] :
    IsDirected α (· ≤ ·) 
goal: IsDirected α fun x x_1 => x ≤ x_1

full_name: SemilatticeInf.to_isDirected_ge
code: instance (priority := 100) SemilatticeInf.to_isDirected_ge [SemilatticeInf α] :
    IsDirected α (· ≥ ·) 
goal: IsDirected α fun x x_1 => x ≥ x_1

full_name: OrderTop.to_isDirected_le
code: instance (priority := 100) OrderTop.to_isDirected_le [LE α] [OrderTop α] : IsDirected α (· ≤ ·) 
goal: IsDirected α fun x x_1 => x ≤ x_1

full_name: OrderBot.to_isDirected_ge
code: instance (priority := 100) OrderBot.to_isDirected_ge [LE α] [OrderBot α] : IsDirected α (· ≥ ·) 
goal: IsDirected α fun x x_1 => x ≥ x_1