/-- Thales' theorem with vectors: if `‖c‖ = ‖a‖` (so `c` is on the circle with diameter from
`a` to `-a`), the two sides `a - c` and `-a - c` are perpendicular.
Hint: expand the inner product with `inner_sub_left`, `inner_sub_right`, `inner_neg_right`,
then use `real_inner_self_eq_norm_sq` and `real_inner_comm`. -/
theorem thales (a c : V) (h : ‖c‖ = ‖a‖) : ⟪a - c, -a - c⟫ = 0 := by
sorryShow the compiled solution
/-- **Thales' theorem**, in vectors. Put the centre of the circle at the origin. A diameter runs
from `a` to `-a`, and `c` is on the circle when `‖c‖ = ‖a‖`. Then the sides `a - c` and `-a - c`
of the triangle are perpendicular: their inner (dot) product is `‖c‖² - ‖a‖² = 0`. So the angle
in a semicircle is a right angle. -/
theorem thales (a c : V) (h : ‖c‖ = ‖a‖) : ⟪a - c, -a - c⟫ = 0 := by
have key : ⟪a - c, -a - c⟫ = ‖c‖ ^ 2 - ‖a‖ ^ 2 := by
rw [inner_sub_left, inner_sub_right, inner_sub_right, inner_neg_right, inner_neg_right,
real_inner_self_eq_norm_sq, real_inner_self_eq_norm_sq, real_inner_comm a c]
ring
rw [key, h, sub_self]Axioms used: propext, Classical.choice, Quot.soundformal/Lumenary/EuclideanGeometry.leanTry it in the Lean web editor