Same optimization algorithm but different results?
조회 수: 2 (최근 30일)
이전 댓글 표시
I noticed that when I run an optimization method in MATLAB with a fmincon function, for example active-set method, the resulting coefficients and computation time is different every time I run the algorithm. I do not change the starting points, I just run the method one after another.
I understand this is the case for global optimization algorithms as they are using stochastic algorithms in the background. But why the same thing happens for the local minimum methods?
댓글 수: 0
답변 (1개)
Bjorn Gustavsson
2016년 8월 1일
We ran into similar results using fminsearch. This was for matlab-versions from around 2010-2011, and we boiled our problems down to parallelization of the sum-function - in our error-function we had something like
V = sum(V)/sum(V)*V;
(not that explicitly), and due to that parallel implementation the two calls to sum resulted in minor differences between them, this made the result very different for some starting-points...
Some matlab-version later the sum implementation were again robust.
What problem you have is very difficult to guess given the small amount of information you've given...
HTH HTH
댓글 수: 2
Bjorn Gustavsson
2016년 8월 2일
Oh, I'm mostly done here...
...but if you want someone else to chime in you'd need to give the bare-bone code reproducing the outcome.
One more thing you should do first: set the display option to fmincon to 'iter', then you'll see where things start to differ.
HTH
참고 항목
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!