My code keeps outputting this error:
i = 0;x1 = xi - f(xi)./df(xi);while abs(f(x1)) > precision i = i + 1; x1 = xi - f(x1)/df(xi)end
- Array indices must be positive integers or logical values.
Can anyone suggest a fix?
errorfaqloop
i = 0;x1 = xi - f(xi)./df(xi);while abs(f(x1)) > precision i = i + 1; x1 = xi - f(x1)/df(xi)end
Best Answer