Take care of imaginary numbers in perfect foresight simulations

Finishing with imaginary parts now does not count as a solution and triggers a new homotopy step.