cons.c
Go to the documentation of this file.
23 /*---+----1----+----2----+----3----+----4----+----5----+----6----+----7----+----8----+----9----+----0----+----1----+----2*/
48 #define AGERESETAVG_INIT 1000.0 /**< initial value of the exponentially decaying weighted sum for ages */
50 #define AGERESETAVG_DECAY 0.0005 /**< weight of a new addend in the exponentially decyaing sum */
51 #define AGERESETAVG_AGELIMIT 2.0 /**< in dynamic setting, a constraint is deleted if its age exceeds the
53 #define AGERESETAVG_OBSOLETEAGE 1.8 /**< in dynamic setting, a constraint is marked obsolete if its age exceeds the
307 assert(conshdlr->propconss[c]->markpropagate || (conshdlr->propconss[c]->obsolete == (c >= conshdlr->nusefulpropconss)));
318 )
327 )
334 /** updates the exponentially decaying weighted age average for age resets after a constraint age was reset */
359 || (set->cons_agelimit == 0 && cons->age > AGERESETAVG_AGELIMIT * conshdlrGetAgeresetavg(cons->conshdlr))));
374 || (set->cons_obsoleteage == 0 && cons->age > AGERESETAVG_OBSOLETEAGE * conshdlrGetAgeresetavg(cons->conshdlr))));
377 /** marks constraint to be obsolete; it will be moved to the last part of the constraint arrays, such that
450 * thus, we have to reset the enforcement counters in order to enforce all constraints again, especially
452 * this case should occur almost never, because a constraint that was not enforced in the last enforcement
453 * is a newly added one, and it is very unlikely that this constraint will become obsolete before the next
455 * this reset is not performed for separation and propagation, because they are not vital for correctness
477 /* in case the constraint is marked to be propagated, we do not move it in the propconss array since the first
507 * it will be moved to the first part of the constraint arrays, such that it is checked, enforced, separated,
534 assert(conshdlr->nusefulcheckconss <= cons->checkconsspos && cons->checkconsspos < conshdlr->ncheckconss);
552 assert(conshdlr->nusefulsepaconss <= cons->sepaconsspos && cons->sepaconsspos < conshdlr->nsepaconss);
567 assert(conshdlr->nusefulenfoconss <= cons->enfoconsspos && cons->enfoconsspos < conshdlr->nenfoconss);
580 /* in case the constraint is marked to be propagated, we do not move it in the propconss array since the first
586 assert(conshdlr->nusefulpropconss <= cons->propconsspos && cons->propconsspos < conshdlr->npropconss);
608 * @note the propagation array is divided into three parts in contrast to the other constraint arrays;
609 * the first part contains constraints which were marked to be propagated (independently of its age)
610 * the second part contains the useful (non-obsolete) constraints which are not marked to be propagated
613 * @note if a constraint gets marked for propagation we put it into the first part regardless of its age
629 /* it may happen that the constraint is deleted while updates are delayed: in this case we just return */
638 /* propagation of the constraint is globally or locally disabled, so we do not have to move the constraint in the
648 /* if the constraint is obsolete, we need to move it first to the non-obsolete part of the array */
651 assert(conshdlr->nusefulpropconss <= cons->propconsspos && cons->propconsspos < conshdlr->npropconss);
664 assert(conshdlr->nmarkedpropconss <= cons->propconsspos && cons->propconsspos < conshdlr->nusefulpropconss);
683 * @note the propagation array is divided into three parts in contrast to the other constraint arrays;
684 * the first part contains constraints which were marked to be propagated (independently of its age)
685 * the second part contains the useful (non-obsolete) constraints which are not marked to be propagated
688 * @note if a constraint gets unmarked for propagation, it is put into the right part depending on its age
704 /* it may happen that the constraint is deleted while updates are delayed: in this case we just return */
713 /* propagation of the constraint is globally or locally disabled, so we do not have to move the constraint in the
724 /* first, move the constraint out of the first part to the second part of the constraint array */
1003 /* we have to make sure that even this obsolete constraint is enforced in the next enforcement call;
1004 * if the same LP or pseudo solution is enforced again, only the newly added useful constraints are
1006 * enforced again; this is not needed for separation and propagation, because they are not vital for correctness
1055 /* if the constraint that moved to the free position was a newly added constraint and not enforced in the last
1057 * this check is not performed for separation and propagation, because they are not vital for correctness
1105 conshdlr->checkconss[conshdlr->ncheckconss] = conshdlr->checkconss[conshdlr->nusefulcheckconss];
1201 /* if the constraint is marked to be propagated, we have to move it to the first part of the array */
1204 /* temporarily unmark the constraint to be propagated, such that we can use the method below */
1235 /* unmark constraint to be propagated; this will move the constraint to the obsolete or non-obsolete part of the
1292 SCIPsetDebugMsg(set, "enable separation of constraint <%s> in constraint handler <%s>\n", cons->name, conshdlr->name);
1320 SCIPdebugMessage("disable separation of constraint <%s> in constraint handler <%s>\n", cons->name, conshdlr->name);
1352 SCIPsetDebugMsg(set, "enable propagation of constraint <%s> in constraint handler <%s>\n", cons->name, conshdlr->name);
1380 SCIPdebugMessage("disable propagation of constraint <%s> in constraint handler <%s>\n", cons->name, conshdlr->name);
1421 SCIPsetDebugMsg(set, "enable constraint <%s> in constraint handler <%s>\n", cons->name, conshdlr->name);
1483 SCIPsetDebugMsg(set, "disable constraint <%s> in constraint handler <%s>\n", cons->name, conshdlr->name);
1530 int depth, /**< depth in the tree where the activation takes place, or -1 for global problem */
1556 SCIPsetDebugMsg(set, "activate constraint <%s> in constraint handler <%s> (depth %d, focus=%u)\n",
1576 /* add constraint to the initconss array if the constraint is initial and added to the focus node */
1623 SCIPsetDebugMsg(set, "deactivate constraint <%s> in constraint handler <%s>\n", cons->name, conshdlr->name);
1676 * recent obsolete check constraints will be moved to the last positions in the sepa-, enfo-, check-, and prop-arrays;
1677 * recent useful constraints will be moved to the first positions in the sepa-, enfo-, check-, and prop-arrays;
1678 * constraints which were recently marked to be propagated are moved to the first positions in the prop-array;
1699 SCIPsetDebugMsg(set, "processing %d constraints that have to be updated in constraint handler <%s>\n",
1715 SCIPsetDebugMsg(set, " -> constraint <%s>: insert=%u, activate=%u, deactivate=%u, enable=%u, disable=%u, sepaenable=%u, sepadisable=%u, propenable=%u, propdisable=%u, obsolete=%u, free=%u (consdata=%p)\n",
1738 SCIP_CALL( conshdlrActivateCons(conshdlr, set, stat, cons, cons->activedepth, cons->updateactfocus) );
1814 /* nothing to do here: the constraint is freed, when it is released from the updateconss array */
1874 /** marks constraint handler to delay all constraint updates until the next conshdlrProcessUpdates() call */
1878 )
1902 SCIPsetDebugMsg(set, "constraint updates of constraint handler <%s> will be processed immediately (count:%d)\n",
1931 SCIPsetDebugMsg(set, "constraint <%s> of age %g has to be updated in constraint handler <%s> (consdata=%p)\n",
1980 SCIPsetDebugMsg(set, "including constraint handler %s in subscip %p\n", SCIPconshdlrGetName(conshdlr), (void*)set->scip);
1998 int checkpriority, /**< priority of the constraint handler for checking feasibility (and propagation) */
1999 int sepafreq, /**< frequency for separating cuts; zero means to separate only in the root node */
2000 int propfreq, /**< frequency for propagating domains; zero means only preprocessing propagation */
2001 int eagerfreq, /**< frequency for using all instead of only the useful constraints in separation,
2003 int maxprerounds, /**< maximal number of presolving rounds the constraint handler participates in (-1: no limit) */
2004 SCIP_Bool delaysepa, /**< should separation method be delayed, if other separators found cuts? */
2005 SCIP_Bool delayprop, /**< should propagation method be delayed, if other propagators found reductions? */
2006 SCIP_Bool needscons, /**< should the constraint handler be skipped, if no constraints are available? */
2007 SCIP_PROPTIMING proptiming, /**< positions in the node solving loop where propagation method of constraint handlers should be executed */
2008 SCIP_PRESOLTIMING presoltiming, /**< timing mask of the constraint handler's presolving method */
2009 SCIP_DECL_CONSHDLRCOPY((*conshdlrcopy)), /**< copy method of constraint handler or NULL if you don't want to copy your plugin into sub-SCIPs */
2013 SCIP_DECL_CONSINITPRE ((*consinitpre)), /**< presolving initialization method of constraint handler */
2014 SCIP_DECL_CONSEXITPRE ((*consexitpre)), /**< presolving deinitialization method of constraint handler */
2015 SCIP_DECL_CONSINITSOL ((*consinitsol)), /**< solving process initialization method of constraint handler */
2016 SCIP_DECL_CONSEXITSOL ((*consexitsol)), /**< solving process deinitialization method of constraint handler */
2018 SCIP_DECL_CONSTRANS ((*constrans)), /**< transform constraint data into data belonging to the transformed problem */
2019 SCIP_DECL_CONSINITLP ((*consinitlp)), /**< initialize LP with relaxations of "initial" constraints */
2021 SCIP_DECL_CONSSEPASOL ((*conssepasol)), /**< separate cutting planes for arbitrary primal solution */
2023 SCIP_DECL_CONSENFORELAX ((*consenforelax)), /**< enforcing constraints for relaxation solutions */
2040 SCIP_DECL_CONSGETDIVEBDCHGS((*consgetdivebdchgs)), /**< constraint handler diving solution enforcement method */
2055 /* the interface change from delay flags to timings cannot be recognized at compile time: Exit with an appropriate
2060 SCIPmessagePrintError("ERROR: 'PRESOLDELAY'-flag no longer available since SCIP 3.2, use an appropriate "
2233 (void) SCIPsnprintf(paramdesc, SCIP_MAXSTRLEN, "timing when constraint propagation should be called (%u:BEFORELP, %u:DURINGLPLOOP, %u:AFTERLPLOOP, %u:ALWAYS)", SCIP_PROPTIMING_BEFORELP, SCIP_PROPTIMING_DURINGLPLOOP, SCIP_PROPTIMING_AFTERLPLOOP, SCIP_PROPTIMING_ALWAYS);
2235 (int*)(&(*conshdlr)->proptiming), TRUE, (int) proptiming, (int) SCIP_PROPTIMING_BEFORELP, (int) SCIP_PROPTIMING_ALWAYS, NULL, NULL) ); /*lint !e713*/
2239 "frequency for using all instead of only the useful constraints in separation, propagation and enforcement (-1: never, 0: only in first evaluation)",
2258 (void) SCIPsnprintf(paramdesc, SCIP_MAXSTRLEN, "timing mask of the constraint handler's presolving method (%u:FAST, %u:MEDIUM, %u:EXHAUSTIVE, %u:FINAL)",
2259 SCIP_PRESOLTIMING_FAST, SCIP_PRESOLTIMING_MEDIUM, SCIP_PRESOLTIMING_EXHAUSTIVE, SCIP_PRESOLTIMING_FINAL);
2261 (int*)&(*conshdlr)->presoltiming, TRUE, (int) presoltiming, (int) SCIP_PRESOLTIMING_FAST, (int) SCIP_PRESOLTIMING_MAX, NULL, NULL) ); /*lint !e740 !e713*/
2276 int checkpriority, /**< priority of the constraint handler for checking feasibility (and propagation) */
2277 int sepafreq, /**< frequency for separating cuts; zero means to separate only in the root node */
2278 int propfreq, /**< frequency for propagating domains; zero means only preprocessing propagation */
2279 int eagerfreq, /**< frequency for using all instead of only the useful constraints in separation,
2281 int maxprerounds, /**< maximal number of presolving rounds the constraint handler participates in (-1: no limit) */
2282 SCIP_Bool delaysepa, /**< should separation method be delayed, if other separators found cuts? */
2283 SCIP_Bool delayprop, /**< should propagation method be delayed, if other propagators found reductions? */
2284 SCIP_Bool needscons, /**< should the constraint handler be skipped, if no constraints are available? */
2285 SCIP_PROPTIMING proptiming, /**< positions in the node solving loop where propagation method of constraint handlers should be executed */
2286 SCIP_PRESOLTIMING presoltiming, /**< timing mask of the constraint handler's presolving method */
2287 SCIP_DECL_CONSHDLRCOPY((*conshdlrcopy)), /**< copy method of constraint handler or NULL if you don't want to copy your plugin into sub-SCIPs */
2291 SCIP_DECL_CONSINITPRE ((*consinitpre)), /**< presolving initialization method of constraint handler */
2292 SCIP_DECL_CONSEXITPRE ((*consexitpre)), /**< presolving deinitialization method of constraint handler */
2293 SCIP_DECL_CONSINITSOL ((*consinitsol)), /**< solving process initialization method of constraint handler */
2294 SCIP_DECL_CONSEXITSOL ((*consexitsol)), /**< solving process deinitialization method of constraint handler */
2296 SCIP_DECL_CONSTRANS ((*constrans)), /**< transform constraint data into data belonging to the transformed problem */
2297 SCIP_DECL_CONSINITLP ((*consinitlp)), /**< initialize LP with relaxations of "initial" constraints */
2299 SCIP_DECL_CONSSEPASOL ((*conssepasol)), /**< separate cutting planes for arbitrary primal solution */
2301 SCIP_DECL_CONSENFORELAX ((*consenforelax)), /**< enforcing constraints for relaxation solutions */
2318 SCIP_DECL_CONSGETDIVEBDCHGS((*consgetdivebdchgs)), /**< constraint handler diving solution enforcement method */
2330 SCIP_CALL_FINALLY( doConshdlrCreate(conshdlr, set, messagehdlr, blkmem, name, desc, sepapriority, enfopriority,
2331 checkpriority, sepafreq, propfreq, eagerfreq, maxprerounds, delaysepa, delayprop, needscons, proptiming,
2332 presoltiming, conshdlrcopy, consfree, consinit, consexit, consinitpre, consexitpre, consinitsol, consexitsol,
2333 consdelete, constrans, consinitlp, conssepalp, conssepasol, consenfolp, consenforelax, consenfops, conscheck,
2334 consprop, conspresol, consresprop, conslock, consactive, consdeactive, consenable, consdisable, consdelvars,
2475 /* because during constraint processing, constraints of this handler may be deleted, activated, deactivated,
2476 * enabled, disabled, marked obsolete or useful, which would change the conss array given to the
2477 * external method; to avoid this, these changes will be buffered and processed after the method call
2519 /* because during constraint processing, constraints of this handler may be deleted, activated, deactivated,
2520 * enabled, disabled, marked obsolete or useful, which would change the conss array given to the
2521 * external method; to avoid this, these changes will be buffered and processed after the method call
2586 /* because during constraint processing, constraints of this handler may be deleted, activated, deactivated,
2587 * enabled, disabled, marked obsolete or useful, which would change the conss array given to the
2588 * external method; to avoid this, these changes will be buffered and processed after the method call
2605 /* after a restart the LP is empty but the initial constraints are not included in the initialconss array anymore;
2606 * we have to put them back into this array in order to obtain the correct initial root relaxation
2614 /**@todo should only active constraints be added to the initconss array? at least cons->active is asserted in
2642 /* because during constraint processing, constraints of this handler may be deleted, activated, deactivated,
2643 * enabled, disabled, marked obsolete or useful, which would change the conss array given to the
2644 * external method; to avoid this, these changes will be buffered and processed after the method call
2686 /* because during constraint processing, constraints of this handler may be deleted, activated, deactivated,
2687 * enabled, disabled, marked obsolete or useful, which would change the conss array given to the
2688 * external method; to avoid this, these changes will be buffered and processed after the method call
2723 /* because during constraint processing, constraints of this handler may be deleted, activated, deactivated,
2724 * enabled, disabled, marked obsolete or useful, which would change the conss array given to the
2725 * external method; to avoid this, these changes will be buffered and processed after the method call
2733 SCIP_CALL( conshdlr->consexitsol(set->scip, conshdlr, conshdlr->conss, conshdlr->nconss, restart) );
2745 /** calls LP initialization method of constraint handler to separate all initial active constraints */
2752 SCIP_Bool initkeptconss, /**< Also initialize constraints which are valid at a more global node,
2755 SCIP_Bool* cutoff /**< pointer to store whether infeasibility was detected while building the LP */
2772 SCIPsetDebugMsg(set, "initializing LP with %d initial constraints of handler <%s> (ninitconss=%d, kept=%d, initkept=%u)\n",
2773 initkeptconss ? conshdlr->ninitconss : conshdlr->ninitconss - conshdlr->ninitconsskept, conshdlr->name,
2776 /* no constraints to initialize (or only kept constraints which do not need to be initialized this time) -> return */
2777 if( conshdlr->needscons && (conshdlr->ninitconss == 0 || (!initkeptconss && conshdlr->ninitconss == conshdlr->ninitconsskept)) )
2780 /* because during constraint processing, constraints of this handler may be deleted, activated, deactivated,
2781 * enabled, disabled, marked obsolete or useful, which would change the conss array given to the
2782 * external method; to avoid this, these changes will be buffered and processed after the method call
2793 /* add all kept initial constraints which are currently active to the second part of the initconss array */
2794 /* @todo keep track of where a constraint was already initialized (e.g., in the conssetchg)? */
2807 SCIP_CALL( conshdlr->consinitlp(set->scip, conshdlr, &conshdlr->initconss[conshdlr->ninitconsskept],
2871 || (0 <= conshdlr->lastnusefulsepaconss && conshdlr->lastnusefulsepaconss <= conshdlr->nusefulsepaconss));
2892 /* all constraints that were not yet separated on the new LP solution must be useful constraints, which means,
2921 SCIPsetDebugMsg(set, "separating constraints %d to %d of %d constraints of handler <%s> (%s LP solution)\n",
2942 /* because during constraint processing, constraints of this handler may be deleted, activated, deactivated,
2943 * enabled, disabled, marked obsolete or useful, which would change the conss array given to the
2944 * external method; to avoid this, these changes will be buffered and processed after the method call
2990 SCIPerrorMessage("LP separation method of constraint handler <%s> returned invalid result <%d>\n",
2998 SCIPsetDebugMsg(set, "LP separation method of constraint handler <%s> was delayed\n", conshdlr->name);
3073 /* because during constraint processing, constraints of this handler may be deleted, activated, deactivated,
3074 * enabled, disabled, marked obsolete or useful, which would change the conss array given to the
3075 * external method; to avoid this, these changes will be buffered and processed after the method call
3084 SCIP_CALL( conshdlr->conssepasol(set->scip, conshdlr, conss, nconss, nusefulconss, sol, result) );
3117 SCIPerrorMessage("SOL separation method of constraint handler <%s> returned invalid result <%d>\n",
3125 SCIPsetDebugMsg(set, "SOL separation method of constraint handler <%s> was delayed\n", conshdlr->name);
3136 /** calls enforcing method of constraint handler for a relaxation solution for all constraints added after last
3165 || (0 <= conshdlr->lastnusefulenfoconss && conshdlr->lastnusefulenfoconss <= conshdlr->nusefulenfoconss));
3175 * the integrality constraint handler always needs to be enforced for all constraints since external branching
3191 /* if we already enforced the same relaxation solution at this node, we will only enforce new constraints in the
3192 * following; however, the result of the last call for the old constraint is still valid and we have to ensure
3203 /* all constraints that were not yet enforced on the new relaxation solution must be useful constraints, which means,
3235 SCIPdebugMessage("enforcing constraints %d to %d of %d constraints of handler <%s> (%s relaxation solution)\n",
3236 firstcons, firstcons + nconss - 1, conshdlr->nenfoconss, conshdlr->name, relaxchanged ? "new" : "old");
3257 /* because during constraint processing, constraints of this handler may be deleted, activated, deactivated,
3258 * enabled, disabled, marked obsolete or useful, which would change the conss array given to the
3259 * external method; to avoid this, these changes will be buffered and processed after the method call
3267 SCIP_CALL( conshdlr->consenforelax(set->scip, relaxsol, conshdlr, conss, nconss, nusefulconss, solinfeasible, result) );
3308 SCIPerrorMessage("enforcing method of constraint handler <%s> for relaxation solutions returned invalid result <%d>\n",
3313 /* if the same relaxation solution was already enforced at this node, we only enforced new constraints this time;
3314 * if the enforelax call returns feasible now, the solution is only feasible w.r.t. the new constraints, if the
3315 * last call detected infeasibility for the old constraints, we have to change the result to infeasible
3324 /** calls enforcing method of constraint handler for LP solution for all constraints added after last
3347 || (0 <= conshdlr->lastnusefulenfoconss && conshdlr->lastnusefulenfoconss <= conshdlr->nusefulenfoconss));
3369 assert(conshdlr->lastenfolpresult == SCIP_FEASIBLE || conshdlr->lastenfolpresult == SCIP_INFEASIBLE
3372 /* if we already enforced the same pseudo solution at this node, we will only enforce new constraints in the
3373 * following; however, the result of the last call for the old constraint is still valid and we have to ensure
3380 assert(conshdlr->lastenfolpresult == SCIP_INFEASIBLE || conshdlr->lastenfolpresult == SCIP_SEPARATED);
3385 /* all constraints that were not yet enforced on the new LP solution must be useful constraints, which means,
3415 SCIPsetDebugMsg(set, "enforcing constraints %d to %d of %d constraints of handler <%s> (%s LP solution)\n",
3416 firstcons, firstcons + nconss - 1, conshdlr->nenfoconss, conshdlr->name, lpchanged ? "new" : "old");
3437 /* because during constraint processing, constraints of this handler may be deleted, activated, deactivated,
3438 * enabled, disabled, marked obsolete or useful, which would change the conss array given to the
3439 * external method; to avoid this, these changes will be buffered and processed after the method call
3447 SCIP_CALL( conshdlr->consenfolp(set->scip, conshdlr, conss, nconss, nusefulconss, solinfeasible, result) );
3487 SCIPerrorMessage("enforcing method of constraint handler <%s> for LP solutions returned invalid result <%d>\n",
3492 /* if the same LP solution was already enforced at this node, we only enforced new constraints this time;
3493 * if the enfolp call returns feasible now, the solution is only feasible w.r.t. the new constraints, if the
3494 * last call detected infeasibility for the old constraints, we have to change the result to infeasible
3510 SCIP_Bool* success, /**< pointer to store whether constraint handler successfully found a variable */
3511 SCIP_Bool* infeasible /**< pointer to store whether the current node was detected to be infeasible */
3523 SCIP_CALL( conshdlr->consgetdivebdchgs(set->scip, conshdlr, diveset, sol, success, infeasible) );
3529 /** calls enforcing method of constraint handler for pseudo solution for all constraints added after last
3540 SCIP_Bool objinfeasible, /**< is the solution infeasible anyway due to violating lower objective bound? */
3553 || (0 <= conshdlr->lastnusefulenfoconss && conshdlr->lastnusefulenfoconss <= conshdlr->nusefulenfoconss));
3587 /* if we already enforced the same pseudo solution at this node, we will only enforce new constraints in the
3588 * following; however, the result of the last call for the old constraint is still valid and we have to ensure
3599 /* all constraints that were not yet enforced on the new LP solution must be useful constraints, which means,
3627 SCIPsetDebugMsg(set, "enforcing constraints %d to %d of %d constraints of handler <%s> (%s pseudo solution, objinfeasible=%u)\n",
3628 firstcons, firstcons + nconss - 1, conshdlr->nenfoconss, conshdlr->name, pschanged ? "new" : "old", objinfeasible);
3646 /* because during constraint processing, constraints of this handler may be deleted, activated, deactivated,
3647 * enabled, disabled, marked obsolete or useful, which would change the conss array given to the
3648 * external method; to avoid this, these changes will be buffered and processed after the method call
3656 SCIP_CALL( conshdlr->consenfops(set->scip, conshdlr, conss, nconss, nusefulconss, solinfeasible, objinfeasible, result) );
3670 SCIPerrorMessage("enforcing method of constraint handler <%s> for pseudo solutions was skipped, even though the solution was not objective-infeasible\n",
3676 /* A constraint handler might return SCIP_DIDNOTRUN and not check any constraints in case objinfeasible was
3710 SCIPerrorMessage("enforcing method of constraint handler <%s> for pseudo solutions returned invalid result <%d>\n",
3715 /* if the same pseudo solution was already enforced at this node, we only enforced new constraints this time;
3716 * if the enfops call returns feasible now, the solution is only feasible w.r.t. the new constraints, if the
3717 * last call detected infeasibility for the old constraints, we have to change the result to infeasible
3725 * Even if nothing is enforced, the solution might still be infeasible due to violating lower bound.
3743 SCIP_Bool checklprows, /**< Do constraints represented by rows in the current LP have to be checked? */
3761 SCIPsetDebugMsg(set, "checking %d constraints of handler <%s>\n", conshdlr->ncheckconss, conshdlr->name);
3763 /* because during constraint processing, constraints of this handler may be deleted, activated, deactivated,
3764 * enabled, disabled, marked obsolete or useful, which would change the conss array given to the
3765 * external method; to avoid this, these changes will be buffered and processed after the method call
3773 SCIP_CALL( conshdlr->conscheck(set->scip, conshdlr, conshdlr->checkconss, conshdlr->ncheckconss,
3789 SCIPerrorMessage("feasibility check of constraint handler <%s> returned invalid result <%d>\n", conshdlr->name, *result);
3818 || (0 <= conshdlr->lastnusefulpropconss && conshdlr->lastnusefulpropconss <= conshdlr->nusefulpropconss));
3840 if( !fullpropagation && conshdlr->lastpropdomchgcount == stat->domchgcount && conshdlr->nmarkedpropconss == 0 )
3842 /* all constraints that were not yet propagated on the new domains must be useful constraints, which means,
3872 SCIPsetDebugMsg(set, "propagating constraints %d to %d of %d constraints of handler <%s> (%s pseudo solution, %d useful)\n",
3874 !fullpropagation && conshdlr->lastpropdomchgcount == stat->domchgcount ? "old" : "new", nusefulconss);
3891 /* because during constraint processing, constraints of this handler may be deleted, activated, deactivated,
3892 * enabled, disabled, marked obsolete or useful, which would change the conss array given to the
3893 * external method; to avoid this, these changes will be buffered and processed after the method call
3908 SCIP_CALL( conshdlr->consprop(set->scip, conshdlr, conss, nconss, nusefulconss, nmarkedpropconss, proptiming, result) );
3949 SCIPerrorMessage("propagation method of constraint handler <%s> returned invalid result <%d>\n",
3957 SCIPsetDebugMsg(set, "propagation method of constraint handler <%s> was delayed\n", conshdlr->name);
3985 int* nchgsides, /**< pointer to total number of changed left/right hand sides of all presolvers */
4013 SCIPsetDebugMsg(set, "presolving %d constraints of handler <%s>\n", conshdlr->nactiveconss, conshdlr->name);
4053 /* because during constraint processing, constraints of this handler may be deleted, activated, deactivated,
4054 * enabled, disabled, marked obsolete or useful, which would change the conss array given to the
4055 * external method; to avoid this, these changes will be buffered and processed after the method call
4063 SCIP_CALL( conshdlr->conspresol(set->scip, conshdlr, conshdlr->conss, conshdlr->nactiveconss, nrounds, timing,
4095 SCIPerrorMessage("presolving method of constraint handler <%s> returned invalid result <%d>\n",
4105 SCIPsetDebugMsg(set, "after presolving %d constraints left of handler <%s>\n", conshdlr->nactiveconss, conshdlr->name);
4126 /* during constraint processing, constraints of this handler may be deleted, activated, deactivated,
4127 * enabled, disabled, marked obsolete or useful, which would change the conss array given to the
4128 * external method; to avoid this, these changes will be buffered and processed after the method call
4142 /** locks rounding of variables involved in the given constraint constraint handler that doesn't need constraints */
4157 /** unlocks rounding of variables involved in the given constraint constraint handler that doesn't need constraints */
4175 )
4185 )
4195 )
4217 SCIP_DECL_CONSSEPASOL ((*conssepasol)), /**< separate cutting planes for arbitrary primal solution */
4218 int sepafreq, /**< frequency for separating cuts; zero means to separate only in the root node */
4220 SCIP_Bool delaysepa /**< should separation method be delayed, if other separators found cuts? */
4234 /** sets both the propagation callback and the propagation frequency of the constraint handler */
4238 int propfreq, /**< frequency for propagating domains; zero means only preprocessing propagation */
4239 SCIP_Bool delayprop, /**< should propagation method be delayed, if other propagators found reductions? */
4240 SCIP_PROPTIMING timingmask /**< positions in the node solving loop where propagators should be executed */
4267 SCIP_DECL_CONSHDLRCOPY((*conshdlrcopy)), /**< copy method of constraint handler or NULL if you don't want to copy your plugin into sub-SCIPs */
4315 SCIP_DECL_CONSINITSOL((*consinitsol)) /**< solving process initialization method of constraint handler */
4326 SCIP_DECL_CONSEXITSOL ((*consexitsol)) /**< solving process deinitialization method of constraint handler */
4337 SCIP_DECL_CONSINITPRE((*consinitpre)) /**< preprocessing initialization method of constraint handler */
4348 SCIP_DECL_CONSEXITPRE((*consexitpre)) /**< preprocessing deinitialization method of constraint handler */
4360 int maxprerounds, /**< maximal number of presolving rounds the constraint handler participates in (-1: no limit) */
4361 SCIP_PRESOLTIMING presoltiming /**< timing mask of the constraint handler's presolving method */
4369 /* the interface change from delay flags to timings cannot be recognized at compile time: Exit with an appropriate
4374 SCIPmessagePrintError("ERROR: 'PRESOLDELAY'-flag no longer available since SCIP 3.2, use an appropriate "
4396 /** sets method of constraint handler to transform constraint data into data belonging to the transformed problem */
4399 SCIP_DECL_CONSTRANS ((*constrans)) /**< transform constraint data into data belonging to the transformed problem */
4407 /** sets method of constraint handler to initialize LP with relaxations of "initial" constraints */
4410 SCIP_DECL_CONSINITLP ((*consinitlp)) /**< initialize LP with relaxations of "initial" constraints */
4531 SCIP_DECL_CONSGETDIVEBDCHGS((*consgetdivebdchgs)) /**< constraint handler diving solution enforcement method */
4539 /** gets array with constraints of constraint handler; the first SCIPconshdlrGetNActiveConss() entries are the active
4540 * constraints, the last SCIPconshdlrGetNConss() - SCIPconshdlrGetNActiveConss() constraints are deactivated
4542 * @note A constraint is active if it is global and was not removed or it was added locally (in that case the local
4547 )
4557 )
4567 )
4576 * @attention Usually, there should be no need to access this array. Use this only if you are absolutely sure what you are doing.
4580 )
4590 )
4600 )
4610 )
4619 * @note A constraint is active if it is global and was not removed or it was added locally (in that case the local
4624 )
4634 )
4644 )
4653 SCIP_CONSHDLR* conshdlr, /**< the constraint handler for which all clocks should be enabled or disabled */
4674 )
4684 )
4694 )
4704 )
4714 )
4724 )
4734 )
4741 /** gets time in seconds used for propagation in this constraint handler during strong branching */
4744 )
4754 )
4764 )
4774 )
4784 )
4794 )
4804 )
4814 )
4824 )
4834 )
4844 )
4854 )
4864 )
4874 )
4884 )
4894 )
4904 )
4914 )
4921 /** gets maximum number of active constraints of constraint handler existing at the same time */
4924 )
4934 )
4944 )
4954 )
4964 )
4974 )
4981 /** gets number of holes added to domains of variables in presolving method of constraint handler */
4984 )
4994 )
5004 )
5014 )
5024 )
5034 )
5041 /** gets number of times the presolving method of the constraint handler was called and tried to find reductions */
5044 )
5054 )
5064 )
5074 )
5084 )
5094 )
5101 /** gets frequency of constraint handler for eager evaluations in separation, propagation and enforcement */
5104 )
5114 )
5124 )
5134 )
5144 )
5154 )
5164 )
5174 )
5184 )
5194 )
5204 )
5226 )
5317 BMSfreeBlockMemoryArrayNull(blkmem, &(*conssetchg)->addedconss, (*conssetchg)->addedconsssize);
5318 BMSfreeBlockMemoryArrayNull(blkmem, &(*conssetchg)->disabledconss, (*conssetchg)->disabledconsssize);