Theorem: BoxIntegral.Box.distortion_eq_of_sub_eq_div
File: Mathlib/Analysis/BoxIntegral/Box/Basic.lean

Proof steps:
state_before: ι : Type u_1
I✝ J✝ : Box ι
x y : ι → ℝ
inst✝ : Fintype ι
I J : Box ι
r : ℝ
h : ∀ (i : ι), I.upper i - I.lower i = (J.upper i - J.lower i) / r
⊢ I.distortion = J.distortion
state_after: ι : Type u_1
I✝ J✝ : Box ι
x y : ι → ℝ
inst✝ : Fintype ι
I J : Box ι
r : ℝ
h : ∀ (i : ι), I.upper i - I.lower i = (J.upper i - J.lower i) / r
⊢ (Finset.univ.sup fun i =>
      (Finset.univ.sup fun b => Real.nnabs (J.upper b - J.lower b) / Real.nnabs r) /
        (Real.nnabs (J.upper i - J.lower i) / Real.nnabs r)) =
    Finset.univ.sup fun i =>
      (Finset.univ.sup fun b => Real.nnabs (J.upper b - J.lower b)) / Real.nnabs (J.upper i - J.lower i)
tactic: simp only [distortion, nndist_pi_def, Real.nndist_eq', h, map_div₀]
state_before: ι : Type u_1
I✝ J✝ : Box ι
x y : ι → ℝ
inst✝ : Fintype ι
I J : Box ι
r : ℝ
h : ∀ (i : ι), I.upper i - I.lower i = (J.upper i - J.lower i) / r
⊢ (Finset.univ.sup fun i =>
      (Finset.univ.sup fun b => Real.nnabs (J.upper b - J.lower b) / Real.nnabs r) /
        (Real.nnabs (J.upper i - J.lower i) / Real.nnabs r)) =
    Finset.univ.sup fun i =>
      (Finset.univ.sup fun b => Real.nnabs (J.upper b - J.lower b)) / Real.nnabs (J.upper i - J.lower i)
state_after: case e_f.h.a
ι : Type u_1
I✝ J✝ : Box ι
x y : ι → ℝ
inst✝ : Fintype ι
I J : Box ι
r : ℝ
h : ∀ (i : ι), I.upper i - I.lower i = (J.upper i - J.lower i) / r
i : ι
⊢ ↑((Finset.univ.sup fun b => Real.nnabs (J.upper b - J.lower b) / Real.nnabs r) /
        (Real.nnabs (J.upper i - J.lower i) / Real.nnabs r)) =
    ↑((Finset.univ.sup fun b => Real.nnabs (J.upper b - J.lower b)) / Real.nnabs (J.upper i - J.lower i))
tactic: congr 1 with i
state_before: case e_f.h.a
ι : Type u_1
I✝ J✝ : Box ι
x y : ι → ℝ
inst✝ : Fintype ι
I J : Box ι
r : ℝ
h : ∀ (i : ι), I.upper i - I.lower i = (J.upper i - J.lower i) / r
i : ι
⊢ ↑((Finset.univ.sup fun b => Real.nnabs (J.upper b - J.lower b) / Real.nnabs r) /
        (Real.nnabs (J.upper i - J.lower i) / Real.nnabs r)) =
    ↑((Finset.univ.sup fun b => Real.nnabs (J.upper b - J.lower b)) / Real.nnabs (J.upper i - J.lower i))
state_after: case e_f.h.a
ι : Type u_1
I✝ J✝ : Box ι
x y : ι → ℝ
inst✝ : Fintype ι
I J : Box ι
r : ℝ
h : ∀ (i : ι), I.upper i - I.lower i = (J.upper i - J.lower i) / r
i : ι
this : 0 < r
⊢ ↑((Finset.univ.sup fun b => Real.nnabs (J.upper b - J.lower b) / Real.nnabs r) /
        (Real.nnabs (J.upper i - J.lower i) / Real.nnabs r)) =
    ↑((Finset.univ.sup fun b => Real.nnabs (J.upper b - J.lower b)) / Real.nnabs (J.upper i - J.lower i))
tactic: have : 0 < r := by
    by_contra hr
    have := div_nonpos_of_nonneg_of_nonpos (sub_nonneg.2 <| J.lower_le_upper i) (not_lt.1 hr)
    rw [← h] at this
    exact this.not_lt (sub_pos.2 <| I.lower_lt_upper i)
state_before: case e_f.h.a
ι : Type u_1
I✝ J✝ : Box ι
x y : ι → ℝ
inst✝ : Fintype ι
I J : Box ι
r : ℝ
h : ∀ (i : ι), I.upper i - I.lower i = (J.upper i - J.lower i) / r
i : ι
this : 0 < r
⊢ ↑((Finset.univ.sup fun b => Real.nnabs (J.upper b - J.lower b) / Real.nnabs r) /
        (Real.nnabs (J.upper i - J.lower i) / Real.nnabs r)) =
    ↑((Finset.univ.sup fun b => Real.nnabs (J.upper b - J.lower b)) / Real.nnabs (J.upper i - J.lower i))
state_after: case e_f.h.a
ι : Type u_1
I✝ J✝ : Box ι
x y : ι → ℝ
inst✝ : Fintype ι
I J : Box ι
r : ℝ
h : ∀ (i : ι), I.upper i - I.lower i = (J.upper i - J.lower i) / r
i : ι
this : 0 < r
hn0 : Real.nnabs r ≠ 0
⊢ ↑((Finset.univ.sup fun b => Real.nnabs (J.upper b - J.lower b) / Real.nnabs r) /
        (Real.nnabs (J.upper i - J.lower i) / Real.nnabs r)) =
    ↑((Finset.univ.sup fun b => Real.nnabs (J.upper b - J.lower b)) / Real.nnabs (J.upper i - J.lower i))
tactic: have hn0 := (map_ne_zero Real.nnabs).2 this.ne'
state_before: case e_f.h.a
ι : Type u_1
I✝ J✝ : Box ι
x y : ι → ℝ
inst✝ : Fintype ι
I J : Box ι
r : ℝ
h : ∀ (i : ι), I.upper i - I.lower i = (J.upper i - J.lower i) / r
i : ι
this : 0 < r
hn0 : Real.nnabs r ≠ 0
⊢ ↑((Finset.univ.sup fun b => Real.nnabs (J.upper b - J.lower b) / Real.nnabs r) /
        (Real.nnabs (J.upper i - J.lower i) / Real.nnabs r)) =
    ↑((Finset.univ.sup fun b => Real.nnabs (J.upper b - J.lower b)) / Real.nnabs (J.upper i - J.lower i))
state_after: no goals
tactic: simp_rw [NNReal.finset_sup_div, div_div_div_cancel_right _ hn0]