Hello Xypron,
thank you very much for the answer. I have just one
more question regarding the constraints you suggested.
Shouldn't the first of them be:
s.t. c1{i in m..N} :
M <= a[i] + b[i] * y[i];
?
Thanks,
Juliana.
------------
>
> Hello Juliana,
>
> For a reference see the API documentation in
> doc/glpk.pdf in the
> distribution tarball available at
> ftp://ftp.gnu.org/gnu/glpk/glpk-4.39.tar.gz
>
> Have a look at the examples the examples folder and in
> glpk-java
> available at http://glpk-java.sourceforge.net/
>
> Consider using modeling language GNU Mathprog available in
> GLPK.
>
>
>
> sum[i=m to N] x_i((a_i) + (b_i*y_i)) + sum[i=1 to N]
> b_i*y_i
>
> is not a linear term because it contains the product of two
> variables
> x_i * y_i.
>
>
>
> If you want to use a MILP solver like GLPK you will
> have to reformulate
> your problem, e.g.
>
>
>
> maximize obj :
> sum{i in m..N} w[i] + sum{i in 1..N} b[i]*y[i];
>
> s.t. c1{i in m..N} :
> w[i] <= a[i] + b[i] * y[i];
> s.t. c2{i in m..N} :
> w[i] <= x[i] * M;
>
> Best regards
>
> Xypron
____________________________________________________________________________________
Veja quais são os assuntos do momento no Yahoo! +Buscados
http://br.maisbuscados.yahoo.com
_______________________________________________
Help-glpk mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/help-glpk