-- Mathlib/MeasureTheory/Function/AEMeasurableSequence.lean
theorem iSup [CompleteLattice β] [Countable ι] (hf : ∀ i, AEMeasurable (f i) μ)
    (hp : ∀ᵐ x ∂μ, p x fun n => f n x) : ⨆ n, aeSeq hf p n =ᵐ[μ] ⨆ n, f n

Proof state:
case e_s
ι : Sort u_1
α : Type u_2
β : Type u_3
inst✝³ : MeasurableSpace α
inst✝² : MeasurableSpace β
f : ι → α → β
μ : Measure α
p : α → (ι → β) → Prop
inst✝¹ : CompleteLattice β
inst✝ : Countable ι
hf : ∀ (i : ι), AEMeasurable (f i) μ
hp : ∀ᵐ (x : α) ∂μ, p x fun n => f n x
x : α
hx : x ∈ aeSeqSet hf p
⊢ (fun i => aeSeq hf p i x) = fun i => f i x

Tactic:
exact funext fun i => aeSeq_eq_fun_of_mem_aeSeqSet hf hx i

Result:
no goals

Proof state:
ι : Sort u_1
α : Type u_2
β : Type u_3
inst✝³ : MeasurableSpace α
inst✝² : MeasurableSpace β
f : ι → α → β
μ : Measure α
p : α → (ι → β) → Prop
inst✝¹ : CompleteLattice β
inst✝ : Countable ι
hf : ∀ (i : ι), AEMeasurable (f i) μ
hp : ∀ᵐ (x : α) ∂μ, p x fun n => f n x
h_ss : aeSeqSet hf p ⊆ {a | ⨆ i, aeSeq hf p i a = ⨆ i, f i a}
⊢ μ {a | ¬⨆ i, aeSeq hf p i a = ⨆ i, f i a} = 0

Tactic:
exact measure_mono_null (Set.compl_subset_compl.mpr h_ss) (measure_compl_aeSeqSet_eq_zero hf hp)

Result:
no goals

Proof state:
ι : Sort u_1
α : Type u_2
β : Type u_3
inst✝³ : MeasurableSpace α
inst✝² : MeasurableSpace β
f : ι → α → β
μ : Measure α
p : α → (ι → β) → Prop
inst✝¹ : CompleteLattice β
inst✝ : Countable ι
hf : ∀ (i : ι), AEMeasurable (f i) μ
hp : ∀ᵐ (x : α) ∂μ, p x fun n => f n x
x : α
hx : x ∈ aeSeqSet hf p
⊢ x ∈ {a | ⨆ i, aeSeq hf p i a = ⨆ i, f i a}

Tactic:
congr

Result:
case e_s
ι : Sort u_1
α : Type u_2
β : Type u_3
inst✝³ : MeasurableSpace α
inst✝² : MeasurableSpace β
f : ι → α → β
μ : Measure α
p : α → (ι → β) → Prop
inst✝¹ : CompleteLattice β
inst✝ : Countable ι
hf : ∀ (i : ι), AEMeasurable (f i) μ
hp : ∀ᵐ (x : α) ∂μ, p x fun n => f n x
x : α
hx : x ∈ aeSeqSet hf p
⊢ (fun i => aeSeq hf p i x) = fun i => f i x

Proof state:
ι : Sort u_1
α : Type u_2
β : Type u_3
inst✝³ : MeasurableSpace α
inst✝² : MeasurableSpace β
f : ι → α → β
μ : Measure α
p : α → (ι → β) → Prop
inst✝¹ : CompleteLattice β
inst✝ : Countable ι
hf : ∀ (i : ι), AEMeasurable (f i) μ
hp : ∀ᵐ (x : α) ∂μ, p x fun n => f n x
⊢ ⨆ n, aeSeq hf p n =ᶠ[ae μ] ⨆ n, f n

Tactic:
simp_rw [Filter.EventuallyEq, ae_iff, iSup_apply]

Result:
ι : Sort u_1
α : Type u_2
β : Type u_3
inst✝³ : MeasurableSpace α
inst✝² : MeasurableSpace β
f : ι → α → β
μ : Measure α
p : α → (ι → β) → Prop
inst✝¹ : CompleteLattice β
inst✝ : Countable ι
hf : ∀ (i : ι), AEMeasurable (f i) μ
hp : ∀ᵐ (x : α) ∂μ, p x fun n => f n x
⊢ μ {a | ¬⨆ i, aeSeq hf p i a = ⨆ i, f i a} = 0

Proof state:
ι : Sort u_1
α : Type u_2
β : Type u_3
inst✝³ : MeasurableSpace α
inst✝² : MeasurableSpace β
f : ι → α → β
μ : Measure α
p : α → (ι → β) → Prop
inst✝¹ : CompleteLattice β
inst✝ : Countable ι
hf : ∀ (i : ι), AEMeasurable (f i) μ
hp : ∀ᵐ (x : α) ∂μ, p x fun n => f n x
⊢ μ {a | ¬⨆ i, aeSeq hf p i a = ⨆ i, f i a} = 0

Tactic:
have h_ss : aeSeqSet hf p ⊆ { a : α | ⨆ i : ι, aeSeq hf p i a = ⨆ i : ι, f i a } := by
  intro x hx
  congr
  exact funext fun i => aeSeq_eq_fun_of_mem_aeSeqSet hf hx i

Result:
ι : Sort u_1
α : Type u_2
β : Type u_3
inst✝³ : MeasurableSpace α
inst✝² : MeasurableSpace β
f : ι → α → β
μ : Measure α
p : α → (ι → β) → Prop
inst✝¹ : CompleteLattice β
inst✝ : Countable ι
hf : ∀ (i : ι), AEMeasurable (f i) μ
hp : ∀ᵐ (x : α) ∂μ, p x fun n => f n x
h_ss : aeSeqSet hf p ⊆ {a | ⨆ i, aeSeq hf p i a = ⨆ i, f i a}
⊢ μ {a | ¬⨆ i, aeSeq hf p i a = ⨆ i, f i a} = 0

Proof state:
ι : Sort u_1
α : Type u_2
β : Type u_3
inst✝³ : MeasurableSpace α
inst✝² : MeasurableSpace β
f : ι → α → β
μ : Measure α
p : α → (ι → β) → Prop
inst✝¹ : CompleteLattice β
inst✝ : Countable ι
hf : ∀ (i : ι), AEMeasurable (f i) μ
hp : ∀ᵐ (x : α) ∂μ, p x fun n => f n x
⊢ aeSeqSet hf p ⊆ {a | ⨆ i, aeSeq hf p i a = ⨆ i, f i a}

Tactic:
intro x hx

Result:
ι : Sort u_1
α : Type u_2
β : Type u_3
inst✝³ : MeasurableSpace α
inst✝² : MeasurableSpace β
f : ι → α → β
μ : Measure α
p : α → (ι → β) → Prop
inst✝¹ : CompleteLattice β
inst✝ : Countable ι
hf : ∀ (i : ι), AEMeasurable (f i) μ
hp : ∀ᵐ (x : α) ∂μ, p x fun n => f n x
x : α
hx : x ∈ aeSeqSet hf p
⊢ x ∈ {a | ⨆ i, aeSeq hf p i a = ⨆ i, f i a}