How can I save the value of each decision variable in each iteration in using fmincon MATLAB
조회 수: 3 (최근 30일)
이전 댓글 표시
I uesed this code to find the optimal value of 3 decision variables, But I want to plot the optimization process, and I need the value of each decision variable in each iteration,
x0=[1;1;1]; % Starting guess
lb=[0.5;0.5;0.5];
ub=[1.25;1.27;4];
options = optimoptions('fmincon','Display','iter','Algorithm','interior-point','Tolx',1e-15,'Tolfun',1e-16,'MaxFunEvals',600,'MaxIter',100);
[x,fval,exitflag,output]=fmincon(@optim,x0,[],[],[],[],lb,ub,[],options)
When I used ,'outputfcn',@outfun, in the options I get error
is there any way that I can check the value of decision variables in each iteration?
댓글 수: 5
답변 (0개)
참고 항목
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!