Theorem: Profinite.exists_isClopen_of_cofiltered
File: Mathlib/Topology/Category/Profinite/CofilteredLimit.lean

tactic: have hB := TopCat.isTopologicalBasis_cofiltered_limit.{u, v} (F ⋙ Profinite.toTopCat)
    (Profinite.toTopCat.mapCone C) (isLimitOfPreserves _ hC) (fun j => {W | IsClopen W}) ?_
    (fun i => isClopen_univ) (fun i U1 U2 hU1 hU2 => hU1.inter hU2) ?_
state_before: J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
⊢ ∃ j V, IsClopen V ∧ U = ⇑(C.π.app j) ⁻¹' V
state_after: case refine_3
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
hB :
  TopologicalSpace.IsTopologicalBasis
    {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
⊢ ∃ j V, IsClopen V ∧ U = ⇑(C.π.app j) ⁻¹' V

case refine_1
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
⊢ ∀ (j : J), TopologicalSpace.IsTopologicalBasis ((fun j => {W | IsClopen W}) j)

case refine_2
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
⊢ ∀ (i j : J) (f : i ⟶ j),
    ∀ V ∈ (fun j => {W | IsClopen W}) j, ⇑((F ⋙ toTopCat).map f) ⁻¹' V ∈ (fun j => {W | IsClopen W}) i

tactic: rotate_left
state_before: case refine_3
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
hB :
  TopologicalSpace.IsTopologicalBasis
    {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
⊢ ∃ j V, IsClopen V ∧ U = ⇑(C.π.app j) ⁻¹' V

case refine_1
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
⊢ ∀ (j : J), TopologicalSpace.IsTopologicalBasis ((fun j => {W | IsClopen W}) j)

case refine_2
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
⊢ ∀ (i j : J) (f : i ⟶ j),
    ∀ V ∈ (fun j => {W | IsClopen W}) j, ⇑((F ⋙ toTopCat).map f) ⁻¹' V ∈ (fun j => {W | IsClopen W}) i
state_after: case refine_1
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
⊢ ∀ (j : J), TopologicalSpace.IsTopologicalBasis ((fun j => {W | IsClopen W}) j)

case refine_2
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
⊢ ∀ (i j : J) (f : i ⟶ j),
    ∀ V ∈ (fun j => {W | IsClopen W}) j, ⇑((F ⋙ toTopCat).map f) ⁻¹' V ∈ (fun j => {W | IsClopen W}) i

case refine_3
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
hB :
  TopologicalSpace.IsTopologicalBasis
    {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
⊢ ∃ j V, IsClopen V ∧ U = ⇑(C.π.app j) ⁻¹' V

tactic: obtain ⟨S, hS, h⟩ := hB.open_eq_sUnion hU.2
state_before: case refine_3
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
hB :
  TopologicalSpace.IsTopologicalBasis
    {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
⊢ ∃ j V, IsClopen V ∧ U = ⇑(C.π.app j) ⁻¹' V
state_after: case refine_3.intro.intro
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
hB :
  TopologicalSpace.IsTopologicalBasis
    {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
⊢ ∃ j V, IsClopen V ∧ U = ⇑(C.π.app j) ⁻¹' V

tactic: clear hB
state_before: case refine_3.intro.intro
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
hB :
  TopologicalSpace.IsTopologicalBasis
    {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
⊢ ∃ j V, IsClopen V ∧ U = ⇑(C.π.app j) ⁻¹' V
state_after: case refine_3.intro.intro
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
⊢ ∃ j V, IsClopen V ∧ U = ⇑(C.π.app j) ⁻¹' V

tactic: let j : S → J := fun s => (hS s.2).choose
state_before: case refine_3.intro.intro
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
⊢ ∃ j V, IsClopen V ∧ U = ⇑(C.π.app j) ⁻¹' V
state_after: case refine_3.intro.intro
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
⊢ ∃ j V, IsClopen V ∧ U = ⇑(C.π.app j) ⁻¹' V

tactic: let V : ∀ s : S, Set (F.obj (j s)) := fun s => (hS s.2).choose_spec.choose
state_before: case refine_3.intro.intro
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
⊢ ∃ j V, IsClopen V ∧ U = ⇑(C.π.app j) ⁻¹' V
state_after: case refine_3.intro.intro
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
⊢ ∃ j V, IsClopen V ∧ U = ⇑(C.π.app j) ⁻¹' V

tactic: have hV : ∀ s : S, IsClopen (V s) ∧ s.1 = C.π.app (j s) ⁻¹' V s := fun s =>
  (hS s.2).choose_spec.choose_spec
state_before: case refine_3.intro.intro
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
⊢ ∃ j V, IsClopen V ∧ U = ⇑(C.π.app j) ⁻¹' V
state_after: case refine_3.intro.intro
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
⊢ ∃ j V, IsClopen V ∧ U = ⇑(C.π.app j) ⁻¹' V

tactic: have hUo : ∀ (i : ↑S), IsOpen ((fun s ↦ (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i) := by
  intro s
  exact (hV s).1.2.preimage (C.π.app (j s)).continuous
state_before: case refine_3.intro.intro
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
⊢ ∃ j V, IsClopen V ∧ U = ⇑(C.π.app j) ⁻¹' V
state_after: case refine_3.intro.intro
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
hUo : ∀ (i : ↑S), IsOpen ((fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i)
⊢ ∃ j V, IsClopen V ∧ U = ⇑(C.π.app j) ⁻¹' V

tactic: have hsU : U ⊆ ⋃ (i : ↑S), (fun s ↦ (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i := by
  dsimp only
  rw [h]
  rintro x ⟨T, hT, hx⟩
  refine ⟨_, ⟨⟨T, hT⟩, rfl⟩, ?_⟩
  dsimp only [forget_map_eq_coe]
  rwa [← (hV ⟨T, hT⟩).2]
state_before: case refine_3.intro.intro
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
hUo : ∀ (i : ↑S), IsOpen ((fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i)
⊢ ∃ j V, IsClopen V ∧ U = ⇑(C.π.app j) ⁻¹' V
state_after: case refine_3.intro.intro
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
hUo : ∀ (i : ↑S), IsOpen ((fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i)
hsU : U ⊆ ⋃ i, (fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i
⊢ ∃ j V, IsClopen V ∧ U = ⇑(C.π.app j) ⁻¹' V

tactic: have := hU.1.isCompact.elim_finite_subcover (fun s : S => C.π.app (j s) ⁻¹' V s) hUo hsU
state_before: case refine_3.intro.intro
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
hUo : ∀ (i : ↑S), IsOpen ((fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i)
hsU : U ⊆ ⋃ i, (fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i
⊢ ∃ j V, IsClopen V ∧ U = ⇑(C.π.app j) ⁻¹' V
state_after: case refine_3.intro.intro
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
hUo : ∀ (i : ↑S), IsOpen ((fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i)
hsU : U ⊆ ⋃ i, (fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i
this : ∃ t, U ⊆ ⋃ i ∈ t, (fun s => ⇑(C.π.app (j s)) ⁻¹' V s) i
⊢ ∃ j V, IsClopen V ∧ U = ⇑(C.π.app j) ⁻¹' V

tactic: obtain ⟨G, hG⟩ := this
state_before: case refine_3.intro.intro
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
hUo : ∀ (i : ↑S), IsOpen ((fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i)
hsU : U ⊆ ⋃ i, (fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i
this : ∃ t, U ⊆ ⋃ i ∈ t, (fun s => ⇑(C.π.app (j s)) ⁻¹' V s) i
⊢ ∃ j V, IsClopen V ∧ U = ⇑(C.π.app j) ⁻¹' V
state_after: case refine_3.intro.intro.intro
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
hUo : ∀ (i : ↑S), IsOpen ((fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i)
hsU : U ⊆ ⋃ i, (fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i
G : Finset ↑S
hG : U ⊆ ⋃ i ∈ G, (fun s => ⇑(C.π.app (j s)) ⁻¹' V s) i
⊢ ∃ j V, IsClopen V ∧ U = ⇑(C.π.app j) ⁻¹' V

tactic: obtain ⟨j0, hj0⟩ := IsCofiltered.inf_objs_exists (G.image j)
state_before: case refine_3.intro.intro.intro
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
hUo : ∀ (i : ↑S), IsOpen ((fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i)
hsU : U ⊆ ⋃ i, (fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i
G : Finset ↑S
hG : U ⊆ ⋃ i ∈ G, (fun s => ⇑(C.π.app (j s)) ⁻¹' V s) i
⊢ ∃ j V, IsClopen V ∧ U = ⇑(C.π.app j) ⁻¹' V
state_after: case refine_3.intro.intro.intro.intro
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
hUo : ∀ (i : ↑S), IsOpen ((fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i)
hsU : U ⊆ ⋃ i, (fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i
G : Finset ↑S
hG : U ⊆ ⋃ i ∈ G, (fun s => ⇑(C.π.app (j s)) ⁻¹' V s) i
j0 : J
hj0 : ∀ {X : J}, X ∈ Finset.image j G → Nonempty (j0 ⟶ X)
⊢ ∃ j V, IsClopen V ∧ U = ⇑(C.π.app j) ⁻¹' V

tactic: let f : ∀ s ∈ G, j0 ⟶ j s := fun s hs => (hj0 (Finset.mem_image.mpr ⟨s, hs, rfl⟩)).some
state_before: case refine_3.intro.intro.intro.intro
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
hUo : ∀ (i : ↑S), IsOpen ((fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i)
hsU : U ⊆ ⋃ i, (fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i
G : Finset ↑S
hG : U ⊆ ⋃ i ∈ G, (fun s => ⇑(C.π.app (j s)) ⁻¹' V s) i
j0 : J
hj0 : ∀ {X : J}, X ∈ Finset.image j G → Nonempty (j0 ⟶ X)
⊢ ∃ j V, IsClopen V ∧ U = ⇑(C.π.app j) ⁻¹' V
state_after: case refine_3.intro.intro.intro.intro
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
hUo : ∀ (i : ↑S), IsOpen ((fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i)
hsU : U ⊆ ⋃ i, (fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i
G : Finset ↑S
hG : U ⊆ ⋃ i ∈ G, (fun s => ⇑(C.π.app (j s)) ⁻¹' V s) i
j0 : J
hj0 : ∀ {X : J}, X ∈ Finset.image j G → Nonempty (j0 ⟶ X)
f : (s : ↑S) → s ∈ G → (j0 ⟶ j s) := fun s hs => ⋯.some
⊢ ∃ j V, IsClopen V ∧ U = ⇑(C.π.app j) ⁻¹' V

tactic: let W : S → Set (F.obj j0) := fun s => if hs : s ∈ G then F.map (f s hs) ⁻¹' V s else Set.univ
state_before: case refine_3.intro.intro.intro.intro
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
hUo : ∀ (i : ↑S), IsOpen ((fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i)
hsU : U ⊆ ⋃ i, (fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i
G : Finset ↑S
hG : U ⊆ ⋃ i ∈ G, (fun s => ⇑(C.π.app (j s)) ⁻¹' V s) i
j0 : J
hj0 : ∀ {X : J}, X ∈ Finset.image j G → Nonempty (j0 ⟶ X)
f : (s : ↑S) → s ∈ G → (j0 ⟶ j s) := fun s hs => ⋯.some
⊢ ∃ j V, IsClopen V ∧ U = ⇑(C.π.app j) ⁻¹' V
state_after: case refine_3.intro.intro.intro.intro
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
hUo : ∀ (i : ↑S), IsOpen ((fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i)
hsU : U ⊆ ⋃ i, (fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i
G : Finset ↑S
hG : U ⊆ ⋃ i ∈ G, (fun s => ⇑(C.π.app (j s)) ⁻¹' V s) i
j0 : J
hj0 : ∀ {X : J}, X ∈ Finset.image j G → Nonempty (j0 ⟶ X)
f : (s : ↑S) → s ∈ G → (j0 ⟶ j s) := fun s hs => ⋯.some
W : ↑S → Set ↑(F.obj j0).toCompHaus.toTop := fun s => if hs : s ∈ G then ⇑(F.map (f s hs)) ⁻¹' V s else Set.univ
⊢ ∃ j V, IsClopen V ∧ U = ⇑(C.π.app j) ⁻¹' V

tactic: refine ⟨j0, ⋃ (s : S) (_ : s ∈ G), W s, ?_, ?_⟩
state_before: case refine_3.intro.intro.intro.intro
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
hUo : ∀ (i : ↑S), IsOpen ((fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i)
hsU : U ⊆ ⋃ i, (fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i
G : Finset ↑S
hG : U ⊆ ⋃ i ∈ G, (fun s => ⇑(C.π.app (j s)) ⁻¹' V s) i
j0 : J
hj0 : ∀ {X : J}, X ∈ Finset.image j G → Nonempty (j0 ⟶ X)
f : (s : ↑S) → s ∈ G → (j0 ⟶ j s) := fun s hs => ⋯.some
W : ↑S → Set ↑(F.obj j0).toCompHaus.toTop := fun s => if hs : s ∈ G then ⇑(F.map (f s hs)) ⁻¹' V s else Set.univ
⊢ ∃ j V, IsClopen V ∧ U = ⇑(C.π.app j) ⁻¹' V
state_after: case refine_3.intro.intro.intro.intro.refine_1
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
hUo : ∀ (i : ↑S), IsOpen ((fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i)
hsU : U ⊆ ⋃ i, (fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i
G : Finset ↑S
hG : U ⊆ ⋃ i ∈ G, (fun s => ⇑(C.π.app (j s)) ⁻¹' V s) i
j0 : J
hj0 : ∀ {X : J}, X ∈ Finset.image j G → Nonempty (j0 ⟶ X)
f : (s : ↑S) → s ∈ G → (j0 ⟶ j s) := fun s hs => ⋯.some
W : ↑S → Set ↑(F.obj j0).toCompHaus.toTop := fun s => if hs : s ∈ G then ⇑(F.map (f s hs)) ⁻¹' V s else Set.univ
⊢ IsClopen (⋃ s ∈ G, W s)

case refine_3.intro.intro.intro.intro.refine_2
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
hUo : ∀ (i : ↑S), IsOpen ((fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i)
hsU : U ⊆ ⋃ i, (fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i
G : Finset ↑S
hG : U ⊆ ⋃ i ∈ G, (fun s => ⇑(C.π.app (j s)) ⁻¹' V s) i
j0 : J
hj0 : ∀ {X : J}, X ∈ Finset.image j G → Nonempty (j0 ⟶ X)
f : (s : ↑S) → s ∈ G → (j0 ⟶ j s) := fun s hs => ⋯.some
W : ↑S → Set ↑(F.obj j0).toCompHaus.toTop := fun s => if hs : s ∈ G then ⇑(F.map (f s hs)) ⁻¹' V s else Set.univ
⊢ U = ⇑(C.π.app j0) ⁻¹' ⋃ s ∈ G, W s

tactic: intro i
state_before: case refine_1
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
⊢ ∀ (j : J), TopologicalSpace.IsTopologicalBasis ((fun j => {W | IsClopen W}) j)
state_after: case refine_1
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
i : J
⊢ TopologicalSpace.IsTopologicalBasis ((fun j => {W | IsClopen W}) i)

tactic: change TopologicalSpace.IsTopologicalBasis {W : Set (F.obj i) | IsClopen W}
state_before: case refine_1
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
i : J
⊢ TopologicalSpace.IsTopologicalBasis ((fun j => {W | IsClopen W}) i)
state_after: case refine_1
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
i : J
⊢ TopologicalSpace.IsTopologicalBasis {W | IsClopen W}

tactic: apply isTopologicalBasis_isClopen
state_before: case refine_1
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
i : J
⊢ TopologicalSpace.IsTopologicalBasis {W | IsClopen W}
state_after: no goals

tactic: rintro i j f V (hV : IsClopen _)
state_before: case refine_2
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
⊢ ∀ (i j : J) (f : i ⟶ j),
    ∀ V ∈ (fun j => {W | IsClopen W}) j, ⇑((F ⋙ toTopCat).map f) ⁻¹' V ∈ (fun j => {W | IsClopen W}) i
state_after: case refine_2
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
i j : J
f : i ⟶ j
V : Set ↑((F ⋙ toTopCat).obj j)
hV : IsClopen V
⊢ ⇑((F ⋙ toTopCat).map f) ⁻¹' V ∈ (fun j => {W | IsClopen W}) i

tactic: exact ⟨hV.1.preimage ((F ⋙ toTopCat).map f).continuous,
  hV.2.preimage ((F ⋙ toTopCat).map f).continuous⟩
state_before: case refine_2
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
i j : J
f : i ⟶ j
V : Set ↑((F ⋙ toTopCat).obj j)
hV : IsClopen V
⊢ ⇑((F ⋙ toTopCat).map f) ⁻¹' V ∈ (fun j => {W | IsClopen W}) i
state_after: no goals

tactic: intro s
state_before: J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
⊢ ∀ (i : ↑S), IsOpen ((fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i)
state_after: J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
s : ↑S
⊢ IsOpen ((fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) s)

tactic: exact (hV s).1.2.preimage (C.π.app (j s)).continuous
state_before: J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
s : ↑S
⊢ IsOpen ((fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) s)
state_after: no goals

tactic: dsimp only
state_before: J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
hUo : ∀ (i : ↑S), IsOpen ((fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i)
⊢ U ⊆ ⋃ i, (fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i
state_after: J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
hUo : ∀ (i : ↑S), IsOpen ((fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i)
⊢ U ⊆ ⋃ i, (forget Profinite).map (C.π.app (j i)) ⁻¹' V i

tactic: rw [h]
state_before: J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
hUo : ∀ (i : ↑S), IsOpen ((fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i)
⊢ U ⊆ ⋃ i, (forget Profinite).map (C.π.app (j i)) ⁻¹' V i
state_after: J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
hUo : ∀ (i : ↑S), IsOpen ((fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i)
⊢ ⋃₀ S ⊆ ⋃ i, (forget Profinite).map (C.π.app (j i)) ⁻¹' V i

tactic: rintro x ⟨T, hT, hx⟩
state_before: J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
hUo : ∀ (i : ↑S), IsOpen ((fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i)
⊢ ⋃₀ S ⊆ ⋃ i, (forget Profinite).map (C.π.app (j i)) ⁻¹' V i
state_after: case intro.intro
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
hUo : ∀ (i : ↑S), IsOpen ((fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i)
x : ↑C.pt.toCompHaus.toTop
T : Set ↑(toTopCat.mapCone C).pt
hT : T ∈ S
hx : x ∈ T
⊢ x ∈ ⋃ i, (forget Profinite).map (C.π.app (j i)) ⁻¹' V i

tactic: refine ⟨_, ⟨⟨T, hT⟩, rfl⟩, ?_⟩
state_before: case intro.intro
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
hUo : ∀ (i : ↑S), IsOpen ((fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i)
x : ↑C.pt.toCompHaus.toTop
T : Set ↑(toTopCat.mapCone C).pt
hT : T ∈ S
hx : x ∈ T
⊢ x ∈ ⋃ i, (forget Profinite).map (C.π.app (j i)) ⁻¹' V i
state_after: case intro.intro
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
hUo : ∀ (i : ↑S), IsOpen ((fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i)
x : ↑C.pt.toCompHaus.toTop
T : Set ↑(toTopCat.mapCone C).pt
hT : T ∈ S
hx : x ∈ T
⊢ x ∈ (fun i => (forget Profinite).map (C.π.app (j i)) ⁻¹' V i) ⟨T, hT⟩

tactic: dsimp only [forget_map_eq_coe]
state_before: case intro.intro
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
hUo : ∀ (i : ↑S), IsOpen ((fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i)
x : ↑C.pt.toCompHaus.toTop
T : Set ↑(toTopCat.mapCone C).pt
hT : T ∈ S
hx : x ∈ T
⊢ x ∈ (fun i => (forget Profinite).map (C.π.app (j i)) ⁻¹' V i) ⟨T, hT⟩
state_after: case intro.intro
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
hUo : ∀ (i : ↑S), IsOpen ((fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i)
x : ↑C.pt.toCompHaus.toTop
T : Set ↑(toTopCat.mapCone C).pt
hT : T ∈ S
hx : x ∈ T
⊢ x ∈ ⇑(C.π.app (j ⟨T, hT⟩)) ⁻¹' V ⟨T, hT⟩

tactic: rwa [← (hV ⟨T, hT⟩).2]
state_before: case intro.intro
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
hUo : ∀ (i : ↑S), IsOpen ((fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i)
x : ↑C.pt.toCompHaus.toTop
T : Set ↑(toTopCat.mapCone C).pt
hT : T ∈ S
hx : x ∈ T
⊢ x ∈ ⇑(C.π.app (j ⟨T, hT⟩)) ⁻¹' V ⟨T, hT⟩
state_after: no goals

tactic: apply isClopen_biUnion_finset
state_before: case refine_3.intro.intro.intro.intro.refine_1
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
hUo : ∀ (i : ↑S), IsOpen ((fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i)
hsU : U ⊆ ⋃ i, (fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i
G : Finset ↑S
hG : U ⊆ ⋃ i ∈ G, (fun s => ⇑(C.π.app (j s)) ⁻¹' V s) i
j0 : J
hj0 : ∀ {X : J}, X ∈ Finset.image j G → Nonempty (j0 ⟶ X)
f : (s : ↑S) → s ∈ G → (j0 ⟶ j s) := fun s hs => ⋯.some
W : ↑S → Set ↑(F.obj j0).toCompHaus.toTop := fun s => if hs : s ∈ G then ⇑(F.map (f s hs)) ⁻¹' V s else Set.univ
⊢ IsClopen (⋃ s ∈ G, W s)
state_after: case refine_3.intro.intro.intro.intro.refine_1.h
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
hUo : ∀ (i : ↑S), IsOpen ((fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i)
hsU : U ⊆ ⋃ i, (fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i
G : Finset ↑S
hG : U ⊆ ⋃ i ∈ G, (fun s => ⇑(C.π.app (j s)) ⁻¹' V s) i
j0 : J
hj0 : ∀ {X : J}, X ∈ Finset.image j G → Nonempty (j0 ⟶ X)
f : (s : ↑S) → s ∈ G → (j0 ⟶ j s) := fun s hs => ⋯.some
W : ↑S → Set ↑(F.obj j0).toCompHaus.toTop := fun s => if hs : s ∈ G then ⇑(F.map (f s hs)) ⁻¹' V s else Set.univ
⊢ ∀ i ∈ G, IsClopen (W i)

tactic: intro s hs
state_before: case refine_3.intro.intro.intro.intro.refine_1.h
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
hUo : ∀ (i : ↑S), IsOpen ((fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i)
hsU : U ⊆ ⋃ i, (fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i
G : Finset ↑S
hG : U ⊆ ⋃ i ∈ G, (fun s => ⇑(C.π.app (j s)) ⁻¹' V s) i
j0 : J
hj0 : ∀ {X : J}, X ∈ Finset.image j G → Nonempty (j0 ⟶ X)
f : (s : ↑S) → s ∈ G → (j0 ⟶ j s) := fun s hs => ⋯.some
W : ↑S → Set ↑(F.obj j0).toCompHaus.toTop := fun s => if hs : s ∈ G then ⇑(F.map (f s hs)) ⁻¹' V s else Set.univ
⊢ ∀ i ∈ G, IsClopen (W i)
state_after: case refine_3.intro.intro.intro.intro.refine_1.h
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
hUo : ∀ (i : ↑S), IsOpen ((fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i)
hsU : U ⊆ ⋃ i, (fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i
G : Finset ↑S
hG : U ⊆ ⋃ i ∈ G, (fun s => ⇑(C.π.app (j s)) ⁻¹' V s) i
j0 : J
hj0 : ∀ {X : J}, X ∈ Finset.image j G → Nonempty (j0 ⟶ X)
f : (s : ↑S) → s ∈ G → (j0 ⟶ j s) := fun s hs => ⋯.some
W : ↑S → Set ↑(F.obj j0).toCompHaus.toTop := fun s => if hs : s ∈ G then ⇑(F.map (f s hs)) ⁻¹' V s else Set.univ
s : ↑S
hs : s ∈ G
⊢ IsClopen (W s)

tactic: dsimp [W]
state_before: case refine_3.intro.intro.intro.intro.refine_1.h
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
hUo : ∀ (i : ↑S), IsOpen ((fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i)
hsU : U ⊆ ⋃ i, (fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i
G : Finset ↑S
hG : U ⊆ ⋃ i ∈ G, (fun s => ⇑(C.π.app (j s)) ⁻¹' V s) i
j0 : J
hj0 : ∀ {X : J}, X ∈ Finset.image j G → Nonempty (j0 ⟶ X)
f : (s : ↑S) → s ∈ G → (j0 ⟶ j s) := fun s hs => ⋯.some
W : ↑S → Set ↑(F.obj j0).toCompHaus.toTop := fun s => if hs : s ∈ G then ⇑(F.map (f s hs)) ⁻¹' V s else Set.univ
s : ↑S
hs : s ∈ G
⊢ IsClopen (W s)
state_after: case refine_3.intro.intro.intro.intro.refine_1.h
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
hUo : ∀ (i : ↑S), IsOpen ((fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i)
hsU : U ⊆ ⋃ i, (fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i
G : Finset ↑S
hG : U ⊆ ⋃ i ∈ G, (fun s => ⇑(C.π.app (j s)) ⁻¹' V s) i
j0 : J
hj0 : ∀ {X : J}, X ∈ Finset.image j G → Nonempty (j0 ⟶ X)
f : (s : ↑S) → s ∈ G → (j0 ⟶ j s) := fun s hs => ⋯.some
W : ↑S → Set ↑(F.obj j0).toCompHaus.toTop := fun s => if hs : s ∈ G then ⇑(F.map (f s hs)) ⁻¹' V s else Set.univ
s : ↑S
hs : s ∈ G
⊢ IsClopen (if hs : s ∈ G then ⇑(F.map (f s hs)) ⁻¹' V s else Set.univ)

tactic: rw [dif_pos hs]
state_before: case refine_3.intro.intro.intro.intro.refine_1.h
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
hUo : ∀ (i : ↑S), IsOpen ((fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i)
hsU : U ⊆ ⋃ i, (fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i
G : Finset ↑S
hG : U ⊆ ⋃ i ∈ G, (fun s => ⇑(C.π.app (j s)) ⁻¹' V s) i
j0 : J
hj0 : ∀ {X : J}, X ∈ Finset.image j G → Nonempty (j0 ⟶ X)
f : (s : ↑S) → s ∈ G → (j0 ⟶ j s) := fun s hs => ⋯.some
W : ↑S → Set ↑(F.obj j0).toCompHaus.toTop := fun s => if hs : s ∈ G then ⇑(F.map (f s hs)) ⁻¹' V s else Set.univ
s : ↑S
hs : s ∈ G
⊢ IsClopen (if hs : s ∈ G then ⇑(F.map (f s hs)) ⁻¹' V s else Set.univ)
state_after: case refine_3.intro.intro.intro.intro.refine_1.h
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
hUo : ∀ (i : ↑S), IsOpen ((fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i)
hsU : U ⊆ ⋃ i, (fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i
G : Finset ↑S
hG : U ⊆ ⋃ i ∈ G, (fun s => ⇑(C.π.app (j s)) ⁻¹' V s) i
j0 : J
hj0 : ∀ {X : J}, X ∈ Finset.image j G → Nonempty (j0 ⟶ X)
f : (s : ↑S) → s ∈ G → (j0 ⟶ j s) := fun s hs => ⋯.some
W : ↑S → Set ↑(F.obj j0).toCompHaus.toTop := fun s => if hs : s ∈ G then ⇑(F.map (f s hs)) ⁻¹' V s else Set.univ
s : ↑S
hs : s ∈ G
⊢ IsClopen (⇑(F.map (f s hs)) ⁻¹' V s)

tactic: exact ⟨(hV s).1.1.preimage (F.map _).continuous, (hV s).1.2.preimage (F.map _).continuous⟩
state_before: case refine_3.intro.intro.intro.intro.refine_1.h
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
hUo : ∀ (i : ↑S), IsOpen ((fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i)
hsU : U ⊆ ⋃ i, (fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i
G : Finset ↑S
hG : U ⊆ ⋃ i ∈ G, (fun s => ⇑(C.π.app (j s)) ⁻¹' V s) i
j0 : J
hj0 : ∀ {X : J}, X ∈ Finset.image j G → Nonempty (j0 ⟶ X)
f : (s : ↑S) → s ∈ G → (j0 ⟶ j s) := fun s hs => ⋯.some
W : ↑S → Set ↑(F.obj j0).toCompHaus.toTop := fun s => if hs : s ∈ G then ⇑(F.map (f s hs)) ⁻¹' V s else Set.univ
s : ↑S
hs : s ∈ G
⊢ IsClopen (⇑(F.map (f s hs)) ⁻¹' V s)
state_after: no goals

tactic: ext x
state_before: case refine_3.intro.intro.intro.intro.refine_2
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
hUo : ∀ (i : ↑S), IsOpen ((fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i)
hsU : U ⊆ ⋃ i, (fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i
G : Finset ↑S
hG : U ⊆ ⋃ i ∈ G, (fun s => ⇑(C.π.app (j s)) ⁻¹' V s) i
j0 : J
hj0 : ∀ {X : J}, X ∈ Finset.image j G → Nonempty (j0 ⟶ X)
f : (s : ↑S) → s ∈ G → (j0 ⟶ j s) := fun s hs => ⋯.some
W : ↑S → Set ↑(F.obj j0).toCompHaus.toTop := fun s => if hs : s ∈ G then ⇑(F.map (f s hs)) ⁻¹' V s else Set.univ
⊢ U = ⇑(C.π.app j0) ⁻¹' ⋃ s ∈ G, W s
state_after: case refine_3.intro.intro.intro.intro.refine_2.h
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
hUo : ∀ (i : ↑S), IsOpen ((fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i)
hsU : U ⊆ ⋃ i, (fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i
G : Finset ↑S
hG : U ⊆ ⋃ i ∈ G, (fun s => ⇑(C.π.app (j s)) ⁻¹' V s) i
j0 : J
hj0 : ∀ {X : J}, X ∈ Finset.image j G → Nonempty (j0 ⟶ X)
f : (s : ↑S) → s ∈ G → (j0 ⟶ j s) := fun s hs => ⋯.some
W : ↑S → Set ↑(F.obj j0).toCompHaus.toTop := fun s => if hs : s ∈ G then ⇑(F.map (f s hs)) ⁻¹' V s else Set.univ
x : ↑C.pt.toCompHaus.toTop
⊢ x ∈ U ↔ x ∈ ⇑(C.π.app j0) ⁻¹' ⋃ s ∈ G, W s

tactic: constructor
state_before: case refine_3.intro.intro.intro.intro.refine_2.h
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
hUo : ∀ (i : ↑S), IsOpen ((fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i)
hsU : U ⊆ ⋃ i, (fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i
G : Finset ↑S
hG : U ⊆ ⋃ i ∈ G, (fun s => ⇑(C.π.app (j s)) ⁻¹' V s) i
j0 : J
hj0 : ∀ {X : J}, X ∈ Finset.image j G → Nonempty (j0 ⟶ X)
f : (s : ↑S) → s ∈ G → (j0 ⟶ j s) := fun s hs => ⋯.some
W : ↑S → Set ↑(F.obj j0).toCompHaus.toTop := fun s => if hs : s ∈ G then ⇑(F.map (f s hs)) ⁻¹' V s else Set.univ
x : ↑C.pt.toCompHaus.toTop
⊢ x ∈ U ↔ x ∈ ⇑(C.π.app j0) ⁻¹' ⋃ s ∈ G, W s
state_after: case refine_3.intro.intro.intro.intro.refine_2.h.mp
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
hUo : ∀ (i : ↑S), IsOpen ((fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i)
hsU : U ⊆ ⋃ i, (fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i
G : Finset ↑S
hG : U ⊆ ⋃ i ∈ G, (fun s => ⇑(C.π.app (j s)) ⁻¹' V s) i
j0 : J
hj0 : ∀ {X : J}, X ∈ Finset.image j G → Nonempty (j0 ⟶ X)
f : (s : ↑S) → s ∈ G → (j0 ⟶ j s) := fun s hs => ⋯.some
W : ↑S → Set ↑(F.obj j0).toCompHaus.toTop := fun s => if hs : s ∈ G then ⇑(F.map (f s hs)) ⁻¹' V s else Set.univ
x : ↑C.pt.toCompHaus.toTop
⊢ x ∈ U → x ∈ ⇑(C.π.app j0) ⁻¹' ⋃ s ∈ G, W s

case refine_3.intro.intro.intro.intro.refine_2.h.mpr
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
hUo : ∀ (i : ↑S), IsOpen ((fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i)
hsU : U ⊆ ⋃ i, (fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i
G : Finset ↑S
hG : U ⊆ ⋃ i ∈ G, (fun s => ⇑(C.π.app (j s)) ⁻¹' V s) i
j0 : J
hj0 : ∀ {X : J}, X ∈ Finset.image j G → Nonempty (j0 ⟶ X)
f : (s : ↑S) → s ∈ G → (j0 ⟶ j s) := fun s hs => ⋯.some
W : ↑S → Set ↑(F.obj j0).toCompHaus.toTop := fun s => if hs : s ∈ G then ⇑(F.map (f s hs)) ⁻¹' V s else Set.univ
x : ↑C.pt.toCompHaus.toTop
⊢ x ∈ ⇑(C.π.app j0) ⁻¹' ⋃ s ∈ G, W s → x ∈ U

tactic: intro hx
state_before: case refine_3.intro.intro.intro.intro.refine_2.h.mp
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
hUo : ∀ (i : ↑S), IsOpen ((fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i)
hsU : U ⊆ ⋃ i, (fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i
G : Finset ↑S
hG : U ⊆ ⋃ i ∈ G, (fun s => ⇑(C.π.app (j s)) ⁻¹' V s) i
j0 : J
hj0 : ∀ {X : J}, X ∈ Finset.image j G → Nonempty (j0 ⟶ X)
f : (s : ↑S) → s ∈ G → (j0 ⟶ j s) := fun s hs => ⋯.some
W : ↑S → Set ↑(F.obj j0).toCompHaus.toTop := fun s => if hs : s ∈ G then ⇑(F.map (f s hs)) ⁻¹' V s else Set.univ
x : ↑C.pt.toCompHaus.toTop
⊢ x ∈ U → x ∈ ⇑(C.π.app j0) ⁻¹' ⋃ s ∈ G, W s
state_after: case refine_3.intro.intro.intro.intro.refine_2.h.mp
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
hUo : ∀ (i : ↑S), IsOpen ((fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i)
hsU : U ⊆ ⋃ i, (fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i
G : Finset ↑S
hG : U ⊆ ⋃ i ∈ G, (fun s => ⇑(C.π.app (j s)) ⁻¹' V s) i
j0 : J
hj0 : ∀ {X : J}, X ∈ Finset.image j G → Nonempty (j0 ⟶ X)
f : (s : ↑S) → s ∈ G → (j0 ⟶ j s) := fun s hs => ⋯.some
W : ↑S → Set ↑(F.obj j0).toCompHaus.toTop := fun s => if hs : s ∈ G then ⇑(F.map (f s hs)) ⁻¹' V s else Set.univ
x : ↑C.pt.toCompHaus.toTop
hx : x ∈ U
⊢ x ∈ ⇑(C.π.app j0) ⁻¹' ⋃ s ∈ G, W s

tactic: simp_rw [W, Set.preimage_iUnion, Set.mem_iUnion]
state_before: case refine_3.intro.intro.intro.intro.refine_2.h.mp
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
hUo : ∀ (i : ↑S), IsOpen ((fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i)
hsU : U ⊆ ⋃ i, (fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i
G : Finset ↑S
hG : U ⊆ ⋃ i ∈ G, (fun s => ⇑(C.π.app (j s)) ⁻¹' V s) i
j0 : J
hj0 : ∀ {X : J}, X ∈ Finset.image j G → Nonempty (j0 ⟶ X)
f : (s : ↑S) → s ∈ G → (j0 ⟶ j s) := fun s hs => ⋯.some
W : ↑S → Set ↑(F.obj j0).toCompHaus.toTop := fun s => if hs : s ∈ G then ⇑(F.map (f s hs)) ⁻¹' V s else Set.univ
x : ↑C.pt.toCompHaus.toTop
hx : x ∈ U
⊢ x ∈ ⇑(C.π.app j0) ⁻¹' ⋃ s ∈ G, W s
state_after: case refine_3.intro.intro.intro.intro.refine_2.h.mp
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
hUo : ∀ (i : ↑S), IsOpen ((fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i)
hsU : U ⊆ ⋃ i, (fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i
G : Finset ↑S
hG : U ⊆ ⋃ i ∈ G, (fun s => ⇑(C.π.app (j s)) ⁻¹' V s) i
j0 : J
hj0 : ∀ {X : J}, X ∈ Finset.image j G → Nonempty (j0 ⟶ X)
f : (s : ↑S) → s ∈ G → (j0 ⟶ j s) := fun s hs => ⋯.some
W : ↑S → Set ↑(F.obj j0).toCompHaus.toTop := fun s => if hs : s ∈ G then ⇑(F.map (f s hs)) ⁻¹' V s else Set.univ
x : ↑C.pt.toCompHaus.toTop
hx : x ∈ U
⊢ ∃ i, ∃ (_ : i ∈ G), x ∈ ⇑(C.π.app j0) ⁻¹' if hs : i ∈ G then ⇑(F.map (f i hs)) ⁻¹' V i else Set.univ

tactic: obtain ⟨_, ⟨s, rfl⟩, _, ⟨hs, rfl⟩, hh⟩ := hG hx
state_before: case refine_3.intro.intro.intro.intro.refine_2.h.mp
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
hUo : ∀ (i : ↑S), IsOpen ((fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i)
hsU : U ⊆ ⋃ i, (fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i
G : Finset ↑S
hG : U ⊆ ⋃ i ∈ G, (fun s => ⇑(C.π.app (j s)) ⁻¹' V s) i
j0 : J
hj0 : ∀ {X : J}, X ∈ Finset.image j G → Nonempty (j0 ⟶ X)
f : (s : ↑S) → s ∈ G → (j0 ⟶ j s) := fun s hs => ⋯.some
W : ↑S → Set ↑(F.obj j0).toCompHaus.toTop := fun s => if hs : s ∈ G then ⇑(F.map (f s hs)) ⁻¹' V s else Set.univ
x : ↑C.pt.toCompHaus.toTop
hx : x ∈ U
⊢ ∃ i, ∃ (_ : i ∈ G), x ∈ ⇑(C.π.app j0) ⁻¹' if hs : i ∈ G then ⇑(F.map (f i hs)) ⁻¹' V i else Set.univ
state_after: case refine_3.intro.intro.intro.intro.refine_2.h.mp.intro.intro.intro.intro.intro.intro
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
hUo : ∀ (i : ↑S), IsOpen ((fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i)
hsU : U ⊆ ⋃ i, (fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i
G : Finset ↑S
hG : U ⊆ ⋃ i ∈ G, (fun s => ⇑(C.π.app (j s)) ⁻¹' V s) i
j0 : J
hj0 : ∀ {X : J}, X ∈ Finset.image j G → Nonempty (j0 ⟶ X)
f : (s : ↑S) → s ∈ G → (j0 ⟶ j s) := fun s hs => ⋯.some
W : ↑S → Set ↑(F.obj j0).toCompHaus.toTop := fun s => if hs : s ∈ G then ⇑(F.map (f s hs)) ⁻¹' V s else Set.univ
x : ↑C.pt.toCompHaus.toTop
hx : x ∈ U
s : ↑S
hs : s ∈ G
hh : x ∈ (fun h => (fun s => ⇑(C.π.app (j s)) ⁻¹' V s) s) hs
⊢ ∃ i, ∃ (_ : i ∈ G), x ∈ ⇑(C.π.app j0) ⁻¹' if hs : i ∈ G then ⇑(F.map (f i hs)) ⁻¹' V i else Set.univ

tactic: refine ⟨s, hs, ?_⟩
state_before: case refine_3.intro.intro.intro.intro.refine_2.h.mp.intro.intro.intro.intro.intro.intro
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
hUo : ∀ (i : ↑S), IsOpen ((fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i)
hsU : U ⊆ ⋃ i, (fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i
G : Finset ↑S
hG : U ⊆ ⋃ i ∈ G, (fun s => ⇑(C.π.app (j s)) ⁻¹' V s) i
j0 : J
hj0 : ∀ {X : J}, X ∈ Finset.image j G → Nonempty (j0 ⟶ X)
f : (s : ↑S) → s ∈ G → (j0 ⟶ j s) := fun s hs => ⋯.some
W : ↑S → Set ↑(F.obj j0).toCompHaus.toTop := fun s => if hs : s ∈ G then ⇑(F.map (f s hs)) ⁻¹' V s else Set.univ
x : ↑C.pt.toCompHaus.toTop
hx : x ∈ U
s : ↑S
hs : s ∈ G
hh : x ∈ (fun h => (fun s => ⇑(C.π.app (j s)) ⁻¹' V s) s) hs
⊢ ∃ i, ∃ (_ : i ∈ G), x ∈ ⇑(C.π.app j0) ⁻¹' if hs : i ∈ G then ⇑(F.map (f i hs)) ⁻¹' V i else Set.univ
state_after: case refine_3.intro.intro.intro.intro.refine_2.h.mp.intro.intro.intro.intro.intro.intro
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
hUo : ∀ (i : ↑S), IsOpen ((fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i)
hsU : U ⊆ ⋃ i, (fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i
G : Finset ↑S
hG : U ⊆ ⋃ i ∈ G, (fun s => ⇑(C.π.app (j s)) ⁻¹' V s) i
j0 : J
hj0 : ∀ {X : J}, X ∈ Finset.image j G → Nonempty (j0 ⟶ X)
f : (s : ↑S) → s ∈ G → (j0 ⟶ j s) := fun s hs => ⋯.some
W : ↑S → Set ↑(F.obj j0).toCompHaus.toTop := fun s => if hs : s ∈ G then ⇑(F.map (f s hs)) ⁻¹' V s else Set.univ
x : ↑C.pt.toCompHaus.toTop
hx : x ∈ U
s : ↑S
hs : s ∈ G
hh : x ∈ (fun h => (fun s => ⇑(C.π.app (j s)) ⁻¹' V s) s) hs
⊢ x ∈ ⇑(C.π.app j0) ⁻¹' if hs : s ∈ G then ⇑(F.map (f s hs)) ⁻¹' V s else Set.univ

tactic: rwa [dif_pos hs, ← Set.preimage_comp, ← Profinite.coe_comp, ← Functor.map_comp, C.w]
state_before: case refine_3.intro.intro.intro.intro.refine_2.h.mp.intro.intro.intro.intro.intro.intro
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
hUo : ∀ (i : ↑S), IsOpen ((fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i)
hsU : U ⊆ ⋃ i, (fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i
G : Finset ↑S
hG : U ⊆ ⋃ i ∈ G, (fun s => ⇑(C.π.app (j s)) ⁻¹' V s) i
j0 : J
hj0 : ∀ {X : J}, X ∈ Finset.image j G → Nonempty (j0 ⟶ X)
f : (s : ↑S) → s ∈ G → (j0 ⟶ j s) := fun s hs => ⋯.some
W : ↑S → Set ↑(F.obj j0).toCompHaus.toTop := fun s => if hs : s ∈ G then ⇑(F.map (f s hs)) ⁻¹' V s else Set.univ
x : ↑C.pt.toCompHaus.toTop
hx : x ∈ U
s : ↑S
hs : s ∈ G
hh : x ∈ (fun h => (fun s => ⇑(C.π.app (j s)) ⁻¹' V s) s) hs
⊢ x ∈ ⇑(C.π.app j0) ⁻¹' if hs : s ∈ G then ⇑(F.map (f s hs)) ⁻¹' V s else Set.univ
state_after: no goals

tactic: intro hx
state_before: case refine_3.intro.intro.intro.intro.refine_2.h.mpr
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
hUo : ∀ (i : ↑S), IsOpen ((fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i)
hsU : U ⊆ ⋃ i, (fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i
G : Finset ↑S
hG : U ⊆ ⋃ i ∈ G, (fun s => ⇑(C.π.app (j s)) ⁻¹' V s) i
j0 : J
hj0 : ∀ {X : J}, X ∈ Finset.image j G → Nonempty (j0 ⟶ X)
f : (s : ↑S) → s ∈ G → (j0 ⟶ j s) := fun s hs => ⋯.some
W : ↑S → Set ↑(F.obj j0).toCompHaus.toTop := fun s => if hs : s ∈ G then ⇑(F.map (f s hs)) ⁻¹' V s else Set.univ
x : ↑C.pt.toCompHaus.toTop
⊢ x ∈ ⇑(C.π.app j0) ⁻¹' ⋃ s ∈ G, W s → x ∈ U
state_after: case refine_3.intro.intro.intro.intro.refine_2.h.mpr
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
hUo : ∀ (i : ↑S), IsOpen ((fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i)
hsU : U ⊆ ⋃ i, (fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i
G : Finset ↑S
hG : U ⊆ ⋃ i ∈ G, (fun s => ⇑(C.π.app (j s)) ⁻¹' V s) i
j0 : J
hj0 : ∀ {X : J}, X ∈ Finset.image j G → Nonempty (j0 ⟶ X)
f : (s : ↑S) → s ∈ G → (j0 ⟶ j s) := fun s hs => ⋯.some
W : ↑S → Set ↑(F.obj j0).toCompHaus.toTop := fun s => if hs : s ∈ G then ⇑(F.map (f s hs)) ⁻¹' V s else Set.univ
x : ↑C.pt.toCompHaus.toTop
hx : x ∈ ⇑(C.π.app j0) ⁻¹' ⋃ s ∈ G, W s
⊢ x ∈ U

tactic: simp_rw [W, Set.preimage_iUnion, Set.mem_iUnion] at hx
state_before: case refine_3.intro.intro.intro.intro.refine_2.h.mpr
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
hUo : ∀ (i : ↑S), IsOpen ((fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i)
hsU : U ⊆ ⋃ i, (fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i
G : Finset ↑S
hG : U ⊆ ⋃ i ∈ G, (fun s => ⇑(C.π.app (j s)) ⁻¹' V s) i
j0 : J
hj0 : ∀ {X : J}, X ∈ Finset.image j G → Nonempty (j0 ⟶ X)
f : (s : ↑S) → s ∈ G → (j0 ⟶ j s) := fun s hs => ⋯.some
W : ↑S → Set ↑(F.obj j0).toCompHaus.toTop := fun s => if hs : s ∈ G then ⇑(F.map (f s hs)) ⁻¹' V s else Set.univ
x : ↑C.pt.toCompHaus.toTop
hx : x ∈ ⇑(C.π.app j0) ⁻¹' ⋃ s ∈ G, W s
⊢ x ∈ U
state_after: case refine_3.intro.intro.intro.intro.refine_2.h.mpr
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
hUo : ∀ (i : ↑S), IsOpen ((fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i)
hsU : U ⊆ ⋃ i, (fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i
G : Finset ↑S
hG : U ⊆ ⋃ i ∈ G, (fun s => ⇑(C.π.app (j s)) ⁻¹' V s) i
j0 : J
hj0 : ∀ {X : J}, X ∈ Finset.image j G → Nonempty (j0 ⟶ X)
f : (s : ↑S) → s ∈ G → (j0 ⟶ j s) := fun s hs => ⋯.some
W : ↑S → Set ↑(F.obj j0).toCompHaus.toTop := fun s => if hs : s ∈ G then ⇑(F.map (f s hs)) ⁻¹' V s else Set.univ
x : ↑C.pt.toCompHaus.toTop
hx : ∃ i, ∃ (_ : i ∈ G), x ∈ ⇑(C.π.app j0) ⁻¹' if hs : i ∈ G then ⇑(F.map (f i hs)) ⁻¹' V i else Set.univ
⊢ x ∈ U

tactic: obtain ⟨s, hs, hx⟩ := hx
state_before: case refine_3.intro.intro.intro.intro.refine_2.h.mpr
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
hUo : ∀ (i : ↑S), IsOpen ((fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i)
hsU : U ⊆ ⋃ i, (fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i
G : Finset ↑S
hG : U ⊆ ⋃ i ∈ G, (fun s => ⇑(C.π.app (j s)) ⁻¹' V s) i
j0 : J
hj0 : ∀ {X : J}, X ∈ Finset.image j G → Nonempty (j0 ⟶ X)
f : (s : ↑S) → s ∈ G → (j0 ⟶ j s) := fun s hs => ⋯.some
W : ↑S → Set ↑(F.obj j0).toCompHaus.toTop := fun s => if hs : s ∈ G then ⇑(F.map (f s hs)) ⁻¹' V s else Set.univ
x : ↑C.pt.toCompHaus.toTop
hx : ∃ i, ∃ (_ : i ∈ G), x ∈ ⇑(C.π.app j0) ⁻¹' if hs : i ∈ G then ⇑(F.map (f i hs)) ⁻¹' V i else Set.univ
⊢ x ∈ U
state_after: case refine_3.intro.intro.intro.intro.refine_2.h.mpr.intro.intro
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
hUo : ∀ (i : ↑S), IsOpen ((fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i)
hsU : U ⊆ ⋃ i, (fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i
G : Finset ↑S
hG : U ⊆ ⋃ i ∈ G, (fun s => ⇑(C.π.app (j s)) ⁻¹' V s) i
j0 : J
hj0 : ∀ {X : J}, X ∈ Finset.image j G → Nonempty (j0 ⟶ X)
f : (s : ↑S) → s ∈ G → (j0 ⟶ j s) := fun s hs => ⋯.some
W : ↑S → Set ↑(F.obj j0).toCompHaus.toTop := fun s => if hs : s ∈ G then ⇑(F.map (f s hs)) ⁻¹' V s else Set.univ
x : ↑C.pt.toCompHaus.toTop
s : ↑S
hs : s ∈ G
hx : x ∈ ⇑(C.π.app j0) ⁻¹' if hs : s ∈ G then ⇑(F.map (f s hs)) ⁻¹' V s else Set.univ
⊢ x ∈ U

tactic: rw [h]
state_before: case refine_3.intro.intro.intro.intro.refine_2.h.mpr.intro.intro
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
hUo : ∀ (i : ↑S), IsOpen ((fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i)
hsU : U ⊆ ⋃ i, (fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i
G : Finset ↑S
hG : U ⊆ ⋃ i ∈ G, (fun s => ⇑(C.π.app (j s)) ⁻¹' V s) i
j0 : J
hj0 : ∀ {X : J}, X ∈ Finset.image j G → Nonempty (j0 ⟶ X)
f : (s : ↑S) → s ∈ G → (j0 ⟶ j s) := fun s hs => ⋯.some
W : ↑S → Set ↑(F.obj j0).toCompHaus.toTop := fun s => if hs : s ∈ G then ⇑(F.map (f s hs)) ⁻¹' V s else Set.univ
x : ↑C.pt.toCompHaus.toTop
s : ↑S
hs : s ∈ G
hx : x ∈ ⇑(C.π.app j0) ⁻¹' if hs : s ∈ G then ⇑(F.map (f s hs)) ⁻¹' V s else Set.univ
⊢ x ∈ U
state_after: case refine_3.intro.intro.intro.intro.refine_2.h.mpr.intro.intro
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
hUo : ∀ (i : ↑S), IsOpen ((fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i)
hsU : U ⊆ ⋃ i, (fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i
G : Finset ↑S
hG : U ⊆ ⋃ i ∈ G, (fun s => ⇑(C.π.app (j s)) ⁻¹' V s) i
j0 : J
hj0 : ∀ {X : J}, X ∈ Finset.image j G → Nonempty (j0 ⟶ X)
f : (s : ↑S) → s ∈ G → (j0 ⟶ j s) := fun s hs => ⋯.some
W : ↑S → Set ↑(F.obj j0).toCompHaus.toTop := fun s => if hs : s ∈ G then ⇑(F.map (f s hs)) ⁻¹' V s else Set.univ
x : ↑C.pt.toCompHaus.toTop
s : ↑S
hs : s ∈ G
hx : x ∈ ⇑(C.π.app j0) ⁻¹' if hs : s ∈ G then ⇑(F.map (f s hs)) ⁻¹' V s else Set.univ
⊢ x ∈ ⋃₀ S

tactic: refine ⟨s.1, s.2, ?_⟩
state_before: case refine_3.intro.intro.intro.intro.refine_2.h.mpr.intro.intro
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
hUo : ∀ (i : ↑S), IsOpen ((fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i)
hsU : U ⊆ ⋃ i, (fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i
G : Finset ↑S
hG : U ⊆ ⋃ i ∈ G, (fun s => ⇑(C.π.app (j s)) ⁻¹' V s) i
j0 : J
hj0 : ∀ {X : J}, X ∈ Finset.image j G → Nonempty (j0 ⟶ X)
f : (s : ↑S) → s ∈ G → (j0 ⟶ j s) := fun s hs => ⋯.some
W : ↑S → Set ↑(F.obj j0).toCompHaus.toTop := fun s => if hs : s ∈ G then ⇑(F.map (f s hs)) ⁻¹' V s else Set.univ
x : ↑C.pt.toCompHaus.toTop
s : ↑S
hs : s ∈ G
hx : x ∈ ⇑(C.π.app j0) ⁻¹' if hs : s ∈ G then ⇑(F.map (f s hs)) ⁻¹' V s else Set.univ
⊢ x ∈ ⋃₀ S
state_after: case refine_3.intro.intro.intro.intro.refine_2.h.mpr.intro.intro
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
hUo : ∀ (i : ↑S), IsOpen ((fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i)
hsU : U ⊆ ⋃ i, (fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i
G : Finset ↑S
hG : U ⊆ ⋃ i ∈ G, (fun s => ⇑(C.π.app (j s)) ⁻¹' V s) i
j0 : J
hj0 : ∀ {X : J}, X ∈ Finset.image j G → Nonempty (j0 ⟶ X)
f : (s : ↑S) → s ∈ G → (j0 ⟶ j s) := fun s hs => ⋯.some
W : ↑S → Set ↑(F.obj j0).toCompHaus.toTop := fun s => if hs : s ∈ G then ⇑(F.map (f s hs)) ⁻¹' V s else Set.univ
x : ↑C.pt.toCompHaus.toTop
s : ↑S
hs : s ∈ G
hx : x ∈ ⇑(C.π.app j0) ⁻¹' if hs : s ∈ G then ⇑(F.map (f s hs)) ⁻¹' V s else Set.univ
⊢ x ∈ ↑s

tactic: rw [(hV s).2]
state_before: case refine_3.intro.intro.intro.intro.refine_2.h.mpr.intro.intro
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
hUo : ∀ (i : ↑S), IsOpen ((fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i)
hsU : U ⊆ ⋃ i, (fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i
G : Finset ↑S
hG : U ⊆ ⋃ i ∈ G, (fun s => ⇑(C.π.app (j s)) ⁻¹' V s) i
j0 : J
hj0 : ∀ {X : J}, X ∈ Finset.image j G → Nonempty (j0 ⟶ X)
f : (s : ↑S) → s ∈ G → (j0 ⟶ j s) := fun s hs => ⋯.some
W : ↑S → Set ↑(F.obj j0).toCompHaus.toTop := fun s => if hs : s ∈ G then ⇑(F.map (f s hs)) ⁻¹' V s else Set.univ
x : ↑C.pt.toCompHaus.toTop
s : ↑S
hs : s ∈ G
hx : x ∈ ⇑(C.π.app j0) ⁻¹' if hs : s ∈ G then ⇑(F.map (f s hs)) ⁻¹' V s else Set.univ
⊢ x ∈ ↑s
state_after: case refine_3.intro.intro.intro.intro.refine_2.h.mpr.intro.intro
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
hUo : ∀ (i : ↑S), IsOpen ((fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i)
hsU : U ⊆ ⋃ i, (fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i
G : Finset ↑S
hG : U ⊆ ⋃ i ∈ G, (fun s => ⇑(C.π.app (j s)) ⁻¹' V s) i
j0 : J
hj0 : ∀ {X : J}, X ∈ Finset.image j G → Nonempty (j0 ⟶ X)
f : (s : ↑S) → s ∈ G → (j0 ⟶ j s) := fun s hs => ⋯.some
W : ↑S → Set ↑(F.obj j0).toCompHaus.toTop := fun s => if hs : s ∈ G then ⇑(F.map (f s hs)) ⁻¹' V s else Set.univ
x : ↑C.pt.toCompHaus.toTop
s : ↑S
hs : s ∈ G
hx : x ∈ ⇑(C.π.app j0) ⁻¹' if hs : s ∈ G then ⇑(F.map (f s hs)) ⁻¹' V s else Set.univ
⊢ x ∈ ⇑(C.π.app (j s)) ⁻¹' V s

tactic: rwa [dif_pos hs, ← Set.preimage_comp, ← Profinite.coe_comp, ← Functor.map_comp, C.w] at hx
state_before: case refine_3.intro.intro.intro.intro.refine_2.h.mpr.intro.intro
J : Type v
inst✝¹ : SmallCategory J
inst✝ : IsCofiltered J
F : J ⥤ Profinite
C : Cone F
U : Set ↑C.pt.toCompHaus.toTop
hC : IsLimit C
hU : IsClopen U
S : Set (Set ↑(toTopCat.mapCone C).pt)
hS : S ⊆ {U | ∃ j, ∃ V ∈ (fun j => {W | IsClopen W}) j, U = ⇑((toTopCat.mapCone C).π.app j) ⁻¹' V}
h : U = ⋃₀ S
j : ↑S → J := fun s => Exists.choose ⋯
V : (s : ↑S) → Set ↑(F.obj (j s)).toCompHaus.toTop := fun s => ⋯.choose
hV : ∀ (s : ↑S), IsClopen (V s) ∧ ↑s = ⇑(C.π.app (j s)) ⁻¹' V s
hUo : ∀ (i : ↑S), IsOpen ((fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i)
hsU : U ⊆ ⋃ i, (fun s => (forget Profinite).map (C.π.app (j s)) ⁻¹' V s) i
G : Finset ↑S
hG : U ⊆ ⋃ i ∈ G, (fun s => ⇑(C.π.app (j s)) ⁻¹' V s) i
j0 : J
hj0 : ∀ {X : J}, X ∈ Finset.image j G → Nonempty (j0 ⟶ X)
f : (s : ↑S) → s ∈ G → (j0 ⟶ j s) := fun s hs => ⋯.some
W : ↑S → Set ↑(F.obj j0).toCompHaus.toTop := fun s => if hs : s ∈ G then ⇑(F.map (f s hs)) ⁻¹' V s else Set.univ
x : ↑C.pt.toCompHaus.toTop
s : ↑S
hs : s ∈ G
hx : x ∈ ⇑(C.π.app j0) ⁻¹' if hs : s ∈ G then ⇑(F.map (f s hs)) ⁻¹' V s else Set.univ
⊢ x ∈ ⇑(C.π.app (j s)) ⁻¹' V s
state_after: no goals