Eigen  5.0.1-dev+master
 
Loading...
Searching...
No Matches
Eigen::UmfPackLU< MatrixType_ > Class Template Reference

#include <Eigen/src/UmfPackSupport/UmfPackSupport.h>

Detailed Description

template<typename MatrixType_>
class Eigen::UmfPackLU< MatrixType_ >

A sparse LU factorization and solver based on UmfPack.

This class allows to solve for A.X = B sparse linear problems via a LU factorization using the UmfPack library. The sparse matrix A must be square and full rank. The vectors or matrices X and B can be either dense or sparse.

Warning
The input matrix A should be in a compressed and column-major form. Otherwise an expensive copy will be made. You can call the inexpensive makeCompressed() to get a compressed matrix.
Template Parameters
MatrixType_the type of the sparse matrix A, it must be a SparseMatrix<>

This class follows the sparse solver concept .

See also
Sparse solver concept, class SparseLU
+ Inheritance diagram for Eigen::UmfPackLU< MatrixType_ >:

Public Member Functions

template<typename InputMatrixType>
void analyzePattern (const InputMatrixType &matrix)
 
template<typename InputMatrixType>
void compute (const InputMatrixType &matrix)
 
template<typename InputMatrixType>
void factorize (const InputMatrixType &matrix)
 
ComputationInfo info () const
 Reports whether previous computation was successful.
 
const LUMatrixType & matrixL () const
 
const LUMatrixType & matrixU () const
 
const IntColVectorType & permutationP () const
 
const IntRowVectorType & permutationQ () const
 
void printUmfpackControl ()
 
void printUmfpackInfo ()
 
void printUmfpackStatus ()
 
const Matrix< RealScalar, Dynamic, 1 > & rowScaling () const
 
UmfpackControl & umfpackControl ()
 
const UmfpackControl & umfpackControl () const
 
int umfpackFactorizeReturncode () const
 
- Public Member Functions inherited from Eigen::SparseSolverBase< UmfPackLU< MatrixType_ > >
Solve< UmfPackLU< MatrixType_ >, Rhs > solve (const MatrixBase< Rhs > &b) const
 
Solve< UmfPackLU< MatrixType_ >, Rhs > solve (const MatrixBase< Rhs > &b) const
 
Solve< UmfPackLU< MatrixType_ >, Rhs > solve (const SparseMatrixBase< Rhs > &b) const
 
Solve< UmfPackLU< MatrixType_ >, Rhs > solve (const SparseMatrixBase< Rhs > &b) const
 
 SparseSolverBase ()=default
 
 SparseSolverBase ()=default
 

Member Function Documentation

◆ analyzePattern()

template<typename MatrixType_>
template<typename InputMatrixType>
void Eigen::UmfPackLU< MatrixType_ >::analyzePattern ( const InputMatrixType & matrix)
inline

Performs a symbolic decomposition on the sparsity of matrix.

This function is particularly useful when solving for several problems having the same structure.

See also
factorize(), compute()

◆ compute()

template<typename MatrixType_>
template<typename InputMatrixType>
void Eigen::UmfPackLU< MatrixType_ >::compute ( const InputMatrixType & matrix)
inline

Computes the sparse LU decomposition of matrix Note that the matrix should be column-major, and in compressed format for best performance.

See also
SparseMatrix::makeCompressed().

◆ factorize()

template<typename MatrixType_>
template<typename InputMatrixType>
void Eigen::UmfPackLU< MatrixType_ >::factorize ( const InputMatrixType & matrix)
inline

Performs a numeric decomposition of matrix

The given matrix must have the same sparsity as the matrix on which the pattern analysis has been performed.

See also
analyzePattern(), compute()

◆ info()

template<typename MatrixType_>
ComputationInfo Eigen::UmfPackLU< MatrixType_ >::info ( ) const
inline

Reports whether previous computation was successful.

Returns
Success if computation was successful, NumericalIssue if the matrix appears to be negative.

◆ matrixL()

template<typename MatrixType_>
const LUMatrixType & Eigen::UmfPackLU< MatrixType_ >::matrixL ( ) const
inline
Returns
the unit lower triangular factor L of the factorization

With P = permutationP(), Q = permutationQ() and s = rowScaling(), UMFPACK computes

(L * U)(i, j) == s(P(i)) * A(P(i), Q(j))

up to rounding: the rows of A are scaled by s before the rows and columns are permuted. By default UMFPACK scales the rows of A (s != 1); set umfpackControl()[UMFPACK_SCALE] to UMFPACK_SCALE_NONE before the factorization to get s = 1. The reference is invalidated by the next call to compute(), analyzePattern() or factorize().

◆ matrixU()

template<typename MatrixType_>
const LUMatrixType & Eigen::UmfPackLU< MatrixType_ >::matrixU ( ) const
inline
Returns
the upper triangular factor U of the factorization, see matrixL()

◆ permutationP()

template<typename MatrixType_>
const IntColVectorType & Eigen::UmfPackLU< MatrixType_ >::permutationP ( ) const
inline
Returns
the row permutation P: row P(k) of A is the k-th pivot row, see matrixL()

◆ permutationQ()

template<typename MatrixType_>
const IntRowVectorType & Eigen::UmfPackLU< MatrixType_ >::permutationQ ( ) const
inline
Returns
the column permutation Q: column Q(k) of A is the k-th pivot column, see matrixL()

◆ printUmfpackControl()

template<typename MatrixType_>
void Eigen::UmfPackLU< MatrixType_ >::printUmfpackControl ( )
inline

Prints the current UmfPack control settings.

See also
umfpackControl()

◆ printUmfpackInfo()

template<typename MatrixType_>
void Eigen::UmfPackLU< MatrixType_ >::printUmfpackInfo ( )
inline

Prints statistics collected by UmfPack.

See also
analyzePattern(), compute()

◆ printUmfpackStatus()

template<typename MatrixType_>
void Eigen::UmfPackLU< MatrixType_ >::printUmfpackStatus ( )
inline

Prints the status of the previous factorization operation performed by UmfPack (symbolic or numerical factorization).

See also
analyzePattern(), compute()

◆ rowScaling()

template<typename MatrixType_>
const Matrix< RealScalar, Dynamic, 1 > & Eigen::UmfPackLU< MatrixType_ >::rowScaling ( ) const
inline
Returns
the factor s by which UMFPACK scaled each row of A before the factorization (all ones if scaling is disabled), indexed like the rows of A. See matrixL().

◆ umfpackControl() [1/2]

template<typename MatrixType_>
UmfpackControl & Eigen::UmfPackLU< MatrixType_ >::umfpackControl ( )
inline

Provides access to the control settings array used by UmfPack.

If this array contains NaN's, the default values are used.

See UMFPACK documentation for details.

◆ umfpackControl() [2/2]

template<typename MatrixType_>
const UmfpackControl & Eigen::UmfPackLU< MatrixType_ >::umfpackControl ( ) const
inline

Provides access to the control settings array used by UmfPack.

If this array contains NaN's, the default values are used.

See UMFPACK documentation for details.

◆ umfpackFactorizeReturncode()

template<typename MatrixType_>
int Eigen::UmfPackLU< MatrixType_ >::umfpackFactorizeReturncode ( ) const
inline

Provides the return status code returned by UmfPack during the numeric factorization.

See also
factorize(), compute()

The documentation for this class was generated from the following file: