error in number of iterations