Clp 1.17.6

- Main Page
- Related Pages
- Modules
- Namespaces
- Classes
- Files

- File List
- File Members

All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
AbcWarmStart.hpp
Go to the documentation of this file.
1 /* $Id: AbcWarmStart.hpp 2385 2019-01-06 19:43:06Z unxusr $ */
8 #ifndef AbcWarmStart_H
9 #define AbcWarmStart_H
10 #include "AbcCommon.hpp"
11 #include "CoinWarmStartBasis.hpp"
12 // could test using ClpSimplex (or for fans)
13 #define CLP_WARMSTART
14 #ifdef CLP_WARMSTART
15 #include "ClpSimplex.hpp"
16 #define AbcSimplex ClpSimplex
17 #else
18 #include "AbcSimplex.hpp"
19 #endif
20 class AbcWarmStart;
21 //#############################################################################
22 class AbcWarmStartOrganizer {
23 public:
25 void createBasis0();
27 void createBasis12();
29 void createBasis34();
31 void deleteBasis(AbcWarmStart *basis);
35
40 AbcWarmStartOrganizer(AbcSimplex *model = NULL);
41
43 AbcWarmStartOrganizer(const AbcWarmStartOrganizer &ws);
44
46 virtual ~AbcWarmStartOrganizer();
47
50 virtual AbcWarmStartOrganizer &operator=(const AbcWarmStartOrganizer &rhs);
52
53 protected:
56 AbcSimplex *model_;
59 AbcWarmStart *firstBasis_;
61 AbcWarmStart *lastBasis_;
63 int numberBases_;
65 int sizeBases_;
67 };
68
74 class AbcWarmStart : public virtual CoinWarmStartBasis {
75 public:
78
84 virtual void setSize(int ns, int na);
85
94 virtual void resize(int newNumberRows, int newNumberColumns);
95
112 virtual void compressRows(int tgtCnt, const int *tgts);
113
125 virtual void deleteRows(int rawTgtCnt, const int *rawTgts);
126
137 virtual void deleteColumns(int number, const int *which);
139 inline void setModel(AbcSimplex *model)
140 {
141 model_ = model;
142 }
144 inline AbcSimplex *model() const
145 {
146 return model_;
147 }
149 void createBasis0(const AbcSimplex *model);
151 void createBasis12(const AbcSimplex *model);
153 void createBasis34(const AbcSimplex *model);
157
163 AbcWarmStart();
164
174 AbcWarmStart(AbcSimplex *model, int type);
175
177 AbcWarmStart(const AbcWarmStart &ws);
178
180 virtual CoinWarmStart *clone() const
181 {
182 return new AbcWarmStart(*this);
183 }
184
186 virtual ~AbcWarmStart();
187
190 virtual AbcWarmStart &operator=(const AbcWarmStart &rhs);
191
207 virtual void assignBasisStatus(int ns, int na, char *&sStat, char *&aStat);
209
210 protected:
221 int typeExtraInformation_;
223 int lengthExtraInformation_;
225 char *extraInformation_;
227 AbcSimplex *model_;
229 AbcWarmStartOrganizer *organizer_;
231 AbcWarmStart *previousBasis_;
233 AbcWarmStart *nextBasis_;
235 int stamp_;
240 int numberValidRows_;
242 };
243 #endif
244
245 /* vi: softtabstop=2 shiftwidth=2 expandtab tabstop=2
246 */
AbcWarmStart::setModel
void setModel(AbcSimplex *model)
Set model.
Definition: AbcWarmStart.hpp:139
ClpSimplex.hpp
AbcWarmStartOrganizer::firstBasis_
AbcWarmStart * firstBasis_
Pointer to first basis.
Definition: AbcWarmStart.hpp:59
AbcSimplex
Definition: AbcSimplex.hpp:62
AbcWarmStartOrganizer::operator=
virtual AbcWarmStartOrganizer & operator=(const AbcWarmStartOrganizer &rhs)
Assignment.
AbcWarmStart::model
AbcSimplex * model() const
Get model.
Definition: AbcWarmStart.hpp:144
AbcWarmStart::compressRows
virtual void compressRows(int tgtCnt, const int *tgts)
Delete a set of rows from the basis.
AbcWarmStartOrganizer::createBasis12
void createBasis12()
Create Basis type 1,2.
AbcWarmStart::assignBasisStatus
virtual void assignBasisStatus(int ns, int na, char *&sStat, char *&aStat)
Assign the status vectors to be the warm start information.
AbcWarmStart::deleteRows
virtual void deleteRows(int rawTgtCnt, const int *rawTgts)
Delete a set of rows from the basis.
AbcWarmStart::resize
virtual void resize(int newNumberRows, int newNumberColumns)
Set basis capacity; existing basis is maintained.
CoinWarmStartBasis
The default COIN simplex (basis-oriented) warm start class.
Definition: CoinWarmStartBasis.hpp:40
AbcWarmStartOrganizer::numberBases_
int numberBases_
Number of bases.
Definition: AbcWarmStart.hpp:63
AbcSimplex.hpp
AbcWarmStartOrganizer::createBasis0
void createBasis0()
Create Basis type 0.
AbcWarmStart::previousBasis_
AbcWarmStart * previousBasis_
Pointer to previous basis.
Definition: AbcWarmStart.hpp:231
AbcWarmStart::typeExtraInformation_
int typeExtraInformation_
Type of basis (always status arrays) 0 - as CoinWarmStartBasis 1,2 - plus factor order as shorts or ...
Definition: AbcWarmStart.hpp:221
AbcCommon.hpp
AbcWarmStart::extraInformation_
char * extraInformation_
The extra information.
Definition: AbcWarmStart.hpp:225
AbcWarmStartOrganizer::model_
AbcSimplex * model_
Pointer to AbcSimplex (can only be applied to that)
Definition: AbcWarmStart.hpp:57
AbcWarmStart::createBasis12
void createBasis12(const AbcSimplex *model)
Create Basis type 12.
AbcWarmStartOrganizer::~AbcWarmStartOrganizer
virtual ~AbcWarmStartOrganizer()
Destructor.
AbcWarmStart::stamp_
int stamp_
Sequence stamp for deletion.
Definition: AbcWarmStart.hpp:235
AbcWarmStart::setSize
virtual void setSize(int ns, int na)
Set basis capacity; existing basis is discarded.
AbcWarmStartOrganizer::lastBasis_
AbcWarmStart * lastBasis_
Pointer to last basis.
Definition: AbcWarmStart.hpp:61
AbcWarmStart::operator=
virtual AbcWarmStart & operator=(const AbcWarmStart &rhs)
Assignment.
AbcWarmStart::numberValidRows_
int numberValidRows_
Number of valid rows (rest should have slacks) Check to see if weights are OK for these rows and then...
Definition: AbcWarmStart.hpp:240
AbcWarmStartOrganizer::sizeBases_
int sizeBases_
Size of bases (extra)
Definition: AbcWarmStart.hpp:65
AbcWarmStart::nextBasis_
AbcWarmStart * nextBasis_
Pointer to next basis.
Definition: AbcWarmStart.hpp:233
AbcWarmStart::createBasis0
void createBasis0(const AbcSimplex *model)
Create Basis type 0.
AbcWarmStart::~AbcWarmStart
virtual ~AbcWarmStart()
Destructor.
AbcWarmStart
As CoinWarmStartBasis but with alternatives (Also uses Clp status meaning for slacks) ...
Definition: AbcWarmStart.hpp:74
AbcWarmStart::model_
AbcSimplex * model_
Pointer back to AbcSimplex (can only be applied to that)
Definition: AbcWarmStart.hpp:227
AbcWarmStart::clone
virtual CoinWarmStart * clone() const
`Virtual constructor&#39;
Definition: AbcWarmStart.hpp:180
AbcWarmStart::deleteColumns
virtual void deleteColumns(int number, const int *which)
Delete a set of columns from the basis.
CoinWarmStartBasis.hpp
AbcWarmStartOrganizer::createBasis34
void createBasis34()
Create Basis type 3,4.
AbcWarmStartOrganizer
Definition: AbcWarmStart.hpp:22
AbcWarmStartOrganizer::AbcWarmStartOrganizer
AbcWarmStartOrganizer(AbcSimplex *model=NULL)
Default constructor.
CoinWarmStart
Abstract base class for warm start information.
Definition: CoinWarmStart.hpp:21
AbcWarmStart::createBasis34
void createBasis34(const AbcSimplex *model)
Create Basis type 34.
AbcWarmStartOrganizer::deleteBasis
void deleteBasis(AbcWarmStart *basis)
delete basis
AbcWarmStart::AbcWarmStart
AbcWarmStart()
Default constructor.
AbcWarmStart::lengthExtraInformation_
int lengthExtraInformation_
Length of extra information in bytes.
Definition: AbcWarmStart.hpp:223
AbcWarmStart::organizer_
AbcWarmStartOrganizer * organizer_
Pointer back to AbcWarmStartOrganizer for organization.
Definition: AbcWarmStart.hpp:229