NOX Development
Loading...
Searching...
No Matches
LOCA::AnasaziOperator::Cayley Class Reference

Anasazi operator for computing generalized eigenvalues using Cayley transformations. More...

#include <LOCA_AnasaziOperator_Cayley.H>

Inheritance diagram for LOCA::AnasaziOperator::Cayley:
Collaboration diagram for LOCA::AnasaziOperator::Cayley:

Public Member Functions

 Cayley (const Teuchos::RCP< LOCA::GlobalData > &global_data, const Teuchos::RCP< LOCA::Parameter::SublistParser > &topParams, const Teuchos::RCP< Teuchos::ParameterList > &eigenParams, const Teuchos::RCP< Teuchos::ParameterList > &solverParams, const Teuchos::RCP< LOCA::TimeDependent::AbstractGroup > &grp)
 Constructor.
virtual ~Cayley ()
 Destructor.
virtual const std::string & label () const
 Return name of this operator.
virtual void apply (const NOX::Abstract::MultiVector &input, NOX::Abstract::MultiVector &output) const
 Apply the operator.
virtual void preProcessSeedVector (NOX::Abstract::MultiVector &ivec)
 PreProcess the random seed vector.
virtual void transformEigenvalue (double &ev_r, double &ev_i) const
 Transform eigenvalue.
virtual NOX::Abstract::Group::ReturnType rayleighQuotient (NOX::Abstract::Vector &evec_r, NOX::Abstract::Vector &evec_i, double &rq_r, double &rq_i) const
 Compute Rayleigh quotient.
Public Member Functions inherited from LOCA::AnasaziOperator::AbstractStrategy
 AbstractStrategy ()
 Constructor.
virtual ~AbstractStrategy ()
 Destructor.
virtual void beginPostProcessing ()
 Hook to precompute info for subsequent repeated calls to tranformEigenvalue and rayleighQuotient.

Protected Attributes

Teuchos::RCP< LOCA::GlobalDataglobalData
 Global data.
std::string myLabel
 Name of this operator.
Teuchos::RCP< Teuchos::ParameterList > eigenParams
 Stores parameters relating to the operator.
Teuchos::RCP< Teuchos::ParameterList > solverParams
 Stores linear solver parameters.
Teuchos::RCP< LOCA::TimeDependent::AbstractGroupgrp
 Stores group representing Jacobian and Mass matrix.
Teuchos::RCP< NOX::Abstract::MultiVectortmp_r
 Stores a temporary vector for computing Rayleigh quotients.
Teuchos::RCP< NOX::Abstract::MultiVectortmp_i
 Stores a temporary vector for computing Rayleigh quotients.
double sigma
 Stores Cayley pole $\sigma$.
double mu
 Stores Cayley zero $\mu$.

Detailed Description

Anasazi operator for computing generalized eigenvalues using Cayley transformations.

This class implements the LOCA::AnasaziOperator::AbstractStrategy interface for computing generalized eigenvalues $\lambda$ and eigenvectors $z$ of the system

\‍[     J z = \lambda M z
*\‍]

where $J$ is the Jacobian matrix and $M$ is the mass matrix. The eigenvalues are computed using a Cayley transformation, i.e. solving

\‍[      (J - \sigma M) z = (J - \mu M) r
\‍]

where $\sigma$ is the Cayley pole and $\mu$ is the Cayley zero.

The parameters used by this class supplied in the constructor are:

  • "Cayley Pole" - $\sigma$ as defined above (Default 0.0)
  • "Cayley Zero" - $\mu$ as defined above (Default 0.0)

Also the grp argument to the constructor must be a child of LOCA::TimeDependent::AbstractGroup for the shift-invert operations.

Constructor & Destructor Documentation

◆ Cayley()

LOCA::AnasaziOperator::Cayley::Cayley ( const Teuchos::RCP< LOCA::GlobalData > & global_data,
const Teuchos::RCP< LOCA::Parameter::SublistParser > & topParams,
const Teuchos::RCP< Teuchos::ParameterList > & eigenParams,
const Teuchos::RCP< Teuchos::ParameterList > & solverParams,
const Teuchos::RCP< LOCA::TimeDependent::AbstractGroup > & grp )

Constructor.

Argument grp must be of type LOCA::TimeDependent::AbstractGroup. See class description for a list of eigenParams.

References eigenParams, globalData, grp, mu, myLabel, sigma, solverParams, tmp_i, and tmp_r.

Member Function Documentation

◆ apply()

void LOCA::AnasaziOperator::Cayley::apply ( const NOX::Abstract::MultiVector & input,
NOX::Abstract::MultiVector & output ) const
virtual

Apply the operator.

Applies the inverse of the shifted operator, i.e., solves

\‍[     (J-\omega I)z = M r
\‍]

for $z$, where $r = \mbox{input}$ and $z = \mbox{output}$.

Implements LOCA::AnasaziOperator::AbstractStrategy.

References NOX::Abstract::MultiVector::clone(), globalData, grp, mu, NOX::Abstract::MultiVector::numVectors(), NOX::Abstract::Group::Ok, NOX::ShapeCopy, sigma, solverParams, and tmp_r.

◆ label()

const std::string & LOCA::AnasaziOperator::Cayley::label ( ) const
virtual

Return name of this operator.

Implements LOCA::AnasaziOperator::AbstractStrategy.

References myLabel.

◆ preProcessSeedVector()

void LOCA::AnasaziOperator::Cayley::preProcessSeedVector ( NOX::Abstract::MultiVector & ivec)
virtual

PreProcess the random seed vector.

Performs one backward Euler iteration on the random initial seed vector, to satisfy contraints

Reimplemented from LOCA::AnasaziOperator::AbstractStrategy.

References NOX::Abstract::MultiVector::clone(), globalData, grp, NOX::Abstract::MultiVector::numVectors(), NOX::Abstract::Group::Ok, NOX::ShapeCopy, sigma, solverParams, and tmp_r.

◆ rayleighQuotient()

NOX::Abstract::Group::ReturnType LOCA::AnasaziOperator::Cayley::rayleighQuotient ( NOX::Abstract::Vector & evec_r,
NOX::Abstract::Vector & evec_i,
double & rq_r,
double & rq_i ) const
virtual

◆ transformEigenvalue()

void LOCA::AnasaziOperator::Cayley::transformEigenvalue ( double & ev_r,
double & ev_i ) const
virtual

Transform eigenvalue.

Transforms the given eigenvalue to the eigenvalue of the Jacobian-mass matrix system by shifting and inverting it.

Implements LOCA::AnasaziOperator::AbstractStrategy.

References mu, and sigma.


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