Objective and constraints having a common function - Problem based in Matlab 2016b
Show older comments
Hi,
In my current optimization problem, both the objective and cosntraint functions are calculated following a time-consuming simulink run. In order to avoid having to run the simulation twice at each iteration (one to compute the objective, one to compute the constraint), I would like to apply the same method as described in https://fr.mathworks.com/help/optim/ug/objective-and-constraints-using-common-function.html.
However, my work only gives access to Matlab 2016b, and the functions used are not available yet : optimvar, fcn2optimexpr.
Is there a way to convert my function "compute_all" (which computes both the objective and the constraint) to an optimization expression, but in Matlab 2016b ?
Thank you for your help,
Thomas
Accepted Answer
More Answers (0)
Categories
Find more on Solver Outputs and Iterative Display in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!