Hello! I have a function:
function z=my_fun(x)a=2;b=3;c=1;z=a*x(1)-b*x(2)+c*x(3);
I use the genetic algoritm (ga, gatool) to generate input parameters x(1), x(2) and x(3). It is necessary for me, that x(1)<x(2)<x(3). How and where can I set this constraint? Thank you very much for any answer 🙂
Natalia
Best Answer