stopping fmincon from termenation before finding the minimum

3 次查看(过去 30 天)
I am running an optimization problem and using fmincon. However, the function terminates before finding the minimum. How to stop that? I get the message below. The answer I get from fmincon is highly dependent on the initial value x0. Thanks!
Local minimum possible. Constraints satisfied.
fmincon stopped because the size of the current step is less than the selected value of the step size tolerance and constraints are satisfied to within the default value of the constraint tolerance.
<stopping criteria details>

回答(1 个)

Alan Weiss
Alan Weiss 2015-6-11
If the solution depends strongly on the initial point, then either there are a lot of local minima, or your objective is not so smooth. For information on local versus global optima, see the documentation.
And I am not 100% sure that I understand you when you say "...the function terminates before finding the minimum." The global minimum or a local minimum? There is a good chance that fmincon finds local minima every time. But, if you want a global minimum, then check the documentation on global vs. local. You might also consult When the Solver Might Have Succeeded or When The Solver Succeeds.
Alan Weiss
MATLAB mathematical toolbox documentation
  1 个评论
Walter Roberson
Walter Roberson 2015-6-11
Remember, the purpose of fmincon() is to find a local minimum.
There is no algorithm for finding the global minimum for arbitrary "black box" functions. Finding a global minimum can, at best, be done symbolically for some analytic functions. For example with the multivariate extension of polynomials then solving the partial derivatives for 0 gives a finite number of points to check with the maximum number calculable similar to the product of the degrees; with the local minima enumerable one knows when to stop looking. But it does not take much to transform an expression into one with an infinite number of places needed to check.

请先登录,再进行评论。

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by