-- Mathlib/MeasureTheory/Decomposition/SignedHahn.lean
theorem of_symmDiff_compl_positive_negative {s : SignedMeasure α} {i j : Set α}
    (hi : MeasurableSet i) (hj : MeasurableSet j) (hi' : 0 ≤[i] s ∧ s ≤[iᶜ] 0)
    (hj' : 0 ≤[j] s ∧ s ≤[jᶜ] 0) : s (i ∆ j) = 0 ∧ s (iᶜ ∆ jᶜ) = 0

Proof state:
α : Type u_1
inst✝ : MeasurableSpace α
s : SignedMeasure α
i j : Set α
hi : MeasurableSet i
hj : MeasurableSet j
hi' : (∀ ⦃j : Set α⦄, MeasurableSet j → j ⊆ i → ↑0 j ≤ ↑s j) ∧ ∀ ⦃j : Set α⦄, MeasurableSet j → j ⊆ iᶜ → ↑s j ≤ ↑0 j
hj' : 0 ≤[j] s ∧ ∀ ⦃j_1 : Set α⦄, MeasurableSet j_1 → j_1 ⊆ jᶜ → ↑s j_1 ≤ ↑0 j_1
⊢ MeasurableSet j

α : Type u_1
inst✝ : MeasurableSpace α
s : SignedMeasure α
i j : Set α
hi : MeasurableSet i
hj : MeasurableSet j
hi' : 0 ≤[i] s ∧ ∀ ⦃j : Set α⦄, MeasurableSet j → j ⊆ iᶜ → ↑s j ≤ ↑0 j
hj' : 0 ≤[j] s ∧ ∀ ⦃j_1 : Set α⦄, MeasurableSet j_1 → j_1 ⊆ jᶜ → ↑s j_1 ≤ ↑0 j_1
⊢ MeasurableSet i

α : Type u_1
inst✝ : MeasurableSpace α
s : SignedMeasure α
i j : Set α
hi : MeasurableSet i
hj : MeasurableSet j
hi' : 0 ≤[i] s ∧ ∀ ⦃j : Set α⦄, MeasurableSet j → j ⊆ iᶜ → ↑s j ≤ ↑0 j
hj' : 0 ≤[j] s ∧ s ≤[jᶜ] 0
⊢ MeasurableSet jᶜ

α : Type u_1
inst✝ : MeasurableSpace α
s : SignedMeasure α
i j : Set α
hi : MeasurableSet i
hj : MeasurableSet j
hi' : 0 ≤[i] s ∧ s ≤[iᶜ] 0
hj' : 0 ≤[j] s ∧ s ≤[jᶜ] 0
⊢ MeasurableSet iᶜ

Tactic:
all_goals measurability

Result:
no goals

Proof state:
case right.hB
α : Type u_1
inst✝ : MeasurableSpace α
s : SignedMeasure α
i j : Set α
hi : MeasurableSet i
hj : MeasurableSet j
hi' : (∀ ⦃j : Set α⦄, MeasurableSet j → j ⊆ i → ↑0 j ≤ ↑s j) ∧ ∀ ⦃j : Set α⦄, MeasurableSet j → j ⊆ iᶜ → ↑s j ≤ ↑0 j
hj' :
  (∀ ⦃j_1 : Set α⦄, MeasurableSet j_1 → j_1 ⊆ j → ↑0 j_1 ≤ ↑s j_1) ∧
    ∀ ⦃j_1 : Set α⦄, MeasurableSet j_1 → j_1 ⊆ jᶜ → ↑s j_1 ≤ ↑0 j_1
⊢ MeasurableSet (i ∩ jᶜ)

Tactic:
exact hi.inter hj.compl

Result:
no goals

Proof state:
case left.h
α : Type u_1
inst✝ : MeasurableSpace α
s : SignedMeasure α
i j : Set α
hi : MeasurableSet i
hj : MeasurableSet j
hi' : (∀ ⦃j : Set α⦄, MeasurableSet j → j ⊆ i → ↑0 j ≤ ↑s j) ∧ ∀ ⦃j : Set α⦄, MeasurableSet j → j ⊆ iᶜ → ↑s j ≤ ↑0 j
hj' :
  (∀ ⦃j_1 : Set α⦄, MeasurableSet j_1 → j_1 ⊆ j → ↑0 j_1 ≤ ↑s j_1) ∧
    ∀ ⦃j_1 : Set α⦄, MeasurableSet j_1 → j_1 ⊆ jᶜ → ↑s j_1 ≤ ↑0 j_1
⊢ Disjoint (jᶜ ∩ i) (iᶜ ∩ j)

Tactic:
exact
  Set.disjoint_of_subset_left Set.inter_subset_left
    (Set.disjoint_of_subset_right Set.inter_subset_right
      (disjoint_comm.1 (IsCompl.disjoint isCompl_compl)))

Result:
no goals

Proof state:
case right
α : Type u_1
inst✝ : MeasurableSpace α
s : SignedMeasure α
i j : Set α
hi : MeasurableSet i
hj : MeasurableSet j
hi' : (∀ ⦃j : Set α⦄, MeasurableSet j → j ⊆ i → ↑0 j ≤ ↑s j) ∧ ∀ ⦃j : Set α⦄, MeasurableSet j → j ⊆ iᶜ → ↑s j ≤ ↑0 j
hj' :
  (∀ ⦃j_1 : Set α⦄, MeasurableSet j_1 → j_1 ⊆ j → ↑0 j_1 ≤ ↑s j_1) ∧
    ∀ ⦃j_1 : Set α⦄, MeasurableSet j_1 → j_1 ⊆ jᶜ → ↑s j_1 ≤ ↑0 j_1
⊢ ↑s (iᶜ ∆ jᶜ) = 0

Tactic:
rw [Set.symmDiff_def, Set.diff_eq_compl_inter, Set.diff_eq_compl_inter, compl_compl,
  compl_compl, of_union,
  le_antisymm (hi'.2 (hj.inter hi.compl) Set.inter_subset_right)
    (hj'.1 (hj.inter hi.compl) Set.inter_subset_left),
  le_antisymm (hj'.2 (hi.inter hj.compl) Set.inter_subset_right)
    (hi'.1 (hi.inter hj.compl) Set.inter_subset_left),
  zero_apply, zero_apply, zero_add]

Result:
case right.h
α : Type u_1
inst✝ : MeasurableSpace α
s : SignedMeasure α
i j : Set α
hi : MeasurableSet i
hj : MeasurableSet j
hi' : (∀ ⦃j : Set α⦄, MeasurableSet j → j ⊆ i → ↑0 j ≤ ↑s j) ∧ ∀ ⦃j : Set α⦄, MeasurableSet j → j ⊆ iᶜ → ↑s j ≤ ↑0 j
hj' :
  (∀ ⦃j_1 : Set α⦄, MeasurableSet j_1 → j_1 ⊆ j → ↑0 j_1 ≤ ↑s j_1) ∧
    ∀ ⦃j_1 : Set α⦄, MeasurableSet j_1 → j_1 ⊆ jᶜ → ↑s j_1 ≤ ↑0 j_1
⊢ Disjoint (j ∩ iᶜ) (i ∩ jᶜ)

case right.hA
α : Type u_1
inst✝ : MeasurableSpace α
s : SignedMeasure α
i j : Set α
hi : MeasurableSet i
hj : MeasurableSet j
hi' : (∀ ⦃j : Set α⦄, MeasurableSet j → j ⊆ i → ↑0 j ≤ ↑s j) ∧ ∀ ⦃j : Set α⦄, MeasurableSet j → j ⊆ iᶜ → ↑s j ≤ ↑0 j
hj' :
  (∀ ⦃j_1 : Set α⦄, MeasurableSet j_1 → j_1 ⊆ j → ↑0 j_1 ≤ ↑s j_1) ∧
    ∀ ⦃j_1 : Set α⦄, MeasurableSet j_1 → j_1 ⊆ jᶜ → ↑s j_1 ≤ ↑0 j_1
⊢ MeasurableSet (j ∩ iᶜ)

case right.hB
α : Type u_1
inst✝ : MeasurableSpace α
s : SignedMeasure α
i j : Set α
hi : MeasurableSet i
hj : MeasurableSet j
hi' : (∀ ⦃j : Set α⦄, MeasurableSet j → j ⊆ i → ↑0 j ≤ ↑s j) ∧ ∀ ⦃j : Set α⦄, MeasurableSet j → j ⊆ iᶜ → ↑s j ≤ ↑0 j
hj' :
  (∀ ⦃j_1 : Set α⦄, MeasurableSet j_1 → j_1 ⊆ j → ↑0 j_1 ≤ ↑s j_1) ∧
    ∀ ⦃j_1 : Set α⦄, MeasurableSet j_1 → j_1 ⊆ jᶜ → ↑s j_1 ≤ ↑0 j_1
⊢ MeasurableSet (i ∩ jᶜ)

Proof state:
α : Type u_1
inst✝ : MeasurableSpace α
s : SignedMeasure α
i j : Set α
hi : MeasurableSet i
hj : MeasurableSet j
hi' : 0 ≤[i] s ∧ s ≤[iᶜ] 0
hj' : 0 ≤[j] s ∧ s ≤[jᶜ] 0
⊢ ↑s (i ∆ j) = 0 ∧ ↑s (iᶜ ∆ jᶜ) = 0

Tactic:
rw [restrict_le_restrict_iff s 0, restrict_le_restrict_iff 0 s] at hi' hj'

Result:
α : Type u_1
inst✝ : MeasurableSpace α
s : SignedMeasure α
i j : Set α
hi : MeasurableSet i
hj : MeasurableSet j
hi' : (∀ ⦃j : Set α⦄, MeasurableSet j → j ⊆ i → ↑0 j ≤ ↑s j) ∧ ∀ ⦃j : Set α⦄, MeasurableSet j → j ⊆ iᶜ → ↑s j ≤ ↑0 j
hj' :
  (∀ ⦃j_1 : Set α⦄, MeasurableSet j_1 → j_1 ⊆ j → ↑0 j_1 ≤ ↑s j_1) ∧
    ∀ ⦃j_1 : Set α⦄, MeasurableSet j_1 → j_1 ⊆ jᶜ → ↑s j_1 ≤ ↑0 j_1
⊢ ↑s (i ∆ j) = 0 ∧ ↑s (iᶜ ∆ jᶜ) = 0

α : Type u_1
inst✝ : MeasurableSpace α
s : SignedMeasure α
i j : Set α
hi : MeasurableSet i
hj : MeasurableSet j
hi' : (∀ ⦃j : Set α⦄, MeasurableSet j → j ⊆ i → ↑0 j ≤ ↑s j) ∧ ∀ ⦃j : Set α⦄, MeasurableSet j → j ⊆ iᶜ → ↑s j ≤ ↑0 j
hj' : 0 ≤[j] s ∧ ∀ ⦃j_1 : Set α⦄, MeasurableSet j_1 → j_1 ⊆ jᶜ → ↑s j_1 ≤ ↑0 j_1
⊢ MeasurableSet j

α : Type u_1
inst✝ : MeasurableSpace α
s : SignedMeasure α
i j : Set α
hi : MeasurableSet i
hj : MeasurableSet j
hi' : 0 ≤[i] s ∧ ∀ ⦃j : Set α⦄, MeasurableSet j → j ⊆ iᶜ → ↑s j ≤ ↑0 j
hj' : 0 ≤[j] s ∧ ∀ ⦃j_1 : Set α⦄, MeasurableSet j_1 → j_1 ⊆ jᶜ → ↑s j_1 ≤ ↑0 j_1
⊢ MeasurableSet i

α : Type u_1
inst✝ : MeasurableSpace α
s : SignedMeasure α
i j : Set α
hi : MeasurableSet i
hj : MeasurableSet j
hi' : 0 ≤[i] s ∧ ∀ ⦃j : Set α⦄, MeasurableSet j → j ⊆ iᶜ → ↑s j ≤ ↑0 j
hj' : 0 ≤[j] s ∧ s ≤[jᶜ] 0
⊢ MeasurableSet jᶜ

α : Type u_1
inst✝ : MeasurableSpace α
s : SignedMeasure α
i j : Set α
hi : MeasurableSet i
hj : MeasurableSet j
hi' : 0 ≤[i] s ∧ s ≤[iᶜ] 0
hj' : 0 ≤[j] s ∧ s ≤[jᶜ] 0
⊢ MeasurableSet iᶜ

Proof state:
α : Type u_1
inst✝ : MeasurableSpace α
s : SignedMeasure α
i j : Set α
hi : MeasurableSet i
hj : MeasurableSet j
hi' : 0 ≤[i] s ∧ s ≤[iᶜ] 0
hj' : 0 ≤[j] s ∧ s ≤[jᶜ] 0
⊢ MeasurableSet iᶜ

Tactic:
measurability

Result:
no goals

Proof state:
case left.hA
α : Type u_1
inst✝ : MeasurableSpace α
s : SignedMeasure α
i j : Set α
hi : MeasurableSet i
hj : MeasurableSet j
hi' : (∀ ⦃j : Set α⦄, MeasurableSet j → j ⊆ i → ↑0 j ≤ ↑s j) ∧ ∀ ⦃j : Set α⦄, MeasurableSet j → j ⊆ iᶜ → ↑s j ≤ ↑0 j
hj' :
  (∀ ⦃j_1 : Set α⦄, MeasurableSet j_1 → j_1 ⊆ j → ↑0 j_1 ≤ ↑s j_1) ∧
    ∀ ⦃j_1 : Set α⦄, MeasurableSet j_1 → j_1 ⊆ jᶜ → ↑s j_1 ≤ ↑0 j_1
⊢ MeasurableSet (jᶜ ∩ i)

Tactic:
exact hj.compl.inter hi

Result:
no goals