Hi, I want to tell Matlab to skip the rest of the instructions and begin the next iteration "for" when the solution of X(1) is Nan. I wrote the following code but that continue in the loop "while". How can I tell MATLAB to go to the next iteration under the loop "for"?
for i = 1:100while error < 10solve equations for X(1) and X(2)if isnan(X(1)) continueenderror = X(1) - X(2)endend
Please help me. Thank you.
Best Answer