Search code examples
linear-programmingscip

SoPlex yields wrong answer


I have an LP in CPLEX LP format, in file LP.tmp

Maximize
    obj: x0 + 2 x1 + 3 x2 + 4 x3 + 5 x4 + 7 x5
Subject To
    c0: 1 x0 + 1 x1 + 1 x2 + 1 x3 + 1 x4 + 1 x5 + 1 x6 + 1 x7 + 1 x8 = 0
End

On this I call soplex -X -x -o0 -f0 -v3 LP.tmp This is obviously unbounded, but calling Soplex gives me the answer (with some other lines).

SoPlex status       : problem is solved [optimal]
Solving time (sec)  : 0.00
Iterations          : 0
Objective value     : 0.00000000e+00


Primal solution (name, value):
All other variables are zero (within 1.0e-16). Solution has 0 nonzero entries.

Background: Originally, I had objective 0, but box constraints, and I always got infeasible. So I reduced everything, until I arrived at the above.

What am I doing wrong?


Solution

  • All variables are non-negative by default in the lp file format, see https://www.ibm.com/support/knowledgecenter/SSSA5P_12.5.0/ilog.odms.cplex.help/CPLEX/FileFormats/topics/LP.html

    Therefore, your constraint fixes all variables to 0. As soon as you change the coefficient of any of the variables but x5 to -1 or add a bounds section where you define it to be free, e.g., x1 free, SoPlex claims unboundedness and provides a valid primal ray.