Anasazi::SortManager< MagnitudeType > Class Template Reference

Anasazi's templated pure virtual class for managing the sorting of approximate eigenvalues computed by the eigensolver. A concrete implementation of this class is necessary. More...

#include <AnasaziSortManager.hpp>

Inheritance diagram for Anasazi::SortManager< MagnitudeType >:

Anasazi::BasicSort< MagnitudeType > List of all members.

Public Member Functions

 SortManager ()
 Default constructor.
 SortManager (Teuchos::ParameterList &pl)
 Constructor accepting a Teuchos::ParameterList. This is the default mode for instantiating a SortManager.
virtual ~SortManager ()
 Destructor.
virtual void sort (std::vector< MagnitudeType > &evals, Teuchos::RCP< std::vector< int > > perm=Teuchos::null, int n=-1) const =0
 Sort real eigenvalues, optionally returning the permutation vector.
virtual void sort (std::vector< MagnitudeType > &r_evals, std::vector< MagnitudeType > &i_evals, Teuchos::RCP< std::vector< int > > perm=Teuchos::null, int n=-1) const =0
 Sort complex eigenvalues, optionally returning the permutation vector.

Detailed Description

template<class MagnitudeType>
class Anasazi::SortManager< MagnitudeType >

Anasazi's templated pure virtual class for managing the sorting of approximate eigenvalues computed by the eigensolver. A concrete implementation of this class is necessary.

Author:
Ulrich Hetmaniuk, Rich Lehoucq, and Heidi Thornquist

Definition at line 66 of file AnasaziSortManager.hpp.


Constructor & Destructor Documentation

template<class MagnitudeType>
Anasazi::SortManager< MagnitudeType >::SortManager (  )  [inline]

Default constructor.

Definition at line 71 of file AnasaziSortManager.hpp.

template<class MagnitudeType>
Anasazi::SortManager< MagnitudeType >::SortManager ( Teuchos::ParameterList pl  )  [inline]

Constructor accepting a Teuchos::ParameterList. This is the default mode for instantiating a SortManager.

Definition at line 74 of file AnasaziSortManager.hpp.

template<class MagnitudeType>
virtual Anasazi::SortManager< MagnitudeType >::~SortManager (  )  [inline, virtual]

Destructor.

Definition at line 77 of file AnasaziSortManager.hpp.


Member Function Documentation

template<class MagnitudeType>
virtual void Anasazi::SortManager< MagnitudeType >::sort ( std::vector< MagnitudeType > &  evals,
Teuchos::RCP< std::vector< int > >  perm = Teuchos::null,
int  n = -1 
) const [pure virtual]

Sort real eigenvalues, optionally returning the permutation vector.

Parameters:
evals [in/out] Vector of length at least n containing the eigenvalues to be sorted.
On output, the first n eigenvalues will be sorted. The rest will be unchanged.
perm [out] Vector of length at least n to store the permutation index (optional).
If specified, on output the first n eigenvalues will contain the permutation indices, in the range [0,n-1], such that evals_out[i] = evals_in[perm[i]]
n [in] Number of values in evals to be sorted. If n == -1, all values will be sorted.

Implemented in Anasazi::BasicSort< MagnitudeType >.

template<class MagnitudeType>
virtual void Anasazi::SortManager< MagnitudeType >::sort ( std::vector< MagnitudeType > &  r_evals,
std::vector< MagnitudeType > &  i_evals,
Teuchos::RCP< std::vector< int > >  perm = Teuchos::null,
int  n = -1 
) const [pure virtual]

Sort complex eigenvalues, optionally returning the permutation vector.

This routine takes two vectors, one for each part of a complex eigenvalue. This is helpful for solving real, non-symmetric eigenvalue problems.

Parameters:
r_evals [in/out] Vector of length at least n containing the real part of the eigenvalues to be sorted.
On output, the first n eigenvalues will be sorted. The rest will be unchanged.
i_evals [in/out] Vector of length at least n containing the imaginary part of the eigenvalues to be sorted.
On output, the first n eigenvalues will be sorted. The rest will be unchanged.
perm [out] Vector of length at least n to store the permutation index (optional).
If specified, on output the first n eigenvalues will contain the permutation indices, in the range [0,n-1], such that r_evals_out[i] = r_evals_in[perm[i]] and similarly for i_evals.
n [in] Number of values in r_evals, i_evals to be sorted. If n == -1, all values will be sorted.

Implemented in Anasazi::BasicSort< MagnitudeType >.


The documentation for this class was generated from the following file:
Generated on Wed May 12 21:40:24 2010 for Anasazi by  doxygen 1.4.7