Scippy

SCIP

Solving Constraint Integer Programs

cutpool.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-2018 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 cutpool.h
17  * @ingroup INTERNALAPI
18  * @brief internal methods for storing cuts in a cut pool
19  * @author Tobias Achterberg
20  */
21 
22 /*---+----1----+----2----+----3----+----4----+----5----+----6----+----7----+----8----+----9----+----0----+----1----+----2*/
23 
24 #ifndef __SCIP_CUTPOOL_H__
25 #define __SCIP_CUTPOOL_H__
26 
27 
28 #include "scip/def.h"
29 #include "blockmemshell/memory.h"
30 #include "scip/type_retcode.h"
31 #include "scip/type_result.h"
32 #include "scip/type_set.h"
33 #include "scip/type_stat.h"
34 #include "scip/type_lp.h"
35 #include "scip/type_sepastore.h"
36 #include "scip/type_cutpool.h"
37 #include "scip/pub_cutpool.h"
38 
39 #ifdef __cplusplus
40 extern "C" {
41 #endif
42 
43 /** creates cut pool */
44 extern
46  SCIP_CUTPOOL** cutpool, /**< pointer to store cut pool */
47  BMS_BLKMEM* blkmem, /**< block memory */
48  SCIP_SET* set, /**< global SCIP settings */
49  int agelimit, /**< maximum age a cut can reach before it is deleted from the pool */
50  SCIP_Bool globalcutpool /**< is this the global cut pool of SCIP? */
51  );
52 
53 /** frees cut pool */
54 extern
56  SCIP_CUTPOOL** cutpool, /**< pointer to store cut pool */
57  BMS_BLKMEM* blkmem, /**< block memory */
58  SCIP_SET* set, /**< global SCIP settings */
59  SCIP_LP* lp /**< current LP data */
60  );
61 
62 /** removes all rows from the cut pool */
63 extern
65  SCIP_CUTPOOL* cutpool, /**< cut pool */
66  BMS_BLKMEM* blkmem, /**< block memory */
67  SCIP_SET* set, /**< global SCIP settings */
68  SCIP_LP* lp /**< current LP data */
69  );
70 
71 /** checks if cut is already existing */
72 extern
74  SCIP_CUTPOOL* cutpool, /**< cut pool */
75  SCIP_SET* set, /**< global SCIP settings */
76  SCIP_ROW* row /**< cutting plane to add */
77  );
78 
79 /** if not already existing, adds row to cut pool and captures it */
80 extern
82  SCIP_CUTPOOL* cutpool, /**< cut pool */
83  BMS_BLKMEM* blkmem, /**< block memory */
84  SCIP_SET* set, /**< global SCIP settings */
85  SCIP_STAT* stat, /**< problem statistics data */
86  SCIP_LP* lp, /**< current LP data */
87  SCIP_ROW* row /**< cutting plane to add */
88  );
89 
90 /** adds row to cut pool and captures it; doesn't check for multiple cuts */
91 extern
93  SCIP_CUTPOOL* cutpool, /**< cut pool */
94  BMS_BLKMEM* blkmem, /**< block memory */
95  SCIP_SET* set, /**< global SCIP settings */
96  SCIP_STAT* stat, /**< problem statistics data */
97  SCIP_LP* lp, /**< current LP data */
98  SCIP_ROW* row /**< cutting plane to add */
99  );
100 
101 /** removes the LP row from the cut pool */
102 extern
104  SCIP_CUTPOOL* cutpool, /**< cut pool */
105  BMS_BLKMEM* blkmem, /**< block memory */
106  SCIP_SET* set, /**< global SCIP settings */
107  SCIP_STAT* stat, /**< problem statistics data */
108  SCIP_LP* lp, /**< current LP data */
109  SCIP_ROW* row /**< row to remove */
110  );
111 
112 /** separates cuts of the cut pool */
113 extern
115  SCIP_CUTPOOL* cutpool, /**< cut pool */
116  BMS_BLKMEM* blkmem, /**< block memory */
117  SCIP_SET* set, /**< global SCIP settings */
118  SCIP_STAT* stat, /**< problem statistics data */
119  SCIP_EVENTQUEUE* eventqueue, /**< event queue */
120  SCIP_EVENTFILTER* eventfilter, /**< event filter for global events */
121  SCIP_LP* lp, /**< current LP data */
122  SCIP_SEPASTORE* sepastore, /**< separation storage */
123  SCIP_SOL* sol, /**< solution to be separated (or NULL for LP-solution) */
124  SCIP_Bool cutpoolisdelayed, /**< is the cutpool delayed (count cuts found)? */
125  SCIP_Bool root, /**< are we at the root node? */
126  SCIP_RESULT* result /**< pointer to store the result of the separation call */
127  );
128 
129 #ifdef __cplusplus
130 }
131 #endif
132 
133 #endif
enum SCIP_Result SCIP_RESULT
Definition: type_result.h:52
SCIP_RETCODE SCIPcutpoolClear(SCIP_CUTPOOL *cutpool, BMS_BLKMEM *blkmem, SCIP_SET *set, SCIP_LP *lp)
Definition: cutpool.c:482
SCIP_RETCODE SCIPcutpoolCreate(SCIP_CUTPOOL **cutpool, BMS_BLKMEM *blkmem, SCIP_SET *set, int agelimit, SCIP_Bool globalcutpool)
Definition: cutpool.c:417
enum SCIP_Retcode SCIP_RETCODE
Definition: type_retcode.h:53
type definitions for global SCIP settings
type definitions for return codes for SCIP methods
SCIP_RETCODE SCIPcutpoolDelRow(SCIP_CUTPOOL *cutpool, BMS_BLKMEM *blkmem, SCIP_SET *set, SCIP_STAT *stat, SCIP_LP *lp, SCIP_ROW *row)
Definition: cutpool.c:785
type definitions for problem statistics
type definitions for LP management
type definitions for storing cuts in a cut pool
type definitions for storing separated cuts
SCIP_Bool SCIPcutpoolIsCutNew(SCIP_CUTPOOL *cutpool, SCIP_SET *set, SCIP_ROW *row)
Definition: cutpool.c:583
#define SCIP_Bool
Definition: def.h:61
public methods for storing cuts in a cut pool
SCIP_RETCODE SCIPcutpoolAddRow(SCIP_CUTPOOL *cutpool, BMS_BLKMEM *blkmem, SCIP_SET *set, SCIP_STAT *stat, SCIP_LP *lp, SCIP_ROW *row)
Definition: cutpool.c:646
result codes for SCIP callback methods
SCIP_RETCODE SCIPcutpoolFree(SCIP_CUTPOOL **cutpool, BMS_BLKMEM *blkmem, SCIP_SET *set, SCIP_LP *lp)
Definition: cutpool.c:456
SCIP_RETCODE SCIPcutpoolSeparate(SCIP_CUTPOOL *cutpool, BMS_BLKMEM *blkmem, SCIP_SET *set, SCIP_STAT *stat, SCIP_EVENTQUEUE *eventqueue, SCIP_EVENTFILTER *eventfilter, SCIP_LP *lp, SCIP_SEPASTORE *sepastore, SCIP_SOL *sol, SCIP_Bool cutpoolisdelayed, SCIP_Bool root, SCIP_RESULT *result)
Definition: cutpool.c:814
common defines and data types used in all packages of SCIP
struct BMS_BlkMem BMS_BLKMEM
Definition: memory.h:419
SCIP_RETCODE SCIPcutpoolAddNewRow(SCIP_CUTPOOL *cutpool, BMS_BLKMEM *blkmem, SCIP_SET *set, SCIP_STAT *stat, SCIP_LP *lp, SCIP_ROW *row)
Definition: cutpool.c:716
memory allocation routines