[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Help-glpk] setting up a basic LP using glp_set_mat_row
From: |
glpk xypron |
Subject: |
Re: [Help-glpk] setting up a basic LP using glp_set_mat_row |
Date: |
Fri, 13 Jan 2012 19:35:23 +0100 |
Hello John,
sorry for the empty mail.
The documentation teaches:
>> Being added to the problem object each column is initially
>> fixed at zero, i.e. its type is GLP_FX and both bounds are 0.
Please, use glp_set_col_bnds to set the column bounds.
Best regards
Xypron
-------- Original-Nachricht --------
> Datum: Fri, 6 Jan 2012 13:27:04 -0600
> Von: John Perry <address@hidden>
> An: "address@hidden" <address@hidden>
> Betreff: [Help-glpk] setting up a basic LP using glp_set_mat_row
> Hi
>
> I'm trying to set up an LP using glp_set_mat_row. As I understand it, I
> need to
> (1) create a problem
> (2) set an objective direction
> (3) set the objective function's coefficients
> (4) create columns
> (5) create rows
> (6) set the rows
> (7) solve
>
> The system I'm trying is simple: x >= 1, y >= 1, minimizing x + y. This
> has the solution (1,1), but the solver tells me there is no solution.
>
> I'm sure I'm setting it up wrong, but I don't know what. I've attached
> code below; can anyone tell me what I'm doing wrong?
>
> (If my etiquette is wrong, can anyone tell me how I should go about asking
> the question?)
>
> regards
> john perry
>
--
Follow me at http://twitter.com/#!/xypron
NEU: FreePhone - 0ct/min Handyspartarif mit Geld-zurück-Garantie!
Jetzt informieren: http://www.gmx.net/de/go/freephone