Examples of relations include the relation of similarity on the set of triangles in a plane, the relation on the real numbers that indicates that a first number is exactly one larger than a second number, or the relation betweem the integers and the set that the two numbers are congruent modulo .
Relations (also known as predicates) are one of the most important fundamental concepts of set theory. The most common kind of relations (including all of those mentioned in the preceding paragraph) are the binary relations, so we begin with them.
A binary relation between a set and a set is formally defined as a subset of the Cartesian product . If and , we say is related to under if . We write this as , or, more commonly, . If , we say that and are not related under .
For a more detailed treatment, see Binary relation.
An -ary relation over the sets is a subset of the Cartesian product . If for , we say are related under , and write (unfortunately though, the other short hand breaks down here) if . If , we say is an -ary relation over .