[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Help-glpk] help! I need a small example to use GLPK java for MIP
From: |
glpk xypron |
Subject: |
Re: [Help-glpk] help! I need a small example to use GLPK java for MIP |
Date: |
Sat, 21 Nov 2009 23:45:01 +0100 |
Hello Yi,
the documentation of the GLPK library can be found in file
doc/glpk.pdf of the GLPK source distribution available at
ftp://ftp.gnu.org/gnu/glpk/glpk-4.40.tar.gz
The routine to solve integer problems is
int glp_intopt(glp_prob *mip, const glp_iocp *parm);
For a complete example see appendix.
Best regards
Xypron
-------- Original-Nachricht --------
> Datum: Fri, 20 Nov 2009 21:09:19 +0300
> Von: "Zong, Yi"
> An: address@hidden
> Betreff: [Help-glpk] help! I need a small example to use GLPK java for MIP
> To it may concern,
>
> I want to use GLPK-java to solve a
> simple MIP.
>
> // Maximize z = 17 * x1 + 12* x2
>
>
>
> // subject to
>
> // 10*x1+7*x2 <= 40
>
> // x1+ x2 <= 5
>
> // where,
>
> // 0.0 <= x1 integer
>
> // 0.0 <= x2 integer
>
> // result: max=68: x1=4, x2=0; ??
>
>
>
>
>
> The code is shown as following. The
> problem is how I can get integer solution?
>
--
GRATIS für alle GMX-Mitglieder: Die maxdome Movie-FLAT!
Jetzt freischalten unter http://portal.gmx.net/de/go/maxdome01
Yi.java
Description: Binary data