I am using acado python interface to get mpc control of a Heterogeneous robot system
I find that it usually get the error “max iteration reached”, especially when I set initial state far away from goal state. I don’t know what’s the problem and I want to know how to solve it? Can anyone help me please? Or at least give me some advice about how to check more specific reason?(for example how to check whether this is because I give a ill-conditioned problem)
More information that may be helpful:
I am basically making a little change for the example to solve my problem, I rewrite the model and constrains, other options parameter include:
thank you, I have checked the output of print_statistics(), and I find that the result remain unchanged from a certain iteration. While other res is close to 0, the res_stat remain a non-zero value, I guess this is abnormal? But I don’t know why and how to solve it. Thank you
I would suggest to enable line search to help the convergence of SQP methods (set globalization='MERTI_BACKTRACKING' and line_search_use_sufficient_descent=1), and print the statistics again. You might see the residuals to decrease slowly (sometimes too slow). But in general we cannot expect the solver to always converge to high precision (residuals goes to very small value like 1e-8) in a few iterations.
By my experience, getting max iteration reached is not a big problem. I can usually get reasonable solutions so I tend to ignore this warning.