Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added matlab binding for vector valued constraints #313

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open

Added matlab binding for vector valued constraints #313

wants to merge 3 commits into from

Conversation

nicolapiccinelli
Copy link
Contributor

I've added to the mex file the binding for the vector-valued inequality and equality constraints. They are available through the opt structure (in the same way for the standard constraint functions) with the following parameters:

  • mfc to define vector-valued inequality function binding
  • mfc_count to define the amount of inequality constraints
  • mfc_tol to define the tolerance for each inequality constraint
  • mh to define vector-valued equality function binding
  • mh_count to define the amount of equality constraints
  • mh_tol to define the tolerance for each equality constraint

there is also the new callback evaluation function user_mfunction defined with the signature provided in the reference manual. This enhancement allows integrating nlopt as a custom solver for the nonlinear model predictive controller in Matlab (the actual limitation is the need for a double evaluation of the nonlinear constraints function).

The limitation could be avoided by adding another specific binding for inequality-equality function binding (nlmpc custom solver).

@jschueller
Copy link
Collaborator

please dont change the indentation or eols, this is annoying to review

@nicolapiccinelli
Copy link
Contributor Author

please dont change the indentation or eols, this is annoying to review

do you have a vscode profile which can be used?

@jschueller
Copy link
Collaborator

no, sorry

@DWolfr
Copy link

DWolfr commented Jul 6, 2020

This should solve #280

@stevengj
Copy link
Owner

We can use https://github.com/stevengj/nlopt/pull/313/files?w=true to review while ignoring whitespace changes…

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants