Scippy

SCIP

Solving Constraint Integer Programs

cons_stp.h
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 cons_stp.h
17  * @brief Constraint handler for Steiner problems
18  * @author Gerald Gamrath
19  * @author Daniel Rehfeldt
20  * @author Michael Winkler
21  *
22  * This file checks solutions for feasibility and separates violated model constraints. For more details see \ref STP_CONS page.
23  */
24 
25 /*---+----1----+----2----+----3----+----4----+----5----+----6----+----7----+----8----+----9----+----0----+----1----+----2*/
26 
27 #ifndef __SCIP_CONS_STP_H__
28 #define __SCIP_CONS_STP_H__
29 
30 
31 #include "scip/scip.h"
32 #include "graph.h"
33 
34 #ifdef __cplusplus
35 extern "C" {
36 #endif
37 
38 
39 /** creates the handler for element constraints and includes it in SCIP */
40 SCIP_EXPORT
42  SCIP* scip /**< SCIP data structure */
43  );
44 
45 /** creates and captures a stp constraint */
46 SCIP_EXPORT
48  SCIP* scip, /**< SCIP data structure */
49  SCIP_CONS** cons, /**< pointer to hold the created constraint */
50  const char* name, /**< name of constraint */
51  GRAPH* graph /**< graph data structure */
52  );
53 
54 /** sets graph */
55 SCIP_EXPORT
57  SCIP* scip /**< SCIP data structure */
58  );
59 
60 /** add cut corresponding to contraction */
61 SCIP_EXPORT
63  SCIP* scip, /**< SCIP data structure */
64  SCIP_VAR* edge, /**< edge */
65  SCIP_VAR* revedge, /**< reversed edge */
66  SCIP_Bool localcut /**< add local cut? */
67  );
68 
69 /** returns implications start array */
70 SCIP_EXPORT
71 const int* SCIPStpGetPcImplStarts(
72  SCIP* scip /**< SCIP data structure */
73  );
74 
75 /** returns number implications starts */
76 SCIP_EXPORT
78  SCIP* scip /**< SCIP data structure */
79  );
80 
81 /** returns implications vertices array */
82 SCIP_EXPORT
83 const int* SCIPStpGetPcImplVerts(
84  SCIP* scip /**< SCIP data structure */
85  );
86 
87 
88 #ifdef __cplusplus
89 }
90 #endif
91 
92 #endif
SCIP_RETCODE SCIPStpAddContractionCut(SCIP *scip, SCIP_VAR *edge, SCIP_VAR *revedge, SCIP_Bool localcut)
Definition: cons_stp.c:1165
enum SCIP_Retcode SCIP_RETCODE
Definition: type_retcode.h:54
includes various files containing graph methods used for Steiner tree problems
void SCIPStpConshdlrSetGraph(SCIP *scip)
Definition: cons_stp.c:1208
SCIP_RETCODE SCIPincludeConshdlrStp(SCIP *scip)
Definition: cons_stp.c:1051
#define SCIP_Bool
Definition: def.h:84
SCIP_RETCODE SCIPcreateConsStp(SCIP *scip, SCIP_CONS **cons, const char *name, GRAPH *graph)
Definition: cons_stp.c:1135
const int * SCIPStpGetPcImplStarts(SCIP *scip)
Definition: cons_stp.c:1231
const int * SCIPStpGetPcImplVerts(SCIP *scip)
Definition: cons_stp.c:1269
int SCIPStpGetPcImplNstarts(SCIP *scip)
Definition: cons_stp.c:1250
SCIP callable library.