PreconditionSSOR< MATRIX > Class Template Reference
[Preconditioners]

Inheritance diagram for PreconditionSSOR< MATRIX >:
Inheritance graph
[legend]

List of all members.

Public Types

typedef PreconditionRelaxation
< MATRIX > 
BaseClass

Public Member Functions

void initialize (const MATRIX &A, typename BaseClass::AdditionalData parameters=typename BaseClass::AdditionalData())
template<class VECTOR >
void vmult (VECTOR &, const VECTOR &) const
template<class VECTOR >
void Tvmult (VECTOR &, const VECTOR &) const

Private Attributes

std::vector< unsigned intpos_right_of_diagonal

Detailed Description

template<class MATRIX = SparseMatrix<double>>
class PreconditionSSOR< MATRIX >

SSOR preconditioner using matrix built-in function. The MATRIX class used is required to have a function precondition_SSOR(VECTOR&, const VECTOR&, double)

     // Declare related objects

 SparseMatrix<double> A;
 Vector<double> x;
 Vector<double> b;
 SolverCG<> solver(...);

 //...initialize and build A

     // Define and initialize preconditioner

 PreconditionSSOR<SparseMatrix<double> > precondition;
 precondition.initialize (A, .6);

 solver.solve (A, x, b, precondition);
Author:
Guido Kanschat, 2000

Member Typedef Documentation

template<class MATRIX = SparseMatrix<double>>
typedef PreconditionRelaxation<MATRIX> PreconditionSSOR< MATRIX >::BaseClass

A typedef to the base class.


Member Function Documentation

template<class MATRIX = SparseMatrix<double>>
void PreconditionSSOR< MATRIX >::initialize ( const MATRIX &  A,
typename BaseClass::AdditionalData  parameters = typename BaseClass::AdditionalData() 
)

Initialize matrix and relaxation parameter. The matrix is just stored in the preconditioner object. The relaxation parameter should be larger than zero and smaller than 2 for numerical reasons. It defaults to 1.

Reimplemented from PreconditionRelaxation< MATRIX >.

template<class MATRIX = SparseMatrix<double>>
template<class VECTOR >
void PreconditionSSOR< MATRIX >::vmult ( VECTOR &  ,
const VECTOR &   
) const [inline]

Apply preconditioner.

template<class MATRIX = SparseMatrix<double>>
template<class VECTOR >
void PreconditionSSOR< MATRIX >::Tvmult ( VECTOR &  ,
const VECTOR &   
) const [inline]

Apply transpose preconditioner. Since this is a symmetric preconditioner, this function is the same as vmult().


Member Data Documentation

template<class MATRIX = SparseMatrix<double>>
std::vector<unsigned int> PreconditionSSOR< MATRIX >::pos_right_of_diagonal [private]

An array that stores for each matrix row where the first position after the diagonal is located.


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

deal.II documentation generated on Mon Nov 23 22:58:01 2009 by doxygen 1.6.1