Ternary relation
In mathematics, a ternary relation or triadic relation is a finitary relation in which the number of places in the relation is three. Ternary relations may also be referred to as 3-adic, 3-ary, 3-dimensional, or 3-place.
Just as a binary relation is formally defined as a set of pairs, i.e. a subset of the Cartesian product A × B of some sets A and B, so a ternary relation is a set of triples, forming a subset of the Cartesian product A × B × C of three sets A, B and C.
An example of a ternary relation in elementary geometry involves triples of points. In this case, a triple (A,B,C) is in the relation if the three points are collinear—that is, they lie on the same straight line. Another geometric example of a ternary relation considers triples consisting of two points and a line. Here, a triple (A,B,ℓ) belongs to the relation if the line ℓ passes through both points A and B; in other words, if the two points determine or are incident with the line.