Hey guys! I am working on Genetic algorithm recently. And I met some problems when using fmincon.
I got error when calling the following line of code.
options = optimoptions(@fmincon,'OutputFcn',@outfun,...
Empty keys are not allowed in this container.
Error in my_fmincon (line 24)
where budget is 10000, outfun is deined in this way:
function stop = outfun(x,optimValues,state)
stop = false;
history.fval = [history.fval; optimValues.fval];
history.x = [history.x; x];
Help! Thanks a lot!!