Skip to content

Commit 1860554

Browse files
committed
feat: add missing Set.Ioo_inter_Iio etc (#11902)
add missing lemmas. I'm not sure if these should be @[simp], as e.g. Ico_inter_Ico isn't, but Ico_inter_Iio is
1 parent 48ec8b6 commit 1860554

File tree

1 file changed

+14
-0
lines changed

1 file changed

+14
-0
lines changed

Mathlib/Data/Set/Intervals/Basic.lean

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1817,6 +1817,20 @@ theorem Ioo_inter_Ioo : Ioo a₁ b₁ ∩ Ioo a₂ b₂ = Ioo (a₁ ⊔ a₂) (b
18171817
simp only [Ioi_inter_Iio.symm, Ioi_inter_Ioi.symm, Iio_inter_Iio.symm]; ac_rfl
18181818
#align set.Ioo_inter_Ioo Set.Ioo_inter_Ioo
18191819

1820+
theorem Ioo_inter_Iio : Ioo a b ∩ Iio c = Ioo a (min b c) := by
1821+
ext
1822+
simp_rw [mem_inter_iff, mem_Ioo, mem_Iio, lt_min_iff, and_assoc]
1823+
1824+
theorem Iio_inter_Ioo : Iio a ∩ Ioo b c = Ioo b (min a c) := by
1825+
rw [Set.inter_comm, Set.Ioo_inter_Iio, min_comm]
1826+
1827+
theorem Ioo_inter_Ioi : Ioo a b ∩ Ioi c = Ioo (max a c) b := by
1828+
ext
1829+
simp_rw [mem_inter_iff, mem_Ioo, mem_Ioi, max_lt_iff, and_assoc, and_comm]
1830+
1831+
theorem Ioi_inter_Ioo : Set.Ioi a ∩ Set.Ioo b c = Set.Ioo (max a b) c := by
1832+
rw [inter_comm, Ioo_inter_Ioi, max_comm]
1833+
18201834
theorem Ioc_inter_Ioo_of_left_lt (h : b₁ < b₂) : Ioc a₁ b₁ ∩ Ioo a₂ b₂ = Ioc (max a₁ a₂) b₁ :=
18211835
ext fun x => by
18221836
simp [and_assoc, @and_left_comm (x ≤ _), and_iff_left_iff_imp.2 fun h' => lt_of_le_of_lt h' h]

0 commit comments

Comments
 (0)