PreconditionIdentity Class Reference
[Preconditioners]

Inheritance diagram for PreconditionIdentity:

Inheritance graph
[legend]

List of all members.

Public Member Functions

template<class MATRIX>
void initialize (const MATRIX &matrix, const AdditionalData &additional_data=AdditionalData())
template<class VECTOR>
void vmult (VECTOR &, const VECTOR &) const
template<class VECTOR>
void Tvmult (VECTOR &, const VECTOR &) const
template<class VECTOR>
void vmult_add (VECTOR &, const VECTOR &) const
template<class VECTOR>
void Tvmult_add (VECTOR &, const VECTOR &) const
void clear ()

Classes

struct  AdditionalData


Detailed Description

No preconditioning. This class helps you, if you want to use a linear solver without preconditioning. All solvers in LAC require a preconditioner. Therefore, you must use the identity provided here to avoid preconditioning. It can be used in the following way:

  SolverControl           solver_control (1000, 1e-12);
  SolverCG<>              cg (solver_control);
  cg.solve (system_matrix, solution, system_rhs,
	    PreconditionIdentity());
 

See the step-3 tutorial program for an example and additional explanations.

Alternatively, the IdentityMatrix class can be used to precondition in this way.

Author:
Guido Kanschat, 1999

Member Function Documentation

template<class MATRIX>
void PreconditionIdentity::initialize ( const MATRIX &  matrix,
const AdditionalData additional_data = AdditionalData() 
) [inline]

The matrix argument is ignored and here just for compatibility with more complex preconditioners.

template<class VECTOR>
void PreconditionIdentity::vmult ( VECTOR &  ,
const VECTOR &   
) const [inline]

Apply preconditioner.

template<class VECTOR>
void PreconditionIdentity::Tvmult ( VECTOR &  ,
const VECTOR &   
) const [inline]

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

template<class VECTOR>
void PreconditionIdentity::vmult_add ( VECTOR &  ,
const VECTOR &   
) const [inline]

Apply preconditioner, adding to the previous value.

template<class VECTOR>
void PreconditionIdentity::Tvmult_add ( VECTOR &  ,
const VECTOR &   
) const [inline]

Apply transpose preconditioner, adding. Since this is the identity, this function is the same as vmult_add().

void PreconditionIdentity::clear (  )  [inline]

This function is only present to provide the interface of a precondtioner to be handed to a smoother. This does nothing.


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

deal.II documentation generated on Wed Jul 28 23:06:37 2010 by doxygen 1.5.6