On Mon, Feb 25, 2008 at 1:30 AM, Andrew Makhorin <[EMAIL PROTECTED]> wrote:

>
> > Error:
> > Model.mod:127: shipmWtoD[Prod1,WhsA,DptE,1] out of domain
> > Model processing error
>
> You should not refer to members of a variable which are not in its
> domain. To avoid such references you need to add corresponding
> conditions everywhere you refer to the variable. For example:
>
> s.t. foo{i in I}: sum{j in J, k in K}
>     (if (i,j,k) in DOMAIN then x[i,j,k] else 0) = ... ;
>
> ('else 0' is used by default, so it can be omitted).
>
>
Thank you for the answer.

I see your point but could not figure out how to implement it when there are
several links between random source nodes and random destination nodes.
Please note that, each element in a subset of sources is not connected to
each element in the subset of destinations, either.
(if it was like that I could do:
set ssubset within source;
set dsubset within destination;
set link within (ssubset cross dsubset); and it could be easy to check the
DOMAIN then but this is not the situation)

So, do I understand right that I have to keep a list of all the links in a
set somehow and check if the variable is referencing to those or referencing
to something else?

Attachment: small.mod
Description: audio/mod

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

Reply via email to