[Scip] Calling a separator

Gerald Gamrath gamrath at zib.de
Thu Apr 5 15:34:30 MEST 2012


Dear Hélène,

Am 05.04.2012 14:25, schrieb Hélène Toussaint:
> Hi Gerald,
>
> Thank you for your prompt answer.
>
> Le 05/04/2012 14:06, Gerald Gamrath a écrit :
>> Dear Hélène,
>>
>>> I have implemented a separator using the C++ class. I have redefined 
>>> only the scip_execlp method. I see in the doc that this method is 
>>> called in the LP solving loop. However it is never called when I run 
>>> my program. I have called SCIPincludeObjSepa before solving and 
>>> tried several priority flags. I put freq = maxbounddist = 1 and 
>>> delay = false.
>>> I'd like scip_execlp be called before branching (since it should 
>>> help me to get rid of some fractional solutions). Do I forget 
>>> something ?
>> well, that is strange. Did you perhaps disable separation in your 
>> settings to turn off the default separators? If the 
>> separating/maxcuts(root) and separating/maxrounds(root) parameters 
>> are set to 0, no separators are called, whatever their priorities are.
>
> Yes indeed I want to disable the default separators because it can 
> perturb my pricing. I have put separating/maxrounds to 0. How can I 
> turn off them without disable my own separator ?
besides the global number of separation rounds separating/maxrounds, 
each separator has its own parameter 
separating/"separatorname"/maxrounds. In order to disable the default 
separators, you should set their local maxrounds value to 0. You could 
also just not include the other separators, of you do not use 
SCIPincludeDefaultPlugins() to add the plugins but use a modified method 
which also includes your pricer, separator, etc.

>
>> How do you know that your separator is never called? Did you add 
>> output messages or did you just look at the statistics of SCIP? In 
>> the latter case, it might be that you just forgot to set the 
>> result-pointer correctly, if it is set to SCIP_DIDNOTRUN, the call is 
>> not counted, even if you did something within the method.
>
> I have added output messages.
>
>>> Morever I have also  a pricer so the constraints generated  by the 
>>> separator must be updated when I get new variables. I would like to 
>>> know if it may cause potential errors in SCIP ?
>> Your pricer just has to add newly created variables not only to the 
>> constraints, but also to the cuts that were already generated and you 
>> have to take into account the dual values of the cuts in your pricing 
>> problem. If you do this, there should be no problems doing 
>> branch-cut-and-price with SCIP.
>
> What is the difference between cuts and constraints ? My separator 
> generate linear constraints with the SCIPcreateConsLinear method. Is 
> it wrong ?
It is not wrong to create linear constraints, but it might be some 
overhead. If your separator is just used to tighten the LP relaxation, 
it should be sufficient to add the cut as a row in the LP. Since it is 
only used to tighten the LP relaxtion, it is enough to have it in the LP 
and you do not need the other things a constraint does, like 
propagation, enforcement and checking.
On the other hand, if it is more convenient for you to have the cuts as 
constraints, because you then do not have to distinguish between initial 
constraints and cuts, you can also adjust the behavior of the newly 
created (cut-) constraints. You can set the enforce, check,and  
propagate flag to FALSE when you create the constraint. Furthermore, you 
should probably set dynamic and removable to TRUE, such that the row 
corresponding to the constraint is removed from the LP when it was not 
tight in the last x LP solutions. This is the default behavior for cuts, 
and the row will automatically be added to the LP again if needed, if 
you set the separate flag to TRUE when creating the constraint.

Best,
Gerald
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://listserv.zib.de/mailman/private/scip/attachments/20120405/023deb3a/attachment.html


More information about the Scip mailing list