1 /* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ 2 /* */ 3 /* This file is part of the program and library */ 4 /* SCIP --- Solving Constraint Integer Programs */ 5 /* */ 6 /* Copyright (C) 2002-2021 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_xyz.h 17 * @ingroup CONSHDLRS 18 * @brief constraint handler for xyz constraints 19 * @author Tobias Achterberg 20 */ 21 22 /*---+----1----+----2----+----3----+----4----+----5----+----6----+----7----+----8----+----9----+----0----+----1----+----2*/ 23 24 #ifndef __SCIP_CONS_XYZ_H__ 25 #define __SCIP_CONS_XYZ_H__ 26 27 28 #include "scip/scip.h" 29 30 #ifdef __cplusplus 31 extern "C" { 32 #endif 33 34 /** creates the handler for xyz constraints and includes it in SCIP 35 * 36 * @ingroup ConshdlrIncludes 37 * */ 38 SCIP_EXPORT 39 SCIP_RETCODE SCIPincludeConshdlrXyz( 40 SCIP* scip /**< SCIP data structure */ 41 ); 42 43 /**@addtogroup CONSHDLRS 44 * 45 * @{ 46 * 47 * @name Xyz Constraints 48 * 49 * @{ 50 */ 51 52 /** creates and captures a xyz constraint 53 * 54 * @note the constraint gets captured, hence at one point you have to release it using the method SCIPreleaseCons() 55 */ 56 SCIP_EXPORT 57 SCIP_RETCODE SCIPcreateConsXyz( 58 SCIP* scip, /**< SCIP data structure */ 59 SCIP_CONS** cons, /**< pointer to hold the created constraint */ 60 const char* name, /**< name of constraint */ 61 int nvars, /**< number of variables in the constraint */ 62 SCIP_VAR** vars, /**< array with variables of constraint entries */ 63 SCIP_Real* coefs, /**< array with coefficients of constraint entries */ 64 SCIP_Real lhs, /**< left hand side of constraint */ 65 SCIP_Real rhs, /**< right hand side of constraint */ 66 SCIP_Bool initial, /**< should the LP relaxation of constraint be in the initial LP? 67 * Usually set to TRUE. Set to FALSE for 'lazy constraints'. */ 68 SCIP_Bool separate, /**< should the constraint be separated during LP processing? 69 * Usually set to TRUE. */ 70 SCIP_Bool enforce, /**< should the constraint be enforced during node processing? 71 * TRUE for model constraints, FALSE for additional, redundant constraints. */ 72 SCIP_Bool check, /**< should the constraint be checked for feasibility? 73 * TRUE for model constraints, FALSE for additional, redundant constraints. */ 74 SCIP_Bool propagate, /**< should the constraint be propagated during node processing? 75 * Usually set to TRUE. */ 76 SCIP_Bool local, /**< is constraint only valid locally? 77 * Usually set to FALSE. Has to be set to TRUE, e.g., for branching constraints. */ 78 SCIP_Bool modifiable, /**< is constraint modifiable (subject to column generation)? 79 * Usually set to FALSE. In column generation applications, set to TRUE if pricing 80 * adds coefficients to this constraint. */ 81 SCIP_Bool dynamic, /**< is constraint subject to aging? 82 * Usually set to FALSE. Set to TRUE for own cuts which 83 * are separated as constraints. */ 84 SCIP_Bool removable, /**< should the relaxation be removed from the LP due to aging or cleanup? 85 * Usually set to FALSE. Set to TRUE for 'lazy constraints' and 'user cuts'. */ 86 SCIP_Bool stickingatnode /**< should the constraint always be kept at the node where it was added, even 87 * if it may be moved to a more global node? 88 * Usually set to FALSE. Set to TRUE to for constraints that represent node data. */ 89 ); 90 91 /** creates and captures a xyz constraint with all its constraint flags set to their 92 * default values 93 * 94 * @note the constraint gets captured, hence at one point you have to release it using the method SCIPreleaseCons() 95 */ 96 SCIP_EXPORT 97 SCIP_RETCODE SCIPcreateConsBasicXyz( 98 SCIP* scip, /**< SCIP data structure */ 99 SCIP_CONS** cons, /**< pointer to hold the created constraint */ 100 const char* name, /**< name of constraint */ 101 int nvars, /**< number of variables in the constraint */ 102 SCIP_VAR** vars, /**< array with variables of constraint entries */ 103 SCIP_Real* coefs, /**< array with coefficients of constraint entries */ 104 SCIP_Real lhs, /**< left hand side of constraint */ 105 SCIP_Real rhs /**< right hand side of constraint */ 106 ); 107 108 /** @} */ 109 110 /** @} */ 111 112 #ifdef __cplusplus 113 } 114 #endif 115 116 #endif 117