Given sets A and B, any subset $R$ of $A\times B$ is a **relation **between A and B.
If
$\left(\mathrm{a,b}\right)\in R$
this is often denoted by $aRb$

If
$A=B$, $R$ is said to be a **relation**
on $A$

The **domain** of a relation $R$ between $A$ and $B$
is the set
$\{a:a\in A\mathrm{and\; there\; exists}b\in B\mathrm{so\; that}aRb\}$

The **range** of a relation $R$ between $A$ and $B$
is the set
$\{b:b\in B\mathrm{and\; there\; exists}a\in A\mathrm{so\; that}aRb\}$

Let $R$ be a relation between $A$ and $B$.
The inverse of the relation $R$ dentoed by ${R}^{-1}$
is a relation between $B$ and $A$, defined by

${R}^{-1}=\left\{\right(b,a):(a,b)\in R\}$

Let $R$ be a relation between $A$ and $B$, and let $S$ be a relation between $B$ and $C$.

The **composition** of $R$ and $S$, denoted by
$S\u25cbR$, is a relation between $A$ and $C$ defined by
$(a,b)\in S\u25cbR\mathrm{if\; there\; exists}b\in B\mathrm{such\; that}(a,b)\in R\mathrm{and}(b,c)\in S$

A relation $R$ on $A$ is **reflexive** if $aRa$
for all $a\in A$.

A relation $R$ on $A$ is **symmetric** if $aRb\to bRa$
for all $a,b\in A$.

A relation $R$ on $A$ is **antisymmetric** if $aRb\mathrm{and}bRa\mathrm{implies}a=b$.

A relation is **transitive** if whenever $aRb\mathrm{and}bRc$, then $aRc$