Feel++  0.91.4
Protected Attributes
Feel::Preconditioner< T > Class Template Reference

base class for preconditioner More...

#include <preconditioner.hpp>

Inheritance diagram for Feel::Preconditioner< T >:
Feel::PreconditionerPetsc< T >

List of all members.

Public Types

Typedefs
typedef Preconditioner< T > preconditioner_type
typedef boost::shared_ptr
< Preconditioner< T > > 
preconditioner_ptrtype
typedef boost::shared_ptr
< MatrixSparse< T > > 
sparse_matrix_ptrtype
typedef boost::shared_ptr
< Vector< T > > 
vector_ptrtype

Public Member Functions

Operator overloads
Preconditioneroperator= (Preconditioner const &o)
 copy operator
Accessors
bool initialized () const
virtual void apply (const Vector< T > &x, Vector< T > &y)=0
void apply (vector_ptrtype const &x, vector_ptrtype &y)
virtual void clear ()
PreconditionerType type () const
Mutators
void setMatrix (sparse_matrix_ptrtype mat)
void setType (const PreconditionerType pct)

Protected Attributes

sparse_matrix_ptrtype M_matrix
PreconditionerType M_preconditioner_type
bool M_is_initialized
mpi::communicator M_comm

Constructors, destructor

 Preconditioner ()
 default constructor
 Preconditioner (Preconditioner const &o)
 copy constructor
 ~Preconditioner ()
 destructor
virtual void init ()
static preconditioner_ptrtype build (BackendType=BACKEND_PETSC)

Detailed Description

template<typename T>
class Feel::Preconditioner< T >

base class for preconditioner

Author:
Christophe Prud'homme
See also:

Member Function Documentation

template<typename T>
virtual void Feel::Preconditioner< T >::apply ( const Vector< T > &  x,
Vector< T > &  y 
) [pure virtual]

Computes the preconditioned vector "y" based on input "x". Usually by solving Py=x to get the action of P^-1 x.

Implemented in Feel::PreconditionerPetsc< T >.

Referenced by Feel::Preconditioner< T >::apply().

template<typename T>
void Feel::Preconditioner< T >::apply ( vector_ptrtype const &  x,
vector_ptrtype &  y 
) [inline]

Computes the preconditioned vector "y" based on input "x". Usually by solving Py=x to get the action of P^-1 x.

References Feel::Preconditioner< T >::apply().

template<typename T>
virtual void Feel::Preconditioner< T >::clear ( ) [inline, virtual]

Release all memory and clear data structures.

Reimplemented in Feel::PreconditionerPetsc< T >.

template<typename T>
virtual void Feel::Preconditioner< T >::init ( ) [inline, virtual]

Initialize data structures if not done so already.

Reimplemented in Feel::PreconditionerPetsc< T >.

template<typename T>
bool Feel::Preconditioner< T >::initialized ( ) const [inline]
Returns:
true if the data structures are initialized, false otherwise.

References Feel::Preconditioner< T >::M_is_initialized.

template<typename T >
FEELPP_STRONG_INLINE void Feel::Preconditioner< T >::setMatrix ( sparse_matrix_ptrtype  mat)

Sets the matrix P to be preconditioned.

template<typename T >
void Feel::Preconditioner< T >::setType ( const PreconditionerType  pct)

Sets the type of preconditioner to use.

template<typename T>
PreconditionerType Feel::Preconditioner< T >::type ( ) const [inline]

Returns the type of preconditioner to use.

References Feel::Preconditioner< T >::M_preconditioner_type.


Member Data Documentation

template<typename T>
bool Feel::Preconditioner< T >::M_is_initialized [protected]

Flag indicating if the data structures have been initialized.

Referenced by Feel::Preconditioner< T >::initialized(), and Feel::Preconditioner< T >::operator=().

template<typename T>
sparse_matrix_ptrtype Feel::Preconditioner< T >::M_matrix [protected]

The matrix P... ie the matrix to be preconditioned. This is often the actual system matrix of a linear sytem.

Referenced by Feel::Preconditioner< T >::operator=().

template<typename T>
PreconditionerType Feel::Preconditioner< T >::M_preconditioner_type [protected]

Enum statitng with type of preconditioner to use.

Referenced by Feel::Preconditioner< T >::operator=(), and Feel::Preconditioner< T >::type().