nonlinear optimization with fminunc
이전 댓글 표시
i want to do a nonlinear optimization with the command 'fminunc' but i get the following error :
Local minimum possible.
fminunc stopped because the size of the current step is less than the default value of the step size tolerance.
Optimization stopped because the norm of the current step, 5.960464e-007, is less than options.TolX = 1.000000e-006.
Optimization Metric Options relative norm(step) = 5.96e-007 TolX = 1e-006 (default)
can someone explain what this means?
답변 (2개)
Sean de Wolski
2013년 2월 12일
That's not an error!
x = linspace(0,2,100);
y1 = (10*(x-1)).^2;
y3 = 1./x;
plot(x,y1,'b-',x,y3,'r-',1,y1(50),'b*',1,y3(50),'r*')
If we look at the blue line and the blue star at x=1, the blue line has hit a minimum, i.e. it starts to go up, the sign of the gradient has changed. With the red line, we have not hit a minimum, the line still appears to be decreasing. But now the amount that it is decreasing by is below some predefined tolerance (fed as an option to fminunc() ). The blue line shows what happens with an exit flag of 1, and the red line show it with an exitflag of 3.
Alan Weiss
2013년 2월 13일
편집: Alan Weiss
2013년 2월 13일
0 개 추천
Alan Weiss
MATLAB mathematical toolbox documentation
카테고리
도움말 센터 및 File Exchange에서 Choose a Solver에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!