Scippy

SCIP

Solving Constraint Integer Programs

pub_relax.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-2023 Zuse Institute Berlin (ZIB) */
7 /* */
8 /* Licensed under the Apache License, Version 2.0 (the "License"); */
9 /* you may not use this file except in compliance with the License. */
10 /* You may obtain a copy of the License at */
11 /* */
12 /* http://www.apache.org/licenses/LICENSE-2.0 */
13 /* */
14 /* Unless required by applicable law or agreed to in writing, software */
15 /* distributed under the License is distributed on an "AS IS" BASIS, */
16 /* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. */
17 /* See the License for the specific language governing permissions and */
18 /* limitations under the License. */
19 /* */
20 /* You should have received a copy of the Apache-2.0 license */
21 /* along with SCIP; see the file LICENSE. If not visit scipopt.org. */
22 /* */
23 /* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
24 
25 /**@file pub_relax.h
26  * @ingroup PUBLICCOREAPI
27  * @brief public methods for relaxation handlers
28  * @author Tobias Achterberg
29  */
30 
31 /*---+----1----+----2----+----3----+----4----+----5----+----6----+----7----+----8----+----9----+----0----+----1----+----2*/
32 
33 #ifndef __SCIP_PUB_RELAX_H__
34 #define __SCIP_PUB_RELAX_H__
35 
36 
37 #include "scip/def.h"
38 #include "scip/type_misc.h"
39 #include "scip/type_relax.h"
40 
41 #ifdef __cplusplus
42 extern "C" {
43 #endif
44 
45 
46 /**@addtogroup PublicRelaxatorMethods
47  *
48  * @{
49  */
50 
51 
52 /** compares two relaxation handlers w. r. to their priority */
53 SCIP_EXPORT
54 SCIP_DECL_SORTPTRCOMP(SCIPrelaxComp);
55 
56 /** comparison method for sorting relaxators w.r.t. to their name */
57 SCIP_EXPORT
58 SCIP_DECL_SORTPTRCOMP(SCIPrelaxCompName);
59 
60 /** gets user data of relaxation handler */
61 SCIP_EXPORT
63  SCIP_RELAX* relax /**< relaxation handler */
64  );
65 
66 /** sets user data of relaxation handler; user has to free old data in advance! */
67 SCIP_EXPORT
68 void SCIPrelaxSetData(
69  SCIP_RELAX* relax, /**< relaxation handler */
70  SCIP_RELAXDATA* relaxdata /**< new relaxation handler user data */
71  );
72 
73 /** gets name of relaxation handler */
74 SCIP_EXPORT
75 const char* SCIPrelaxGetName(
76  SCIP_RELAX* relax /**< relaxation handler */
77  );
78 
79 /** gets description of relaxation handler */
80 SCIP_EXPORT
81 const char* SCIPrelaxGetDesc(
82  SCIP_RELAX* relax /**< relaxation handler */
83  );
84 
85 /** gets priority of relaxation handler */
86 SCIP_EXPORT
88  SCIP_RELAX* relax /**< relaxation handler */
89  );
90 
91 /** gets frequency of relaxation handler */
92 SCIP_EXPORT
94  SCIP_RELAX* relax /**< relaxation handler */
95  );
96 
97 /** gets time in seconds used in this relaxator for setting up for next stages */
98 SCIP_EXPORT
100  SCIP_RELAX* relax /**< relaxator */
101  );
102 
103 /** gets time in seconds used in this relaxation handler */
104 SCIP_EXPORT
106  SCIP_RELAX* relax /**< relaxation handler */
107  );
108 
109 /** gets the total number of times the relaxation handler was called */
110 SCIP_EXPORT
112  SCIP_RELAX* relax /**< relaxation handler */
113  );
114 
115 /** gets the total number of times the relaxation handler cut off a node */
116 SCIP_EXPORT
118  SCIP_RELAX* relax /**< relaxation handler */
119  );
120 
121 /** gets the total number of times the relaxation handler improved a node's lower bound */
122 SCIP_EXPORT
124  SCIP_RELAX* relax /**< relaxation handler */
125  );
126 
127 /** gets the time in seconds spent for the execution of the relaxation handler when a node's lower bound could be improved (or a cutoff was found) */
128 SCIP_EXPORT
130  SCIP_RELAX* relax /**< relaxation handler */
131  );
132 
133 /** gets the total number of times the relaxation handler added constraints */
134 SCIP_EXPORT
136  SCIP_RELAX* relax /**< relaxation handler */
137  );
138 
139 /** gets the total number of times the relaxation handler reduced variable domains */
140 SCIP_EXPORT
142  SCIP_RELAX* relax /**< relaxation handler */
143  );
144 
145 /** gets the total number of times the relaxation handler separated cutting planes */
146 SCIP_EXPORT
148  SCIP_RELAX* relax /**< relaxation handler */
149  );
150 
151 /** is relaxation handler initialized? */
152 SCIP_EXPORT
154  SCIP_RELAX* relax /**< relaxation handler */
155  );
156 
157 /** marks the current relaxation unsolved, s.t. the relaxation handler is called again in the next solving round */
158 SCIP_EXPORT
160  SCIP_RELAX* relax /**< relaxation handler */
161  );
162 
163 /** @} */
164 
165 #ifdef __cplusplus
166 }
167 #endif
168 
169 #endif
SCIP_DECL_SORTPTRCOMP(SCIPrelaxComp)
Definition: relax.c:56
type definitions for miscellaneous datastructures
SCIP_Longint SCIPrelaxGetNImprovedLowerbound(SCIP_RELAX *relax)
Definition: relax.c:648
SCIP_Longint SCIPrelaxGetNCalls(SCIP_RELAX *relax)
Definition: relax.c:628
SCIP_Real SCIPrelaxGetTime(SCIP_RELAX *relax)
Definition: relax.c:618
SCIP_Real SCIPrelaxGetImprovedLowerboundTime(SCIP_RELAX *relax)
Definition: relax.c:668
int SCIPrelaxGetPriority(SCIP_RELAX *relax)
Definition: relax.c:562
SCIP_Longint SCIPrelaxGetNReducedDomains(SCIP_RELAX *relax)
Definition: relax.c:678
const char * SCIPrelaxGetName(SCIP_RELAX *relax)
Definition: relax.c:542
SCIP_RELAXDATA * SCIPrelaxGetData(SCIP_RELAX *relax)
Definition: relax.c:455
void SCIPrelaxMarkUnsolved(SCIP_RELAX *relax)
Definition: relax.c:720
type definitions for relaxators
int SCIPrelaxGetFreq(SCIP_RELAX *relax)
Definition: relax.c:586
SCIP_Real SCIPrelaxGetSetupTime(SCIP_RELAX *relax)
Definition: relax.c:596
#define SCIP_Bool
Definition: def.h:93
const char * SCIPrelaxGetDesc(SCIP_RELAX *relax)
Definition: relax.c:552
void SCIPrelaxSetData(SCIP_RELAX *relax, SCIP_RELAXDATA *relaxdata)
Definition: relax.c:465
struct SCIP_RelaxData SCIP_RELAXDATA
Definition: type_relax.h:47
SCIP_Longint SCIPrelaxGetNSeparatedCuts(SCIP_RELAX *relax)
Definition: relax.c:688
SCIP_Bool SCIPrelaxIsInitialized(SCIP_RELAX *relax)
Definition: relax.c:698
#define SCIP_Real
Definition: def.h:186
SCIP_Longint SCIPrelaxGetNCutoffs(SCIP_RELAX *relax)
Definition: relax.c:638
#define SCIP_Longint
Definition: def.h:171
SCIP_Longint SCIPrelaxGetNAddedConss(SCIP_RELAX *relax)
Definition: relax.c:658
common defines and data types used in all packages of SCIP