Clp
1.17.8
|
Base class for Clp Cholesky factorization Will do better factorization. More...
#include <ClpCholeskyBase.hpp>
Public Member Functions | |
Gets | |
int | status () const |
status. Returns status More... | |
int | numberRowsDropped () const |
numberRowsDropped. Number of rows gone More... | |
void | resetRowsDropped () |
reset numberRowsDropped and rowsDropped. More... | |
char * | rowsDropped () const |
rowsDropped - which rows are gone More... | |
double | choleskyCondition () const |
choleskyCondition. More... | |
double | goDense () const |
goDense i.e. use dense factoriaztion if > this (default 0.7). More... | |
void | setGoDense (double value) |
goDense i.e. use dense factoriaztion if > this (default 0.7). More... | |
int | rank () const |
rank. Returns rank More... | |
int | numberRows () const |
Return number of rows. More... | |
int | size () const |
Return size. More... | |
longDouble * | sparseFactor () const |
Return sparseFactor. More... | |
longDouble * | diagonal () const |
Return diagonal. More... | |
longDouble * | workDouble () const |
Return workDouble. More... | |
bool | kkt () const |
If KKT on. More... | |
void | setKKT (bool yesNo) |
Set KKT. More... | |
void | setIntegerParameter (int i, int value) |
Set integer parameter. More... | |
int | getIntegerParameter (int i) |
get integer parameter More... | |
void | setDoubleParameter (int i, double value) |
Set double parameter. More... | |
double | getDoubleParameter (int i) |
get double parameter More... | |
Constructors, destructor | |
ClpCholeskyBase (int denseThreshold=-1) | |
Constructor which has dense columns activated. More... | |
virtual | ~ClpCholeskyBase () |
Destructor (has to be public) More... | |
ClpCholeskyBase (const ClpCholeskyBase &) | |
Copy. More... | |
ClpCholeskyBase & | operator= (const ClpCholeskyBase &) |
Assignment. More... | |
Protected Member Functions | |
Symbolic, factor and solve | |
int | symbolic1 (const int *Astart, const int *Arow) |
Symbolic1 - works out size without clever stuff. More... | |
void | symbolic2 (const int *Astart, const int *Arow) |
Symbolic2 - Fills in indices Uses lower triangular so can do cliques etc. More... | |
void | factorizePart2 (int *rowsDropped) |
Factorize - filling in rowsDropped and returning number dropped in integerParam. More... | |
void | solve (CoinWorkDouble *region, int type) |
solve - 1 just first half, 2 just second half - 3 both. More... | |
int | preOrder (bool lowerTriangular, bool includeDiagonal, bool doKKT) |
Forms ADAT - returns nonzero if not enough memory. More... | |
void | updateDense (longDouble *d, int *first) |
Updates dense part (broken out for profiling) More... | |
Protected Attributes | |
Data members | |
The data members are protected to allow access for derived classes. | |
int | type_ |
type (may be useful) if > 20 do KKT More... | |
bool | doKKT_ |
Doing full KKT (only used if default symbolic and factorization) More... | |
double | goDense_ |
Go dense at this fraction. More... | |
double | choleskyCondition_ |
choleskyCondition. More... | |
ClpInterior * | model_ |
model. More... | |
int | numberTrials_ |
numberTrials. Number of trials before rejection More... | |
int | numberRows_ |
numberRows. Number of Rows in factorization More... | |
int | status_ |
status. Status of factorization More... | |
char * | rowsDropped_ |
rowsDropped More... | |
int * | permuteInverse_ |
permute inverse. More... | |
int * | permute_ |
main permute. More... | |
int | numberRowsDropped_ |
numberRowsDropped. Number of rows gone More... | |
longDouble * | sparseFactor_ |
sparseFactor. More... | |
int * | choleskyStart_ |
choleskyStart - element starts More... | |
int * | choleskyRow_ |
choleskyRow (can be shorter than sparsefactor) More... | |
int * | indexStart_ |
Index starts. More... | |
longDouble * | diagonal_ |
Diagonal. More... | |
longDouble * | workDouble_ |
double work array More... | |
int * | link_ |
link array More... | |
int * | workInteger_ |
int * | clique_ |
int | sizeFactor_ |
sizeFactor. More... | |
int | sizeIndex_ |
Size of index array. More... | |
int | firstDense_ |
First dense row. More... | |
int | integerParameters_ [64] |
integerParameters More... | |
double | doubleParameters_ [64] |
doubleParameters; More... | |
ClpMatrixBase * | rowCopy_ |
Row copy of matrix. More... | |
char * | whichDense_ |
Dense indicators. More... | |
longDouble * | denseColumn_ |
Dense columns (updated) More... | |
ClpCholeskyDense * | dense_ |
Dense cholesky. More... | |
int | denseThreshold_ |
Dense threshold (for taking out of Cholesky) More... | |
Virtual methods that the derived classes may provide | |
virtual int | order (ClpInterior *model) |
Orders rows and saves pointer to matrix.and model. More... | |
virtual int | symbolic () |
Does Symbolic factorization given permutation. More... | |
virtual int | factorize (const CoinWorkDouble *diagonal, int *rowsDropped) |
Factorize - filling in rowsDropped and returning number dropped. More... | |
virtual void | solve (CoinWorkDouble *region) |
Uses factorization to solve. More... | |
virtual void | solveKKT (CoinWorkDouble *region1, CoinWorkDouble *region2, const CoinWorkDouble *diagonal, CoinWorkDouble diagonalScaleFactor) |
Uses factorization to solve. More... | |
int | orderAMD () |
AMD ordering. More... | |
Other | |
virtual ClpCholeskyBase * | clone () const |
int | type () const |
Returns type. More... | |
void | setType (int type) |
Sets type. More... | |
void | setModel (ClpInterior *model) |
model. More... | |
Base class for Clp Cholesky factorization Will do better factorization.
very crude ordering
Derived classes may be using more sophisticated methods
Definition at line 53 of file ClpCholeskyBase.hpp.
ClpCholeskyBase::ClpCholeskyBase | ( | int | denseThreshold = -1 | ) |
Constructor which has dense columns activated.
Default is off.
|
virtual |
Destructor (has to be public)
ClpCholeskyBase::ClpCholeskyBase | ( | const ClpCholeskyBase & | ) |
Copy.
|
virtual |
Orders rows and saves pointer to matrix.and model.
returns non-zero if not enough memory. You can use preOrder to set up ADAT If using default symbolic etc then must set sizeFactor_ to size of input matrix to order (and to symbolic). Also just permute_ and permuteInverse_ should be created
Reimplemented in ClpCholeskyTaucs, ClpCholeskyUfl, ClpCholeskyMumps, ClpCholeskyWssmp, ClpCholeskyWssmpKKT, and ClpCholeskyDense.
|
virtual |
Does Symbolic factorization given permutation.
This is called immediately after order. If user provides this then user must provide factorize and solve. Otherwise the default factorization is used returns non-zero if not enough memory
Reimplemented in ClpCholeskyTaucs, ClpCholeskyUfl, ClpCholeskyMumps, ClpCholeskyWssmp, ClpCholeskyWssmpKKT, and ClpCholeskyDense.
|
virtual |
Factorize - filling in rowsDropped and returning number dropped.
If return code negative then out of memory
Reimplemented in ClpCholeskyDense.
|
virtual |
Uses factorization to solve.
Reimplemented in ClpCholeskyDense.
|
virtual |
Uses factorization to solve.
|
private |
AMD ordering.
|
inline |
status. Returns status
Definition at line 90 of file ClpCholeskyBase.hpp.
|
inline |
numberRowsDropped. Number of rows gone
Definition at line 95 of file ClpCholeskyBase.hpp.
void ClpCholeskyBase::resetRowsDropped | ( | ) |
reset numberRowsDropped and rowsDropped.
|
inline |
rowsDropped - which rows are gone
Definition at line 102 of file ClpCholeskyBase.hpp.
|
inline |
choleskyCondition.
Definition at line 107 of file ClpCholeskyBase.hpp.
|
inline |
goDense i.e. use dense factoriaztion if > this (default 0.7).
Definition at line 112 of file ClpCholeskyBase.hpp.
|
inline |
goDense i.e. use dense factoriaztion if > this (default 0.7).
Definition at line 117 of file ClpCholeskyBase.hpp.
|
inline |
rank. Returns rank
Definition at line 122 of file ClpCholeskyBase.hpp.
|
inline |
Return number of rows.
Definition at line 127 of file ClpCholeskyBase.hpp.
|
inline |
Return size.
Definition at line 132 of file ClpCholeskyBase.hpp.
|
inline |
Return sparseFactor.
Definition at line 137 of file ClpCholeskyBase.hpp.
|
inline |
Return diagonal.
Definition at line 142 of file ClpCholeskyBase.hpp.
|
inline |
Return workDouble.
Definition at line 147 of file ClpCholeskyBase.hpp.
|
inline |
If KKT on.
Definition at line 152 of file ClpCholeskyBase.hpp.
|
inline |
Set KKT.
Definition at line 157 of file ClpCholeskyBase.hpp.
|
inline |
Set integer parameter.
Definition at line 162 of file ClpCholeskyBase.hpp.
|
inline |
get integer parameter
Definition at line 167 of file ClpCholeskyBase.hpp.
|
inline |
Set double parameter.
Definition at line 172 of file ClpCholeskyBase.hpp.
|
inline |
get double parameter
Definition at line 177 of file ClpCholeskyBase.hpp.
ClpCholeskyBase& ClpCholeskyBase::operator= | ( | const ClpCholeskyBase & | ) |
Assignment.
|
virtual |
Reimplemented in ClpCholeskyDense, ClpCholeskyTaucs, ClpCholeskyUfl, ClpCholeskyWssmpKKT, ClpCholeskyMumps, and ClpCholeskyWssmp.
|
inline |
Returns type.
Definition at line 203 of file ClpCholeskyBase.hpp.
|
inlineprotected |
Sets type.
Definition at line 213 of file ClpCholeskyBase.hpp.
|
inlineprotected |
model.
Definition at line 218 of file ClpCholeskyBase.hpp.
|
protected |
Symbolic1 - works out size without clever stuff.
Uses upper triangular as much easier. Returns size
|
protected |
Symbolic2 - Fills in indices Uses lower triangular so can do cliques etc.
|
protected |
Factorize - filling in rowsDropped and returning number dropped in integerParam.
|
protected |
solve - 1 just first half, 2 just second half - 3 both.
If 1 and 2 then diagonal has sqrt of inverse otherwise inverse
|
protected |
Forms ADAT - returns nonzero if not enough memory.
|
protected |
Updates dense part (broken out for profiling)
|
protected |
type (may be useful) if > 20 do KKT
Definition at line 254 of file ClpCholeskyBase.hpp.
|
protected |
Doing full KKT (only used if default symbolic and factorization)
Definition at line 256 of file ClpCholeskyBase.hpp.
|
protected |
Go dense at this fraction.
Definition at line 258 of file ClpCholeskyBase.hpp.
|
protected |
choleskyCondition.
Definition at line 260 of file ClpCholeskyBase.hpp.
|
protected |
model.
Definition at line 262 of file ClpCholeskyBase.hpp.
|
protected |
numberTrials. Number of trials before rejection
Definition at line 264 of file ClpCholeskyBase.hpp.
|
protected |
numberRows. Number of Rows in factorization
Definition at line 266 of file ClpCholeskyBase.hpp.
|
protected |
status. Status of factorization
Definition at line 268 of file ClpCholeskyBase.hpp.
|
protected |
rowsDropped
Definition at line 270 of file ClpCholeskyBase.hpp.
|
protected |
permute inverse.
Definition at line 272 of file ClpCholeskyBase.hpp.
|
protected |
main permute.
Definition at line 274 of file ClpCholeskyBase.hpp.
|
protected |
numberRowsDropped. Number of rows gone
Definition at line 276 of file ClpCholeskyBase.hpp.
|
protected |
sparseFactor.
Definition at line 278 of file ClpCholeskyBase.hpp.
|
protected |
choleskyStart - element starts
Definition at line 280 of file ClpCholeskyBase.hpp.
|
protected |
choleskyRow (can be shorter than sparsefactor)
Definition at line 282 of file ClpCholeskyBase.hpp.
|
protected |
Index starts.
Definition at line 284 of file ClpCholeskyBase.hpp.
|
protected |
Diagonal.
Definition at line 286 of file ClpCholeskyBase.hpp.
|
protected |
double work array
Definition at line 288 of file ClpCholeskyBase.hpp.
|
protected |
link array
Definition at line 290 of file ClpCholeskyBase.hpp.
|
protected |
Definition at line 292 of file ClpCholeskyBase.hpp.
|
protected |
Definition at line 294 of file ClpCholeskyBase.hpp.
|
protected |
sizeFactor.
Definition at line 296 of file ClpCholeskyBase.hpp.
|
protected |
Size of index array.
Definition at line 298 of file ClpCholeskyBase.hpp.
|
protected |
First dense row.
Definition at line 300 of file ClpCholeskyBase.hpp.
|
protected |
integerParameters
Definition at line 302 of file ClpCholeskyBase.hpp.
|
protected |
doubleParameters;
Definition at line 304 of file ClpCholeskyBase.hpp.
|
protected |
Row copy of matrix.
Definition at line 306 of file ClpCholeskyBase.hpp.
|
protected |
Dense indicators.
Definition at line 308 of file ClpCholeskyBase.hpp.
|
protected |
Dense columns (updated)
Definition at line 310 of file ClpCholeskyBase.hpp.
|
protected |
Dense cholesky.
Definition at line 312 of file ClpCholeskyBase.hpp.
|
protected |
Dense threshold (for taking out of Cholesky)
Definition at line 314 of file ClpCholeskyBase.hpp.