[Top][All Lists]

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

Re: [Help-glpk] (no subject)

From: Raniere Silva
Subject: Re: [Help-glpk] (no subject)
Date: Tue, 11 Jun 2013 12:12:22 -0300
User-agent: Mutt/1.5.21 (2010-09-15)

> I have a decision variable defined as
> x(i,j,k,t) where
> i in I
> j in J(i)
> k in K(i,j)
> That is, the number of elements of J depends on the "i".
> For instance, J(1) has 1 element, J(2) has 1 element, J(3) has 4 elements,
> J(4) has 6 elements and so on.
> Is it possible to use GMPL to define this variable?

I don't know how. AFAIK in GMPL there is not a data structure of the form set
of sets (it only have set of arrays) that is what you need.

You you realy want to keep using GMPL, you can write a prototype that will be
used for a script (perl, python, ruby, ...) to build you model. Or you can use
the C library.


reply via email to

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