Documentation

Mathlib.Geometry.Euclidean.Sphere.Ptolemy

Ptolemy's theorem #

This file proves Ptolemy's theorem on the lengths of the diagonals and sides of a cyclic quadrilateral.

Main theorems #

TODO: The current statement of Ptolemy’s theorem works around the lack of a "cyclic polygon" concept in mathlib, which is what the theorem statement would naturally use (or two such concepts, since both a strict version, where all vertices must be distinct, and a weak version, where consecutive vertices may be equal, would be useful; Ptolemy's theorem should then use the weak one).

An API needs to be built around that concept, which would include:

theorem EuclideanGeometry.mul_dist_add_mul_dist_eq_mul_dist_of_cospherical {V : Type u_1} [NormedAddCommGroup V] [InnerProductSpace V] {P : Type u_2} [MetricSpace P] [NormedAddTorsor V P] {a : P} {b : P} {c : P} {d : P} {p : P} (h : EuclideanGeometry.Cospherical {a, b, c, d}) (hapc : EuclideanGeometry.angle a p c = Real.pi) (hbpd : EuclideanGeometry.angle b p d = Real.pi) :
dist a b * dist c d + dist b c * dist d a = dist a c * dist b d

Ptolemy’s Theorem.