Theorem: Set.mem_Icc_Ico_Ioc_Ioo_of_subset_of_subset
File: Mathlib/Data/Set/Intervals/Basic.lean

tactic: by_cases ha : a ∈ s <;> by_cases hb : b ∈ s
state_before: α : Type u_1
β : Type ?u.49808
inst✝ : PartialOrder α
a b c : α
s : Set α
ho : Ioo a b ⊆ s
hc : s ⊆ Icc a b
⊢ s ∈ {Icc a b, Ico a b, Ioc a b, Ioo a b}

tactic: refine' Or.inl (Subset.antisymm hc _)
state_before: case pos
α : Type u_1
β : Type ?u.49808
inst✝ : PartialOrder α
a b c : α
s : Set α
ho : Ioo a b ⊆ s
hc : s ⊆ Icc a b
ha : a ∈ s
hb : b ∈ s
⊢ s ∈ {Icc a b, Ico a b, Ioc a b, Ioo a b}

tactic: rwa [← Ico_diff_left, diff_singleton_subset_iff, insert_eq_of_mem ha, ← Icc_diff_right,
  diff_singleton_subset_iff, insert_eq_of_mem hb] at ho
state_before: case pos
α : Type u_1
β : Type ?u.49808
inst✝ : PartialOrder α
a b c : α
s : Set α
ho : Ioo a b ⊆ s
hc : s ⊆ Icc a b
ha : a ∈ s
hb : b ∈ s
⊢ Icc a b ⊆ s

tactic: refine' Or.inr <| Or.inl <| Subset.antisymm _ _
state_before: case neg
α : Type u_1
β : Type ?u.49808
inst✝ : PartialOrder α
a b c : α
s : Set α
ho : Ioo a b ⊆ s
hc : s ⊆ Icc a b
ha : a ∈ s
hb : ¬b ∈ s
⊢ s ∈ {Icc a b, Ico a b, Ioc a b, Ioo a b}

tactic: rw [← Icc_diff_right]
state_before: case neg.refine'_1
α : Type u_1
β : Type ?u.49808
inst✝ : PartialOrder α
a b c : α
s : Set α
ho : Ioo a b ⊆ s
hc : s ⊆ Icc a b
ha : a ∈ s
hb : ¬b ∈ s
⊢ s ⊆ Ico a b

tactic: exact subset_diff_singleton hc hb
state_before: case neg.refine'_1
α : Type u_1
β : Type ?u.49808
inst✝ : PartialOrder α
a b c : α
s : Set α
ho : Ioo a b ⊆ s
hc : s ⊆ Icc a b
ha : a ∈ s
hb : ¬b ∈ s
⊢ s ⊆ Icc a b \ {b}

tactic: rwa [← Ico_diff_left, diff_singleton_subset_iff, insert_eq_of_mem ha] at ho
state_before: case neg.refine'_2
α : Type u_1
β : Type ?u.49808
inst✝ : PartialOrder α
a b c : α
s : Set α
ho : Ioo a b ⊆ s
hc : s ⊆ Icc a b
ha : a ∈ s
hb : ¬b ∈ s
⊢ Ico a b ⊆ s

tactic: refine' Or.inr <| Or.inr <| Or.inl <| Subset.antisymm _ _
state_before: case pos
α : Type u_1
β : Type ?u.49808
inst✝ : PartialOrder α
a b c : α
s : Set α
ho : Ioo a b ⊆ s
hc : s ⊆ Icc a b
ha : ¬a ∈ s
hb : b ∈ s
⊢ s ∈ {Icc a b, Ico a b, Ioc a b, Ioo a b}

tactic: rw [← Icc_diff_left]
state_before: case pos.refine'_1
α : Type u_1
β : Type ?u.49808
inst✝ : PartialOrder α
a b c : α
s : Set α
ho : Ioo a b ⊆ s
hc : s ⊆ Icc a b
ha : ¬a ∈ s
hb : b ∈ s
⊢ s ⊆ Ioc a b

tactic: exact subset_diff_singleton hc ha
state_before: case pos.refine'_1
α : Type u_1
β : Type ?u.49808
inst✝ : PartialOrder α
a b c : α
s : Set α
ho : Ioo a b ⊆ s
hc : s ⊆ Icc a b
ha : ¬a ∈ s
hb : b ∈ s
⊢ s ⊆ Icc a b \ {a}

tactic: rwa [← Ioc_diff_right, diff_singleton_subset_iff, insert_eq_of_mem hb] at ho
state_before: case pos.refine'_2
α : Type u_1
β : Type ?u.49808
inst✝ : PartialOrder α
a b c : α
s : Set α
ho : Ioo a b ⊆ s
hc : s ⊆ Icc a b
ha : ¬a ∈ s
hb : b ∈ s
⊢ Ioc a b ⊆ s

tactic: refine' Or.inr <| Or.inr <| Or.inr <| Subset.antisymm _ ho
state_before: case neg
α : Type u_1
β : Type ?u.49808
inst✝ : PartialOrder α
a b c : α
s : Set α
ho : Ioo a b ⊆ s
hc : s ⊆ Icc a b
ha : ¬a ∈ s
hb : ¬b ∈ s
⊢ s ∈ {Icc a b, Ico a b, Ioc a b, Ioo a b}

tactic: rw [← Ico_diff_left, ← Icc_diff_right]
state_before: case neg
α : Type u_1
β : Type ?u.49808
inst✝ : PartialOrder α
a b c : α
s : Set α
ho : Ioo a b ⊆ s
hc : s ⊆ Icc a b
ha : ¬a ∈ s
hb : ¬b ∈ s
⊢ s ⊆ Ioo a b

tactic: apply_rules [subset_diff_singleton]
state_before: case neg
α : Type u_1
β : Type ?u.49808
inst✝ : PartialOrder α
a b c : α
s : Set α
ho : Ioo a b ⊆ s
hc : s ⊆ Icc a b
ha : ¬a ∈ s
hb : ¬b ∈ s
⊢ s ⊆ (Icc a b \ {b}) \ {a}