[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Help-glpk] Viewing input constraints in Java
From: |
glpk xypron |
Subject: |
Re: [Help-glpk] Viewing input constraints in Java |
Date: |
Fri, 30 Dec 2011 18:07:17 +0100 |
Hello Raymond,
you can use the followin methods:
GLPK.doubleArray_getitem()
GLPK.intArray_getitem()
cf.
http://www.xypron.de/projects/glpk-java/apidocs/org/gnu/glpk/GLPK.html#intArray_getitem%28org.gnu.glpk.SWIGTYPE_p_int,%20int%29
Best regards
Xypron
-------- Original-Nachricht --------
> Datum: Thu, 29 Dec 2011 14:11:25 -0500 (EST)
> Betreff: [Help-glpk] Viewing input constraints in Java
> Hello,
>
> I am using glpk-java to solve a network flow LP using the simplex solver
> (smcp). The solver has solved a few instances correctly, but not all (even
> simple ones).
> My belief is that one of the constraints I am building is not getting
> input correctly. The problem is, I do not know how to view a constraint in
> Java
> after it is built.
>
> I know the function glp_get_mat_row returns the number of variables in row
> i, as well as stores which variables and coefficients in ind and val. The
> problem is that in Java there is no way to access the individual indices of
> SWIGTYPE_p_int or SWIGTYPE_p_double that I can find.
>
> Any help would be greatly appreciated.
>
> _______________________________________________
> Help-glpk mailing list
> address@hidden
> https://lists.gnu.org/mailman/listinfo/help-glpk
--
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