Classes | Public Member Functions

PreconditionIdentity Class Reference
[Preconditioners and Relaxation Operators]

Inheritance diagram for PreconditionIdentity:
Inheritance graph
[legend]

List of all members.

Classes

struct  AdditionalData

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 ()

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

Definition at line 55 of file precondition.h.


Member Function Documentation

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

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

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

Apply preconditioner.

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

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

Apply preconditioner, adding to the previous value.

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

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 preconditioner to be handed to a smoother. This does nothing.

Definition at line 125 of file precondition.h.


The documentation for this class was generated from the following file:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines

deal.II documentation generated on Fri Feb 3 2012 06:04:10 by doxygen 1.7.2