changed find_global_minimum so that the gradient perturbation is not perpetually called