Lean library · module TopologyByExample.Spaces.CohenModifiedPlank

Cohen's modified ordinal product

Source file

The interior of omega one times its closed successor is made discrete, while neighbourhoods along the top edge remain those of the original product.

This file was written by Codex (OpenAI's AI model) working under the direction of David R. MacIver, who reviews it and is responsible for it.

Imports

definition CohenModifiedPlank

TopologyByExample.CohenModifiedPlank

The carrier of Cohen's modified product.

def CohenModifiedPlank
:= OmegaOne × WithTop OmegaOne

On this site: Space: Cohen's modified ordinal plank

definition toProd

TopologyByExample.CohenModifiedPlank.toProd

Forgetting the refined topology identifies the underlying ordinal product.

def toProd : CohenModifiedPlank ≃ OmegaOne × WithTop OmegaOne
:= Equiv.refl _

instance

The original product topology is refined by isolating all points below its top edge.

instance : TopologicalSpace CohenModifiedPlank
Proof
:=
  induced toProd inferInstance ⊓ generateFrom {s | ∀ x ∈ s, (toProd x).2 ≠ ⊤}

theorem nhds_eq_inf

TopologyByExample.CohenModifiedPlank.nhds_eq_inf

Neighbourhoods in the refinement.

theorem nhds_eq_inf (x : CohenModifiedPlank) :
    𝓝 x = comap toProd (𝓝 (toProd x)) ⊓
      ⨅ s ∈ {s | x ∈ s ∧ s ∈ {s | ∀ y ∈ s, (toProd y).2 ≠ ⊤}}, 𝓟 s
Proof
:= by
  have he : 𝓝 x = @nhds _ (induced toProd inferInstance) x ⊓
      @nhds _ (generateFrom {s | ∀ y ∈ s, (toProd y).2 ≠ ⊤}) x :=
    nhds_inf (t₁ := induced toProd inferInstance)
      (t₂ := generateFrom {s | ∀ y ∈ s, (toProd y).2 ≠ ⊤})
  have hgen : @nhds _ (generateFrom {s | ∀ y ∈ s, (toProd y).2 ≠ ⊤}) x =
      ⨅ s ∈ {s | x ∈ s ∧ s ∈ {s | ∀ y ∈ s, (toProd y).2 ≠ ⊤}}, 𝓟 s :=
    nhds_generateFrom
  rw [he, nhds_induced, hgen]

theorem nhds_of_ne_top

TopologyByExample.CohenModifiedPlank.nhds_of_ne_top

Points below the top edge are isolated.

theorem nhds_of_ne_top {x : CohenModifiedPlank} (hx : (toProd x).2 ≠ ⊤) :
    𝓝 x = pure x
Proof
:= by
  refine le_antisymm ?_ (pure_le_nhds x)
  rw [nhds_eq_inf, ← principal_singleton]
  refine inf_le_of_right_le (iInf₂_le {x} ⟨rfl, ?_⟩)
  rintro y rfl
  exact hx

theorem nhds_of_top

TopologyByExample.CohenModifiedPlank.nhds_of_top

At the top edge, the original product neighbourhoods are unchanged.

theorem nhds_of_top {x : CohenModifiedPlank} (hx : (toProd x).2 = ⊤) :
    𝓝 x = comap toProd (𝓝 (toProd x))
Proof
:= by
  rw [nhds_eq_inf]
  refine inf_eq_left.mpr (le_iInf₂ fun s hs ↦ ?_)
  exact (hs.2 x hs.1 hx).elim

theorem continuous_toProd

TopologyByExample.CohenModifiedPlank.continuous_toProd

Forgetting the refinement is continuous.

theorem continuous_toProd : Continuous toProd
Proof
:= by
  apply continuous_iff_continuousAt.mpr
  intro x
  by_cases hx : (toProd x).2 = ⊤
  · rw [ContinuousAt, nhds_of_top hx]
    exact tendsto_comap
  · rw [ContinuousAt, nhds_of_ne_top hx, tendsto_pure_left]
    exact fun s hs ↦ mem_of_mem_nhds hs

instance

The finer topology remains Hausdorff.

instance : T2Space CohenModifiedPlank
Proof
:=
  T2Space.of_injective_continuous toProd.injective continuous_toProd

theorem isOpen_singleton

TopologyByExample.CohenModifiedPlank.isOpen_singleton

Singletons below the top edge are open.

theorem isOpen_singleton {x : CohenModifiedPlank} (hx : (toProd x).2 ≠ ⊤) :
    IsOpen ({x} : Set CohenModifiedPlank)
Proof
:=
  (isOpen_singleton_iff_nhds_eq_pure x).mpr (nhds_of_ne_top hx)

definition edge

TopologyByExample.CohenModifiedPlank.edge

The top edge parametrization.

def edge (a : OmegaOne) : CohenModifiedPlank
:= toProd.symm (a, ⊤)

theorem continuous_edge

TopologyByExample.CohenModifiedPlank.continuous_edge

The edge parametrization is continuous.

theorem continuous_edge : Continuous edge
Proof
:= by
  apply continuous_iff_continuousAt.mpr
  intro a
  rw [ContinuousAt, nhds_of_top (x := edge a) rfl]
  apply tendsto_comap_iff.mpr
  exact (continuous_id.prodMk continuous_const).continuousAt

theorem isClosedEmbedding_edge

TopologyByExample.CohenModifiedPlank.isClosedEmbedding_edge

The original omega-one space embeds as the closed top edge.

theorem isClosedEmbedding_edge : IsClosedEmbedding edge
Proof
:= by
  have hi : Function.LeftInverse (fun x : CohenModifiedPlank ↦ (toProd x).1) edge :=
    fun _ ↦ rfl
  exact hi.isClosedEmbedding (continuous_fst.comp continuous_toProd) continuous_edge

On this site: Cohen's modified ordinal plank: The closed ordinal top edge

theorem cardinality

TopologyByExample.CohenModifiedPlank.cardinality

The underlying set has cardinality aleph one.

theorem cardinality : #CohenModifiedPlank = aleph 1
Proof
:= by
  change #(OmegaOne × WithTop OmegaOne) = _
  rw [mk_prod]
  have htop : #(WithTop OmegaOne) = aleph 1 := by
    change #(Option OmegaOne) = _
    rw [mk_option, OrdinalCardinalities.omegaOne, add_one_eq (aleph0_le_aleph _)]
  simp only [OrdinalCardinalities.omegaOne, htop, lift_aleph, Ordinal.lift_one]
  exact Cardinal.mul_eq_self (aleph0_le_aleph _)

On this site: Cohen's modified ordinal plank: Cardinality of the modified ordinal plank

structure LeftInterval

TopologyByExample.CohenModifiedPlank.LeftInterval

A clopen order-convex neighbourhood bounded by its distinguished point.

structure LeftInterval (a : OmegaOne) where
  /-- The underlying set of ordinals. -/
  carrier : Set OmegaOne
  isClopen : IsClopen carrier
  ordConnected : OrdConnected carrier
  mem : a ∈ carrier
  le : carrier ⊆ Iic a

theorem exists_leftInterval

TopologyByExample.CohenModifiedPlank.exists_leftInterval

Every ordinal neighbourhood contains a left interval.

theorem exists_leftInterval {a : OmegaOne} {U : Set OmegaOne} (hU : U ∈ 𝓝 a) :
    ∃ L : LeftInterval a, L.carrier ⊆ U
Proof
:= by
  by_cases ha : a = ⊥
  · refine ⟨⟨Iic a, ⟨isClosed_Iic, OmegaOne.isOpen_Iic a⟩,
      ordConnected_Iic, mem_Iic.mpr le_rfl, subset_rfl⟩, ?_⟩
    intro b hb
    have he : b = a := le_antisymm hb (ha ▸ bot_le)
    exact he ▸ mem_of_mem_nhds hU
  · obtain ⟨b, hba, hbU⟩ := exists_Ioc_subset_of_mem_nhds hU ⟨⊥, bot_lt_iff_ne_bot.mpr ha⟩
    have hc : IsClosed (Ioi b : Set OmegaOne) := by
      simpa only [compl_Iic] using (OmegaOne.isOpen_Iic b).isClosed_compl
    exact ⟨⟨Ioc b a, ⟨hc.inter isClosed_Iic, isOpen_Ioi.inter (OmegaOne.isOpen_Iic a)⟩,
      ordConnected_Ioc, ⟨hba, le_rfl⟩, fun _ h ↦ h.2⟩, hbU⟩

definition rectangle

TopologyByExample.CohenModifiedPlank.rectangle

A basic rectangle along the top edge.

def rectangle {a : OmegaOne} (L : LeftInterval a) (γ : OmegaOne) : Set CohenModifiedPlank
:=
  toProd ⁻¹' (L.carrier ×ˢ Ioi (γ : WithTop OmegaOne))

theorem isClopen_rectangle

TopologyByExample.CohenModifiedPlank.isClopen_rectangle

Basic edge rectangles are clopen.

theorem isClopen_rectangle {a : OmegaOne} (L : LeftInterval a) (γ : OmegaOne) :
    IsClopen (rectangle L γ)
Proof
:= by
  have hc : IsClopen (Ioi (γ : WithTop OmegaOne)) :=
    ⟨by
      simpa only [compl_Iic] using
        (SuccOrder.isOpen_Iic (a := (γ : WithTop OmegaOne))).isClosed_compl,
      isOpen_Ioi⟩
  exact (L.isClopen.prod hc).preimage continuous_toProd

theorem edge_mem_rectangle

TopologyByExample.CohenModifiedPlank.edge_mem_rectangle

Rectangles contain their distinguished edge point.

theorem edge_mem_rectangle {a : OmegaOne} (L : LeftInterval a) (γ : OmegaOne) :
    edge a ∈ rectangle L γ
Proof
:= ⟨L.mem, WithTop.coe_lt_top γ⟩

definition Basic

TopologyByExample.CohenModifiedPlank.Basic

A neighbourhood is either an isolated singleton or a left-bounded edge rectangle.

def Basic (x : CohenModifiedPlank) (V : Set CohenModifiedPlank) : Prop
:=
  ((toProd x).2 ≠ ⊤ ∧ V = {x}) ∨ ((toProd x).2 = ⊤ ∧
    ∃ L : LeftInterval (toProd x).1, ∃ γ, V = rectangle L γ)

theorem isClopen_mem

TopologyByExample.CohenModifiedPlank.Basic.isClopen_mem

Basic neighbourhoods are clopen and contain their centre.

theorem Basic.isClopen_mem {x : CohenModifiedPlank} {V : Set CohenModifiedPlank}
    (h : Basic x V) : IsClopen V ∧ x ∈ V
Proof
:= by
  rcases h with ⟨hx, rfl⟩ | ⟨hx, L, γ, rfl⟩
  · exact ⟨⟨isClosed_singleton, isOpen_singleton hx⟩, rfl⟩
  · exact ⟨isClopen_rectangle L γ, L.mem, by simp [hx]⟩

theorem exists_basic_subset

TopologyByExample.CohenModifiedPlank.exists_basic_subset

Basic neighbourhoods refine every neighbourhood in the modified topology.

theorem exists_basic_subset {x : CohenModifiedPlank} {U : Set CohenModifiedPlank}
    (hU : U ∈ 𝓝 x) : ∃ V, Basic x V ∧ V ⊆ U
Proof
:= by
  by_cases hx : (toProd x).2 = ⊤
  · rw [nhds_of_top hx, mem_comap] at hU
    obtain ⟨W, hW, hWU⟩ := hU
    obtain ⟨A, hA, B, hB, hAB⟩ := mem_nhds_prod_iff.mp hW
    obtain ⟨L, hLA⟩ := exists_leftInterval hA
    change B ∈ 𝓝 (toProd x).2 at hB
    rw [hx] at hB
    obtain ⟨b, hb, hbB⟩ := nhds_top_basis.mem_iff.mp hB
    obtain ⟨γ, rfl⟩ := WithTop.ne_top_iff_exists.mp hb.ne
    refine ⟨rectangle L γ, Or.inr ⟨hx, L, γ, rfl⟩, ?_⟩
    intro y hy
    exact hWU (hAB ⟨hLA hy.1, hbB hy.2⟩)
  · exact ⟨{x}, Or.inl ⟨hx, rfl⟩, singleton_subset_iff.mpr (mem_of_mem_nhds hU)⟩

On this site: Cohen's modified ordinal plank: Clopen neighbourhoods

instance

The modified plank is zero dimensional.

instance : ZeroDimensionalSpace CohenModifiedPlank
Proof
:= by
  refine ZeroDimensionalSpace.of_hasBasis fun x ↦
    ⟨Set CohenModifiedPlank, Basic x, id, fun _ h ↦ h.isClopen_mem.1, ?_⟩
  constructor
  intro U
  exact ⟨exists_basic_subset, fun ⟨V, hV, hVU⟩ ↦
    mem_of_superset (hV.isClopen_mem.1.isOpen.mem_nhds hV.isClopen_mem.2) hVU⟩

theorem inter_nonempty

TopologyByExample.CohenModifiedPlank.Basic.inter_nonempty

Intersecting basic neighbourhoods contain one another's centre.

theorem Basic.inter_nonempty {x y : CohenModifiedPlank} {U V : Set CohenModifiedPlank}
    (hU : Basic x U) (hV : Basic y V) (hUV : (U ∩ V).Nonempty) : x ∈ V ∨ y ∈ U
Proof
:= by
  obtain ⟨z, hzU, hzV⟩ := hUV
  rcases hU with ⟨_, rfl⟩ | ⟨hx, L, γ, rfl⟩
  · exact Or.inl ((mem_singleton_iff.mp hzU) ▸ hzV)
  rcases hV with ⟨_, rfl⟩ | ⟨hy, M, δ, rfl⟩
  · exact Or.inr ((mem_singleton_iff.mp hzV) ▸ hzU)
  rcases le_total (toProd x).1 (toProd y).1 with hxy | hyx
  · exact Or.inl ⟨M.ordConnected.out hzV.1 M.mem ⟨L.le hzU.1, hxy⟩, by simp [hx]⟩
  · exact Or.inr ⟨L.ordConnected.out hzU.1 L.mem ⟨M.le hzV.1, hyx⟩, by simp [hy]⟩

instance

The rectangle intersection property separates any two separated sets.

instance : CompletelyNormalSpace CohenModifiedPlank
Proof
:= by
  classical
  constructor
  intro s t hst hts
  have hchoose (A B : Set CohenModifiedPlank) (hAB : Disjoint A (closure B)) :
      ∀ x : A, ∃ U, Basic x.val U ∧ U ⊆ (closure B)ᶜ := by
    intro x
    exact exists_basic_subset (isClosed_closure.isOpen_compl.mem_nhds
      (Set.disjoint_left.mp hAB x.property))
  choose U hU using hchoose s t hts
  choose V hV using hchoose t s hst.symm
  have hUs : (⋃ x : s, U x) ∈ 𝓝ˢ s := by
    apply mem_nhdsSet_iff_forall.mpr
    intro x hx
    exact mem_of_superset ((hU ⟨x, hx⟩).1.isClopen_mem.1.isOpen.mem_nhds
      (hU ⟨x, hx⟩).1.isClopen_mem.2) (subset_iUnion U ⟨x, hx⟩)
  have hVt : (⋃ y : t, V y) ∈ 𝓝ˢ t := by
    apply mem_nhdsSet_iff_forall.mpr
    intro y hy
    exact mem_of_superset ((hV ⟨y, hy⟩).1.isClopen_mem.1.isOpen.mem_nhds
      (hV ⟨y, hy⟩).1.isClopen_mem.2) (subset_iUnion V ⟨y, hy⟩)
  refine Filter.disjoint_iff.mpr ⟨_, hUs, _, hVt, ?_⟩
  apply Set.disjoint_left.mpr
  intro z hzU hzV
  obtain ⟨x, hx⟩ := mem_iUnion.mp hzU
  obtain ⟨y, hy⟩ := mem_iUnion.mp hzV
  rcases (hU x).1.inter_nonempty (hV y).1 ⟨z, hx, hy⟩ with hxy | hyx
  · exact (hV y).2 hxy (subset_closure x.property)
  · exact (hU x).2 hyx (subset_closure y.property)

theorem countablyParacompactSpace

TopologyByExample.CohenModifiedPlank.countablyParacompactSpace

The countably compact top edge and isolated interior give countable paracompactness.

theorem countablyParacompactSpace : CountablyParacompactSpace CohenModifiedPlank
Proof
:= by
  have hK : IsCountablyCompact (range edge) := by
    simpa only [image_univ] using
      (isCountablyCompact_univ_iff.mpr (inferInstance : CountablyCompactSpace OmegaOne)).image
        continuous_edge
  apply countablyParacompactSpace_of_isCountablyCompact hK
  intro x hx
  apply isOpen_singleton
  intro he
  exact hx ⟨(toProd x).1, toProd.injective (Prod.ext rfl he.symm)⟩

On this site: Cohen's modified ordinal plank is countably paracompact

theorem exists_rectangle_subset

TopologyByExample.CohenModifiedPlank.exists_rectangle_subset

At an edge point, every neighbourhood contains a basic rectangle.

theorem exists_rectangle_subset (a : OmegaOne) {U : Set CohenModifiedPlank}
    (hU : U ∈ 𝓝 (edge a)) : ∃ L : LeftInterval a, ∃ γ, rectangle L γ ⊆ U
Proof
:= by
  obtain ⟨V, hV, hVU⟩ := exists_basic_subset hU
  rcases hV with ⟨hbad, _⟩ | ⟨_, L, γ, rfl⟩
  · exact (hbad rfl).elim
  · exact ⟨L, γ, hVU⟩

theorem exists_interior_mem_iInter

TopologyByExample.CohenModifiedPlank.exists_interior_mem_iInter

Countably many edge neighbourhoods contain a common point below that edge.

theorem exists_interior_mem_iInter (a : OmegaOne) (U : ℕ → Set CohenModifiedPlank)
    (hU : ∀ n, U n ∈ 𝓝 (edge a)) :
    ∃ b : OmegaOne, toProd.symm (a, (b : WithTop OmegaOne)) ∈ ⋂ n, U n
Proof
:= by
  choose L γ hsub using fun n ↦ exists_rectangle_subset a (hU n)
  obtain ⟨b, _, hb⟩ := OmegaOne.exists_gt_and_forall_gt ⊥ γ
  refine ⟨b, mem_iInter.mpr fun n ↦ hsub n ?_⟩
  exact ⟨(L n).mem, WithTop.coe_lt_coe.mpr (hb n)⟩

theorem not_isGδ_singleton_edge

TopologyByExample.CohenModifiedPlank.not_isGδ_singleton_edge

No singleton on the top edge is a G-delta set.

theorem not_isGδ_singleton_edge (a : OmegaOne) : ¬IsGδ ({edge a} : Set CohenModifiedPlank)
Proof
:= by
  intro h
  obtain ⟨U, hU, he⟩ := h.eq_iInter_nat
  have hmem : ∀ n, edge a ∈ U n := by
    have hh : edge a ∈ ⋂ n, U n := he ▸ mem_singleton (edge a)
    exact mem_iInter.mp hh
  obtain ⟨b, hb⟩ := exists_interior_mem_iInter a U fun n ↦ (hU n).mem_nhds (hmem n)
  rw [← he] at hb
  have hp := congrArg (fun x : CohenModifiedPlank ↦ (toProd x).2) (mem_singleton_iff.mp hb)
  exact WithTop.coe_ne_top hp

theorem not_firstCountableTopology

TopologyByExample.CohenModifiedPlank.not_firstCountableTopology

The plank is not first countable.

theorem not_firstCountableTopology : ¬FirstCountableTopology CohenModifiedPlank
Proof
:= by
  intro h
  exact not_isGδ_singleton_edge ⊥ (IsGδ.singleton (edge ⊥))

On this site: Cohen's modified ordinal plank is not first countable

theorem not_perfectlyNormalSpace

TopologyByExample.CohenModifiedPlank.not_perfectlyNormalSpace

The plank is not perfectly normal.

theorem not_perfectlyNormalSpace : ¬PerfectlyNormalSpace CohenModifiedPlank
Proof
:= by
  intro h
  exact not_isGδ_singleton_edge ⊥ isClosed_singleton.isGδ

On this site: Cohen's modified ordinal plank is not perfectly normal

theorem not_metacompactSpace

TopologyByExample.CohenModifiedPlank.not_metacompactSpace

The closed top edge obstructs metacompactness.

theorem not_metacompactSpace : ¬MetacompactSpace CohenModifiedPlank
Proof
:= by
  intro h
  let := isClosedEmbedding_edge.metacompactSpace
  exact OmegaOne.not_compactSpace compactSpace_of_metacompactSpace_of_countablyCompactSpace

On this site: Cohen's modified ordinal plank is not metacompact

theorem not_fullyT4Space

TopologyByExample.CohenModifiedPlank.not_fullyT4Space

The closed ordinal edge obstructs point-star refinements.

theorem not_fullyT4Space : ¬FullyT4Space CohenModifiedPlank
Proof
:= by
  intro h
  let : FullyT4Space OmegaOne := fullyT4Space_of_isClosedEmbedding isClosedEmbedding_edge
  exact OmegaOne.not_compactSpace compactSpace_of_countablyCompactSpace_of_fullyT4Space

On this site: Cohen's modified ordinal plank is not fully T₄

theorem scatteredSpace

TopologyByExample.CohenModifiedPlank.scatteredSpace

The original scattered product topology remains scattered after refinement.

theorem scatteredSpace : ScatteredSpace CohenModifiedPlank
Proof
:= by
  let : ScatteredSpace OmegaOne := OmegaOne.scatteredSpace
  let : ScatteredSpace (WithTop OmegaOne) :=
    scatteredSpace_of_isOpen_Iic fun _ ↦ SuccOrder.isOpen_Iic
  exact ScatteredSpace.of_injective toProd.injective continuous_toProd

On this site: Cohen's modified ordinal plank is scattered

theorem not_sequentiallyDiscreteSpace

TopologyByExample.CohenModifiedPlank.not_sequentiallyDiscreteSpace

A nonconstant sequence on the top edge converges.

theorem not_sequentiallyDiscreteSpace : ¬SequentiallyDiscreteSpace CohenModifiedPlank
Proof
:= by
  intro h
  obtain ⟨c, a, _, hc, hca⟩ := OmegaOne.exists_tendsto_of_not_bddAbove
    isClosed_univ (not_bddAbove_univ)
  have ht : Tendsto (fun n ↦ edge (c n)) atTop (𝓝 (edge a)) :=
    continuous_edge.continuousAt.tendsto.comp hc
  obtain ⟨n, hn⟩ := (SequentiallyDiscreteSpace.eventually_eq_of_tendsto _ _ ht).exists
  exact (hca n).ne (isClosedEmbedding_edge.injective hn)

On this site: Cohen's modified ordinal plank is not sequentially discrete

theorem isClosed_of_countable_interior

TopologyByExample.CohenModifiedPlank.isClosed_of_countable_interior

Countable subsets of the isolated interior are closed.

theorem isClosed_of_countable_interior {S : Set CohenModifiedPlank} (hS : S.Countable)
    (hi : ∀ x ∈ S, (toProd x).2 ≠ ⊤) : IsClosed S
Proof
:= by
  classical
  let : Countable S := hS.to_subtype
  have hex (x : S) : ∃ b : OmegaOne, (b : WithTop OmegaOne) = (toProd x.val).2 :=
    WithTop.ne_top_iff_exists.mp (hi x.val x.property)
  choose b hb using hex
  obtain ⟨γ, hγ⟩ := OmegaOne.bddAbove_of_countable (countable_range b)
  apply isOpen_compl_iff.mp
  apply isOpen_iff_mem_nhds.mpr
  intro x hx
  by_cases hxt : (toProd x).2 = ⊤
  · let V : Set CohenModifiedPlank := toProd ⁻¹' (Set.univ ×ˢ Ioi (γ : WithTop OmegaOne))
    have hV : IsOpen V := (isOpen_univ.prod isOpen_Ioi).preimage continuous_toProd
    apply mem_of_superset (hV.mem_nhds (by exact ⟨mem_univ _, by simp [hxt]⟩))
    intro y hy hyS
    have hle : (b ⟨y, hyS⟩ : WithTop OmegaOne) ≤ γ :=
      WithTop.coe_le_coe.mpr (hγ (mem_range_self (f := b) (⟨y, hyS⟩ : S)))
    rw [hb ⟨y, hyS⟩] at hle
    exact (not_lt_of_ge hle) hy.2
  · exact mem_of_superset ((isOpen_singleton hxt).mem_nhds rfl)
      (singleton_subset_iff.mpr hx)

theorem isOpen_of_interior

TopologyByExample.CohenModifiedPlank.isOpen_of_interior

Sets of isolated interior points are open.

theorem isOpen_of_interior {S : Set CohenModifiedPlank}
    (hi : ∀ x ∈ S, (toProd x).2 ≠ ⊤) : IsOpen S
Proof
:= by
  rw [← biUnion_of_singleton S]
  exact isOpen_biUnion fun x hx ↦ isOpen_singleton (hi x hx)

theorem countable_interior_clopen_discrete

TopologyByExample.CohenModifiedPlank.countable_interior_clopen_discrete

A countable set of interior points is clopen and discrete.

theorem countable_interior_clopen_discrete {S : Set CohenModifiedPlank} (hS : S.Countable)
    (hi : ∀ x ∈ S, (toProd x).2 ≠ ⊤) : IsClopen S ∧ IsDiscrete S
Proof
:= by
  refine ⟨⟨isClosed_of_countable_interior hS hi, isOpen_of_interior hi⟩, ?_⟩
  apply isDiscrete_iff_forall_mem_exists_isOpen.mpr
  intro x hx
  exact ⟨{x}, isOpen_singleton (hi x hx), by simp [hx]⟩

On this site: Cohen's modified ordinal plank: Countable subsets below the top edge

theorem not_compact_neighbourhood

TopologyByExample.CohenModifiedPlank.not_compact_neighbourhood

No compact set is a neighbourhood of a point on the top edge.

theorem not_compact_neighbourhood (a : OmegaOne) {K : Set CohenModifiedPlank}
    (hK : IsCompact K) : K ∉ 𝓝 (edge a)
Proof
:= by
  classical
  intro hKn
  obtain ⟨L, γ, hLK⟩ := exists_rectangle_subset a hKn
  let : Infinite (Ioi γ) := (Set.Ioi_infinite γ).to_subtype
  let e : ℕ ↪ Ioi γ := Infinite.natEmbedding (Ioi γ)
  let f : ℕ → CohenModifiedPlank := fun n ↦ toProd.symm (a, ((e n).val : WithTop OmegaOne))
  have hf : Function.Injective f := by
    intro m n h
    apply e.injective
    apply Subtype.ext
    exact WithTop.coe_injective (congrArg (fun x : CohenModifiedPlank ↦ (toProd x).2) h)
  have hfi : ∀ x ∈ range f, (toProd x).2 ≠ ⊤ := by
    rintro x ⟨n, rfl⟩
    exact WithTop.coe_ne_top
  have hprops := countable_interior_clopen_discrete (countable_range f) hfi
  have hsub : range f ⊆ K := by
    rintro x ⟨n, rfl⟩
    exact hLK ⟨L.mem, WithTop.coe_lt_coe.mpr (e n).property⟩
  have hfinite := (hK.of_isClosed_subset hprops.1.isClosed hsub).finite hprops.2
  exact Set.infinite_range_of_injective hf hfinite

theorem not_weaklyLocallyCompactSpace

TopologyByExample.CohenModifiedPlank.not_weaklyLocallyCompactSpace

The modified plank is not weakly locally compact.

theorem not_weaklyLocallyCompactSpace : ¬WeaklyLocallyCompactSpace CohenModifiedPlank
Proof
:= by
  intro h
  obtain ⟨K, hK, hKn⟩ := exists_compact_mem_nhds (edge ⊥)
  exact not_compact_neighbourhood ⊥ hK hKn

On this site: Cohen's modified ordinal plank is not weakly locally compact

instance

The top edge supplies a point.

instance : Nonempty CohenModifiedPlank
Proof
:= ⟨edge ⊥⟩

instance

Distinct points on the top edge remain distinct.

instance : Nontrivial CohenModifiedPlank
Proof
:= isClosedEmbedding_edge.injective.nontrivial

theorem hasIsolatedPoint

TopologyByExample.CohenModifiedPlank.hasIsolatedPoint

There are isolated points in the interior.

theorem hasIsolatedPoint : HasIsolatedPoint CohenModifiedPlank
Proof
:=
  ⟨toProd.symm (⊥, (⊥ : OmegaOne)), isOpen_singleton WithTop.coe_ne_top⟩

On this site: Cohen's modified ordinal plank has an isolated point

theorem not_countableChainCondition

TopologyByExample.CohenModifiedPlank.not_countableChainCondition

The isolated bottom row witnesses failure of the countable chain condition.

theorem not_countableChainCondition :
    ¬∀ S : Set (Set CohenModifiedPlank), (∀ s ∈ S, IsOpen s ∧ s.Nonempty) →
      S.PairwiseDisjoint id → S.Countable
Proof
:= by
  intro h
  let f : OmegaOne → CohenModifiedPlank := fun a ↦ toProd.symm (a, (⊥ : OmegaOne))
  have hf : Function.Injective f := fun a b hab ↦
    congrArg (fun x : CohenModifiedPlank ↦ (toProd x).1) hab
  have hi : Function.Injective (fun a ↦ ({f a} : Set CohenModifiedPlank)) :=
    fun _ _ h ↦ hf (singleton_injective h)
  refine not_countable_univ (α := OmegaOne)
    (countable_of_injective_of_countable_image hi.injOn ?_)
  rw [image_univ]
  apply h
  · rintro _ ⟨a, rfl⟩
    exact ⟨isOpen_singleton WithTop.coe_ne_top, singleton_nonempty _⟩
  · rintro _ ⟨a, rfl⟩ _ ⟨b, rfl⟩ hab
    exact disjoint_singleton.mpr fun he ↦ hab (congrArg singleton he)

On this site: Cohen's modified ordinal plank does not satisfy the countable chain condition

theorem not_pseudocompactSpace

TopologyByExample.CohenModifiedPlank.not_pseudocompactSpace

A countable clopen discrete subset supports an unbounded continuous function.

theorem not_pseudocompactSpace : ¬PseudocompactSpace CohenModifiedPlank
Proof
:= by
  classical
  intro h
  let e : ℕ ↪ OmegaOne := Infinite.natEmbedding OmegaOne
  let f : ℕ → CohenModifiedPlank := fun n ↦ toProd.symm (e n, (⊥ : OmegaOne))
  have hf : Function.Injective f := fun m n he ↦
    e.injective (congrArg (fun x : CohenModifiedPlank ↦ (toProd x).1) he)
  have hfi : ∀ x ∈ range f, (toProd x).2 ≠ ⊤ := by
    rintro x ⟨n, rfl⟩
    exact WithTop.coe_ne_top
  have hclosed := isClosed_of_countable_interior (countable_range f) hfi
  let g : CohenModifiedPlank → ℝ := fun x ↦
    if x ∈ range f then ((Function.invFun f x : ℕ) : ℝ) else 0
  have hg : Continuous g := by
    apply continuous_iff_continuousAt.mpr
    intro x
    by_cases hx : x ∈ range f
    · rw [ContinuousAt, nhds_of_ne_top (hfi x hx)]
      exact tendsto_pure_nhds (f := g) (a := x)
    · have hzero : g x = 0 := by simp only [g, ite_eq_right hx]
      rw [ContinuousAt, hzero]
      apply tendsto_const_nhds.congr'
      filter_upwards [hclosed.isOpen_compl.mem_nhds hx] with y hy
      simp only [g, ite_eq_right hy]
  let g' : C(CohenModifiedPlank, ℝ) := ⟨g, hg⟩
  obtain ⟨b, hb⟩ := (PseudocompactSpace.bddAbove_and_bddBelow_range g').1
  obtain ⟨n, hn⟩ := exists_nat_gt b
  have hgn : g' (f n) = (n : ℝ) := by
    simp [g', g, Function.leftInverse_invFun hf n]
  exact hn.not_ge (hgn ▸ hb (mem_range_self (f n)))

On this site: Cohen's modified ordinal plank is not pseudocompact

theorem not_countable

TopologyByExample.CohenModifiedPlank.not_countable

The carrier is uncountable.

theorem not_countable : ¬Countable CohenModifiedPlank
Proof
:= by
  intro h
  have hc := Cardinal.mk_le_aleph0 (α := CohenModifiedPlank)
  rw [cardinality] at hc
  exact (Cardinal.aleph0_lt_aleph_one).not_ge hc

On this site: Cohen's modified ordinal plank is not countable

theorem cardinalityAtMostTwoToContinuum

TopologyByExample.CohenModifiedPlank.cardinalityAtMostTwoToContinuum

The carrier satisfies the upper chart cardinal bound.

theorem cardinalityAtMostTwoToContinuum : CardinalityAtMostTwoToContinuum CohenModifiedPlank
Proof
:=
  OrdinalCardinalities.atMost cardinality

On this site: Cohen's modified ordinal plank has cardinality at most \(2^{\mathfrak{c}}\)

theorem cardinalityContinuum_of_ch

TopologyByExample.CohenModifiedPlank.cardinalityContinuum_of_ch

Under CH the carrier has continuum cardinality.

theorem cardinalityContinuum_of_ch (h : continuum.{0} = aleph 1) :
    CardinalityContinuum CohenModifiedPlank
Proof
:= OrdinalCardinalities.continuum_of_ch cardinality h

On this site: Cohen's modified ordinal plank has cardinality equal to \(\mathfrak{c}\) (assuming CH)

theorem cardinalityLessThanContinuum_of_not_ch

TopologyByExample.CohenModifiedPlank.cardinalityLessThanContinuum_of_not_ch

Without CH the carrier is smaller than continuum.

theorem cardinalityLessThanContinuum_of_not_ch (h : continuum.{0} ≠ aleph 1) :
    CardinalityLessThanContinuum CohenModifiedPlank
Proof
:=
  OrdinalCardinalities.less_of_not_ch cardinality h

On this site: Cohen's modified ordinal plank has cardinality less than \(\mathfrak{c}\) (assuming CH fails)

theorem not_cardinalityLessThanContinuum_of_ch

TopologyByExample.CohenModifiedPlank.not_cardinalityLessThanContinuum_of_ch

Under CH the carrier is not smaller than continuum.

theorem not_cardinalityLessThanContinuum_of_ch (h : continuum.{0} = aleph 1) :
    ¬CardinalityLessThanContinuum CohenModifiedPlank
Proof
:=
  OrdinalCardinalities.not_less_of_ch cardinality h

On this site: Cohen's modified ordinal plank does not have cardinality less than \(\mathfrak{c}\) (assuming CH)

theorem not_cardinalityContinuum_of_not_ch

TopologyByExample.CohenModifiedPlank.not_cardinalityContinuum_of_not_ch

Without CH the carrier does not have continuum cardinality.

theorem not_cardinalityContinuum_of_not_ch (h : continuum.{0} ≠ aleph 1) :
    ¬CardinalityContinuum CohenModifiedPlank
Proof
:=
  OrdinalCardinalities.not_continuum_of_not_ch cardinality h

On this site: Cohen's modified ordinal plank does not have cardinality equal to \(\mathfrak{c}\) (assuming CH fails)