A bug has been detected in the MathProg translator. Due to this bug
iterated expressions having an indexing expression whose dummy indices
are bound to some values, i.e. like 'sum{(i+1,j,k-1) in E} x[i,j,k]'
are evaluated incorrectly. Namely, current value of such expressions
is not invalidated when corresponding dummy indices (like i and k in
the example above) are changed, that erroneously results in the same
value evaluated for the first time.

The following model demonstrates the bug:

------------------------------------------------------------------------
param n := 10;

set E := setof{i in 1..n, j in 1..n: Uniform(0,1) <= 0.25} (i,j);

display E;

display{i in 1..n} i, setof{(i,j) in E} (i,j);

end;
------------------------------------------------------------------------

To fix the bug please apply the patch attached.

Note that the bug will be fixed in a next version of the package.

Attachment: glpmpl01.c.diff
Description: Binary data

_______________________________________________
Bug-glpk mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/bug-glpk

Reply via email to