Nelder Mead method convergence method modified