Added constraints for energy minimization
Added image example.