Output of fmincon() for multiple solution problem

2 views (last 30 days)
Hi all, I am using fmincon() for a problem like this
min |f(x1,x2)|
s.t. x1^2+x2^2<a^2
Now I know that for my problem there will be a range of variables (x1,x2) to make abs( f(x1,x2) )=0.But using fmincon() I only got one solution for this problem. So I am wondering how does fmincon() decides which solution is used if for a problem there are multiple solutions?
Thank you!
------------------------------------------------
p.s. By the way, my real problem is like this
min |f(x1,x2)|,x1^2+x2^2
s.t. x1^2+x2^2<a^2
so I am actually having two objective functions,and within the multiple solutions for (x1,x2) I am trying to find the one that has the minimum square sum. It looks like gamultiobj() doesn't give a single solution that's ready to use, so I am curios to know if there are any good method to do multi-objective optimization in MATLAB.

Answers (2)

Matt J
Matt J on 25 Mar 2018
FMINCON does an iterative search for the solution. The point it finds depends on the initial guess and various other algorithm settings. It is even possible for fmincon to fail to find any of the solutions, e.g., when there are local minima for the iterations to get trapped in.

Walter Roberson
Walter Roberson on 25 Mar 2018
fmincon will use the first location it finds for any given value of the function, except in cases where a later location is less of a constraint violation.
  1 Comment
Walter Roberson
Walter Roberson on 25 Mar 2018
You do not appear to have two objective functions. You appear to have one function and one nonlinear constraint.
fmincon will never return multiple solutions.
gamultiobj will return a set of locations each corresponding to a local minima. It does not attempt to return all of them (there could be an infinite number)

Sign in to comment.

Community Treasure Hunt

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

Start Hunting!