Equivalence iff Diagonal and Inverse Composite

Theorem
Let $$\mathcal{R}$$ be a relation on $$S$$.

Then $$\mathcal{R}$$ is an equivalence relation on $$S$$ iff $$\Delta_S \subseteq \mathcal{R}$$ and $$\mathcal{R} = \mathcal{R} \circ \mathcal{R}^{-1}$$.

Proof

 * Let $$\mathcal{R}$$ be an equivalence relation.

By definition, $$\mathcal{R}$$ is reflexive, hence $$\Delta_S \subseteq \mathcal{R}$$ from Reflexive contains Diagonal Relation.

Also, $$\mathcal{R}$$ is transitive, and so $$\mathcal{R} \circ \mathcal{R} \subseteq \mathcal{R}$$.

But as $$\mathcal{R}$$ is symmetric, $$\mathcal{R} = \mathcal{R}^{-1}$$ from Relation equals Inverse iff Symmetric.

Thus $$\mathcal{R} \circ \mathcal{R}^{-1} \subseteq \mathcal{R}$$.

So the first part has been shown: $$\Delta_S \subseteq \mathcal{R}$$ and $$\mathcal{R} = \mathcal{R} \circ \mathcal{R}^{-1}$$.


 * Now, let $$\Delta_S \subseteq \mathcal{R}$$ and $$\mathcal{R} = \mathcal{R} \circ \mathcal{R}^{-1}$$.

From Reflexive contains Diagonal Relation, $$\mathcal{R}$$ is reflexive.

...