Theorem: AEMeasurable.is_lub_of_nonempty
File: Mathlib/MeasureTheory/Constructions/BorelSpace/Basic.lean

tactic: let p : δ → (ι → α) → Prop := fun x f' => IsLUB { a | ∃ i, f' i = a } (g x)
state_before: α : Type u_3
β : Type ?u.1096180
γ : Type ?u.1096183
γ₂ : Type ?u.1096186
δ : Type u_2
ι✝ : Sort y
s t u : Set α
inst✝¹³ : TopologicalSpace α
inst✝¹² : MeasurableSpace α
inst✝¹¹ : BorelSpace α
inst✝¹⁰ : TopologicalSpace β
inst✝⁹ : MeasurableSpace β
inst✝⁸ : BorelSpace β
inst✝⁷ : TopologicalSpace γ
inst✝⁶ : MeasurableSpace γ
inst✝⁵ : BorelSpace γ
inst✝⁴ : MeasurableSpace δ
inst✝³ : LinearOrder α
inst✝² : OrderTopology α
inst✝¹ : SecondCountableTopology α
ι : Sort u_1
hι : Nonempty ι
μ : MeasureTheory.Measure δ
inst✝ : Countable ι
f : ι → δ → α
g : δ → α
hf : ∀ (i : ι), AEMeasurable (f i)
hg : ∀ᵐ (b : δ) ∂μ, IsLUB {a | ∃ i, f i b = a} (g b)
⊢ AEMeasurable g

tactic: let g_seq x := ite (x ∈ aeSeqSet hf p) (g x) (⟨g x⟩ : Nonempty α).some
state_before: α : Type u_3
β : Type ?u.1096180
γ : Type ?u.1096183
γ₂ : Type ?u.1096186
δ : Type u_2
ι✝ : Sort y
s t u : Set α
inst✝¹³ : TopologicalSpace α
inst✝¹² : MeasurableSpace α
inst✝¹¹ : BorelSpace α
inst✝¹⁰ : TopologicalSpace β
inst✝⁹ : MeasurableSpace β
inst✝⁸ : BorelSpace β
inst✝⁷ : TopologicalSpace γ
inst✝⁶ : MeasurableSpace γ
inst✝⁵ : BorelSpace γ
inst✝⁴ : MeasurableSpace δ
inst✝³ : LinearOrder α
inst✝² : OrderTopology α
inst✝¹ : SecondCountableTopology α
ι : Sort u_1
hι : Nonempty ι
μ : MeasureTheory.Measure δ
inst✝ : Countable ι
f : ι → δ → α
g : δ → α
hf : ∀ (i : ι), AEMeasurable (f i)
hg : ∀ᵐ (b : δ) ∂μ, IsLUB {a | ∃ i, f i b = a} (g b)
p : δ → (ι → α) → Prop := fun x f' => IsLUB {a | ∃ i, f' i = a} (g x)
⊢ AEMeasurable g

tactic: refine' ⟨g_seq, Measurable.isLUB (aeSeq.measurable hf p) hg_seq, _⟩
state_before: α : Type u_3
β : Type ?u.1096180
γ : Type ?u.1096183
γ₂ : Type ?u.1096186
δ : Type u_2
ι✝ : Sort y
s t u : Set α
inst✝¹³ : TopologicalSpace α
inst✝¹² : MeasurableSpace α
inst✝¹¹ : BorelSpace α
inst✝¹⁰ : TopologicalSpace β
inst✝⁹ : MeasurableSpace β
inst✝⁸ : BorelSpace β
inst✝⁷ : TopologicalSpace γ
inst✝⁶ : MeasurableSpace γ
inst✝⁵ : BorelSpace γ
inst✝⁴ : MeasurableSpace δ
inst✝³ : LinearOrder α
inst✝² : OrderTopology α
inst✝¹ : SecondCountableTopology α
ι : Sort u_1
hι : Nonempty ι
μ : MeasureTheory.Measure δ
inst✝ : Countable ι
f : ι → δ → α
g : δ → α
hf : ∀ (i : ι), AEMeasurable (f i)
hg : ∀ᵐ (b : δ) ∂μ, IsLUB {a | ∃ i, f i b = a} (g b)
p : δ → (ι → α) → Prop := fun x f' => IsLUB {a | ∃ i, f' i = a} (g x)
g_seq : δ → α := fun x => if x ∈ aeSeqSet hf p then g x else Nonempty.some (_ : Nonempty α)
hg_seq : ∀ (b : δ), IsLUB {a | ∃ i, aeSeq hf p i b = a} (g_seq b)
⊢ AEMeasurable g

tactic: exact
  (ite_ae_eq_of_measure_compl_zero g (fun x => (⟨g x⟩ : Nonempty α).some) (aeSeqSet hf p)
      (aeSeq.measure_compl_aeSeqSet_eq_zero hf hg)).symm
state_before: α : Type u_3
β : Type ?u.1096180
γ : Type ?u.1096183
γ₂ : Type ?u.1096186
δ : Type u_2
ι✝ : Sort y
s t u : Set α
inst✝¹³ : TopologicalSpace α
inst✝¹² : MeasurableSpace α
inst✝¹¹ : BorelSpace α
inst✝¹⁰ : TopologicalSpace β
inst✝⁹ : MeasurableSpace β
inst✝⁸ : BorelSpace β
inst✝⁷ : TopologicalSpace γ
inst✝⁶ : MeasurableSpace γ
inst✝⁵ : BorelSpace γ
inst✝⁴ : MeasurableSpace δ
inst✝³ : LinearOrder α
inst✝² : OrderTopology α
inst✝¹ : SecondCountableTopology α
ι : Sort u_1
hι : Nonempty ι
μ : MeasureTheory.Measure δ
inst✝ : Countable ι
f : ι → δ → α
g : δ → α
hf : ∀ (i : ι), AEMeasurable (f i)
hg : ∀ᵐ (b : δ) ∂μ, IsLUB {a | ∃ i, f i b = a} (g b)
p : δ → (ι → α) → Prop := fun x f' => IsLUB {a | ∃ i, f' i = a} (g x)
g_seq : δ → α := fun x => if x ∈ aeSeqSet hf p then g x else Nonempty.some (_ : Nonempty α)
hg_seq : ∀ (b : δ), IsLUB {a | ∃ i, aeSeq hf p i b = a} (g_seq b)
⊢ g =ᵐ[μ] g_seq

tactic: intro b
state_before: α : Type u_3
β : Type ?u.1096180
γ : Type ?u.1096183
γ₂ : Type ?u.1096186
δ : Type u_2
ι✝ : Sort y
s t u : Set α
inst✝¹³ : TopologicalSpace α
inst✝¹² : MeasurableSpace α
inst✝¹¹ : BorelSpace α
inst✝¹⁰ : TopologicalSpace β
inst✝⁹ : MeasurableSpace β
inst✝⁸ : BorelSpace β
inst✝⁷ : TopologicalSpace γ
inst✝⁶ : MeasurableSpace γ
inst✝⁵ : BorelSpace γ
inst✝⁴ : MeasurableSpace δ
inst✝³ : LinearOrder α
inst✝² : OrderTopology α
inst✝¹ : SecondCountableTopology α
ι : Sort u_1
hι : Nonempty ι
μ : MeasureTheory.Measure δ
inst✝ : Countable ι
f : ι → δ → α
g : δ → α
hf : ∀ (i : ι), AEMeasurable (f i)
hg : ∀ᵐ (b : δ) ∂μ, IsLUB {a | ∃ i, f i b = a} (g b)
p : δ → (ι → α) → Prop := fun x f' => IsLUB {a | ∃ i, f' i = a} (g x)
g_seq : δ → α := fun x => if x ∈ aeSeqSet hf p then g x else Nonempty.some (_ : Nonempty α)
⊢ ∀ (b : δ), IsLUB {a | ∃ i, aeSeq hf p i b = a} (g_seq b)

tactic: haveI hα : Nonempty α := Nonempty.map g ⟨b⟩
state_before: α : Type u_3
β : Type ?u.1096180
γ : Type ?u.1096183
γ₂ : Type ?u.1096186
δ : Type u_2
ι✝ : Sort y
s t u : Set α
inst✝¹³ : TopologicalSpace α
inst✝¹² : MeasurableSpace α
inst✝¹¹ : BorelSpace α
inst✝¹⁰ : TopologicalSpace β
inst✝⁹ : MeasurableSpace β
inst✝⁸ : BorelSpace β
inst✝⁷ : TopologicalSpace γ
inst✝⁶ : MeasurableSpace γ
inst✝⁵ : BorelSpace γ
inst✝⁴ : MeasurableSpace δ
inst✝³ : LinearOrder α
inst✝² : OrderTopology α
inst✝¹ : SecondCountableTopology α
ι : Sort u_1
hι : Nonempty ι
μ : MeasureTheory.Measure δ
inst✝ : Countable ι
f : ι → δ → α
g : δ → α
hf : ∀ (i : ι), AEMeasurable (f i)
hg : ∀ᵐ (b : δ) ∂μ, IsLUB {a | ∃ i, f i b = a} (g b)
p : δ → (ι → α) → Prop := fun x f' => IsLUB {a | ∃ i, f' i = a} (g x)
g_seq : δ → α := fun x => if x ∈ aeSeqSet hf p then g x else Nonempty.some (_ : Nonempty α)
b : δ
⊢ IsLUB {a | ∃ i, aeSeq hf p i b = a} (g_seq b)

tactic: simp only [aeSeq]
state_before: α : Type u_3
β : Type ?u.1096180
γ : Type ?u.1096183
γ₂ : Type ?u.1096186
δ : Type u_2
ι✝ : Sort y
s t u : Set α
inst✝¹³ : TopologicalSpace α
inst✝¹² : MeasurableSpace α
inst✝¹¹ : BorelSpace α
inst✝¹⁰ : TopologicalSpace β
inst✝⁹ : MeasurableSpace β
inst✝⁸ : BorelSpace β
inst✝⁷ : TopologicalSpace γ
inst✝⁶ : MeasurableSpace γ
inst✝⁵ : BorelSpace γ
inst✝⁴ : MeasurableSpace δ
inst✝³ : LinearOrder α
inst✝² : OrderTopology α
inst✝¹ : SecondCountableTopology α
ι : Sort u_1
hι : Nonempty ι
μ : MeasureTheory.Measure δ
inst✝ : Countable ι
f : ι → δ → α
g : δ → α
hf : ∀ (i : ι), AEMeasurable (f i)
hg : ∀ᵐ (b : δ) ∂μ, IsLUB {a | ∃ i, f i b = a} (g b)
p : δ → (ι → α) → Prop := fun x f' => IsLUB {a | ∃ i, f' i = a} (g x)
g_seq : δ → α := fun x => if x ∈ aeSeqSet hf p then g x else Nonempty.some (_ : Nonempty α)
b : δ
hα : Nonempty α
⊢ IsLUB {a | ∃ i, aeSeq hf p i b = a} (g_seq b)

tactic: split_ifs with h
state_before: α : Type u_3
β : Type ?u.1096180
γ : Type ?u.1096183
γ₂ : Type ?u.1096186
δ : Type u_2
ι✝ : Sort y
s t u : Set α
inst✝¹³ : TopologicalSpace α
inst✝¹² : MeasurableSpace α
inst✝¹¹ : BorelSpace α
inst✝¹⁰ : TopologicalSpace β
inst✝⁹ : MeasurableSpace β
inst✝⁸ : BorelSpace β
inst✝⁷ : TopologicalSpace γ
inst✝⁶ : MeasurableSpace γ
inst✝⁵ : BorelSpace γ
inst✝⁴ : MeasurableSpace δ
inst✝³ : LinearOrder α
inst✝² : OrderTopology α
inst✝¹ : SecondCountableTopology α
ι : Sort u_1
hι : Nonempty ι
μ : MeasureTheory.Measure δ
inst✝ : Countable ι
f : ι → δ → α
g : δ → α
hf : ∀ (i : ι), AEMeasurable (f i)
hg : ∀ᵐ (b : δ) ∂μ, IsLUB {a | ∃ i, f i b = a} (g b)
p : δ → (ι → α) → Prop := fun x f' => IsLUB {a | ∃ i, f' i = a} (g x)
g_seq : δ → α := fun x => if x ∈ aeSeqSet hf p then g x else Nonempty.some (_ : Nonempty α)
b : δ
hα : Nonempty α
⊢ IsLUB
    {a |
      ∃ i,
        (if b ∈ aeSeqSet hf fun x f' => IsLUB {a | ∃ i, f' i = a} (g x) then mk (f i) (_ : AEMeasurable (f i)) b
          else Nonempty.some (_ : Nonempty α)) =
          a}
    (if b ∈ aeSeqSet hf fun x f' => IsLUB {a | ∃ i, f' i = a} (g x) then g b else Nonempty.some (_ : Nonempty α))

tactic: have h_set_eq :
    { a : α | ∃ i : ι, (hf i).mk (f i) b = a } = { a : α | ∃ i : ι, f i b = a } := by
  ext x
  simp_rw [Set.mem_setOf_eq, aeSeq.mk_eq_fun_of_mem_aeSeqSet hf h]
state_before: case inl
α : Type u_3
β : Type ?u.1096180
γ : Type ?u.1096183
γ₂ : Type ?u.1096186
δ : Type u_2
ι✝ : Sort y
s t u : Set α
inst✝¹³ : TopologicalSpace α
inst✝¹² : MeasurableSpace α
inst✝¹¹ : BorelSpace α
inst✝¹⁰ : TopologicalSpace β
inst✝⁹ : MeasurableSpace β
inst✝⁸ : BorelSpace β
inst✝⁷ : TopologicalSpace γ
inst✝⁶ : MeasurableSpace γ
inst✝⁵ : BorelSpace γ
inst✝⁴ : MeasurableSpace δ
inst✝³ : LinearOrder α
inst✝² : OrderTopology α
inst✝¹ : SecondCountableTopology α
ι : Sort u_1
hι : Nonempty ι
μ : MeasureTheory.Measure δ
inst✝ : Countable ι
f : ι → δ → α
g : δ → α
hf : ∀ (i : ι), AEMeasurable (f i)
hg : ∀ᵐ (b : δ) ∂μ, IsLUB {a | ∃ i, f i b = a} (g b)
p : δ → (ι → α) → Prop := fun x f' => IsLUB {a | ∃ i, f' i = a} (g x)
g_seq : δ → α := fun x => if x ∈ aeSeqSet hf p then g x else Nonempty.some (_ : Nonempty α)
b : δ
hα : Nonempty α
h : b ∈ aeSeqSet hf fun x f' => IsLUB {a | ∃ i, f' i = a} (g x)
⊢ IsLUB {a | ∃ i, mk (f i) (_ : AEMeasurable (f i)) b = a} (g b)

tactic: rw [h_set_eq]
state_before: case inl
α : Type u_3
β : Type ?u.1096180
γ : Type ?u.1096183
γ₂ : Type ?u.1096186
δ : Type u_2
ι✝ : Sort y
s t u : Set α
inst✝¹³ : TopologicalSpace α
inst✝¹² : MeasurableSpace α
inst✝¹¹ : BorelSpace α
inst✝¹⁰ : TopologicalSpace β
inst✝⁹ : MeasurableSpace β
inst✝⁸ : BorelSpace β
inst✝⁷ : TopologicalSpace γ
inst✝⁶ : MeasurableSpace γ
inst✝⁵ : BorelSpace γ
inst✝⁴ : MeasurableSpace δ
inst✝³ : LinearOrder α
inst✝² : OrderTopology α
inst✝¹ : SecondCountableTopology α
ι : Sort u_1
hι : Nonempty ι
μ : MeasureTheory.Measure δ
inst✝ : Countable ι
f : ι → δ → α
g : δ → α
hf : ∀ (i : ι), AEMeasurable (f i)
hg : ∀ᵐ (b : δ) ∂μ, IsLUB {a | ∃ i, f i b = a} (g b)
p : δ → (ι → α) → Prop := fun x f' => IsLUB {a | ∃ i, f' i = a} (g x)
g_seq : δ → α := fun x => if x ∈ aeSeqSet hf p then g x else Nonempty.some (_ : Nonempty α)
b : δ
hα : Nonempty α
h : b ∈ aeSeqSet hf fun x f' => IsLUB {a | ∃ i, f' i = a} (g x)
h_set_eq : {a | ∃ i, mk (f i) (_ : AEMeasurable (f i)) b = a} = {a | ∃ i, f i b = a}
⊢ IsLUB {a | ∃ i, mk (f i) (_ : AEMeasurable (f i)) b = a} (g b)

tactic: exact aeSeq.fun_prop_of_mem_aeSeqSet hf h
state_before: case inl
α : Type u_3
β : Type ?u.1096180
γ : Type ?u.1096183
γ₂ : Type ?u.1096186
δ : Type u_2
ι✝ : Sort y
s t u : Set α
inst✝¹³ : TopologicalSpace α
inst✝¹² : MeasurableSpace α
inst✝¹¹ : BorelSpace α
inst✝¹⁰ : TopologicalSpace β
inst✝⁹ : MeasurableSpace β
inst✝⁸ : BorelSpace β
inst✝⁷ : TopologicalSpace γ
inst✝⁶ : MeasurableSpace γ
inst✝⁵ : BorelSpace γ
inst✝⁴ : MeasurableSpace δ
inst✝³ : LinearOrder α
inst✝² : OrderTopology α
inst✝¹ : SecondCountableTopology α
ι : Sort u_1
hι : Nonempty ι
μ : MeasureTheory.Measure δ
inst✝ : Countable ι
f : ι → δ → α
g : δ → α
hf : ∀ (i : ι), AEMeasurable (f i)
hg : ∀ᵐ (b : δ) ∂μ, IsLUB {a | ∃ i, f i b = a} (g b)
p : δ → (ι → α) → Prop := fun x f' => IsLUB {a | ∃ i, f' i = a} (g x)
g_seq : δ → α := fun x => if x ∈ aeSeqSet hf p then g x else Nonempty.some (_ : Nonempty α)
b : δ
hα : Nonempty α
h : b ∈ aeSeqSet hf fun x f' => IsLUB {a | ∃ i, f' i = a} (g x)
h_set_eq : {a | ∃ i, mk (f i) (_ : AEMeasurable (f i)) b = a} = {a | ∃ i, f i b = a}
⊢ IsLUB {a | ∃ i, f i b = a} (g b)

tactic: ext x
state_before: α : Type u_3
β : Type ?u.1096180
γ : Type ?u.1096183
γ₂ : Type ?u.1096186
δ : Type u_2
ι✝ : Sort y
s t u : Set α
inst✝¹³ : TopologicalSpace α
inst✝¹² : MeasurableSpace α
inst✝¹¹ : BorelSpace α
inst✝¹⁰ : TopologicalSpace β
inst✝⁹ : MeasurableSpace β
inst✝⁸ : BorelSpace β
inst✝⁷ : TopologicalSpace γ
inst✝⁶ : MeasurableSpace γ
inst✝⁵ : BorelSpace γ
inst✝⁴ : MeasurableSpace δ
inst✝³ : LinearOrder α
inst✝² : OrderTopology α
inst✝¹ : SecondCountableTopology α
ι : Sort u_1
hι : Nonempty ι
μ : MeasureTheory.Measure δ
inst✝ : Countable ι
f : ι → δ → α
g : δ → α
hf : ∀ (i : ι), AEMeasurable (f i)
hg : ∀ᵐ (b : δ) ∂μ, IsLUB {a | ∃ i, f i b = a} (g b)
p : δ → (ι → α) → Prop := fun x f' => IsLUB {a | ∃ i, f' i = a} (g x)
g_seq : δ → α := fun x => if x ∈ aeSeqSet hf p then g x else Nonempty.some (_ : Nonempty α)
b : δ
hα : Nonempty α
h : b ∈ aeSeqSet hf fun x f' => IsLUB {a | ∃ i, f' i = a} (g x)
⊢ {a | ∃ i, mk (f i) (_ : AEMeasurable (f i)) b = a} = {a | ∃ i, f i b = a}

tactic: simp_rw [Set.mem_setOf_eq, aeSeq.mk_eq_fun_of_mem_aeSeqSet hf h]
state_before: case h
α : Type u_3
β : Type ?u.1096180
γ : Type ?u.1096183
γ₂ : Type ?u.1096186
δ : Type u_2
ι✝ : Sort y
s t u : Set α
inst✝¹³ : TopologicalSpace α
inst✝¹² : MeasurableSpace α
inst✝¹¹ : BorelSpace α
inst✝¹⁰ : TopologicalSpace β
inst✝⁹ : MeasurableSpace β
inst✝⁸ : BorelSpace β
inst✝⁷ : TopologicalSpace γ
inst✝⁶ : MeasurableSpace γ
inst✝⁵ : BorelSpace γ
inst✝⁴ : MeasurableSpace δ
inst✝³ : LinearOrder α
inst✝² : OrderTopology α
inst✝¹ : SecondCountableTopology α
ι : Sort u_1
hι : Nonempty ι
μ : MeasureTheory.Measure δ
inst✝ : Countable ι
f : ι → δ → α
g : δ → α
hf : ∀ (i : ι), AEMeasurable (f i)
hg : ∀ᵐ (b : δ) ∂μ, IsLUB {a | ∃ i, f i b = a} (g b)
p : δ → (ι → α) → Prop := fun x f' => IsLUB {a | ∃ i, f' i = a} (g x)
g_seq : δ → α := fun x => if x ∈ aeSeqSet hf p then g x else Nonempty.some (_ : Nonempty α)
b : δ
hα : Nonempty α
h : b ∈ aeSeqSet hf fun x f' => IsLUB {a | ∃ i, f' i = a} (g x)
x : α
⊢ x ∈ {a | ∃ i, mk (f i) (_ : AEMeasurable (f i)) b = a} ↔ x ∈ {a | ∃ i, f i b = a}

tactic: have h_singleton : { a : α | ∃ _ : ι, hα.some = a } = {hα.some} := by
  ext1 x
  exact ⟨fun hx => hx.choose_spec.symm, fun hx => ⟨hι.some, hx.symm⟩⟩
state_before: case inr
α : Type u_3
β : Type ?u.1096180
γ : Type ?u.1096183
γ₂ : Type ?u.1096186
δ : Type u_2
ι✝ : Sort y
s t u : Set α
inst✝¹³ : TopologicalSpace α
inst✝¹² : MeasurableSpace α
inst✝¹¹ : BorelSpace α
inst✝¹⁰ : TopologicalSpace β
inst✝⁹ : MeasurableSpace β
inst✝⁸ : BorelSpace β
inst✝⁷ : TopologicalSpace γ
inst✝⁶ : MeasurableSpace γ
inst✝⁵ : BorelSpace γ
inst✝⁴ : MeasurableSpace δ
inst✝³ : LinearOrder α
inst✝² : OrderTopology α
inst✝¹ : SecondCountableTopology α
ι : Sort u_1
hι : Nonempty ι
μ : MeasureTheory.Measure δ
inst✝ : Countable ι
f : ι → δ → α
g : δ → α
hf : ∀ (i : ι), AEMeasurable (f i)
hg : ∀ᵐ (b : δ) ∂μ, IsLUB {a | ∃ i, f i b = a} (g b)
p : δ → (ι → α) → Prop := fun x f' => IsLUB {a | ∃ i, f' i = a} (g x)
g_seq : δ → α := fun x => if x ∈ aeSeqSet hf p then g x else Nonempty.some (_ : Nonempty α)
b : δ
hα : Nonempty α
h : ¬b ∈ aeSeqSet hf fun x f' => IsLUB {a | ∃ i, f' i = a} (g x)
⊢ IsLUB {a | ∃ i, Nonempty.some (_ : Nonempty α) = a} (Nonempty.some (_ : Nonempty α))

tactic: rw [h_singleton]
state_before: case inr
α : Type u_3
β : Type ?u.1096180
γ : Type ?u.1096183
γ₂ : Type ?u.1096186
δ : Type u_2
ι✝ : Sort y
s t u : Set α
inst✝¹³ : TopologicalSpace α
inst✝¹² : MeasurableSpace α
inst✝¹¹ : BorelSpace α
inst✝¹⁰ : TopologicalSpace β
inst✝⁹ : MeasurableSpace β
inst✝⁸ : BorelSpace β
inst✝⁷ : TopologicalSpace γ
inst✝⁶ : MeasurableSpace γ
inst✝⁵ : BorelSpace γ
inst✝⁴ : MeasurableSpace δ
inst✝³ : LinearOrder α
inst✝² : OrderTopology α
inst✝¹ : SecondCountableTopology α
ι : Sort u_1
hι : Nonempty ι
μ : MeasureTheory.Measure δ
inst✝ : Countable ι
f : ι → δ → α
g : δ → α
hf : ∀ (i : ι), AEMeasurable (f i)
hg : ∀ᵐ (b : δ) ∂μ, IsLUB {a | ∃ i, f i b = a} (g b)
p : δ → (ι → α) → Prop := fun x f' => IsLUB {a | ∃ i, f' i = a} (g x)
g_seq : δ → α := fun x => if x ∈ aeSeqSet hf p then g x else Nonempty.some (_ : Nonempty α)
b : δ
hα : Nonempty α
h : ¬b ∈ aeSeqSet hf fun x f' => IsLUB {a | ∃ i, f' i = a} (g x)
h_singleton : {a | ∃ x, Nonempty.some hα = a} = {Nonempty.some hα}
⊢ IsLUB {a | ∃ i, Nonempty.some (_ : Nonempty α) = a} (Nonempty.some (_ : Nonempty α))

tactic: exact isLUB_singleton
state_before: case inr
α : Type u_3
β : Type ?u.1096180
γ : Type ?u.1096183
γ₂ : Type ?u.1096186
δ : Type u_2
ι✝ : Sort y
s t u : Set α
inst✝¹³ : TopologicalSpace α
inst✝¹² : MeasurableSpace α
inst✝¹¹ : BorelSpace α
inst✝¹⁰ : TopologicalSpace β
inst✝⁹ : MeasurableSpace β
inst✝⁸ : BorelSpace β
inst✝⁷ : TopologicalSpace γ
inst✝⁶ : MeasurableSpace γ
inst✝⁵ : BorelSpace γ
inst✝⁴ : MeasurableSpace δ
inst✝³ : LinearOrder α
inst✝² : OrderTopology α
inst✝¹ : SecondCountableTopology α
ι : Sort u_1
hι : Nonempty ι
μ : MeasureTheory.Measure δ
inst✝ : Countable ι
f : ι → δ → α
g : δ → α
hf : ∀ (i : ι), AEMeasurable (f i)
hg : ∀ᵐ (b : δ) ∂μ, IsLUB {a | ∃ i, f i b = a} (g b)
p : δ → (ι → α) → Prop := fun x f' => IsLUB {a | ∃ i, f' i = a} (g x)
g_seq : δ → α := fun x => if x ∈ aeSeqSet hf p then g x else Nonempty.some (_ : Nonempty α)
b : δ
hα : Nonempty α
h : ¬b ∈ aeSeqSet hf fun x f' => IsLUB {a | ∃ i, f' i = a} (g x)
h_singleton : {a | ∃ x, Nonempty.some hα = a} = {Nonempty.some hα}
⊢ IsLUB {Nonempty.some hα} (Nonempty.some (_ : Nonempty α))

tactic: ext1 x
state_before: α : Type u_3
β : Type ?u.1096180
γ : Type ?u.1096183
γ₂ : Type ?u.1096186
δ : Type u_2
ι✝ : Sort y
s t u : Set α
inst✝¹³ : TopologicalSpace α
inst✝¹² : MeasurableSpace α
inst✝¹¹ : BorelSpace α
inst✝¹⁰ : TopologicalSpace β
inst✝⁹ : MeasurableSpace β
inst✝⁸ : BorelSpace β
inst✝⁷ : TopologicalSpace γ
inst✝⁶ : MeasurableSpace γ
inst✝⁵ : BorelSpace γ
inst✝⁴ : MeasurableSpace δ
inst✝³ : LinearOrder α
inst✝² : OrderTopology α
inst✝¹ : SecondCountableTopology α
ι : Sort u_1
hι : Nonempty ι
μ : MeasureTheory.Measure δ
inst✝ : Countable ι
f : ι → δ → α
g : δ → α
hf : ∀ (i : ι), AEMeasurable (f i)
hg : ∀ᵐ (b : δ) ∂μ, IsLUB {a | ∃ i, f i b = a} (g b)
p : δ → (ι → α) → Prop := fun x f' => IsLUB {a | ∃ i, f' i = a} (g x)
g_seq : δ → α := fun x => if x ∈ aeSeqSet hf p then g x else Nonempty.some (_ : Nonempty α)
b : δ
hα : Nonempty α
h : ¬b ∈ aeSeqSet hf fun x f' => IsLUB {a | ∃ i, f' i = a} (g x)
⊢ {a | ∃ x, Nonempty.some hα = a} = {Nonempty.some hα}

tactic: exact ⟨fun hx => hx.choose_spec.symm, fun hx => ⟨hι.some, hx.symm⟩⟩
state_before: case h
α : Type u_3
β : Type ?u.1096180
γ : Type ?u.1096183
γ₂ : Type ?u.1096186
δ : Type u_2
ι✝ : Sort y
s t u : Set α
inst✝¹³ : TopologicalSpace α
inst✝¹² : MeasurableSpace α
inst✝¹¹ : BorelSpace α
inst✝¹⁰ : TopologicalSpace β
inst✝⁹ : MeasurableSpace β
inst✝⁸ : BorelSpace β
inst✝⁷ : TopologicalSpace γ
inst✝⁶ : MeasurableSpace γ
inst✝⁵ : BorelSpace γ
inst✝⁴ : MeasurableSpace δ
inst✝³ : LinearOrder α
inst✝² : OrderTopology α
inst✝¹ : SecondCountableTopology α
ι : Sort u_1
hι : Nonempty ι
μ : MeasureTheory.Measure δ
inst✝ : Countable ι
f : ι → δ → α
g : δ → α
hf : ∀ (i : ι), AEMeasurable (f i)
hg : ∀ᵐ (b : δ) ∂μ, IsLUB {a | ∃ i, f i b = a} (g b)
p : δ → (ι → α) → Prop := fun x f' => IsLUB {a | ∃ i, f' i = a} (g x)
g_seq : δ → α := fun x => if x ∈ aeSeqSet hf p then g x else Nonempty.some (_ : Nonempty α)
b : δ
hα : Nonempty α
h : ¬b ∈ aeSeqSet hf fun x f' => IsLUB {a | ∃ i, f' i = a} (g x)
x : α
⊢ x ∈ {a | ∃ x, Nonempty.some hα = a} ↔ x ∈ {Nonempty.some hα}