Sparse supernodal LU factorization for general matrices. More...
#include <SparseLU.h>
Public Types | |
enum | { ColsAtCompileTime = MatrixType::ColsAtCompileTime, MaxColsAtCompileTime = MatrixType::MaxColsAtCompileTime } |
typedef internal::SparseLUImpl< Scalar, StorageIndex > | Base |
typedef Matrix< StorageIndex, Dynamic, 1 > | IndexVector |
typedef _MatrixType | MatrixType |
typedef SparseMatrix< Scalar, ColMajor, StorageIndex > | NCMatrix |
typedef _OrderingType | OrderingType |
typedef PermutationMatrix< Dynamic, Dynamic, StorageIndex > | PermutationType |
typedef MatrixType::RealScalar | RealScalar |
typedef MatrixType::Scalar | Scalar |
typedef Matrix< Scalar, Dynamic, 1 > | ScalarVector |
typedef internal::MappedSuperNodalMatrix< Scalar, StorageIndex > | SCMatrix |
typedef MatrixType::StorageIndex | StorageIndex |
Protected Types | |
typedef SparseSolverBase< SparseLU< _MatrixType, _OrderingType > > | APIBase |
Protected Member Functions | |
void | initperfvalues () |
Protected Attributes | |
bool | m_analysisIsOk |
Index | m_detPermC |
Index | m_detPermR |
RealScalar | m_diagpivotthresh |
IndexVector | m_etree |
bool | m_factorizationIsOk |
Base::GlobalLU_t | m_glu |
ComputationInfo | m_info |
bool | m_isInitialized |
std::string | m_lastError |
SCMatrix | m_Lstore |
NCMatrix | m_mat |
Index | m_nnzL |
Index | m_nnzU |
internal::perfvalues | m_perfv |
PermutationType | m_perm_c |
PermutationType | m_perm_r |
bool | m_symmetricmode |
MappedSparseMatrix< Scalar, ColMajor, StorageIndex > | m_Ustore |
Private Member Functions | |
SparseLU (const SparseLU &) | |
Sparse supernodal LU factorization for general matrices.
This class implements the supernodal LU factorization for general matrices. It uses the main techniques from the sequential SuperLU package (http://crd-legacy.lbl.gov/~xiaoye/SuperLU/). It handles transparently real and complex arithmetic with single and double precision, depending on the scalar type of your input matrix. The code has been optimized to provide BLAS-3 operations during supernode-panel updates. It benefits directly from the built-in high-performant Eigen BLAS routines. Moreover, when the size of a supernode is very small, the BLAS calls are avoided to enable a better optimization from the compiler. For best performance, you should compile it with NDEBUG flag to avoid the numerous bounds checking on vectors.
An important parameter of this class is the ordering method. It is used to reorder the columns (and eventually the rows) of the matrix to reduce the number of new elements that are created during numerical factorization. The cheapest method available is COLAMD. See the OrderingMethods module for the list of built-in and external ordering methods.
Simple example with key steps
_MatrixType | The type of the sparse matrix. It must be a column-major SparseMatrix<> |
_OrderingType | The ordering method to use, either AMD, COLAMD or METIS. Default is COLMAD |
\implsparsesolverconcept
Definition at line 17 of file SparseLU.h.
|
protected |
Definition at line 134 of file SparseLU.h.
Definition at line 149 of file SparseLU.h.
typedef Matrix<StorageIndex,Dynamic,1> Eigen::SparseLU::IndexVector |
Definition at line 147 of file SparseLU.h.
typedef _MatrixType Eigen::SparseLU::MatrixType |
Definition at line 139 of file SparseLU.h.
Definition at line 144 of file SparseLU.h.
typedef _OrderingType Eigen::SparseLU::OrderingType |
Definition at line 140 of file SparseLU.h.
Definition at line 148 of file SparseLU.h.
typedef MatrixType::RealScalar Eigen::SparseLU::RealScalar |
Definition at line 142 of file SparseLU.h.
typedef MatrixType::Scalar Eigen::SparseLU::Scalar |
Definition at line 141 of file SparseLU.h.
typedef Matrix<Scalar,Dynamic,1> Eigen::SparseLU::ScalarVector |
Definition at line 146 of file SparseLU.h.
Definition at line 145 of file SparseLU.h.
typedef MatrixType::StorageIndex Eigen::SparseLU::StorageIndex |
Definition at line 143 of file SparseLU.h.
anonymous enum |
Enumerator | |
---|---|
ColsAtCompileTime | |
MaxColsAtCompileTime |
Definition at line 151 of file SparseLU.h.
|
inline |
Definition at line 158 of file SparseLU.h.
|
inlineexplicit |
Definition at line 162 of file SparseLU.h.
|
inline |
Definition at line 169 of file SparseLU.h.
|
private |
|
inline |
Definition at line 314 of file SparseLU.h.
|
inline |
Definition at line 111 of file SparseSolverBase.h.
|
inline |
Definition at line 350 of file SparseLU.h.
|
inline |
A typical usage is to solve for the adjoint problem A' x = b:
For real scalar types, this function is equivalent to transpose().
Definition at line 221 of file SparseLU.h.
void Eigen::SparseLU::analyzePattern | ( | const MatrixType & | mat | ) |
Compute the column permutation to minimize the fill-in
Definition at line 510 of file SparseLU.h.
|
inline |
Definition at line 230 of file SparseLU.h.
|
inline |
Definition at line 270 of file SparseLU.h.
|
inline |
Compute the symbolic and numeric factorization of the input sparse matrix. The input matrix should be in column-major storage.
Definition at line 182 of file SparseLU.h.
|
inline |
Definition at line 434 of file SparseLU.h.
void Eigen::SparseLU::factorize | ( | const MatrixType & | matrix | ) |
Interleaved with the symbolic factorization On exit, info is
= 0: successful factorization
0: if info = i, and i is
<= A->ncol: U(i,i) is exactly zero. The factorization has been completed, but the factor U is exactly singular, and division by zero will occur if it is used to solve a system of equations. > A->ncol: number of bytes allocated when memory allocation failure occurred, plus A->ncol. If lwork = -1, it is the estimated amount of space needed, plus A->ncol.
Definition at line 595 of file SparseLU.h.
|
inline |
Reports whether previous computation was successful.
Success
if computation was successful, NumericalIssue
if the LU factorization reports a problem, zero diagonal for instance InvalidInput
if the input matrix is invalidDefinition at line 299 of file SparseLU.h.
|
inlineprotected |
Definition at line 460 of file SparseLU.h.
|
inline |
Indicate that the pattern of the input matrix is symmetric
Definition at line 232 of file SparseLU.h.
|
inline |
Definition at line 308 of file SparseLU.h.
|
inline |
Definition at line 380 of file SparseLU.h.
|
inline |
|
inline |
|
inline |
Definition at line 455 of file SparseLU.h.
|
inline |
Definition at line 456 of file SparseLU.h.
|
inline |
Definition at line 229 of file SparseLU.h.
|
inline |
Definition at line 262 of file SparseLU.h.
|
inline |
Set the threshold used for a diagonal entry to be an acceptable pivot.
Definition at line 275 of file SparseLU.h.
|
inline |
Definition at line 406 of file SparseLU.h.
void Eigen::SparseLU::simplicialfactorize | ( | const MatrixType & | matrix | ) |
|
inline |
|
protected |
Definition at line 473 of file SparseLU.h.
|
protected |
Definition at line 490 of file SparseLU.h.
|
protected |
Definition at line 490 of file SparseLU.h.
|
protected |
Definition at line 488 of file SparseLU.h.
|
protected |
Definition at line 480 of file SparseLU.h.
|
protected |
Definition at line 472 of file SparseLU.h.
|
protected |
Definition at line 482 of file SparseLU.h.
|
mutableprotected |
Definition at line 471 of file SparseLU.h.
|
mutableprotected |
Definition at line 119 of file SparseSolverBase.h.
|
protected |
Definition at line 474 of file SparseLU.h.
|
protected |
Definition at line 476 of file SparseLU.h.
|
protected |
Definition at line 475 of file SparseLU.h.
|
protected |
Definition at line 489 of file SparseLU.h.
|
protected |
Definition at line 489 of file SparseLU.h.
|
protected |
Definition at line 487 of file SparseLU.h.
|
protected |
Definition at line 478 of file SparseLU.h.
|
protected |
Definition at line 479 of file SparseLU.h.
|
protected |
Definition at line 485 of file SparseLU.h.
|
protected |
Definition at line 477 of file SparseLU.h.