Theorem: IsCountablySpanning.pi
File: Mathlib/MeasureTheory/Constructions/Pi.lean

tactic: choose s h1s h2s using hC
state_before: ι : Type u_1
ι' : Type u_2
α : ι → Type u_3
inst✝¹ : Finite ι
inst✝ : Finite ι'
C : (i : ι) → Set (Set (α i))
hC : ∀ (i : ι), IsCountablySpanning (C i)
⊢ IsCountablySpanning (univ.pi '' univ.pi C)
state_after: ι : Type u_1
ι' : Type u_2
α : ι → Type u_3
inst✝¹ : Finite ι
inst✝ : Finite ι'
C : (i : ι) → Set (Set (α i))
s : (i : ι) → ℕ → Set (α i)
h1s : ∀ (i : ι) (n : ℕ), s i n ∈ C i
h2s : ∀ (i : ι), ⋃ n, s i n = univ
⊢ IsCountablySpanning (univ.pi '' univ.pi C)

tactic: cases nonempty_encodable (ι → ℕ)
state_before: ι : Type u_1
ι' : Type u_2
α : ι → Type u_3
inst✝¹ : Finite ι
inst✝ : Finite ι'
C : (i : ι) → Set (Set (α i))
s : (i : ι) → ℕ → Set (α i)
h1s : ∀ (i : ι) (n : ℕ), s i n ∈ C i
h2s : ∀ (i : ι), ⋃ n, s i n = univ
⊢ IsCountablySpanning (univ.pi '' univ.pi C)
state_after: case intro
ι : Type u_1
ι' : Type u_2
α : ι → Type u_3
inst✝¹ : Finite ι
inst✝ : Finite ι'
C : (i : ι) → Set (Set (α i))
s : (i : ι) → ℕ → Set (α i)
h1s : ∀ (i : ι) (n : ℕ), s i n ∈ C i
h2s : ∀ (i : ι), ⋃ n, s i n = univ
val✝ : Encodable (ι → ℕ)
⊢ IsCountablySpanning (univ.pi '' univ.pi C)

tactic: let e : ℕ → ι → ℕ := fun n => (@decode (ι → ℕ) _ n).iget
state_before: case intro
ι : Type u_1
ι' : Type u_2
α : ι → Type u_3
inst✝¹ : Finite ι
inst✝ : Finite ι'
C : (i : ι) → Set (Set (α i))
s : (i : ι) → ℕ → Set (α i)
h1s : ∀ (i : ι) (n : ℕ), s i n ∈ C i
h2s : ∀ (i : ι), ⋃ n, s i n = univ
val✝ : Encodable (ι → ℕ)
⊢ IsCountablySpanning (univ.pi '' univ.pi C)
state_after: case intro
ι : Type u_1
ι' : Type u_2
α : ι → Type u_3
inst✝¹ : Finite ι
inst✝ : Finite ι'
C : (i : ι) → Set (Set (α i))
s : (i : ι) → ℕ → Set (α i)
h1s : ∀ (i : ι) (n : ℕ), s i n ∈ C i
h2s : ∀ (i : ι), ⋃ n, s i n = univ
val✝ : Encodable (ι → ℕ)
e : ℕ → ι → ℕ := fun n => (decode n).iget
⊢ IsCountablySpanning (univ.pi '' univ.pi C)

tactic: refine ⟨fun n => Set.pi univ fun i => s i (e n i), fun n =>
  mem_image_of_mem _ fun i _ => h1s i _, ?_⟩
state_before: case intro
ι : Type u_1
ι' : Type u_2
α : ι → Type u_3
inst✝¹ : Finite ι
inst✝ : Finite ι'
C : (i : ι) → Set (Set (α i))
s : (i : ι) → ℕ → Set (α i)
h1s : ∀ (i : ι) (n : ℕ), s i n ∈ C i
h2s : ∀ (i : ι), ⋃ n, s i n = univ
val✝ : Encodable (ι → ℕ)
e : ℕ → ι → ℕ := fun n => (decode n).iget
⊢ IsCountablySpanning (univ.pi '' univ.pi C)
state_after: case intro
ι : Type u_1
ι' : Type u_2
α : ι → Type u_3
inst✝¹ : Finite ι
inst✝ : Finite ι'
C : (i : ι) → Set (Set (α i))
s : (i : ι) → ℕ → Set (α i)
h1s : ∀ (i : ι) (n : ℕ), s i n ∈ C i
h2s : ∀ (i : ι), ⋃ n, s i n = univ
val✝ : Encodable (ι → ℕ)
e : ℕ → ι → ℕ := fun n => (decode n).iget
⊢ ⋃ n, (fun n => univ.pi fun i => s i (e n i)) n = univ

tactic: simp_rw [(surjective_decode_iget (ι → ℕ)).iUnion_comp fun x => Set.pi univ fun i => s i (x i),
  iUnion_univ_pi s, h2s, pi_univ]
state_before: case intro
ι : Type u_1
ι' : Type u_2
α : ι → Type u_3
inst✝¹ : Finite ι
inst✝ : Finite ι'
C : (i : ι) → Set (Set (α i))
s : (i : ι) → ℕ → Set (α i)
h1s : ∀ (i : ι) (n : ℕ), s i n ∈ C i
h2s : ∀ (i : ι), ⋃ n, s i n = univ
val✝ : Encodable (ι → ℕ)
e : ℕ → ι → ℕ := fun n => (decode n).iget
⊢ ⋃ n, (fun n => univ.pi fun i => s i (e n i)) n = univ
state_after: no goals