Add a termination condition - stop if energy is no longer changing