Set function tolerance patternsearch
이전 댓글 표시
Hello,
I'm trying to do a minimization using patternsearch, here's a portion of my code.
lb=[Pmin Tmin];
ub=[Pmax Tmax];
objective=@(PT)objective_meemum(PT,bulk,pos,an);
options=optimoptions('patternsearch','Display','iter',...
'MeshTolerance',1e-10, 'ScaleMesh', false,'PlotFcn',@psplotbestf,...
'UseCompletePoll',true);
[PTopt(i,:), distance(i)]=patternsearch(objective,PT0,[],[],[],[],lb,ub,[], options);
In fact, I would want my the optimization to stop when the objective function gives a value <7e-3 (in this case the value is the distance variable).
Is there a way to do this? It seems like the FcnTolerance option does not work with patternsearch.
Thank you for the help,
Guillaume
댓글 수: 1
Guillaume Bonnet
2020년 7월 8일
편집: Guillaume Bonnet
2020년 7월 8일
채택된 답변
추가 답변 (0개)
카테고리
도움말 센터 및 File Exchange에서 Direct Search에 대해 자세히 알아보기
제품
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!