fix bug #2447 in congruence
fix bug #2447 in congruence