GOBNILP
f164d83
|
Implements the functions needed to add acyclicity constraints based on the convex hull of the family-variable polytope for 4 nodes. More...
#include "convex4_cuts.h"
Functions | |
SCIP_RETCODE | C4_add_convexhull_constraints (SCIP *scip, SolutionInfo *solinfo, ParentSetData *psd, SCIP_Bool ***store, SCIP_CONSHDLR *conshdlr, SCIP_SOL *sol, int *nGen, SCIP_Bool forcecuts, SCIP_Bool *found_efficacious, SCIP_Bool *cutoff) |
Search for (potentially) all non-initial 'convex4' constraints (derived from convex hull of DAG polytope with 4 nodes ) More... | |
SCIP_RETCODE | C4_add_initconvexhull_constraints (SCIP *scip, SCIP_CONSHDLR *conshdlr, SolutionInfo *solinfo, ParentSetData *psd, SCIP_Bool ***store) |
Search for (potentially) all initial 'convex4' constraints (derived from convex hull of DAG polytope with 4 nodes ) More... | |
SCIP_RETCODE | C4_addParams (SCIP *scip) |
Add parameters controlling the addition of 'convex4' cuts to the SCIP instance. More... | |
static SCIP_RETCODE | convexhull4x (SCIP *scip, SCIP_CONSHDLR *conshdlr, SolutionInfo *solinfo, ParentSetData *psd, SCIP_Bool ***store, SCIP_SOL *sol, const int cluster[4], const int convex4x, const int convex4x_ind, SCIP_Bool *result, const SCIP_Bool must_separate, const SCIP_Bool add_to_pool, const SCIP_Bool addcut, const SCIP_Bool forcecuts, SCIP_Bool *found_efficacious_ptr, SCIP_Bool *cutoff) |
(conditionally) add a convex4 cut More... | |
static SCIP_RETCODE | cut_convexhull4b (SCIP *scip, SolutionInfo *solinfo, ParentSetData *psd, SCIP_Bool ***store, SCIP_CONSHDLR *conshdlr, int *nGen, SCIP_SOL *sol, SCIP_Bool must_separate, SCIP_Bool add_to_pool, SCIP_Bool addcut, int limit, SCIP_Bool forcecuts, SCIP_Bool *found_efficacious_ptr, SCIP_Bool *cutoff) |
Search for 4B constraints (derived from convex hull of DAG polytope with 4 nodes ) Can be use to add initial cuts or cuts for a specific LP solution. More... | |
static SCIP_RETCODE | cut_convexhull4c (SCIP *scip, SolutionInfo *solinfo, ParentSetData *psd, SCIP_Bool ***store, SCIP_CONSHDLR *conshdlr, int *nGen, SCIP_SOL *sol, SCIP_Bool must_separate, SCIP_Bool add_to_pool, SCIP_Bool addcut, int limit, SCIP_Bool forcecuts, SCIP_Bool *found_efficacious_ptr, SCIP_Bool *cutoff) |
Search for 4C constraints (derived from convex hull of DAG polytope with 4 nodes ) Can be use to add initial cuts or cuts for a specific LP solution. More... | |
static SCIP_RETCODE | cut_convexhull4d (SCIP *scip, SolutionInfo *solinfo, ParentSetData *psd, SCIP_Bool ***store, SCIP_CONSHDLR *conshdlr, int *nGen, SCIP_SOL *sol, SCIP_Bool must_separate, SCIP_Bool add_to_pool, SCIP_Bool addcut, int limit, SCIP_Bool forcecuts, SCIP_Bool *found_efficacious_ptr, SCIP_Bool *cutoff) |
Search for 4D constraints (derived from convex hull of DAG polytope with 4 nodes ) Can be use to add initial cuts or cuts for a specific LP solution. More... | |
static SCIP_RETCODE | cut_convexhull4e (SCIP *scip, SolutionInfo *solinfo, ParentSetData *psd, SCIP_Bool ***store, SCIP_CONSHDLR *conshdlr, int *nGen, SCIP_SOL *sol, SCIP_Bool must_separate, SCIP_Bool add_to_pool, SCIP_Bool addcut, int limit, SCIP_Bool forcecuts, SCIP_Bool *found_efficacious_ptr, SCIP_Bool *cutoff) |
Search for 4E constraints (derived from convex hull of DAG polytope with 4 nodes ) Can be use to add initial cuts or cuts for a specific LP solution. More... | |
static SCIP_RETCODE | cut_convexhull4g (SCIP *scip, SolutionInfo *solinfo, ParentSetData *psd, SCIP_Bool ***store, SCIP_CONSHDLR *conshdlr, int *nGen, SCIP_SOL *sol, SCIP_Bool must_separate, SCIP_Bool add_to_pool, SCIP_Bool addcut, int limit, SCIP_Bool forcecuts, SCIP_Bool *found_efficacious_ptr, SCIP_Bool *cutoff) |
Search for 4G constraints (derived from convex hull of DAG polytope with 4 nodes ) Can be use to add initial cuts or cuts for a specific LP solution. More... | |
static SCIP_RETCODE | cut_convexhull4h (SCIP *scip, SolutionInfo *solinfo, ParentSetData *psd, SCIP_Bool ***store, SCIP_CONSHDLR *conshdlr, int *nGen, SCIP_SOL *sol, SCIP_Bool must_separate, SCIP_Bool add_to_pool, SCIP_Bool addcut, int limit, SCIP_Bool forcecuts, SCIP_Bool *found_efficacious_ptr, SCIP_Bool *cutoff) |
Search for 4H constraints (derived from convex hull of DAG polytope with 4 nodes ) Can be use to add initial cuts or cuts for a specific LP solution. More... | |
static SCIP_RETCODE | cut_convexhull4i (SCIP *scip, SolutionInfo *solinfo, ParentSetData *psd, SCIP_Bool ***store, SCIP_CONSHDLR *conshdlr, int *nGen, SCIP_SOL *sol, SCIP_Bool must_separate, SCIP_Bool add_to_pool, SCIP_Bool addcut, int limit, SCIP_Bool forcecuts, SCIP_Bool *found_efficacious_ptr, SCIP_Bool *cutoff) |
Search for 4I constraints (derived from convex hull of DAG polytope with 4 nodes ) Can be use to add initial cuts or cuts for a specific LP solution. More... | |
Implements the functions needed to add acyclicity constraints based on the convex hull of the family-variable polytope for 4 nodes.
SCIP_RETCODE C4_add_convexhull_constraints | ( | SCIP * | scip, |
SolutionInfo * | solinfo, | ||
ParentSetData * | psd, | ||
SCIP_Bool *** | store, | ||
SCIP_CONSHDLR * | conshdlr, | ||
SCIP_SOL * | sol, | ||
int * | nGen, | ||
SCIP_Bool | forcecuts, | ||
SCIP_Bool * | found_efficacious, | ||
SCIP_Bool * | cutoff | ||
) |
Search for (potentially) all non-initial 'convex4' constraints (derived from convex hull of DAG polytope with 4 nodes )
(Not all will be searched for; it depends on the parameter settings.)
References cut_convexhull4b(), cut_convexhull4c(), cut_convexhull4d(), cut_convexhull4e(), cut_convexhull4g(), cut_convexhull4h(), and cut_convexhull4i().
SCIP_RETCODE C4_add_initconvexhull_constraints | ( | SCIP * | scip, |
SCIP_CONSHDLR * | conshdlr, | ||
SolutionInfo * | solinfo, | ||
ParentSetData * | psd, | ||
SCIP_Bool *** | store | ||
) |
Search for (potentially) all initial 'convex4' constraints (derived from convex hull of DAG polytope with 4 nodes )
(Not all will be searched for; it depends on the parameter settings.)
References cut_convexhull4b(), cut_convexhull4c(), cut_convexhull4d(), cut_convexhull4e(), cut_convexhull4g(), cut_convexhull4h(), and cut_convexhull4i().
Referenced by SCIP_DECL_CONSINITLP().
SCIP_RETCODE C4_addParams | ( | SCIP * | scip | ) |
Add parameters controlling the addition of 'convex4' cuts to the SCIP instance.
scip | SCIP data structure |
|
static |
(conditionally) add a convex4 cut
scip | SCIP data structure |
conshdlr | constraint handler |
solinfo | solution information |
sol | solution to be separated |
cluster | the 4 variables in the convex4 cut to be added e.g. [v0,v1,v2,v3] = [2,5,4,3] |
convex4x | convex4 cut class, e.g 4b=1, 4c=2 |
convex4x_ind | convex4 cut class, e.g 4b=1, 4c=2 but offset to pick out right pattern |
result | to return whether the cut was added |
must_separate | whether to only add if it separates sol, otherwise added unconditionally |
add_to_pool | whether to add cut to global cut pool |
addcut | whether to add cut to LP ( might just add to cut pool ) |
forcecuts | whether to force cuts to be added |
found_efficacious_ptr | to return whether an efficacious cutting plane was found |
References SolutionInfo::lpsolvals, ParentSetData::nParentSets, and ParentSetData::PaVars.
Referenced by cut_convexhull4b(), cut_convexhull4c(), cut_convexhull4d(), cut_convexhull4e(), cut_convexhull4g(), cut_convexhull4h(), and cut_convexhull4i().
|
static |
Search for 4B constraints (derived from convex hull of DAG polytope with 4 nodes ) Can be use to add initial cuts or cuts for a specific LP solution.
Example convex4b cut:
scip | SCIP data structure |
solinfo | solution information |
conshdlr | constraint handler |
nGen | *nGen is how many cuts added |
sol | solution to be separated |
must_separate | if true cut is only added if it separates sol, otherwise added unconditionally |
add_to_pool | whether to add cut to global cut pool |
addcut | whether to add cut ( might just add to cut pool ) |
limit | limit on number of cuts to add (-1 for no limit ) |
forcecuts | whether to force cuts to be added |
found_efficacious_ptr | to return whether an efficacious cutting plane was found |
References SolutionInfo::ch, convexhull4x(), SolutionInfo::ispa, ParentSetData::n, SolutionInfo::nch, SolutionInfo::npa, SolutionInfo::nposvars, SolutionInfo::pa, and SolutionInfo::posvars.
Referenced by C4_add_convexhull_constraints(), and C4_add_initconvexhull_constraints().
|
static |
Search for 4C constraints (derived from convex hull of DAG polytope with 4 nodes ) Can be use to add initial cuts or cuts for a specific LP solution.
Example 4c cut:
scip | SCIP data structure |
solinfo | solution information |
conshdlr | constraint handler |
nGen | *nGen is how many cuts added |
sol | solution to be separated |
must_separate | if true cut is only added if it separates sol, otherwise added unconditionally |
add_to_pool | whether to add cut to global cut pool |
addcut | whether to add cut ( might just add to cut pool ) |
limit | limit on number of cuts to add (-1 for no limit ) |
forcecuts | whether to force cuts to be added |
found_efficacious_ptr | to return whether an efficacious cutting plane was found |
References convexhull4x(), SolutionInfo::ispa, ParentSetData::n, SolutionInfo::npa, SolutionInfo::nposvars, SolutionInfo::pa, and SolutionInfo::posvars.
Referenced by C4_add_convexhull_constraints(), and C4_add_initconvexhull_constraints().
|
static |
Search for 4D constraints (derived from convex hull of DAG polytope with 4 nodes ) Can be use to add initial cuts or cuts for a specific LP solution.
scip | SCIP data structure |
solinfo | solution information |
conshdlr | constraint handler |
nGen | *nGen is how many cuts added |
sol | solution to be separated |
must_separate | if true cut is only added if it separates sol, otherwise added unconditionally |
add_to_pool | whether to add cut to global cut pool |
addcut | whether to add cut ( might just add to cut pool ) |
limit | limit on number of cuts to add (-1 for no limit ) |
forcecuts | whether to force cuts to be added |
found_efficacious_ptr | to return whether an efficacious cutting plane was found |
References convexhull4x(), SolutionInfo::ispa, ParentSetData::n, SolutionInfo::npa, SolutionInfo::nposvars, SolutionInfo::pa, and SolutionInfo::posvars.
Referenced by C4_add_convexhull_constraints(), and C4_add_initconvexhull_constraints().
|
static |
Search for 4E constraints (derived from convex hull of DAG polytope with 4 nodes ) Can be use to add initial cuts or cuts for a specific LP solution.
Example 4e cut:
scip | SCIP data structure |
solinfo | solution information |
conshdlr | constraint handler |
nGen | *nGen is how many cuts added |
sol | solution to be separated |
must_separate | if true cut is only added if it separates sol, otherwise added unconditionally |
add_to_pool | whether to add cut to global cut pool |
addcut | whether to add cut ( might just add to cut pool ) |
limit | limit on number of cuts to add (-1 for no limit ) |
forcecuts | whether to force cuts to be added |
found_efficacious_ptr | to return whether an efficacious cutting plane was found |
References convexhull4x(), SolutionInfo::ispa, ParentSetData::n, SolutionInfo::npa, SolutionInfo::nposvars, SolutionInfo::pa, and SolutionInfo::posvars.
Referenced by C4_add_convexhull_constraints(), and C4_add_initconvexhull_constraints().
|
static |
Search for 4G constraints (derived from convex hull of DAG polytope with 4 nodes ) Can be use to add initial cuts or cuts for a specific LP solution.
scip | SCIP data structure |
solinfo | solution information |
conshdlr | constraint handler |
nGen | *nGen is how many cuts added |
sol | solution to be separated |
must_separate | if true cut is only added if it separates sol, otherwise added unconditionally |
add_to_pool | whether to add cut to global cut pool |
addcut | whether to add cut ( might just add to cut pool ) |
limit | limit on number of cuts to add (-1 for no limit ) |
forcecuts | whether to force cuts to be added |
found_efficacious_ptr | to return whether an efficacious cutting plane was found |
References SolutionInfo::ch, convexhull4x(), SolutionInfo::ispa, ParentSetData::n, SolutionInfo::nch, SolutionInfo::npa, SolutionInfo::nposvars, SolutionInfo::pa, and SolutionInfo::posvars.
Referenced by C4_add_convexhull_constraints(), and C4_add_initconvexhull_constraints().
|
static |
Search for 4H constraints (derived from convex hull of DAG polytope with 4 nodes ) Can be use to add initial cuts or cuts for a specific LP solution.
Example 4h cut:
scip | SCIP data structure |
solinfo | solution information |
conshdlr | constraint handler |
nGen | *nGen is how many cuts added |
sol | solution to be separated |
must_separate | if true cut is only added if it separates sol, otherwise added unconditionally |
add_to_pool | whether to add cut to global cut pool |
addcut | whether to add cut ( might just add to cut pool ) |
limit | limit on number of cuts to add (-1 for no limit ) |
forcecuts | whether to force cuts to be added |
found_efficacious_ptr | to return whether an efficacious cutting plane was found |
References convexhull4x(), ParentSetData::n, SolutionInfo::npa, SolutionInfo::nposvars, SolutionInfo::pa, and SolutionInfo::posvars.
Referenced by C4_add_convexhull_constraints(), and C4_add_initconvexhull_constraints().
|
static |
Search for 4I constraints (derived from convex hull of DAG polytope with 4 nodes ) Can be use to add initial cuts or cuts for a specific LP solution.
greedy search incomplete algorithm
Example 4i cut:
scip | SCIP data structure |
solinfo | solution information |
conshdlr | constraint handler |
nGen | *nGen is how many cuts added |
sol | solution to be separated |
must_separate | if true cut is only added if it separates sol, otherwise added unconditionally |
add_to_pool | whether to add cut to global cut pool |
addcut | whether to add cut ( might just add to cut pool ) |
limit | limit on number of cuts to add (-1 for no limit ) |
forcecuts | whether to force cuts to be added |
found_efficacious_ptr | to return whether an efficacious cutting plane was found |
References convexhull4x(), SolutionInfo::ispa, ParentSetData::n, SolutionInfo::npa, and SolutionInfo::pa.
Referenced by C4_add_convexhull_constraints(), and C4_add_initconvexhull_constraints().