> i need some help to modelling this model in
> GLPK.
>
> i dont know how to represent upper and lower bounds
> in the sum.
>
> I try this, but wasnt sucessfull.:
>
> /* objetive function */
> minimize z:
> sum{i in TAREFAS, t in TEMPOS: t<=tempo_total-tempo_producao[i]+1}
> custo[i,t]*x[i,t];
> /* constraints */
>
> /*todas atividades devem ser executadas*/
> s.t. rest1{i in TAREFAS}:
> sum{t in TEMPOS} x[i,t] = 1;
>
> /*maximo uma atividade por período*/
> s.t. rest2{t in TEMPOS}: sum{i in
> TAREFAS, s=t-tempo_producao[i]+1 .. t}x[i,s] <= 1;
Probably you can write something like this:
minimize z:
sum{i in 1..n, t in 1..T - p[i] + 1) c[i,t] * x[i,t];
and so on.
Could you provide the terminal output from the solver? Is there a
syntactic error, or the solution seems to be wrong?
_______________________________________________
Help-glpk mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/help-glpk