Hey!
Suppose that you have a non-linear program. In that program you can have several decision variables combinations which result in same optimum. Is there any way to make GAMS tell you that several points satisfy the optimality conditions for the optimum found?
Thanks in advance
Eg:
minimize x_2
s.t.:
x_1 =g= 0;
x_2 =g= 2;
x_2 =g= (x_1)^2
x_1,x_2 \in \doubleR
The optimum is x_2=2, but x_1 \in [0,sqrt(2)]
Some solvers supporting discrete variables can give you some alternative optimal or close optimum solutions, see e.g. Cplex’s solution pool (CPLEX). BARON (BARON) also has a way to report multiple solutions. It wants to report a finite number of solutions to there is a parameter called ISolTol (default 1e-4) to separate solutions. When I run this with your model, BARON solves this in presolve and does not report alternative solutions. Perhaps, you have more luck with a real model and alternative solutions:
variable x_1,x_2; x_1.lo = 0; x_2.lo = 2;
equation e; e.. x_2 =g= sqr(x_1);
model m /e/; m.optfile=1; option qcp=baron;
$echo numsol -1 > baron.opt
solve m min x_2 us qcp;
The log reads:
Starting solution is feasible with a value of 2.00000
Preprocessing found feasible solution with value 2.00000
Problem solved during preprocessing
Lower bound is 2.00000
-Michael