<div dir="ltr">Hi,<div><br></div><div>Imagine a large-neighborhood like procedure using SCIP as (MILP) solver, which is basically all about partially fixing some available incumbent and ask the solver to improve the problem while being able to interfere with unfixed variables only.<br><br>While we could explicitly embed fixed-decisions (a set of fixed variables) during modelling without SCIP even seeing those (e.g. constant offset of accumulated fixed variables in some linear inequality), this is probably hard to keep correct when the model gets more complex.<br>As an alternative, we could model the full problem and just use SCIPfixVar for those selected variables. SCIPs presolve seems to be quite efficient (i saw it efficiently remove 800k constraints on some erroneous/incomplete "embed fixed decisions" code before).<br><br>Now at some point, it's important how to select variables to fix during LNS, to get a problem which is: easy enough to be solved efficiently and big enough to cover a large-neighborhood.<br>Somewhat ignoring the difference between structured (exploiting problem-specific knowledge) and unstructured (basically uniform over variables) variable-selection, the following idea comes to mind:<br><br>- Use the number of variables as a proxy-measure for easyness / neighborhood-size (it can be argued of course if that's a good idea)<br>- Obviously, some variables might have many implications (like fixings) on other variables while others are less "effectful"<br><br>The latter is hard to analyze and doing it will probably become a maintainment-burden too with more complex models.<br><br>An idea here is:<br><br>- Select TargetVarCount<br>- done = false<br>- While !done<br>  - Select a constant batch of variables<br>  - Fix those variables (using some available incumbent)<br>  - Trigger presolve<br>    - Variable fixings are about to happen<br>  - Read out remaining (non-presolved) variables -> RemVars<br>    - If RemVars <= TargetVarCount<br>              done = true<br><br>Can this be achieved (easily) with SCIP?<br><br>The documentation might indicate, that it's not as easy as one would hope as:<br><br>SCIPpresolve(...)<br><br>Postcondition<br>After calling this method SCIP reaches one of the following stages:<br>SCIP_STAGE_PRESOLVING if the presolving process was interrupted<br>SCIP_STAGE_PRESOLVED if the presolving process was finished and did not solve the problem<br>SCIP_STAGE_SOLVED if the problem was solved during presolving<br><br>SCIPfixVar(...)<br><br>Precondition<br>This method can be called if scip is in one of the following stages:<br>SCIP_STAGE_PROBLEM<br>SCIP_STAGE_PRESOLVING<br>SCIP_STAGE_SOLVING<br><br>I expect SCIPpresolve to result in SCIP_STAGE_PRESOLVED which is not allowed when calling SCIPfixVar :-/.<br><br>When not being restricted to variable-fixings, i expect some theory problems due to dual-reductions (compare with incremental SAT-solving where presolving away variables might be incorrect depending on future changes too).<br>Not sure if the restriction of variable-fixing only (without revising any earlier decision) helps here (in theory) and how hard it is to exploit in practice.<br><br>Greetings,<br>Sascha<br></div></div>