l3lab/ntp-mathlib huggingface dataset:
/-- Auxiliary lemma for the proof of `oangle_sign_smul_add_right`; not intended to be used
outside of that proof. -/
theorem oangle_smul_add_right_eq_zero_or_eq_pi_iff {x y : V} (r : ℝ) :
    o.oangle x (r • x + y) = 0 ∨ o.oangle x (r • x + y) = π ↔
    o.oangle x y = 0 ∨ o.oangle x y = π := by
  simp_rw [oangle_eq_zero_or_eq_pi_iff_not_linearIndependent, Fintype.not_linearIndependent_iff]
  -- Porting note: at this point all occurences of the bound variable `i` are of type
  -- `Fin (Nat.succ (Nat.succ 0))`, but `Fin.sum_univ_two` and `Fin.exists_fin_two` expect it to be
  -- `Fin 2` instead. Hence all the `conv`s.
  -- Was `simp_rw [Fin.sum_univ_two, Fin.exists_fin_two]`
  conv_lhs => enter [1, g, 1, 1, 2, i]; tactic => change Fin 2 at i
  conv_lhs => enter [1, g]; rw [Fin.sum_univ_two]
  conv_rhs => enter [1, g, 1, 1, 2, i]; tactic => change Fin 2 at i
  conv_rhs => enter [1, g]; rw [Fin.sum_univ_two]
  conv_lhs => enter [1, g, 2, 1, i]; tactic => change Fin 2 at i
  conv_lhs => enter [1, g]; rw [Fin.exists_fin_two]
  conv_rhs => enter [1, g, 2, 1, i]; tactic => change Fin 2 at i
  conv_rhs => enter [1, g]; 

Proof state:
case h
V : Type u_1
V' : Type u_2
inst✝⁵ : NormedAddCommGroup V
inst✝⁴ : NormedAddCommGroup V'
inst✝³ : InnerProductSpace ℝ V
inst✝² : InnerProductSpace ℝ V'
inst✝¹ : Fact (finrank ℝ V = 2)
inst✝ : Fact (finrank ℝ V' = 2)
o : Orientation ℝ V (Fin 2)
x y : V
r : ℝ
g : Fin (Nat.succ (Nat.succ 0)) → ℝ
| g 0 • Matrix.vecCons x ![y] 0 + g 1 • Matrix.vecCons x ![y] 1 = 0 ∧ ∃ i, g i ≠ 0

Next tactic:
rw [Fin.exists_fin_two]
/-- Auxiliary lemma for the proof of `oangle_sign_smul_add_right`; not intended to be used
outside of that proof. -/
theorem oangle_smul_add_right_eq_zero_or_eq_pi_iff {x y : V} (r : ℝ) :
    o.oangle x (r • x + y) = 0 ∨ o.oangle x (r • x + y) = π ↔
    o.oangle x y = 0 ∨ o.oangle x y = π := by
  simp_rw [oangle_eq_zero_or_eq_pi_iff_not_linearIndependent, Fintype.not_linearIndependent_iff]
  -- Porting note: at this point all occurences of the bound variable `i` are of type
  -- `Fin (Nat.succ (Nat.succ 0))`, but `Fin.sum_univ_two` and `Fin.exists_fin_two` expect it to be
  -- `Fin 2` instead. Hence all the `conv`s.
  -- Was `simp_rw [Fin.sum_univ_two, Fin.exists_fin_two]`
  conv_lhs => enter [1, g, 1, 1, 2, i]; tactic => change Fin 2 at i
  conv_lhs => enter [1, g]; rw [Fin.sum_univ_two]
  conv_rhs => enter [1, g, 1, 1, 2, i]; tactic => change Fin 2 at i
  conv_rhs => enter [1, g]; rw [Fin.sum_univ_two]
  conv_lhs => enter [1, g, 2, 1, i]; tactic => change Fin 2 at i
  conv_lhs => enter [1, g]; rw [Fin.exists_fin_two]
  conv_rhs => enter [1, g, 2, 1, i]; tactic => change Fin 2 at i
  conv_rhs => enter [1, g]; rw [Fin.exists_fin_two]
  

Proof state:
V : Type u_1
V' : Type u_2
inst✝⁵ : NormedAddCommGroup V
inst✝⁴ : NormedAddCommGroup V'
inst✝³ : InnerProductSpace ℝ V
inst✝² : InnerProductSpace ℝ V'
inst✝¹ : Fact (finrank ℝ V = 2)
inst✝ : Fact (finrank ℝ V' = 2)
o : Orientation ℝ V (Fin 2)
x y : V
r : ℝ
⊢ (∃ g, g 0 • Matrix.vecCons x ![r • x + y] 0 + g 1 • Matrix.vecCons x ![r • x + y] 1 = 0 ∧ (g 0 ≠ 0 ∨ g 1 ≠ 0)) ↔
    ∃ g, g 0 • Matrix.vecCons x ![y] 0 + g 1 • Matrix.vecCons x ![y] 1 = 0 ∧ (g 0 ≠ 0 ∨ g 1 ≠ 0)

Next tactic:
refine' ⟨fun h => _, fun h => _⟩
/-- Auxiliary lemma for the proof of `oangle_sign_smul_add_right`; not intended to be used
outside of that proof. -/
theorem oangle_smul_add_right_eq_zero_or_eq_pi_iff {x y : V} (r : ℝ) :
    o.oangle x (r • x + y) = 0 ∨ o.oangle x (r • x + y) = π ↔
    o.oangle x y = 0 ∨ o.oangle x y = π := by
  simp_rw [oangle_eq_zero_or_eq_pi_iff_not_linearIndependent, Fintype.not_linearIndependent_iff]
  -- Porting note: at this point all occurences of the bound variable `i` are of type
  -- `Fin (Nat.succ (Nat.succ 0))`, but `Fin.sum_univ_two` and `Fin.exists_fin_two` expect it to be
  -- `Fin 2` instead. Hence all the `conv`s.
  -- Was `simp_rw [Fin.sum_univ_two, Fin.exists_fin_two]`
  conv_lhs => enter [1, g, 1, 1, 2, i]; tactic => change Fin 2 at i
  conv_lhs => enter [1, g]; rw [Fin.sum_univ_two]
  conv_rhs => enter [1, g, 1, 1, 2, i]; tactic => change Fin 2 at i
  conv_rhs => enter [1, g]; rw [Fin.sum_univ_two]
  conv_lhs => enter [1, g, 2, 1, i]; tactic => change Fin 2 at i
  conv_lhs => enter [1, g]; rw [Fin.exists_fin_two]
  conv_rhs => enter [1, g, 2, 1, i]; tactic => change Fin 2 at i
  conv_rhs => enter [1, g]; rw [Fin.exists_fin_two]
  refine' ⟨fun h => _, fun h => _⟩
  · 

Proof state:
case refine'_1
V : Type u_1
V' : Type u_2
inst✝⁵ : NormedAddCommGroup V
inst✝⁴ : NormedAddCommGroup V'
inst✝³ : InnerProductSpace ℝ V
inst✝² : InnerProductSpace ℝ V'
inst✝¹ : Fact (finrank ℝ V = 2)
inst✝ : Fact (finrank ℝ V' = 2)
o : Orientation ℝ V (Fin 2)
x y : V
r : ℝ
h : ∃ g, g 0 • Matrix.vecCons x ![r • x + y] 0 + g 1 • Matrix.vecCons x ![r • x + y] 1 = 0 ∧ (g 0 ≠ 0 ∨ g 1 ≠ 0)
⊢ ∃ g, g 0 • Matrix.vecCons x ![y] 0 + g 1 • Matrix.vecCons x ![y] 1 = 0 ∧ (g 0 ≠ 0 ∨ g 1 ≠ 0)

Next tactic:
rcases h with ⟨m, h, hm⟩
/-- Auxiliary lemma for the proof of `oangle_sign_smul_add_right`; not intended to be used
outside of that proof. -/
theorem oangle_smul_add_right_eq_zero_or_eq_pi_iff {x y : V} (r : ℝ) :
    o.oangle x (r • x + y) = 0 ∨ o.oangle x (r • x + y) = π ↔
    o.oangle x y = 0 ∨ o.oangle x y = π := by
  simp_rw [oangle_eq_zero_or_eq_pi_iff_not_linearIndependent, Fintype.not_linearIndependent_iff]
  -- Porting note: at this point all occurences of the bound variable `i` are of type
  -- `Fin (Nat.succ (Nat.succ 0))`, but `Fin.sum_univ_two` and `Fin.exists_fin_two` expect it to be
  -- `Fin 2` instead. Hence all the `conv`s.
  -- Was `simp_rw [Fin.sum_univ_two, Fin.exists_fin_two]`
  conv_lhs => enter [1, g, 1, 1, 2, i]; tactic => change Fin 2 at i
  conv_lhs => enter [1, g]; rw [Fin.sum_univ_two]
  conv_rhs => enter [1, g, 1, 1, 2, i]; tactic => change Fin 2 at i
  conv_rhs => enter [1, g]; rw [Fin.sum_univ_two]
  conv_lhs => enter [1, g, 2, 1, i]; tactic => change Fin 2 at i
  conv_lhs => enter [1, g]; rw [Fin.exists_fin_two]
  conv_rhs => enter [1, g, 2, 1, i]; tactic => change Fin 2 at i
  conv_rhs => enter [1, g]; rw [Fin.exists_fin_two]
  refine' ⟨fun h => _, fun h => _⟩
  · rcases h with ⟨m, h, hm⟩
    

Proof state:
case refine'_1.intro.intro
V : Type u_1
V' : Type u_2
inst✝⁵ : NormedAddCommGroup V
inst✝⁴ : NormedAddCommGroup V'
inst✝³ : InnerProductSpace ℝ V
inst✝² : InnerProductSpace ℝ V'
inst✝¹ : Fact (finrank ℝ V = 2)
inst✝ : Fact (finrank ℝ V' = 2)
o : Orientation ℝ V (Fin 2)
x y : V
r : ℝ
m : Fin (Nat.succ (Nat.succ 0)) → ℝ
h : m 0 • Matrix.vecCons x ![r • x + y] 0 + m 1 • Matrix.vecCons x ![r • x + y] 1 = 0
hm : m 0 ≠ 0 ∨ m 1 ≠ 0
⊢ ∃ g, g 0 • Matrix.vecCons x ![y] 0 + g 1 • Matrix.vecCons x ![y] 1 = 0 ∧ (g 0 ≠ 0 ∨ g 1 ≠ 0)

Next tactic:
change m 0 • x + m 1 • (r • x + y) = 0 at h
/-- Auxiliary lemma for the proof of `oangle_sign_smul_add_right`; not intended to be used
outside of that proof. -/
theorem oangle_smul_add_right_eq_zero_or_eq_pi_iff {x y : V} (r : ℝ) :
    o.oangle x (r • x + y) = 0 ∨ o.oangle x (r • x + y) = π ↔
    o.oangle x y = 0 ∨ o.oangle x y = π := by
  simp_rw [oangle_eq_zero_or_eq_pi_iff_not_linearIndependent, Fintype.not_linearIndependent_iff]
  -- Porting note: at this point all occurences of the bound variable `i` are of type
  -- `Fin (Nat.succ (Nat.succ 0))`, but `Fin.sum_univ_two` and `Fin.exists_fin_two` expect it to be
  -- `Fin 2` instead. Hence all the `conv`s.
  -- Was `simp_rw [Fin.sum_univ_two, Fin.exists_fin_two]`
  conv_lhs => enter [1, g, 1, 1, 2, i]; tactic => change Fin 2 at i
  conv_lhs => enter [1, g]; rw [Fin.sum_univ_two]
  conv_rhs => enter [1, g, 1, 1, 2, i]; tactic => change Fin 2 at i
  conv_rhs => enter [1, g]; rw [Fin.sum_univ_two]
  conv_lhs => enter [1, g, 2, 1, i]; tactic => change Fin 2 at i
  conv_lhs => enter [1, g]; rw [Fin.exists_fin_two]
  conv_rhs => enter [1, g, 2, 1, i]; tactic => change Fin 2 at i
  conv_rhs => enter [1, g]; rw [Fin.exists_fin_two]
  refine' ⟨fun h => _, fun h => _⟩
  · rcases h with ⟨m, h, hm⟩
    change m 0 • x + m 1 • (r • x + y) = 0 at h
    

Proof state:
case refine'_1.intro.intro
V : Type u_1
V' : Type u_2
inst✝⁵ : NormedAddCommGroup V
inst✝⁴ : NormedAddCommGroup V'
inst✝³ : InnerProductSpace ℝ V
inst✝² : InnerProductSpace ℝ V'
inst✝¹ : Fact (finrank ℝ V = 2)
inst✝ : Fact (finrank ℝ V' = 2)
o : Orientation ℝ V (Fin 2)
x y : V
r : ℝ
m : Fin (Nat.succ (Nat.succ 0)) → ℝ
hm : m 0 ≠ 0 ∨ m 1 ≠ 0
h : m 0 • x + m 1 • (r • x + y) = 0
⊢ ∃ g, g 0 • Matrix.vecCons x ![y] 0 + g 1 • Matrix.vecCons x ![y] 1 = 0 ∧ (g 0 ≠ 0 ∨ g 1 ≠ 0)

Next tactic:
refine' ⟨![m 0 + m 1 * r, m 1], _⟩
/-- Auxiliary lemma for the proof of `oangle_sign_smul_add_right`; not intended to be used
outside of that proof. -/
theorem oangle_smul_add_right_eq_zero_or_eq_pi_iff {x y : V} (r : ℝ) :
    o.oangle x (r • x + y) = 0 ∨ o.oangle x (r • x + y) = π ↔
    o.oangle x y = 0 ∨ o.oangle x y = π := by
  simp_rw [oangle_eq_zero_or_eq_pi_iff_not_linearIndependent, Fintype.not_linearIndependent_iff]
  -- Porting note: at this point all occurences of the bound variable `i` are of type
  -- `Fin (Nat.succ (Nat.succ 0))`, but `Fin.sum_univ_two` and `Fin.exists_fin_two` expect it to be
  -- `Fin 2` instead. Hence all the `conv`s.
  -- Was `simp_rw [Fin.sum_univ_two, Fin.exists_fin_two]`
  conv_lhs => enter [1, g, 1, 1, 2, i]; tactic => change Fin 2 at i
  conv_lhs => enter [1, g]; rw [Fin.sum_univ_two]
  conv_rhs => enter [1, g, 1, 1, 2, i]; tactic => change Fin 2 at i
  conv_rhs => enter [1, g]; rw [Fin.sum_univ_two]
  conv_lhs => enter [1, g, 2, 1, i]; tactic => change Fin 2 at i
  conv_lhs => enter [1, g]; rw [Fin.exists_fin_two]
  conv_rhs => enter [1, g, 2, 1, i]; tactic => change Fin 2 at i
  conv_rhs => enter [1, g]; rw [Fin.exists_fin_two]
  refine' ⟨fun h => _, fun h => _⟩
  · rcases h with ⟨m, h, hm⟩
    change m 0 • x + m 1 • (r • x + y) = 0 at h
    refine' ⟨![m 0 + m 1 * r, m 1], _⟩
    

Proof state:
case refine'_1.intro.intro
V : Type u_1
V' : Type u_2
inst✝⁵ : NormedAddCommGroup V
inst✝⁴ : NormedAddCommGroup V'
inst✝³ : InnerProductSpace ℝ V
inst✝² : InnerProductSpace ℝ V'
inst✝¹ : Fact (finrank ℝ V = 2)
inst✝ : Fact (finrank ℝ V' = 2)
o : Orientation ℝ V (Fin 2)
x y : V
r : ℝ
m : Fin (Nat.succ (Nat.succ 0)) → ℝ
hm : m 0 ≠ 0 ∨ m 1 ≠ 0
h : m 0 • x + m 1 • (r • x + y) = 0
⊢ Matrix.vecCons (m 0 + m 1 * r) ![m 1] 0 • Matrix.vecCons x ![y] 0 +
        Matrix.vecCons (m 0 + m 1 * r) ![m 1] 1 • Matrix.vecCons x ![y] 1 =
      0 ∧
    (Matrix.vecCons (m 0 + m 1 * r) ![m 1] 0 ≠ 0 ∨ Matrix.vecCons (m 0 + m 1 * r) ![m 1] 1 ≠ 0)

Next tactic:
change (m 0 + m 1 * r) • x + m 1 • y = 0 ∧ (m 0 + m 1 * r ≠ 0 ∨ m 1 ≠ 0)
/-- Auxiliary lemma for the proof of `oangle_sign_smul_add_right`; not intended to be used
outside of that proof. -/
theorem oangle_smul_add_right_eq_zero_or_eq_pi_iff {x y : V} (r : ℝ) :
    o.oangle x (r • x + y) = 0 ∨ o.oangle x (r • x + y) = π ↔
    o.oangle x y = 0 ∨ o.oangle x y = π := by
  simp_rw [oangle_eq_zero_or_eq_pi_iff_not_linearIndependent, Fintype.not_linearIndependent_iff]
  -- Porting note: at this point all occurences of the bound variable `i` are of type
  -- `Fin (Nat.succ (Nat.succ 0))`, but `Fin.sum_univ_two` and `Fin.exists_fin_two` expect it to be
  -- `Fin 2` instead. Hence all the `conv`s.
  -- Was `simp_rw [Fin.sum_univ_two, Fin.exists_fin_two]`
  conv_lhs => enter [1, g, 1, 1, 2, i]; tactic => change Fin 2 at i
  conv_lhs => enter [1, g]; rw [Fin.sum_univ_two]
  conv_rhs => enter [1, g, 1, 1, 2, i]; tactic => change Fin 2 at i
  conv_rhs => enter [1, g]; rw [Fin.sum_univ_two]
  conv_lhs => enter [1, g, 2, 1, i]; tactic => change Fin 2 at i
  conv_lhs => enter [1, g]; rw [Fin.exists_fin_two]
  conv_rhs => enter [1, g, 2, 1, i]; tactic => change Fin 2 at i
  conv_rhs => enter [1, g]; rw [Fin.exists_fin_two]
  refine' ⟨fun h => _, fun h => _⟩
  · rcases h with ⟨m, h, hm⟩
    change m 0 • x + m 1 • (r • x + y) = 0 at h
    refine' ⟨![m 0 + m 1 * r, m 1], _⟩
    change (m 0 + m 1 * r) • x + m 1 • y = 0 ∧ (m 0 + m 1 * r ≠ 0 ∨ m 1 ≠ 0)
    

Proof state:
case refine'_1.intro.intro
V : Type u_1
V' : Type u_2
inst✝⁵ : NormedAddCommGroup V
inst✝⁴ : NormedAddCommGroup V'
inst✝³ : InnerProductSpace ℝ V
inst✝² : InnerProductSpace ℝ V'
inst✝¹ : Fact (finrank ℝ V = 2)
inst✝ : Fact (finrank ℝ V' = 2)
o : Orientation ℝ V (Fin 2)
x y : V
r : ℝ
m : Fin (Nat.succ (Nat.succ 0)) → ℝ
hm : m 0 ≠ 0 ∨ m 1 ≠ 0
h : m 0 • x + m 1 • (r • x + y) = 0
⊢ (m 0 + m 1 * r) • x + m 1 • y = 0 ∧ (m 0 + m 1 * r ≠ 0 ∨ m 1 ≠ 0)

Next tactic:
rw [smul_add, smul_smul, ← add_assoc, ← add_smul] at h
/-- Auxiliary lemma for the proof of `oangle_sign_smul_add_right`; not intended to be used
outside of that proof. -/
theorem oangle_smul_add_right_eq_zero_or_eq_pi_iff {x y : V} (r : ℝ) :
    o.oangle x (r • x + y) = 0 ∨ o.oangle x (r • x + y) = π ↔
    o.oangle x y = 0 ∨ o.oangle x y = π := by
  simp_rw [oangle_eq_zero_or_eq_pi_iff_not_linearIndependent, Fintype.not_linearIndependent_iff]
  -- Porting note: at this point all occurences of the bound variable `i` are of type
  -- `Fin (Nat.succ (Nat.succ 0))`, but `Fin.sum_univ_two` and `Fin.exists_fin_two` expect it to be
  -- `Fin 2` instead. Hence all the `conv`s.
  -- Was `simp_rw [Fin.sum_univ_two, Fin.exists_fin_two]`
  conv_lhs => enter [1, g, 1, 1, 2, i]; tactic => change Fin 2 at i
  conv_lhs => enter [1, g]; rw [Fin.sum_univ_two]
  conv_rhs => enter [1, g, 1, 1, 2, i]; tactic => change Fin 2 at i
  conv_rhs => enter [1, g]; rw [Fin.sum_univ_two]
  conv_lhs => enter [1, g, 2, 1, i]; tactic => change Fin 2 at i
  conv_lhs => enter [1, g]; rw [Fin.exists_fin_two]
  conv_rhs => enter [1, g, 2, 1, i]; tactic => change Fin 2 at i
  conv_rhs => enter [1, g]; rw [Fin.exists_fin_two]
  refine' ⟨fun h => _, fun h => _⟩
  · rcases h with ⟨m, h, hm⟩
    change m 0 • x + m 1 • (r • x + y) = 0 at h
    refine' ⟨![m 0 + m 1 * r, m 1], _⟩
    change (m 0 + m 1 * r) • x + m 1 • y = 0 ∧ (m 0 + m 1 * r ≠ 0 ∨ m 1 ≠ 0)
    rw [smul_add, smul_smul, ← add_assoc, ← add_smul] at h
    

Proof state:
case refine'_1.intro.intro
V : Type u_1
V' : Type u_2
inst✝⁵ : NormedAddCommGroup V
inst✝⁴ : NormedAddCommGroup V'
inst✝³ : InnerProductSpace ℝ V
inst✝² : InnerProductSpace ℝ V'
inst✝¹ : Fact (finrank ℝ V = 2)
inst✝ : Fact (finrank ℝ V' = 2)
o : Orientation ℝ V (Fin 2)
x y : V
r : ℝ
m : Fin (Nat.succ (Nat.succ 0)) → ℝ
hm : m 0 ≠ 0 ∨ m 1 ≠ 0
h : (m 0 + m 1 * r) • x + m 1 • y = 0
⊢ (m 0 + m 1 * r) • x + m 1 • y = 0 ∧ (m 0 + m 1 * r ≠ 0 ∨ m 1 ≠ 0)

Next tactic:
refine' ⟨h, not_and_or.1 fun h0 => _⟩
/-- Auxiliary lemma for the proof of `oangle_sign_smul_add_right`; not intended to be used
outside of that proof. -/
theorem oangle_smul_add_right_eq_zero_or_eq_pi_iff {x y : V} (r : ℝ) :
    o.oangle x (r • x + y) = 0 ∨ o.oangle x (r • x + y) = π ↔
    o.oangle x y = 0 ∨ o.oangle x y = π := by
  simp_rw [oangle_eq_zero_or_eq_pi_iff_not_linearIndependent, Fintype.not_linearIndependent_iff]
  -- Porting note: at this point all occurences of the bound variable `i` are of type
  -- `Fin (Nat.succ (Nat.succ 0))`, but `Fin.sum_univ_two` and `Fin.exists_fin_two` expect it to be
  -- `Fin 2` instead. Hence all the `conv`s.
  -- Was `simp_rw [Fin.sum_univ_two, Fin.exists_fin_two]`
  conv_lhs => enter [1, g, 1, 1, 2, i]; tactic => change Fin 2 at i
  conv_lhs => enter [1, g]; rw [Fin.sum_univ_two]
  conv_rhs => enter [1, g, 1, 1, 2, i]; tactic => change Fin 2 at i
  conv_rhs => enter [1, g]; rw [Fin.sum_univ_two]
  conv_lhs => enter [1, g, 2, 1, i]; tactic => change Fin 2 at i
  conv_lhs => enter [1, g]; rw [Fin.exists_fin_two]
  conv_rhs => enter [1, g, 2, 1, i]; tactic => change Fin 2 at i
  conv_rhs => enter [1, g]; rw [Fin.exists_fin_two]
  refine' ⟨fun h => _, fun h => _⟩
  · rcases h with ⟨m, h, hm⟩
    change m 0 • x + m 1 • (r • x + y) = 0 at h
    refine' ⟨![m 0 + m 1 * r, m 1], _⟩
    change (m 0 + m 1 * r) • x + m 1 • y = 0 ∧ (m 0 + m 1 * r ≠ 0 ∨ m 1 ≠ 0)
    rw [smul_add, smul_smul, ← add_assoc, ← add_smul] at h
    refine' ⟨h, not_and_or.1 fun h0 => _⟩
    

Proof state:
case refine'_1.intro.intro
V : Type u_1
V' : Type u_2
inst✝⁵ : NormedAddCommGroup V
inst✝⁴ : NormedAddCommGroup V'
inst✝³ : InnerProductSpace ℝ V
inst✝² : InnerProductSpace ℝ V'
inst✝¹ : Fact (finrank ℝ V = 2)
inst✝ : Fact (finrank ℝ V' = 2)
o : Orientation ℝ V (Fin 2)
x y : V
r : ℝ
m : Fin (Nat.succ (Nat.succ 0)) → ℝ
hm : m 0 ≠ 0 ∨ m 1 ≠ 0
h : (m 0 + m 1 * r) • x + m 1 • y = 0
h0 : m 0 + m 1 * r = 0 ∧ m 1 = 0
⊢ False

Next tactic:
obtain ⟨h0, h1⟩ := h0
/-- Auxiliary lemma for the proof of `oangle_sign_smul_add_right`; not intended to be used
outside of that proof. -/
theorem oangle_smul_add_right_eq_zero_or_eq_pi_iff {x y : V} (r : ℝ) :
    o.oangle x (r • x + y) = 0 ∨ o.oangle x (r • x + y) = π ↔
    o.oangle x y = 0 ∨ o.oangle x y = π := by
  simp_rw [oangle_eq_zero_or_eq_pi_iff_not_linearIndependent, Fintype.not_linearIndependent_iff]
  -- Porting note: at this point all occurences of the bound variable `i` are of type
  -- `Fin (Nat.succ (Nat.succ 0))`, but `Fin.sum_univ_two` and `Fin.exists_fin_two` expect it to be
  -- `Fin 2` instead. Hence all the `conv`s.
  -- Was `simp_rw [Fin.sum_univ_two, Fin.exists_fin_two]`
  conv_lhs => enter [1, g, 1, 1, 2, i]; tactic => change Fin 2 at i
  conv_lhs => enter [1, g]; rw [Fin.sum_univ_two]
  conv_rhs => enter [1, g, 1, 1, 2, i]; tactic => change Fin 2 at i
  conv_rhs => enter [1, g]; rw [Fin.sum_univ_two]
  conv_lhs => enter [1, g, 2, 1, i]; tactic => change Fin 2 at i
  conv_lhs => enter [1, g]; rw [Fin.exists_fin_two]
  conv_rhs => enter [1, g, 2, 1, i]; tactic => change Fin 2 at i
  conv_rhs => enter [1, g]; rw [Fin.exists_fin_two]
  refine' ⟨fun h => _, fun h => _⟩
  · rcases h with ⟨m, h, hm⟩
    change m 0 • x + m 1 • (r • x + y) = 0 at h
    refine' ⟨![m 0 + m 1 * r, m 1], _⟩
    change (m 0 + m 1 * r) • x + m 1 • y = 0 ∧ (m 0 + m 1 * r ≠ 0 ∨ m 1 ≠ 0)
    rw [smul_add, smul_smul, ← add_assoc, ← add_smul] at h
    refine' ⟨h, not_and_or.1 fun h0 => _⟩
    obtain ⟨h0, h1⟩ := h0
    

Proof state:
case refine'_1.intro.intro.intro
V : Type u_1
V' : Type u_2
inst✝⁵ : NormedAddCommGroup V
inst✝⁴ : NormedAddCommGroup V'
inst✝³ : InnerProductSpace ℝ V
inst✝² : InnerProductSpace ℝ V'
inst✝¹ : Fact (finrank ℝ V = 2)
inst✝ : Fact (finrank ℝ V' = 2)
o : Orientation ℝ V (Fin 2)
x y : V
r : ℝ
m : Fin (Nat.succ (Nat.succ 0)) → ℝ
hm : m 0 ≠ 0 ∨ m 1 ≠ 0
h : (m 0 + m 1 * r) • x + m 1 • y = 0
h0 : m 0 + m 1 * r = 0
h1 : m 1 = 0
⊢ False

Next tactic:
rw [h1] at h0 hm
/-- Auxiliary lemma for the proof of `oangle_sign_smul_add_right`; not intended to be used
outside of that proof. -/
theorem oangle_smul_add_right_eq_zero_or_eq_pi_iff {x y : V} (r : ℝ) :
    o.oangle x (r • x + y) = 0 ∨ o.oangle x (r • x + y) = π ↔
    o.oangle x y = 0 ∨ o.oangle x y = π := by
  simp_rw [oangle_eq_zero_or_eq_pi_iff_not_linearIndependent, Fintype.not_linearIndependent_iff]
  -- Porting note: at this point all occurences of the bound variable `i` are of type
  -- `Fin (Nat.succ (Nat.succ 0))`, but `Fin.sum_univ_two` and `Fin.exists_fin_two` expect it to be
  -- `Fin 2` instead. Hence all the `conv`s.
  -- Was `simp_rw [Fin.sum_univ_two, Fin.exists_fin_two]`
  conv_lhs => enter [1, g, 1, 1, 2, i]; tactic => change Fin 2 at i
  conv_lhs => enter [1, g]; rw [Fin.sum_univ_two]
  conv_rhs => enter [1, g, 1, 1, 2, i]; tactic => change Fin 2 at i
  conv_rhs => enter [1, g]; rw [Fin.sum_univ_two]
  conv_lhs => enter [1, g, 2, 1, i]; tactic => change Fin 2 at i
  conv_lhs => enter [1, g]; rw [Fin.exists_fin_two]
  conv_rhs => enter [1, g, 2, 1, i]; tactic => change Fin 2 at i
  conv_rhs => enter [1, g]; rw [Fin.exists_fin_two]
  refine' ⟨fun h => _, fun h => _⟩
  · rcases h with ⟨m, h, hm⟩
    change m 0 • x + m 1 • (r • x + y) = 0 at h
    refine' ⟨![m 0 + m 1 * r, m 1], _⟩
    change (m 0 + m 1 * r) • x + m 1 • y = 0 ∧ (m 0 + m 1 * r ≠ 0 ∨ m 1 ≠ 0)
    rw [smul_add, smul_smul, ← add_assoc, ← add_smul] at h
    refine' ⟨h, not_and_or.1 fun h0 => _⟩
    obtain ⟨h0, h1⟩ := h0
    rw [h1] at h0 hm
    

Proof state:
case refine'_1.intro.intro.intro
V : Type u_1
V' : Type u_2
inst✝⁵ : NormedAddCommGroup V
inst✝⁴ : NormedAddCommGroup V'
inst✝³ : InnerProductSpace ℝ V
inst✝² : InnerProductSpace ℝ V'
inst✝¹ : Fact (finrank ℝ V = 2)
inst✝ : Fact (finrank ℝ V' = 2)
o : Orientation ℝ V (Fin 2)
x y : V
r : ℝ
m : Fin (Nat.succ (Nat.succ 0)) → ℝ
hm : m 0 ≠ 0 ∨ 0 ≠ 0
h : (m 0 + m 1 * r) • x + m 1 • y = 0
h0 : m 0 + 0 * r = 0
h1 : m 1 = 0
⊢ False

Next tactic:
rw [zero_mul, add_zero] at h0
/-- Auxiliary lemma for the proof of `oangle_sign_smul_add_right`; not intended to be used
outside of that proof. -/
theorem oangle_smul_add_right_eq_zero_or_eq_pi_iff {x y : V} (r : ℝ) :
    o.oangle x (r • x + y) = 0 ∨ o.oangle x (r • x + y) = π ↔
    o.oangle x y = 0 ∨ o.oangle x y = π := by
  simp_rw [oangle_eq_zero_or_eq_pi_iff_not_linearIndependent, Fintype.not_linearIndependent_iff]
  -- Porting note: at this point all occurences of the bound variable `i` are of type
  -- `Fin (Nat.succ (Nat.succ 0))`, but `Fin.sum_univ_two` and `Fin.exists_fin_two` expect it to be
  -- `Fin 2` instead. Hence all the `conv`s.
  -- Was `simp_rw [Fin.sum_univ_two, Fin.exists_fin_two]`
  conv_lhs => enter [1, g, 1, 1, 2, i]; tactic => change Fin 2 at i
  conv_lhs => enter [1, g]; rw [Fin.sum_univ_two]
  conv_rhs => enter [1, g, 1, 1, 2, i]; tactic => change Fin 2 at i
  conv_rhs => enter [1, g]; rw [Fin.sum_univ_two]
  conv_lhs => enter [1, g, 2, 1, i]; tactic => change Fin 2 at i
  conv_lhs => enter [1, g]; rw [Fin.exists_fin_two]
  conv_rhs => enter [1, g, 2, 1, i]; tactic => change Fin 2 at i
  conv_rhs => enter [1, g]; rw [Fin.exists_fin_two]
  refine' ⟨fun h => _, fun h => _⟩
  · rcases h with ⟨m, h, hm⟩
    change m 0 • x + m 1 • (r • x + y) = 0 at h
    refine' ⟨![m 0 + m 1 * r, m 1], _⟩
    change (m 0 + m 1 * r) • x + m 1 • y = 0 ∧ (m 0 + m 1 * r ≠ 0 ∨ m 1 ≠ 0)
    rw [smul_add, smul_smul, ← add_assoc, ← add_smul] at h
    refine' ⟨h, not_and_or.1 fun h0 => _⟩
    obtain ⟨h0, h1⟩ := h0
    rw [h1] at h0 hm
    rw [zero_mul, add_zero] at h0
    

Proof state:
case refine'_1.intro.intro.intro
V : Type u_1
V' : Type u_2
inst✝⁵ : NormedAddCommGroup V
inst✝⁴ : NormedAddCommGroup V'
inst✝³ : InnerProductSpace ℝ V
inst✝² : InnerProductSpace ℝ V'
inst✝¹ : Fact (finrank ℝ V = 2)
inst✝ : Fact (finrank ℝ V' = 2)
o : Orientation ℝ V (Fin 2)
x y : V
r : ℝ
m : Fin (Nat.succ (Nat.succ 0)) → ℝ
hm : m 0 ≠ 0 ∨ 0 ≠ 0
h : (m 0 + m 1 * r) • x + m 1 • y = 0
h0 : m 0 = 0
h1 : m 1 = 0
⊢ False

Next tactic:
simp [h0] at hm