fix bugs by other constraints

I probably complete optimizing a simple topology