Skip to main content

Using Callbacks for Column-and-constraint generation algorithm

Answered

Comments

4 comments

  • Daniel Espinoza

    Angelos,

    No, there is no way to add variables during B&B. You could do a https://en.wikipedia.org/wiki/Fourier%E2%80%93Motzkin_elimination of the new variable....

    Hope that helps,

    Daniel

    0
  • Angelos Georghiou
    Gurobi-versary
    First Comment
    First Question

    Dear Daniel,

    Thank you for your suggestion. For now, using Fourier Motzkin elimination is not an option as I need to add many variables and this will be nearly impossible to do.

    Let me ask a small follow up question about how Callback works.

    Assume that I introduce all continuous variables in my initial Master problem, and say non of them appear in the constraints (as these constraints will be added later on as lazy constraints), then pre-solve will eliminate them before starting the B&B algorithm. Now, when adding a new constraint as lazy constraint, will Gurobi recognize that it has previous eliminated the continuous variables that appear in the new constraint and re-introduce them? Or Gurobi will complain that the constraint contains decisions that don't appear in the problem (because they got eliminated during pre-solve)?

    kind regards,

    Angelos 

    0
  • Daniel Espinoza

    For using lazy constraints, you have to set the parameter http://www.gurobi.com/documentation/8.1/refman/lazyconstraints.html#parameter:LazyConstraints

    which will disable many presolve reductions (because having lazy constraints means that presolve does not know the full problem). So, in principle (with that parameter enabled) it should work.

    Daniel

    0
  • Angelos Georghiou
    Gurobi-versary
    First Comment
    First Question

    Thanks a lot Daniel

    best wishes,

    Angelos

    0

Please sign in to leave a comment.