Theorem: ProbabilityTheory.kernel.singularPart_of_subset_mutuallySingularSetSlice
File: Mathlib/Probability/Kernel/RadonNikodym.lean

tactic: have hs' : ∀ x ∈ s, 1 ≤ rnDerivAux κ (κ + η) a x := fun _ hx ↦ hs hx
state_before: α : Type u_1
γ : Type u_2
mα : MeasurableSpace α
mγ : MeasurableSpace γ
κ η : ↥(kernel α γ)
hαγ : MeasurableSpace.CountableOrCountablyGenerated α γ
inst✝¹ : IsFiniteKernel κ
inst✝ : IsFiniteKernel η
a : α
s : Set γ
hsm : MeasurableSet s
hs : s ⊆ mutuallySingularSetSlice κ η a
⊢ ((singularPart κ η) a) s = (κ a) s
state_after: α : Type u_1
γ : Type u_2
mα : MeasurableSpace α
mγ : MeasurableSpace γ
κ η : ↥(kernel α γ)
hαγ : MeasurableSpace.CountableOrCountablyGenerated α γ
inst✝¹ : IsFiniteKernel κ
inst✝ : IsFiniteKernel η
a : α
s : Set γ
hsm : MeasurableSet s
hs : s ⊆ mutuallySingularSetSlice κ η a
hs' : ∀ x ∈ s, 1 ≤ rnDerivAux κ (κ + η) a x
⊢ ((singularPart κ η) a) s = (κ a) s

tactic: rw [singularPart, kernel.withDensity_apply']
state_before: α : Type u_1
γ : Type u_2
mα : MeasurableSpace α
mγ : MeasurableSpace γ
κ η : ↥(kernel α γ)
hαγ : MeasurableSpace.CountableOrCountablyGenerated α γ
inst✝¹ : IsFiniteKernel κ
inst✝ : IsFiniteKernel η
a : α
s : Set γ
hsm : MeasurableSet s
hs : s ⊆ mutuallySingularSetSlice κ η a
hs' : ∀ x ∈ s, 1 ≤ rnDerivAux κ (κ + η) a x
⊢ ((singularPart κ η) a) s = (κ a) s
state_after: α : Type u_1
γ : Type u_2
mα : MeasurableSpace α
mγ : MeasurableSpace γ
κ η : ↥(kernel α γ)
hαγ : MeasurableSpace.CountableOrCountablyGenerated α γ
inst✝¹ : IsFiniteKernel κ
inst✝ : IsFiniteKernel η
a : α
s : Set γ
hsm : MeasurableSet s
hs : s ⊆ mutuallySingularSetSlice κ η a
hs' : ∀ x ∈ s, 1 ≤ rnDerivAux κ (κ + η) a x
⊢ ∫⁻ (b : γ) in s,
      ↑(rnDerivAux κ (κ + η) a b).toNNReal - ↑(1 - rnDerivAux κ (κ + η) a b).toNNReal * rnDeriv κ η a b ∂(κ + η) a =
    (κ a) s

case hf
α : Type u_1
γ : Type u_2
mα : MeasurableSpace α
mγ : MeasurableSpace γ
κ η : ↥(kernel α γ)
hαγ : MeasurableSpace.CountableOrCountablyGenerated α γ
inst✝¹ : IsFiniteKernel κ
inst✝ : IsFiniteKernel η
a : α
s : Set γ
hsm : MeasurableSet s
hs : s ⊆ mutuallySingularSetSlice κ η a
hs' : ∀ x ∈ s, 1 ≤ rnDerivAux κ (κ + η) a x
⊢ Measurable
    (Function.uncurry fun a x =>
      ↑(rnDerivAux κ (κ + η) a x).toNNReal - ↑(1 - rnDerivAux κ (κ + η) a x).toNNReal * rnDeriv κ η a x)

tactic: swap
state_before: α : Type u_1
γ : Type u_2
mα : MeasurableSpace α
mγ : MeasurableSpace γ
κ η : ↥(kernel α γ)
hαγ : MeasurableSpace.CountableOrCountablyGenerated α γ
inst✝¹ : IsFiniteKernel κ
inst✝ : IsFiniteKernel η
a : α
s : Set γ
hsm : MeasurableSet s
hs : s ⊆ mutuallySingularSetSlice κ η a
hs' : ∀ x ∈ s, 1 ≤ rnDerivAux κ (κ + η) a x
⊢ ∫⁻ (b : γ) in s,
      ↑(rnDerivAux κ (κ + η) a b).toNNReal - ↑(1 - rnDerivAux κ (κ + η) a b).toNNReal * rnDeriv κ η a b ∂(κ + η) a =
    (κ a) s

case hf
α : Type u_1
γ : Type u_2
mα : MeasurableSpace α
mγ : MeasurableSpace γ
κ η : ↥(kernel α γ)
hαγ : MeasurableSpace.CountableOrCountablyGenerated α γ
inst✝¹ : IsFiniteKernel κ
inst✝ : IsFiniteKernel η
a : α
s : Set γ
hsm : MeasurableSet s
hs : s ⊆ mutuallySingularSetSlice κ η a
hs' : ∀ x ∈ s, 1 ≤ rnDerivAux κ (κ + η) a x
⊢ Measurable
    (Function.uncurry fun a x =>
      ↑(rnDerivAux κ (κ + η) a x).toNNReal - ↑(1 - rnDerivAux κ (κ + η) a x).toNNReal * rnDeriv κ η a x)
state_after: case hf
α : Type u_1
γ : Type u_2
mα : MeasurableSpace α
mγ : MeasurableSpace γ
κ η : ↥(kernel α γ)
hαγ : MeasurableSpace.CountableOrCountablyGenerated α γ
inst✝¹ : IsFiniteKernel κ
inst✝ : IsFiniteKernel η
a : α
s : Set γ
hsm : MeasurableSet s
hs : s ⊆ mutuallySingularSetSlice κ η a
hs' : ∀ x ∈ s, 1 ≤ rnDerivAux κ (κ + η) a x
⊢ Measurable
    (Function.uncurry fun a x =>
      ↑(rnDerivAux κ (κ + η) a x).toNNReal - ↑(1 - rnDerivAux κ (κ + η) a x).toNNReal * rnDeriv κ η a x)

α : Type u_1
γ : Type u_2
mα : MeasurableSpace α
mγ : MeasurableSpace γ
κ η : ↥(kernel α γ)
hαγ : MeasurableSpace.CountableOrCountablyGenerated α γ
inst✝¹ : IsFiniteKernel κ
inst✝ : IsFiniteKernel η
a : α
s : Set γ
hsm : MeasurableSet s
hs : s ⊆ mutuallySingularSetSlice κ η a
hs' : ∀ x ∈ s, 1 ≤ rnDerivAux κ (κ + η) a x
⊢ ∫⁻ (b : γ) in s,
      ↑(rnDerivAux κ (κ + η) a b).toNNReal - ↑(1 - rnDerivAux κ (κ + η) a b).toNNReal * rnDeriv κ η a b ∂(κ + η) a =
    (κ a) s

tactic: calc
  ∫⁻ x in s, ↑(Real.toNNReal (rnDerivAux κ (κ + η) a x)) -
    ↑(Real.toNNReal (1 - rnDerivAux κ (κ + η) a x)) * rnDeriv κ η a x
    ∂(κ + η) a
  = ∫⁻ _ in s, 1 ∂(κ + η) a := by
      refine setLIntegral_congr_fun hsm ?_
      have h_le : κ ≤ κ + η := le_add_of_nonneg_right bot_le
      filter_upwards [rnDerivAux_le_one h_le] with x hx hxs
      have h_eq_one : rnDerivAux κ (κ + η) a x = 1 := le_antisymm hx (hs' x hxs)
      simp [h_eq_one]
_ = (κ + η) a s := by simp
_ = κ a s := by
      suffices η a s = 0 by simp [this]
      exact measure_mono_null hs (measure_mutuallySingularSetSlice κ η a)
state_before: α : Type u_1
γ : Type u_2
mα : MeasurableSpace α
mγ : MeasurableSpace γ
κ η : ↥(kernel α γ)
hαγ : MeasurableSpace.CountableOrCountablyGenerated α γ
inst✝¹ : IsFiniteKernel κ
inst✝ : IsFiniteKernel η
a : α
s : Set γ
hsm : MeasurableSet s
hs : s ⊆ mutuallySingularSetSlice κ η a
hs' : ∀ x ∈ s, 1 ≤ rnDerivAux κ (κ + η) a x
⊢ ∫⁻ (b : γ) in s,
      ↑(rnDerivAux κ (κ + η) a b).toNNReal - ↑(1 - rnDerivAux κ (κ + η) a b).toNNReal * rnDeriv κ η a b ∂(κ + η) a =
    (κ a) s
state_after: no goals

tactic: exact measurable_singularPart_fun κ η
state_before: case hf
α : Type u_1
γ : Type u_2
mα : MeasurableSpace α
mγ : MeasurableSpace γ
κ η : ↥(kernel α γ)
hαγ : MeasurableSpace.CountableOrCountablyGenerated α γ
inst✝¹ : IsFiniteKernel κ
inst✝ : IsFiniteKernel η
a : α
s : Set γ
hsm : MeasurableSet s
hs : s ⊆ mutuallySingularSetSlice κ η a
hs' : ∀ x ∈ s, 1 ≤ rnDerivAux κ (κ + η) a x
⊢ Measurable
    (Function.uncurry fun a x =>
      ↑(rnDerivAux κ (κ + η) a x).toNNReal - ↑(1 - rnDerivAux κ (κ + η) a x).toNNReal * rnDeriv κ η a x)
state_after: no goals

tactic: refine setLIntegral_congr_fun hsm ?_
state_before: α : Type u_1
γ : Type u_2
mα : MeasurableSpace α
mγ : MeasurableSpace γ
κ η : ↥(kernel α γ)
hαγ : MeasurableSpace.CountableOrCountablyGenerated α γ
inst✝¹ : IsFiniteKernel κ
inst✝ : IsFiniteKernel η
a : α
s : Set γ
hsm : MeasurableSet s
hs : s ⊆ mutuallySingularSetSlice κ η a
hs' : ∀ x ∈ s, 1 ≤ rnDerivAux κ (κ + η) a x
⊢ ∫⁻ (x : γ) in s,
      ↑(rnDerivAux κ (κ + η) a x).toNNReal - ↑(1 - rnDerivAux κ (κ + η) a x).toNNReal * rnDeriv κ η a x ∂(κ + η) a =
    ∫⁻ (x : γ) in s, 1 ∂(κ + η) a
state_after: α : Type u_1
γ : Type u_2
mα : MeasurableSpace α
mγ : MeasurableSpace γ
κ η : ↥(kernel α γ)
hαγ : MeasurableSpace.CountableOrCountablyGenerated α γ
inst✝¹ : IsFiniteKernel κ
inst✝ : IsFiniteKernel η
a : α
s : Set γ
hsm : MeasurableSet s
hs : s ⊆ mutuallySingularSetSlice κ η a
hs' : ∀ x ∈ s, 1 ≤ rnDerivAux κ (κ + η) a x
⊢ ∀ᵐ (x : γ) ∂(κ + η) a,
    x ∈ s → ↑(rnDerivAux κ (κ + η) a x).toNNReal - ↑(1 - rnDerivAux κ (κ + η) a x).toNNReal * rnDeriv κ η a x = 1

tactic: have h_le : κ ≤ κ + η := le_add_of_nonneg_right bot_le
state_before: α : Type u_1
γ : Type u_2
mα : MeasurableSpace α
mγ : MeasurableSpace γ
κ η : ↥(kernel α γ)
hαγ : MeasurableSpace.CountableOrCountablyGenerated α γ
inst✝¹ : IsFiniteKernel κ
inst✝ : IsFiniteKernel η
a : α
s : Set γ
hsm : MeasurableSet s
hs : s ⊆ mutuallySingularSetSlice κ η a
hs' : ∀ x ∈ s, 1 ≤ rnDerivAux κ (κ + η) a x
⊢ ∀ᵐ (x : γ) ∂(κ + η) a,
    x ∈ s → ↑(rnDerivAux κ (κ + η) a x).toNNReal - ↑(1 - rnDerivAux κ (κ + η) a x).toNNReal * rnDeriv κ η a x = 1
state_after: α : Type u_1
γ : Type u_2
mα : MeasurableSpace α
mγ : MeasurableSpace γ
κ η : ↥(kernel α γ)
hαγ : MeasurableSpace.CountableOrCountablyGenerated α γ
inst✝¹ : IsFiniteKernel κ
inst✝ : IsFiniteKernel η
a : α
s : Set γ
hsm : MeasurableSet s
hs : s ⊆ mutuallySingularSetSlice κ η a
hs' : ∀ x ∈ s, 1 ≤ rnDerivAux κ (κ + η) a x
h_le : κ ≤ κ + η
⊢ ∀ᵐ (x : γ) ∂(κ + η) a,
    x ∈ s → ↑(rnDerivAux κ (κ + η) a x).toNNReal - ↑(1 - rnDerivAux κ (κ + η) a x).toNNReal * rnDeriv κ η a x = 1

tactic: filter_upwards [rnDerivAux_le_one h_le] with x hx hxs
state_before: α : Type u_1
γ : Type u_2
mα : MeasurableSpace α
mγ : MeasurableSpace γ
κ η : ↥(kernel α γ)
hαγ : MeasurableSpace.CountableOrCountablyGenerated α γ
inst✝¹ : IsFiniteKernel κ
inst✝ : IsFiniteKernel η
a : α
s : Set γ
hsm : MeasurableSet s
hs : s ⊆ mutuallySingularSetSlice κ η a
hs' : ∀ x ∈ s, 1 ≤ rnDerivAux κ (κ + η) a x
h_le : κ ≤ κ + η
⊢ ∀ᵐ (x : γ) ∂(κ + η) a,
    x ∈ s → ↑(rnDerivAux κ (κ + η) a x).toNNReal - ↑(1 - rnDerivAux κ (κ + η) a x).toNNReal * rnDeriv κ η a x = 1
state_after: case h
α : Type u_1
γ : Type u_2
mα : MeasurableSpace α
mγ : MeasurableSpace γ
κ η : ↥(kernel α γ)
hαγ : MeasurableSpace.CountableOrCountablyGenerated α γ
inst✝¹ : IsFiniteKernel κ
inst✝ : IsFiniteKernel η
a : α
s : Set γ
hsm : MeasurableSet s
hs : s ⊆ mutuallySingularSetSlice κ η a
hs' : ∀ x ∈ s, 1 ≤ rnDerivAux κ (κ + η) a x
h_le : κ ≤ κ + η
x : γ
hx : rnDerivAux κ (κ + η) a x ≤ 1 x
hxs : x ∈ s
⊢ ↑(rnDerivAux κ (κ + η) a x).toNNReal - ↑(1 - rnDerivAux κ (κ + η) a x).toNNReal * rnDeriv κ η a x = 1

tactic: have h_eq_one : rnDerivAux κ (κ + η) a x = 1 := le_antisymm hx (hs' x hxs)
state_before: case h
α : Type u_1
γ : Type u_2
mα : MeasurableSpace α
mγ : MeasurableSpace γ
κ η : ↥(kernel α γ)
hαγ : MeasurableSpace.CountableOrCountablyGenerated α γ
inst✝¹ : IsFiniteKernel κ
inst✝ : IsFiniteKernel η
a : α
s : Set γ
hsm : MeasurableSet s
hs : s ⊆ mutuallySingularSetSlice κ η a
hs' : ∀ x ∈ s, 1 ≤ rnDerivAux κ (κ + η) a x
h_le : κ ≤ κ + η
x : γ
hx : rnDerivAux κ (κ + η) a x ≤ 1 x
hxs : x ∈ s
⊢ ↑(rnDerivAux κ (κ + η) a x).toNNReal - ↑(1 - rnDerivAux κ (κ + η) a x).toNNReal * rnDeriv κ η a x = 1
state_after: case h
α : Type u_1
γ : Type u_2
mα : MeasurableSpace α
mγ : MeasurableSpace γ
κ η : ↥(kernel α γ)
hαγ : MeasurableSpace.CountableOrCountablyGenerated α γ
inst✝¹ : IsFiniteKernel κ
inst✝ : IsFiniteKernel η
a : α
s : Set γ
hsm : MeasurableSet s
hs : s ⊆ mutuallySingularSetSlice κ η a
hs' : ∀ x ∈ s, 1 ≤ rnDerivAux κ (κ + η) a x
h_le : κ ≤ κ + η
x : γ
hx : rnDerivAux κ (κ + η) a x ≤ 1 x
hxs : x ∈ s
h_eq_one : rnDerivAux κ (κ + η) a x = 1
⊢ ↑(rnDerivAux κ (κ + η) a x).toNNReal - ↑(1 - rnDerivAux κ (κ + η) a x).toNNReal * rnDeriv κ η a x = 1

tactic: simp [h_eq_one]
state_before: case h
α : Type u_1
γ : Type u_2
mα : MeasurableSpace α
mγ : MeasurableSpace γ
κ η : ↥(kernel α γ)
hαγ : MeasurableSpace.CountableOrCountablyGenerated α γ
inst✝¹ : IsFiniteKernel κ
inst✝ : IsFiniteKernel η
a : α
s : Set γ
hsm : MeasurableSet s
hs : s ⊆ mutuallySingularSetSlice κ η a
hs' : ∀ x ∈ s, 1 ≤ rnDerivAux κ (κ + η) a x
h_le : κ ≤ κ + η
x : γ
hx : rnDerivAux κ (κ + η) a x ≤ 1 x
hxs : x ∈ s
h_eq_one : rnDerivAux κ (κ + η) a x = 1
⊢ ↑(rnDerivAux κ (κ + η) a x).toNNReal - ↑(1 - rnDerivAux κ (κ + η) a x).toNNReal * rnDeriv κ η a x = 1
state_after: no goals

tactic: simp
state_before: α : Type u_1
γ : Type u_2
mα : MeasurableSpace α
mγ : MeasurableSpace γ
κ η : ↥(kernel α γ)
hαγ : MeasurableSpace.CountableOrCountablyGenerated α γ
inst✝¹ : IsFiniteKernel κ
inst✝ : IsFiniteKernel η
a : α
s : Set γ
hsm : MeasurableSet s
hs : s ⊆ mutuallySingularSetSlice κ η a
hs' : ∀ x ∈ s, 1 ≤ rnDerivAux κ (κ + η) a x
⊢ ∫⁻ (x : γ) in s, 1 ∂(κ + η) a = ((κ + η) a) s
state_after: no goals

tactic: suffices η a s = 0 by simp [this]
state_before: α : Type u_1
γ : Type u_2
mα : MeasurableSpace α
mγ : MeasurableSpace γ
κ η : ↥(kernel α γ)
hαγ : MeasurableSpace.CountableOrCountablyGenerated α γ
inst✝¹ : IsFiniteKernel κ
inst✝ : IsFiniteKernel η
a : α
s : Set γ
hsm : MeasurableSet s
hs : s ⊆ mutuallySingularSetSlice κ η a
hs' : ∀ x ∈ s, 1 ≤ rnDerivAux κ (κ + η) a x
⊢ ((κ + η) a) s = (κ a) s
state_after: α : Type u_1
γ : Type u_2
mα : MeasurableSpace α
mγ : MeasurableSpace γ
κ η : ↥(kernel α γ)
hαγ : MeasurableSpace.CountableOrCountablyGenerated α γ
inst✝¹ : IsFiniteKernel κ
inst✝ : IsFiniteKernel η
a : α
s : Set γ
hsm : MeasurableSet s
hs : s ⊆ mutuallySingularSetSlice κ η a
hs' : ∀ x ∈ s, 1 ≤ rnDerivAux κ (κ + η) a x
⊢ (η a) s = 0

tactic: exact measure_mono_null hs (measure_mutuallySingularSetSlice κ η a)
state_before: α : Type u_1
γ : Type u_2
mα : MeasurableSpace α
mγ : MeasurableSpace γ
κ η : ↥(kernel α γ)
hαγ : MeasurableSpace.CountableOrCountablyGenerated α γ
inst✝¹ : IsFiniteKernel κ
inst✝ : IsFiniteKernel η
a : α
s : Set γ
hsm : MeasurableSet s
hs : s ⊆ mutuallySingularSetSlice κ η a
hs' : ∀ x ∈ s, 1 ≤ rnDerivAux κ (κ + η) a x
⊢ (η a) s = 0
state_after: no goals

tactic: simp [this]
state_before: α : Type u_1
γ : Type u_2
mα : MeasurableSpace α
mγ : MeasurableSpace γ
κ η : ↥(kernel α γ)
hαγ : MeasurableSpace.CountableOrCountablyGenerated α γ
inst✝¹ : IsFiniteKernel κ
inst✝ : IsFiniteKernel η
a : α
s : Set γ
hsm : MeasurableSet s
hs : s ⊆ mutuallySingularSetSlice κ η a
hs' : ∀ x ∈ s, 1 ≤ rnDerivAux κ (κ + η) a x
this : (η a) s = 0
⊢ ((κ + η) a) s = (κ a) s
state_after: no goals