Scippy

SCIP

Solving Constraint Integer Programs

cons_disjunction.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-2016 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 email to scip@zib.de. */
13 /* */
14 /* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
15 
16 /**@file cons_disjunction.h
17  * @ingroup CONSHDLRS
18  * @brief constraint handler for disjunction constraints
19  * @author Stefan Heinz
20  * @author Michael Winkler
21  *
22  * A disjunction constraint \f$ C \f$ is a constraint of the form
23  * \f[
24  * C = C_1 \vee \dots \vee C_n
25  * \f]
26  * where all the \f$ C_i \f$ are individual constraints themselves.
27  */
28 
29 /*---+----1----+----2----+----3----+----4----+----5----+----6----+----7----+----8----+----9----+----0----+----1----+----2*/
30 
31 #ifndef __SCIP_CONS_DISJUNCTION_H__
32 #define __SCIP_CONS_DISJUNCTION_H__
33 
34 
35 #include "scip/scip.h"
36 
37 #ifdef __cplusplus
38 extern "C" {
39 #endif
40 
41 /** creates the handler for disjunction constraints and includes it in SCIP */
42 extern
44  SCIP* scip /**< SCIP data structure */
45  );
46 
47 /** creates and captures a disjunction constraint
48  *
49  * @note the constraint gets captured, hence at one point you have to release it using the method SCIPreleaseCons()
50  */
51 extern
53  SCIP* scip, /**< SCIP data structure */
54  SCIP_CONS** cons, /**< pointer to hold the created constraint */
55  const char* name, /**< name of constraint */
56  int nconss, /**< number of initial constraints in disjunction */
57  SCIP_CONS** conss, /**< initial constraint in disjunction */
58  SCIP_CONS* relaxcons, /**< a conjunction constraint containing the linear relaxation of the disjunction constraint, or NULL */
59  SCIP_Bool initial, /**< should the LP relaxation of constraint be in the initial LP?
60  * Usually set to TRUE. Set to FALSE for 'lazy constraints'. */
61  SCIP_Bool enforce, /**< should the constraint be enforced during node processing?
62  * TRUE for model constraints, FALSE for additional, redundant constraints. */
63  SCIP_Bool check, /**< should the constraint be checked for feasibility?
64  * TRUE for model constraints, FALSE for additional, redundant constraints. */
65  SCIP_Bool local, /**< is constraint only valid locally?
66  * Usually set to FALSE. Has to be set to TRUE, e.g., for branching constraints. */
67  SCIP_Bool modifiable, /**< is constraint modifiable (subject to column generation)?
68  * Usually set to FALSE. In column generation applications, set to TRUE if pricing
69  * adds coefficients to this constraint. */
70  SCIP_Bool dynamic /**< is constraint subject to aging?
71  * Usually set to FALSE. Set to TRUE for own cuts which
72  * are separated as constraints. */
73  );
74 
75 /** creates and captures a cumulative constraint
76  * in its most basic version, i. e., all constraint flags are set to their basic value as explained for the
77  * method SCIPcreateConsDisjunction(); all flags can be set via SCIPsetConsFLAGNAME-methods in scip.h
78  *
79  * @see SCIPcreateConsDisjunction() for information about the basic constraint flag configuration
80  *
81  * @note the constraint gets captured, hence at one point you have to release it using the method SCIPreleaseCons()
82  */
83 extern
85  SCIP* scip, /**< SCIP data structure */
86  SCIP_CONS** cons, /**< pointer to hold the created constraint */
87  const char* name, /**< name of constraint */
88  int nconss, /**< number of initial constraints in disjunction */
89  SCIP_CONS** conss, /**< initial constraint in disjunction */
90  SCIP_CONS* relaxcons /**< a conjunction constraint containing the linear relaxation of the disjunction constraint, or NULL */
91  );
92 
93 /** adds constraint to the disjunction of constraints */
94 extern
96  SCIP* scip, /**< SCIP data structure */
97  SCIP_CONS* cons, /**< disjunction constraint */
98  SCIP_CONS* addcons /**< additional constraint in disjunction */
99  );
100 
101 #ifdef __cplusplus
102 }
103 #endif
104 
105 #endif
SCIP_RETCODE SCIPcreateConsDisjunction(SCIP *scip, SCIP_CONS **cons, const char *name, int nconss, SCIP_CONS **conss, SCIP_CONS *relaxcons, SCIP_Bool initial, SCIP_Bool enforce, SCIP_Bool check, SCIP_Bool local, SCIP_Bool modifiable, SCIP_Bool dynamic)
enum SCIP_Retcode SCIP_RETCODE
Definition: type_retcode.h:53
#define SCIP_Bool
Definition: def.h:53
SCIP_RETCODE SCIPcreateConsBasicDisjunction(SCIP *scip, SCIP_CONS **cons, const char *name, int nconss, SCIP_CONS **conss, SCIP_CONS *relaxcons)
SCIP_RETCODE SCIPincludeConshdlrDisjunction(SCIP *scip)
SCIP_RETCODE SCIPaddConsElemDisjunction(SCIP *scip, SCIP_CONS *cons, SCIP_CONS *addcons)
SCIP callable library.