Menu

Advanced constraints for code generation

2015-02-23
2015-02-24
  • Espen Skjong

    Espen Skjong - 2015-02-23

    Hi,

    I was trying to implement more advanced constraints when using code generation with EXACT_HESSIAN (FULL_CONDENSING_N2):

    ocp.subjectTo( -0.5 <= u(0) + sqrt(3)/3*u(1) <= 0.5);

    However, when compiling and running the code generation an error message appears: "Error: Requested function is not yet implemented". Do anyone know if these kind of constraints are/will be supported? I tried to make an algebraic state representing the expression in the constraint, but that did not pan out as it gave segmentation fault...

     
  • Rien Quirynen

    Rien Quirynen - 2015-02-24

    Hey,

    This feature of having more complex (affine and/or nonlinear) constraints is indeed not yet implemented for all solvers based on N2 condensing (so both Gauss-Newton and Exact Hessian based). It is expected to be implemented in the next months, but it is hard to say when exactly as our development team is currently very limited.

    Your proposed fix with an algebraic variable won't work either, since these algebraic variables are not (yet) allowed to appear in objective and/or constraint functions (support for this probably will come later even).

    So basically, if you are interested in this specific feature, you could make a request on our github so you will be informed there when it would be included in ACADO code generation.

    Cheers,
    Rien

     

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.