help-glpk
[Top][All Lists]
Advanced

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

[Help-glpk] [Fwd: request for a feature (maximal iteration number or cal


From: Andrew Makhorin
Subject: [Help-glpk] [Fwd: request for a feature (maximal iteration number or callback function in glpk_simplex)]
Date: Thu, 16 May 2013 22:51:38 +0400

-------- Forwarded Message --------
From: Robert Baier <address@hidden>
To: address@hidden
Cc: address@hidden <address@hidden>
Subject: request for a feature (maximal iteration number or callback
function in glpk_simplex)
Date: Thu, 16 May 2013 18:30:28 +0200

Dear members of the GLPK project,

we used "glp_simplex(..)" in a academic research project in mathematics
and made good experiences for most of the problems.

There is one (huge and very badly scaled) problem where
"glp_simplex(..)" fails to find a feasible solution (even after two days
of computation ...).

To study better, if an error is in the model problem or which kind of
(infeasible, but almost feasible) point is reached by "glp_simplex(..)"
we would like to have a way that

  - 1) either we can set a maximal iteration number or a minimal
       infeasibility measure for "glp_simplex(..)"

  - 2) or that we can add a callback function / hook during the run of
       "glp_simplex(..)" that is always called as it possible for the
       output with "glp_term_hook(..)"

remarks to 1) resp. 2):

1)  There is a regular terminal output by "glp_simplex(..)"
    (as in the manual, p. 51) like

  10200: obj =   1.333e+00  infeas =  2.545e+001 (0)

    in which a first number appears (here: 10200) for which we would
    like to establish a maximal iteration number.

    But we cannot see a way to do this.
    To set the control parameter "it_lim" (see manual, p. 53) does
    not help, since this does not set a maximum for the number that
    appears in the regular terminal output (we guess it is a limit
    for an inner iteration).

    Q1) Do you know of a way how we can stop "glp_simplex" to reach
        the iteration number "10200"?

        Or to stop after a certain infeasibility accuracy is reached?

2)  The hook function should have a parameter "glp_prob * lp" from which
    we can get intermediate information during the run of simplex.

    Q2) Is there a way to establish such a callback function for
        "glp_simplex(..)"?

    Q3) Is there a way to access the iteration number "10200" from the
        pointer "lp" during the run of "glp_simplex(..)"?

    In the manual (p.20 - 23) it is announced that in the structure
    "glp_prob" there are control parameters and a statistics segment,
    but it is not described further on (in contrary to the first
    four segments).

    We are afraid that there is no way, since we made the following
    experiment:

    We established a hook function with "glp_term_hook(..)". Then,
    we extracted from the const char-pointer "s" (second argument) the
    iteration number and we tried to read from a (detested) global
    pointer variable (that points to "glp_prob"-variable in main()) and
    its double-array the index 21 (seen as a pointer to int).

    After the call of "glp_simplex(..)" in main() we see the iteration
    number "10200" via our global pointer variable, but inside the
    hook function we only see the wrong value "0".

    Q4) Is it true that only after the end of "glp_simplex(..)"
        the data structure "glp_prob" contains the iteration number
        and further solution values (which is too late for us)?

Thank you in advance for any helping comments resp. answers to our
questions Q1)-Q4) and thanks for developing the software ... .

Best regards
  Robert and Huijuan
-- 
----------------------------------------------------
                    Robert Baier

Universitaet Bayreuth         University of Bayreuth
Angewandte Mathematik V       Applied Mathematics V
D-95440 Bayreuth              D-95440 Bayreuth
Deutschland                   Germany

Tel.:   0921/55-3286          (49) 921/55-3286
Fax:    0921/55-2999          (49) 921/55-2999

         e-mail: address@hidden
----------------------------------------------------






reply via email to

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