l3lab/ntp-mathlib huggingface dataset:
protected theorem IsOpenMap.prod {f : α → β} {g : γ → δ} (hf : IsOpenMap f) (hg : IsOpenMap g) :
    IsOpenMap fun p : α × γ => (f p.1, g p.2) := by
  

Proof state:
α : Type u
β : Type v
γ : Type u_1
δ : Type u_2
ε : Type u_3
ζ : Type u_4
inst✝⁵ : TopologicalSpace α
inst✝⁴ : TopologicalSpace β
inst✝³ : TopologicalSpace γ
inst✝² : TopologicalSpace δ
inst✝¹ : TopologicalSpace ε
inst✝ : TopologicalSpace ζ
f : α → β
g : γ → δ
hf : IsOpenMap f
hg : IsOpenMap g
⊢ IsOpenMap fun p => (f p.1, g p.2)

Next tactic:
rw [isOpenMap_iff_nhds_le]
protected theorem IsOpenMap.prod {f : α → β} {g : γ → δ} (hf : IsOpenMap f) (hg : IsOpenMap g) :
    IsOpenMap fun p : α × γ => (f p.1, g p.2) := by
  rw [isOpenMap_iff_nhds_le]
  

Proof state:
α : Type u
β : Type v
γ : Type u_1
δ : Type u_2
ε : Type u_3
ζ : Type u_4
inst✝⁵ : TopologicalSpace α
inst✝⁴ : TopologicalSpace β
inst✝³ : TopologicalSpace γ
inst✝² : TopologicalSpace δ
inst✝¹ : TopologicalSpace ε
inst✝ : TopologicalSpace ζ
f : α → β
g : γ → δ
hf : IsOpenMap f
hg : IsOpenMap g
⊢ ∀ (a : α × γ), 𝓝 (f a.1, g a.2) ≤ map (fun p => (f p.1, g p.2)) (𝓝 a)

Next tactic:
rintro ⟨a, b⟩
protected theorem IsOpenMap.prod {f : α → β} {g : γ → δ} (hf : IsOpenMap f) (hg : IsOpenMap g) :
    IsOpenMap fun p : α × γ => (f p.1, g p.2) := by
  rw [isOpenMap_iff_nhds_le]
  rintro ⟨a, b⟩
  

Proof state:
case mk
α : Type u
β : Type v
γ : Type u_1
δ : Type u_2
ε : Type u_3
ζ : Type u_4
inst✝⁵ : TopologicalSpace α
inst✝⁴ : TopologicalSpace β
inst✝³ : TopologicalSpace γ
inst✝² : TopologicalSpace δ
inst✝¹ : TopologicalSpace ε
inst✝ : TopologicalSpace ζ
f : α → β
g : γ → δ
hf : IsOpenMap f
hg : IsOpenMap g
a : α
b : γ
⊢ 𝓝 (f (a, b).1, g (a, b).2) ≤ map (fun p => (f p.1, g p.2)) (𝓝 (a, b))

Next tactic:
rw [nhds_prod_eq, nhds_prod_eq, ← Filter.prod_map_map_eq]
protected theorem IsOpenMap.prod {f : α → β} {g : γ → δ} (hf : IsOpenMap f) (hg : IsOpenMap g) :
    IsOpenMap fun p : α × γ => (f p.1, g p.2) := by
  rw [isOpenMap_iff_nhds_le]
  rintro ⟨a, b⟩
  rw [nhds_prod_eq, nhds_prod_eq, ← Filter.prod_map_map_eq]
  

Proof state:
case mk
α : Type u
β : Type v
γ : Type u_1
δ : Type u_2
ε : Type u_3
ζ : Type u_4
inst✝⁵ : TopologicalSpace α
inst✝⁴ : TopologicalSpace β
inst✝³ : TopologicalSpace γ
inst✝² : TopologicalSpace δ
inst✝¹ : TopologicalSpace ε
inst✝ : TopologicalSpace ζ
f : α → β
g : γ → δ
hf : IsOpenMap f
hg : IsOpenMap g
a : α
b : γ
⊢ 𝓝 (f (a, b).1) ×ˢ 𝓝 (g (a, b).2) ≤ map f (𝓝 a) ×ˢ map g (𝓝 b)

Next tactic:
exact Filter.prod_mono (hf.nhds_le a) (hg.nhds_le b)
theorem isClosed_sum_iff {s : Set (α ⊕ β)} :
    IsClosed s ↔ IsClosed (inl ⁻¹' s) ∧ IsClosed (inr ⁻¹' s) := by
  

Proof state:
α : Type u
β : Type v
γ : Type u_1
δ : Type u_2
ε : Type u_3
ζ : Type u_4
inst✝³ : TopologicalSpace α
inst✝² : TopologicalSpace β
inst✝¹ : TopologicalSpace γ
inst✝ : TopologicalSpace δ
s : Set (α ⊕ β)
⊢ IsClosed s ↔ IsClosed (inl ⁻¹' s) ∧ IsClosed (inr ⁻¹' s)

Next tactic:
simp only [← isOpen_compl_iff, isOpen_sum_iff, preimage_compl]
theorem isOpenMap_inl : IsOpenMap (@inl α β) := fun u hu => by
  

Proof state:
α : Type u
β : Type v
γ : Type u_1
δ : Type u_2
ε : Type u_3
ζ : Type u_4
inst✝³ : TopologicalSpace α
inst✝² : TopologicalSpace β
inst✝¹ : TopologicalSpace γ
inst✝ : TopologicalSpace δ
u : Set α
hu : IsOpen u
⊢ IsOpen (inl '' u)

Next tactic:
simpa [isOpen_sum_iff, preimage_image_eq u Sum.inl_injective]
theorem isOpenMap_inr : IsOpenMap (@inr α β) := fun u hu => by
  

Proof state:
α : Type u
β : Type v
γ : Type u_1
δ : Type u_2
ε : Type u_3
ζ : Type u_4
inst✝³ : TopologicalSpace α
inst✝² : TopologicalSpace β
inst✝¹ : TopologicalSpace γ
inst✝ : TopologicalSpace δ
u : Set β
hu : IsOpen u
⊢ IsOpen (inr '' u)

Next tactic:
simpa [isOpen_sum_iff, preimage_image_eq u Sum.inr_injective]
theorem isClosed_range_inl : IsClosed (range (inl : α → Sum α β)) := by
  

Proof state:
α : Type u
β : Type v
γ : Type u_1
δ : Type u_2
ε : Type u_3
ζ : Type u_4
inst✝³ : TopologicalSpace α
inst✝² : TopologicalSpace β
inst✝¹ : TopologicalSpace γ
inst✝ : TopologicalSpace δ
⊢ IsClosed (range inl)

Next tactic:
rw [← isOpen_compl_iff, compl_range_inl]
theorem isClosed_range_inl : IsClosed (range (inl : α → Sum α β)) := by
  rw [← isOpen_compl_iff, compl_range_inl]
  

Proof state:
α : Type u
β : Type v
γ : Type u_1
δ : Type u_2
ε : Type u_3
ζ : Type u_4
inst✝³ : TopologicalSpace α
inst✝² : TopologicalSpace β
inst✝¹ : TopologicalSpace γ
inst✝ : TopologicalSpace δ
⊢ IsOpen (range inr)

Next tactic:
exact isOpen_range_inr
theorem isClosed_range_inr : IsClosed (range (inr : β → Sum α β)) := by
  

Proof state:
α : Type u
β : Type v
γ : Type u_1
δ : Type u_2
ε : Type u_3
ζ : Type u_4
inst✝³ : TopologicalSpace α
inst✝² : TopologicalSpace β
inst✝¹ : TopologicalSpace γ
inst✝ : TopologicalSpace δ
⊢ IsClosed (range inr)

Next tactic:
rw [← isOpen_compl_iff, compl_range_inr]
theorem isClosed_range_inr : IsClosed (range (inr : β → Sum α β)) := by
  rw [← isOpen_compl_iff, compl_range_inr]
  

Proof state:
α : Type u
β : Type v
γ : Type u_1
δ : Type u_2
ε : Type u_3
ζ : Type u_4
inst✝³ : TopologicalSpace α
inst✝² : TopologicalSpace β
inst✝¹ : TopologicalSpace γ
inst✝ : TopologicalSpace δ
⊢ IsOpen (range inl)

Next tactic:
exact isOpen_range_inl
theorem isOpenMap_sum {f : Sum α β → γ} :
    IsOpenMap f ↔ (IsOpenMap fun a => f (inl a)) ∧ IsOpenMap fun b => f (inr b) := by
  

Proof state:
α : Type u
β : Type v
γ : Type u_1
δ : Type u_2
ε : Type u_3
ζ : Type u_4
inst✝³ : TopologicalSpace α
inst✝² : TopologicalSpace β
inst✝¹ : TopologicalSpace γ
inst✝ : TopologicalSpace δ
f : α ⊕ β → γ
⊢ IsOpenMap f ↔ (IsOpenMap fun a => f (inl a)) ∧ IsOpenMap fun b => f (inr b)

Next tactic:
simp only [isOpenMap_iff_nhds_le, Sum.forall, nhds_inl, nhds_inr, Filter.map_map, comp]
@[simp]
theorem isOpenMap_sum_elim {f : α → γ} {g : β → γ} :
    IsOpenMap (Sum.elim f g) ↔ IsOpenMap f ∧ IsOpenMap g := by
  

Proof state:
α : Type u
β : Type v
γ : Type u_1
δ : Type u_2
ε : Type u_3
ζ : Type u_4
inst✝³ : TopologicalSpace α
inst✝² : TopologicalSpace β
inst✝¹ : TopologicalSpace γ
inst✝ : TopologicalSpace δ
f : α → γ
g : β → γ
⊢ IsOpenMap (Sum.elim f g) ↔ IsOpenMap f ∧ IsOpenMap g

Next tactic:
simp only [isOpenMap_sum, elim_inl, elim_inr]
theorem closedEmbedding_subtype_val (h : IsClosed { a | p a }) :
    ClosedEmbedding ((↑) : Subtype p → α) :=
  ⟨embedding_subtype_val, by 

Proof state:
α : Type u
β : Type v
γ : Type u_1
δ : Type u_2
ε : Type u_3
ζ : Type u_4
inst✝² : TopologicalSpace α
inst✝¹ : TopologicalSpace β
inst✝ : TopologicalSpace γ
p : α → Prop
h : IsClosed {a | p a}
⊢ IsClosed (range Subtype.val)

Next tactic:
rwa [Subtype.range_coe_subtype]
lemma IsClosedMap.restrictPreimage {f : α → β} (hcl : IsClosedMap f) (T : Set β) :
    IsClosedMap (T.restrictPreimage f) := by
  

Proof state:
α : Type u
β : Type v
γ : Type u_1
δ : Type u_2
ε : Type u_3
ζ : Type u_4
inst✝² : TopologicalSpace α
inst✝¹ : TopologicalSpace β
inst✝ : TopologicalSpace γ
p : α → Prop
f : α → β
hcl : IsClosedMap f
T : Set β
⊢ IsClosedMap (Set.restrictPreimage T f)

Next tactic:
rw [isClosedMap_iff_clusterPt] at hcl ⊢
lemma IsClosedMap.restrictPreimage {f : α → β} (hcl : IsClosedMap f) (T : Set β) :
    IsClosedMap (T.restrictPreimage f) := by
  rw [isClosedMap_iff_clusterPt] at hcl ⊢
  

Proof state:
α : Type u
β : Type v
γ : Type u_1
δ : Type u_2
ε : Type u_3
ζ : Type u_4
inst✝² : TopologicalSpace α
inst✝¹ : TopologicalSpace β
inst✝ : TopologicalSpace γ
p : α → Prop
f : α → β
hcl : ∀ (s : Set α) (y : β), MapClusterPt y (𝓟 s) f → ∃ x, f x = y ∧ ClusterPt x (𝓟 s)
T : Set β
⊢ ∀ (s : Set ↑(f ⁻¹' T)) (y : ↑T),
    MapClusterPt y (𝓟 s) (Set.restrictPreimage T f) → ∃ x, Set.restrictPreimage T f x = y ∧ ClusterPt x (𝓟 s)

Next tactic:
intro A ⟨y, hyT⟩ hy
lemma IsClosedMap.restrictPreimage {f : α → β} (hcl : IsClosedMap f) (T : Set β) :
    IsClosedMap (T.restrictPreimage f) := by
  rw [isClosedMap_iff_clusterPt] at hcl ⊢
  intro A ⟨y, hyT⟩ hy
  

Proof state:
α : Type u
β : Type v
γ : Type u_1
δ : Type u_2
ε : Type u_3
ζ : Type u_4
inst✝² : TopologicalSpace α
inst✝¹ : TopologicalSpace β
inst✝ : TopologicalSpace γ
p : α → Prop
f : α → β
hcl : ∀ (s : Set α) (y : β), MapClusterPt y (𝓟 s) f → ∃ x, f x = y ∧ ClusterPt x (𝓟 s)
T : Set β
A : Set ↑(f ⁻¹' T)
y : β
hyT : y ∈ T
hy : MapClusterPt { val := y, property := hyT } (𝓟 A) (Set.restrictPreimage T f)
⊢ ∃ x, Set.restrictPreimage T f x = { val := y, property := hyT } ∧ ClusterPt x (𝓟 A)

Next tactic:
rw [Set.restrictPreimage, MapClusterPt, ← inducing_subtype_val.mapClusterPt_iff, MapClusterPt,
      map_map, MapsTo.restrict_commutes, ← map_map, ← MapClusterPt, map_principal] at hy
lemma IsClosedMap.restrictPreimage {f : α → β} (hcl : IsClosedMap f) (T : Set β) :
    IsClosedMap (T.restrictPreimage f) := by
  rw [isClosedMap_iff_clusterPt] at hcl ⊢
  intro A ⟨y, hyT⟩ hy
  rw [Set.restrictPreimage, MapClusterPt, ← inducing_subtype_val.mapClusterPt_iff, MapClusterPt,
      map_map, MapsTo.restrict_commutes, ← map_map, ← MapClusterPt, map_principal] at hy
  

Proof state:
α : Type u
β : Type v
γ : Type u_1
δ : Type u_2
ε : Type u_3
ζ : Type u_4
inst✝² : TopologicalSpace α
inst✝¹ : TopologicalSpace β
inst✝ : TopologicalSpace γ
p : α → Prop
f : α → β
hcl : ∀ (s : Set α) (y : β), MapClusterPt y (𝓟 s) f → ∃ x, f x = y ∧ ClusterPt x (𝓟 s)
T : Set β
A : Set ↑(f ⁻¹' T)
y : β
hyT : y ∈ T
hy : MapClusterPt (↑{ val := y, property := hyT }) (𝓟 (Subtype.val '' A)) f
⊢ ∃ x, Set.restrictPreimage T f x = { val := y, property := hyT } ∧ ClusterPt x (𝓟 A)

Next tactic:
rcases hcl _ y hy with ⟨x, hxy, hx⟩
lemma IsClosedMap.restrictPreimage {f : α → β} (hcl : IsClosedMap f) (T : Set β) :
    IsClosedMap (T.restrictPreimage f) := by
  rw [isClosedMap_iff_clusterPt] at hcl ⊢
  intro A ⟨y, hyT⟩ hy
  rw [Set.restrictPreimage, MapClusterPt, ← inducing_subtype_val.mapClusterPt_iff, MapClusterPt,
      map_map, MapsTo.restrict_commutes, ← map_map, ← MapClusterPt, map_principal] at hy
  rcases hcl _ y hy with ⟨x, hxy, hx⟩
  

Proof state:
case intro.intro
α : Type u
β : Type v
γ : Type u_1
δ : Type u_2
ε : Type u_3
ζ : Type u_4
inst✝² : TopologicalSpace α
inst✝¹ : TopologicalSpace β
inst✝ : TopologicalSpace γ
p : α → Prop
f : α → β
hcl : ∀ (s : Set α) (y : β), MapClusterPt y (𝓟 s) f → ∃ x, f x = y ∧ ClusterPt x (𝓟 s)
T : Set β
A : Set ↑(f ⁻¹' T)
y : β
hyT : y ∈ T
hy : MapClusterPt (↑{ val := y, property := hyT }) (𝓟 (Subtype.val '' A)) f
x : α
hxy : f x = y
hx : ClusterPt x (𝓟 (Subtype.val '' A))
⊢ ∃ x, Set.restrictPreimage T f x = { val := y, property := hyT } ∧ ClusterPt x (𝓟 A)

Next tactic:
have hxT : f x ∈ T := hxy ▸ hyT
lemma IsClosedMap.restrictPreimage {f : α → β} (hcl : IsClosedMap f) (T : Set β) :
    IsClosedMap (T.restrictPreimage f) := by
  rw [isClosedMap_iff_clusterPt] at hcl ⊢
  intro A ⟨y, hyT⟩ hy
  rw [Set.restrictPreimage, MapClusterPt, ← inducing_subtype_val.mapClusterPt_iff, MapClusterPt,
      map_map, MapsTo.restrict_commutes, ← map_map, ← MapClusterPt, map_principal] at hy
  rcases hcl _ y hy with ⟨x, hxy, hx⟩
  have hxT : f x ∈ T := hxy ▸ hyT
  

Proof state:
case intro.intro
α : Type u
β : Type v
γ : Type u_1
δ : Type u_2
ε : Type u_3
ζ : Type u_4
inst✝² : TopologicalSpace α
inst✝¹ : TopologicalSpace β
inst✝ : TopologicalSpace γ
p : α → Prop
f : α → β
hcl : ∀ (s : Set α) (y : β), MapClusterPt y (𝓟 s) f → ∃ x, f x = y ∧ ClusterPt x (𝓟 s)
T : Set β
A : Set ↑(f ⁻¹' T)
y : β
hyT : y ∈ T
hy : MapClusterPt (↑{ val := y, property := hyT }) (𝓟 (Subtype.val '' A)) f
x : α
hxy : f x = y
hx : ClusterPt x (𝓟 (Subtype.val '' A))
hxT : f x ∈ T
⊢ ∃ x, Set.restrictPreimage T f x = { val := y, property := hyT } ∧ ClusterPt x (𝓟 A)

Next tactic:
refine ⟨⟨x, hxT⟩, Subtype.ext hxy, ?_⟩
lemma IsClosedMap.restrictPreimage {f : α → β} (hcl : IsClosedMap f) (T : Set β) :
    IsClosedMap (T.restrictPreimage f) := by
  rw [isClosedMap_iff_clusterPt] at hcl ⊢
  intro A ⟨y, hyT⟩ hy
  rw [Set.restrictPreimage, MapClusterPt, ← inducing_subtype_val.mapClusterPt_iff, MapClusterPt,
      map_map, MapsTo.restrict_commutes, ← map_map, ← MapClusterPt, map_principal] at hy
  rcases hcl _ y hy with ⟨x, hxy, hx⟩
  have hxT : f x ∈ T := hxy ▸ hyT
  refine ⟨⟨x, hxT⟩, Subtype.ext hxy, ?_⟩
  

Proof state:
case intro.intro
α : Type u
β : Type v
γ : Type u_1
δ : Type u_2
ε : Type u_3
ζ : Type u_4
inst✝² : TopologicalSpace α
inst✝¹ : TopologicalSpace β
inst✝ : TopologicalSpace γ
p : α → Prop
f : α → β
hcl : ∀ (s : Set α) (y : β), MapClusterPt y (𝓟 s) f → ∃ x, f x = y ∧ ClusterPt x (𝓟 s)
T : Set β
A : Set ↑(f ⁻¹' T)
y : β
hyT : y ∈ T
hy : MapClusterPt (↑{ val := y, property := hyT }) (𝓟 (Subtype.val '' A)) f
x : α
hxy : f x = y
hx : ClusterPt x (𝓟 (Subtype.val '' A))
hxT : f x ∈ T
⊢ ClusterPt { val := x, property := hxT } (𝓟 A)

Next tactic:
rwa [← inducing_subtype_val.mapClusterPt_iff, MapClusterPt, map_principal]
theorem Subtype.dense_iff {s : Set α} {t : Set s} : Dense t ↔ s ⊆ closure ((↑) '' t) := by
  

Proof state:
α : Type u
β : Type v
γ : Type u_1
δ : Type u_2
ε : Type u_3
ζ : Type u_4
inst✝² : TopologicalSpace α
inst✝¹ : TopologicalSpace β
inst✝ : TopologicalSpace γ
p : α → Prop
s : Set α
t : Set ↑s
⊢ Dense t ↔ s ⊆ closure (val '' t)

Next tactic:
rw [inducing_subtype_val.dense_iff, SetCoe.forall]
theorem Subtype.dense_iff {s : Set α} {t : Set s} : Dense t ↔ s ⊆ closure ((↑) '' t) := by
  rw [inducing_subtype_val.dense_iff, SetCoe.forall]
  

Proof state:
α : Type u
β : Type v
γ : Type u_1
δ : Type u_2
ε : Type u_3
ζ : Type u_4
inst✝² : TopologicalSpace α
inst✝¹ : TopologicalSpace β
inst✝ : TopologicalSpace γ
p : α → Prop
s : Set α
t : Set ↑s
⊢ (∀ (x : α) (h : x ∈ s), ↑{ val := x, property := h } ∈ closure (val '' t)) ↔ s ⊆ closure (val '' t)

Next tactic:
rfl
theorem map_nhds_subtype_val {s : Set α} (a : s) : map ((↑) : s → α) (𝓝 a) = 𝓝[s] ↑a := by
  

Proof state:
α : Type u
β : Type v
γ : Type u_1
δ : Type u_2
ε : Type u_3
ζ : Type u_4
inst✝² : TopologicalSpace α
inst✝¹ : TopologicalSpace β
inst✝ : TopologicalSpace γ
p : α → Prop
s : Set α
a : ↑s
⊢ map Subtype.val (𝓝 a) = 𝓝[s] ↑a

Next tactic:
rw [inducing_subtype_val.map_nhds_eq, Subtype.range_val]
theorem map_nhds_subtype_coe_eq_nhds {a : α} (ha : p a) (h : ∀ᶠ x in 𝓝 a, p x) :
    map ((↑) : Subtype p → α) (𝓝 ⟨a, ha⟩) = 𝓝 a :=
  map_nhds_induced_of_mem <| by 

Proof state:
α : Type u
β : Type v
γ : Type u_1
δ : Type u_2
ε : Type u_3
ζ : Type u_4
inst✝² : TopologicalSpace α
inst✝¹ : TopologicalSpace β
inst✝ : TopologicalSpace γ
p : α → Prop
a : α
ha : p a
h : ∀ᶠ (x : α) in 𝓝 a, p x
⊢ range Subtype.val ∈ 𝓝 ↑{ val := a, property := ha }

Next tactic:
rw [Subtype.range_val]
theorem map_nhds_subtype_coe_eq_nhds {a : α} (ha : p a) (h : ∀ᶠ x in 𝓝 a, p x) :
    map ((↑) : Subtype p → α) (𝓝 ⟨a, ha⟩) = 𝓝 a :=
  map_nhds_induced_of_mem <| by rw [Subtype.range_val]; 

Proof state:
α : Type u
β : Type v
γ : Type u_1
δ : Type u_2
ε : Type u_3
ζ : Type u_4
inst✝² : TopologicalSpace α
inst✝¹ : TopologicalSpace β
inst✝ : TopologicalSpace γ
p : α → Prop
a : α
ha : p a
h : ∀ᶠ (x : α) in 𝓝 a, p x
⊢ (fun x => p x) ∈ 𝓝 ↑{ val := a, property := ha }

Next tactic:
exact h
theorem tendsto_subtype_rng {β : Type*} {p : α → Prop} {b : Filter β} {f : β → Subtype p} :
    ∀ {a : Subtype p}, Tendsto f b (𝓝 a) ↔ Tendsto (fun x => (f x : α)) b (𝓝 (a : α))
  | ⟨a, ha⟩ => by 

Proof state:
α : Type u
β✝ : Type v
γ : Type u_1
δ : Type u_2
ε : Type u_3
ζ : Type u_4
inst✝² : TopologicalSpace α
inst✝¹ : TopologicalSpace β✝
inst✝ : TopologicalSpace γ
p✝ : α → Prop
β : Type u_5
p : α → Prop
b : Filter β
f : β → Subtype p
a : α
ha : p a
⊢ Tendsto f b (𝓝 { val := a, property := ha }) ↔ Tendsto (fun x => ↑(f x)) b (𝓝 ↑{ val := a, property := ha })

Next tactic:
rw [nhds_subtype_eq_comap, tendsto_comap_iff]
theorem tendsto_subtype_rng {β : Type*} {p : α → Prop} {b : Filter β} {f : β → Subtype p} :
    ∀ {a : Subtype p}, Tendsto f b (𝓝 a) ↔ Tendsto (fun x => (f x : α)) b (𝓝 (a : α))
  | ⟨a, ha⟩ => by rw [nhds_subtype_eq_comap, tendsto_comap_iff]; 

Proof state:
α : Type u
β✝ : Type v
γ : Type u_1
δ : Type u_2
ε : Type u_3
ζ : Type u_4
inst✝² : TopologicalSpace α
inst✝¹ : TopologicalSpace β✝
inst✝ : TopologicalSpace γ
p✝ : α → Prop
β : Type u_5
p : α → Prop
b : Filter β
f : β → Subtype p
a : α
ha : p a
⊢ Tendsto (Subtype.val ∘ f) b (𝓝 a) ↔ Tendsto (fun x => ↑(f x)) b (𝓝 ↑{ val := a, property := ha })

Next tactic:
rfl
theorem continuous_pi_iff : Continuous f ↔ ∀ i, Continuous fun a => f a i := by
  

Proof state:
α : Type u
β : Type v
γ : Type u_1
δ : Type u_2
ε : Type u_3
ζ : Type u_4
ι : Type u_5
π : ι → Type u_6
κ : Type u_7
inst✝ : TopologicalSpace α
T : (i : ι) → TopologicalSpace (π i)
f : α → (i : ι) → π i
⊢ Continuous f ↔ ∀ (i : ι), Continuous fun a => f a i

Next tactic:
simp only [continuous_iInf_rng, continuous_induced_rng, comp]
theorem nhds_pi {a : ∀ i, π i} : 𝓝 a = pi fun i => 𝓝 (a i) := by
  

Proof state:
α : Type u
β : Type v
γ : Type u_1
δ : Type u_2
ε : Type u_3
ζ : Type u_4
ι : Type u_5
π : ι → Type u_6
κ : Type u_7
inst✝ : TopologicalSpace α
T : (i : ι) → TopologicalSpace (π i)
f : α → (i : ι) → π i
a : (i : ι) → π i
⊢ 𝓝 a = Filter.pi fun i => 𝓝 (a i)

Next tactic:
simp only [nhds_iInf, nhds_induced, Filter.pi]
theorem tendsto_pi_nhds {f : β → ∀ i, π i} {g : ∀ i, π i} {u : Filter β} :
    Tendsto f u (𝓝 g) ↔ ∀ x, Tendsto (fun i => f i x) u (𝓝 (g x)) := by
  

Proof state:
α : Type u
β : Type v
γ : Type u_1
δ : Type u_2
ε : Type u_3
ζ : Type u_4
ι : Type u_5
π : ι → Type u_6
κ : Type u_7
inst✝ : TopologicalSpace α
T : (i : ι) → TopologicalSpace (π i)
f✝ : α → (i : ι) → π i
f : β → (i : ι) → π i
g : (i : ι) → π i
u : Filter β
⊢ Tendsto f u (𝓝 g) ↔ ∀ (x : ι), Tendsto (fun i => f i x) u (𝓝 (g x))

Next tactic:
rw [nhds_pi, Filter.tendsto_pi]
lemma Pi.induced_precomp' {ι' : Type*} (φ : ι' → ι) :
    induced (fun (f : (∀ i, π i)) (j : ι') ↦ f (φ j)) Pi.topologicalSpace =
    ⨅ i', induced (eval (φ i')) (T (φ i')) := by
  

Proof state:
α : Type u
β : Type v
γ : Type u_1
δ : Type u_2
ε : Type u_3
ζ : Type u_4
ι : Type u_5
π : ι → Type u_6
κ : Type u_7
inst✝ : TopologicalSpace α
T : (i : ι) → TopologicalSpace (π i)
f : α → (i : ι) → π i
ι' : Type u_8
φ : ι' → ι
⊢ induced (fun f j => f (φ j)) topologicalSpace = ⨅ i', induced (eval (φ i')) (T (φ i'))

Next tactic:
simp [Pi.topologicalSpace, induced_iInf, induced_compose, comp]
lemma Pi.induced_restrict (S : Set ι) :
    induced (S.restrict) Pi.topologicalSpace =
    ⨅ i ∈ S, induced (eval i) (T i) := by
  

Proof state:
α : Type u
β : Type v
γ : Type u_1
δ : Type u_2
ε : Type u_3
ζ : Type u_4
ι : Type u_5
π : ι → Type u_6
κ : Type u_7
inst✝ : TopologicalSpace α
T : (i : ι) → TopologicalSpace (π i)
f : α → (i : ι) → π i
S : Set ι
⊢ induced (restrict S) topologicalSpace = ⨅ i ∈ S, induced (eval i) (T i)

Next tactic:
simp (config := { unfoldPartialApp := true }) [← iInf_subtype'', ← induced_precomp' ((↑) : S → ι),
    Set.restrict]
theorem Filter.Tendsto.update [DecidableEq ι] {l : Filter β} {f : β → ∀ i, π i} {x : ∀ i, π i}
    (hf : Tendsto f l (𝓝 x)) (i : ι) {g : β → π i} {xi : π i} (hg : Tendsto g l (𝓝 xi)) :
    Tendsto (fun a => update (f a) i (g a)) l (𝓝 <| update x i xi) :=
  tendsto_pi_nhds.2 fun j => by 

Proof state:
α : Type u
β : Type v
γ : Type u_1
δ : Type u_2
ε : Type u_3
ζ : Type u_4
ι : Type u_5
π : ι → Type u_6
κ : Type u_7
inst✝¹ : TopologicalSpace α
T : (i : ι) → TopologicalSpace (π i)
f✝ : α → (i : ι) → π i
inst✝ : DecidableEq ι
l : Filter β
f : β → (i : ι) → π i
x : (i : ι) → π i
hf : Tendsto f l (𝓝 x)
i : ι
g : β → π i
xi : π i
hg : Tendsto g l (𝓝 xi)
j : ι
⊢ Tendsto (fun i_1 => Function.update (f i_1) i (g i_1) j) l (𝓝 (Function.update x i xi j))

Next tactic:
rcases eq_or_ne j i with (rfl | hj)
theorem Filter.Tendsto.update [DecidableEq ι] {l : Filter β} {f : β → ∀ i, π i} {x : ∀ i, π i}
    (hf : Tendsto f l (𝓝 x)) (i : ι) {g : β → π i} {xi : π i} (hg : Tendsto g l (𝓝 xi)) :
    Tendsto (fun a => update (f a) i (g a)) l (𝓝 <| update x i xi) :=
  tendsto_pi_nhds.2 fun j => by rcases eq_or_ne j i with (rfl | hj) <;> 

Proof state:
case inl
α : Type u
β : Type v
γ : Type u_1
δ : Type u_2
ε : Type u_3
ζ : Type u_4
ι : Type u_5
π : ι → Type u_6
κ : Type u_7
inst✝¹ : TopologicalSpace α
T : (i : ι) → TopologicalSpace (π i)
f✝ : α → (i : ι) → π i
inst✝ : DecidableEq ι
l : Filter β
f : β → (i : ι) → π i
x : (i : ι) → π i
hf : Tendsto f l (𝓝 x)
j : ι
g : β → π j
xi : π j
hg : Tendsto g l (𝓝 xi)
⊢ Tendsto (fun i => Function.update (f i) j (g i) j) l (𝓝 (Function.update x j xi j))

Next tactic:
simp [*, hf.apply]
theorem Filter.Tendsto.update [DecidableEq ι] {l : Filter β} {f : β → ∀ i, π i} {x : ∀ i, π i}
    (hf : Tendsto f l (𝓝 x)) (i : ι) {g : β → π i} {xi : π i} (hg : Tendsto g l (𝓝 xi)) :
    Tendsto (fun a => update (f a) i (g a)) l (𝓝 <| update x i xi) :=
  tendsto_pi_nhds.2 fun j => by rcases eq_or_ne j i with (rfl | hj) <;> 

Proof state:
case inr
α : Type u
β : Type v
γ : Type u_1
δ : Type u_2
ε : Type u_3
ζ : Type u_4
ι : Type u_5
π : ι → Type u_6
κ : Type u_7
inst✝¹ : TopologicalSpace α
T : (i : ι) → TopologicalSpace (π i)
f✝ : α → (i : ι) → π i
inst✝ : DecidableEq ι
l : Filter β
f : β → (i : ι) → π i
x : (i : ι) → π i
hf : Tendsto f l (𝓝 x)
i : ι
g : β → π i
xi : π i
hg : Tendsto g l (𝓝 xi)
j : ι
hj : j ≠ i
⊢ Tendsto (fun i_1 => Function.update (f i_1) i (g i_1) j) l (𝓝 (Function.update x i xi j))

Next tactic:
simp [*, hf.apply]
theorem Filter.Tendsto.fin_insertNth {n} {π : Fin (n + 1) → Type*} [∀ i, TopologicalSpace (π i)]
    (i : Fin (n + 1)) {f : β → π i} {l : Filter β} {x : π i} (hf : Tendsto f l (𝓝 x))
    {g : β → ∀ j : Fin n, π (i.succAbove j)} {y : ∀ j, π (i.succAbove j)} (hg : Tendsto g l (𝓝 y)) :
    Tendsto (fun a => i.insertNth (f a) (g a)) l (𝓝 <| i.insertNth x y) :=
  tendsto_pi_nhds.2 fun j => Fin.succAboveCases i (by 

Proof state:
α : Type u
β : Type v
γ : Type u_1
δ : Type u_2
ε : Type u_3
ζ : Type u_4
ι : Type u_5
π✝ : ι → Type u_6
κ : Type u_7
inst✝¹ : TopologicalSpace α
T : (i : ι) → TopologicalSpace (π✝ i)
f✝ : α → (i : ι) → π✝ i
n : ℕ
π : Fin (n + 1) → Type u_8
inst✝ : (i : Fin (n + 1)) → TopologicalSpace (π i)
i : Fin (n + 1)
f : β → π i
l : Filter β
x : π i
hf : Tendsto f l (𝓝 x)
g : β → (j : Fin n) → π (Fin.succAbove i j)
y : (j : Fin n) → π (Fin.succAbove i j)
hg : Tendsto g l (𝓝 y)
j : Fin (n + 1)
⊢ Tendsto (fun i_1 => Fin.insertNth i (f i_1) (g i_1) i) l (𝓝 (Fin.insertNth i x y i))

Next tactic:
simpa
theorem Filter.Tendsto.fin_insertNth {n} {π : Fin (n + 1) → Type*} [∀ i, TopologicalSpace (π i)]
    (i : Fin (n + 1)) {f : β → π i} {l : Filter β} {x : π i} (hf : Tendsto f l (𝓝 x))
    {g : β → ∀ j : Fin n, π (i.succAbove j)} {y : ∀ j, π (i.succAbove j)} (hg : Tendsto g l (𝓝 y)) :
    Tendsto (fun a => i.insertNth (f a) (g a)) l (𝓝 <| i.insertNth x y) :=
  tendsto_pi_nhds.2 fun j => Fin.succAboveCases i (by simpa) (by 

Proof state:
α : Type u
β : Type v
γ : Type u_1
δ : Type u_2
ε : Type u_3
ζ : Type u_4
ι : Type u_5
π✝ : ι → Type u_6
κ : Type u_7
inst✝¹ : TopologicalSpace α
T : (i : ι) → TopologicalSpace (π✝ i)
f✝ : α → (i : ι) → π✝ i
n : ℕ
π : Fin (n + 1) → Type u_8
inst✝ : (i : Fin (n + 1)) → TopologicalSpace (π i)
i : Fin (n + 1)
f : β → π i
l : Filter β
x : π i
hf : Tendsto f l (𝓝 x)
g : β → (j : Fin n) → π (Fin.succAbove i j)
y : (j : Fin n) → π (Fin.succAbove i j)
hg : Tendsto g l (𝓝 y)
j : Fin (n + 1)
⊢ ∀ (j : Fin n),
    Tendsto (fun i_1 => Fin.insertNth i (f i_1) (g i_1) (Fin.succAbove i j)) l
      (𝓝 (Fin.insertNth i x y (Fin.succAbove i j)))

Next tactic:
simpa using tendsto_pi_nhds.1 hg
theorem isOpen_set_pi {i : Set ι} {s : ∀ a, Set (π a)} (hi : i.Finite)
    (hs : ∀ a ∈ i, IsOpen (s a)) : IsOpen (pi i s) := by
  

Proof state:
α : Type u
β : Type v
γ : Type u_1
δ : Type u_2
ε : Type u_3
ζ : Type u_4
ι : Type u_5
π : ι → Type u_6
κ : Type u_7
inst✝ : TopologicalSpace α
T : (i : ι) → TopologicalSpace (π i)
f : α → (i : ι) → π i
i : Set ι
s : (a : ι) → Set (π a)
hi : Set.Finite i
hs : ∀ a ∈ i, IsOpen (s a)
⊢ IsOpen (Set.pi i s)

Next tactic:
rw [pi_def]
theorem isOpen_set_pi {i : Set ι} {s : ∀ a, Set (π a)} (hi : i.Finite)
    (hs : ∀ a ∈ i, IsOpen (s a)) : IsOpen (pi i s) := by
  rw [pi_def]; 

Proof state:
α : Type u
β : Type v
γ : Type u_1
δ : Type u_2
ε : Type u_3
ζ : Type u_4
ι : Type u_5
π : ι → Type u_6
κ : Type u_7
inst✝ : TopologicalSpace α
T : (i : ι) → TopologicalSpace (π i)
f : α → (i : ι) → π i
i : Set ι
s : (a : ι) → Set (π a)
hi : Set.Finite i
hs : ∀ a ∈ i, IsOpen (s a)
⊢ IsOpen (⋂ a ∈ i, eval a ⁻¹' s a)

Next tactic:
exact hi.isOpen_biInter fun a ha => (hs _ ha).preimage (continuous_apply _)