Given a binary relation $\mathcal R$ over a set $A$,then the transitive closure of $\mathcal R$ over $A$ is the smallest transitive relation on $A$ containing $\mathcal R$, it's indeed the intersection of all transitive relations over $A$ that are a superset of $\mathcal R$.
The transitive closure of $\mathcal R$ is denoted by $\mathcal R^{+}$ and has the following explicit formula: $$\mathcal R^{+}=\bigcup_{n=1}^{\infty} \mathcal R^n$$
Where $\mathcal R^1=\mathcal R$, and
$\mathcal R^{n+1}=\mathcal R^n ∘ \mathcal R^1\tag{$n \in \mathbb N^+$}$
The first time I faced the formula I thought that it is not practically applicable,since it's needed to take the union of infinitely many relations (with infinity many distinct relations).
However after working with some sets I realized that it's not generally true,for example let $\mathcal R$ be a set over $A=\left\{1,2,3\right\}$ defined as $$\mathcal R:=\left\{(3,2),(2,3)\right\}$$ Then one can prove by induction that $$\mathcal R^{2n}=\left\{(3,3),(2,2)\right\}=\text{id}_A \setminus \left\{(1,1)\right\}\;,\;\mathcal R^{2n-1}=\left\{(3,2),(2,3)\right\}=\mathcal R\tag{$n \in \mathbb N^{+}$}$$
So the transitive closure of $\mathcal R$ over $A$ is given by:
$$\mathcal R^{+}=\bigcup_{n=1}^{\infty} \mathcal R^n=\left[\bigcup_{n=1}^{\infty} \mathcal R^{2n-1}\right]\cup \left[\bigcup_{n=1}^{\infty} \mathcal R^{2n}\right] $$ $$=\mathcal R \; \cup \text{id}_A \setminus \left\{(1,1)\right\}=\left\{(3,2),(2,3),(3,3),(2,2)\right\}$$
I computed the transitive closure of $\mathcal R$ over a few sets,and all of them had such a pattern,neither of them needed the union of an infinite number of infinity many distinct relation to be taken.
The questions are :
- Is this true that to determine the transitive closure of a relation $\mathcal R $ over a finite set $A$, we always just need to take the union of infinite number of finitely many distinct relations on $A$?
- If no,then give a counterexample, if yes then please prove it.
Let $A$ be a set with $n$ elements. Let $a, b \in A$ such that $a \mathcal{R}^{+} b$. Then there is a $k$ and there are are $c_{i} \in A$, for $i = 1, 2, \dots, k$, such that $$ \tag{chain} a \mathcal{R} c_{1} \mathcal{R} c_{2} \mathcal{R} \dots \mathcal{R} c_{k} \mathcal{R} b.$$ Suppose further that $k$ is smallest such that (chain) holds.
If $c_{i} = c_{j}$ for some $i < j$, we also have $a \mathcal{R} c_{1} \mathcal{R} \dots \mathcal{R} c_{i} \mathcal{R} c_{j+1} \mathcal{R} \dots \mathcal{R} b$, a shorter chain. (The same holds if $a = c_{i}$ or $c_{i} = b$ for some $i$.) Therefore we may assume that in (chain) $a, b$ and the $c_{i}$ are distinct. It follows that $k \le n - 2$, so that $$ \mathcal{R}^{+} = \bigcup_{i=1}^{n-1} \mathcal{R}^{i}. $$