Scippy

SCIP

Solving Constraint Integer Programs

heur_bound.c
Go to the documentation of this file.
1 /* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
2 /* */
3 /* This file is part of the program and library */
4 /* SCIP --- Solving Constraint Integer Programs */
5 /* */
6 /* Copyright (C) 2002-2022 Konrad-Zuse-Zentrum */
7 /* fuer Informationstechnik Berlin */
8 /* */
9 /* SCIP is distributed under the terms of the ZIB Academic License. */
10 /* */
11 /* You should have received a copy of the ZIB Academic License */
12 /* along with SCIP; see the file COPYING. If not visit scipopt.org. */
13 /* */
14 /* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
15 
16 /**@file heur_bound.c
17  * @ingroup DEFPLUGINS_HEUR
18  * @brief heuristic which fixes all integer variables to a bound (lower/upper) and solves the remaining LP
19  * @author Gerald Gamrath
20  *
21  */
22 
23 /*---+----1----+----2----+----3----+----4----+----5----+----6----+----7----+----8----+----9----+----0----+----1----+----2*/
24 
25 #include "scip/heur_bound.h"
26 #include "scip/pub_heur.h"
27 #include "scip/pub_message.h"
28 #include "scip/pub_tree.h"
29 #include "scip/pub_var.h"
30 #include "scip/scip_branch.h"
31 #include "scip/scip_general.h"
32 #include "scip/scip_heur.h"
33 #include "scip/scip_lp.h"
34 #include "scip/scip_mem.h"
35 #include "scip/scip_message.h"
36 #include "scip/scip_numerics.h"
37 #include "scip/scip_param.h"
38 #include "scip/scip_prob.h"
39 #include "scip/scip_probing.h"
40 #include "scip/scip_sol.h"
41 #include "scip/scip_solvingstats.h"
42 #include "scip/scip_timing.h"
43 #include "scip/scip_tree.h"
44 #include <string.h>
45 
46 #ifdef SCIP_STATISTIC
47 #include "scip/clock.h"
48 #endif
49 
50 #define HEUR_NAME "bound"
51 #define HEUR_DESC "heuristic which fixes all integer variables to a bound and solves the remaining LP"
52 #define HEUR_DISPCHAR SCIP_HEURDISPCHAR_PROP
53 #define HEUR_PRIORITY -1107000
54 #define HEUR_FREQ -1
55 #define HEUR_FREQOFS 0
56 #define HEUR_MAXDEPTH -1
57 #define HEUR_TIMING SCIP_HEURTIMING_BEFORENODE
58 #define HEUR_USESSUBSCIP FALSE /**< does the heuristic use a secondary SCIP instance? */
59 
60 #define DEFAULT_ONLYWITHOUTSOL TRUE /**< Should heuristic only be executed if no primal solution was found, yet? */
61 #define DEFAULT_MAXPROPROUNDS 0 /* maximum number of propagation rounds during probing */
62 #define DEFAULT_BOUND 'l' /**< to which bound should integer variables be fixed? */
63 
64 
65 /*
66  * Data structures
67  */
68 
69 /** primal heuristic data */
70 struct SCIP_HeurData
71 {
72  SCIP_Bool onlywithoutsol; /**< Should heuristic only be executed if no primal solution was found, yet? */
73  int maxproprounds; /**< maximum number of propagation rounds during probing */
74  char bound; /**< to which bound should integer variables be fixed? */
75 };
76 
77 /*
78  * Local methods
79  */
80 
81 /** main procedure of the bound heuristic */
82 static
84  SCIP* scip, /**< original SCIP data structure */
85  SCIP_HEUR* heur, /**< heuristic */
86  SCIP_HEURDATA* heurdata, /**< heuristic data structure */
87  SCIP_Bool lower, /**< should integer variables be fixed to their lower bound? */
88  SCIP_RESULT* result /**< pointer to store the result */
89  )
90 {
91  SCIP_VAR** vars;
92  SCIP_VAR* var;
93  SCIP_Bool infeasible = FALSE;
94  int maxproprounds;
95  int nbinvars;
96  int nintvars;
97  int nvars;
98  int v;
99 
100  /* get variable data of original problem */
101  SCIP_CALL( SCIPgetVarsData(scip, &vars, NULL, &nbinvars, &nintvars, NULL, NULL) );
102 
103  maxproprounds = heurdata->maxproprounds;
104  if( maxproprounds == -2 )
105  maxproprounds = 0;
106 
107  /* only look at binary and integer variables */
108  nvars = nbinvars + nintvars;
109 
110  /* stop if we would have infinite fixings */
111  if( lower )
112  {
113  for( v = 0; v < nvars; ++v )
114  {
115  if( SCIPisInfinity(scip, -SCIPvarGetLbLocal(vars[v])) )
116  return SCIP_OKAY;
117  }
118  }
119  else
120  {
121  for( v = 0; v < nvars; ++v )
122  {
123  if( SCIPisInfinity(scip, SCIPvarGetUbLocal(vars[v])) )
124  return SCIP_OKAY;
125  }
126  }
127 
128  /* start probing */
129  SCIP_CALL( SCIPstartProbing(scip) );
130 
131  for( v = 0; v < nvars; ++v )
132  {
133  var = vars[v];
134 
135  assert(SCIPvarGetType(var) < SCIP_VARTYPE_IMPLINT);
136 
137  /* skip variables which are already fixed */
138  if( SCIPvarGetLbLocal(var) + 0.5 > SCIPvarGetUbLocal(var) )
139  continue;
140 
141  /* fix variable to lower bound */
142  if( lower )
143  {
144  SCIP_CALL( SCIPfixVarProbing(scip, var, SCIPvarGetLbLocal(var)) );
145  SCIPdebugMsg(scip, "fixing %d: variable <%s> to lower bound <%g> (%d pseudo cands)\n",
147  }
148  /* fix variable to upper bound */
149  else
150  {
151  SCIP_CALL( SCIPfixVarProbing(scip, var, SCIPvarGetUbLocal(var)) );
152  SCIPdebugMsg(scip, "fixing %d: variable <%s> to upper bound <%g> (%d pseudo cands)\n",
154  }
155 
156  /* propagate fixings */
157  if( heurdata->maxproprounds != 0 )
158  {
159  SCIP_CALL( SCIPpropagateProbing(scip, maxproprounds, &infeasible, NULL) );
160  }
161 
162  /* try to repair probing */
163  if( infeasible )
164  {
165 #if 0
167 
168  /* fix the last variable, which was fixed the reverse bound */
169  SCIP_CALL( SCIPfixVarProbing(scip, var, SCIPvarGetUbLocal(var)) );
170 
171  /* propagate fixings */
172  SCIP_CALL( SCIPpropagateProbing(scip, maxproprounds, &infeasible, NULL) );
173 
174  SCIPdebugMsg(scip, "backtracking ended with %sfeasible problem\n", (infeasible ? "in" : ""));
175 
176  if( infeasible )
177 #endif
178  break;
179  }
180  }
181 
182  SCIPdebugMsg(scip, "probing ended with %sfeasible problem\n", infeasible ? "in" : "");
183 
184  /*************************** Probing LP Solving ***************************/
185 
186  /* solve lp only if the problem is still feasible */
187  if( !infeasible )
188  {
189  char strbuf[SCIP_MAXSTRLEN];
190  SCIP_LPSOLSTAT lpstatus;
191  SCIP_Bool lperror;
192  int ncols;
193 
194  /* print message if relatively large LP is solved from scratch, since this could lead to a longer period during
195  * which the user sees no output; more detailed probing stats only in debug mode */
196  ncols = SCIPgetNLPCols(scip);
197  if( !SCIPisLPSolBasic(scip) && ncols > 1000 )
198  {
199  int nunfixedcols = SCIPgetNUnfixedLPCols(scip);
200 
201  if( nunfixedcols > 0.5 * ncols )
202  {
204  "Heuristic " HEUR_NAME " solving LP from scratch with %.1f %% unfixed columns (%d of %d) ...\n",
205  100.0 * (nunfixedcols / (SCIP_Real)ncols), nunfixedcols, ncols);
206  }
207  }
208  SCIPdebugMsg(scip, "Heuristic " HEUR_NAME " probing LP: %s\n",
210 
211  /* solve LP; errors in the LP solver should not kill the overall solving process, if the LP is just needed for a
212  * heuristic. hence in optimized mode, the return code is caught and a warning is printed, only in debug mode,
213  * SCIP will stop.
214  */
215  SCIPdebugMsg(scip, "starting solving bound-heur LP at time %g, LP iterations: %" SCIP_LONGINT_FORMAT "\n",
217 #ifdef NDEBUG
218  {
219  SCIP_Bool retstat;
220  retstat = SCIPsolveProbingLP(scip, -1, &lperror, NULL);
221  if( retstat != SCIP_OKAY )
222  {
223  SCIPwarningMessage(scip, "Error while solving LP in bound heuristic; LP solve terminated with code <%d>\n",
224  retstat);
225  }
226  }
227 #else
228  SCIP_CALL( SCIPsolveProbingLP(scip, -1, &lperror, NULL) );
229 #endif
230  SCIPdebugMsg(scip, "ending solving bound-heur LP at time %g\n", SCIPgetSolvingTime(scip));
231 
232  lpstatus = SCIPgetLPSolstat(scip);
233 
234  SCIPdebugMsg(scip, " -> new LP iterations: %" SCIP_LONGINT_FORMAT "\n", SCIPgetNLPIterations(scip));
235  SCIPdebugMsg(scip, " -> error=%u, status=%d\n", lperror, lpstatus);
236 
237  /* check if this is a feasible solution */
238  if( lpstatus == SCIP_LPSOLSTAT_OPTIMAL && !lperror )
239  {
240  SCIP_SOL* newsol;
241  SCIP_Bool stored;
242  SCIP_Bool success;
243 
244  /* create temporary solution */
245  SCIP_CALL( SCIPcreateSol(scip, &newsol, heur) );
246 
247  /* copy the current LP solution to the working solution */
248  SCIP_CALL( SCIPlinkLPSol(scip, newsol) );
249 
250  SCIP_CALL( SCIProundSol(scip, newsol, &success) );
251 
252  if( success )
253  {
254  SCIPdebugMsg(scip, "bound heuristic found roundable primal solution: obj=%g\n",
255  SCIPgetSolOrigObj(scip, newsol));
256 
257  /* check solution for feasibility, and add it to solution store if possible.
258  * Neither integrality nor feasibility of LP rows have to be checked, because they
259  * are guaranteed by the heuristic at this stage.
260  */
261 #ifdef SCIP_DEBUG
262  SCIP_CALL( SCIPtrySol(scip, newsol, TRUE, TRUE, TRUE, TRUE, TRUE, &stored) );
263 #else
264  SCIP_CALL( SCIPtrySol(scip, newsol, FALSE, FALSE, TRUE, FALSE, FALSE, &stored) );
265 #endif
266 
267  if( stored )
268  {
269  SCIPdebugMsg(scip, "found feasible solution:\n");
270  *result = SCIP_FOUNDSOL;
271  }
272  }
273 
274  /* free solution */
275  SCIP_CALL( SCIPfreeSol(scip, &newsol) );
276  }
277  }
278 
279  /* exit probing mode */
280  SCIP_CALL( SCIPendProbing(scip) );
281 
282  return SCIP_OKAY;
283 }
284 
285 
286 /*
287  * Callback methods of primal heuristic
288  */
289 
290 /** copy method for primal heuristic plugins (called when SCIP copies plugins) */
291 static
292 SCIP_DECL_HEURCOPY(heurCopyBound)
293 { /*lint --e{715}*/
294  assert(scip != NULL);
295  assert(heur != NULL);
296  assert(strcmp(SCIPheurGetName(heur), HEUR_NAME) == 0);
297 
298  /* call inclusion method of heuristic */
300 
301  return SCIP_OKAY;
302 }
303 
304 /** destructor of primal heuristic to free user data (called when SCIP is exiting) */
305 static
306 SCIP_DECL_HEURFREE(heurFreeBound)
307 { /*lint --e{715}*/
308  SCIP_HEURDATA* heurdata;
309 
310  /* free heuristic data */
311  heurdata = SCIPheurGetData(heur);
312 
313  SCIPfreeBlockMemory(scip, &heurdata);
314  SCIPheurSetData(heur, NULL);
315 
316  return SCIP_OKAY;
317 }
318 
319 /** execution method of primal heuristic */
320 static
321 SCIP_DECL_HEUREXEC(heurExecBound)
322 { /*lint --e{715}*/
323  SCIP_HEURDATA* heurdata;
324 
325  assert(heur != NULL);
326  assert(scip != NULL);
327  assert(result != NULL);
328 
329  *result = SCIP_DIDNOTRUN;
330 
331  if( SCIPgetNPseudoBranchCands(scip) == 0 )
332  return SCIP_OKAY;
333 
334  if( !SCIPhasCurrentNodeLP(scip) )
335  return SCIP_OKAY;
336 
337  heurdata = SCIPheurGetData(heur);
338  assert(heurdata != NULL);
339 
340  *result = SCIP_DIDNOTFIND;
341 
342  if( SCIPisStopped(scip) )
343  return SCIP_OKAY;
344 
345  /* stop execution method if there is already a primal feasible solution at hand */
346  if( SCIPgetBestSol(scip) != NULL && heurdata->onlywithoutsol )
347  return SCIP_OKAY;
348 
349  SCIPdebugMsg(scip, "apply bound heuristic at node %lld\n",
351 
352  if( !SCIPisLPConstructed(scip) )
353  {
354  SCIP_Bool cutoff;
355 
356  SCIP_CALL( SCIPconstructLP(scip, &cutoff) );
357 
358  /* manually cut off the node if the LP construction detected infeasibility (heuristics cannot return such a result) */
359  if( cutoff )
360  {
362  return SCIP_OKAY;
363  }
364 
366  }
367 
368  if( heurdata->bound == 'l' || heurdata->bound == 'b' )
369  {
370  SCIP_CALL(applyBoundHeur(scip, heur, heurdata, TRUE, result) );
371  }
372  if( heurdata->bound == 'u' || heurdata->bound == 'b' )
373  {
374  SCIP_CALL(applyBoundHeur(scip, heur, heurdata, FALSE, result) );
375  }
376 
377  return SCIP_OKAY;
378 }
379 
380 /*
381  * primal heuristic specific interface methods
382  */
383 
384 /** creates the bound primal heuristic and includes it in SCIP */
386  SCIP* scip /**< SCIP data structure */
387  )
388 {
389  SCIP_HEURDATA* heurdata;
390  SCIP_HEUR* heur;
391 
392  /* create bound primal heuristic data */
393  SCIP_CALL( SCIPallocBlockMemory(scip, &heurdata) );
394 
395  /* include primal heuristic */
396  SCIP_CALL( SCIPincludeHeurBasic(scip, &heur,
398  HEUR_MAXDEPTH, HEUR_TIMING, HEUR_USESSUBSCIP, heurExecBound, heurdata) );
399 
400  assert(heur != NULL);
401 
402  /* set non-NULL pointers to callback methods */
403  SCIP_CALL( SCIPsetHeurCopy(scip, heur, heurCopyBound) );
404  SCIP_CALL( SCIPsetHeurFree(scip, heur, heurFreeBound) );
405 
406  /* add bound heuristic parameters */
407 
408  SCIP_CALL( SCIPaddBoolParam(scip, "heuristics/" HEUR_NAME "/onlywithoutsol",
409  "Should heuristic only be executed if no primal solution was found, yet?",
410  &heurdata->onlywithoutsol, TRUE, DEFAULT_ONLYWITHOUTSOL, NULL, NULL) );
411 
412  SCIP_CALL( SCIPaddIntParam(scip, "heuristics/" HEUR_NAME "/maxproprounds",
413  "maximum number of propagation rounds during probing (-1 infinity, -2 parameter settings)",
414  &heurdata->maxproprounds, TRUE, DEFAULT_MAXPROPROUNDS, -1, INT_MAX/4, NULL, NULL) );
415 
416  SCIP_CALL( SCIPaddCharParam(scip, "heuristics/" HEUR_NAME "/bound",
417  "to which bound should integer variables be fixed? ('l'ower, 'u'pper, or 'b'oth)",
418  &heurdata->bound, FALSE, DEFAULT_BOUND, "lub", NULL, NULL) );
419 
420  return SCIP_OKAY;
421 }
enum SCIP_Result SCIP_RESULT
Definition: type_result.h:52
SCIP_RETCODE SCIPlinkLPSol(SCIP *scip, SCIP_SOL *sol)
Definition: scip_sol.c:1017
SCIP_Real SCIPgetSolvingTime(SCIP *scip)
Definition: scip_timing.c:369
#define HEUR_PRIORITY
Definition: heur_bound.c:53
static SCIP_DECL_HEURCOPY(heurCopyBound)
Definition: heur_bound.c:292
public methods for SCIP parameter handling
SCIP_NODE * SCIPgetCurrentNode(SCIP *scip)
Definition: scip_tree.c:82
public methods for branch and bound tree
SCIP_RETCODE SCIPbacktrackProbing(SCIP *scip, int probingdepth)
Definition: scip_probing.c:216
SCIP_Longint SCIPgetNLPIterations(SCIP *scip)
static SCIP_DECL_HEUREXEC(heurExecBound)
Definition: heur_bound.c:321
public methods for memory management
int SCIPgetProbingDepth(SCIP *scip)
Definition: scip_probing.c:189
#define DEFAULT_MAXPROPROUNDS
Definition: heur_bound.c:61
#define SCIP_MAXSTRLEN
Definition: def.h:293
#define HEUR_DESC
Definition: heur_bound.c:51
internal methods for clocks and timing issues
static long bound
#define HEUR_FREQ
Definition: heur_bound.c:54
SCIP_Real SCIPvarGetLbLocal(SCIP_VAR *var)
Definition: var.c:17966
int SCIPgetNPseudoBranchCands(SCIP *scip)
Definition: scip_branch.c:749
public methods for timing
SCIP_RETCODE SCIPincludeHeurBound(SCIP *scip)
Definition: heur_bound.c:385
SCIP_RETCODE SCIPgetVarsData(SCIP *scip, SCIP_VAR ***vars, int *nvars, int *nbinvars, int *nintvars, int *nimplvars, int *ncontvars)
Definition: scip_prob.c:1865
#define FALSE
Definition: def.h:87
SCIP_RETCODE SCIPcutoffNode(SCIP *scip, SCIP_NODE *node)
Definition: scip_tree.c:425
#define TRUE
Definition: def.h:86
enum SCIP_Retcode SCIP_RETCODE
Definition: type_retcode.h:54
struct SCIP_HeurData SCIP_HEURDATA
Definition: type_heur.h:67
public methods for problem variables
#define SCIPfreeBlockMemory(scip, ptr)
Definition: scip_mem.h:99
SCIP_RETCODE SCIPincludeHeurBasic(SCIP *scip, SCIP_HEUR **heur, const char *name, const char *desc, char dispchar, int priority, int freq, int freqofs, int maxdepth, SCIP_HEURTIMING timingmask, SCIP_Bool usessubscip, SCIP_DECL_HEUREXEC((*heurexec)), SCIP_HEURDATA *heurdata)
Definition: scip_heur.c:108
SCIP_RETCODE SCIPconstructLP(SCIP *scip, SCIP_Bool *cutoff)
Definition: scip_lp.c:115
#define HEUR_FREQOFS
Definition: heur_bound.c:55
enum SCIP_LPSolStat SCIP_LPSOLSTAT
Definition: type_lp.h:42
void SCIPheurSetData(SCIP_HEUR *heur, SCIP_HEURDATA *heurdata)
Definition: heur.c:1362
void SCIPwarningMessage(SCIP *scip, const char *formatstr,...)
Definition: scip_message.c:111
#define SCIPdebugMsg
Definition: scip_message.h:69
#define HEUR_DISPCHAR
Definition: heur_bound.c:52
SCIP_RETCODE SCIPaddIntParam(SCIP *scip, const char *name, const char *desc, int *valueptr, SCIP_Bool isadvanced, int defaultvalue, int minvalue, int maxvalue, SCIP_DECL_PARAMCHGD((*paramchgd)), SCIP_PARAMDATA *paramdata)
Definition: scip_param.c:74
public methods for numerical tolerances
public methods for querying solving statistics
public methods for the branch-and-bound tree
SCIP_Bool SCIPisLPConstructed(SCIP *scip)
Definition: scip_lp.c:92
SCIP_Longint SCIPnodeGetNumber(SCIP_NODE *node)
Definition: tree.c:7432
SCIP_Bool SCIPisLPSolBasic(SCIP *scip)
Definition: scip_lp.c:658
static SCIP_RETCODE applyBoundHeur(SCIP *scip, SCIP_HEUR *heur, SCIP_HEURDATA *heurdata, SCIP_Bool lower, SCIP_RESULT *result)
Definition: heur_bound.c:83
#define DEFAULT_BOUND
Definition: heur_bound.c:62
const char * SCIPheurGetName(SCIP_HEUR *heur)
Definition: heur.c:1441
SCIP_RETCODE SCIPsetHeurFree(SCIP *scip, SCIP_HEUR *heur, SCIP_DECL_HEURFREE((*heurfree)))
Definition: scip_heur.c:169
SCIP_RETCODE SCIPpropagateProbing(SCIP *scip, int maxproprounds, SCIP_Bool *cutoff, SCIP_Longint *ndomredsfound)
Definition: scip_probing.c:571
SCIP_RETCODE SCIPfixVarProbing(SCIP *scip, SCIP_VAR *var, SCIP_Real fixedval)
Definition: scip_probing.c:409
SCIP_RETCODE SCIPendProbing(SCIP *scip)
Definition: scip_probing.c:251
const char * SCIPvarGetName(SCIP_VAR *var)
Definition: var.c:17251
char * SCIPsnprintfProbingStats(SCIP *scip, char *strbuf, int len)
#define NULL
Definition: lpi_spx1.cpp:155
#define HEUR_MAXDEPTH
Definition: heur_bound.c:56
int SCIPgetNUnfixedLPCols(SCIP *scip)
Definition: scip_lp.c:539
#define SCIP_CALL(x)
Definition: def.h:384
static SCIP_DECL_HEURFREE(heurFreeBound)
Definition: heur_bound.c:306
SCIP_RETCODE SCIPsolveProbingLP(SCIP *scip, int itlim, SCIP_Bool *lperror, SCIP_Bool *cutoff)
Definition: scip_probing.c:810
void SCIPverbMessage(SCIP *scip, SCIP_VERBLEVEL msgverblevel, FILE *file, const char *formatstr,...)
Definition: scip_message.c:216
#define DEFAULT_ONLYWITHOUTSOL
Definition: heur_bound.c:60
#define HEUR_USESSUBSCIP
Definition: heur_bound.c:58
SCIP_Bool SCIPhasCurrentNodeLP(SCIP *scip)
Definition: scip_lp.c:74
public methods for primal heuristic plugins and divesets
#define HEUR_NAME
Definition: heur_bound.c:50
#define SCIP_Bool
Definition: def.h:84
SCIP_LPSOLSTAT SCIPgetLPSolstat(SCIP *scip)
Definition: scip_lp.c:159
SCIP_RETCODE SCIProundSol(SCIP *scip, SCIP_SOL *sol, SCIP_Bool *success)
Definition: scip_sol.c:2446
SCIP_RETCODE SCIPfreeSol(SCIP *scip, SCIP_SOL **sol)
Definition: scip_sol.c:976
SCIP_Real SCIPgetSolOrigObj(SCIP *scip, SCIP_SOL *sol)
Definition: scip_sol.c:1435
SCIP_RETCODE SCIPflushLP(SCIP *scip)
Definition: scip_lp.c:139
SCIP_Bool SCIPisInfinity(SCIP *scip, SCIP_Real val)
SCIP_RETCODE SCIPtrySol(SCIP *scip, SCIP_SOL *sol, SCIP_Bool printreason, SCIP_Bool completely, SCIP_Bool checkbounds, SCIP_Bool checkintegrality, SCIP_Bool checklprows, SCIP_Bool *stored)
Definition: scip_sol.c:3125
public methods for the LP relaxation, rows and columns
public methods for branching rule plugins and branching
general public methods
SCIP_SOL * SCIPgetBestSol(SCIP *scip)
Definition: scip_sol.c:2304
SCIP_RETCODE SCIPaddCharParam(SCIP *scip, const char *name, const char *desc, char *valueptr, SCIP_Bool isadvanced, char defaultvalue, const char *allowedvalues, SCIP_DECL_PARAMCHGD((*paramchgd)), SCIP_PARAMDATA *paramdata)
Definition: scip_param.c:158
public methods for solutions
public methods for the probing mode
public methods for message output
#define SCIP_Real
Definition: def.h:177
SCIP_Bool SCIPisStopped(SCIP *scip)
Definition: scip_general.c:694
public methods for message handling
#define HEUR_TIMING
Definition: heur_bound.c:57
SCIP_VARTYPE SCIPvarGetType(SCIP_VAR *var)
Definition: var.c:17416
int SCIPgetNLPCols(SCIP *scip)
Definition: scip_lp.c:518
SCIP_RETCODE SCIPsetHeurCopy(SCIP *scip, SCIP_HEUR *heur, SCIP_DECL_HEURCOPY((*heurcopy)))
Definition: scip_heur.c:153
SCIP_Real SCIPvarGetUbLocal(SCIP_VAR *var)
Definition: var.c:17976
SCIP_RETCODE SCIPstartProbing(SCIP *scip)
Definition: scip_probing.c:110
public methods for primal heuristics
SCIPallocBlockMemory(scip, subsol))
SCIP_HEURDATA * SCIPheurGetData(SCIP_HEUR *heur)
Definition: heur.c:1352
public methods for global and local (sub)problems
SCIP_RETCODE SCIPaddBoolParam(SCIP *scip, const char *name, const char *desc, SCIP_Bool *valueptr, SCIP_Bool isadvanced, SCIP_Bool defaultvalue, SCIP_DECL_PARAMCHGD((*paramchgd)), SCIP_PARAMDATA *paramdata)
Definition: scip_param.c:48
heuristic which fixes all integer variables to a bound (lower/upper) and solves the remaining LP ...
SCIP_RETCODE SCIPcreateSol(SCIP *scip, SCIP_SOL **sol, SCIP_HEUR *heur)
Definition: scip_sol.c:319