help-glpk
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Help-glpk] interrupt glpk using JNI


From: faheem hussain
Subject: Re: [Help-glpk] interrupt glpk using JNI
Date: Wed, 19 Apr 2006 12:48:52 -0700 (PDT)

Thanks for your quick response but unfortunately this solution doesn't apply in this case. I want to let the user decide whether he wants to interrupt/cancel the solution process or not, and when. To be precise in the GUI I want to provide the cancel button once the solution is in progress. The time limit can be set only before the solution process begins. Once the solver starts solving the process, settting this parameter doesn't help(I actually tried it). Any other suggestions?

Andrew Makhorin <address@hidden> wrote:
> I am using GLPK JNI for my problem. For the small instances it's ok
> since the solver doesn't take much time to solve. But sometimes
> when the instances are large GLPK takes few minutes to solve the
> instance. Now what if the user wants to interrupt the solver and
> not continue the solution process. I have tried to find out how to
> stop the solver while it is still running but no luck. I have tried
> to stop the java thread that starts GLPK solver native thread but it
> didn't help. Is there any API call or any specific method to interrupt
> the solver? I would highly appreciate any help.

You can limit the solution time. I'm not sure about jni (since never
used it); however, in c this can be attained by the following call:

lpx_set_real_parm(prob, LPX_K_TMLIM, tmlim);

where tmlim is the time limit, in secs, of double type.



Yahoo! Messenger with Voice. PC-to-Phone calls for ridiculously low rates.
reply via email to

[Prev in Thread] Current Thread [Next in Thread]