Removing useless constraints