assert(graph !=
NULL);
79startnode = &graph->
nodes[0];
89 while( edge !=
NULL)
98 if( nextedge !=
NULL|| tourlength > graph->
nnodes)
104 if( node == startnode )
112 if( nextedge ==
NULL)
115node = nextedge->
adjac;
118 while( node != startnode );
120assert(tourlength <= graph->
nnodes);
122 return( graph->
nnodes!= tourlength );
139assert(result !=
NULL);
143 for(
intc = 0; c < nusefulconss && *result !=
SCIP_CUTOFF; ++c)
150assert(consdata !=
NULL);
152graph = consdata->graph;
153assert(graph !=
NULL);
156 for(
inti = 0; i < graph->
nedges; i++)
169 for(
inti = 0; i < graph->
nnodes; i++)
178 for(
inti = 0; i < ncuts && *result !=
SCIP_CUTOFF; ++i)
185 for(
intj = 0; j < graph->
nnodes; j++)
193 while( edge !=
NULL)
195 if( ! cuts[i][edge->
adjac->
id] )
222 for(
inti = graph->
nnodes- 1; i >= 0; i--)
234assert(consdata !=
NULL);
250assert( sourcedata !=
NULL);
253targetdata->graph = sourcedata->graph;
352assert(result !=
NULL);
396assert(result !=
NULL);
431assert(result !=
NULL);
434 for(
inti = 0; i < nconss; ++i )
440assert(conss !=
NULL);
441assert(conss[i] !=
NULL);
443assert(consdata !=
NULL);
444graph = consdata->graph;
445assert(graph !=
NULL);
478assert(result !=
NULL);
540assert(consdata !=
NULL);
545 for(
inti = 0; i < g->
nedges; ++i )
580assert(consdata !=
NULL);
593assert(valid !=
NULL);
608assert(valid !=
NULL);
612 if( conshdlr ==
NULL)
622assert( probdatatsp !=
NULL);
625consdata->graph = graph;
630conshdlr, consdata, initial, separate, enforce, check,
631propagate, local, modifiable, dynamic, removable,
FALSE) );
660 if( conshdlr ==
NULL)
668consdata->graph = graph;
672 SCIP_CALL(
SCIPcreateCons(
scip, cons, name, conshdlr, consdata, initial, separate, enforce, check, propagate,
673local, modifiable, dynamic, removable,
FALSE) );
SCIP_DECL_CONSENFOPS(ConshdlrSubtour::scip_enfops)
SCIP_DECL_CONSSEPASOL(ConshdlrSubtour::scip_sepasol)
SCIP_DECL_CONSLOCK(ConshdlrSubtour::scip_lock)
static SCIP_Bool findSubtour(SCIP *scip, GRAPH *graph, SCIP_SOL *sol)
SCIP_DECL_CONSHDLRCLONE(ObjProbCloneable *ConshdlrSubtour::clone)
SCIP_DECL_CONSDELETE(ConshdlrSubtour::scip_delete)
static SCIP_RETCODE sepaSubtour(SCIP *scip, SCIP_CONSHDLR *conshdlr, SCIP_CONS **conss, int nconss, int nusefulconss, SCIP_SOL *sol, SCIP_Bool enforce, SCIP_RESULT *result)
SCIP_DECL_CONSCOPY(ConshdlrSubtour::scip_copy)
SCIP_DECL_CONSSEPALP(ConshdlrSubtour::scip_sepalp)
SCIP_DECL_CONSTRANS(ConshdlrSubtour::scip_trans)
SCIP_DECL_CONSDELVARS(ConshdlrSubtour::scip_delvars)
SCIP_DECL_CONSPRINT(ConshdlrSubtour::scip_print)
SCIP_DECL_CONSCHECK(ConshdlrSubtour::scip_check)
SCIP_DECL_CONSPROP(ConshdlrSubtour::scip_prop)
SCIP_DECL_CONSENFOLP(ConshdlrSubtour::scip_enfolp)
C++ constraint handler for TSP subtour elimination constraints.
void capture_graph(GRAPH *gr)
SCIP_Bool ghc_tree(GRAPH *gr, SCIP_Bool **cuts, int *ncuts, double minviol)
void release_graph(GRAPH **gr)
generator for global cuts in undirected graphs
Constraint handler for linear constraints in their most general form, .
void SCIPinfoMessage(SCIP *scip, FILE *file, const char *formatstr,...)
SCIP_CONSHDLR * SCIPfindConshdlr(SCIP *scip, const char *name)
SCIP_CONSDATA * SCIPconsGetData(SCIP_CONS *cons)
SCIP_Bool SCIPconsIsDynamic(SCIP_CONS *cons)
SCIP_Bool SCIPconsIsInitial(SCIP_CONS *cons)
SCIP_RETCODE SCIPprintCons(SCIP *scip, SCIP_CONS *cons, FILE *file)
SCIP_Bool SCIPconsIsChecked(SCIP_CONS *cons)
SCIP_Bool SCIPconsIsEnforced(SCIP_CONS *cons)
SCIP_RETCODE SCIPcreateCons(SCIP *scip, SCIP_CONS **cons, const char *name, SCIP_CONSHDLR *conshdlr, SCIP_CONSDATA *consdata, SCIP_Bool initial, SCIP_Bool separate, SCIP_Bool enforce, SCIP_Bool check, SCIP_Bool propagate, SCIP_Bool local, SCIP_Bool modifiable, SCIP_Bool dynamic, SCIP_Bool removable, SCIP_Bool stickingatnode)
SCIP_Bool SCIPconsIsPropagated(SCIP_CONS *cons)
SCIP_Bool SCIPconsIsLocal(SCIP_CONS *cons)
const char * SCIPconsGetName(SCIP_CONS *cons)
SCIP_Bool SCIPconsIsModifiable(SCIP_CONS *cons)
SCIP_Bool SCIPconsIsStickingAtNode(SCIP_CONS *cons)
SCIP_Bool SCIPconsIsSeparated(SCIP_CONS *cons)
SCIP_Bool SCIPconsIsRemovable(SCIP_CONS *cons)
SCIP_Bool SCIPisCutEfficacious(SCIP *scip, SCIP_SOL *sol, SCIP_ROW *cut)
SCIP_RETCODE SCIPaddRow(SCIP *scip, SCIP_ROW *row, SCIP_Bool forcecut, SCIP_Bool *infeasible)
#define SCIPallocBufferArray(scip, ptr, num)
#define SCIPfreeBufferArray(scip, ptr)
#define SCIPfreeBlockMemory(scip, ptr)
#define SCIPallocBlockMemory(scip, ptr)
SCIP_RETCODE SCIPcacheRowExtensions(SCIP *scip, SCIP_ROW *row)
SCIP_RETCODE SCIPflushRowExtensions(SCIP *scip, SCIP_ROW *row)
SCIP_RETCODE SCIPcreateEmptyRowConshdlr(SCIP *scip, SCIP_ROW **row, SCIP_CONSHDLR *conshdlr, const char *name, SCIP_Real lhs, SCIP_Real rhs, SCIP_Bool local, SCIP_Bool modifiable, SCIP_Bool removable)
SCIP_RETCODE SCIPaddVarToRow(SCIP *scip, SCIP_ROW *row, SCIP_VAR *var, SCIP_Real val)
SCIP_RETCODE SCIPreleaseRow(SCIP *scip, SCIP_ROW **row)
SCIP_Real SCIPgetSolVal(SCIP *scip, SCIP_SOL *sol, SCIP_VAR *var)
SCIP_Real SCIPinfinity(SCIP *scip)
SCIP_Real SCIPfeastol(SCIP *scip)
SCIP_RETCODE SCIPaddVarLocksType(SCIP *scip, SCIP_VAR *var, SCIP_LOCKTYPE locktype, int nlocksdown, int nlocksup)
SCIP_RETCODE SCIPcreateConsSubtour(SCIP *scip, SCIP_CONS **cons, const char *name, GRAPH *graph, SCIP_Bool initial, SCIP_Bool separate, SCIP_Bool enforce, SCIP_Bool check, SCIP_Bool propagate, SCIP_Bool local, SCIP_Bool modifiable, SCIP_Bool dynamic, SCIP_Bool removable)
scip::ObjProbData * SCIPgetObjProbData(SCIP *scip)
C++ wrapper classes for SCIP.
struct GraphEdge * first_edge
Definition of base class for all clonable classes which define problem data.
struct SCIP_ConsData SCIP_CONSDATA
enum SCIP_Result SCIP_RESULT
enum SCIP_Retcode SCIP_RETCODE
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4