Definition:Relation Compatible with Operation

Definition
Let $\mathcal R$ be a relation on an algebraic structure $\left({S, \circ}\right)$.

Then $\mathcal R$ is compatible with $\circ$ iff:


 * $\forall x_1, x_2, y_1, y_2 \in S: x_1 \mathcal R x_2 \land y_1 \mathcal R y_2 \implies \left({x_1 \circ y_1}\right) \mathcal R \left({x_2 \circ y_2}\right)$

This is alternatively given as:


 * $\forall x, y, z \in S: x \mathcal R y \implies \left({x \circ z}\right) \mathcal R \left({y \circ z}\right)$


 * $\forall x, y, z \in S: x \mathcal R y \implies \left({z \circ x}\right) \mathcal R \left({z \circ y}\right)$

These definitions are equivalent if $\mathcal R$ is a preorder.

The former is usually more often seen when the preorder relation in question is also an equivalence, while the latter tends to be used when the preorder is also an order.

Also see

 * Congruence relation