Thyra::AmesosLinearOpWithSolve Class Reference
[Amesos to Thyra Linear Solver Adapter Code]

Concrete LinearOpWithSolveBase subclass that adapts any Amesos_BaseSolver object. More...

#include <Thyra_AmesosLinearOpWithSolve.hpp>

Inheritance diagram for Thyra::AmesosLinearOpWithSolve:

[legend]
List of all members.

Constructors/initializers/accessors

 AmesosLinearOpWithSolve ()
 Construct to uninitialized.
 AmesosLinearOpWithSolve (const Teuchos::RefCountPtr< const LinearOpBase< double > > &fwdOp, const Teuchos::RefCountPtr< const LinearOpSourceBase< double > > &fwdOpSrc, const Teuchos::RefCountPtr< Epetra_LinearProblem > &epetraLP, const Teuchos::RefCountPtr< Amesos_BaseSolver > &amesosSolver, const ETransp amesosSolverTransp, const double amesosSolverScalar)
 Calls this->initialize().
void initialize (const Teuchos::RefCountPtr< const LinearOpBase< double > > &fwdOp, const Teuchos::RefCountPtr< const LinearOpSourceBase< double > > &fwdOpSrc, const Teuchos::RefCountPtr< Epetra_LinearProblem > &epetraLP, const Teuchos::RefCountPtr< Amesos_BaseSolver > &amesosSolver, const ETransp amesosSolverTransp, const double amesosSolverScalar)
 First initialization.
Teuchos::RefCountPtr< const
LinearOpSourceBase< double > > 
extract_fwdOpSrc ()
 Extract the LinearOpSourceBase<double> object so that it can be modified.
Teuchos::RefCountPtr< const
LinearOpBase< double > > 
get_fwdOp () const
 
Teuchos::RefCountPtr< const
LinearOpSourceBase< double > > 
get_fwdOpSrc () const
 
Teuchos::RefCountPtr< Epetra_LinearProblemget_epetraLP () const
 
Teuchos::RefCountPtr< Amesos_BaseSolverget_amesosSolver () const
 
ETransp get_amesosSolverTransp () const
 
double get_amesosSolverScalar () const
 
void uninitialize (Teuchos::RefCountPtr< const LinearOpBase< double > > *fwdOp=NULL, Teuchos::RefCountPtr< const LinearOpSourceBase< double > > *fwdOpSrc=NULL, Teuchos::RefCountPtr< Epetra_LinearProblem > *epetraLP=NULL, Teuchos::RefCountPtr< Amesos_BaseSolver > *amesosSolver=NULL, ETransp *amesosSolverTransp=NULL, double *amesosSolverScalar=NULL)
 Uninitialize.

Overridden public functions from LinearOpBase

Teuchos::RefCountPtr< const
VectorSpaceBase< double > > 
range () const
 .
Teuchos::RefCountPtr< const
VectorSpaceBase< double > > 
domain () const
 .
Teuchos::RefCountPtr< const
LinearOpBase< double > > 
clone () const
 .

Overridden public functions from Teuchos::Describable

std::string description () const
 

Overridden protected functions from SingleScalarLinearOpBase

bool opSupported (ETransp M_trans) const
 
void apply (const ETransp M_trans, const MultiVectorBase< double > &X, MultiVectorBase< double > *Y, const double alpha, const double beta) const
 

Overridden protected functions from SingleScalarLinearOpWithSolveBase

bool solveSupportsTrans (ETransp M_trans) const
 
bool solveSupportsSolveMeasureType (ETransp M_trans, const SolveMeasureType &solveMeasureType) const
 
void solve (const ETransp M_trans, const MultiVectorBase< double > &B, MultiVectorBase< double > *X, const int numBlocks, const BlockSolveCriteria< double > blockSolveCriteria[], SolveStatus< double > blockSolveStatus[]) const
 

Detailed Description

Concrete LinearOpWithSolveBase subclass that adapts any Amesos_BaseSolver object.

See the LinearOpWithSolveBase interface for a description of how to use objects of this type.

Note: Clients should not generally directly create objects of this type but instead should use AmesosLinearOpWithSolveFactory. Only very sophisticated users should ever directly interact with an object through this subclass interface.

Definition at line 55 of file Thyra_AmesosLinearOpWithSolve.hpp.


Constructor & Destructor Documentation

Thyra::AmesosLinearOpWithSolve::AmesosLinearOpWithSolve  ) 
 

Construct to uninitialized.

Definition at line 48 of file Thyra_AmesosLinearOpWithSolve.cpp.

Thyra::AmesosLinearOpWithSolve::AmesosLinearOpWithSolve const Teuchos::RefCountPtr< const LinearOpBase< double > > &  fwdOp,
const Teuchos::RefCountPtr< const LinearOpSourceBase< double > > &  fwdOpSrc,
const Teuchos::RefCountPtr< Epetra_LinearProblem > &  epetraLP,
const Teuchos::RefCountPtr< Amesos_BaseSolver > &  amesosSolver,
const ETransp  amesosSolverTransp,
const double  amesosSolverScalar
 

Calls this->initialize().

Definition at line 53 of file Thyra_AmesosLinearOpWithSolve.cpp.


Member Function Documentation

void Thyra::AmesosLinearOpWithSolve::initialize const Teuchos::RefCountPtr< const LinearOpBase< double > > &  fwdOp,
const Teuchos::RefCountPtr< const LinearOpSourceBase< double > > &  fwdOpSrc,
const Teuchos::RefCountPtr< Epetra_LinearProblem > &  epetraLP,
const Teuchos::RefCountPtr< Amesos_BaseSolver > &  amesosSolver,
const ETransp  amesosSolverTransp,
const double  amesosSolverScalar
 

First initialization.

Parameters:
fwdOp [in] The forward operator for which the factorization exists.
epetraLP [in] The Epetra_LinearProblem object that was used to create the Amesos_BaseSolver object *amesosSolver. Note that the RHS and the LHS multi-vector pointers in this object will be set and unset here.
amesosSolver [in] Contains the factored, and ready to go, Amesos_BaseSolver object ready to solve linear system.
amesosSolverTransp [in] Determines if the Amesos solver should be used as its transpose or not.
amesosSolverScalar [in] Determines the scaling factor associated with the Amesos solver. The solution to the linear solve is scaled by 1/amesosSolverScalar.
Preconditions:
  • fwdOp.get()!=NULL
  • epetraLP.get()!=NULL
  • amesosSolver.get()!=NULL
  • *epetraLP->GetOperator() is compatible with *fwdOp
  • epetraLP->GetLHS()==NULL
  • epetraLP->GetRHS()==NULL
  • *amesosSolver contains the factorization of *fwdOp and is ready to solve linear systems!

Postconditions:

Definition at line 66 of file Thyra_AmesosLinearOpWithSolve.cpp.

Teuchos::RefCountPtr< const LinearOpSourceBase< double > > Thyra::AmesosLinearOpWithSolve::extract_fwdOpSrc  ) 
 

Extract the LinearOpSourceBase<double> object so that it can be modified.

Postconditions:

Definition at line 92 of file Thyra_AmesosLinearOpWithSolve.cpp.

Teuchos::RefCountPtr< const LinearOpBase< double > > Thyra::AmesosLinearOpWithSolve::get_fwdOp  )  const [inline]
 

Definition at line 232 of file Thyra_AmesosLinearOpWithSolve.hpp.

Teuchos::RefCountPtr< const LinearOpSourceBase< double > > Thyra::AmesosLinearOpWithSolve::get_fwdOpSrc  )  const [inline]
 

Definition at line 239 of file Thyra_AmesosLinearOpWithSolve.hpp.

Teuchos::RefCountPtr< Epetra_LinearProblem > Thyra::AmesosLinearOpWithSolve::get_epetraLP  )  const [inline]
 

Definition at line 246 of file Thyra_AmesosLinearOpWithSolve.hpp.

Teuchos::RefCountPtr< Amesos_BaseSolver > Thyra::AmesosLinearOpWithSolve::get_amesosSolver  )  const [inline]
 

Definition at line 253 of file Thyra_AmesosLinearOpWithSolve.hpp.

ETransp Thyra::AmesosLinearOpWithSolve::get_amesosSolverTransp  )  const [inline]
 

Definition at line 259 of file Thyra_AmesosLinearOpWithSolve.hpp.

double Thyra::AmesosLinearOpWithSolve::get_amesosSolverScalar  )  const [inline]
 

Definition at line 265 of file Thyra_AmesosLinearOpWithSolve.hpp.

void Thyra::AmesosLinearOpWithSolve::uninitialize Teuchos::RefCountPtr< const LinearOpBase< double > > *  fwdOp = NULL,
Teuchos::RefCountPtr< const LinearOpSourceBase< double > > *  fwdOpSrc = NULL,
Teuchos::RefCountPtr< Epetra_LinearProblem > *  epetraLP = NULL,
Teuchos::RefCountPtr< Amesos_BaseSolver > *  amesosSolver = NULL,
ETransp amesosSolverTransp = NULL,
double *  amesosSolverScalar = NULL
 

Uninitialize.

Definition at line 99 of file Thyra_AmesosLinearOpWithSolve.cpp.

Teuchos::RefCountPtr< const VectorSpaceBase< double > > Thyra::AmesosLinearOpWithSolve::range  )  const
 

.

Definition at line 128 of file Thyra_AmesosLinearOpWithSolve.cpp.

Teuchos::RefCountPtr< const VectorSpaceBase< double > > Thyra::AmesosLinearOpWithSolve::domain  )  const
 

.

Definition at line 134 of file Thyra_AmesosLinearOpWithSolve.cpp.

Teuchos::RefCountPtr< const LinearOpBase< double > > Thyra::AmesosLinearOpWithSolve::clone  )  const
 

.

Definition at line 140 of file Thyra_AmesosLinearOpWithSolve.cpp.

std::string Thyra::AmesosLinearOpWithSolve::description  )  const
 

Definition at line 147 of file Thyra_AmesosLinearOpWithSolve.cpp.

bool Thyra::AmesosLinearOpWithSolve::opSupported ETransp  M_trans  )  const [protected]
 

Definition at line 162 of file Thyra_AmesosLinearOpWithSolve.cpp.

void Thyra::AmesosLinearOpWithSolve::apply const ETransp  M_trans,
const MultiVectorBase< double > &  X,
MultiVectorBase< double > *  Y,
const double  alpha,
const double  beta
const [protected]
 

Definition at line 167 of file Thyra_AmesosLinearOpWithSolve.cpp.

bool Thyra::AmesosLinearOpWithSolve::solveSupportsTrans ETransp  M_trans  )  const [protected, virtual]
 

Implements Thyra::SingleScalarLinearOpWithSolveBase< double >.

Definition at line 180 of file Thyra_AmesosLinearOpWithSolve.cpp.

bool Thyra::AmesosLinearOpWithSolve::solveSupportsSolveMeasureType ETransp  M_trans,
const SolveMeasureType solveMeasureType
const [protected, virtual]
 

Implements Thyra::SingleScalarLinearOpWithSolveBase< double >.

Definition at line 185 of file Thyra_AmesosLinearOpWithSolve.cpp.

void Thyra::AmesosLinearOpWithSolve::solve const ETransp  M_trans,
const MultiVectorBase< double > &  B,
MultiVectorBase< double > *  X,
const int  numBlocks,
const BlockSolveCriteria< double >  blockSolveCriteria[],
SolveStatus< double >  blockSolveStatus[]
const [protected, virtual]
 

Implements Thyra::SingleScalarLinearOpWithSolveBase< double >.

Definition at line 192 of file Thyra_AmesosLinearOpWithSolve.cpp.


The documentation for this class was generated from the following files:
Generated on Thu Sep 18 12:30:59 2008 for Amesos/Thyra Linear Solver Adapter Software by doxygen 1.3.9.1