does nonlcon works for gamultiobjective Matlab r2014a

1 view (last 30 days)
Hello Ive been trying to use multiobjecive GA with nonlinear constrains http://uk.mathworks.com/help/gads/gamultiobj.html but whenever I tried I got a message saying "error using famultiobj too many input arguments". the only difference I can find between the software I am using and the examples I have found is that the software I have is r2013a and the examples at te internet are r2014b. Is there anything I can do to solve this or should I just look for a r2014b software?
BTW my code looks like this:
function [c, ceq] = simple_constraint(x) c = 2*x(2)+x(3)+0.002; ceq = [];
LB=[ 1 0.005 ]; UB=[ 51 0.08 ];
ConstraintFunction = @simple_constraint;
[x fval]=gamultiobj(@GA_ACCHA,3,[],[],[],[],LB,UB,ConstraintFunction,[]);
I didn't add my function to optimize because is too long and also I have tried it with a simple ga and worked well.
Regards

Answers (1)

Sean de Wolski
Sean de Wolski on 25 Nov 2014
Edited: Sean de Wolski on 25 Nov 2014
The ability for gamultiobj to support nonlinear constraints was added in R2014b.
If your company/university is current on maintenance, you should be able to upgrade at no additional cost.

Categories

Find more on Introduction to Installation and Licensing in Help Center and File Exchange

Products

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!