Public Member Functions | |
InverseMatrixRichardson (SolverControl &control, VectorMemory< VECTOR > &mem) | |
~InverseMatrixRichardson () | |
template<class MATRIX , class PRECONDITION > | |
void | initialize (const MATRIX &, const PRECONDITION &) |
SolverControl & | control () const |
void | vmult (VECTOR &, const VECTOR &) const |
void | vmult_add (VECTOR &, const VECTOR &) const |
void | Tvmult (VECTOR &, const VECTOR &) const |
void | Tvmult_add (VECTOR &, const VECTOR &) const |
Private Attributes | |
VectorMemory< VECTOR > & | mem |
SolverRichardson< VECTOR > | solver |
PointerMatrixBase< VECTOR > * | matrix |
PointerMatrixBase< VECTOR > * | precondition |
Inverse matrix computed approximately by using the SolverRichardson iterative solver. In particular, the function SolverRichardson::Tsolve() allows for the implementation of transpose matrix vector products.
The functions vmult() and Tvmult() appoximate the inverse iteratively starting with the vector dst
. Functions vmult_add() and Tvmult_add() start the iteration with a zero vector.
<float> and <double>
; others can be generated in application programs (see the section on Template instantiations in the manual).InverseMatrixRichardson< VECTOR >::InverseMatrixRichardson | ( | SolverControl & | control, | |
VectorMemory< VECTOR > & | mem | |||
) |
Constructor, initializing the solver with a control and memory object. The inverted matrix and the preconditioner are added in initialize().
InverseMatrixRichardson< VECTOR >::~InverseMatrixRichardson | ( | ) |
Since we use two pointers, we must implement a destructor.
void InverseMatrixRichardson< VECTOR >::initialize | ( | const MATRIX & | m, | |
const PRECONDITION & | p | |||
) | [inline] |
Initialization function. Provide a solver object, a matrix, and another preconditioner for this.
References InverseMatrixRichardson< VECTOR >::matrix, and InverseMatrixRichardson< VECTOR >::precondition.
SolverControl& InverseMatrixRichardson< VECTOR >::control | ( | ) | const |
Access to the SolverControl object used by the solver.
void InverseMatrixRichardson< VECTOR >::vmult | ( | VECTOR & | , | |
const VECTOR & | ||||
) | const |
Execute solver.
void InverseMatrixRichardson< VECTOR >::vmult_add | ( | VECTOR & | , | |
const VECTOR & | ||||
) | const |
Execute solver.
void InverseMatrixRichardson< VECTOR >::Tvmult | ( | VECTOR & | , | |
const VECTOR & | ||||
) | const |
Execute transpose solver.
void InverseMatrixRichardson< VECTOR >::Tvmult_add | ( | VECTOR & | , | |
const VECTOR & | ||||
) | const |
Execute transpose solver.
VectorMemory<VECTOR>& InverseMatrixRichardson< VECTOR >::mem [private] |
A reference to the provided VectorMemory object.
SolverRichardson<VECTOR> InverseMatrixRichardson< VECTOR >::solver [mutable, private] |
The solver object.
PointerMatrixBase<VECTOR>* InverseMatrixRichardson< VECTOR >::matrix [private] |
The matrix in use.
Referenced by InverseMatrixRichardson< VECTOR >::initialize().
PointerMatrixBase<VECTOR>* InverseMatrixRichardson< VECTOR >::precondition [private] |
The preconditioner to use.
Referenced by InverseMatrixRichardson< VECTOR >::initialize().