Teko  Version of the Day
 All Classes Files Functions Variables Pages
Public Member Functions | Protected Member Functions | List of all members
Teko::InvFactoryDiagStrategy Class Reference

#include <Teko_BlockInvDiagonalStrategy.hpp>

Inheritance diagram for Teko::InvFactoryDiagStrategy:
Inheritance graph
[legend]

Public Member Functions

 InvFactoryDiagStrategy (const Teuchos::RCP< InverseFactory > &factory)
 
 InvFactoryDiagStrategy (const std::vector< Teuchos::RCP< InverseFactory > > &factories, const Teuchos::RCP< InverseFactory > &defaultFact=Teuchos::null)
 
virtual void getInvD (const BlockedLinearOp &A, BlockPreconditionerState &state, std::vector< LinearOp > &invDiag) const
 
const std::vector
< Teuchos::RCP< InverseFactory > > & 
getFactories () const
 Get factories for testing purposes. More...
 

Protected Member Functions

LinearOp buildInverse (const InverseFactory &invFact, const LinearOp &matrix, BlockPreconditionerState &state, const std::string &opPrefix, int i) const
 Conveinence function for building inverse operators. More...
 

Detailed Description

A simple class that takes a vector of the InverseFactory objects and pairs each with the diagonal element of the block matrix. This provides the operators needed to use Gauss-Seidel or Jacobi.

Definition at line 123 of file Teko_BlockInvDiagonalStrategy.hpp.

Constructor & Destructor Documentation

Teko::InvFactoryDiagStrategy::InvFactoryDiagStrategy ( const Teuchos::RCP< InverseFactory > &  factory)

Constructor accepting a single inverse factory that will be used to invert all diagonal blocks.

Parameters
[in]factoryFactory to be used to invert each diagonal block.

Definition at line 51 of file Teko_BlockInvDiagonalStrategy.cpp.

Teko::InvFactoryDiagStrategy::InvFactoryDiagStrategy ( const std::vector< Teuchos::RCP< InverseFactory > > &  factories,
const Teuchos::RCP< InverseFactory > &  defaultFact = Teuchos::null 
)

Constructor that lets the inverse of each block be set individually.

Parameters
[in]factoriesA vector of InverseFactory objects which should be the same length as the number of diagonal blocks.
[in]defaultFactThe default factory to use if none is specified.

Definition at line 58 of file Teko_BlockInvDiagonalStrategy.cpp.

Member Function Documentation

void Teko::InvFactoryDiagStrategy::getInvD ( const BlockedLinearOp &  A,
BlockPreconditionerState state,
std::vector< LinearOp > &  invDiag 
) const
virtual

returns an (approximate) inverse of the diagonal blocks of A where A is closely related to the original source for invD0 and invD1

Parameters
[in]AOperator to extract the block diagonals from.
[in]stateState object for this operator.
[in,out]invDiagVector eventually containing the inverse operators

returns an (approximate) inverse of the diagonal blocks of A where A is closely related to the original source for invD0 and invD1

Implements Teko::BlockInvDiagonalStrategy.

Definition at line 72 of file Teko_BlockInvDiagonalStrategy.cpp.

const std::vector<Teuchos::RCP<InverseFactory> >& Teko::InvFactoryDiagStrategy::getFactories ( ) const
inline

Get factories for testing purposes.

Definition at line 155 of file Teko_BlockInvDiagonalStrategy.hpp.

LinearOp Teko::InvFactoryDiagStrategy::buildInverse ( const InverseFactory invFact,
const LinearOp &  matrix,
BlockPreconditionerState state,
const std::string &  opPrefix,
int  i 
) const
protected

Conveinence function for building inverse operators.

Definition at line 96 of file Teko_BlockInvDiagonalStrategy.cpp.


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