Theorem: ChartedSpace.locallyCompact
File: Mathlib/Geometry/Manifold/ChartedSpace.lean

tactic: have : ∀ x : M, (𝓝 x).HasBasis
    (fun s ↦ s ∈ 𝓝 (chartAt H x x) ∧ IsCompact s ∧ s ⊆ (chartAt H x).target)
    fun s ↦ (chartAt H x).symm '' s := fun x ↦ by
  rw [← (chartAt H x).symm_map_nhds_eq (mem_chart_source H x)]
  exact ((compact_basis_nhds (chartAt H x x)).hasBasis_self_subset
    (chart_target_mem_nhds H x)).map _
state_before: H : Type u
H' : Type ?u.45087
M : Type u_1
M' : Type ?u.45093
M'' : Type ?u.45096
inst✝³ : TopologicalSpace H
inst✝² : TopologicalSpace M
inst✝¹ : ChartedSpace H M
inst✝ : LocallyCompactSpace H
⊢ LocallyCompactSpace M

tactic: refine locallyCompactSpace_of_hasBasis this ?_
state_before: H : Type u
H' : Type ?u.45087
M : Type u_1
M' : Type ?u.45093
M'' : Type ?u.45096
inst✝³ : TopologicalSpace H
inst✝² : TopologicalSpace M
inst✝¹ : ChartedSpace H M
inst✝ : LocallyCompactSpace H
this :
  ∀ (x : M),
    HasBasis (𝓝 x) (fun s => s ∈ 𝓝 (↑(chartAt H x) x) ∧ IsCompact s ∧ s ⊆ (chartAt H x).toLocalEquiv.target) fun s =>
      ↑(LocalHomeomorph.symm (chartAt H x)) '' s
⊢ LocallyCompactSpace M

tactic: rintro x s ⟨_, h₂, h₃⟩
state_before: H : Type u
H' : Type ?u.45087
M : Type u_1
M' : Type ?u.45093
M'' : Type ?u.45096
inst✝³ : TopologicalSpace H
inst✝² : TopologicalSpace M
inst✝¹ : ChartedSpace H M
inst✝ : LocallyCompactSpace H
this :
  ∀ (x : M),
    HasBasis (𝓝 x) (fun s => s ∈ 𝓝 (↑(chartAt H x) x) ∧ IsCompact s ∧ s ⊆ (chartAt H x).toLocalEquiv.target) fun s =>
      ↑(LocalHomeomorph.symm (chartAt H x)) '' s
⊢ ∀ (x : M) (i : Set H),
    i ∈ 𝓝 (↑(chartAt H x) x) ∧ IsCompact i ∧ i ⊆ (chartAt H x).toLocalEquiv.target →
      IsCompact (↑(LocalHomeomorph.symm (chartAt H x)) '' i)

tactic: exact h₂.image_of_continuousOn ((chartAt H x).continuousOn_symm.mono h₃)
state_before: case intro.intro
H : Type u
H' : Type ?u.45087
M : Type u_1
M' : Type ?u.45093
M'' : Type ?u.45096
inst✝³ : TopologicalSpace H
inst✝² : TopologicalSpace M
inst✝¹ : ChartedSpace H M
inst✝ : LocallyCompactSpace H
this :
  ∀ (x : M),
    HasBasis (𝓝 x) (fun s => s ∈ 𝓝 (↑(chartAt H x) x) ∧ IsCompact s ∧ s ⊆ (chartAt H x).toLocalEquiv.target) fun s =>
      ↑(LocalHomeomorph.symm (chartAt H x)) '' s
x : M
s : Set H
left✝ : s ∈ 𝓝 (↑(chartAt H x) x)
h₂ : IsCompact s
h₃ : s ⊆ (chartAt H x).toLocalEquiv.target
⊢ IsCompact (↑(LocalHomeomorph.symm (chartAt H x)) '' s)

tactic: rw [← (chartAt H x).symm_map_nhds_eq (mem_chart_source H x)]
state_before: H : Type u
H' : Type ?u.45087
M : Type u_1
M' : Type ?u.45093
M'' : Type ?u.45096
inst✝³ : TopologicalSpace H
inst✝² : TopologicalSpace M
inst✝¹ : ChartedSpace H M
inst✝ : LocallyCompactSpace H
x : M
⊢ HasBasis (𝓝 x) (fun s => s ∈ 𝓝 (↑(chartAt H x) x) ∧ IsCompact s ∧ s ⊆ (chartAt H x).toLocalEquiv.target) fun s =>
    ↑(LocalHomeomorph.symm (chartAt H x)) '' s

tactic: exact ((compact_basis_nhds (chartAt H x x)).hasBasis_self_subset
  (chart_target_mem_nhds H x)).map _
state_before: H : Type u
H' : Type ?u.45087
M : Type u_1
M' : Type ?u.45093
M'' : Type ?u.45096
inst✝³ : TopologicalSpace H
inst✝² : TopologicalSpace M
inst✝¹ : ChartedSpace H M
inst✝ : LocallyCompactSpace H
x : M
⊢ HasBasis (map (↑(LocalHomeomorph.symm (chartAt H x))) (𝓝 (↑(chartAt H x) x)))
    (fun s => s ∈ 𝓝 (↑(chartAt H x) x) ∧ IsCompact s ∧ s ⊆ (chartAt H x).toLocalEquiv.target) fun s =>
    ↑(LocalHomeomorph.symm (chartAt H x)) '' s