Belos::StatusTest< ScalarType, MV, OP > Class Template Reference

A pure virtual class for defining the status tests for the Belos iterative solvers. More...

#include <BelosStatusTest.hpp>

Inheritance diagram for Belos::StatusTest< ScalarType, MV, OP >:

Inheritance graph
[legend]
List of all members.

Public Member Functions

Constructors/destructors
 StatusTest ()
 Constructor.
virtual ~StatusTest ()
 Destructor.
Status methods
virtual StatusType CheckStatus (IterativeSolver< ScalarType, MV, OP > *iSolver)=0
 Check convergence status: Unconverged, Converged, Failed.
virtual StatusType GetStatus () const =0
 Return the result of the most recent CheckStatus call.
Reset methods
virtual void Reset ()=0
 Informs the convergence test that it should reset its internal configuration to the initialized state.
Attribute methods
virtual bool ResidualVectorRequired () const =0
 Indicates if residual vector is required by this convergence test.
Print methods
virtual ostream & Print (ostream &os, int indent=0) const =0
 Output formatted description of stopping test to output stream.
virtual void PrintStatus (ostream &os, StatusType type) const
 Output the result of the most recent CheckStatus call.

Detailed Description

template<class ScalarType, class MV, class OP>
class Belos::StatusTest< ScalarType, MV, OP >

A pure virtual class for defining the status tests for the Belos iterative solvers.

Belos::StatusTest is an interface that can be implemented to create convergence tests for all Belos solvers. Almost any kind of test can be expressed using this mechanism, including composite tests (see Belos::StatusTestCombo).

Definition at line 55 of file BelosStatusTest.hpp.


Constructor & Destructor Documentation

template<class ScalarType, class MV, class OP>
Belos::StatusTest< ScalarType, MV, OP >::StatusTest  )  [inline]
 

Constructor.

Definition at line 62 of file BelosStatusTest.hpp.

template<class ScalarType, class MV, class OP>
virtual Belos::StatusTest< ScalarType, MV, OP >::~StatusTest  )  [inline, virtual]
 

Destructor.

Definition at line 65 of file BelosStatusTest.hpp.


Member Function Documentation

template<class ScalarType, class MV, class OP>
virtual StatusType Belos::StatusTest< ScalarType, MV, OP >::CheckStatus IterativeSolver< ScalarType, MV, OP > *  iSolver  )  [pure virtual]
 

Check convergence status: Unconverged, Converged, Failed.

This method checks to see if the convergence criteria are met. The calling routine may pass in the current native residual vector (the one naturally produced as part of the iterative method) or a pre-computed estimate of the two-norm of the current residual, or both or neither. The calling routine should also indicate if the solution of the linear problem has been updated to be compatible with the residual. Some methods, such as GMRES do not update the solution at each iteration.

Returns:
Belos::StatusType: Unconverged, Converged or Failed.

Implemented in Belos::StatusTestCombo< ScalarType, MV, OP >, Belos::StatusTestMaxIters< ScalarType, MV, OP >, Belos::StatusTestMaxRestarts< ScalarType, MV, OP >, Belos::StatusTestOutputter< ScalarType, MV, OP >, and Belos::StatusTestResNorm< ScalarType, MV, OP >.

template<class ScalarType, class MV, class OP>
virtual StatusType Belos::StatusTest< ScalarType, MV, OP >::GetStatus  )  const [pure virtual]
 

Return the result of the most recent CheckStatus call.

Implemented in Belos::StatusTestCombo< ScalarType, MV, OP >, Belos::StatusTestMaxIters< ScalarType, MV, OP >, Belos::StatusTestMaxRestarts< ScalarType, MV, OP >, Belos::StatusTestOutputter< ScalarType, MV, OP >, and Belos::StatusTestResNorm< ScalarType, MV, OP >.

template<class ScalarType, class MV, class OP>
virtual void Belos::StatusTest< ScalarType, MV, OP >::Reset  )  [pure virtual]
 

Informs the convergence test that it should reset its internal configuration to the initialized state.

This is necessary for the case when the status test is being reused by another solver or for another linear problem. The status test may have information that pertains to a particular linear system. The internal information will be reset back to the initialized state. The user specified information that the convergence test uses will remain.

Implemented in Belos::StatusTestCombo< ScalarType, MV, OP >, Belos::StatusTestMaxIters< ScalarType, MV, OP >, Belos::StatusTestMaxRestarts< ScalarType, MV, OP >, Belos::StatusTestOutputter< ScalarType, MV, OP >, and Belos::StatusTestResNorm< ScalarType, MV, OP >.

template<class ScalarType, class MV, class OP>
virtual bool Belos::StatusTest< ScalarType, MV, OP >::ResidualVectorRequired  )  const [pure virtual]
 

Indicates if residual vector is required by this convergence test.

If this method returns true, then the ResidualVector argument to the Converged() method will defined. If this method returns false, then the ResidualVector may not be defined when Converged() is called. Some iterative methods do not explicitly construct the residual vector at each iteration. Thus, if this vector is not required, this vector will not need to be constructed if this method returns false.

Implemented in Belos::StatusTestCombo< ScalarType, MV, OP >, Belos::StatusTestMaxIters< ScalarType, MV, OP >, Belos::StatusTestMaxRestarts< ScalarType, MV, OP >, Belos::StatusTestOutputter< ScalarType, MV, OP >, and Belos::StatusTestResNorm< ScalarType, MV, OP >.

template<class ScalarType, class MV, class OP>
virtual ostream& Belos::StatusTest< ScalarType, MV, OP >::Print ostream &  os,
int  indent = 0
const [pure virtual]
 

Output formatted description of stopping test to output stream.

Implemented in Belos::StatusTestCombo< ScalarType, MV, OP >, Belos::StatusTestMaxIters< ScalarType, MV, OP >, Belos::StatusTestMaxRestarts< ScalarType, MV, OP >, Belos::StatusTestOutputter< ScalarType, MV, OP >, and Belos::StatusTestResNorm< ScalarType, MV, OP >.

template<class ScalarType, class MV, class OP>
virtual void Belos::StatusTest< ScalarType, MV, OP >::PrintStatus ostream &  os,
StatusType  type
const [inline, virtual]
 

Output the result of the most recent CheckStatus call.

Definition at line 115 of file BelosStatusTest.hpp.


The documentation for this class was generated from the following file:
Generated on Thu Sep 18 12:30:13 2008 for Belos by doxygen 1.3.9.1