> I have to solve a knapsack problem : I have n variables with both a weight
> and a value
> for each, and I want to maximize the value I get summing the value of
> variables put to 1
> (as the corresponding object is taken in the sack), while the sum of the
> weigths of the
> variables put to 1 cannot be greater than the initial capacity of the
> sack... 
> After having set up the model in the solver, the objective function (which
> is set to
> "maximize") always returns 0. The solver has the correct model in memory
> though, I mean
> there is no mistake in the inequations that are known by the solver, no,
> the problem is
> that  the solver doesn't maximize anything. Can you help me ?

Please send to me either your source code or your instance in mps format
produced by lpx_write_mps.

Andrew Makhorin




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

Reply via email to