Hi, I am trying to use MATLAB gamultiobj, but I need the variables to be between -1.5 and 1.5, but after it runs I realize it didn't take them into account. The variables exeed the conditions. I will write here the code:

fit_funct=@obj_functs_taller

num_vab=2

A=[];b=[];

Aeq=[];beq=[];

lb=[-1.5,-1.5];

ub=[1.5,1.5];

options = optimoptions(@gamultiobj,'PlotFcn',{@gaplotpareto,@gaplotscorediversity});

[xr,fvalr]=gamultiobj(fit_funct,num_vab,A,b,Aeq,beq,lb,ub,options);

And the function:

function y=obj_functs_taller(x)

y(1)=exp(-prod(x-sqrt(1/3)));

y(2)=exp(-prod(x+sqrt(1/3)));

end

Any help would be appreciated

Similar questions and discussions