Anasazi::Eigensolver< ScalarType, MV, OP > Class Template Reference

The Eigensolver is a templated virtual base class that defines the basic interface that any eigensolver will support. More...

#include <AnasaziEigensolverDecl.hpp>

Inheritance diagram for Anasazi::Eigensolver< ScalarType, MV, OP >:

Anasazi::BlockDavidson< ScalarType, MV, OP > Anasazi::BlockKrylovSchur< ScalarType, MV, OP > Anasazi::LOBPCG< ScalarType, MV, OP > List of all members.

Public Member Functions

Constructors/Destructor
 Eigensolver ()
 Default Constructor.
 Eigensolver (const Teuchos::RefCountPtr< Eigenproblem< ScalarType, MV, OP > > &problem, const Teuchos::RefCountPtr< SortManager< ScalarType, MV, OP > > &sorter, const Teuchos::RefCountPtr< OutputManager< ScalarType > > &printer, const Teuchos::RefCountPtr< StatusTest< ScalarType, MV, OP > > &tester, const Teuchos::RefCountPtr< OrthoManager< ScalarType, MV > > &ortho, Teuchos::ParameterList &params)
 Basic Constructor.
virtual ~Eigensolver ()
 Destructor.
Solver methods
virtual void iterate ()=0
 This method performs eigensolvers iterations until the status test indicates the need to stop or an error occurs (in which case, an exception is thrown).
virtual void initialize ()=0
 Initialize the solver with the initial vectors from the eigenproblem or random data.
Status methods
virtual int getNumIters () const =0
 Get the current iteration count.
virtual void resetNumIters ()=0
 Reset the iteration count.
virtual Teuchos::RefCountPtr<
const MV > 
getRitzVectors ()=0
 Get the Ritz vectors from the previous iteration. These are indexed using getRitzIndex().
virtual std::vector< Value<
ScalarType > > 
getRitzValues ()=0
 Get the Ritz values from the previous iteration.
virtual std::vector< int > getRitzIndex ()=0
 Get the index used for indexing the compressed storage used for Ritz vectors for real, non-Hermitian problems.
virtual std::vector< typename
Teuchos::ScalarTraits< ScalarType
>::magnitudeType > 
getResNorms ()=0
 Get the current residual norms.
virtual std::vector< typename
Teuchos::ScalarTraits< ScalarType
>::magnitudeType > 
getRes2Norms ()=0
virtual std::vector< typename
Teuchos::ScalarTraits< ScalarType
>::magnitudeType > 
getRitzRes2Norms ()=0
virtual int getCurSubspaceDim () const =0
 Get the dimension of the search subspace used to generate the current eigenvectors and eigenvalues.
virtual int getMaxSubspaceDim () const =0
 Get the maximum dimension allocated for the search subspace.
Accessor methods
virtual const Eigenproblem<
ScalarType, MV, OP > & 
getProblem () const =0
 Get a constant reference to the eigenvalue problem.
virtual int getBlockSize () const =0
 Get the blocksize to be used by the iterative solver in solving this eigenproblem.
virtual void setBlockSize (int blockSize)=0
 Set the blocksize to be used by the iterative solver in solving this eigenproblem.
virtual void setAuxVecs (const Teuchos::Array< Teuchos::RefCountPtr< const MV > > &auxvecs)=0
 Set the auxiliary vectors for the solver.
virtual Teuchos::Array< Teuchos::RefCountPtr<
const MV > > 
getAuxVecs () const =0
 Get the auxiliary vectors for the solver.
virtual bool isInitialized ()=0
 States whether the solver has been initialized or not.
Output methods
virtual void currentStatus (ostream &os)=0
 This method requests that the solver print out its current status to screen.

Detailed Description

template<class ScalarType, class MV, class OP>
class Anasazi::Eigensolver< ScalarType, MV, OP >

The Eigensolver is a templated virtual base class that defines the basic interface that any eigensolver will support.

This interface is mainly concerned with providing a set of eigensolver status method that can be requested from any eigensolver by an StatusTest object.

Definition at line 54 of file AnasaziEigensolver.hpp.


Constructor & Destructor Documentation

template<class ScalarType, class MV, class OP>
Anasazi::Eigensolver< ScalarType, MV, OP >::Eigensolver  )  [inline]
 

Default Constructor.

Definition at line 62 of file AnasaziEigensolver.hpp.

template<class ScalarType, class MV, class OP>
Anasazi::Eigensolver< ScalarType, MV, OP >::Eigensolver const Teuchos::RefCountPtr< Eigenproblem< ScalarType, MV, OP > > &  problem,
const Teuchos::RefCountPtr< SortManager< ScalarType, MV, OP > > &  sorter,
const Teuchos::RefCountPtr< OutputManager< ScalarType > > &  printer,
const Teuchos::RefCountPtr< StatusTest< ScalarType, MV, OP > > &  tester,
const Teuchos::RefCountPtr< OrthoManager< ScalarType, MV > > &  ortho,
Teuchos::ParameterList params
 

Basic Constructor.

This constructor, implemented by all Anasazi eigensolvers, takes an Anasazi::Eigenproblem, Anasazi::SortManager, Anasazi::OutputManager, and Teuchos::ParameterList as input. These four arguments are sufficient enough for constructing any Anasazi::Eigensolver object.

template<class ScalarType, class MV, class OP>
virtual Anasazi::Eigensolver< ScalarType, MV, OP >::~Eigensolver  )  [inline, virtual]
 

Destructor.

Definition at line 77 of file AnasaziEigensolver.hpp.


Member Function Documentation

template<class ScalarType, class MV, class OP>
virtual void Anasazi::Eigensolver< ScalarType, MV, OP >::iterate  )  [pure virtual]
 

This method performs eigensolvers iterations until the status test indicates the need to stop or an error occurs (in which case, an exception is thrown).

Implemented in Anasazi::BlockDavidson< ScalarType, MV, OP >, Anasazi::BlockKrylovSchur< ScalarType, MV, OP >, and Anasazi::LOBPCG< ScalarType, MV, OP >.

template<class ScalarType, class MV, class OP>
virtual void Anasazi::Eigensolver< ScalarType, MV, OP >::initialize  )  [pure virtual]
 

Initialize the solver with the initial vectors from the eigenproblem or random data.

Implemented in Anasazi::BlockDavidson< ScalarType, MV, OP >, Anasazi::BlockKrylovSchur< ScalarType, MV, OP >, and Anasazi::LOBPCG< ScalarType, MV, OP >.

template<class ScalarType, class MV, class OP>
virtual int Anasazi::Eigensolver< ScalarType, MV, OP >::getNumIters  )  const [pure virtual]
 

Get the current iteration count.

Implemented in Anasazi::BlockDavidson< ScalarType, MV, OP >, Anasazi::BlockKrylovSchur< ScalarType, MV, OP >, and Anasazi::LOBPCG< ScalarType, MV, OP >.

template<class ScalarType, class MV, class OP>
virtual void Anasazi::Eigensolver< ScalarType, MV, OP >::resetNumIters  )  [pure virtual]
 

Reset the iteration count.

Implemented in Anasazi::BlockDavidson< ScalarType, MV, OP >, Anasazi::BlockKrylovSchur< ScalarType, MV, OP >, and Anasazi::LOBPCG< ScalarType, MV, OP >.

template<class ScalarType, class MV, class OP>
virtual Teuchos::RefCountPtr<const MV> Anasazi::Eigensolver< ScalarType, MV, OP >::getRitzVectors  )  [pure virtual]
 

Get the Ritz vectors from the previous iteration. These are indexed using getRitzIndex().

For a description of the indexing scheme, see getRitzIndex().

Implemented in Anasazi::BlockDavidson< ScalarType, MV, OP >, Anasazi::BlockKrylovSchur< ScalarType, MV, OP >, and Anasazi::LOBPCG< ScalarType, MV, OP >.

template<class ScalarType, class MV, class OP>
virtual std::vector<Value<ScalarType> > Anasazi::Eigensolver< ScalarType, MV, OP >::getRitzValues  )  [pure virtual]
 

Get the Ritz values from the previous iteration.

Implemented in Anasazi::BlockDavidson< ScalarType, MV, OP >, Anasazi::BlockKrylovSchur< ScalarType, MV, OP >, and Anasazi::LOBPCG< ScalarType, MV, OP >.

template<class ScalarType, class MV, class OP>
virtual std::vector<int> Anasazi::Eigensolver< ScalarType, MV, OP >::getRitzIndex  )  [pure virtual]
 

Get the index used for indexing the compressed storage used for Ritz vectors for real, non-Hermitian problems.

index has length numVecs, where each entry is 0, +1, or -1. These have the following interpretation:

  • index[i] == 0: signifies that the corresponding eigenvector is stored as the i column of Evecs. This will usually be the case when ScalarType is complex, an eigenproblem is Hermitian, or a real, non-Hermitian eigenproblem has a real eigenvector.
  • index[i] == +1: signifies that the corresponding eigenvector is stored in two vectors: the real part in the i column of Evecs and the positive imaginary part in the i+1 column of Evecs.
  • index[i] == -1: signifies that the corresponding eigenvector is stored in two vectors: the real part in the i-1 column of Evecs and the negative imaginary part in the i column of Evecs

Implemented in Anasazi::BlockDavidson< ScalarType, MV, OP >, Anasazi::BlockKrylovSchur< ScalarType, MV, OP >, and Anasazi::LOBPCG< ScalarType, MV, OP >.

template<class ScalarType, class MV, class OP>
virtual std::vector<typename Teuchos::ScalarTraits<ScalarType>::magnitudeType> Anasazi::Eigensolver< ScalarType, MV, OP >::getResNorms  )  [pure virtual]
 

Get the current residual norms.

Returns:
A vector of length blockSize containing the norms of the residuals, according to the orthogonalization manager norm() method.

Implemented in Anasazi::BlockDavidson< ScalarType, MV, OP >, Anasazi::BlockKrylovSchur< ScalarType, MV, OP >, and Anasazi::LOBPCG< ScalarType, MV, OP >.

template<class ScalarType, class MV, class OP>
virtual std::vector<typename Teuchos::ScalarTraits<ScalarType>::magnitudeType> Anasazi::Eigensolver< ScalarType, MV, OP >::getRes2Norms  )  [pure virtual]
 

Get the current residual 2-norms

Returns:
A vector of length blockSize containing the 2-norms of the residuals.

Implemented in Anasazi::BlockDavidson< ScalarType, MV, OP >, Anasazi::BlockKrylovSchur< ScalarType, MV, OP >, and Anasazi::LOBPCG< ScalarType, MV, OP >.

template<class ScalarType, class MV, class OP>
virtual std::vector<typename Teuchos::ScalarTraits<ScalarType>::magnitudeType> Anasazi::Eigensolver< ScalarType, MV, OP >::getRitzRes2Norms  )  [pure virtual]
 

Get the 2-norms of the Ritz residuals.

Returns:
A vector of length blockSize containing the 2-norms of the Ritz residuals.

Implemented in Anasazi::BlockDavidson< ScalarType, MV, OP >, Anasazi::BlockKrylovSchur< ScalarType, MV, OP >, and Anasazi::LOBPCG< ScalarType, MV, OP >.

template<class ScalarType, class MV, class OP>
virtual int Anasazi::Eigensolver< ScalarType, MV, OP >::getCurSubspaceDim  )  const [pure virtual]
 

Get the dimension of the search subspace used to generate the current eigenvectors and eigenvalues.

Implemented in Anasazi::BlockDavidson< ScalarType, MV, OP >, Anasazi::BlockKrylovSchur< ScalarType, MV, OP >, and Anasazi::LOBPCG< ScalarType, MV, OP >.

template<class ScalarType, class MV, class OP>
virtual int Anasazi::Eigensolver< ScalarType, MV, OP >::getMaxSubspaceDim  )  const [pure virtual]
 

Get the maximum dimension allocated for the search subspace.

Implemented in Anasazi::BlockDavidson< ScalarType, MV, OP >, Anasazi::BlockKrylovSchur< ScalarType, MV, OP >, and Anasazi::LOBPCG< ScalarType, MV, OP >.

template<class ScalarType, class MV, class OP>
virtual const Eigenproblem<ScalarType,MV,OP>& Anasazi::Eigensolver< ScalarType, MV, OP >::getProblem  )  const [pure virtual]
 

Get a constant reference to the eigenvalue problem.

Implemented in Anasazi::BlockDavidson< ScalarType, MV, OP >, Anasazi::BlockKrylovSchur< ScalarType, MV, OP >, and Anasazi::LOBPCG< ScalarType, MV, OP >.

template<class ScalarType, class MV, class OP>
virtual int Anasazi::Eigensolver< ScalarType, MV, OP >::getBlockSize  )  const [pure virtual]
 

Get the blocksize to be used by the iterative solver in solving this eigenproblem.

Implemented in Anasazi::BlockDavidson< ScalarType, MV, OP >, Anasazi::BlockKrylovSchur< ScalarType, MV, OP >, and Anasazi::LOBPCG< ScalarType, MV, OP >.

template<class ScalarType, class MV, class OP>
virtual void Anasazi::Eigensolver< ScalarType, MV, OP >::setBlockSize int  blockSize  )  [pure virtual]
 

Set the blocksize to be used by the iterative solver in solving this eigenproblem.

Implemented in Anasazi::BlockDavidson< ScalarType, MV, OP >, Anasazi::BlockKrylovSchur< ScalarType, MV, OP >, and Anasazi::LOBPCG< ScalarType, MV, OP >.

template<class ScalarType, class MV, class OP>
virtual void Anasazi::Eigensolver< ScalarType, MV, OP >::setAuxVecs const Teuchos::Array< Teuchos::RefCountPtr< const MV > > &  auxvecs  )  [pure virtual]
 

Set the auxiliary vectors for the solver.

Implemented in Anasazi::BlockDavidson< ScalarType, MV, OP >, Anasazi::BlockKrylovSchur< ScalarType, MV, OP >, and Anasazi::LOBPCG< ScalarType, MV, OP >.

template<class ScalarType, class MV, class OP>
virtual Teuchos::Array<Teuchos::RefCountPtr<const MV> > Anasazi::Eigensolver< ScalarType, MV, OP >::getAuxVecs  )  const [pure virtual]
 

Get the auxiliary vectors for the solver.

Implemented in Anasazi::BlockDavidson< ScalarType, MV, OP >, Anasazi::BlockKrylovSchur< ScalarType, MV, OP >, and Anasazi::LOBPCG< ScalarType, MV, OP >.

template<class ScalarType, class MV, class OP>
virtual bool Anasazi::Eigensolver< ScalarType, MV, OP >::isInitialized  )  [pure virtual]
 

States whether the solver has been initialized or not.

Implemented in Anasazi::BlockDavidson< ScalarType, MV, OP >, Anasazi::BlockKrylovSchur< ScalarType, MV, OP >, and Anasazi::LOBPCG< ScalarType, MV, OP >.

template<class ScalarType, class MV, class OP>
virtual void Anasazi::Eigensolver< ScalarType, MV, OP >::currentStatus ostream &  os  )  [pure virtual]
 

This method requests that the solver print out its current status to screen.

Implemented in Anasazi::BlockDavidson< ScalarType, MV, OP >, Anasazi::BlockKrylovSchur< ScalarType, MV, OP >, and Anasazi::LOBPCG< ScalarType, MV, OP >.


The documentation for this class was generated from the following file:
Generated on Thu Sep 18 12:31:39 2008 for Anasazi by doxygen 1.3.9.1