Theorem: MeasureTheory.exists_lt_lintegral_simpleFunc_of_lt_lintegral
File: Mathlib/MeasureTheory/Integral/Lebesgue.lean

tactic: simp_rw [lintegral_eq_nnreal, lt_iSup_iff] at hL
state_before: α : Type u_1
β : Type ?u.1845716
γ : Type ?u.1845719
δ : Type ?u.1845722
m✝ m0 : MeasurableSpace α
E : Type ?u.1845731
inst✝³ : NormedAddCommGroup E
inst✝² : MeasurableSpace E
inst✝¹ : OpensMeasurableSpace E
m : MeasurableSpace α
μ : Measure α
inst✝ : SigmaFinite μ
f : α → ℝ≥0
L : ℝ≥0∞
hL : L < ∫⁻ (x : α), ↑(f x) ∂μ
⊢ ∃ g, (∀ (x : α), ↑g x ≤ f x) ∧ (∫⁻ (x : α), ↑(↑g x) ∂μ) < ⊤ ∧ L < ∫⁻ (x : α), ↑(↑g x) ∂μ

tactic: rcases hL with ⟨g₀, hg₀, g₀L⟩
state_before: α : Type u_1
β : Type ?u.1845716
γ : Type ?u.1845719
δ : Type ?u.1845722
m✝ m0 : MeasurableSpace α
E : Type ?u.1845731
inst✝³ : NormedAddCommGroup E
inst✝² : MeasurableSpace E
inst✝¹ : OpensMeasurableSpace E
m : MeasurableSpace α
μ : Measure α
inst✝ : SigmaFinite μ
f : α → ℝ≥0
L : ℝ≥0∞
hL : ∃ i i_1, L < SimpleFunc.lintegral (SimpleFunc.map ENNReal.some i) μ
⊢ ∃ g, (∀ (x : α), ↑g x ≤ f x) ∧ (∫⁻ (x : α), ↑(↑g x) ∂μ) < ⊤ ∧ L < ∫⁻ (x : α), ↑(↑g x) ∂μ

tactic: have h'L : L < ∫⁻ x, g₀ x ∂μ := by
  convert g₀L
  rw [← SimpleFunc.lintegral_eq_lintegral]
  rfl
state_before: case intro.intro
α : Type u_1
β : Type ?u.1845716
γ : Type ?u.1845719
δ : Type ?u.1845722
m✝ m0 : MeasurableSpace α
E : Type ?u.1845731
inst✝³ : NormedAddCommGroup E
inst✝² : MeasurableSpace E
inst✝¹ : OpensMeasurableSpace E
m : MeasurableSpace α
μ : Measure α
inst✝ : SigmaFinite μ
f : α → ℝ≥0
L : ℝ≥0∞
g₀ : α →ₛ ℝ≥0
hg₀ : ∀ (x : α), ↑(↑g₀ x) ≤ ↑(f x)
g₀L : L < SimpleFunc.lintegral (SimpleFunc.map ENNReal.some g₀) μ
⊢ ∃ g, (∀ (x : α), ↑g x ≤ f x) ∧ (∫⁻ (x : α), ↑(↑g x) ∂μ) < ⊤ ∧ L < ∫⁻ (x : α), ↑(↑g x) ∂μ

tactic: rcases SimpleFunc.exists_lt_lintegral_simpleFunc_of_lt_lintegral h'L with ⟨g, hg, gL, gtop⟩
state_before: case intro.intro
α : Type u_1
β : Type ?u.1845716
γ : Type ?u.1845719
δ : Type ?u.1845722
m✝ m0 : MeasurableSpace α
E : Type ?u.1845731
inst✝³ : NormedAddCommGroup E
inst✝² : MeasurableSpace E
inst✝¹ : OpensMeasurableSpace E
m : MeasurableSpace α
μ : Measure α
inst✝ : SigmaFinite μ
f : α → ℝ≥0
L : ℝ≥0∞
g₀ : α →ₛ ℝ≥0
hg₀ : ∀ (x : α), ↑(↑g₀ x) ≤ ↑(f x)
g₀L : L < SimpleFunc.lintegral (SimpleFunc.map ENNReal.some g₀) μ
h'L : L < ∫⁻ (x : α), ↑(↑g₀ x) ∂μ
⊢ ∃ g, (∀ (x : α), ↑g x ≤ f x) ∧ (∫⁻ (x : α), ↑(↑g x) ∂μ) < ⊤ ∧ L < ∫⁻ (x : α), ↑(↑g x) ∂μ

tactic: exact ⟨g, fun x => (hg x).trans (coe_le_coe.1 (hg₀ x)), gL, gtop⟩
state_before: case intro.intro.intro.intro.intro
α : Type u_1
β : Type ?u.1845716
γ : Type ?u.1845719
δ : Type ?u.1845722
m✝ m0 : MeasurableSpace α
E : Type ?u.1845731
inst✝³ : NormedAddCommGroup E
inst✝² : MeasurableSpace E
inst✝¹ : OpensMeasurableSpace E
m : MeasurableSpace α
μ : Measure α
inst✝ : SigmaFinite μ
f : α → ℝ≥0
L : ℝ≥0∞
g₀ : α →ₛ ℝ≥0
hg₀ : ∀ (x : α), ↑(↑g₀ x) ≤ ↑(f x)
g₀L : L < SimpleFunc.lintegral (SimpleFunc.map ENNReal.some g₀) μ
h'L : L < ∫⁻ (x : α), ↑(↑g₀ x) ∂μ
g : α →ₛ ℝ≥0
hg : ∀ (x : α), ↑g x ≤ ↑g₀ x
gL : (∫⁻ (x : α), ↑(↑g x) ∂μ) < ⊤
gtop : L < ∫⁻ (x : α), ↑(↑g x) ∂μ
⊢ ∃ g, (∀ (x : α), ↑g x ≤ f x) ∧ (∫⁻ (x : α), ↑(↑g x) ∂μ) < ⊤ ∧ L < ∫⁻ (x : α), ↑(↑g x) ∂μ

tactic: convert g₀L
state_before: α : Type u_1
β : Type ?u.1845716
γ : Type ?u.1845719
δ : Type ?u.1845722
m✝ m0 : MeasurableSpace α
E : Type ?u.1845731
inst✝³ : NormedAddCommGroup E
inst✝² : MeasurableSpace E
inst✝¹ : OpensMeasurableSpace E
m : MeasurableSpace α
μ : Measure α
inst✝ : SigmaFinite μ
f : α → ℝ≥0
L : ℝ≥0∞
g₀ : α →ₛ ℝ≥0
hg₀ : ∀ (x : α), ↑(↑g₀ x) ≤ ↑(f x)
g₀L : L < SimpleFunc.lintegral (SimpleFunc.map ENNReal.some g₀) μ
⊢ L < ∫⁻ (x : α), ↑(↑g₀ x) ∂μ

tactic: rw [← SimpleFunc.lintegral_eq_lintegral]
state_before: case h.e'_4
α : Type u_1
β : Type ?u.1845716
γ : Type ?u.1845719
δ : Type ?u.1845722
m✝ m0 : MeasurableSpace α
E : Type ?u.1845731
inst✝³ : NormedAddCommGroup E
inst✝² : MeasurableSpace E
inst✝¹ : OpensMeasurableSpace E
m : MeasurableSpace α
μ : Measure α
inst✝ : SigmaFinite μ
f : α → ℝ≥0
L : ℝ≥0∞
g₀ : α →ₛ ℝ≥0
hg₀ : ∀ (x : α), ↑(↑g₀ x) ≤ ↑(f x)
g₀L : L < SimpleFunc.lintegral (SimpleFunc.map ENNReal.some g₀) μ
⊢ (∫⁻ (x : α), ↑(↑g₀ x) ∂μ) = SimpleFunc.lintegral (SimpleFunc.map ENNReal.some g₀) μ

tactic: rfl
state_before: case h.e'_4
α : Type u_1
β : Type ?u.1845716
γ : Type ?u.1845719
δ : Type ?u.1845722
m✝ m0 : MeasurableSpace α
E : Type ?u.1845731
inst✝³ : NormedAddCommGroup E
inst✝² : MeasurableSpace E
inst✝¹ : OpensMeasurableSpace E
m : MeasurableSpace α
μ : Measure α
inst✝ : SigmaFinite μ
f : α → ℝ≥0
L : ℝ≥0∞
g₀ : α →ₛ ℝ≥0
hg₀ : ∀ (x : α), ↑(↑g₀ x) ≤ ↑(f x)
g₀L : L < SimpleFunc.lintegral (SimpleFunc.map ENNReal.some g₀) μ
⊢ (∫⁻ (x : α), ↑(↑g₀ x) ∂μ) = ∫⁻ (a : α), ↑(SimpleFunc.map ENNReal.some g₀) a ∂μ