Borrar filtros
Borrar filtros

fmincon multiple optimal solution

7 visualizaciones (últimos 30 días)
amin re
amin re el 31 de En. de 2014
Comentada: hscbsc el 5 de Ag. de 2016
Hi,
I use fmincon to solve an optimization. The problem is that, I know theoretically my cost function will have multiple optimal points, however fmincon generates different solutions at each run. I expect it should stick to one solution. The algorithm is 'trust-region', as it uses finite difference method for hessian estimation, I suspect if some sort of randomness is behind it, causing different optimal solutions at each run.
Thanks for any comment and solution, how to get a unique solution.
  3 comentarios
Igor
Igor el 31 de En. de 2014
Editada: Igor el 31 de En. de 2014
The results must be exactly the same if you keep the same start point and all of the options associated with the 'fmincon' algorithm. 'fmincon' is a deterministic solver, which means nothing should alter the way it works unless there are uncertainties. For example, if your objective is noisy rather than deterministic, you might get a different result each time.
If you would like to get many local minima, use 'MultiStart' from the Global Optimization Toolbox. That would give you an idea about the "landscape" of your objective. If you need a single "global" solution (global minimum), use 'GlobalSearch' from the same toolbox. Even though it is effective enough, there is no guarantee the solution produced will be global. The more information you know about your objective and possible solution bounds, the better your chances of finding a solution you want to have.
hscbsc
hscbsc el 5 de Ag. de 2016
Hi,
I am facing a similar problem. Different fmincon runs give different answer. Not drastically different but differs at e-02 level or so. In my case my function is unsolvable for certain values, for this I render the objective function to a high value (10e+10). I use exactly the same options same initial points.

Iniciar sesión para comentar.

Respuestas (2)

Shashank Prasanna
Shashank Prasanna el 31 de En. de 2014
If you use the same starting point you must get the same results. If you use the Trust-Region-Reflective algorithm for the solver and if x0 is not strictly feasible, fmincon chooses a new strictly feasible (centered) starting point.
More information can be found here:
Make sure there is no randomness associated with the objective function. If you do have access to the global optimization toolbox, you can use Multistart with fmincon to find the global minima:
Or use PATTERNSEARCH:

Matt J
Matt J el 31 de En. de 2014
Editada: Matt J el 31 de En. de 2014
I know theoretically my cost function will have multiple optimal points
If the multiple optimal points you mention form a continuum, for example when the objective function has the form f(A*x) where the matrix A has non-zero null vectors, then your problem is ill-posed/unstable and needs to be reformulated. As the others have been saying, you should expect to get the same solution if run repeatedly on the same machine, the same input data, and from the exact same initial point. However, if you change architecture at all, or make even small changes to the input data, you can't rule out arbitrarily large jumps in the result.

Categorías

Más información sobre Get Started with Optimization Toolbox en Help Center y File Exchange.

Community Treasure Hunt

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

Start Hunting!

Translated by