On Wed, Apr 27, 2011 at 4:46 PM, Andrew Makhorin
<address@hidden> wrote:
> I've got a problem with the max() and min() functions...
>
> i need to do something like this:
> min(120,ScorteIniziali+PrimoStd+PrimoStra)*70
> in my "objective function"
>
> but min() accepts only numeric parameters..
>
> is there any alternatives?
A non-linear objective function like this
maximize z = min(x1, x2) + min(x3, x4) + ...
can be modeled within mip as follows:
z = min_x1_x2 + min_x3_x4 + ...
s.t. min_x1_x2 <= x1
min_x1_x2 <= x2
min_x3_x4 <= x3
min_x3_x4 <= x4
. . .
Note that max(x, y) = -min(-x, -y) that allows you to model objective
terms -max(x, y) thru min.
Sent via my good, old desktop.
_________________________________________