KASKADE 7 development version
Classes | Enumerations | Functions

Classes and functions for elimination methods. More...

Classes

class  Kaskade::DirectSolver< Domain_, Range_ >
 
class  Kaskade::DirectPreconditioner< Op >
 
class  Kaskade::Factorization< Scalar >
 Abstract base class for matrix factorizations. More...
 
struct  Kaskade::Creator< Factorization< Scalar > >
 Abstract base class for factorization creators to be plugged into a factorization factory. More...
 
class  Kaskade::MUMPSFactorization< Scalar >
 Factorization of sparse linear systems with mumps. More...
 

Enumerations

enum class  DirectType {
  DirectType::ANY =-1 , DirectType::UMFPACK , DirectType::PARDISO , DirectType::MUMPS ,
  DirectType::SUPERLU , DirectType::UMFPACK3264 , DirectType::UMFPACK64
}
 Available direct solvers for linear equation systems. More...
 

Functions

template<class Scalar , class Index >
std::unique_ptr< Factorization< Scalar > > Kaskade::getFactorization (DirectType directType, MatrixAsTriplet< Scalar, Index > const &A, FactorizationOptions options)
 Creates a factorization of the given triplet matrix. More...
 
template<class Scalar >
std::unique_ptr< Factorization< Scalar > > Kaskade::getFactorization (DirectType directType, Dune::BCRSMatrix< Dune::FieldMatrix< Scalar, 1, 1 > > const &A, FactorizationOptions options)
 Creates a factorization of the given BCRSmatrix. More...
 
template<class Scalar , int n, int m, class Index >
std::unique_ptr< Factorization< Scalar > > Kaskade::getFactorization (DirectType directType, NumaBCRSMatrix< Dune::FieldMatrix< Scalar, n, m >, Index > const &A, FactorizationOptions options)
 Creates a factorization of the given NumaBCRS matrix. More...
 

Detailed Description

Classes and functions for elimination methods.

Kaskade 7 provides a dynamic abstract interface to direct solvers for linear equation systems \( Ax = b \). The interface and available direct solvers are described here.

Creating solvers

Available solvers

Different solvers have been integrated by providing glue code registering them dynamically with the solver factory. Only solvers that are actually installed are available. This can be queried at run time at the factory.

UMFPack

Direct type: UMFPACK, UMFPACK64

UMFPack is a general-purpose direct solver computing an LU decomposition with pivoting, included in the SuiteSparse software. It is not the fastest solver around, but robust and easy to work with. Unless performance or memory consumption are critical, it is a good choice to start with.

In 3D diffusion problems, UMFPack works well up to more than 100k degrees of freedom. Standard UMFPACK works with 32 bit int indices, and can therefore fail on very large problems. In that case, use UMFPACK64, which works with 64 bit long indices.

UMFPack supports the following options that can be set in the FactorizationOptions object passed when constructing a solver:

MUMPS

Enumeration Type Documentation

◆ DirectType

enum class DirectType
strong

Available direct solvers for linear equation systems.

Not all of these need be actually available, that depends on which solvers are included in the installation. But these are the lookup keys for creating solvers via the factorization factory.

Enumerator
ANY 
UMFPACK 

UMFPack from SuiteSparse, using 32 bit integer indices.

This is a robust LU factorization. For very large systems, it may run out of index space, then consider using UMFPACK64.

Using several UMFPack factorizations in different threads appears to work fine.

PARDISO 
MUMPS 

MUMPS sparse solver.

This provides LU as well as Cholesky decompositions. Usually somewhat faster than UMFPack. Using several MUMPS factorizations in different threads does not work.

SUPERLU 
UMFPACK3264 

NO LONGER SUPPORTED.

This refers to the exotic option in UMFPack to use 32 bit integers for indexing rows/columns, but 64 bit integers for indexing matrix entry arrays. This saves some memory and data transfer, but requires a particular way of installation which we no longer support.

UMFPACK64 

UMFPack from SuiteSparse, using 64 bit integer indices.

This is a robust LU factorization for very large systems. Smaller systems, where 32 bit indices are sufficient, may benefit from using UMFPACK instead.

Definition at line 35 of file enums.hh.

Function Documentation

◆ getFactorization() [1/3]

template<class Scalar >
std::unique_ptr< Factorization< Scalar > > Kaskade::getFactorization ( DirectType  directType,
Dune::BCRSMatrix< Dune::FieldMatrix< Scalar, 1, 1 > > const &  A,
FactorizationOptions  options 
)

Creates a factorization of the given BCRSmatrix.

Definition at line 217 of file factorization.hh.

◆ getFactorization() [2/3]

template<class Scalar , class Index >
std::unique_ptr< Factorization< Scalar > > Kaskade::getFactorization ( DirectType  directType,
MatrixAsTriplet< Scalar, Index > const &  A,
FactorizationOptions  options 
)

Creates a factorization of the given triplet matrix.

Definition at line 192 of file factorization.hh.

Referenced by Kaskade::getFactorization(), and Kaskade::PartialDirectPreconditioner< Op >::PartialDirectPreconditioner().

◆ getFactorization() [3/3]

template<class Scalar , int n, int m, class Index >
std::unique_ptr< Factorization< Scalar > > Kaskade::getFactorization ( DirectType  directType,
NumaBCRSMatrix< Dune::FieldMatrix< Scalar, n, m >, Index > const &  A,
FactorizationOptions  options 
)

Creates a factorization of the given NumaBCRS matrix.

Definition at line 231 of file factorization.hh.