KASKADE 7 development version
Public Types | Public Member Functions | Protected Attributes | List of all members
Kaskade::PardisoFactorization< Scalar, SparseIndexInt, DIL > Class Template Referenceabstract

Factorization with DirectType::PARDISO. More...

#include <pardiso_solve.hh>

Detailed Description

template<class Scalar, class SparseIndexInt = int, class DIL = int>
class Kaskade::PardisoFactorization< Scalar, SparseIndexInt, DIL >

Factorization with DirectType::PARDISO.

Link with intel mkl if you want to use it. (Version from 2013 will not work, but from 2017 and 2018 works)

Definition at line 31 of file linalg/pardiso_solve.hh.

Inheritance diagram for Kaskade::PardisoFactorization< Scalar, SparseIndexInt, DIL >:
Kaskade::Factorization< Scalar, int >

Public Types

typedef Scalar field_type
 The type of matrix elements (a field type). More...
 
using Options = FactorizationOptions
 

Public Member Functions

 PardisoFactorization (SparseIndexInt n, std::vector< SparseIndexInt >const &ridx, std::vector< SparseIndexInt >const &cidx, std::vector< Scalar >const &values, MatrixProperties property=MatrixProperties::GENERAL)
 
 ~PardisoFactorization ()
 
PardisoFactorizationoperator= (PardisoFactorization &&other)
 
void swap (PardisoFactorization &other)
 
virtual void solve (std::vector< Scalar > const &b, std::vector< Scalar > &x, int n, bool transposed=false) const
 
virtual void solve (std::vector< Scalar > const &b, std::vector< Scalar > &x, bool transpose=false) const
 Solves the system \( Ax=b \) for the given right hand side \( b \). More...
 
void solve (std::vector< Scalar > &b) const
 Solves the system \( Ax=b \) for the given right hand side \( b \). More...
 
void solve (std::vector< Scalar > &b, int n, bool transposed=false) const
 
void setVerbose (int verbose_)
 
int getVerbose () const
 
Info const & info () const
 
virtual size_t size () const=0
 reports the dimension of the system More...
 
System solution
virtual void solve (field_type *b) const=0
 Solves the system \( Ax=b \) for the given right hand side \( b \). More...
 
virtual void solve (Scalar const *b, Scalar *x, bool transposed=false) const=0
 Solves the system \( Ax=b \) for the given right hand side \( b \). More...
 

Protected Attributes

Options options
 
Info info_
 

Member Typedef Documentation

◆ field_type

typedef Scalar Kaskade::Factorization< Scalar >::field_type
inherited

The type of matrix elements (a field type).

Definition at line 48 of file factorization.hh.

◆ Options

using Kaskade::Factorization< Scalar >::Options = FactorizationOptions
inherited

Definition at line 50 of file factorization.hh.

Constructor & Destructor Documentation

◆ PardisoFactorization()

template<class Scalar , class SparseIndexInt = int, class DIL = int>
Kaskade::PardisoFactorization< Scalar, SparseIndexInt, DIL >::PardisoFactorization ( SparseIndexInt  n,
std::vector< SparseIndexInt >const &  ridx,
std::vector< SparseIndexInt >const &  cidx,
std::vector< Scalar >const &  values,
MatrixProperties  property = MatrixProperties::GENERAL 
)

Construction is factorization! Input matrix in triplet format.

Parameters
nsize of the (square) matrix, i.e. the number of rows
ridxrow indices
cidxcolumn indices
valuesentry values
propertymatrix property

◆ ~PardisoFactorization()

template<class Scalar , class SparseIndexInt = int, class DIL = int>
Kaskade::PardisoFactorization< Scalar, SparseIndexInt, DIL >::~PardisoFactorization ( )

Member Function Documentation

◆ getVerbose()

int Kaskade::Factorization< Scalar >::getVerbose ( ) const
inlineinherited

Definition at line 115 of file factorization.hh.

◆ info()

Info const & Kaskade::Factorization< Scalar >::info ( ) const
inlineinherited

Definition at line 117 of file factorization.hh.

◆ operator=()

template<class Scalar , class SparseIndexInt = int, class DIL = int>
PardisoFactorization & Kaskade::PardisoFactorization< Scalar, SparseIndexInt, DIL >::operator= ( PardisoFactorization< Scalar, SparseIndexInt, DIL > &&  other)

◆ setVerbose()

void Kaskade::Factorization< Scalar >::setVerbose ( int  verbose_)
inlineinherited

Definition at line 114 of file factorization.hh.

◆ size()

virtual size_t Kaskade::Factorization< Scalar >::size ( ) const
pure virtualinherited

reports the dimension of the system

◆ solve() [1/6]

virtual void Kaskade::Factorization< Scalar >::solve ( field_type b) const
pure virtualinherited

Solves the system \( Ax=b \) for the given right hand side \( b \).

Parameters
[in,out]bright hand side, is overwritten with the solution \( x \). This must point to a memory region of length of system dimension.

◆ solve() [2/6]

virtual void Kaskade::Factorization< Scalar >::solve ( Scalar const *  b,
Scalar *  x,
bool  transposed = false 
) const
pure virtualinherited

Solves the system \( Ax=b \) for the given right hand side \( b \).

Parameters
[in]bthe right hand side
[out]xthe solution. x must point to a memory region of length of system dimension.

◆ solve() [3/6]

template<class Scalar , class SparseIndexInt = int, class DIL = int>
void Kaskade::PardisoFactorization< Scalar, SparseIndexInt, DIL >::solve ( std::vector< Scalar > &  b) const
inlinevirtual

Solves the system \( Ax=b \) for the given right hand side \( b \).

Parameters
[in,out]bright hand side, is overwritten with the solution \( x \).

Reimplemented from Kaskade::Factorization< Scalar, int >.

Definition at line 65 of file linalg/pardiso_solve.hh.

Referenced by Kaskade::PardisoFactorization< Scalar, SparseIndexInt, DIL >::solve().

◆ solve() [4/6]

template<class Scalar , class SparseIndexInt = int, class DIL = int>
void Kaskade::PardisoFactorization< Scalar, SparseIndexInt, DIL >::solve ( std::vector< Scalar > &  b,
int  n,
bool  transposed = false 
) const
inline

Definition at line 67 of file linalg/pardiso_solve.hh.

◆ solve() [5/6]

template<class Scalar , class SparseIndexInt = int, class DIL = int>
virtual void Kaskade::PardisoFactorization< Scalar, SparseIndexInt, DIL >::solve ( std::vector< Scalar > const &  b,
std::vector< Scalar > &  x,
bool  transposed = false 
) const
inlinevirtual

Solves the system \( Ax=b \) for the given right hand side \( b \).

Parameters
[in]bthe right hand side
[out]xthe solution. x is resized if needed.

Reimplemented from Kaskade::Factorization< Scalar, int >.

Definition at line 62 of file linalg/pardiso_solve.hh.

◆ solve() [6/6]

template<class Scalar , class SparseIndexInt = int, class DIL = int>
virtual void Kaskade::PardisoFactorization< Scalar, SparseIndexInt, DIL >::solve ( std::vector< Scalar > const &  b,
std::vector< Scalar > &  x,
int  n,
bool  transposed = false 
) const
virtual

Solves the system for the given right hand side

  • b.
  • x is resized to the number of matrix columns.

Referenced by Kaskade::PardisoFactorization< Scalar, SparseIndexInt, DIL >::solve().

◆ swap()

template<class Scalar , class SparseIndexInt = int, class DIL = int>
void Kaskade::PardisoFactorization< Scalar, SparseIndexInt, DIL >::swap ( PardisoFactorization< Scalar, SparseIndexInt, DIL > &  other)

Member Data Documentation

◆ info_

Info Kaskade::Factorization< Scalar >::info_
protectedinherited

Definition at line 126 of file factorization.hh.

◆ options

Options Kaskade::Factorization< Scalar >::options
protectedinherited

Definition at line 125 of file factorization.hh.


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