-- Mathlib/MeasureTheory/Decomposition/Jordan.lean
theorem of_diff_eq_zero_of_symmDiff_eq_zero_positive (hu : MeasurableSet u) (hv : MeasurableSet v)
    (hsu : 0 ≤[u] s) (hsv : 0 ≤[v] s) (hs : s (u ∆ v) = 0) : s (u \ v) = 0 ∧ s (v \ u) = 0

Proof state:
α : Type u_1
inst✝ : MeasurableSpace α
s : SignedMeasure α
u v : Set α
hu : MeasurableSet u
hv : MeasurableSet v
hsu : ∀ ⦃j : Set α⦄, MeasurableSet j → j ⊆ u → ↑0 j ≤ ↑s j
hsv : ∀ ⦃j : Set α⦄, MeasurableSet j → j ⊆ v → ↑0 j ≤ ↑s j
hs : ↑s (u ∆ v) = 0
a : ↑0 (u \ v) ≤ ↑s (u \ v)
⊢ ↑s (u \ v) = 0 ∧ ↑s (v \ u) = 0

Tactic:
have b := hsv (hv.diff hu) diff_subset

Result:
α : Type u_1
inst✝ : MeasurableSpace α
s : SignedMeasure α
u v : Set α
hu : MeasurableSet u
hv : MeasurableSet v
hsu : ∀ ⦃j : Set α⦄, MeasurableSet j → j ⊆ u → ↑0 j ≤ ↑s j
hsv : ∀ ⦃j : Set α⦄, MeasurableSet j → j ⊆ v → ↑0 j ≤ ↑s j
hs : ↑s (u ∆ v) = 0
a : ↑0 (u \ v) ≤ ↑s (u \ v)
b : ↑0 (v \ u) ≤ ↑s (v \ u)
⊢ ↑s (u \ v) = 0 ∧ ↑s (v \ u) = 0

Proof state:
case hi
α : Type u_1
inst✝ : MeasurableSpace α
s : SignedMeasure α
u v : Set α
hu : MeasurableSet u
hv : MeasurableSet v
hsu : 0 ≤[u] s
hsv : 0 ≤[v] s
hs : ↑s (u ∆ v) = 0
⊢ MeasurableSet u

Tactic:
assumption

Result:
no goals

Proof state:
α : Type u_1
inst✝ : MeasurableSpace α
s : SignedMeasure α
u v : Set α
hu : MeasurableSet u
hv : MeasurableSet v
hsu : ∀ ⦃j : Set α⦄, MeasurableSet j → j ⊆ u → ↑0 j ≤ ↑s j
hsv : ∀ ⦃j : Set α⦄, MeasurableSet j → j ⊆ v → ↑0 j ≤ ↑s j
hs : ↑s (u ∆ v) = 0
⊢ ↑s (u \ v) = 0 ∧ ↑s (v \ u) = 0

case hi
α : Type u_1
inst✝ : MeasurableSpace α
s : SignedMeasure α
u v : Set α
hu : MeasurableSet u
hv : MeasurableSet v
hsu : ∀ ⦃j : Set α⦄, MeasurableSet j → j ⊆ u → ↑0 j ≤ ↑s j
hsv : 0 ≤[v] s
hs : ↑s (u ∆ v) = 0
⊢ MeasurableSet v

case hi
α : Type u_1
inst✝ : MeasurableSpace α
s : SignedMeasure α
u v : Set α
hu : MeasurableSet u
hv : MeasurableSet v
hsu : 0 ≤[u] s
hsv : 0 ≤[v] s
hs : ↑s (u ∆ v) = 0
⊢ MeasurableSet u

Tactic:
on_goal 1 =>
  have a := hsu (hu.diff hv) diff_subset
  have b := hsv (hv.diff hu) diff_subset
  erw [of_union (Set.disjoint_of_subset_left diff_subset disjoint_sdiff_self_right)
      (hu.diff hv) (hv.diff hu)] at hs
  rw [zero_apply] at a b
  constructor

Result:
case left
α : Type u_1
inst✝ : MeasurableSpace α
s : SignedMeasure α
u v : Set α
hu : MeasurableSet u
hv : MeasurableSet v
hsu : ∀ ⦃j : Set α⦄, MeasurableSet j → j ⊆ u → ↑0 j ≤ ↑s j
hsv : ∀ ⦃j : Set α⦄, MeasurableSet j → j ⊆ v → ↑0 j ≤ ↑s j
hs : ↑s (u \ v) + ↑s (v \ u) = 0
a : 0 ≤ ↑s (u \ v)
b : 0 ≤ ↑s (v \ u)
⊢ ↑s (u \ v) = 0

case right
α : Type u_1
inst✝ : MeasurableSpace α
s : SignedMeasure α
u v : Set α
hu : MeasurableSet u
hv : MeasurableSet v
hsu : ∀ ⦃j : Set α⦄, MeasurableSet j → j ⊆ u → ↑0 j ≤ ↑s j
hsv : ∀ ⦃j : Set α⦄, MeasurableSet j → j ⊆ v → ↑0 j ≤ ↑s j
hs : ↑s (u \ v) + ↑s (v \ u) = 0
a : 0 ≤ ↑s (u \ v)
b : 0 ≤ ↑s (v \ u)
⊢ ↑s (v \ u) = 0

case hi
α : Type u_1
inst✝ : MeasurableSpace α
s : SignedMeasure α
u v : Set α
hu : MeasurableSet u
hv : MeasurableSet v
hsu : ∀ ⦃j : Set α⦄, MeasurableSet j → j ⊆ u → ↑0 j ≤ ↑s j
hsv : 0 ≤[v] s
hs : ↑s (u ∆ v) = 0
⊢ MeasurableSet v

case hi
α : Type u_1
inst✝ : MeasurableSpace α
s : SignedMeasure α
u v : Set α
hu : MeasurableSet u
hv : MeasurableSet v
hsu : 0 ≤[u] s
hsv : 0 ≤[v] s
hs : ↑s (u ∆ v) = 0
⊢ MeasurableSet u

Proof state:
α : Type u_1
inst✝ : MeasurableSpace α
s : SignedMeasure α
u v : Set α
hu : MeasurableSet u
hv : MeasurableSet v
hsu : ∀ ⦃j : Set α⦄, MeasurableSet j → j ⊆ u → ↑0 j ≤ ↑s j
hsv : ∀ ⦃j : Set α⦄, MeasurableSet j → j ⊆ v → ↑0 j ≤ ↑s j
hs : ↑s (u ∆ v) = 0
⊢ ↑s (u \ v) = 0 ∧ ↑s (v \ u) = 0

Tactic:
have a := hsu (hu.diff hv) diff_subset

Result:
α : Type u_1
inst✝ : MeasurableSpace α
s : SignedMeasure α
u v : Set α
hu : MeasurableSet u
hv : MeasurableSet v
hsu : ∀ ⦃j : Set α⦄, MeasurableSet j → j ⊆ u → ↑0 j ≤ ↑s j
hsv : ∀ ⦃j : Set α⦄, MeasurableSet j → j ⊆ v → ↑0 j ≤ ↑s j
hs : ↑s (u ∆ v) = 0
a : ↑0 (u \ v) ≤ ↑s (u \ v)
⊢ ↑s (u \ v) = 0 ∧ ↑s (v \ u) = 0

Proof state:
α : Type u_1
inst✝ : MeasurableSpace α
s : SignedMeasure α
u v : Set α
hu : MeasurableSet u
hv : MeasurableSet v
hsu : ∀ ⦃j : Set α⦄, MeasurableSet j → j ⊆ u → ↑0 j ≤ ↑s j
hsv : ∀ ⦃j : Set α⦄, MeasurableSet j → j ⊆ v → ↑0 j ≤ ↑s j
hs : ↑s (u ∆ v) = 0
a : ↑0 (u \ v) ≤ ↑s (u \ v)
b : ↑0 (v \ u) ≤ ↑s (v \ u)
⊢ ↑s (u \ v) = 0 ∧ ↑s (v \ u) = 0

Tactic:
erw [of_union (Set.disjoint_of_subset_left diff_subset disjoint_sdiff_self_right)
    (hu.diff hv) (hv.diff hu)] at hs

Result:
α : Type u_1
inst✝ : MeasurableSpace α
s : SignedMeasure α
u v : Set α
hu : MeasurableSet u
hv : MeasurableSet v
hsu : ∀ ⦃j : Set α⦄, MeasurableSet j → j ⊆ u → ↑0 j ≤ ↑s j
hsv : ∀ ⦃j : Set α⦄, MeasurableSet j → j ⊆ v → ↑0 j ≤ ↑s j
hs : ↑s (u \ v) + ↑s (v \ u) = 0
a : ↑0 (u \ v) ≤ ↑s (u \ v)
b : ↑0 (v \ u) ≤ ↑s (v \ u)
⊢ ↑s (u \ v) = 0 ∧ ↑s (v \ u) = 0

Proof state:
case right
α : Type u_1
inst✝ : MeasurableSpace α
s : SignedMeasure α
u v : Set α
hu : MeasurableSet u
hv : MeasurableSet v
hsu : ∀ ⦃j : Set α⦄, MeasurableSet j → j ⊆ u → ↑0 j ≤ ↑s j
hsv : ∀ ⦃j : Set α⦄, MeasurableSet j → j ⊆ v → ↑0 j ≤ ↑s j
hs : ↑s (u \ v) + ↑s (v \ u) = 0
a : 0 ≤ ↑s (u \ v)
b : 0 ≤ ↑s (v \ u)
⊢ ↑s (v \ u) = 0

Tactic:
linarith

Result:
no goals

Proof state:
case left
α : Type u_1
inst✝ : MeasurableSpace α
s : SignedMeasure α
u v : Set α
hu : MeasurableSet u
hv : MeasurableSet v
hsu : ∀ ⦃j : Set α⦄, MeasurableSet j → j ⊆ u → ↑0 j ≤ ↑s j
hsv : ∀ ⦃j : Set α⦄, MeasurableSet j → j ⊆ v → ↑0 j ≤ ↑s j
hs : ↑s (u \ v) + ↑s (v \ u) = 0
a : 0 ≤ ↑s (u \ v)
b : 0 ≤ ↑s (v \ u)
⊢ ↑s (u \ v) = 0

case right
α : Type u_1
inst✝ : MeasurableSpace α
s : SignedMeasure α
u v : Set α
hu : MeasurableSet u
hv : MeasurableSet v
hsu : ∀ ⦃j : Set α⦄, MeasurableSet j → j ⊆ u → ↑0 j ≤ ↑s j
hsv : ∀ ⦃j : Set α⦄, MeasurableSet j → j ⊆ v → ↑0 j ≤ ↑s j
hs : ↑s (u \ v) + ↑s (v \ u) = 0
a : 0 ≤ ↑s (u \ v)
b : 0 ≤ ↑s (v \ u)
⊢ ↑s (v \ u) = 0

case hi
α : Type u_1
inst✝ : MeasurableSpace α
s : SignedMeasure α
u v : Set α
hu : MeasurableSet u
hv : MeasurableSet v
hsu : ∀ ⦃j : Set α⦄, MeasurableSet j → j ⊆ u → ↑0 j ≤ ↑s j
hsv : 0 ≤[v] s
hs : ↑s (u ∆ v) = 0
⊢ MeasurableSet v

case hi
α : Type u_1
inst✝ : MeasurableSpace α
s : SignedMeasure α
u v : Set α
hu : MeasurableSet u
hv : MeasurableSet v
hsu : 0 ≤[u] s
hsv : 0 ≤[v] s
hs : ↑s (u ∆ v) = 0
⊢ MeasurableSet u

Tactic:
all_goals first | linarith | assumption

Result:
no goals

Proof state:
α : Type u_1
inst✝ : MeasurableSpace α
s : SignedMeasure α
u v : Set α
hu : MeasurableSet u
hv : MeasurableSet v
hsu : ∀ ⦃j : Set α⦄, MeasurableSet j → j ⊆ u → ↑0 j ≤ ↑s j
hsv : ∀ ⦃j : Set α⦄, MeasurableSet j → j ⊆ v → ↑0 j ≤ ↑s j
hs : ↑s (u \ v) + ↑s (v \ u) = 0
a : ↑0 (u \ v) ≤ ↑s (u \ v)
b : ↑0 (v \ u) ≤ ↑s (v \ u)
⊢ ↑s (u \ v) = 0 ∧ ↑s (v \ u) = 0

Tactic:
rw [zero_apply] at a b

Result:
α : Type u_1
inst✝ : MeasurableSpace α
s : SignedMeasure α
u v : Set α
hu : MeasurableSet u
hv : MeasurableSet v
hsu : ∀ ⦃j : Set α⦄, MeasurableSet j → j ⊆ u → ↑0 j ≤ ↑s j
hsv : ∀ ⦃j : Set α⦄, MeasurableSet j → j ⊆ v → ↑0 j ≤ ↑s j
hs : ↑s (u \ v) + ↑s (v \ u) = 0
a : 0 ≤ ↑s (u \ v)
b : 0 ≤ ↑s (v \ u)
⊢ ↑s (u \ v) = 0 ∧ ↑s (v \ u) = 0