Open
Graph Drawing
Framework

 v. 2023.09 (Elderberry)
 

Loading...
Searching...
No Matches
fixcand.h
Go to the documentation of this file.
1
30#pragma once
31
33
34
35namespace abacus {
36
37class Master;
38class Sub;
39class FSVarStat;
40class Variable;
41class Constraint;
42
43template<class BaseType, class CoType> class CutBuffer;
44template<class BaseType, class CoType> class PoolSlotRef;
45
46
48
64
65 friend class Sub;
66 friend class Master;
67
68public:
69
71
74 FixCand(Master *master) :
75 master_(master),
76 candidates_(nullptr),
77 fsVarStat_(nullptr),
78 lhs_(nullptr)
79 { }
80
82 ~FixCand() { deleteAll(); }
83
84private:
85
87
90 void saveCandidates(Sub *sub);
91
93
107
109
112 void deleteAll();
113
115 void allocate(int nCand);
116
117
119
121
123
125
126 FixCand(const FixCand &rhs);
127 const FixCand &operator=(const FixCand &rhs);
128};
129
130}
Base class of all other classes of ABACUS.
Definition abacusroot.h:68
Cut buffers.
Definition cutbuffer.h:52
Candidates for fixing.
Definition fixcand.h:63
~FixCand()
The destructor.
Definition fixcand.h:82
const FixCand & operator=(const FixCand &rhs)
FixCand(const FixCand &rhs)
void saveCandidates(Sub *sub)
Memorizes suitable variables for fixing.
void fixByRedCost(CutBuffer< Variable, Constraint > *addVarBuffer)
Tries to fix as many candidates as possible.
ArrayBuffer< PoolSlotRef< Variable, Constraint > * > * candidates_
The candidates for fixing.
Definition fixcand.h:120
void deleteAll()
Deletes all allocated memory of members.
ArrayBuffer< double > * lhs_
The left hand side of the expression evaluated for fixing.
Definition fixcand.h:124
FixCand(Master *master)
Creates an empty set of candidates for fixing.
Definition fixcand.h:74
Master * master_
A pointer to the corresponding master of the optimization.
Definition fixcand.h:118
ArrayBuffer< FSVarStat * > * fsVarStat_
The fixing status of the candidates.
Definition fixcand.h:122
void allocate(int nCand)
Allocates memory to store nCand candidates for fixing.
The master of the optimization.
Definition master.h:69
The subproblem.
Definition sub.h:68
An array that keeps track of the number of inserted elements; also usable as an efficient stack.
Definition ArrayBuffer.h:56
#define OGDF_EXPORT
Specifies that a function or class is exported by the OGDF DLL.
Definition config.h:101
static MultilevelBuilder * getDoubleFactoredZeroAdjustedMerger()