dune-istl  2.9.0
Public Types | Public Member Functions | Protected Types | Protected Member Functions | List of all members
Dune::LDL< BCRSMatrix< FieldMatrix< T, n, m >, A > > Class Template Referenceabstract

The LDL direct sparse solver for matrices of type BCRSMatrix. More...

#include <dune/istl/ldl.hh>

Inheritance diagram for Dune::LDL< BCRSMatrix< FieldMatrix< T, n, m >, A > >:
Inheritance graph

Public Types

typedef Dune::BCRSMatrix< FieldMatrix< T, n, m >, A > Matrix
 The matrix type. More...
 
typedef Dune::BCRSMatrix< FieldMatrix< T, n, m >, A > matrix_type
 
typedef Dune::ISTL::Impl::BCCSMatrix< T, int > LDLMatrix
 The corresponding SuperLU Matrix type. More...
 
typedef ISTL::Impl::BCCSMatrixInitializer< BCRSMatrix< FieldMatrix< T, n, m >, A >, int > MatrixInitializer
 Type of an associated initializer class. More...
 
typedef Dune::BlockVector< FieldVector< T, m >, typename std::allocator_traits< A >::template rebind_alloc< FieldVector< T, m > > > domain_type
 The type of the domain of the solver. More...
 
typedef Dune::BlockVector< FieldVector< T, n >, typename std::allocator_traits< A >::template rebind_alloc< FieldVector< T, n > > > range_type
 The type of the range of the solver. More...
 
typedef X::field_type field_type
 The field type of the operator. More...
 
typedef FieldTraits< field_type >::real_type real_type
 The real type of the field type (is the same if using real numbers, but differs for std::complex) More...
 
typedef Simd::Scalar< real_typescalar_real_type
 scalar type underlying the field_type More...
 

Public Member Functions

virtual SolverCategory::Category category () const
 Category of the solver (see SolverCategory::Category) More...
 
 LDL (const Matrix &matrix, int verbose=0)
 Construct a solver object from a BCRSMatrix. More...
 
 LDL (const Matrix &matrix, int verbose, bool)
 Constructor for compatibility with SuperLU standard constructor. More...
 
 LDL (const Matrix &matrix, const ParameterTree &config)
 Constructs the LDL solver. More...
 
 LDL ()
 Default constructor. More...
 
virtual ~LDL ()
 Default constructor. More...
 
virtual void apply (domain_type &x, range_type &b, InverseOperatorResult &res)
 Apply inverse operator,. More...
 
virtual void apply (domain_type &x, range_type &b, [[maybe_unused]] double reduction, InverseOperatorResult &res)
 apply inverse operator, with given convergence criteria. More...
 
void apply (T *x, T *b)
 Additional apply method with c-arrays in analogy to superlu. More...
 
void setOption ([[maybe_unused]] unsigned int option, [[maybe_unused]] double value)
 
void setMatrix (const Matrix &matrix)
 Initialize data from given matrix. More...
 
template<class S >
void setSubMatrix (const Matrix &matrix, const S &rowIndexSet)
 
void setVerbosity (int v)
 Sets the verbosity level for the solver. More...
 
LDLMatrixgetInternalMatrix ()
 Return the column compress matrix. More...
 
void free ()
 Free allocated space. More...
 
const char * name ()
 Get method name. More...
 
double * getD ()
 Get factorization diagonal matrix D. More...
 
int * getLp ()
 Get factorization Lp. More...
 
int * getLi ()
 Get factorization Li. More...
 
double * getLx ()
 Get factorization Lx. More...
 
virtual void apply (BlockVector< FieldVector< T, m >, std::allocator_traits< A >::template rebind_alloc< FieldVector< T, m > > > &x, BlockVector< FieldVector< T, n >, std::allocator_traits< A >::template rebind_alloc< FieldVector< T, n > > > &b, InverseOperatorResult &res)=0
 Apply inverse operator,. More...
 
virtual void apply (BlockVector< FieldVector< T, m >, std::allocator_traits< A >::template rebind_alloc< FieldVector< T, m > > > &x, BlockVector< FieldVector< T, n >, std::allocator_traits< A >::template rebind_alloc< FieldVector< T, n > > > &b, double reduction, InverseOperatorResult &res)=0
 apply inverse operator, with given convergence criteria. More...
 

Protected Types

enum  
 

Protected Member Functions

void printHeader (std::ostream &s) const
 helper function for printing header of solver output More...
 
void printOutput (std::ostream &s, const CountType &iter, const DataType &norm, const DataType &norm_old) const
 helper function for printing solver output More...
 
void printOutput (std::ostream &s, const CountType &iter, const DataType &norm) const
 helper function for printing solver output More...
 

Detailed Description

template<typename T, typename A, int n, int m>
class Dune::LDL< BCRSMatrix< FieldMatrix< T, n, m >, A > >

The LDL direct sparse solver for matrices of type BCRSMatrix.

Specialization for the Dune::BCRSMatrix. LDL will always go double precision.

Template Parameters
TNumber type. Only double is supported
ASTL-compatible allocator type
nNumber of rows in a matrix block
mNumber of columns in a matrix block
Note
This will only work if dune-istl has been configured to use LDL

Member Typedef Documentation

◆ field_type

typedef X::field_type Dune::InverseOperator< BlockVector< FieldVector< T, m >, std::allocator_traits< A >::template rebind_alloc< FieldVector< T, m > > > , BlockVector< FieldVector< T, n >, std::allocator_traits< A >::template rebind_alloc< FieldVector< T, n > > > >::field_type
inherited

The field type of the operator.

◆ real_type

typedef FieldTraits<field_type>::real_type Dune::InverseOperator< BlockVector< FieldVector< T, m >, std::allocator_traits< A >::template rebind_alloc< FieldVector< T, m > > > , BlockVector< FieldVector< T, n >, std::allocator_traits< A >::template rebind_alloc< FieldVector< T, n > > > >::real_type
inherited

The real type of the field type (is the same if using real numbers, but differs for std::complex)

◆ scalar_real_type

typedef Simd::Scalar<real_type> Dune::InverseOperator< BlockVector< FieldVector< T, m >, std::allocator_traits< A >::template rebind_alloc< FieldVector< T, m > > > , BlockVector< FieldVector< T, n >, std::allocator_traits< A >::template rebind_alloc< FieldVector< T, n > > > >::scalar_real_type
inherited

scalar type underlying the field_type

Member Enumeration Documentation

◆ anonymous enum

anonymous enum
protectedinherited

Member Function Documentation

◆ apply() [1/2]

virtual void Dune::InverseOperator< BlockVector< FieldVector< T, m >, std::allocator_traits< A >::template rebind_alloc< FieldVector< T, m > > > , BlockVector< FieldVector< T, n >, std::allocator_traits< A >::template rebind_alloc< FieldVector< T, n > > > >::apply ( BlockVector< FieldVector< T, m >, std::allocator_traits< A >::template rebind_alloc< FieldVector< T, m > > > &  x,
BlockVector< FieldVector< T, n >, std::allocator_traits< A >::template rebind_alloc< FieldVector< T, n > > > &  b,
double  reduction,
InverseOperatorResult res 
)
pure virtualinherited

apply inverse operator, with given convergence criteria.

Warning
Right hand side b may be overwritten!
Parameters
xThe left hand side to store the result in.
bThe right hand side
reductionThe minimum defect reduction to achieve.
resObject to store the statistics about applying the operator.
Exceptions
SolverAbortWhen the solver detects a problem and cannot continue

◆ apply() [2/2]

virtual void Dune::InverseOperator< BlockVector< FieldVector< T, m >, std::allocator_traits< A >::template rebind_alloc< FieldVector< T, m > > > , BlockVector< FieldVector< T, n >, std::allocator_traits< A >::template rebind_alloc< FieldVector< T, n > > > >::apply ( BlockVector< FieldVector< T, m >, std::allocator_traits< A >::template rebind_alloc< FieldVector< T, m > > > &  x,
BlockVector< FieldVector< T, n >, std::allocator_traits< A >::template rebind_alloc< FieldVector< T, n > > > &  b,
InverseOperatorResult res 
)
pure virtualinherited

Apply inverse operator,.

Warning
Note: right hand side b may be overwritten!
Parameters
xThe left hand side to store the result in.
bThe right hand side
resObject to store the statistics about applying the operator.
Exceptions
SolverAbortWhen the solver detects a problem and cannot continue

◆ printHeader()

void Dune::InverseOperator< BlockVector< FieldVector< T, m >, std::allocator_traits< A >::template rebind_alloc< FieldVector< T, m > > > , BlockVector< FieldVector< T, n >, std::allocator_traits< A >::template rebind_alloc< FieldVector< T, n > > > >::printHeader ( std::ostream &  s) const
inlineprotectedinherited

helper function for printing header of solver output

◆ printOutput() [1/2]

void Dune::InverseOperator< BlockVector< FieldVector< T, m >, std::allocator_traits< A >::template rebind_alloc< FieldVector< T, m > > > , BlockVector< FieldVector< T, n >, std::allocator_traits< A >::template rebind_alloc< FieldVector< T, n > > > >::printOutput ( std::ostream &  s,
const CountType &  iter,
const DataType &  norm 
) const
inlineprotectedinherited

helper function for printing solver output

◆ printOutput() [2/2]

void Dune::InverseOperator< BlockVector< FieldVector< T, m >, std::allocator_traits< A >::template rebind_alloc< FieldVector< T, m > > > , BlockVector< FieldVector< T, n >, std::allocator_traits< A >::template rebind_alloc< FieldVector< T, n > > > >::printOutput ( std::ostream &  s,
const CountType &  iter,
const DataType &  norm,
const DataType &  norm_old 
) const
inlineprotectedinherited

helper function for printing solver output


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