l3lab/ntp-mathlib huggingface dataset:
/-- If a function is integrable on a set `s`, and vanishes on `t \ s`, then it is integrable on `t`
if `t` is null-measurable. -/
theorem IntegrableOn.of_ae_diff_eq_zero (hf : IntegrableOn f s μ) (ht : NullMeasurableSet t μ)
    (h't : ∀ᵐ x ∂μ, x ∈ t \ s → f x = 0) : IntegrableOn f t μ := by
  let u := { x ∈ s | f x ≠ 0 }
  have hu : IntegrableOn f u μ := hf.mono_set fun x hx => hx.1
  let v := toMeasurable μ u
  have A : IntegrableOn f v μ := by
    rw [IntegrableOn, hu.restrict_toMeasurable]
    · exact hu
    · intro x hx; exact hx.2
  have B : IntegrableOn f (t \ v) μ := by
    apply integrableOn_zero.congr
    filter_upwards [ae_restrict_of_ae h't,
      ae_restrict_mem₀ (ht.diff (measurableSet_toMeasurable μ u).nullMeasurableSet)] with x hxt hx
    by_cases h'x : x ∈ s
    · 

Proof state:
case pos
α : Type u_1
β : Type u_2
E : Type u_3
F : Type u_4
inst✝¹ : MeasurableSpace α
inst✝ : NormedAddCommGroup E
f g : α → E
s t : Set α
μ ν : Measure α
hf : IntegrableOn f s
ht : NullMeasurableSet t
h't : ∀ᵐ (x : α) ∂μ, x ∈ t \ s → f x = 0
u : Set α := {x | x ∈ s ∧ f x ≠ 0}
hu : IntegrableOn f u
v : Set α := toMeasurable μ u
A : IntegrableOn f v
x : α
hxt : x ∈ t \ s → f x = 0
hx : x ∈ t \ v
h'x : x ∈ s
⊢ 0 = f x

Next tactic:
by_contra H
/-- If a function is integrable on a set `s`, and vanishes on `t \ s`, then it is integrable on `t`
if `t` is null-measurable. -/
theorem IntegrableOn.of_ae_diff_eq_zero (hf : IntegrableOn f s μ) (ht : NullMeasurableSet t μ)
    (h't : ∀ᵐ x ∂μ, x ∈ t \ s → f x = 0) : IntegrableOn f t μ := by
  let u := { x ∈ s | f x ≠ 0 }
  have hu : IntegrableOn f u μ := hf.mono_set fun x hx => hx.1
  let v := toMeasurable μ u
  have A : IntegrableOn f v μ := by
    rw [IntegrableOn, hu.restrict_toMeasurable]
    · exact hu
    · intro x hx; exact hx.2
  have B : IntegrableOn f (t \ v) μ := by
    apply integrableOn_zero.congr
    filter_upwards [ae_restrict_of_ae h't,
      ae_restrict_mem₀ (ht.diff (measurableSet_toMeasurable μ u).nullMeasurableSet)] with x hxt hx
    by_cases h'x : x ∈ s
    · by_contra H
      

Proof state:
case pos
α : Type u_1
β : Type u_2
E : Type u_3
F : Type u_4
inst✝¹ : MeasurableSpace α
inst✝ : NormedAddCommGroup E
f g : α → E
s t : Set α
μ ν : Measure α
hf : IntegrableOn f s
ht : NullMeasurableSet t
h't : ∀ᵐ (x : α) ∂μ, x ∈ t \ s → f x = 0
u : Set α := {x | x ∈ s ∧ f x ≠ 0}
hu : IntegrableOn f u
v : Set α := toMeasurable μ u
A : IntegrableOn f v
x : α
hxt : x ∈ t \ s → f x = 0
hx : x ∈ t \ v
h'x : x ∈ s
H : ¬0 = f x
⊢ False

Next tactic:
exact hx.2 (subset_toMeasurable μ u ⟨h'x, Ne.symm H⟩)
/-- If a function is integrable on a set `s`, and vanishes on `t \ s`, then it is integrable on `t`
if `t` is null-measurable. -/
theorem IntegrableOn.of_ae_diff_eq_zero (hf : IntegrableOn f s μ) (ht : NullMeasurableSet t μ)
    (h't : ∀ᵐ x ∂μ, x ∈ t \ s → f x = 0) : IntegrableOn f t μ := by
  let u := { x ∈ s | f x ≠ 0 }
  have hu : IntegrableOn f u μ := hf.mono_set fun x hx => hx.1
  let v := toMeasurable μ u
  have A : IntegrableOn f v μ := by
    rw [IntegrableOn, hu.restrict_toMeasurable]
    · exact hu
    · intro x hx; exact hx.2
  have B : IntegrableOn f (t \ v) μ := by
    apply integrableOn_zero.congr
    filter_upwards [ae_restrict_of_ae h't,
      ae_restrict_mem₀ (ht.diff (measurableSet_toMeasurable μ u).nullMeasurableSet)] with x hxt hx
    by_cases h'x : x ∈ s
    · by_contra H
      exact hx.2 (subset_toMeasurable μ u ⟨h'x, Ne.symm H⟩)
    · 

Proof state:
case neg
α : Type u_1
β : Type u_2
E : Type u_3
F : Type u_4
inst✝¹ : MeasurableSpace α
inst✝ : NormedAddCommGroup E
f g : α → E
s t : Set α
μ ν : Measure α
hf : IntegrableOn f s
ht : NullMeasurableSet t
h't : ∀ᵐ (x : α) ∂μ, x ∈ t \ s → f x = 0
u : Set α := {x | x ∈ s ∧ f x ≠ 0}
hu : IntegrableOn f u
v : Set α := toMeasurable μ u
A : IntegrableOn f v
x : α
hxt : x ∈ t \ s → f x = 0
hx : x ∈ t \ v
h'x : x ∉ s
⊢ 0 = f x

Next tactic:
exact (hxt ⟨hx.1, h'x⟩).symm
/-- If a function is integrable on a set `s`, and vanishes on `t \ s`, then it is integrable on `t`
if `t` is null-measurable. -/
theorem IntegrableOn.of_ae_diff_eq_zero (hf : IntegrableOn f s μ) (ht : NullMeasurableSet t μ)
    (h't : ∀ᵐ x ∂μ, x ∈ t \ s → f x = 0) : IntegrableOn f t μ := by
  let u := { x ∈ s | f x ≠ 0 }
  have hu : IntegrableOn f u μ := hf.mono_set fun x hx => hx.1
  let v := toMeasurable μ u
  have A : IntegrableOn f v μ := by
    rw [IntegrableOn, hu.restrict_toMeasurable]
    · exact hu
    · intro x hx; exact hx.2
  have B : IntegrableOn f (t \ v) μ := by
    apply integrableOn_zero.congr
    filter_upwards [ae_restrict_of_ae h't,
      ae_restrict_mem₀ (ht.diff (measurableSet_toMeasurable μ u).nullMeasurableSet)] with x hxt hx
    by_cases h'x : x ∈ s
    · by_contra H
      exact hx.2 (subset_toMeasurable μ u ⟨h'x, Ne.symm H⟩)
    · exact (hxt ⟨hx.1, h'x⟩).symm
  

Proof state:
α : Type u_1
β : Type u_2
E : Type u_3
F : Type u_4
inst✝¹ : MeasurableSpace α
inst✝ : NormedAddCommGroup E
f g : α → E
s t : Set α
μ ν : Measure α
hf : IntegrableOn f s
ht : NullMeasurableSet t
h't : ∀ᵐ (x : α) ∂μ, x ∈ t \ s → f x = 0
u : Set α := {x | x ∈ s ∧ f x ≠ 0}
hu : IntegrableOn f u
v : Set α := toMeasurable μ u
A : IntegrableOn f v
B : IntegrableOn f (t \ v)
⊢ IntegrableOn f t

Next tactic:
apply (A.union B).mono_set _
/-- If a function is integrable on a set `s`, and vanishes on `t \ s`, then it is integrable on `t`
if `t` is null-measurable. -/
theorem IntegrableOn.of_ae_diff_eq_zero (hf : IntegrableOn f s μ) (ht : NullMeasurableSet t μ)
    (h't : ∀ᵐ x ∂μ, x ∈ t \ s → f x = 0) : IntegrableOn f t μ := by
  let u := { x ∈ s | f x ≠ 0 }
  have hu : IntegrableOn f u μ := hf.mono_set fun x hx => hx.1
  let v := toMeasurable μ u
  have A : IntegrableOn f v μ := by
    rw [IntegrableOn, hu.restrict_toMeasurable]
    · exact hu
    · intro x hx; exact hx.2
  have B : IntegrableOn f (t \ v) μ := by
    apply integrableOn_zero.congr
    filter_upwards [ae_restrict_of_ae h't,
      ae_restrict_mem₀ (ht.diff (measurableSet_toMeasurable μ u).nullMeasurableSet)] with x hxt hx
    by_cases h'x : x ∈ s
    · by_contra H
      exact hx.2 (subset_toMeasurable μ u ⟨h'x, Ne.symm H⟩)
    · exact (hxt ⟨hx.1, h'x⟩).symm
  apply (A.union B).mono_set _
  

Proof state:
α : Type u_1
β : Type u_2
E : Type u_3
F : Type u_4
inst✝¹ : MeasurableSpace α
inst✝ : NormedAddCommGroup E
f g : α → E
s t : Set α
μ ν : Measure α
hf : IntegrableOn f s
ht : NullMeasurableSet t
h't : ∀ᵐ (x : α) ∂μ, x ∈ t \ s → f x = 0
u : Set α := {x | x ∈ s ∧ f x ≠ 0}
hu : IntegrableOn f u
v : Set α := toMeasurable μ u
A : IntegrableOn f v
B : IntegrableOn f (t \ v)
⊢ t ⊆ v ∪ t \ v

Next tactic:
rw [union_diff_self]
/-- If a function is integrable on a set `s`, and vanishes on `t \ s`, then it is integrable on `t`
if `t` is null-measurable. -/
theorem IntegrableOn.of_ae_diff_eq_zero (hf : IntegrableOn f s μ) (ht : NullMeasurableSet t μ)
    (h't : ∀ᵐ x ∂μ, x ∈ t \ s → f x = 0) : IntegrableOn f t μ := by
  let u := { x ∈ s | f x ≠ 0 }
  have hu : IntegrableOn f u μ := hf.mono_set fun x hx => hx.1
  let v := toMeasurable μ u
  have A : IntegrableOn f v μ := by
    rw [IntegrableOn, hu.restrict_toMeasurable]
    · exact hu
    · intro x hx; exact hx.2
  have B : IntegrableOn f (t \ v) μ := by
    apply integrableOn_zero.congr
    filter_upwards [ae_restrict_of_ae h't,
      ae_restrict_mem₀ (ht.diff (measurableSet_toMeasurable μ u).nullMeasurableSet)] with x hxt hx
    by_cases h'x : x ∈ s
    · by_contra H
      exact hx.2 (subset_toMeasurable μ u ⟨h'x, Ne.symm H⟩)
    · exact (hxt ⟨hx.1, h'x⟩).symm
  apply (A.union B).mono_set _
  rw [union_diff_self]
  

Proof state:
α : Type u_1
β : Type u_2
E : Type u_3
F : Type u_4
inst✝¹ : MeasurableSpace α
inst✝ : NormedAddCommGroup E
f g : α → E
s t : Set α
μ ν : Measure α
hf : IntegrableOn f s
ht : NullMeasurableSet t
h't : ∀ᵐ (x : α) ∂μ, x ∈ t \ s → f x = 0
u : Set α := {x | x ∈ s ∧ f x ≠ 0}
hu : IntegrableOn f u
v : Set α := toMeasurable μ u
A : IntegrableOn f v
B : IntegrableOn f (t \ v)
⊢ t ⊆ v ∪ t

Next tactic:
exact subset_union_right _ _
/-- If a function is integrable on a set `s` and vanishes almost everywhere on its complement,
then it is integrable. -/
theorem IntegrableOn.integrable_of_ae_not_mem_eq_zero (hf : IntegrableOn f s μ)
    (h't : ∀ᵐ x ∂μ, x ∉ s → f x = 0) : Integrable f μ := by
  

Proof state:
α : Type u_1
β : Type u_2
E : Type u_3
F : Type u_4
inst✝¹ : MeasurableSpace α
inst✝ : NormedAddCommGroup E
f g : α → E
s t : Set α
μ ν : Measure α
hf : IntegrableOn f s
h't : ∀ᵐ (x : α) ∂μ, x ∉ s → f x = 0
⊢ Integrable f

Next tactic:
rw [← integrableOn_univ]
/-- If a function is integrable on a set `s` and vanishes almost everywhere on its complement,
then it is integrable. -/
theorem IntegrableOn.integrable_of_ae_not_mem_eq_zero (hf : IntegrableOn f s μ)
    (h't : ∀ᵐ x ∂μ, x ∉ s → f x = 0) : Integrable f μ := by
  rw [← integrableOn_univ]
  

Proof state:
α : Type u_1
β : Type u_2
E : Type u_3
F : Type u_4
inst✝¹ : MeasurableSpace α
inst✝ : NormedAddCommGroup E
f g : α → E
s t : Set α
μ ν : Measure α
hf : IntegrableOn f s
h't : ∀ᵐ (x : α) ∂μ, x ∉ s → f x = 0
⊢ IntegrableOn f univ

Next tactic:
apply hf.of_ae_diff_eq_zero nullMeasurableSet_univ
/-- If a function is integrable on a set `s` and vanishes almost everywhere on its complement,
then it is integrable. -/
theorem IntegrableOn.integrable_of_ae_not_mem_eq_zero (hf : IntegrableOn f s μ)
    (h't : ∀ᵐ x ∂μ, x ∉ s → f x = 0) : Integrable f μ := by
  rw [← integrableOn_univ]
  apply hf.of_ae_diff_eq_zero nullMeasurableSet_univ
  

Proof state:
α : Type u_1
β : Type u_2
E : Type u_3
F : Type u_4
inst✝¹ : MeasurableSpace α
inst✝ : NormedAddCommGroup E
f g : α → E
s t : Set α
μ ν : Measure α
hf : IntegrableOn f s
h't : ∀ᵐ (x : α) ∂μ, x ∉ s → f x = 0
⊢ ∀ᵐ (x : α) ∂μ, x ∈ univ \ s → f x = 0

Next tactic:
filter_upwards [h't] with x hx h'x using hx h'x.2
theorem integrableOn_iff_integrable_of_support_subset (h1s : support f ⊆ s) :
    IntegrableOn f s μ ↔ Integrable f μ := by
  

Proof state:
α : Type u_1
β : Type u_2
E : Type u_3
F : Type u_4
inst✝¹ : MeasurableSpace α
inst✝ : NormedAddCommGroup E
f g : α → E
s t : Set α
μ ν : Measure α
h1s : support f ⊆ s
⊢ IntegrableOn f s ↔ Integrable f

Next tactic:
refine' ⟨fun h => _, fun h => h.integrableOn⟩
theorem integrableOn_iff_integrable_of_support_subset (h1s : support f ⊆ s) :
    IntegrableOn f s μ ↔ Integrable f μ := by
  refine' ⟨fun h => _, fun h => h.integrableOn⟩
  

Proof state:
α : Type u_1
β : Type u_2
E : Type u_3
F : Type u_4
inst✝¹ : MeasurableSpace α
inst✝ : NormedAddCommGroup E
f g : α → E
s t : Set α
μ ν : Measure α
h1s : support f ⊆ s
h : IntegrableOn f s
⊢ Integrable f

Next tactic:
refine h.integrable_of_forall_not_mem_eq_zero fun x hx => ?_
theorem integrableOn_iff_integrable_of_support_subset (h1s : support f ⊆ s) :
    IntegrableOn f s μ ↔ Integrable f μ := by
  refine' ⟨fun h => _, fun h => h.integrableOn⟩
  refine h.integrable_of_forall_not_mem_eq_zero fun x hx => ?_
  

Proof state:
α : Type u_1
β : Type u_2
E : Type u_3
F : Type u_4
inst✝¹ : MeasurableSpace α
inst✝ : NormedAddCommGroup E
f g : α → E
s t : Set α
μ ν : Measure α
h1s : support f ⊆ s
h : IntegrableOn f s
x : α
hx : x ∉ s
⊢ f x = 0

Next tactic:
contrapose! hx
theorem integrableOn_iff_integrable_of_support_subset (h1s : support f ⊆ s) :
    IntegrableOn f s μ ↔ Integrable f μ := by
  refine' ⟨fun h => _, fun h => h.integrableOn⟩
  refine h.integrable_of_forall_not_mem_eq_zero fun x hx => ?_
  contrapose! hx
  

Proof state:
α : Type u_1
β : Type u_2
E : Type u_3
F : Type u_4
inst✝¹ : MeasurableSpace α
inst✝ : NormedAddCommGroup E
f g : α → E
s t : Set α
μ ν : Measure α
h1s : support f ⊆ s
h : IntegrableOn f s
x : α
hx : f x ≠ 0
⊢ x ∈ s

Next tactic:
exact h1s (mem_support.2 hx)
theorem integrableOn_Lp_of_measure_ne_top {E} [NormedAddCommGroup E] {p : ℝ≥0∞} {s : Set α}
    (f : Lp E p μ) (hp : 1 ≤ p) (hμs : μ s ≠ ∞) : IntegrableOn f s μ := by
  

Proof state:
α : Type u_1
β : Type u_2
E✝ : Type u_3
F : Type u_4
inst✝² : MeasurableSpace α
inst✝¹ : NormedAddCommGroup E✝
f✝ g : α → E✝
s✝ t : Set α
μ ν : Measure α
E : Type u_5
inst✝ : NormedAddCommGroup E
p : ℝ≥0∞
s : Set α
f : ↥(Lp E p)
hp : 1 ≤ p
hμs : ↑↑μ s ≠ ⊤
⊢ IntegrableOn (↑↑f) s

Next tactic:
refine' memℒp_one_iff_integrable.mp _
theorem integrableOn_Lp_of_measure_ne_top {E} [NormedAddCommGroup E] {p : ℝ≥0∞} {s : Set α}
    (f : Lp E p μ) (hp : 1 ≤ p) (hμs : μ s ≠ ∞) : IntegrableOn f s μ := by
  refine' memℒp_one_iff_integrable.mp _
  

Proof state:
α : Type u_1
β : Type u_2
E✝ : Type u_3
F : Type u_4
inst✝² : MeasurableSpace α
inst✝¹ : NormedAddCommGroup E✝
f✝ g : α → E✝
s✝ t : Set α
μ ν : Measure α
E : Type u_5
inst✝ : NormedAddCommGroup E
p : ℝ≥0∞
s : Set α
f : ↥(Lp E p)
hp : 1 ≤ p
hμs : ↑↑μ s ≠ ⊤
⊢ Memℒp (↑↑f) 1

Next tactic:
have hμ_restrict_univ : (μ.restrict s) Set.univ < ∞ := by
    simpa only [Set.univ_inter, MeasurableSet.univ, Measure.restrict_apply, lt_top_iff_ne_top]
theorem integrableOn_Lp_of_measure_ne_top {E} [NormedAddCommGroup E] {p : ℝ≥0∞} {s : Set α}
    (f : Lp E p μ) (hp : 1 ≤ p) (hμs : μ s ≠ ∞) : IntegrableOn f s μ := by
  refine' memℒp_one_iff_integrable.mp _
  have hμ_restrict_univ : (μ.restrict s) Set.univ < ∞ := by
    

Proof state:
α : Type u_1
β : Type u_2
E✝ : Type u_3
F : Type u_4
inst✝² : MeasurableSpace α
inst✝¹ : NormedAddCommGroup E✝
f✝ g : α → E✝
s✝ t : Set α
μ ν : Measure α
E : Type u_5
inst✝ : NormedAddCommGroup E
p : ℝ≥0∞
s : Set α
f : ↥(Lp E p)
hp : 1 ≤ p
hμs : ↑↑μ s ≠ ⊤
⊢ ↑↑(Measure.restrict μ s) univ < ⊤

Next tactic:
simpa only [Set.univ_inter, MeasurableSet.univ, Measure.restrict_apply, lt_top_iff_ne_top]
theorem integrableOn_Lp_of_measure_ne_top {E} [NormedAddCommGroup E] {p : ℝ≥0∞} {s : Set α}
    (f : Lp E p μ) (hp : 1 ≤ p) (hμs : μ s ≠ ∞) : IntegrableOn f s μ := by
  refine' memℒp_one_iff_integrable.mp _
  have hμ_restrict_univ : (μ.restrict s) Set.univ < ∞ := by
    simpa only [Set.univ_inter, MeasurableSet.univ, Measure.restrict_apply, lt_top_iff_ne_top]
  

Proof state:
α : Type u_1
β : Type u_2
E✝ : Type u_3
F : Type u_4
inst✝² : MeasurableSpace α
inst✝¹ : NormedAddCommGroup E✝
f✝ g : α → E✝
s✝ t : Set α
μ ν : Measure α
E : Type u_5
inst✝ : NormedAddCommGroup E
p : ℝ≥0∞
s : Set α
f : ↥(Lp E p)
hp : 1 ≤ p
hμs : ↑↑μ s ≠ ⊤
hμ_restrict_univ : ↑↑(Measure.restrict μ s) univ < ⊤
⊢ Memℒp (↑↑f) 1

Next tactic:
haveI hμ_finite : IsFiniteMeasure (μ.restrict s) := ⟨hμ_restrict_univ⟩
theorem integrableOn_Lp_of_measure_ne_top {E} [NormedAddCommGroup E] {p : ℝ≥0∞} {s : Set α}
    (f : Lp E p μ) (hp : 1 ≤ p) (hμs : μ s ≠ ∞) : IntegrableOn f s μ := by
  refine' memℒp_one_iff_integrable.mp _
  have hμ_restrict_univ : (μ.restrict s) Set.univ < ∞ := by
    simpa only [Set.univ_inter, MeasurableSet.univ, Measure.restrict_apply, lt_top_iff_ne_top]
  haveI hμ_finite : IsFiniteMeasure (μ.restrict s) := ⟨hμ_restrict_univ⟩
  

Proof state:
α : Type u_1
β : Type u_2
E✝ : Type u_3
F : Type u_4
inst✝² : MeasurableSpace α
inst✝¹ : NormedAddCommGroup E✝
f✝ g : α → E✝
s✝ t : Set α
μ ν : Measure α
E : Type u_5
inst✝ : NormedAddCommGroup E
p : ℝ≥0∞
s : Set α
f : ↥(Lp E p)
hp : 1 ≤ p
hμs : ↑↑μ s ≠ ⊤
hμ_restrict_univ : ↑↑(Measure.restrict μ s) univ < ⊤
hμ_finite : IsFiniteMeasure (Measure.restrict μ s)
⊢ Memℒp (↑↑f) 1

Next tactic:
exact ((Lp.memℒp _).restrict s).memℒp_of_exponent_le hp
theorem _root_.MeasurableEmbedding.integrableAtFilter_map_iff [MeasurableSpace β] {e : α → β}
    (he : MeasurableEmbedding e) {f : β → E} :
    IntegrableAtFilter f (l.map e) (μ.map e) ↔ IntegrableAtFilter (f ∘ e) l μ := by
  

Proof state:
α : Type u_1
β : Type u_2
E : Type u_3
F : Type u_4
inst✝² : MeasurableSpace α
inst✝¹ : NormedAddCommGroup E
f✝ g : α → E
s t : Set α
μ ν : Measure α
l l' : Filter α
inst✝ : MeasurableSpace β
e : α → β
he : MeasurableEmbedding e
f : β → E
⊢ IntegrableAtFilter f (map e l) ↔ IntegrableAtFilter (f ∘ e) l

Next tactic:
simp_rw [IntegrableAtFilter, he.integrableOn_map_iff]
theorem _root_.MeasurableEmbedding.integrableAtFilter_map_iff [MeasurableSpace β] {e : α → β}
    (he : MeasurableEmbedding e) {f : β → E} :
    IntegrableAtFilter f (l.map e) (μ.map e) ↔ IntegrableAtFilter (f ∘ e) l μ := by
  simp_rw [IntegrableAtFilter, he.integrableOn_map_iff]
  

Proof state:
α : Type u_1
β : Type u_2
E : Type u_3
F : Type u_4
inst✝² : MeasurableSpace α
inst✝¹ : NormedAddCommGroup E
f✝ g : α → E
s t : Set α
μ ν : Measure α
l l' : Filter α
inst✝ : MeasurableSpace β
e : α → β
he : MeasurableEmbedding e
f : β → E
⊢ (∃ s ∈ map e l, IntegrableOn (f ∘ e) (e ⁻¹' s)) ↔ ∃ s ∈ l, IntegrableOn (f ∘ e) s

Next tactic:
constructor
theorem _root_.MeasurableEmbedding.integrableAtFilter_map_iff [MeasurableSpace β] {e : α → β}
    (he : MeasurableEmbedding e) {f : β → E} :
    IntegrableAtFilter f (l.map e) (μ.map e) ↔ IntegrableAtFilter (f ∘ e) l μ := by
  simp_rw [IntegrableAtFilter, he.integrableOn_map_iff]
  constructor <;> 

Proof state:
case mp
α : Type u_1
β : Type u_2
E : Type u_3
F : Type u_4
inst✝² : MeasurableSpace α
inst✝¹ : NormedAddCommGroup E
f✝ g : α → E
s t : Set α
μ ν : Measure α
l l' : Filter α
inst✝ : MeasurableSpace β
e : α → β
he : MeasurableEmbedding e
f : β → E
⊢ (∃ s ∈ map e l, IntegrableOn (f ∘ e) (e ⁻¹' s)) → ∃ s ∈ l, IntegrableOn (f ∘ e) s

Next tactic:
rintro ⟨s, hs⟩
theorem _root_.MeasurableEmbedding.integrableAtFilter_map_iff [MeasurableSpace β] {e : α → β}
    (he : MeasurableEmbedding e) {f : β → E} :
    IntegrableAtFilter f (l.map e) (μ.map e) ↔ IntegrableAtFilter (f ∘ e) l μ := by
  simp_rw [IntegrableAtFilter, he.integrableOn_map_iff]
  constructor <;> 

Proof state:
case mpr
α : Type u_1
β : Type u_2
E : Type u_3
F : Type u_4
inst✝² : MeasurableSpace α
inst✝¹ : NormedAddCommGroup E
f✝ g : α → E
s t : Set α
μ ν : Measure α
l l' : Filter α
inst✝ : MeasurableSpace β
e : α → β
he : MeasurableEmbedding e
f : β → E
⊢ (∃ s ∈ l, IntegrableOn (f ∘ e) s) → ∃ s ∈ map e l, IntegrableOn (f ∘ e) (e ⁻¹' s)

Next tactic:
rintro ⟨s, hs⟩
theorem _root_.MeasurableEmbedding.integrableAtFilter_map_iff [MeasurableSpace β] {e : α → β}
    (he : MeasurableEmbedding e) {f : β → E} :
    IntegrableAtFilter f (l.map e) (μ.map e) ↔ IntegrableAtFilter (f ∘ e) l μ := by
  simp_rw [IntegrableAtFilter, he.integrableOn_map_iff]
  constructor <;> rintro ⟨s, hs⟩
  · 

Proof state:
case mp.intro
α : Type u_1
β : Type u_2
E : Type u_3
F : Type u_4
inst✝² : MeasurableSpace α
inst✝¹ : NormedAddCommGroup E
f✝ g : α → E
s✝ t : Set α
μ ν : Measure α
l l' : Filter α
inst✝ : MeasurableSpace β
e : α → β
he : MeasurableEmbedding e
f : β → E
s : Set β
hs : s ∈ map e l ∧ IntegrableOn (f ∘ e) (e ⁻¹' s)
⊢ ∃ s ∈ l, IntegrableOn (f ∘ e) s

Next tactic:
exact ⟨_, hs⟩
theorem _root_.MeasurableEmbedding.integrableAtFilter_map_iff [MeasurableSpace β] {e : α → β}
    (he : MeasurableEmbedding e) {f : β → E} :
    IntegrableAtFilter f (l.map e) (μ.map e) ↔ IntegrableAtFilter (f ∘ e) l μ := by
  simp_rw [IntegrableAtFilter, he.integrableOn_map_iff]
  constructor <;> rintro ⟨s, hs⟩
  · exact ⟨_, hs⟩
  · 

Proof state:
case mpr.intro
α : Type u_1
β : Type u_2
E : Type u_3
F : Type u_4
inst✝² : MeasurableSpace α
inst✝¹ : NormedAddCommGroup E
f✝ g : α → E
s✝ t : Set α
μ ν : Measure α
l l' : Filter α
inst✝ : MeasurableSpace β
e : α → β
he : MeasurableEmbedding e
f : β → E
s : Set α
hs : s ∈ l ∧ IntegrableOn (f ∘ e) s
⊢ ∃ s ∈ map e l, IntegrableOn (f ∘ e) (e ⁻¹' s)

Next tactic:
exact ⟨e '' s, by rwa [mem_map, he.injective.preimage_image]⟩
theorem _root_.MeasurableEmbedding.integrableAtFilter_map_iff [MeasurableSpace β] {e : α → β}
    (he : MeasurableEmbedding e) {f : β → E} :
    IntegrableAtFilter f (l.map e) (μ.map e) ↔ IntegrableAtFilter (f ∘ e) l μ := by
  simp_rw [IntegrableAtFilter, he.integrableOn_map_iff]
  constructor <;> rintro ⟨s, hs⟩
  · exact ⟨_, hs⟩
  · exact ⟨e '' s, by 

Proof state:
α : Type u_1
β : Type u_2
E : Type u_3
F : Type u_4
inst✝² : MeasurableSpace α
inst✝¹ : NormedAddCommGroup E
f✝ g : α → E
s✝ t : Set α
μ ν : Measure α
l l' : Filter α
inst✝ : MeasurableSpace β
e : α → β
he : MeasurableEmbedding e
f : β → E
s : Set α
hs : s ∈ l ∧ IntegrableOn (f ∘ e) s
⊢ e '' s ∈ map e l ∧ IntegrableOn (f ∘ e) (e ⁻¹' (e '' s))

Next tactic:
rwa [mem_map, he.injective.preimage_image]
theorem _root_.MeasurableEmbedding.integrableAtFilter_iff_comap [MeasurableSpace β] {e : α → β}
    (he : MeasurableEmbedding e) {f : β → E} {μ : Measure β} :
    IntegrableAtFilter f (l.map e) μ ↔ IntegrableAtFilter (f ∘ e) l (μ.comap e) := by
  

Proof state:
α : Type u_1
β : Type u_2
E : Type u_3
F : Type u_4
inst✝² : MeasurableSpace α
inst✝¹ : NormedAddCommGroup E
f✝ g : α → E
s t : Set α
μ✝ ν : Measure α
l l' : Filter α
inst✝ : MeasurableSpace β
e : α → β
he : MeasurableEmbedding e
f : β → E
μ : Measure β
⊢ IntegrableAtFilter f (map e l) ↔ IntegrableAtFilter (f ∘ e) l

Next tactic:
simp_rw [← he.integrableAtFilter_map_iff, IntegrableAtFilter, he.map_comap]
theorem _root_.MeasurableEmbedding.integrableAtFilter_iff_comap [MeasurableSpace β] {e : α → β}
    (he : MeasurableEmbedding e) {f : β → E} {μ : Measure β} :
    IntegrableAtFilter f (l.map e) μ ↔ IntegrableAtFilter (f ∘ e) l (μ.comap e) := by
  simp_rw [← he.integrableAtFilter_map_iff, IntegrableAtFilter, he.map_comap]
  

Proof state:
α : Type u_1
β : Type u_2
E : Type u_3
F : Type u_4
inst✝² : MeasurableSpace α
inst✝¹ : NormedAddCommGroup E
f✝ g : α → E
s t : Set α
μ✝ ν : Measure α
l l' : Filter α
inst✝ : MeasurableSpace β
e : α → β
he : MeasurableEmbedding e
f : β → E
μ : Measure β
⊢ (∃ s ∈ map e l, IntegrableOn f s) ↔ ∃ s ∈ map e l, IntegrableOn f s

Next tactic:
constructor
theorem _root_.MeasurableEmbedding.integrableAtFilter_iff_comap [MeasurableSpace β] {e : α → β}
    (he : MeasurableEmbedding e) {f : β → E} {μ : Measure β} :
    IntegrableAtFilter f (l.map e) μ ↔ IntegrableAtFilter (f ∘ e) l (μ.comap e) := by
  simp_rw [← he.integrableAtFilter_map_iff, IntegrableAtFilter, he.map_comap]
  constructor <;> 

Proof state:
case mp
α : Type u_1
β : Type u_2
E : Type u_3
F : Type u_4
inst✝² : MeasurableSpace α
inst✝¹ : NormedAddCommGroup E
f✝ g : α → E
s t : Set α
μ✝ ν : Measure α
l l' : Filter α
inst✝ : MeasurableSpace β
e : α → β
he : MeasurableEmbedding e
f : β → E
μ : Measure β
⊢ (∃ s ∈ map e l, IntegrableOn f s) → ∃ s ∈ map e l, IntegrableOn f s

Next tactic:
rintro ⟨s, hs, int⟩
theorem _root_.MeasurableEmbedding.integrableAtFilter_iff_comap [MeasurableSpace β] {e : α → β}
    (he : MeasurableEmbedding e) {f : β → E} {μ : Measure β} :
    IntegrableAtFilter f (l.map e) μ ↔ IntegrableAtFilter (f ∘ e) l (μ.comap e) := by
  simp_rw [← he.integrableAtFilter_map_iff, IntegrableAtFilter, he.map_comap]
  constructor <;> 

Proof state:
case mpr
α : Type u_1
β : Type u_2
E : Type u_3
F : Type u_4
inst✝² : MeasurableSpace α
inst✝¹ : NormedAddCommGroup E
f✝ g : α → E
s t : Set α
μ✝ ν : Measure α
l l' : Filter α
inst✝ : MeasurableSpace β
e : α → β
he : MeasurableEmbedding e
f : β → E
μ : Measure β
⊢ (∃ s ∈ map e l, IntegrableOn f s) → ∃ s ∈ map e l, IntegrableOn f s

Next tactic:
rintro ⟨s, hs, int⟩
theorem _root_.MeasurableEmbedding.integrableAtFilter_iff_comap [MeasurableSpace β] {e : α → β}
    (he : MeasurableEmbedding e) {f : β → E} {μ : Measure β} :
    IntegrableAtFilter f (l.map e) μ ↔ IntegrableAtFilter (f ∘ e) l (μ.comap e) := by
  simp_rw [← he.integrableAtFilter_map_iff, IntegrableAtFilter, he.map_comap]
  constructor <;> rintro ⟨s, hs, int⟩
  · 

Proof state:
case mp.intro.intro
α : Type u_1
β : Type u_2
E : Type u_3
F : Type u_4
inst✝² : MeasurableSpace α
inst✝¹ : NormedAddCommGroup E
f✝ g : α → E
s✝ t : Set α
μ✝ ν : Measure α
l l' : Filter α
inst✝ : MeasurableSpace β
e : α → β
he : MeasurableEmbedding e
f : β → E
μ : Measure β
s : Set β
hs : s ∈ map e l
int : IntegrableOn f s
⊢ ∃ s ∈ map e l, IntegrableOn f s

Next tactic:
exact ⟨s, hs, int.mono_measure <| μ.restrict_le_self⟩