A metric on a finite set satisfies the
four-point condition if, for every four points
,
,
, and
, the two largest of the three numbers
are equal. Equivalently, the maximum of the three numbers is attained at least twice.
A finite metric satisfies the four-point condition iff it is a tree metric. This criterion is consequently used to recognize when a distance matrix can be represented by distances in an edge-weighted tree.