Loading...
Searching...
No Matches
ClpCholeskyDense.hpp
Go to the documentation of this file.
/* $Id$ */
/*
Copyright (C) 2003, International Business Machines Corporation
and others. All Rights Reserved.
This code is licensed under the terms of the Eclipse Public License (EPL).
*/
#ifndef ClpCholeskyDense_H
#define ClpCholeskyDense_H
#include "ClpCholeskyBase.hpp"
class ClpMatrixBase;
class ClpCholeskyDense : public ClpCholeskyBase {
public:
virtual int order(ClpInterior *model);
virtual int symbolic();
virtual int factorize(const CoinWorkDouble *diagonal, int *rowsDropped);
virtual void solve(CoinWorkDouble *region);
int reserveSpace(const ClpCholeskyBase *factor, int numberRows);
int space(int numberRows) const;
void factorizePart2(int *rowsDropped);
void factorizePart3(int *rowsDropped);
void solveF1(longDouble *a, int n, CoinWorkDouble *region);
void solveF2(longDouble *a, int n, CoinWorkDouble *region, CoinWorkDouble *region2);
void solveB1(longDouble *a, int n, CoinWorkDouble *region);
void solveB2(longDouble *a, int n, CoinWorkDouble *region, CoinWorkDouble *region2);
int bNumber(const longDouble *array, int &, int &);
inline longDouble *aMatrix() const
{
return sparseFactor_;
}
inline longDouble *diagonal() const
{
return diagonal_;
}
ClpCholeskyDense();
virtual ~ClpCholeskyDense();
ClpCholeskyDense(const ClpCholeskyDense &);
ClpCholeskyDense &operator=(const ClpCholeskyDense &);
virtual ClpCholeskyBase *clone() const;
private:
bool borrowSpace_;
};
/* structure for C */
typedef struct {
longDouble *diagonal_;
longDouble *a;
longDouble *work;
int *rowsDropped;
double doubleParameters_[1]; /* corresponds to 10 */
int integerParameters_[2]; /* corresponds to 34, nThreads */
int n;
int numberBlocks;
} ClpCholeskyDenseC;
extern "C" {
void ClpCholeskySpawn(void *);
}
void ClpCholeskyCfactor(ClpCholeskyDenseC *thisStruct,
longDouble *a, int n, int numberBlocks,
longDouble *diagonal, longDouble *work, int *rowsDropped);
void ClpCholeskyCtriRec(ClpCholeskyDenseC *thisStruct,
longDouble *aTri, int nThis,
longDouble *aUnder, longDouble *diagonal,
longDouble *work,
int nLeft, int iBlock, int jBlock,
int numberBlocks);
void ClpCholeskyCrecTri(ClpCholeskyDenseC *thisStruct,
longDouble *aUnder, int nTri, int nDo,
int iBlock, int jBlock, longDouble *aTri,
longDouble *diagonal, longDouble *work,
int numberBlocks);
void ClpCholeskyCrecRec(ClpCholeskyDenseC *thisStruct,
longDouble *above, int nUnder, int nUnderK,
int nDo, longDouble *aUnder, longDouble *aOther,
longDouble *work,
int iBlock, int jBlock,
int numberBlocks);
void ClpCholeskyCfactorLeaf(ClpCholeskyDenseC *thisStruct,
longDouble *a, int n,
longDouble *diagonal, longDouble *work,
int *rowsDropped);
void ClpCholeskyCtriRecLeaf(/*ClpCholeskyDenseC * thisStruct,*/
longDouble *aTri, longDouble *aUnder,
longDouble *diagonal, longDouble *work,
int nUnder);
void ClpCholeskyCrecTriLeaf(/*ClpCholeskyDenseC * thisStruct, */
longDouble *aUnder, longDouble *aTri,
/*longDouble * diagonal,*/ longDouble *work, int nUnder);
void ClpCholeskyCrecRecLeaf(/*ClpCholeskyDenseC * thisStruct, */
const longDouble *COIN_RESTRICT above,
const longDouble *COIN_RESTRICT aUnder,
longDouble *COIN_RESTRICT aOther,
const longDouble *COIN_RESTRICT work,
int nUnder);
#endif
/* vi: softtabstop=2 shiftwidth=2 expandtab tabstop=2
*/
ClpCholeskyBase.hpp
longDouble
double longDouble
Definition ClpCholeskyBase.hpp:40
ClpCholeskyCrecRec
void ClpCholeskyCrecRec(ClpCholeskyDenseC *thisStruct, longDouble *above, int nUnder, int nUnderK, int nDo, longDouble *aUnder, longDouble *aOther, longDouble *work, int iBlock, int jBlock, int numberBlocks)
Non leaf recursive rectangle rectangle update, nUnder is number of rows in iBlock,...
ClpCholeskyCtriRec
void ClpCholeskyCtriRec(ClpCholeskyDenseC *thisStruct, longDouble *aTri, int nThis, longDouble *aUnder, longDouble *diagonal, longDouble *work, int nLeft, int iBlock, int jBlock, int numberBlocks)
Non leaf recursive triangle rectangle update.
ClpCholeskyCtriRecLeaf
void ClpCholeskyCtriRecLeaf(longDouble *aTri, longDouble *aUnder, longDouble *diagonal, longDouble *work, int nUnder)
Leaf recursive triangle rectangle update.
ClpCholeskyCrecRecLeaf
void ClpCholeskyCrecRecLeaf(const longDouble *COIN_RESTRICT above, const longDouble *COIN_RESTRICT aUnder, longDouble *COIN_RESTRICT aOther, const longDouble *COIN_RESTRICT work, int nUnder)
Leaf recursive rectangle rectangle update, nUnder is number of rows in iBlock, nUnderK is number of r...
ClpCholeskyCrecTriLeaf
void ClpCholeskyCrecTriLeaf(longDouble *aUnder, longDouble *aTri, longDouble *work, int nUnder)
Leaf recursive rectangle triangle update.
ClpCholeskyCfactor
void ClpCholeskyCfactor(ClpCholeskyDenseC *thisStruct, longDouble *a, int n, int numberBlocks, longDouble *diagonal, longDouble *work, int *rowsDropped)
Non leaf recursive factor.
ClpCholeskyCrecTri
void ClpCholeskyCrecTri(ClpCholeskyDenseC *thisStruct, longDouble *aUnder, int nTri, int nDo, int iBlock, int jBlock, longDouble *aTri, longDouble *diagonal, longDouble *work, int numberBlocks)
Non leaf recursive rectangle triangle update.
ClpCholeskyCfactorLeaf
void ClpCholeskyCfactorLeaf(ClpCholeskyDenseC *thisStruct, longDouble *a, int n, longDouble *diagonal, longDouble *work, int *rowsDropped)
Leaf recursive factor.
ClpCholeskySpawn
void ClpCholeskySpawn(void *)
COIN_RESTRICT
#define COIN_RESTRICT
Definition ClpMatrixBase.hpp:21
ClpCholeskyBase::diagonal_
longDouble * diagonal_
Diagonal.
Definition ClpCholeskyBase.hpp:286
ClpCholeskyBase::sparseFactor_
longDouble * sparseFactor_
sparseFactor.
Definition ClpCholeskyBase.hpp:278
ClpCholeskyBase::numberRows
int numberRows() const
Return number of rows.
Definition ClpCholeskyBase.hpp:127
ClpCholeskyBase::rowsDropped
char * rowsDropped() const
rowsDropped - which rows are gone
Definition ClpCholeskyBase.hpp:102
ClpCholeskyBase::ClpCholeskyBase
ClpCholeskyBase(int denseThreshold=-1)
Constructor which has dense columns activated.
ClpCholeskyDense::factorizePart3
void factorizePart3(int *rowsDropped)
part 2 of Factorize - filling in rowsDropped - blocked
ClpCholeskyDense::ClpCholeskyDense
ClpCholeskyDense()
Default constructor.
ClpCholeskyDense::reserveSpace
int reserveSpace(const ClpCholeskyBase *factor, int numberRows)
Reserves space.
ClpCholeskyDense::clone
virtual ClpCholeskyBase * clone() const
Clone.
ClpCholeskyDense::aMatrix
longDouble * aMatrix() const
A.
Definition ClpCholeskyDense.hpp:54
ClpCholeskyDense::solveB1
void solveB1(longDouble *a, int n, CoinWorkDouble *region)
Backward part of solve.
ClpCholeskyDense::ClpCholeskyDense
ClpCholeskyDense(const ClpCholeskyDense &)
Copy.
ClpCholeskyDense::space
int space(int numberRows) const
Returns space needed.
ClpCholeskyDense::bNumber
int bNumber(const longDouble *array, int &, int &)
ClpCholeskyDense::factorize
virtual int factorize(const CoinWorkDouble *diagonal, int *rowsDropped)
Factorize - filling in rowsDropped and returning number dropped.
ClpCholeskyDense::factorizePart2
void factorizePart2(int *rowsDropped)
part 2 of Factorize - filling in rowsDropped
ClpCholeskyDense::solveF2
void solveF2(longDouble *a, int n, CoinWorkDouble *region, CoinWorkDouble *region2)
ClpCholeskyDense::operator=
ClpCholeskyDense & operator=(const ClpCholeskyDense &)
Assignment.
ClpCholeskyDense::borrowSpace_
bool borrowSpace_
Just borrowing space.
Definition ClpCholeskyDense.hpp:83
ClpCholeskyDense::order
virtual int order(ClpInterior *model)
Orders rows and saves pointer to matrix.and model.
ClpCholeskyDense::solveF1
void solveF1(longDouble *a, int n, CoinWorkDouble *region)
Forward part of solve.
ClpCholeskyDense::symbolic
virtual int symbolic()
Does Symbolic factorization given permutation.
ClpCholeskyDense::~ClpCholeskyDense
virtual ~ClpCholeskyDense()
Destructor.
ClpCholeskyDense::solveB2
void solveB2(longDouble *a, int n, CoinWorkDouble *region, CoinWorkDouble *region2)
ClpCholeskyDense::diagonal
longDouble * diagonal() const
Diagonal.
Definition ClpCholeskyDense.hpp:59
ClpCholeskyDense::solve
virtual void solve(CoinWorkDouble *region)
Uses factorization to solve.
ClpInterior
This solves LPs using interior point methods.
Definition ClpInterior.hpp:72
ClpMatrixBase
Abstract base class for Clp Matrices.
Definition ClpMatrixBase.hpp:38
ClpCholeskyDenseC
Definition ClpCholeskyDense.hpp:88
ClpCholeskyDenseC::rowsDropped
int * rowsDropped
Definition ClpCholeskyDense.hpp:92
ClpCholeskyDenseC::n
int n
Definition ClpCholeskyDense.hpp:95
ClpCholeskyDenseC::integerParameters_
int integerParameters_[2]
Definition ClpCholeskyDense.hpp:94
ClpCholeskyDenseC::doubleParameters_
double doubleParameters_[1]
Definition ClpCholeskyDense.hpp:93
ClpCholeskyDenseC::numberBlocks
int numberBlocks
Definition ClpCholeskyDense.hpp:96
ClpCholeskyDenseC::work
longDouble * work
Definition ClpCholeskyDense.hpp:91
ClpCholeskyDenseC::a
longDouble * a
Definition ClpCholeskyDense.hpp:90
ClpCholeskyDenseC::diagonal_
longDouble * diagonal_
Definition ClpCholeskyDense.hpp:89