Scippy

SCIP

Solving Constraint Integer Programs

cutsel.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 cutsel.c
17  * @ingroup OTHER_CFILES
18  * @brief methods for cut selectors
19  * @author Felipe Serrano
20  * @author Mark Turner
21  */
22 
23 /*---+----1----+----2----+----3----+----4----+----5----+----6----+----7----+----8----+----9----+----0----+----1----+----2*/
24 
25 #include <assert.h>
26 
27 #include "scip/set.h"
28 #include "scip/clock.h"
29 #include "scip/paramset.h"
30 #include "scip/scip.h"
31 #include "scip/cutsel.h"
32 
33 #include "scip/struct_cutsel.h"
34 
35 
36 /** method to call, when the priority of a cut selector was changed */
37 static
38 SCIP_DECL_PARAMCHGD(paramChgdCutselPriority)
39 { /*lint --e{715}*/
40  SCIP_PARAMDATA* paramdata;
41 
42  paramdata = SCIPparamGetData(param);
43  assert(paramdata != NULL);
44 
45  /* use SCIPsetCutselPriority() to mark the cutsels unsorted */
46  SCIP_CALL( SCIPsetCutselPriority(scip, (SCIP_CUTSEL*)paramdata, SCIPparamGetInt(param)) ); /*lint !e740*/
47 
48  return SCIP_OKAY;
49 }
50 
51 /** internal method for creating a cut selector */
52 static
54  SCIP_CUTSEL** cutsel, /**< pointer to store cut selector */
55  SCIP_SET* set, /**< global SCIP settings */
56  SCIP_MESSAGEHDLR* messagehdlr, /**< message handler */
57  BMS_BLKMEM* blkmem, /**< block memory for parameter settings */
58  const char* name, /**< name of cut selector */
59  const char* desc, /**< description of cut selector */
60  int priority, /**< priority of the cut selector */
61  SCIP_DECL_CUTSELCOPY ((*cutselcopy)), /**< copy method of cut selector or NULL if you don't want to copy your plugin into sub-SCIPs */
62  SCIP_DECL_CUTSELFREE ((*cutselfree)), /**< destructor of cut selector */
63  SCIP_DECL_CUTSELINIT ((*cutselinit)), /**< initialize cut selector */
64  SCIP_DECL_CUTSELEXIT ((*cutselexit)), /**< deinitialize cut selector */
65  SCIP_DECL_CUTSELINITSOL((*cutselinitsol)),/**< solving process initialization method of cut selector */
66  SCIP_DECL_CUTSELEXITSOL((*cutselexitsol)),/**< solving process deinitialization method of cut selector */
67  SCIP_DECL_CUTSELSELECT((*cutselselect)), /**< cut selection method */
68  SCIP_CUTSELDATA* cutseldata /**< cut selector data */
69  )
70 {
72  char paramdesc[SCIP_MAXSTRLEN];
73 
74  assert(cutsel != NULL);
75  assert(name != NULL);
76  assert(desc != NULL);
77  assert(cutselselect != NULL);
78 
79  SCIP_ALLOC( BMSallocMemory(cutsel) );
80  BMSclearMemory(*cutsel);
81 
82  SCIP_ALLOC( BMSduplicateMemoryArray(&(*cutsel)->name, name, strlen(name)+1) );
83  SCIP_ALLOC( BMSduplicateMemoryArray(&(*cutsel)->desc, desc, strlen(desc)+1) );
84  (*cutsel)->priority = priority;
85  (*cutsel)->cutselcopy = cutselcopy;
86  (*cutsel)->cutselfree = cutselfree;
87  (*cutsel)->cutselinit = cutselinit;
88  (*cutsel)->cutselexit = cutselexit;
89  (*cutsel)->cutselinitsol = cutselinitsol;
90  (*cutsel)->cutselexitsol = cutselexitsol;
91  (*cutsel)->cutselselect = cutselselect;
92  (*cutsel)->cutseldata = cutseldata;
93  (*cutsel)->initialized = FALSE;
94 
95  /* create clocks */
96  SCIP_CALL( SCIPclockCreate(&(*cutsel)->setuptime, SCIP_CLOCKTYPE_DEFAULT) );
97  SCIP_CALL( SCIPclockCreate(&(*cutsel)->cutseltime, SCIP_CLOCKTYPE_DEFAULT) );
98 
99  /* add parameters */
100  (void) SCIPsnprintf(paramname, SCIP_MAXSTRLEN, "cutselection/%s/priority", name);
101  (void) SCIPsnprintf(paramdesc, SCIP_MAXSTRLEN, "priority of cut selection rule <%s>", name);
102  SCIP_CALL( SCIPsetAddIntParam(set, messagehdlr, blkmem, paramname, paramdesc,
103  &(*cutsel)->priority, FALSE, priority, INT_MIN/4, INT_MAX/2,
104  paramChgdCutselPriority, (SCIP_PARAMDATA*)(*cutsel)) ); /*lint !e740*/
105 
106  return SCIP_OKAY;
107 }
108 
109 
110 /** creates a cut selector */
112  SCIP_CUTSEL** cutsel, /**< pointer to store cut selector */
113  SCIP_SET* set, /**< global SCIP settings */
114  SCIP_MESSAGEHDLR* messagehdlr, /**< message handler */
115  BMS_BLKMEM* blkmem, /**< block memory for parameter settings */
116  const char* name, /**< name of cut selector */
117  const char* desc, /**< description of cut selector */
118  int priority, /**< priority of the cut selector in standard mode */
119  SCIP_DECL_CUTSELCOPY ((*cutselcopy)), /**< copy method of cut selector or NULL if you don't want to copy your plugin into sub-SCIPs */
120  SCIP_DECL_CUTSELFREE ((*cutselfree)), /**< destructor of cut selector */
121  SCIP_DECL_CUTSELINIT ((*cutselinit)), /**< initialize cut selector */
122  SCIP_DECL_CUTSELEXIT ((*cutselexit)), /**< deinitialize cut selector */
123  SCIP_DECL_CUTSELINITSOL((*cutselinitsol)),/**< solving process initialization method of cut selector */
124  SCIP_DECL_CUTSELEXITSOL((*cutselexitsol)),/**< solving process deinitialization method of cut selector */
125  SCIP_DECL_CUTSELSELECT((*cutselselect)), /**< cut selection method */
126  SCIP_CUTSELDATA* cutseldata /**< cut selector data */
127  )
128 {
129  assert(cutsel != NULL);
130  assert(name != NULL);
131  assert(desc != NULL);
132  assert(cutselselect != NULL);
133 
134  SCIP_CALL_FINALLY( doCutselCreate(cutsel, set, messagehdlr, blkmem, name, desc, priority,
135  cutselcopy, cutselfree, cutselinit, cutselexit, cutselinitsol, cutselexitsol, cutselselect,
136  cutseldata), (void) SCIPcutselFree(cutsel, set) );
137 
138  return SCIP_OKAY;
139 }
140 
141 /** gets name of cut selector */
142 const char* SCIPcutselGetName(
143  SCIP_CUTSEL* cutsel /**< cut selector */
144  )
145 {
146  assert(cutsel != NULL);
147 
148  return cutsel->name;
149 }
150 
151 /** calls cut selectors to select cuts */
153  SCIP_SET* set, /**< global SCIP settings */
154  SCIP_ROW** cuts, /**< array with cuts to select from */
155  int ncuts, /**< length of cuts */
156  int nforcedcuts, /**< number of forced cuts at start of given array */
157  SCIP_Bool root, /**< are we at the root node? */
158  int maxnselectedcuts, /**< maximum number of cuts to be selected */
159  int* nselectedcuts /**< pointer to return number of selected cuts */
160  )
161 {
162  int i;
163  SCIP_RESULT result = SCIP_DIDNOTFIND;
164 
165  assert(nselectedcuts != NULL);
166 
167  /* sort the cut selectors by priority */
168  SCIPsetSortCutsels(set);
169 
170  /* Redefine maxnselectedcuts to be w.r.t the optional cuts. */
171  maxnselectedcuts -= nforcedcuts;
172 
173  /* try all cut selectors until one succeeds */
174  *nselectedcuts = 0;
175  for( i = 0; i < set->ncutsels && result == SCIP_DIDNOTFIND; ++i )
176  {
177  SCIP_CUTSEL* cutsel;
178 
179  cutsel = set->cutsels[i];
180 
181  assert(cutsel != NULL);
182  assert(ncuts - nforcedcuts > 0);
183  assert(maxnselectedcuts > 0);
184 
185  SCIP_CALL( cutsel->cutselselect(set->scip, cutsel, &(cuts[nforcedcuts]), ncuts - nforcedcuts, cuts, nforcedcuts,
186  root, maxnselectedcuts, nselectedcuts, &result) );
187 
188  assert(*nselectedcuts <= maxnselectedcuts);
189  assert(result == SCIP_SUCCESS || result == SCIP_DIDNOTFIND);
190  assert(result != SCIP_DIDNOTFIND || *nselectedcuts == 0);
191  }
192 
193  return SCIP_OKAY;
194 }
195 
196 /** gets description of cut selector */
197 const char* SCIPcutselGetDesc(
198  SCIP_CUTSEL* cutsel /**< cut selector */
199  )
200 {
201  assert(cutsel != NULL);
202 
203  return cutsel->desc;
204 }
205 
206 /** copies the given cut selector to a new scip */
208  SCIP_CUTSEL* cutsel, /**< cut selector */
209  SCIP_SET* set /**< SCIP_SET of SCIP to copy to */
210  )
211 {
212  assert(cutsel != NULL);
213  assert(set != NULL);
214  assert(set->scip != NULL);
215 
216  if( cutsel->cutselcopy != NULL )
217  {
218  SCIPsetDebugMsg(set, "including cut selector %s in subscip %p\n", SCIPcutselGetName(cutsel), (void*)set->scip);
219  SCIP_CALL( cutsel->cutselcopy(set->scip, cutsel) );
220  }
221  return SCIP_OKAY;
222 }
223 
224 /** frees memory of cut selector */
226  SCIP_CUTSEL** cutsel, /**< pointer to cut selector data structure */
227  SCIP_SET* set /**< global SCIP settings */
228  )
229 {
230  assert(cutsel != NULL);
231 
232  if( *cutsel == NULL )
233  return SCIP_OKAY;
234 
235  assert(!(*cutsel)->initialized);
236  assert(set != NULL);
237 
238  /* call destructor of cut selector */
239  if( (*cutsel)->cutselfree != NULL )
240  {
241  SCIP_CALL( (*cutsel)->cutselfree(set->scip, *cutsel) );
242  }
243 
244  /* free clocks */
245  SCIPclockFree(&(*cutsel)->cutseltime);
246  SCIPclockFree(&(*cutsel)->setuptime);
247 
248  BMSfreeMemoryArrayNull(&(*cutsel)->name);
249  BMSfreeMemoryArrayNull(&(*cutsel)->desc);
250  BMSfreeMemory(cutsel);
251 
252  return SCIP_OKAY;
253 }
254 
255 /** initializes cut selector */
257  SCIP_CUTSEL* cutsel, /**< cut selector */
258  SCIP_SET* set /**< global SCIP settings */
259  )
260 {
261  assert(cutsel != NULL);
262  assert(set != NULL);
263 
264  if( cutsel->initialized )
265  {
266  SCIPerrorMessage("cut selector <%s> already initialized", cutsel->name);
267  return SCIP_INVALIDCALL;
268  }
269 
270  if( set->misc_resetstat )
271  {
272  SCIPclockReset(cutsel->setuptime);
273  SCIPclockReset(cutsel->cutseltime);
274  }
275 
276  if( cutsel->cutselinit != NULL )
277  {
278  /* start timing */
279  SCIPclockStart(cutsel->setuptime, set);
280 
281  SCIP_CALL( cutsel->cutselinit(set->scip, cutsel) );
282 
283  /* stop timing */
284  SCIPclockStop(cutsel->setuptime, set);
285  }
286 
287  cutsel->initialized = TRUE;
288 
289  return SCIP_OKAY;
290 }
291 
292 /** deinitializes cut selector */
294  SCIP_CUTSEL* cutsel, /**< cut selector */
295  SCIP_SET* set /**< global SCIP settings */
296  )
297 {
298  assert(cutsel != NULL);
299  assert(set != NULL);
300 
301  if( !cutsel->initialized )
302  {
303  SCIPerrorMessage("cut selector <%s> not initialized", cutsel->name);
304  return SCIP_INVALIDCALL;
305  }
306 
307  if( cutsel->cutselexit != NULL )
308  {
309  /* start timing */
310  SCIPclockStart(cutsel->setuptime, set);
311 
312  SCIP_CALL( cutsel->cutselexit(set->scip, cutsel) );
313 
314  /* stop timing */
315  SCIPclockStop(cutsel->setuptime, set);
316  }
317  cutsel->initialized = FALSE;
318 
319  return SCIP_OKAY;
320 }
321 
322 /** informs cut selector that the branch and bound process is being started */
324  SCIP_CUTSEL* cutsel, /**< cut selector */
325  SCIP_SET* set /**< global SCIP settings */
326  )
327 {
328  assert(cutsel != NULL);
329  assert(set != NULL);
330 
331  /* call solving process initialization method of cut selector */
332  if( cutsel->cutselinitsol != NULL )
333  {
334  /* start timing */
335  SCIPclockStart(cutsel->setuptime, set);
336 
337  SCIP_CALL( cutsel->cutselinitsol(set->scip, cutsel) );
338 
339  /* stop timing */
340  SCIPclockStop(cutsel->setuptime, set);
341  }
342 
343  return SCIP_OKAY;
344 }
345 
346 /** informs cut selector that the branch and bound process is being started */
348  SCIP_CUTSEL* cutsel, /**< cut selector */
349  SCIP_SET* set /**< global SCIP settings */
350  )
351 {
352  assert(cutsel != NULL);
353  assert(set != NULL);
354 
355  /* call solving process deinitialization method of cut selector */
356  if( cutsel->cutselexitsol != NULL )
357  {
358  /* start timing */
359  SCIPclockStart(cutsel->setuptime, set);
360 
361  SCIP_CALL( cutsel->cutselexitsol(set->scip, cutsel) );
362 
363  /* stop timing */
364  SCIPclockStop(cutsel->setuptime, set);
365  }
366 
367  return SCIP_OKAY;
368 }
369 
370 /** gets user data of cut selector */
372  SCIP_CUTSEL* cutsel /**< cut selector */
373  )
374 {
375  assert(cutsel != NULL);
376 
377  return cutsel->cutseldata;
378 }
379 
380 /** sets user data of cut selector; user has to free old data in advance! */
382  SCIP_CUTSEL* cutsel, /**< cut selector */
383  SCIP_CUTSELDATA* cutseldata /**< new cut selector user data */
384 )
385 {
386  assert(cutsel != NULL);
387 
388  cutsel->cutseldata = cutseldata;
389 }
390 
391 /** gets priority of cut selector */
393  SCIP_CUTSEL* cutsel /**< cut selector */
394  )
395 {
396  assert(cutsel != NULL);
397 
398  return cutsel->priority;
399 }
400 
401 /** enables or disables all clocks of @p cutsel, depending on the value of the flag */
403  SCIP_CUTSEL* cutsel, /**< the cut selector for which all clocks should be enabled or disabled */
404  SCIP_Bool enable /**< should the clocks of the cut selector be enabled? */
405  )
406 {
407  assert(cutsel != NULL);
408 
409  SCIPclockEnableOrDisable(cutsel->setuptime, enable);
410  SCIPclockEnableOrDisable(cutsel->cutseltime, enable);
411 }
412 
413 
414 /* new callback/method setter methods */
415 
416 /** sets copy method of cut selector */
418  SCIP_CUTSEL* cutsel, /**< cut selector */
419  SCIP_DECL_CUTSELCOPY ((*cutselcopy)) /**< copy method of cut selector or NULL if you don't want to copy your plugin into sub-SCIPs */
420  )
421 {
422  assert(cutsel != NULL);
423 
424  cutsel->cutselcopy = cutselcopy;
425 }
426 
427 /** sets destructor method of cut selector */
429  SCIP_CUTSEL* cutsel, /**< cut selector */
430  SCIP_DECL_CUTSELFREE ((*cutselfree)) /**< destructor of cut selector */
431  )
432 {
433  assert(cutsel != NULL);
434 
435  cutsel->cutselfree = cutselfree;
436 }
437 
438 /** sets initialization method of cut selector */
440  SCIP_CUTSEL* cutsel, /**< cut selector */
441  SCIP_DECL_CUTSELINIT ((*cutselinit)) /**< initialize cut selector */
442  )
443 {
444  assert(cutsel != NULL);
445 
446  cutsel->cutselinit = cutselinit;
447 }
448 
449 /** sets deinitialization method of cut selector */
451  SCIP_CUTSEL* cutsel, /**< cut selector */
452  SCIP_DECL_CUTSELEXIT ((*cutselexit)) /**< deinitialize cut selector */
453  )
454 {
455  assert(cutsel != NULL);
456 
457  cutsel->cutselexit = cutselexit;
458 }
459 
460 /** sets solving process initialization method of cut selector */
462  SCIP_CUTSEL* cutsel, /**< cut selector */
463  SCIP_DECL_CUTSELINITSOL ((*cutselinitsol))/**< solving process initialization method of cut selector */
464  )
465 {
466  assert(cutsel != NULL);
467 
468  cutsel->cutselinitsol = cutselinitsol;
469 }
470 
471 /** sets solving process deinitialization method of cut selector */
473  SCIP_CUTSEL* cutsel, /**< cut selector */
474  SCIP_DECL_CUTSELEXITSOL ((*cutselexitsol))/**< solving process deinitialization method of cut selector */
475  )
476 {
477  assert(cutsel != NULL);
478 
479  cutsel->cutselexitsol = cutselexitsol;
480 }
481 
482 /** sets priority of cut selector */
484  SCIP_CUTSEL* cutsel, /**< cut selector */
485  SCIP_SET* set, /**< global SCIP settings */
486  int priority /**< new priority of the cut selector */
487  )
488 {
489  assert(cutsel != NULL);
490  assert(set != NULL);
491 
492  cutsel->priority = priority;
493  set->cutselssorted = FALSE;
494 }
495 
496 /** is cut selector initialized? */
498  SCIP_CUTSEL* cutsel /**< cut selector */
499  )
500 {
501  assert(cutsel != NULL);
502 
503  return cutsel->initialized;
504 }
505 
506 /** gets time in seconds used in this cut selector for setting up for next stages */
508  SCIP_CUTSEL* cutsel /**< cut selector */
509  )
510 {
511  assert(cutsel != NULL);
512 
513  return SCIPclockGetTime(cutsel->setuptime);
514 }
515 
516 /** gets time in seconds used in this cut selector */
518  SCIP_CUTSEL* cutsel /**< cut selector */
519  )
520 {
521  assert(cutsel != NULL);
522 
523  return SCIPclockGetTime(cutsel->cutseltime);
524 }
525 
526 /** compares two cut selectors w. r. to their priority */
527 SCIP_DECL_SORTPTRCOMP(SCIPcutselComp)
528 { /*lint --e{715}*/
529  return ((SCIP_CUTSEL*)elem2)->priority - ((SCIP_CUTSEL*)elem1)->priority;
530 }
enum SCIP_Result SCIP_RESULT
Definition: type_result.h:52
const char * SCIPcutselGetName(SCIP_CUTSEL *cutsel)
Definition: cutsel.c:142
SCIP_RETCODE SCIPcutselsSelect(SCIP_SET *set, SCIP_ROW **cuts, int ncuts, int nforcedcuts, SCIP_Bool root, int maxnselectedcuts, int *nselectedcuts)
Definition: cutsel.c:152
SCIP_RETCODE SCIPcutselFree(SCIP_CUTSEL **cutsel, SCIP_SET *set)
Definition: cutsel.c:225
SCIP_RETCODE SCIPcutselExitsol(SCIP_CUTSEL *cutsel, SCIP_SET *set)
Definition: cutsel.c:347
#define BMSfreeMemoryArrayNull(ptr)
Definition: memory.h:141
SCIP_CUTSELDATA * SCIPcutselGetData(SCIP_CUTSEL *cutsel)
Definition: cutsel.c:371
SCIP_PARAMDATA * SCIPparamGetData(SCIP_PARAM *param)
Definition: paramset.c:670
#define SCIP_DECL_CUTSELINITSOL(x)
Definition: type_cutsel.h:88
#define SCIP_MAXSTRLEN
Definition: def.h:293
internal methods for clocks and timing issues
struct SCIP_CutselData SCIP_CUTSELDATA
Definition: type_cutsel.h:44
struct SCIP_ParamData SCIP_PARAMDATA
Definition: type_paramset.h:78
#define SCIP_CALL_FINALLY(x, y)
Definition: def.h:426
SCIP_RETCODE SCIPcutselCreate(SCIP_CUTSEL **cutsel, SCIP_SET *set, SCIP_MESSAGEHDLR *messagehdlr, BMS_BLKMEM *blkmem, const char *name, const char *desc, int priority, SCIP_DECL_CUTSELCOPY((*cutselcopy)), SCIP_DECL_CUTSELFREE((*cutselfree)), SCIP_DECL_CUTSELINIT((*cutselinit)), SCIP_DECL_CUTSELEXIT((*cutselexit)), SCIP_DECL_CUTSELINITSOL((*cutselinitsol)), SCIP_DECL_CUTSELEXITSOL((*cutselexitsol)), SCIP_DECL_CUTSELSELECT((*cutselselect)), SCIP_CUTSELDATA *cutseldata)
Definition: cutsel.c:111
static SCIP_RETCODE doCutselCreate(SCIP_CUTSEL **cutsel, SCIP_SET *set, SCIP_MESSAGEHDLR *messagehdlr, BMS_BLKMEM *blkmem, const char *name, const char *desc, int priority, SCIP_DECL_CUTSELCOPY((*cutselcopy)), SCIP_DECL_CUTSELFREE((*cutselfree)), SCIP_DECL_CUTSELINIT((*cutselinit)), SCIP_DECL_CUTSELEXIT((*cutselexit)), SCIP_DECL_CUTSELINITSOL((*cutselinitsol)), SCIP_DECL_CUTSELEXITSOL((*cutselexitsol)), SCIP_DECL_CUTSELSELECT((*cutselselect)), SCIP_CUTSELDATA *cutseldata)
Definition: cutsel.c:53
void SCIPcutselSetPriority(SCIP_CUTSEL *cutsel, SCIP_SET *set, int priority)
Definition: cutsel.c:483
SCIP_Bool initialized
Definition: struct_cutsel.h:52
void SCIPclockStop(SCIP_CLOCK *clck, SCIP_SET *set)
Definition: clock.c:351
#define FALSE
Definition: def.h:87
internal methods for cut selectors
void SCIPclockStart(SCIP_CLOCK *clck, SCIP_SET *set)
Definition: clock.c:281
static SCIP_DECL_PARAMCHGD(paramChgdCutselPriority)
Definition: cutsel.c:38
int SCIPsnprintf(char *t, int len, const char *s,...)
Definition: misc.c:10755
#define TRUE
Definition: def.h:86
void SCIPsetSortCutsels(SCIP_SET *set)
Definition: set.c:4359
enum SCIP_Retcode SCIP_RETCODE
Definition: type_retcode.h:54
#define SCIP_DECL_CUTSELEXIT(x)
Definition: type_cutsel.h:77
void SCIPcutselEnableOrDisableClocks(SCIP_CUTSEL *cutsel, SCIP_Bool enable)
Definition: cutsel.c:402
internal methods for handling parameter settings
void SCIPcutselSetData(SCIP_CUTSEL *cutsel, SCIP_CUTSELDATA *cutseldata)
Definition: cutsel.c:381
void SCIPclockEnableOrDisable(SCIP_CLOCK *clck, SCIP_Bool enable)
Definition: clock.c:251
#define BMSfreeMemory(ptr)
Definition: memory.h:138
Definition: heur_padm.c:123
#define SCIP_DECL_CUTSELSELECT(x)
Definition: type_cutsel.h:123
SCIP_CLOCK * setuptime
Definition: struct_cutsel.h:48
void SCIPcutselSetCopy(SCIP_CUTSEL *cutsel, SCIP_DECL_CUTSELCOPY((*cutselcopy)))
Definition: cutsel.c:417
SCIP_DECL_SORTPTRCOMP(SCIPcutselComp)
Definition: cutsel.c:527
SCIP_RETCODE SCIPcutselCopyInclude(SCIP_CUTSEL *cutsel, SCIP_SET *set)
Definition: cutsel.c:207
#define SCIPerrorMessage
Definition: pub_message.h:55
void SCIPclockReset(SCIP_CLOCK *clck)
Definition: clock.c:200
SCIP_Real SCIPcutselGetSetupTime(SCIP_CUTSEL *cutsel)
Definition: cutsel.c:507
#define SCIP_DECL_CUTSELINIT(x)
Definition: type_cutsel.h:69
SCIP_Real SCIPclockGetTime(SCIP_CLOCK *clck)
Definition: clock.c:429
#define NULL
Definition: lpi_spx1.cpp:155
internal methods for global SCIP settings
#define SCIP_CALL(x)
Definition: def.h:384
void SCIPcutselSetExitsol(SCIP_CUTSEL *cutsel, SCIP_DECL_CUTSELEXITSOL((*cutselexitsol)))
Definition: cutsel.c:472
#define SCIP_DECL_CUTSELCOPY(x)
Definition: type_cutsel.h:53
SCIP_RETCODE SCIPsetAddIntParam(SCIP_SET *set, SCIP_MESSAGEHDLR *messagehdlr, BMS_BLKMEM *blkmem, 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: set.c:3014
#define BMSduplicateMemoryArray(ptr, source, num)
Definition: memory.h:136
SCIP_RETCODE SCIPcutselInit(SCIP_CUTSEL *cutsel, SCIP_SET *set)
Definition: cutsel.c:256
SCIP_RETCODE SCIPclockCreate(SCIP_CLOCK **clck, SCIP_CLOCKTYPE clocktype)
Definition: clock.c:161
SCIP_Bool SCIPcutselIsInitialized(SCIP_CUTSEL *cutsel)
Definition: cutsel.c:497
#define SCIP_Bool
Definition: def.h:84
static const char * paramname[]
Definition: lpi_msk.c:4998
SCIP_RETCODE SCIPcutselExit(SCIP_CUTSEL *cutsel, SCIP_SET *set)
Definition: cutsel.c:293
void SCIPclockFree(SCIP_CLOCK **clck)
Definition: clock.c:176
const char * SCIPcutselGetDesc(SCIP_CUTSEL *cutsel)
Definition: cutsel.c:197
#define SCIPsetDebugMsg
Definition: set.h:1755
SCIP_RETCODE SCIPsetCutselPriority(SCIP *scip, SCIP_CUTSEL *cutsel, int priority)
Definition: scip_cutsel.c:249
void SCIPcutselSetFree(SCIP_CUTSEL *cutsel, SCIP_DECL_CUTSELFREE((*cutselfree)))
Definition: cutsel.c:428
#define BMSclearMemory(ptr)
Definition: memory.h:122
int SCIPparamGetInt(SCIP_PARAM *param)
Definition: paramset.c:725
void SCIPcutselSetExit(SCIP_CUTSEL *cutsel, SCIP_DECL_CUTSELEXIT((*cutselexit)))
Definition: cutsel.c:450
data structures for cut selectors
int SCIPcutselGetPriority(SCIP_CUTSEL *cutsel)
Definition: cutsel.c:392
#define SCIP_Real
Definition: def.h:177
SCIP_CUTSELDATA * cutseldata
Definition: struct_cutsel.h:50
void SCIPcutselSetInit(SCIP_CUTSEL *cutsel, SCIP_DECL_CUTSELINIT((*cutselinit)))
Definition: cutsel.c:439
#define SCIP_DECL_CUTSELFREE(x)
Definition: type_cutsel.h:61
#define BMSallocMemory(ptr)
Definition: memory.h:111
SCIP_CLOCK * cutseltime
Definition: struct_cutsel.h:49
SCIP_Real SCIPcutselGetTime(SCIP_CUTSEL *cutsel)
Definition: cutsel.c:517
struct BMS_BlkMem BMS_BLKMEM
Definition: memory.h:430
#define SCIP_ALLOC(x)
Definition: def.h:395
#define SCIP_DECL_CUTSELEXITSOL(x)
Definition: type_cutsel.h:99
SCIP callable library.
SCIP_RETCODE SCIPcutselInitsol(SCIP_CUTSEL *cutsel, SCIP_SET *set)
Definition: cutsel.c:323
void SCIPcutselSetInitsol(SCIP_CUTSEL *cutsel, SCIP_DECL_CUTSELINITSOL((*cutselinitsol)))
Definition: cutsel.c:461