computing constraints. The fix also improved the constraints computation speed at least several times :)