Minotaur 0.4.1
Docs for developers
LinMods.h
Go to the documentation of this file.
1//
2// Minotaur -- It's only 1/2 bull
3//
4// (C)opyright 2009 - 2025 The Minotaur Team.
5//
6
14#ifndef MINOTAURLINMODS_H
15#define MINOTAURLINMODS_H
16
17#include "LinConMod.h"
18#include "VarBoundMod.h"
19
20namespace Minotaur {
21
22class LinMods;
23typedef LinMods* LinModsPtr;
24typedef const LinMods* ConstLinModsPtr;
25
30class LinMods : public Modification {
31 public:
33 LinMods();
34
36 ~LinMods();
37
39 void applyToProblem(ProblemPtr problem);
40
41 // base class method.
43
45 void insert(VarBoundModPtr bmod);
46
48 void insert(VarBoundMod2Ptr b2mod);
49
51 void insert(LinConModPtr lmod);
52
57 bool isEmpty() const;
58
59 // base class method.
61
63 void undoToProblem(ProblemPtr problem);
64
66 void write(std::ostream&) const;
67
68 private:
70 std::vector<VarBoundModPtr> bmods_;
71
73 std::vector<VarBoundMod2Ptr> bmods2_;
74
76 std::vector<LinConModPtr> lmods_;
77};
78} // namespace Minotaur
79#endif
80
Declare the class LinConMod. It is used to save modifications in the linear functions of constraints.
Declare the class VarBoundMod. It is used to save modifications in a bound of a variable....
Definition: LinConMod.h:37
Definition: LinMods.h:30
void applyToProblem(ProblemPtr problem)
Apply it to the problem.
Definition: LinMods.cpp:58
ModificationPtr toRel(ProblemPtr, RelaxationPtr) const
Covert a modification for a problem to one for its relaxation.
Definition: LinMods.cpp:138
bool isEmpty() const
Definition: LinMods.cpp:105
void insert(VarBoundModPtr bmod)
Insert a new VarBoundMod.
Definition: LinMods.cpp:90
void undoToProblem(ProblemPtr problem)
Restore the modification for a problem.
Definition: LinMods.cpp:74
~LinMods()
Destroy.
Definition: LinMods.cpp:30
ModificationPtr fromRel(RelaxationPtr, ProblemPtr) const
Covert a modification for a relaxation to one for its original problem.
Definition: LinMods.cpp:110
LinMods()
Constructor.
Definition: LinMods.cpp:23
void write(std::ostream &) const
Write it to 'out'.
Definition: LinMods.cpp:166
Definition: Modification.h:29
Definition: Problem.h:74
Definition: Relaxation.h:53
Modification of a both bounds on a variable.
Definition: VarBoundMod.h:84
Modification of a single bound on a variable.
Definition: VarBoundMod.h:30
Definition: ActiveNodeStore.h:20

Minotaur source code documented by Doxygen 1.9.4 on Thu Apr 24 2025