Theorem: MeasureTheory.analyticSet_iff_exists_polishSpace_range
File: Mathlib/MeasureTheory/Constructions/Polish.lean

tactic: constructor
state_before: α : Type u_1
ι : Type u_2
inst✝ : TopologicalSpace α
s : Set α
⊢ AnalyticSet s ↔ ∃ β h, ∃ (_ : PolishSpace β), ∃ f, Continuous f ∧ range f = s
state_after: case mp
α : Type u_1
ι : Type u_2
inst✝ : TopologicalSpace α
s : Set α
⊢ AnalyticSet s → ∃ β h, ∃ (_ : PolishSpace β), ∃ f, Continuous f ∧ range f = s

case mpr
α : Type u_1
ι : Type u_2
inst✝ : TopologicalSpace α
s : Set α
⊢ (∃ β h, ∃ (_ : PolishSpace β), ∃ f, Continuous f ∧ range f = s) → AnalyticSet s

tactic: intro h
state_before: case mp
α : Type u_1
ι : Type u_2
inst✝ : TopologicalSpace α
s : Set α
⊢ AnalyticSet s → ∃ β h, ∃ (_ : PolishSpace β), ∃ f, Continuous f ∧ range f = s
state_after: case mp
α : Type u_1
ι : Type u_2
inst✝ : TopologicalSpace α
s : Set α
h : AnalyticSet s
⊢ ∃ β h, ∃ (_ : PolishSpace β), ∃ f, Continuous f ∧ range f = s

tactic: rw [AnalyticSet] at h
state_before: case mp
α : Type u_1
ι : Type u_2
inst✝ : TopologicalSpace α
s : Set α
h : AnalyticSet s
⊢ ∃ β h, ∃ (_ : PolishSpace β), ∃ f, Continuous f ∧ range f = s
state_after: case mp
α : Type u_1
ι : Type u_2
inst✝ : TopologicalSpace α
s : Set α
h : s = ∅ ∨ ∃ f, Continuous f ∧ range f = s
⊢ ∃ β h, ∃ (_ : PolishSpace β), ∃ f, Continuous f ∧ range f = s

tactic: cases' h with h h
state_before: case mp
α : Type u_1
ι : Type u_2
inst✝ : TopologicalSpace α
s : Set α
h : s = ∅ ∨ ∃ f, Continuous f ∧ range f = s
⊢ ∃ β h, ∃ (_ : PolishSpace β), ∃ f, Continuous f ∧ range f = s
state_after: case mp.inl
α : Type u_1
ι : Type u_2
inst✝ : TopologicalSpace α
s : Set α
h : s = ∅
⊢ ∃ β h, ∃ (_ : PolishSpace β), ∃ f, Continuous f ∧ range f = s

case mp.inr
α : Type u_1
ι : Type u_2
inst✝ : TopologicalSpace α
s : Set α
h : ∃ f, Continuous f ∧ range f = s
⊢ ∃ β h, ∃ (_ : PolishSpace β), ∃ f, Continuous f ∧ range f = s

tactic: refine ⟨Empty, inferInstance, inferInstance, Empty.elim, continuous_bot, ?_⟩
state_before: case mp.inl
α : Type u_1
ι : Type u_2
inst✝ : TopologicalSpace α
s : Set α
h : s = ∅
⊢ ∃ β h, ∃ (_ : PolishSpace β), ∃ f, Continuous f ∧ range f = s
state_after: case mp.inl
α : Type u_1
ι : Type u_2
inst✝ : TopologicalSpace α
s : Set α
h : s = ∅
⊢ range Empty.elim = s

tactic: rw [h]
state_before: case mp.inl
α : Type u_1
ι : Type u_2
inst✝ : TopologicalSpace α
s : Set α
h : s = ∅
⊢ range Empty.elim = s
state_after: case mp.inl
α : Type u_1
ι : Type u_2
inst✝ : TopologicalSpace α
s : Set α
h : s = ∅
⊢ range Empty.elim = ∅

tactic: exact range_eq_empty _
state_before: case mp.inl
α : Type u_1
ι : Type u_2
inst✝ : TopologicalSpace α
s : Set α
h : s = ∅
⊢ range Empty.elim = ∅
state_after: no goals

tactic: exact ⟨ℕ → ℕ, inferInstance, inferInstance, h⟩
state_before: case mp.inr
α : Type u_1
ι : Type u_2
inst✝ : TopologicalSpace α
s : Set α
h : ∃ f, Continuous f ∧ range f = s
⊢ ∃ β h, ∃ (_ : PolishSpace β), ∃ f, Continuous f ∧ range f = s
state_after: no goals

tactic: rintro ⟨β, h, h', f, f_cont, f_range⟩
state_before: case mpr
α : Type u_1
ι : Type u_2
inst✝ : TopologicalSpace α
s : Set α
⊢ (∃ β h, ∃ (_ : PolishSpace β), ∃ f, Continuous f ∧ range f = s) → AnalyticSet s
state_after: case mpr.intro.intro.intro.intro.intro
α : Type u_1
ι : Type u_2
inst✝ : TopologicalSpace α
s : Set α
β : Type
h : TopologicalSpace β
h' : PolishSpace β
f : β → α
f_cont : Continuous f
f_range : range f = s
⊢ AnalyticSet s

tactic: rw [← f_range]
state_before: case mpr.intro.intro.intro.intro.intro
α : Type u_1
ι : Type u_2
inst✝ : TopologicalSpace α
s : Set α
β : Type
h : TopologicalSpace β
h' : PolishSpace β
f : β → α
f_cont : Continuous f
f_range : range f = s
⊢ AnalyticSet s
state_after: case mpr.intro.intro.intro.intro.intro
α : Type u_1
ι : Type u_2
inst✝ : TopologicalSpace α
s : Set α
β : Type
h : TopologicalSpace β
h' : PolishSpace β
f : β → α
f_cont : Continuous f
f_range : range f = s
⊢ AnalyticSet (range f)

tactic: exact analyticSet_range_of_polishSpace f_cont
state_before: case mpr.intro.intro.intro.intro.intro
α : Type u_1
ι : Type u_2
inst✝ : TopologicalSpace α
s : Set α
β : Type
h : TopologicalSpace β
h' : PolishSpace β
f : β → α
f_cont : Continuous f
f_range : range f = s
⊢ AnalyticSet (range f)
state_after: no goals