[Lemon-user] I have a problem using Lp
Alpár Jüttner
alpar at cs.elte.hu
Fri Mar 30 17:30:52 CEST 2012
On Fri, 2012-03-30 at 16:44 +0200, NGUYEN Vu Ngoc Tung wrote:
> The glpk library has already installed in my computer.
GLPK must be installed under some standards location in order that LEMON
can find it. If it is not there, you must give the location by hand. The
standard locations are usually /usr and /usr/local on linux. On Windows
there is no such a thing that standard place for libraries, so you must
always give it manually.
The GLPK install root dir can be set by the -DGLPK_ROOT_DIR cmake
parameter, e.g.
cmake -DGLPK_ROOT_DIR=/opt/glpk -LA ..
Option -LA lists all the variables set by CMAKE, thus you can check
whether or not GLPK was successfully detected. For this, you should look
for variables GLPK_INCLUDE_DIR and GLPK_LIBRARY. If you see something
like this:
GLPK_INCLUDE_DIR:PATH=/opt/glpk/include
GLPK_LIBRARY:FILEPATH=/opt/glpk/lib/libglpk.so
then GLPK was detected correctly by LEMON. However
GLPK_INCLUDE_DIR:PATH=GLPK_INCLUDE_DIR-NOTFOUND
GLPK_LIBRARY:FILEPATH=GLPK_LIBRARY-NOTFOUND
tells you that something went wrong.
>
> But if I want to run maxflow algorithm, how do I resolve the problem
> with glpk.
You don't even need an lp solver for running the max flow algorithms. It
is only the lp_maxflow_demo.cc that needs it, because it solves the max
flow problem using the lp solver. LEMON's own max flow algorithms work
without using an LP solver (and run much more efficiently).
> Could you give me the original link in order to download Hao-Orlin
> demonstration.
I'm not aware of a specific Hao-Orlin demo, but the use of HaoOrlin
class should be quite straightforward based on its doc.
http://lemon.cs.elte.hu/pub/doc/1.2.3/a00162.html
at least once you will have got familiar with the basic concepts of
LEMON. If you aren't yet, I recommend going through this Tutorial:
http://lemon.cs.elte.hu/pub/tutorial/
Regards,
Alpar
More information about the Lemon-user
mailing list