Preliminary development. Algorithm for constraint generation is done.