Thyra Package Browser (Single Doxygen Collection) Version of the Day
Classes | Private Types | Private Member Functions | Private Attributes | Related Functions
Thyra::DefaultBlockedLinearOp< Scalar > Class Template Reference

Concrete composite LinearOpBase subclass that creates single linear operator object out of a set of constituent LinearOpBase blocks. More...

#include <Thyra_DefaultBlockedLinearOp_decl.hpp>

Inheritance diagram for Thyra::DefaultBlockedLinearOp< Scalar >:
Inheritance graph
[legend]

List of all members.

Classes

struct  BlockEntry

Private Types

typedef
Teuchos::ConstNonconstObjectContainer
< LinearOpBase< Scalar > > 
CNCLO
typedef Teuchos::Array
< Teuchos::RCP< const
VectorSpaceBase< Scalar > > > 
vec_array_t

Private Member Functions

void resetStorage (const int numRowBlocks, const int numColBlocks)
void assertBlockFillIsActive (bool) const
void assertBlockRowCol (const int i, const int j) const
void setBlockSpaces (const int i, const int j, const LinearOpBase< Scalar > &block)
template<class LinearOpType >
void setBlockImpl (const int i, const int j, const Teuchos::RCP< LinearOpType > &block)
void adjustBlockSpaces ()
 DefaultBlockedLinearOp (const DefaultBlockedLinearOp &)
DefaultBlockedLinearOpoperator= (const DefaultBlockedLinearOp &)

Private Attributes

Teuchos::RCP< const
ProductVectorSpaceBase< Scalar > > 
productRange_
Teuchos::RCP< const
ProductVectorSpaceBase< Scalar > > 
productDomain_
Teuchos::RCP< const
DefaultProductVectorSpace
< Scalar > > 
defaultProductRange_
Teuchos::RCP< const
DefaultProductVectorSpace
< Scalar > > 
defaultProductDomain_
int numRowBlocks_
int numColBlocks_
std::vector< CNCLOOps_
vec_array_t rangeBlocks_
vec_array_t domainBlocks_
std::vector< BlockEntry< Scalar > > Ops_stack_
bool blockFillIsActive_

Related Functions

(Note that these are not member functions.)

template<class Scalar >
RCP< DefaultBlockedLinearOp
< Scalar > > 
defaultBlockedLinearOp ()
 Nonmember default constructor.
template<class Scalar >
Teuchos::RCP< const
LinearOpBase< Scalar > > 
block1x1 (const Teuchos::RCP< const LinearOpBase< Scalar > > &A00, const std::string &label="")
 Form an implicit block 1x1 linear operator [ A00 ].
template<class Scalar >
Teuchos::RCP< const
LinearOpBase< Scalar > > 
block1x2 (const Teuchos::RCP< const LinearOpBase< Scalar > > &A00, const Teuchos::RCP< const LinearOpBase< Scalar > > &A01, const std::string &label="")
 Form an implicit block 1x2 linear operator [ A00, A01 ].
template<class Scalar >
Teuchos::RCP< const
LinearOpBase< Scalar > > 
block2x1 (const Teuchos::RCP< const LinearOpBase< Scalar > > &A00, const Teuchos::RCP< const LinearOpBase< Scalar > > &A10, const std::string &label="")
 Form an implicit block 2x1 linear operator [ A00; A10 ].
template<class Scalar >
Teuchos::RCP< const
LinearOpBase< Scalar > > 
block2x2 (const Teuchos::RCP< const LinearOpBase< Scalar > > &A00, const Teuchos::RCP< const LinearOpBase< Scalar > > &A01, const Teuchos::RCP< const LinearOpBase< Scalar > > &A10, const Teuchos::RCP< const LinearOpBase< Scalar > > &A11, const std::string &label="")
 Form an implicit block 2x2 linear operator [ A00, A01; A10, A11 ].
template<class Scalar >
Teuchos::RCP< LinearOpBase
< Scalar > > 
nonconstBlock1x1 (const Teuchos::RCP< LinearOpBase< Scalar > > &A00, const std::string &label="")
 Form an implicit block 1x1 linear operator [ A00 ].
template<class Scalar >
Teuchos::RCP< LinearOpBase
< Scalar > > 
nonconstBlock1x2 (const Teuchos::RCP< LinearOpBase< Scalar > > &A00, const Teuchos::RCP< LinearOpBase< Scalar > > &A01, const std::string &label="")
 Form an implicit block 1x2 linear operator [ A00, A01 ].
template<class Scalar >
Teuchos::RCP< LinearOpBase
< Scalar > > 
nonconstBlock2x1 (const Teuchos::RCP< LinearOpBase< Scalar > > &A00, const Teuchos::RCP< LinearOpBase< Scalar > > &A10, const std::string &label="")
 Form an implicit block 2x1 linear operator [ A00; A10 ].
template<class Scalar >
Teuchos::RCP< LinearOpBase
< Scalar > > 
nonconstBlock2x2 (const Teuchos::RCP< LinearOpBase< Scalar > > &A00, const Teuchos::RCP< LinearOpBase< Scalar > > &A01, const Teuchos::RCP< LinearOpBase< Scalar > > &A10, const Teuchos::RCP< LinearOpBase< Scalar > > &A11, const std::string &label="")
 Form an implicit block 2x2 linear operator [ A00, A01; A10, A11 ].

Constructors

 DefaultBlockedLinearOp ()
 

Overridden from PhysicallyBlockedLinearOpBase

void beginBlockFill ()
 
void beginBlockFill (const int numRowBlocks, const int numColBlocks)
 
void beginBlockFill (const Teuchos::RCP< const ProductVectorSpaceBase< Scalar > > &productRange, const Teuchos::RCP< const ProductVectorSpaceBase< Scalar > > &productDomain)
 
bool blockFillIsActive () const
 
bool acceptsBlock (const int i, const int j) const
 
void setNonconstBlock (const int i, const int j, const Teuchos::RCP< LinearOpBase< Scalar > > &block)
 
void setBlock (const int i, const int j, const Teuchos::RCP< const LinearOpBase< Scalar > > &block)
 
void endBlockFill ()
 
void uninitialize ()
 

Overridden from BlockedLinearOpBase

Teuchos::RCP< const
ProductVectorSpaceBase< Scalar > > 
productRange () const
 
Teuchos::RCP< const
ProductVectorSpaceBase< Scalar > > 
productDomain () const
 
bool blockExists (const int i, const int j) const
 
bool blockIsConst (const int i, const int j) const
 
Teuchos::RCP< LinearOpBase
< Scalar > > 
getNonconstBlock (const int i, const int j)
 
Teuchos::RCP< const
LinearOpBase< Scalar > > 
getBlock (const int i, const int j) const
 

Overridden from LinearOpBase

Teuchos::RCP< const
VectorSpaceBase< Scalar > > 
range () const
 
Teuchos::RCP< const
VectorSpaceBase< Scalar > > 
domain () const
 
Teuchos::RCP< const
LinearOpBase< Scalar > > 
clone () const
 
bool opSupportedImpl (EOpTransp M_trans) const
 Returns true only if all constituent operators support M_trans.
void applyImpl (const EOpTransp M_trans, const MultiVectorBase< Scalar > &X, const Ptr< MultiVectorBase< Scalar > > &Y, const Scalar alpha, const Scalar beta) const
 

Overridden from Teuchos::Describable

std::string description () const
 Prints just the name DefaultBlockedLinearOp along with the overall dimensions and the number of constituent operators.
void describe (Teuchos::FancyOStream &out, const Teuchos::EVerbosityLevel verbLevel) const
 Prints the details about the constituent linear operators.

Detailed Description

template<class Scalar>
class Thyra::DefaultBlockedLinearOp< Scalar >

Concrete composite LinearOpBase subclass that creates single linear operator object out of a set of constituent LinearOpBase blocks.

This class represents a blocked linear operator M of the form:

 
  M =  [ Op[0,0], Op[0,1], ... , Op[0,N];  
         Op[1,0], Op[1,1], ... , Op[1,N];  
         .        .              .         
         Op[M,0], Op[M,1], ... , Op[M,N]; ]

 

where Op[] is a logical 2D array of LinearOpBase objects and M=this->productRange()->getNumBlocks() and N=this->productDomain()->getNumBlocks(). Of course the operator M is not constructed explicitly but instead just applies the constituent linear operators with each set of blocks.

ToDo: Finish Documentation!

Definition at line 72 of file Thyra_DefaultBlockedLinearOp_decl.hpp.


Member Typedef Documentation

template<class Scalar >
typedef Teuchos::ConstNonconstObjectContainer<LinearOpBase<Scalar> > Thyra::DefaultBlockedLinearOp< Scalar >::CNCLO [private]

Definition at line 203 of file Thyra_DefaultBlockedLinearOp_decl.hpp.

template<class Scalar >
typedef Teuchos::Array<Teuchos::RCP<const VectorSpaceBase<Scalar> > > Thyra::DefaultBlockedLinearOp< Scalar >::vec_array_t [private]

Definition at line 204 of file Thyra_DefaultBlockedLinearOp_decl.hpp.


Constructor & Destructor Documentation

template<class Scalar >
Thyra::DefaultBlockedLinearOp< Scalar >::DefaultBlockedLinearOp ( )

Definition at line 49 of file Thyra_DefaultBlockedLinearOp_def.hpp.

template<class Scalar >
Thyra::DefaultBlockedLinearOp< Scalar >::DefaultBlockedLinearOp ( const DefaultBlockedLinearOp< Scalar > &  ) [private]

Member Function Documentation

template<class Scalar >
void Thyra::DefaultBlockedLinearOp< Scalar >::beginBlockFill ( ) [virtual]
template<class Scalar >
void Thyra::DefaultBlockedLinearOp< Scalar >::beginBlockFill ( const int  numRowBlocks,
const int  numColBlocks 
) [virtual]
template<class Scalar >
void Thyra::DefaultBlockedLinearOp< Scalar >::beginBlockFill ( const Teuchos::RCP< const ProductVectorSpaceBase< Scalar > > &  productRange,
const Teuchos::RCP< const ProductVectorSpaceBase< Scalar > > &  productDomain 
) [virtual]
template<class Scalar >
bool Thyra::DefaultBlockedLinearOp< Scalar >::blockFillIsActive ( ) const [virtual]
template<class Scalar >
bool Thyra::DefaultBlockedLinearOp< Scalar >::acceptsBlock ( const int  i,
const int  j 
) const [virtual]
template<class Scalar >
void Thyra::DefaultBlockedLinearOp< Scalar >::setNonconstBlock ( const int  i,
const int  j,
const Teuchos::RCP< LinearOpBase< Scalar > > &  block 
) [virtual]
template<class Scalar >
void Thyra::DefaultBlockedLinearOp< Scalar >::setBlock ( const int  i,
const int  j,
const Teuchos::RCP< const LinearOpBase< Scalar > > &  block 
) [virtual]
template<class Scalar >
void Thyra::DefaultBlockedLinearOp< Scalar >::endBlockFill ( ) [virtual]
template<class Scalar >
void Thyra::DefaultBlockedLinearOp< Scalar >::uninitialize ( ) [virtual]
template<class Scalar >
RCP< const ProductVectorSpaceBase< Scalar > > Thyra::DefaultBlockedLinearOp< Scalar >::productRange ( ) const [virtual]
template<class Scalar >
RCP< const ProductVectorSpaceBase< Scalar > > Thyra::DefaultBlockedLinearOp< Scalar >::productDomain ( ) const [virtual]
template<class Scalar >
bool Thyra::DefaultBlockedLinearOp< Scalar >::blockExists ( const int  i,
const int  j 
) const [virtual]
template<class Scalar >
bool Thyra::DefaultBlockedLinearOp< Scalar >::blockIsConst ( const int  i,
const int  j 
) const [virtual]
template<class Scalar >
RCP< LinearOpBase< Scalar > > Thyra::DefaultBlockedLinearOp< Scalar >::getNonconstBlock ( const int  i,
const int  j 
) [virtual]
template<class Scalar >
RCP< const LinearOpBase< Scalar > > Thyra::DefaultBlockedLinearOp< Scalar >::getBlock ( const int  i,
const int  j 
) const [virtual]
template<class Scalar >
RCP< const VectorSpaceBase< Scalar > > Thyra::DefaultBlockedLinearOp< Scalar >::range ( ) const [virtual]
template<class Scalar >
RCP< const VectorSpaceBase< Scalar > > Thyra::DefaultBlockedLinearOp< Scalar >::domain ( ) const [virtual]
template<class Scalar >
RCP< const LinearOpBase< Scalar > > Thyra::DefaultBlockedLinearOp< Scalar >::clone ( ) const [virtual]

Reimplemented from Thyra::LinearOpBase< Scalar >.

Definition at line 317 of file Thyra_DefaultBlockedLinearOp_def.hpp.

References Teuchos::null.

template<class Scalar >
std::string Thyra::DefaultBlockedLinearOp< Scalar >::description ( ) const [virtual]

Prints just the name DefaultBlockedLinearOp along with the overall dimensions and the number of constituent operators.

Reimplemented from Teuchos::Describable.

Definition at line 327 of file Thyra_DefaultBlockedLinearOp_def.hpp.

References Teuchos::Describable::description().

template<class Scalar >
void Thyra::DefaultBlockedLinearOp< Scalar >::describe ( Teuchos::FancyOStream out,
const Teuchos::EVerbosityLevel  verbLevel 
) const [virtual]

Prints the details about the constituent linear operators.

This function outputs different levels of detail based on the value passed in for verbLevel:

ToDo: Finish documentation!

Reimplemented from Teuchos::Describable.

Definition at line 341 of file Thyra_DefaultBlockedLinearOp_def.hpp.

References Teuchos::Describable::description(), Teuchos::RCP< T >::get(), Teuchos::VERB_DEFAULT, Teuchos::VERB_EXTREME, Teuchos::VERB_HIGH, Teuchos::VERB_LOW, and Teuchos::VERB_MEDIUM.

template<class Scalar >
bool Thyra::DefaultBlockedLinearOp< Scalar >::opSupportedImpl ( EOpTransp  M_trans) const [protected, virtual]

Returns true only if all constituent operators support M_trans.

Implements Thyra::LinearOpBase< Scalar >.

Definition at line 400 of file Thyra_DefaultBlockedLinearOp_def.hpp.

References Teuchos::RCP< T >::get().

template<class Scalar >
void Thyra::DefaultBlockedLinearOp< Scalar >::applyImpl ( const EOpTransp  M_trans,
const MultiVectorBase< Scalar > &  X,
const Ptr< MultiVectorBase< Scalar > > &  Y,
const Scalar  alpha,
const Scalar  beta 
) const [protected, virtual]
template<class Scalar >
void Thyra::DefaultBlockedLinearOp< Scalar >::resetStorage ( const int  numRowBlocks,
const int  numColBlocks 
) [private]

Definition at line 492 of file Thyra_DefaultBlockedLinearOp_def.hpp.

References is_null().

template<class Scalar >
void Thyra::DefaultBlockedLinearOp< Scalar >::assertBlockFillIsActive ( bool  wantedValue) const [private]

Definition at line 508 of file Thyra_DefaultBlockedLinearOp_def.hpp.

template<class Scalar >
void Thyra::DefaultBlockedLinearOp< Scalar >::assertBlockRowCol ( const int  i,
const int  j 
) const [private]

Definition at line 519 of file Thyra_DefaultBlockedLinearOp_def.hpp.

References TEST_FOR_EXCEPTION.

template<class Scalar >
void Thyra::DefaultBlockedLinearOp< Scalar >::setBlockSpaces ( const int  i,
const int  j,
const LinearOpBase< Scalar > &  block 
) [private]
template<class Scalar >
template<class LinearOpType >
void Thyra::DefaultBlockedLinearOp< Scalar >::setBlockImpl ( const int  i,
const int  j,
const Teuchos::RCP< LinearOpType > &  block 
) [private]
template<class Scalar >
void Thyra::DefaultBlockedLinearOp< Scalar >::adjustBlockSpaces ( ) [private]

Definition at line 651 of file Thyra_DefaultBlockedLinearOp_def.hpp.

References is_null(), and TEUCHOS_ASSERT_INEQUALITY.

template<class Scalar >
DefaultBlockedLinearOp& Thyra::DefaultBlockedLinearOp< Scalar >::operator= ( const DefaultBlockedLinearOp< Scalar > &  ) [private]

Friends And Related Function Documentation

template<class Scalar >
RCP< DefaultBlockedLinearOp< Scalar > > defaultBlockedLinearOp ( ) [related]

Nonmember default constructor.

template<class Scalar >
Teuchos::RCP< const LinearOpBase< Scalar > > block1x1 ( const Teuchos::RCP< const LinearOpBase< Scalar > > &  A00,
const std::string &  label = "" 
) [related]

Form an implicit block 1x1 linear operator [ A00 ].

template<class Scalar >
Teuchos::RCP< const LinearOpBase< Scalar > > block1x2 ( const Teuchos::RCP< const LinearOpBase< Scalar > > &  A00,
const Teuchos::RCP< const LinearOpBase< Scalar > > &  A01,
const std::string &  label = "" 
) [related]

Form an implicit block 1x2 linear operator [ A00, A01 ].

Referenced by exampleImplicitlyComposedLinearOperators().

template<class Scalar >
Teuchos::RCP< const LinearOpBase< Scalar > > block2x1 ( const Teuchos::RCP< const LinearOpBase< Scalar > > &  A00,
const Teuchos::RCP< const LinearOpBase< Scalar > > &  A10,
const std::string &  label = "" 
) [related]

Form an implicit block 2x1 linear operator [ A00; A10 ].

Referenced by exampleImplicitlyComposedLinearOperators().

template<class Scalar >
Teuchos::RCP< const LinearOpBase< Scalar > > block2x2 ( const Teuchos::RCP< const LinearOpBase< Scalar > > &  A00,
const Teuchos::RCP< const LinearOpBase< Scalar > > &  A01,
const Teuchos::RCP< const LinearOpBase< Scalar > > &  A10,
const Teuchos::RCP< const LinearOpBase< Scalar > > &  A11,
const std::string &  label = "" 
) [related]

Form an implicit block 2x2 linear operator [ A00, A01; A10, A11 ].

Referenced by exampleImplicitlyComposedLinearOperators().

template<class Scalar >
Teuchos::RCP< LinearOpBase< Scalar > > nonconstBlock1x1 ( const Teuchos::RCP< LinearOpBase< Scalar > > &  A00,
const std::string &  label = "" 
) [related]

Form an implicit block 1x1 linear operator [ A00 ].

template<class Scalar >
Teuchos::RCP< LinearOpBase< Scalar > > nonconstBlock1x2 ( const Teuchos::RCP< LinearOpBase< Scalar > > &  A00,
const Teuchos::RCP< LinearOpBase< Scalar > > &  A01,
const std::string &  label = "" 
) [related]

Form an implicit block 1x2 linear operator [ A00, A01 ].

template<class Scalar >
Teuchos::RCP< LinearOpBase< Scalar > > nonconstBlock2x1 ( const Teuchos::RCP< LinearOpBase< Scalar > > &  A00,
const Teuchos::RCP< LinearOpBase< Scalar > > &  A10,
const std::string &  label = "" 
) [related]

Form an implicit block 2x1 linear operator [ A00; A10 ].

template<class Scalar >
Teuchos::RCP< LinearOpBase< Scalar > > nonconstBlock2x2 ( const Teuchos::RCP< LinearOpBase< Scalar > > &  A00,
const Teuchos::RCP< LinearOpBase< Scalar > > &  A01,
const Teuchos::RCP< LinearOpBase< Scalar > > &  A10,
const Teuchos::RCP< LinearOpBase< Scalar > > &  A11,
const std::string &  label = "" 
) [related]

Form an implicit block 2x2 linear operator [ A00, A01; A10, A11 ].


Member Data Documentation

template<class Scalar >
Teuchos::RCP<const ProductVectorSpaceBase<Scalar> > Thyra::DefaultBlockedLinearOp< Scalar >::productRange_ [private]

Definition at line 220 of file Thyra_DefaultBlockedLinearOp_decl.hpp.

template<class Scalar >
Teuchos::RCP<const ProductVectorSpaceBase<Scalar> > Thyra::DefaultBlockedLinearOp< Scalar >::productDomain_ [private]

Definition at line 221 of file Thyra_DefaultBlockedLinearOp_decl.hpp.

template<class Scalar >
Teuchos::RCP<const DefaultProductVectorSpace<Scalar> > Thyra::DefaultBlockedLinearOp< Scalar >::defaultProductRange_ [private]

Definition at line 222 of file Thyra_DefaultBlockedLinearOp_decl.hpp.

template<class Scalar >
Teuchos::RCP<const DefaultProductVectorSpace<Scalar> > Thyra::DefaultBlockedLinearOp< Scalar >::defaultProductDomain_ [private]

Definition at line 223 of file Thyra_DefaultBlockedLinearOp_decl.hpp.

template<class Scalar >
int Thyra::DefaultBlockedLinearOp< Scalar >::numRowBlocks_ [private]

Definition at line 224 of file Thyra_DefaultBlockedLinearOp_decl.hpp.

template<class Scalar >
int Thyra::DefaultBlockedLinearOp< Scalar >::numColBlocks_ [private]

Definition at line 225 of file Thyra_DefaultBlockedLinearOp_decl.hpp.

template<class Scalar >
std::vector<CNCLO> Thyra::DefaultBlockedLinearOp< Scalar >::Ops_ [private]

Definition at line 227 of file Thyra_DefaultBlockedLinearOp_decl.hpp.

template<class Scalar >
vec_array_t Thyra::DefaultBlockedLinearOp< Scalar >::rangeBlocks_ [private]

Definition at line 229 of file Thyra_DefaultBlockedLinearOp_decl.hpp.

template<class Scalar >
vec_array_t Thyra::DefaultBlockedLinearOp< Scalar >::domainBlocks_ [private]

Definition at line 230 of file Thyra_DefaultBlockedLinearOp_decl.hpp.

template<class Scalar >
std::vector<BlockEntry<Scalar> > Thyra::DefaultBlockedLinearOp< Scalar >::Ops_stack_ [private]

Definition at line 231 of file Thyra_DefaultBlockedLinearOp_decl.hpp.

template<class Scalar >
bool Thyra::DefaultBlockedLinearOp< Scalar >::blockFillIsActive_ [private]

Definition at line 232 of file Thyra_DefaultBlockedLinearOp_decl.hpp.


The documentation for this class was generated from the following files:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines