Scippy

SCIP

Solving Constraint Integer Programs

struct_nodesel.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 visit scip.zib.de. */
13 /* */
14 /* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
15 
16 /**@file struct_nodesel.h
17  * @ingroup INTERNALAPI
18  * @brief data structures for node selectors and node priority queues
19  * @author Tobias Achterberg
20  */
21 
22 /*---+----1----+----2----+----3----+----4----+----5----+----6----+----7----+----8----+----9----+----0----+----1----+----2*/
23 
24 #ifndef __SCIP_STRUCT_NODESEL_H__
25 #define __SCIP_STRUCT_NODESEL_H__
26 
27 
28 #include "scip/def.h"
29 #include "scip/type_tree.h"
30 #include "scip/type_nodesel.h"
31 
32 #ifdef __cplusplus
33 extern "C" {
34 #endif
35 
36 /** node priority queue data structure;
37  * the fields lowerboundnode, lowerbound, nlowerbounds and validlowerbound are only used for node selection rules,
38  * that don't store the lowest bound node in the first slot of the queue
39  */
41 {
42  SCIP_Real lowerboundsum; /**< sum of lower bounds of all nodes in the queue */
43  SCIP_NODESEL* nodesel; /**< node selector used for sorting the nodes in the queue */
44  SCIP_NODE** slots; /**< array of element slots */
45  int* bfsposs; /**< position of the slot in the bfs ordered queue */
46  int* bfsqueue; /**< queue of slots[] indices sorted by best lower bound */
47  int len; /**< number of used element slots */
48  int size; /**< total number of available element slots */
49 };
50 
51 /** node selector */
53 {
54  char* name; /**< name of node selector */
55  char* desc; /**< description of node selector */
56  SCIP_DECL_NODESELCOPY ((*nodeselcopy)); /**< copy method of node selector or NULL if you don't want to copy your plugin into sub-SCIPs */
57  SCIP_DECL_NODESELFREE ((*nodeselfree)); /**< destructor of node selector */
58  SCIP_DECL_NODESELINIT ((*nodeselinit)); /**< initialize node selector */
59  SCIP_DECL_NODESELEXIT ((*nodeselexit)); /**< deinitialize node selector */
60  SCIP_DECL_NODESELINITSOL((*nodeselinitsol));/**< solving process initialization method of node selector */
61  SCIP_DECL_NODESELEXITSOL((*nodeselexitsol));/**< solving process deinitialization method of node selector */
62  SCIP_DECL_NODESELSELECT((*nodeselselect));/**< node selection method */
63  SCIP_DECL_NODESELCOMP ((*nodeselcomp)); /**< node comparison method */
64  SCIP_CLOCK* setuptime; /**< time spend for setting up this node selector for the next stages */
65  SCIP_CLOCK* nodeseltime; /**< node selector execution time */
66  SCIP_NODESELDATA* nodeseldata; /**< node selector data */
67  int stdpriority; /**< priority of the node selector in standard mode */
68  int memsavepriority; /**< priority of the node selector in memory saving mode */
69  SCIP_Bool initialized; /**< is node selector initialized? */
70 };
71 
72 #ifdef __cplusplus
73 }
74 #endif
75 
76 #endif
#define SCIP_DECL_NODESELCOMP(x)
Definition: type_nodesel.h:126
SCIP_Real lowerboundsum
#define SCIP_DECL_NODESELINITSOL(x)
Definition: type_nodesel.h:83
SCIP_Bool initialized
#define SCIP_DECL_NODESELEXITSOL(x)
Definition: type_nodesel.h:94
SCIP_CLOCK * setuptime
#define SCIP_DECL_NODESELINIT(x)
Definition: type_nodesel.h:64
struct SCIP_NodeselData SCIP_NODESELDATA
Definition: type_nodesel.h:38
SCIP_NODE ** slots
SCIP_CLOCK * nodeseltime
#define SCIP_DECL_NODESELFREE(x)
Definition: type_nodesel.h:56
#define SCIP_Bool
Definition: def.h:62
#define SCIP_DECL_NODESELEXIT(x)
Definition: type_nodesel.h:72
type definitions for branch and bound tree
SCIP_NODESELDATA * nodeseldata
#define SCIP_Real
Definition: def.h:150
#define SCIP_DECL_NODESELCOPY(x)
Definition: type_nodesel.h:47
common defines and data types used in all packages of SCIP
SCIP_NODESEL * nodesel
type definitions for node selectors
#define SCIP_DECL_NODESELSELECT(x)
Definition: type_nodesel.h:109