Theorem: IsClosed.mem_of_ge_of_forall_exists_gt
File: Mathlib/Topology/Algebra/Order/IntermediateValue.lean

tactic: let S := s ∩ Icc a b
state_before: α : Type u
β : Type v
γ : Type w
inst✝⁶ : ConditionallyCompleteLinearOrder α
inst✝⁵ : TopologicalSpace α
inst✝⁴ : OrderTopology α
inst✝³ : ConditionallyCompleteLinearOrder β
inst✝² : TopologicalSpace β
inst✝¹ : OrderTopology β
inst✝ : Nonempty γ
a b : α
s : Set α
hs : IsClosed (s ∩ Icc a b)
ha : a ∈ s
hab : a ≤ b
hgt : ∀ (x : α), x ∈ s ∩ Ico a b → Set.Nonempty (s ∩ Ioc x b)
⊢ b ∈ s

tactic: replace ha : a ∈ S
state_before: α : Type u
β : Type v
γ : Type w
inst✝⁶ : ConditionallyCompleteLinearOrder α
inst✝⁵ : TopologicalSpace α
inst✝⁴ : OrderTopology α
inst✝³ : ConditionallyCompleteLinearOrder β
inst✝² : TopologicalSpace β
inst✝¹ : OrderTopology β
inst✝ : Nonempty γ
a b : α
s : Set α
hs : IsClosed (s ∩ Icc a b)
ha : a ∈ s
hab : a ≤ b
hgt : ∀ (x : α), x ∈ s ∩ Ico a b → Set.Nonempty (s ∩ Ioc x b)
S : Set α := s ∩ Icc a b
⊢ b ∈ s

tactic: exact ⟨ha, left_mem_Icc.2 hab⟩
state_before: case ha
α : Type u
β : Type v
γ : Type w
inst✝⁶ : ConditionallyCompleteLinearOrder α
inst✝⁵ : TopologicalSpace α
inst✝⁴ : OrderTopology α
inst✝³ : ConditionallyCompleteLinearOrder β
inst✝² : TopologicalSpace β
inst✝¹ : OrderTopology β
inst✝ : Nonempty γ
a b : α
s : Set α
hs : IsClosed (s ∩ Icc a b)
ha : a ∈ s
hab : a ≤ b
hgt : ∀ (x : α), x ∈ s ∩ Ico a b → Set.Nonempty (s ∩ Ioc x b)
S : Set α := s ∩ Icc a b
⊢ a ∈ S

α : Type u
β : Type v
γ : Type w
inst✝⁶ : ConditionallyCompleteLinearOrder α
inst✝⁵ : TopologicalSpace α
inst✝⁴ : OrderTopology α
inst✝³ : ConditionallyCompleteLinearOrder β
inst✝² : TopologicalSpace β
inst✝¹ : OrderTopology β
inst✝ : Nonempty γ
a b : α
s : Set α
hs : IsClosed (s ∩ Icc a b)
hab : a ≤ b
hgt : ∀ (x : α), x ∈ s ∩ Ico a b → Set.Nonempty (s ∩ Ioc x b)
S : Set α := s ∩ Icc a b
ha : a ∈ S
⊢ b ∈ s

tactic: have Sbd : BddAbove S := ⟨b, fun z hz => hz.2.2⟩
state_before: α : Type u
β : Type v
γ : Type w
inst✝⁶ : ConditionallyCompleteLinearOrder α
inst✝⁵ : TopologicalSpace α
inst✝⁴ : OrderTopology α
inst✝³ : ConditionallyCompleteLinearOrder β
inst✝² : TopologicalSpace β
inst✝¹ : OrderTopology β
inst✝ : Nonempty γ
a b : α
s : Set α
hs : IsClosed (s ∩ Icc a b)
hab : a ≤ b
hgt : ∀ (x : α), x ∈ s ∩ Ico a b → Set.Nonempty (s ∩ Ioc x b)
S : Set α := s ∩ Icc a b
ha : a ∈ S
⊢ b ∈ s

tactic: let c := sSup (s ∩ Icc a b)
state_before: α : Type u
β : Type v
γ : Type w
inst✝⁶ : ConditionallyCompleteLinearOrder α
inst✝⁵ : TopologicalSpace α
inst✝⁴ : OrderTopology α
inst✝³ : ConditionallyCompleteLinearOrder β
inst✝² : TopologicalSpace β
inst✝¹ : OrderTopology β
inst✝ : Nonempty γ
a b : α
s : Set α
hs : IsClosed (s ∩ Icc a b)
hab : a ≤ b
hgt : ∀ (x : α), x ∈ s ∩ Ico a b → Set.Nonempty (s ∩ Ioc x b)
S : Set α := s ∩ Icc a b
ha : a ∈ S
Sbd : BddAbove S
⊢ b ∈ s

tactic: have c_mem : c ∈ S := hs.csSup_mem ⟨_, ha⟩ Sbd
state_before: α : Type u
β : Type v
γ : Type w
inst✝⁶ : ConditionallyCompleteLinearOrder α
inst✝⁵ : TopologicalSpace α
inst✝⁴ : OrderTopology α
inst✝³ : ConditionallyCompleteLinearOrder β
inst✝² : TopologicalSpace β
inst✝¹ : OrderTopology β
inst✝ : Nonempty γ
a b : α
s : Set α
hs : IsClosed (s ∩ Icc a b)
hab : a ≤ b
hgt : ∀ (x : α), x ∈ s ∩ Ico a b → Set.Nonempty (s ∩ Ioc x b)
S : Set α := s ∩ Icc a b
ha : a ∈ S
Sbd : BddAbove S
c : α := sSup (s ∩ Icc a b)
⊢ b ∈ s

tactic: have c_le : c ≤ b := csSup_le ⟨_, ha⟩ fun x hx => hx.2.2
state_before: α : Type u
β : Type v
γ : Type w
inst✝⁶ : ConditionallyCompleteLinearOrder α
inst✝⁵ : TopologicalSpace α
inst✝⁴ : OrderTopology α
inst✝³ : ConditionallyCompleteLinearOrder β
inst✝² : TopologicalSpace β
inst✝¹ : OrderTopology β
inst✝ : Nonempty γ
a b : α
s : Set α
hs : IsClosed (s ∩ Icc a b)
hab : a ≤ b
hgt : ∀ (x : α), x ∈ s ∩ Ico a b → Set.Nonempty (s ∩ Ioc x b)
S : Set α := s ∩ Icc a b
ha : a ∈ S
Sbd : BddAbove S
c : α := sSup (s ∩ Icc a b)
c_mem : c ∈ S
⊢ b ∈ s

tactic: cases' eq_or_lt_of_le c_le with hc hc
state_before: α : Type u
β : Type v
γ : Type w
inst✝⁶ : ConditionallyCompleteLinearOrder α
inst✝⁵ : TopologicalSpace α
inst✝⁴ : OrderTopology α
inst✝³ : ConditionallyCompleteLinearOrder β
inst✝² : TopologicalSpace β
inst✝¹ : OrderTopology β
inst✝ : Nonempty γ
a b : α
s : Set α
hs : IsClosed (s ∩ Icc a b)
hab : a ≤ b
hgt : ∀ (x : α), x ∈ s ∩ Ico a b → Set.Nonempty (s ∩ Ioc x b)
S : Set α := s ∩ Icc a b
ha : a ∈ S
Sbd : BddAbove S
c : α := sSup (s ∩ Icc a b)
c_mem : c ∈ S
c_le : c ≤ b
⊢ b ∈ s

tactic: exact hc ▸ c_mem.1
state_before: case inl
α : Type u
β : Type v
γ : Type w
inst✝⁶ : ConditionallyCompleteLinearOrder α
inst✝⁵ : TopologicalSpace α
inst✝⁴ : OrderTopology α
inst✝³ : ConditionallyCompleteLinearOrder β
inst✝² : TopologicalSpace β
inst✝¹ : OrderTopology β
inst✝ : Nonempty γ
a b : α
s : Set α
hs : IsClosed (s ∩ Icc a b)
hab : a ≤ b
hgt : ∀ (x : α), x ∈ s ∩ Ico a b → Set.Nonempty (s ∩ Ioc x b)
S : Set α := s ∩ Icc a b
ha : a ∈ S
Sbd : BddAbove S
c : α := sSup (s ∩ Icc a b)
c_mem : c ∈ S
c_le : c ≤ b
hc : c = b
⊢ b ∈ s

case inr
α : Type u
β : Type v
γ : Type w
inst✝⁶ : ConditionallyCompleteLinearOrder α
inst✝⁵ : TopologicalSpace α
inst✝⁴ : OrderTopology α
inst✝³ : ConditionallyCompleteLinearOrder β
inst✝² : TopologicalSpace β
inst✝¹ : OrderTopology β
inst✝ : Nonempty γ
a b : α
s : Set α
hs : IsClosed (s ∩ Icc a b)
hab : a ≤ b
hgt : ∀ (x : α), x ∈ s ∩ Ico a b → Set.Nonempty (s ∩ Ioc x b)
S : Set α := s ∩ Icc a b
ha : a ∈ S
Sbd : BddAbove S
c : α := sSup (s ∩ Icc a b)
c_mem : c ∈ S
c_le : c ≤ b
hc : c < b
⊢ b ∈ s

tactic: exfalso
state_before: case inr
α : Type u
β : Type v
γ : Type w
inst✝⁶ : ConditionallyCompleteLinearOrder α
inst✝⁵ : TopologicalSpace α
inst✝⁴ : OrderTopology α
inst✝³ : ConditionallyCompleteLinearOrder β
inst✝² : TopologicalSpace β
inst✝¹ : OrderTopology β
inst✝ : Nonempty γ
a b : α
s : Set α
hs : IsClosed (s ∩ Icc a b)
hab : a ≤ b
hgt : ∀ (x : α), x ∈ s ∩ Ico a b → Set.Nonempty (s ∩ Ioc x b)
S : Set α := s ∩ Icc a b
ha : a ∈ S
Sbd : BddAbove S
c : α := sSup (s ∩ Icc a b)
c_mem : c ∈ S
c_le : c ≤ b
hc : c < b
⊢ b ∈ s

tactic: rcases hgt c ⟨c_mem.1, c_mem.2.1, hc⟩ with ⟨x, xs, cx, xb⟩
state_before: case inr.h
α : Type u
β : Type v
γ : Type w
inst✝⁶ : ConditionallyCompleteLinearOrder α
inst✝⁵ : TopologicalSpace α
inst✝⁴ : OrderTopology α
inst✝³ : ConditionallyCompleteLinearOrder β
inst✝² : TopologicalSpace β
inst✝¹ : OrderTopology β
inst✝ : Nonempty γ
a b : α
s : Set α
hs : IsClosed (s ∩ Icc a b)
hab : a ≤ b
hgt : ∀ (x : α), x ∈ s ∩ Ico a b → Set.Nonempty (s ∩ Ioc x b)
S : Set α := s ∩ Icc a b
ha : a ∈ S
Sbd : BddAbove S
c : α := sSup (s ∩ Icc a b)
c_mem : c ∈ S
c_le : c ≤ b
hc : c < b
⊢ False

tactic: exact not_lt_of_le (le_csSup Sbd ⟨xs, le_trans (le_csSup Sbd ha) (le_of_lt cx), xb⟩) cx
state_before: case inr.h.intro.intro.intro
α : Type u
β : Type v
γ : Type w
inst✝⁶ : ConditionallyCompleteLinearOrder α
inst✝⁵ : TopologicalSpace α
inst✝⁴ : OrderTopology α
inst✝³ : ConditionallyCompleteLinearOrder β
inst✝² : TopologicalSpace β
inst✝¹ : OrderTopology β
inst✝ : Nonempty γ
a b : α
s : Set α
hs : IsClosed (s ∩ Icc a b)
hab : a ≤ b
hgt : ∀ (x : α), x ∈ s ∩ Ico a b → Set.Nonempty (s ∩ Ioc x b)
S : Set α := s ∩ Icc a b
ha : a ∈ S
Sbd : BddAbove S
c : α := sSup (s ∩ Icc a b)
c_mem : c ∈ S
c_le : c ≤ b
hc : c < b
x : α
xs : x ∈ s
cx : c < x
xb : x ≤ b
⊢ False