Definition: When \(A\) and \(B\) are sets, we say any subset of \(A \times B\) is a binary relation. A relation \(R\) can also be represented as
A function \(f_{TF} : A \times B \to \{T, F\}\) where, for \(a \in A\) and \(b \in B\), \(f_{TF}(~(a,b)~) = \begin{cases} T \qquad&\text{when } (a,b) \in R \\ F \qquad&\text{when } (a,b) \notin R \end{cases}\)
A function \(f_{\mathcal{P}} : A \to \mathcal{P}(B)\) where, for \(a \in A\), \(f_{\mathcal{P}}( a ) = \{ b \in B ~|~ (a,b) \in R \}\)
When \(A\) is a set, we say any subset of \(A \times A\) is a (binary) relation on \(A\).