Scippy

SCIP

Solving Constraint Integer Programs

struct_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-2024 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 struct_relax.h
26  * @ingroup INTERNALAPI
27  * @brief data structures for relaxators
28  * @author Tobias Achterberg
29  */
30 
31 /*---+----1----+----2----+----3----+----4----+----5----+----6----+----7----+----8----+----9----+----0----+----1----+----2*/
32 
33 #ifndef __SCIP_STRUCT_RELAX_H__
34 #define __SCIP_STRUCT_RELAX_H__
35 
36 
37 #include "scip/def.h"
38 #include "scip/type_clock.h"
39 #include "scip/type_relax.h"
40 
41 #ifdef __cplusplus
42 extern "C" {
43 #endif
44 
45 /** relaxators data */
46 struct SCIP_Relax
47 {
48  SCIP_Longint ncalls; /**< number of times, this relaxator was called */
49  SCIP_Longint ncutoffs; /**< number of times, this relaxator cut off a node */
50  SCIP_Longint nimprbounds; /**< number of times, this relaxator improves the node's lower bound (w.r.t. SCIPisRelGT) */
51  SCIP_Longint naddedconss; /**< number of times, this relaxator added constraints */
52  SCIP_Longint nreduceddom; /**< number of times, this relaxator reduced variable domains */
53  SCIP_Longint nseparated; /**< number of times, this relaxator separated cuts */
54  SCIP_Longint lastsolvednode; /**< last total nodes counter, where the current relaxation was solved */
55  char* name; /**< name of relaxator */
56  char* desc; /**< description of relaxator */
57  SCIP_DECL_RELAXCOPY ((*relaxcopy)); /**< copy method of relaxator or NULL if you don't want to copy your plugin into sub-SCIPs */
58  SCIP_DECL_RELAXFREE ((*relaxfree)); /**< destructor of relaxator */
59  SCIP_DECL_RELAXINIT ((*relaxinit)); /**< initialize relaxator */
60  SCIP_DECL_RELAXEXIT ((*relaxexit)); /**< deinitialize relaxator */
61  SCIP_DECL_RELAXINITSOL((*relaxinitsol)); /**< solving process initialization method of relaxator */
62  SCIP_DECL_RELAXEXITSOL((*relaxexitsol)); /**< solving process deinitialization method of relaxator */
63  SCIP_DECL_RELAXEXEC ((*relaxexec)); /**< execution method of relaxator */
64  SCIP_RELAXDATA* relaxdata; /**< relaxators local data */
65  SCIP_CLOCK* setuptime; /**< time spent for setting up this relaxator for the next stages */
66  SCIP_CLOCK* relaxclock; /**< relaxation time */
67  SCIP_Real imprtime; /**< time spent for executing relaxator when improving bound (or cutoff) */
68  int priority; /**< priority of the relaxator */
69  int freq; /**< frequency for calling relaxator */
70  SCIP_Bool initialized; /**< is relaxator initialized? */
71 };
72 
73 /** relaxation information data */
75 {
80  SCIP_RELAX* lastsolrelax; /**< relaxator of the most recent relaxation solution */
81 };
82 
83 
84 #ifdef __cplusplus
85 }
86 #endif
87 
88 #endif
SCIP_DECL_RELAXEXITSOL((*relaxexitsol))
char * desc
Definition: struct_relax.h:56
SCIP_DECL_RELAXCOPY((*relaxcopy))
SCIP_Longint ncutoffs
Definition: struct_relax.h:49
SCIP_RELAX * lastsolrelax
Definition: struct_relax.h:80
SCIP_DECL_RELAXINIT((*relaxinit))
SCIP_DECL_RELAXEXEC((*relaxexec))
SCIP_DECL_RELAXFREE((*relaxfree))
SCIP_RELAXDATA * relaxdata
Definition: struct_relax.h:64
SCIP_CLOCK * relaxclock
Definition: struct_relax.h:66
SCIP_Longint naddedconss
Definition: struct_relax.h:51
SCIP_Bool relaxsolincludeslp
Definition: struct_relax.h:78
SCIP_Real relaxsolobjval
Definition: struct_relax.h:76
SCIP_Bool relaxsolvalid
Definition: struct_relax.h:77
SCIP_Longint nimprbounds
Definition: struct_relax.h:50
SCIP_CLOCK * setuptime
Definition: struct_relax.h:65
type definitions for relaxators
char * name
Definition: struct_relax.h:55
#define SCIP_Bool
Definition: def.h:91
SCIP_Bool initialized
Definition: struct_relax.h:70
SCIP_Longint lastsolvednode
Definition: struct_relax.h:54
type definitions for clocks and timing issues
SCIP_Longint ncalls
Definition: struct_relax.h:48
SCIP_Real imprtime
Definition: struct_relax.h:67
struct SCIP_RelaxData SCIP_RELAXDATA
Definition: type_relax.h:47
SCIP_DECL_RELAXEXIT((*relaxexit))
SCIP_Bool relaxsolzero
Definition: struct_relax.h:79
SCIP_Longint nreduceddom
Definition: struct_relax.h:52
#define SCIP_Real
Definition: def.h:173
#define SCIP_Longint
Definition: def.h:158
SCIP_DECL_RELAXINITSOL((*relaxinitsol))
common defines and data types used in all packages of SCIP
SCIP_Longint nseparated
Definition: struct_relax.h:53