13 #ifndef CoinWarmStartBasis_H
14 #define CoinWarmStartBasis_H
108 st_byte =
static_cast< char >(st_byte & ~(3 << ((i & 3) << 1)));
109 st_byte =
static_cast< char >(st_byte | (st << ((i & 3) << 1)));
142 st_byte =
static_cast< char >(st_byte & ~(3 << ((i & 3) << 1)));
143 st_byte =
static_cast< char >(st_byte | (st << ((i & 3) << 1)));
186 virtual void setSize(
int ns,
int na);
196 virtual void resize(
int newNumberRows,
int newNumberColumns);
227 virtual void deleteRows(
int rawTgtCnt,
const int *rawTgts);
319 virtual void print()
const;
353 const int st = (array[i >> 2] >> ((i & 3) << 1)) & 3;
363 char &st_byte = array[i >> 2];
364 st_byte =
static_cast< char >(st_byte & ~(3 << ((i & 3) << 1)));
365 st_byte =
static_cast< char >(st_byte | (st << ((i & 3) << 1)));
410 return (dynamic_cast< CoinWarmStartDiff * >(cwsbd));
446 const unsigned int *
const diffVals);
char * structuralStatus_
The status of the structural variables.
virtual void setSize(int ns, int na)
Set basis capacity; existing basis is discarded.
const char * statusName(CoinPrePostsolveMatrix::Status status)
Generate a print string for a status code.
virtual void mergeBasis(const CoinWarmStartBasis *src, const XferVec *xferRows, const XferVec *xferCols)
Merge entries from a source basis into this basis.
const char * getArtificialStatus() const
const overload for getArtificialStatus()
virtual CoinWarmStartDiff * generateDiff(const CoinWarmStart *const oldCWS) const
Generate a `diff' that can convert the warm start basis passed as a parameter to the warm start basis...
Not basic and not at bound.
int maxSize_
The maximum sise (in ints - actually 4*char) (so resize does not need to do new)
bool fullBasis() const
Returns true if full basis (for debug)
virtual void resize(int newNumberRows, int newNumberColumns)
Set basis capacity; existing basis is maintained.
char * getArtificialStatus()
As for getStructuralStatus , but returns the status array for the artificial variables.
Abstract base class for warm start `diff' objects.
unsigned int * difference_
Array of diff indices and diff values.
std::vector< XferEntry > XferVec
Transfer vector for mergeBasis(const CoinWarmStartBasis*,const XferVec*,const XferVec*) ...
const char * getStructuralStatus() const
const overload for getStructuralStatus()
virtual CoinWarmStartBasisDiff & operator=(const CoinWarmStartBasisDiff &rhs)
Assignment.
void setStructStatus(int i, Status st)
Set the status of the specified structural variable.
int getNumStructural() const
Return the number of structural variables.
A `diff' between two CoinWarmStartBasis objects.
virtual ~CoinWarmStartBasis()
Destructor.
virtual void applyDiff(const CoinWarmStartDiff *const cwsdDiff)
Apply diff to this basis.
CoinWarmStartBasis::Status getStatus(const char *array, int i)
Get the status of the specified variable in the given status array.
CoinWarmStartBasisDiff()
Default constructor.
int numberBasicStructurals() const
Return the number of basic structurals.
Declaration of the generic simplex (basis-oriented) warm start class. Also contains a basis diff clas...
Status getStructStatus(int i) const
Return the status of the specified structural variable.
virtual CoinWarmStartBasis & operator=(const CoinWarmStartBasis &rhs)
Assignment.
bool fixFullBasis()
Returns true if full basis and fixes up (for debug)
void setStatus(char *array, int i, CoinWarmStartBasis::Status st)
Set the status of the specified variable in the given status array.
int numArtificial_
The number of artificial variables.
CoinWarmStartBasis()
Default constructor.
int getNumArtificial() const
Return the number of artificial variables.
Abstract base class for warm start information.
Status getArtifStatus(int i) const
Return the status of the specified artificial variable.
virtual void assignBasisStatus(int ns, int na, char *&sStat, char *&aStat)
Assign the status vectors to be the warm start information.
virtual void deleteColumns(int number, const int *which)
Delete a set of columns from the basis.
virtual void print() const
Prints in readable format (for debug)
int numStructural_
The number of structural variables.
void setArtifStatus(int i, Status st)
Set the status of the specified artificial variable.
int sze_
Number of entries (and allocated capacity), in units of int.
char statusToChar(CoinWarmStartBasis::Status status)
In an example Aleksandr Kazachkov sent to me, I noticed he was using code as above but with char - it...
virtual CoinWarmStart * clone() const
`Virtual constructor'
char * getStructuralStatus()
Return the status array for the structural variables.
virtual void deleteRows(int rawTgtCnt, const int *rawTgts)
Delete a set of rows from the basis.
virtual void compressRows(int tgtCnt, const int *tgts)
Delete a set of rows from the basis.
char * artificialStatus_
The status of the artificial variables.
CoinWarmStartBasis::Status charToStatus(char status)
Convert character to status.
virtual CoinWarmStartDiff * clone() const
`Virtual constructor'
virtual ~CoinWarmStartBasisDiff()
Destructor.
The default COIN simplex (basis-oriented) warm start class.
Status
Enum for status of variables.
CoinTriple< int, int, int > XferEntry
Transfer vector entry for mergeBasis(const CoinWarmStartBasis*,const XferVec*,const XferVec*) ...