Skip to content

Commit

Permalink
feat: add a variant of measurableSet_eq_fun that applies to ENNReal (
Browse files Browse the repository at this point in the history
  • Loading branch information
RemyDegenne committed Mar 13, 2024
1 parent 2731f81 commit 98385b0
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions Mathlib/MeasureTheory/Group/Arithmetic.lean
Expand Up @@ -383,6 +383,18 @@ theorem measurableSet_eq_fun {m : MeasurableSpace α} {E} [MeasurableSpace E] [A
simp_rw [Set.mem_setOf_eq, Pi.sub_apply, sub_eq_zero]
#align measurable_set_eq_fun measurableSet_eq_fun

@[measurability]
lemma measurableSet_eq_fun' {β : Type*} [CanonicallyOrderedAddCommMonoid β] [Sub β] [OrderedSub β]
{_ : MeasurableSpace β} [MeasurableSub₂ β] [MeasurableSingletonClass β]
{f g : α → β} (hf : Measurable f) (hg : Measurable g) :
MeasurableSet {x | f x = g x} := by
have : {a | f a = g a} = {a | (f - g) a = 0} ∩ {a | (g - f) a = 0} := by
ext
simp only [Set.mem_setOf_eq, Pi.sub_apply, tsub_eq_zero_iff_le, Set.mem_inter_iff]
exact ⟨fun h ↦ ⟨h.le, h.symm.le⟩, fun h ↦ le_antisymm h.1 h.2
rw [this]
exact ((hf.sub hg) (measurableSet_singleton 0)).inter ((hg.sub hf) (measurableSet_singleton 0))

theorem nullMeasurableSet_eq_fun {E} [MeasurableSpace E] [AddGroup E] [MeasurableSingletonClass E]
[MeasurableSub₂ E] {f g : α → E} (hf : AEMeasurable f μ) (hg : AEMeasurable g μ) :
NullMeasurableSet { x | f x = g x } μ := by
Expand Down

0 comments on commit 98385b0

Please sign in to comment.