Skip to content
This repository was archived by the owner on Jul 24, 2024. It is now read-only.

Commit a444e81

Browse files
committed
feat(measure_theory/borel_space): a preconnected set is measurable (#8044)
In a conditionally complete linear order equipped with the order topology and the corresponding borel σ-algebra, any preconnected set is measurable.
1 parent bcd61b1 commit a444e81

File tree

3 files changed

+60
-12
lines changed

3 files changed

+60
-12
lines changed

src/data/set/finite.lean

Lines changed: 26 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ Copyright (c) 2017 Johannes Hölzl. All rights reserved.
33
Released under Apache 2.0 license as described in the file LICENSE.
44
Authors: Johannes Hölzl, Mario Carneiro
55
-/
6-
import data.fintype.basic
6+
import data.finset.sort
77

88
/-!
99
# Finite sets
@@ -810,3 +810,28 @@ lemma card_compl_eq_card_compl (h : fintype.card {x // p x} = fintype.card {x //
810810
by simp only [card_subtype_compl, h]
811811

812812
end fintype
813+
814+
/--
815+
If a set `s` does not contain any elements between any pair of elements `x, z ∈ s` with `x ≤ z`
816+
(i.e if given `x, y, z ∈ s` such that `x ≤ y ≤ z`, then `y` is either `x` or `z`), then `s` is
817+
finite.
818+
-/
819+
lemma set.finite_of_forall_between_eq_endpoints {α : Type*} [linear_order α] (s : set α)
820+
(h : ∀ (x ∈ s) (y ∈ s) (z ∈ s), x ≤ y → y ≤ z → x = y ∨ y = z) :
821+
set.finite s :=
822+
begin
823+
by_contra hinf,
824+
change s.infinite at hinf,
825+
rcases hinf.exists_subset_card_eq 3 with ⟨t, hts, ht⟩,
826+
let f := t.order_iso_of_fin ht,
827+
let x := f 0,
828+
let y := f 1,
829+
let z := f 2,
830+
have := h x (hts x.2) y (hts y.2) z (hts z.2)
831+
(f.monotone $ by dec_trivial) (f.monotone $ by dec_trivial),
832+
have key₁ : (0 : fin 3) ≠ 1 := by dec_trivial,
833+
have key₂ : (1 : fin 3) ≠ 2 := by dec_trivial,
834+
cases this,
835+
{ dsimp only [x, y] at this, exact key₁ (f.injective $ subtype.coe_injective this) },
836+
{ dsimp only [y, z] at this, exact key₂ (f.injective $ subtype.coe_injective this) }
837+
end

src/measure_theory/borel_space.lean

Lines changed: 24 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -351,17 +351,36 @@ instance nhds_within_Iio_is_measurably_generated :
351351
(𝓝[Iio b] a).is_measurably_generated :=
352352
measurable_set_Iio.nhds_within_is_measurably_generated _
353353

354-
variables [second_countable_topology α]
355-
356354
@[measurability]
357-
lemma measurable_set_lt' : measurable_set {p : α × α | p.1 < p.2} :=
355+
lemma measurable_set_lt' [second_countable_topology α] : measurable_set {p : α × α | p.1 < p.2} :=
358356
(is_open_lt continuous_fst continuous_snd).measurable_set
359357

360358
@[measurability]
361-
lemma measurable_set_lt {f g : δ → α} (hf : measurable f) (hg : measurable g) :
362-
measurable_set {a | f a < g a} :=
359+
lemma measurable_set_lt [second_countable_topology α] {f g : δ → α} (hf : measurable f)
360+
(hg : measurable g) : measurable_set {a | f a < g a} :=
363361
hf.prod_mk hg measurable_set_lt'
364362

363+
lemma set.ord_connected.measurable_set (h : ord_connected s) : measurable_set s :=
364+
begin
365+
let u := ⋃ (x ∈ s) (y ∈ s), Ioo x y,
366+
have huopen : is_open u := is_open_bUnion (λ x hx, is_open_bUnion (λ y hy, is_open_Ioo)),
367+
have humeas : measurable_set u := huopen.measurable_set,
368+
have hfinite : (s \ u).finite,
369+
{ refine set.finite_of_forall_between_eq_endpoints (s \ u) (λ x hx y hy z hz hxy hyz, _),
370+
by_contra h,
371+
push_neg at h,
372+
exact hy.2 (mem_bUnion_iff.mpr ⟨x, hx.1,
373+
mem_bUnion_iff.mpr ⟨z, hz.1, lt_of_le_of_ne hxy h.1, lt_of_le_of_ne hyz h.2⟩⟩) },
374+
have : u ⊆ s :=
375+
bUnion_subset (λ x hx, bUnion_subset (λ y hy, Ioo_subset_Icc_self.trans (h.out hx hy))),
376+
rw ← union_diff_cancel this,
377+
exact humeas.union hfinite.measurable_set
378+
end
379+
380+
lemma is_preconnected.measurable_set
381+
(h : is_preconnected s) : measurable_set s :=
382+
h.ord_connected.measurable_set
383+
365384
end linear_order
366385

367386
section linear_order

src/topology/algebra/ordered/basic.lean

Lines changed: 10 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -679,6 +679,10 @@ lemma filter.tendsto.min {b : filter β} {a₁ a₂ : α} (hf : tendsto f b (
679679
tendsto (λb, min (f b) (g b)) b (𝓝 (min a₁ a₂)) :=
680680
(continuous_min.tendsto (a₁, a₂)).comp (hf.prod_mk_nhds hg)
681681

682+
lemma is_preconnected.ord_connected {s : set α} (h : is_preconnected s) :
683+
ord_connected s :=
684+
⟨λ x hx y hy, h.Icc_subset hx hy⟩
685+
682686
end linear_order
683687

684688
end order_closed_topology
@@ -2688,14 +2692,14 @@ end
26882692

26892693
lemma is_preconnected_interval : is_preconnected (interval a b) := is_preconnected_Icc
26902694

2695+
lemma set.ord_connected.is_preconnected {s : set α} (h : s.ord_connected) :
2696+
is_preconnected s :=
2697+
is_preconnected_of_forall_pair $ λ x y hx hy, ⟨interval x y, h.interval_subset hx hy,
2698+
left_mem_interval, right_mem_interval, is_preconnected_interval⟩
2699+
26912700
lemma is_preconnected_iff_ord_connected {s : set α} :
26922701
is_preconnected s ↔ ord_connected s :=
2693-
⟨λ h, ⟨λ x hx y hy, h.Icc_subset hx hy⟩, λ h, is_preconnected_of_forall_pair $ λ x y hx hy,
2694-
⟨interval x y, h.interval_subset hx hy, left_mem_interval, right_mem_interval,
2695-
is_preconnected_interval⟩⟩
2696-
2697-
alias is_preconnected_iff_ord_connected ↔
2698-
is_preconnected.ord_connected set.ord_connected.is_preconnected
2702+
⟨is_preconnected.ord_connected, set.ord_connected.is_preconnected⟩
26992703

27002704
lemma is_preconnected_Ici : is_preconnected (Ici a) := ord_connected_Ici.is_preconnected
27012705
lemma is_preconnected_Iic : is_preconnected (Iic a) := ord_connected_Iic.is_preconnected

0 commit comments

Comments
 (0)