Compatibility of Congruence with Addition and Multiplication