help-glpk
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Help-glpk] GUSEK - MPS format generation


From: Heinrich Schuchardt
Subject: Re: [Help-glpk] GUSEK - MPS format generation
Date: Thu, 25 Sep 2014 23:35:18 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Icedove/31.0

On 25.09.2014 23:15, technical forestry services wrote:
Hello

I believe there is an issue in the manner in which GUSEK prepares MPS
format
for an LP maximum problem.

MPS format only accepts a minimisation problem.  If GUSEK is asked to
prepare MPS
format for an LP minimisation problem it faithfully generates the MPS
code correctly.  If it is asked to generate
the MPS format for an LP maximisation problem it does not convert it to
the equivalent minimisation
problem required by MPS but instead simple trots out the objective
coefficients without changing their sign.
Recollect the identity max f(x) = - min {- f(x)}.

Evidence for the above can easily be seen b:
1) generating a max problem using GMPL and solve it.
2) use GUSEK to generate the MPS format for the same problem and solve
that.
Two different answers are obtained for the objective function value. The
first is the maximum and the second
the minimum.

Cheers
Lrb


Here is an example:

var x, >= -20, <= 10;
maximize obj: x;
solve;
end;

$ glpsol -m test.mod --wmps test.mps --nopresol
obj =   1.000000000e+01
$ glpsol test.mps --nopresol
obj =  -2.000000000e+01

Best regards

Heinrich Schuchardt




reply via email to

[Prev in Thread] Current Thread [Next in Thread]