l3lab/ntp-mathlib huggingface dataset:
/-- Cofiltered limits of nonempty compact Hausdorff spaces are nonempty topological spaces.
-/
-- porting note: generalized from `TopCat.{u}` to `TopCatMax.{u,v}`
theorem nonempty_limitCone_of_compact_t2_cofiltered_system (F : J ⥤ TopCatMax.{u,v})
    [IsCofilteredOrEmpty J]
    [∀ j : J, Nonempty (F.obj j)] [∀ j : J, CompactSpace (F.obj j)] [∀ j : J, T2Space (F.obj j)] :
    Nonempty (TopCat.limitCone F).pt := by
  classical
  obtain ⟨u, hu⟩ :=
    IsCompact.nonempty_iInter_of_directed_nonempty_compact_closed (fun G => partialSections F _)
      (partialSections.directed F) (fun G => partialSections.nonempty F _)
      (fun G => IsClosed.isCompact (partialSections.closed F _)) fun G =>
      partialSections.closed F _
  use u
  intro X Y f
  let G : FiniteDiagram J :=
    ⟨{X, Y},
      {⟨X, Y, by simp only [true_or_iff, eq_self_iff_true, Finset.mem_insert], by
          

Proof state:
J : Type u
inst✝⁴ : SmallCategory J
F✝ : J ⥤ TopCat
F : J ⥤ TopCatMax
inst✝³ : IsCofilteredOrEmpty J
inst✝² : ∀ (j : J), Nonempty ↑(F.obj j)
inst✝¹ : ∀ (j : J), CompactSpace ↑(F.obj j)
inst✝ : ∀ (j : J), T2Space ↑(F.obj j)
u : (j : J) → ↑(F.obj j)
hu : u ∈ ⋂ i, partialSections F i.snd
X Y : J
f : X ⟶ Y
⊢ Y ∈ {X, Y}

Next tactic:
simp only [eq_self_iff_true, or_true_iff, Finset.mem_insert, Finset.mem_singleton]
/-- Cofiltered limits of nonempty compact Hausdorff spaces are nonempty topological spaces.
-/
-- porting note: generalized from `TopCat.{u}` to `TopCatMax.{u,v}`
theorem nonempty_limitCone_of_compact_t2_cofiltered_system (F : J ⥤ TopCatMax.{u,v})
    [IsCofilteredOrEmpty J]
    [∀ j : J, Nonempty (F.obj j)] [∀ j : J, CompactSpace (F.obj j)] [∀ j : J, T2Space (F.obj j)] :
    Nonempty (TopCat.limitCone F).pt := by
  classical
  obtain ⟨u, hu⟩ :=
    IsCompact.nonempty_iInter_of_directed_nonempty_compact_closed (fun G => partialSections F _)
      (partialSections.directed F) (fun G => partialSections.nonempty F _)
      (fun G => IsClosed.isCompact (partialSections.closed F _)) fun G =>
      partialSections.closed F _
  use u
  intro X Y f
  let G : FiniteDiagram J :=
    ⟨{X, Y},
      {⟨X, Y, by simp only [true_or_iff, eq_self_iff_true, Finset.mem_insert], by
          simp only [eq_self_iff_true, or_true_iff, Finset.mem_insert, Finset.mem_singleton], f⟩}⟩
  

Proof state:
case property
J : Type u
inst✝⁴ : SmallCategory J
F✝ : J ⥤ TopCat
F : J ⥤ TopCatMax
inst✝³ : IsCofilteredOrEmpty J
inst✝² : ∀ (j : J), Nonempty ↑(F.obj j)
inst✝¹ : ∀ (j : J), CompactSpace ↑(F.obj j)
inst✝ : ∀ (j : J), T2Space ↑(F.obj j)
u : (j : J) → ↑(F.obj j)
hu : u ∈ ⋂ i, partialSections F i.snd
X Y : J
f : X ⟶ Y
G : TopCat.FiniteDiagram J :=
  { fst := {X, Y},
    snd :=
      {{ fst := X,
          snd := { fst := Y, snd := { fst := (_ : X ∈ {X, Y}), snd := { fst := (_ : Y ∈ {X, Y}), snd := f } } } }} }
⊢ (F.map f) (u X) = u Y

Next tactic:
exact hu _ ⟨G, rfl⟩ (Finset.mem_singleton_self _)
instance CompletelyRegularSpace.instRegularSpace [CompletelyRegularSpace X] : RegularSpace X := by
  

Proof state:
X : Type u
inst✝² : TopologicalSpace X
inst✝¹ : T1Space X
inst✝ : CompletelyRegularSpace X
⊢ RegularSpace X

Next tactic:
rw [regularSpace_iff]
instance CompletelyRegularSpace.instRegularSpace [CompletelyRegularSpace X] : RegularSpace X := by
  rw [regularSpace_iff]
  

Proof state:
X : Type u
inst✝² : TopologicalSpace X
inst✝¹ : T1Space X
inst✝ : CompletelyRegularSpace X
⊢ ∀ {s : Set X} {a : X}, IsClosed s → a ∉ s → Disjoint (𝓝ˢ s) (𝓝 a)

Next tactic:
intro s a hs ha
instance CompletelyRegularSpace.instRegularSpace [CompletelyRegularSpace X] : RegularSpace X := by
  rw [regularSpace_iff]
  intro s a hs ha
  

Proof state:
X : Type u
inst✝² : TopologicalSpace X
inst✝¹ : T1Space X
inst✝ : CompletelyRegularSpace X
s : Set X
a : X
hs : IsClosed s
ha : a ∉ s
⊢ Disjoint (𝓝ˢ s) (𝓝 a)

Next tactic:
obtain ⟨f, cf, hf, hhf⟩ := CompletelyRegularSpace.completely_regular a s hs ha
instance CompletelyRegularSpace.instRegularSpace [CompletelyRegularSpace X] : RegularSpace X := by
  rw [regularSpace_iff]
  intro s a hs ha
  obtain ⟨f, cf, hf, hhf⟩ := CompletelyRegularSpace.completely_regular a s hs ha
  

Proof state:
case intro.intro.intro
X : Type u
inst✝² : TopologicalSpace X
inst✝¹ : T1Space X
inst✝ : CompletelyRegularSpace X
s : Set X
a : X
hs : IsClosed s
ha : a ∉ s
f : X → ↑I
cf : Continuous f
hf : f a = 0
hhf : EqOn f 1 s
⊢ Disjoint (𝓝ˢ s) (𝓝 a)

Next tactic:
apply disjoint_of_map (f := f)
instance CompletelyRegularSpace.instRegularSpace [CompletelyRegularSpace X] : RegularSpace X := by
  rw [regularSpace_iff]
  intro s a hs ha
  obtain ⟨f, cf, hf, hhf⟩ := CompletelyRegularSpace.completely_regular a s hs ha
  apply disjoint_of_map (f := f)
  

Proof state:
case intro.intro.intro
X : Type u
inst✝² : TopologicalSpace X
inst✝¹ : T1Space X
inst✝ : CompletelyRegularSpace X
s : Set X
a : X
hs : IsClosed s
ha : a ∉ s
f : X → ↑I
cf : Continuous f
hf : f a = 0
hhf : EqOn f 1 s
⊢ Disjoint (map f (𝓝ˢ s)) (map f (𝓝 a))

Next tactic:
apply Disjoint.mono (cf.tendsto_nhdsSet_nhds hhf) cf.continuousAt
instance CompletelyRegularSpace.instRegularSpace [CompletelyRegularSpace X] : RegularSpace X := by
  rw [regularSpace_iff]
  intro s a hs ha
  obtain ⟨f, cf, hf, hhf⟩ := CompletelyRegularSpace.completely_regular a s hs ha
  apply disjoint_of_map (f := f)
  apply Disjoint.mono (cf.tendsto_nhdsSet_nhds hhf) cf.continuousAt
  

Proof state:
case intro.intro.intro
X : Type u
inst✝² : TopologicalSpace X
inst✝¹ : T1Space X
inst✝ : CompletelyRegularSpace X
s : Set X
a : X
hs : IsClosed s
ha : a ∉ s
f : X → ↑I
cf : Continuous f
hf : f a = 0
hhf : EqOn f 1 s
⊢ Disjoint (𝓝 { val := 1, property := hasOne.proof_1 }) (𝓝 (f a))

Next tactic:
exact disjoint_nhds_nhds.mpr (hf.symm ▸ zero_ne_one).symm
instance NormalSpace.instCompletelyRegularSpace [NormalSpace X] : CompletelyRegularSpace X := by
  

Proof state:
X : Type u
inst✝² : TopologicalSpace X
inst✝¹ : T1Space X
inst✝ : NormalSpace X
⊢ CompletelyRegularSpace X

Next tactic:
rw [completelyRegularSpace_iff]
instance NormalSpace.instCompletelyRegularSpace [NormalSpace X] : CompletelyRegularSpace X := by
  rw [completelyRegularSpace_iff]
  

Proof state:
X : Type u
inst✝² : TopologicalSpace X
inst✝¹ : T1Space X
inst✝ : NormalSpace X
⊢ ∀ (x : X) (K : Set X), IsClosed K → x ∉ K → ∃ f, Continuous f ∧ f x = 0 ∧ EqOn f 1 K

Next tactic:
intro x K hK hx
instance NormalSpace.instCompletelyRegularSpace [NormalSpace X] : CompletelyRegularSpace X := by
  rw [completelyRegularSpace_iff]
  intro x K hK hx
  

Proof state:
X : Type u
inst✝² : TopologicalSpace X
inst✝¹ : T1Space X
inst✝ : NormalSpace X
x : X
K : Set X
hK : IsClosed K
hx : x ∉ K
⊢ ∃ f, Continuous f ∧ f x = 0 ∧ EqOn f 1 K

Next tactic:
have cx : IsClosed {x} := T1Space.t1 x
instance NormalSpace.instCompletelyRegularSpace [NormalSpace X] : CompletelyRegularSpace X := by
  rw [completelyRegularSpace_iff]
  intro x K hK hx
  have cx : IsClosed {x} := T1Space.t1 x
  

Proof state:
X : Type u
inst✝² : TopologicalSpace X
inst✝¹ : T1Space X
inst✝ : NormalSpace X
x : X
K : Set X
hK : IsClosed K
hx : x ∉ K
cx : IsClosed {x}
⊢ ∃ f, Continuous f ∧ f x = 0 ∧ EqOn f 1 K

Next tactic:
have d : Disjoint {x} K := by rwa [Set.disjoint_iff, subset_empty_iff, singleton_inter_eq_empty]
instance NormalSpace.instCompletelyRegularSpace [NormalSpace X] : CompletelyRegularSpace X := by
  rw [completelyRegularSpace_iff]
  intro x K hK hx
  have cx : IsClosed {x} := T1Space.t1 x
  have d : Disjoint {x} K := by 

Proof state:
X : Type u
inst✝² : TopologicalSpace X
inst✝¹ : T1Space X
inst✝ : NormalSpace X
x : X
K : Set X
hK : IsClosed K
hx : x ∉ K
cx : IsClosed {x}
⊢ Disjoint {x} K

Next tactic:
rwa [Set.disjoint_iff, subset_empty_iff, singleton_inter_eq_empty]
instance NormalSpace.instCompletelyRegularSpace [NormalSpace X] : CompletelyRegularSpace X := by
  rw [completelyRegularSpace_iff]
  intro x K hK hx
  have cx : IsClosed {x} := T1Space.t1 x
  have d : Disjoint {x} K := by rwa [Set.disjoint_iff, subset_empty_iff, singleton_inter_eq_empty]
  

Proof state:
X : Type u
inst✝² : TopologicalSpace X
inst✝¹ : T1Space X
inst✝ : NormalSpace X
x : X
K : Set X
hK : IsClosed K
hx : x ∉ K
cx : IsClosed {x}
d : Disjoint {x} K
⊢ ∃ f, Continuous f ∧ f x = 0 ∧ EqOn f 1 K

Next tactic:
let ⟨⟨f, cf⟩, hfx, hfK, hficc⟩ := exists_continuous_zero_one_of_isClosed cx hK d
instance NormalSpace.instCompletelyRegularSpace [NormalSpace X] : CompletelyRegularSpace X := by
  rw [completelyRegularSpace_iff]
  intro x K hK hx
  have cx : IsClosed {x} := T1Space.t1 x
  have d : Disjoint {x} K := by rwa [Set.disjoint_iff, subset_empty_iff, singleton_inter_eq_empty]
  let ⟨⟨f, cf⟩, hfx, hfK, hficc⟩ := exists_continuous_zero_one_of_isClosed cx hK d
  

Proof state:
X : Type u
inst✝² : TopologicalSpace X
inst✝¹ : T1Space X
inst✝ : NormalSpace X
x : X
K : Set X
hK : IsClosed K
hx : x ∉ K
cx : IsClosed {x}
d : Disjoint {x} K
f : X → ℝ
cf : Continuous f
hfx : EqOn (⇑(ContinuousMap.mk f)) 0 {x}
hfK : EqOn (⇑(ContinuousMap.mk f)) 1 K
hficc : ∀ (x : X), (ContinuousMap.mk f) x ∈ Icc 0 1
⊢ ∃ f, Continuous f ∧ f x = 0 ∧ EqOn f 1 K

Next tactic:
let g : X → I := fun x => ⟨f x, hficc x⟩
instance NormalSpace.instCompletelyRegularSpace [NormalSpace X] : CompletelyRegularSpace X := by
  rw [completelyRegularSpace_iff]
  intro x K hK hx
  have cx : IsClosed {x} := T1Space.t1 x
  have d : Disjoint {x} K := by rwa [Set.disjoint_iff, subset_empty_iff, singleton_inter_eq_empty]
  let ⟨⟨f, cf⟩, hfx, hfK, hficc⟩ := exists_continuous_zero_one_of_isClosed cx hK d
  let g : X → I := fun x => ⟨f x, hficc x⟩
  

Proof state:
X : Type u
inst✝² : TopologicalSpace X
inst✝¹ : T1Space X
inst✝ : NormalSpace X
x : X
K : Set X
hK : IsClosed K
hx : x ∉ K
cx : IsClosed {x}
d : Disjoint {x} K
f : X → ℝ
cf : Continuous f
hfx : EqOn (⇑(ContinuousMap.mk f)) 0 {x}
hfK : EqOn (⇑(ContinuousMap.mk f)) 1 K
hficc : ∀ (x : X), (ContinuousMap.mk f) x ∈ Icc 0 1
g : X → ↑I := fun x => { val := f x, property := (_ : (ContinuousMap.mk f) x ∈ Icc 0 1) }
⊢ ∃ f, Continuous f ∧ f x = 0 ∧ EqOn f 1 K

Next tactic:
have cg : Continuous g := cf.subtype_mk hficc
instance NormalSpace.instCompletelyRegularSpace [NormalSpace X] : CompletelyRegularSpace X := by
  rw [completelyRegularSpace_iff]
  intro x K hK hx
  have cx : IsClosed {x} := T1Space.t1 x
  have d : Disjoint {x} K := by rwa [Set.disjoint_iff, subset_empty_iff, singleton_inter_eq_empty]
  let ⟨⟨f, cf⟩, hfx, hfK, hficc⟩ := exists_continuous_zero_one_of_isClosed cx hK d
  let g : X → I := fun x => ⟨f x, hficc x⟩
  have cg : Continuous g := cf.subtype_mk hficc
  

Proof state:
X : Type u
inst✝² : TopologicalSpace X
inst✝¹ : T1Space X
inst✝ : NormalSpace X
x : X
K : Set X
hK : IsClosed K
hx : x ∉ K
cx : IsClosed {x}
d : Disjoint {x} K
f : X → ℝ
cf : Continuous f
hfx : EqOn (⇑(ContinuousMap.mk f)) 0 {x}
hfK : EqOn (⇑(ContinuousMap.mk f)) 1 K
hficc : ∀ (x : X), (ContinuousMap.mk f) x ∈ Icc 0 1
g : X → ↑I := fun x => { val := f x, property := (_ : (ContinuousMap.mk f) x ∈ Icc 0 1) }
cg : Continuous g
⊢ ∃ f, Continuous f ∧ f x = 0 ∧ EqOn f 1 K

Next tactic:
have hgx : g x = 0 := Subtype.ext (hfx (mem_singleton_iff.mpr (Eq.refl x)))
instance NormalSpace.instCompletelyRegularSpace [NormalSpace X] : CompletelyRegularSpace X := by
  rw [completelyRegularSpace_iff]
  intro x K hK hx
  have cx : IsClosed {x} := T1Space.t1 x
  have d : Disjoint {x} K := by rwa [Set.disjoint_iff, subset_empty_iff, singleton_inter_eq_empty]
  let ⟨⟨f, cf⟩, hfx, hfK, hficc⟩ := exists_continuous_zero_one_of_isClosed cx hK d
  let g : X → I := fun x => ⟨f x, hficc x⟩
  have cg : Continuous g := cf.subtype_mk hficc
  have hgx : g x = 0 := Subtype.ext (hfx (mem_singleton_iff.mpr (Eq.refl x)))
  

Proof state:
X : Type u
inst✝² : TopologicalSpace X
inst✝¹ : T1Space X
inst✝ : NormalSpace X
x : X
K : Set X
hK : IsClosed K
hx : x ∉ K
cx : IsClosed {x}
d : Disjoint {x} K
f : X → ℝ
cf : Continuous f
hfx : EqOn (⇑(ContinuousMap.mk f)) 0 {x}
hfK : EqOn (⇑(ContinuousMap.mk f)) 1 K
hficc : ∀ (x : X), (ContinuousMap.mk f) x ∈ Icc 0 1
g : X → ↑I := fun x => { val := f x, property := (_ : (ContinuousMap.mk f) x ∈ Icc 0 1) }
cg : Continuous g
hgx : g x = 0
⊢ ∃ f, Continuous f ∧ f x = 0 ∧ EqOn f 1 K

Next tactic:
have hgK : EqOn g 1 K := fun k hk => Subtype.ext (hfK hk)
instance NormalSpace.instCompletelyRegularSpace [NormalSpace X] : CompletelyRegularSpace X := by
  rw [completelyRegularSpace_iff]
  intro x K hK hx
  have cx : IsClosed {x} := T1Space.t1 x
  have d : Disjoint {x} K := by rwa [Set.disjoint_iff, subset_empty_iff, singleton_inter_eq_empty]
  let ⟨⟨f, cf⟩, hfx, hfK, hficc⟩ := exists_continuous_zero_one_of_isClosed cx hK d
  let g : X → I := fun x => ⟨f x, hficc x⟩
  have cg : Continuous g := cf.subtype_mk hficc
  have hgx : g x = 0 := Subtype.ext (hfx (mem_singleton_iff.mpr (Eq.refl x)))
  have hgK : EqOn g 1 K := fun k hk => Subtype.ext (hfK hk)
  

Proof state:
X : Type u
inst✝² : TopologicalSpace X
inst✝¹ : T1Space X
inst✝ : NormalSpace X
x : X
K : Set X
hK : IsClosed K
hx : x ∉ K
cx : IsClosed {x}
d : Disjoint {x} K
f : X → ℝ
cf : Continuous f
hfx : EqOn (⇑(ContinuousMap.mk f)) 0 {x}
hfK : EqOn (⇑(ContinuousMap.mk f)) 1 K
hficc : ∀ (x : X), (ContinuousMap.mk f) x ∈ Icc 0 1
g : X → ↑I := fun x => { val := f x, property := (_ : (ContinuousMap.mk f) x ∈ Icc 0 1) }
cg : Continuous g
hgx : g x = 0
hgK : EqOn g 1 K
⊢ ∃ f, Continuous f ∧ f x = 0 ∧ EqOn f 1 K

Next tactic:
exact ⟨g, cg, hgx, hgK⟩
instance T35Space.instT3space [T35Space X] : T3Space X := by
  

Proof state:
X : Type u
inst✝² : TopologicalSpace X
inst✝¹ : T1Space X
inst✝ : T35Space X
⊢ T3Space X

Next tactic:
have : T0Space X := T1Space.t0Space
instance T35Space.instT3space [T35Space X] : T3Space X := by
  have : T0Space X := T1Space.t0Space
  

Proof state:
X : Type u
inst✝² : TopologicalSpace X
inst✝¹ : T1Space X
inst✝ : T35Space X
this : T0Space X
⊢ T3Space X

Next tactic:
have : RegularSpace X := CompletelyRegularSpace.instRegularSpace
instance T35Space.instT3space [T35Space X] : T3Space X := by
  have : T0Space X := T1Space.t0Space
  have : RegularSpace X := CompletelyRegularSpace.instRegularSpace
  

Proof state:
X : Type u
inst✝² : TopologicalSpace X
inst✝¹ : T1Space X
inst✝ : T35Space X
this✝ : T0Space X
this : RegularSpace X
⊢ T3Space X

Next tactic:
exact {}
instance T4Space.instT35Space [T4Space X] : T35Space X := by
  

Proof state:
X : Type u
inst✝² : TopologicalSpace X
inst✝¹ : T1Space X
inst✝ : T4Space X
⊢ T35Space X

Next tactic:
have : T1Space X := T2Space.t1Space
instance T4Space.instT35Space [T4Space X] : T35Space X := by
  have : T1Space X := T2Space.t1Space
  

Proof state:
X : Type u
inst✝² : TopologicalSpace X
inst✝¹ : T1Space X
inst✝ : T4Space X
this : T1Space X
⊢ T35Space X

Next tactic:
have : CompletelyRegularSpace X := NormalSpace.instCompletelyRegularSpace
instance T4Space.instT35Space [T4Space X] : T35Space X := by
  have : T1Space X := T2Space.t1Space
  have : CompletelyRegularSpace X := NormalSpace.instCompletelyRegularSpace
  

Proof state:
X : Type u
inst✝² : TopologicalSpace X
inst✝¹ : T1Space X
inst✝ : T4Space X
this✝ : T1Space X
this : CompletelyRegularSpace X
⊢ T35Space X

Next tactic:
exact {}
theorem borel_eq_top_of_countable [TopologicalSpace α] [T1Space α] [Countable α] : borel α = ⊤ := by
  

Proof state:
α : Type u_1
β : Type u_2
γ : Type u_3
γ₂ : Type u_4
δ : Type u_5
ι : Sort y
s t u : Set α
inst✝² : TopologicalSpace α
inst✝¹ : T1Space α
inst✝ : Countable α
⊢ borel α = ⊤

Next tactic:
refine' top_le_iff.1 fun s _ => biUnion_of_singleton s ▸ _
theorem borel_eq_top_of_countable [TopologicalSpace α] [T1Space α] [Countable α] : borel α = ⊤ := by
  refine' top_le_iff.1 fun s _ => biUnion_of_singleton s ▸ _
  

Proof state:
α : Type u_1
β : Type u_2
γ : Type u_3
γ₂ : Type u_4
δ : Type u_5
ι : Sort y
s✝ t u : Set α
inst✝² : TopologicalSpace α
inst✝¹ : T1Space α
inst✝ : Countable α
s : Set α
x✝ : MeasurableSet s
⊢ MeasurableSet (⋃ x ∈ s, {x})

Next tactic:
apply MeasurableSet.biUnion s.to_countable
theorem borel_eq_top_of_countable [TopologicalSpace α] [T1Space α] [Countable α] : borel α = ⊤ := by
  refine' top_le_iff.1 fun s _ => biUnion_of_singleton s ▸ _
  apply MeasurableSet.biUnion s.to_countable
  

Proof state:
α : Type u_1
β : Type u_2
γ : Type u_3
γ₂ : Type u_4
δ : Type u_5
ι : Sort y
s✝ t u : Set α
inst✝² : TopologicalSpace α
inst✝¹ : T1Space α
inst✝ : Countable α
s : Set α
x✝ : MeasurableSet s
⊢ ∀ b ∈ s, MeasurableSet {b}

Next tactic:
intro x _
theorem borel_eq_top_of_countable [TopologicalSpace α] [T1Space α] [Countable α] : borel α = ⊤ := by
  refine' top_le_iff.1 fun s _ => biUnion_of_singleton s ▸ _
  apply MeasurableSet.biUnion s.to_countable
  intro x _
  

Proof state:
α : Type u_1
β : Type u_2
γ : Type u_3
γ₂ : Type u_4
δ : Type u_5
ι : Sort y
s✝ t u : Set α
inst✝² : TopologicalSpace α
inst✝¹ : T1Space α
inst✝ : Countable α
s : Set α
x✝ : MeasurableSet s
x : α
a✝ : x ∈ s
⊢ MeasurableSet {x}

Next tactic:
apply MeasurableSet.of_compl
theorem borel_eq_top_of_countable [TopologicalSpace α] [T1Space α] [Countable α] : borel α = ⊤ := by
  refine' top_le_iff.1 fun s _ => biUnion_of_singleton s ▸ _
  apply MeasurableSet.biUnion s.to_countable
  intro x _
  apply MeasurableSet.of_compl
  

Proof state:
case h
α : Type u_1
β : Type u_2
γ : Type u_3
γ₂ : Type u_4
δ : Type u_5
ι : Sort y
s✝ t u : Set α
inst✝² : TopologicalSpace α
inst✝¹ : T1Space α
inst✝ : Countable α
s : Set α
x✝ : MeasurableSet s
x : α
a✝ : x ∈ s
⊢ MeasurableSet {x}ᶜ

Next tactic:
apply GenerateMeasurable.basic
theorem borel_eq_top_of_countable [TopologicalSpace α] [T1Space α] [Countable α] : borel α = ⊤ := by
  refine' top_le_iff.1 fun s _ => biUnion_of_singleton s ▸ _
  apply MeasurableSet.biUnion s.to_countable
  intro x _
  apply MeasurableSet.of_compl
  apply GenerateMeasurable.basic
  

Proof state:
case h.a
α : Type u_1
β : Type u_2
γ : Type u_3
γ₂ : Type u_4
δ : Type u_5
ι : Sort y
s✝ t u : Set α
inst✝² : TopologicalSpace α
inst✝¹ : T1Space α
inst✝ : Countable α
s : Set α
x✝ : MeasurableSet s
x : α
a✝ : x ∈ s
⊢ {x}ᶜ ∈ {s | IsOpen s}

Next tactic:
exact isClosed_singleton.isOpen_compl
theorem borel_eq_generateFrom_of_subbasis {s : Set (Set α)} [t : TopologicalSpace α]
    [SecondCountableTopology α] (hs : t = .generateFrom s) : borel α = .generateFrom s :=
  le_antisymm
    (generateFrom_le fun u (hu : t.IsOpen u) => by
      

Proof state:
α : Type u_1
β : Type u_2
γ : Type u_3
γ₂ : Type u_4
δ : Type u_5
ι : Sort y
s✝ t✝ u✝ : Set α
s : Set (Set α)
t : TopologicalSpace α
inst✝ : SecondCountableTopology α
hs : t = TopologicalSpace.generateFrom s
u : Set α
hu : TopologicalSpace.IsOpen u
⊢ MeasurableSet u

Next tactic:
rw [hs] at hu
theorem borel_eq_generateFrom_of_subbasis {s : Set (Set α)} [t : TopologicalSpace α]
    [SecondCountableTopology α] (hs : t = .generateFrom s) : borel α = .generateFrom s :=
  le_antisymm
    (generateFrom_le fun u (hu : t.IsOpen u) => by
      rw [hs] at hu
      

Proof state:
α : Type u_1
β : Type u_2
γ : Type u_3
γ₂ : Type u_4
δ : Type u_5
ι : Sort y
s✝ t✝ u✝ : Set α
s : Set (Set α)
t : TopologicalSpace α
inst✝ : SecondCountableTopology α
hs : t = TopologicalSpace.generateFrom s
u : Set α
hu : TopologicalSpace.IsOpen u
⊢ MeasurableSet u

Next tactic:
induction hu
theorem borel_eq_generateFrom_of_subbasis {s : Set (Set α)} [t : TopologicalSpace α]
    [SecondCountableTopology α] (hs : t = .generateFrom s) : borel α = .generateFrom s :=
  le_antisymm
    (generateFrom_le fun u (hu : t.IsOpen u) => by
      rw [hs] at hu
      induction hu
      

Proof state:
case basic
α : Type u_1
β : Type u_2
γ : Type u_3
γ₂ : Type u_4
δ : Type u_5
ι : Sort y
s✝¹ t✝ u✝ : Set α
s : Set (Set α)
t : TopologicalSpace α
inst✝ : SecondCountableTopology α
hs : t = TopologicalSpace.generateFrom s
u s✝ : Set α
a✝ : s✝ ∈ s
⊢ MeasurableSet s✝
case univ
α : Type u_1
β : Type u_2
γ : Type u_3
γ₂ : Type u_4
δ : Type u_5
ι : Sort y
s✝ t✝ u✝ : Set α
s : Set (Set α)
t : TopologicalSpace α
inst✝ : SecondCountableTopology α
hs : t = TopologicalSpace.generateFrom s
u : Set α
⊢ MeasurableSet univ
case inter
α : Type u_1
β : Type u_2
γ : Type u_3
γ₂ : Type u_4
δ : Type u_5
ι : Sort y
s✝¹ t✝¹ u✝ : Set α
s : Set (Set α)
t : TopologicalSpace α
inst✝ : SecondCountableTopology α
hs : t = TopologicalSpace.generateFrom s
u s✝ t✝ : Set α
a✝¹ : GenerateOpen s s✝
a✝ : GenerateOpen s t✝
a_ih✝¹ : MeasurableSet s✝
a_ih✝ : MeasurableSet t✝
⊢ MeasurableSet (s✝ ∩ t✝)
case sUnion
α : Type u_1
β : Type u_2
γ : Type u_3
γ₂ : Type u_4
δ : Type u_5
ι : Sort y
s✝ t✝ u✝ : Set α
s : Set (Set α)
t : TopologicalSpace α
inst✝ : SecondCountableTopology α
hs : t = TopologicalSpace.generateFrom s
u : Set α
S✝ : Set (Set α)
a✝ : ∀ s_1 ∈ S✝, GenerateOpen s s_1
a_ih✝ : ∀ s_1 ∈ S✝, MeasurableSet s_1
⊢ MeasurableSet (⋃₀ S✝)

Next tactic:
case basic u hu => exact GenerateMeasurable.basic u hu
theorem borel_eq_generateFrom_of_subbasis {s : Set (Set α)} [t : TopologicalSpace α]
    [SecondCountableTopology α] (hs : t = .generateFrom s) : borel α = .generateFrom s :=
  le_antisymm
    (generateFrom_le fun u (hu : t.IsOpen u) => by
      rw [hs] at hu
      induction hu
      

Proof state:
α : Type u_1
β : Type u_2
γ : Type u_3
γ₂ : Type u_4
δ : Type u_5
ι : Sort y
s✝ t✝ u✝¹ : Set α
s : Set (Set α)
t : TopologicalSpace α
inst✝ : SecondCountableTopology α
hs : t = TopologicalSpace.generateFrom s
u✝ u : Set α
hu : u ∈ s
⊢ MeasurableSet u

Next tactic:
case basic u hu => exact GenerateMeasurable.basic u hu
theorem borel_eq_generateFrom_of_subbasis {s : Set (Set α)} [t : TopologicalSpace α]
    [SecondCountableTopology α] (hs : t = .generateFrom s) : borel α = .generateFrom s :=
  le_antisymm
    (generateFrom_le fun u (hu : t.IsOpen u) => by
      rw [hs] at hu
      induction hu
      case basic u hu => 

Proof state:
α : Type u_1
β : Type u_2
γ : Type u_3
γ₂ : Type u_4
δ : Type u_5
ι : Sort y
s✝ t✝ u✝¹ : Set α
s : Set (Set α)
t : TopologicalSpace α
inst✝ : SecondCountableTopology α
hs : t = TopologicalSpace.generateFrom s
u✝ u : Set α
hu : u ∈ s
⊢ MeasurableSet u

Next tactic:
exact GenerateMeasurable.basic u hu
theorem borel_eq_generateFrom_of_subbasis {s : Set (Set α)} [t : TopologicalSpace α]
    [SecondCountableTopology α] (hs : t = .generateFrom s) : borel α = .generateFrom s :=
  le_antisymm
    (generateFrom_le fun u (hu : t.IsOpen u) => by
      rw [hs] at hu
      induction hu
      case basic u hu => exact GenerateMeasurable.basic u hu
      

Proof state:
case univ
α : Type u_1
β : Type u_2
γ : Type u_3
γ₂ : Type u_4
δ : Type u_5
ι : Sort y
s✝ t✝ u✝ : Set α
s : Set (Set α)
t : TopologicalSpace α
inst✝ : SecondCountableTopology α
hs : t = TopologicalSpace.generateFrom s
u : Set α
⊢ MeasurableSet univ
case inter
α : Type u_1
β : Type u_2
γ : Type u_3
γ₂ : Type u_4
δ : Type u_5
ι : Sort y
s✝¹ t✝¹ u✝ : Set α
s : Set (Set α)
t : TopologicalSpace α
inst✝ : SecondCountableTopology α
hs : t = TopologicalSpace.generateFrom s
u s✝ t✝ : Set α
a✝¹ : GenerateOpen s s✝
a✝ : GenerateOpen s t✝
a_ih✝¹ : MeasurableSet s✝
a_ih✝ : MeasurableSet t✝
⊢ MeasurableSet (s✝ ∩ t✝)
case sUnion
α : Type u_1
β : Type u_2
γ : Type u_3
γ₂ : Type u_4
δ : Type u_5
ι : Sort y
s✝ t✝ u✝ : Set α
s : Set (Set α)
t : TopologicalSpace α
inst✝ : SecondCountableTopology α
hs : t = TopologicalSpace.generateFrom s
u : Set α
S✝ : Set (Set α)
a✝ : ∀ s_1 ∈ S✝, GenerateOpen s s_1
a_ih✝ : ∀ s_1 ∈ S✝, MeasurableSet s_1
⊢ MeasurableSet (⋃₀ S✝)

Next tactic:
case univ => exact @MeasurableSet.univ α (generateFrom s)
theorem borel_eq_generateFrom_of_subbasis {s : Set (Set α)} [t : TopologicalSpace α]
    [SecondCountableTopology α] (hs : t = .generateFrom s) : borel α = .generateFrom s :=
  le_antisymm
    (generateFrom_le fun u (hu : t.IsOpen u) => by
      rw [hs] at hu
      induction hu
      case basic u hu => exact GenerateMeasurable.basic u hu
      

Proof state:
α : Type u_1
β : Type u_2
γ : Type u_3
γ₂ : Type u_4
δ : Type u_5
ι : Sort y
s✝ t✝ u✝ : Set α
s : Set (Set α)
t : TopologicalSpace α
inst✝ : SecondCountableTopology α
hs : t = TopologicalSpace.generateFrom s
u : Set α
⊢ MeasurableSet univ

Next tactic:
case univ => exact @MeasurableSet.univ α (generateFrom s)