Replies: 1 comment
-
It looks like your inner QPs are getting non-convex. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi folks,
I'm working on a small demonstration that uses Model Predictive Control in a simple Matlab script, and I have run into an error that I can't quite understand. I will add the script at the end of this, as well as a quick description of what is going on (it is not a very advanced setup). To get straight to the point, this is the error that I see:
What I have found after some quick experimentation is that this error does not show until the number of variables that is solved for goes beyond a certain threshold. Additionally, having this many points is only a problem when I also use constraints on my NLP problem, which to me is quite puzzling. This may be due to me having a very shallow understanding of numerical optimization algorithms, but I suspect it's actually a problem with the Casadi / SQPmethod implementations.
Could someone take a look at this and shine some light on it for me? I'd be very happy with any help.
In the script (see below; this is basically a copy of the MPC blogposts on the Casadi blog) you can change the number of variables that is optimized over by increasing or decreasing the variable
dt
. For example, settingdt = 0.01
, the script runs perfectly fine and gives reasonable results, but a value of0.005
will result in the error I've shown before. The difference between these values ofdt
is a factor of two in the number of optimization variables.Beta Was this translation helpful? Give feedback.
All reactions