Thyra  Version of the Day
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
List of all members
Thyra::VectorDefaultBase< Scalar > Class Template Reference

Convenient node subclass for concrete VectorBase subclasses that relies on a default MultiVectorBase implementation. More...

#include <Thyra_VectorDefaultBase_decl.hpp>

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

Public functions overridden from Teuchos::Describable

virtual std::string description () const
 Default description that gives the label, type, and dimenstion . More...
 
virtual void describe (Teuchos::FancyOStream &out, const Teuchos::EVerbosityLevel verbLevel) const
 Generates a default outputting for all vectors. More...
 

Overridden from LinearOpBase

virtual RCP< const
VectorSpaceBase< Scalar > > 
range () const
 Returns this->space(). More...
 
virtual RCP< const
VectorSpaceBase< Scalar > > 
domain () const
 Returns a DefaultSerialVectorSpace object with dimension 1. More...
 

Overridden from MultiVectorBase

RCP< MultiVectorBase< Scalar > > clone_mv () const
 Returns this->clone_v(). More...
 

Overridden from VectorBase

RCP< VectorBase< Scalar > > clone_v () const
 Simply creates a new vector and copies the contents from *this. More...
 

Overridden protected functions from MultiVectorBase

virtual void assignVecImpl (const VectorBase< Scalar > &x)
 Default implementation of assign(vector) using RTOps. More...
 
virtual void randomizeImpl (Scalar l, Scalar u)
 Default implementation of randomize using RTOps. More...
 
virtual void absImpl (const VectorBase< Scalar > &x)
 Default implementation of abs using RTOps. More...
 
virtual void reciprocalImpl (const VectorBase< Scalar > &x)
 Default implementation of reciprocal using RTOps. More...
 
virtual void eleWiseScaleImpl (const VectorBase< Scalar > &x)
 Default implementation of ele_wise_scale using RTOps. More...
 
virtual void updateVecImpl (Scalar alpha, const VectorBase< Scalar > &x)
 Default implementation of update using RTOps. More...
 
virtual void linearCombinationVecImpl (const ArrayView< const Scalar > &alpha, const ArrayView< const Ptr< const VectorBase< Scalar > > > &x, const Scalar &beta)
 Default implementation of linear_combination using RTOps. More...
 
virtual Scalar dotImpl (const VectorBase< Scalar > &x) const
 Default implementation of dot using RTOps. More...
 
virtual Teuchos::ScalarTraits
< Scalar >::magnitudeType 
norm1Impl () const
 Default implementation of norm_1 using RTOps. More...
 
virtual Teuchos::ScalarTraits
< Scalar >::magnitudeType 
norm2Impl () const
 Default implementation of norm_2 using RTOps. More...
 
virtual Teuchos::ScalarTraits
< Scalar >::magnitudeType 
norm2WeightedImpl (const VectorBase< Scalar > &x) const
 Default implementation of norm_2 (weighted) using RTOps. More...
 
virtual Teuchos::ScalarTraits
< Scalar >::magnitudeType 
normInfImpl () const
 Default implementation of norm_inf using RTOps. More...
 
virtual RCP< VectorBase< Scalar > > nonconstColImpl (Ordinal j)
 Returns Teuchos::rcp(this,false). More...
 
virtual RCP< const
MultiVectorBase< Scalar > > 
contigSubViewImpl (const Range1D &col_rng) const
 Returns Teuchos::rcp(this,false). More...
 
virtual RCP< MultiVectorBase
< Scalar > > 
nonconstContigSubViewImpl (const Range1D &col_rng)
 Returns Teuchos::rcp(this,false). More...
 
virtual RCP< const
MultiVectorBase< Scalar > > 
nonContigSubViewImpl (const ArrayView< const int > &cols) const
 Returns Teuchos::rcp(this,false). More...
 
virtual RCP< MultiVectorBase
< Scalar > > 
nonconstNonContigSubViewImpl (const ArrayView< const int > &cols)
 Returns Teuchos::rcp(this,false). More...
 
virtual void acquireDetachedMultiVectorViewImpl (const Range1D &rowRng, const Range1D &colRng, RTOpPack::ConstSubMultiVectorView< Scalar > *sub_mv) const
 Implemented in terms of this->acquireDetachedView(). More...
 
virtual void releaseDetachedMultiVectorViewImpl (RTOpPack::ConstSubMultiVectorView< Scalar > *sub_mv) const
 Implemented in terms of this->releaseDetachedView(). More...
 
virtual void acquireNonconstDetachedMultiVectorViewImpl (const Range1D &rowRng, const Range1D &colRng, RTOpPack::SubMultiVectorView< Scalar > *sub_mv)
 Implemented in terms of this->acquireDetachedView(). More...
 
virtual void commitNonconstDetachedMultiVectorViewImpl (RTOpPack::SubMultiVectorView< Scalar > *sub_mv)
 Implemented in terms of this->commitDetachedView(). More...
 

Overridden protected functions from VectorBase

virtual void acquireDetachedVectorViewImpl (const Range1D &rng, RTOpPack::ConstSubVectorView< Scalar > *sub_vec) const
 
virtual void releaseDetachedVectorViewImpl (RTOpPack::ConstSubVectorView< Scalar > *sub_vec) const
 
virtual void acquireNonconstDetachedVectorViewImpl (const Range1D &rng, RTOpPack::SubVectorView< Scalar > *sub_vec)
 
virtual void commitNonconstDetachedVectorViewImpl (RTOpPack::SubVectorView< Scalar > *sub_vec)
 
virtual void setSubVectorImpl (const RTOpPack::SparseSubVectorT< Scalar > &sub_vec)
 

Overridden protected functions from LinearOpBase

bool opSupportedImpl (EOpTransp M_trans) const
 For complex Scalar types returns true for NOTRANS and CONJTRANS and for real types returns true for all values of M_trans. More...
 
void applyImpl (const EOpTransp M_trans, const MultiVectorBase< Scalar > &X, const Ptr< MultiVectorBase< Scalar > > &Y, const Scalar alpha, const Scalar beta) const
 . Applies vector or its adjoint (transpose) as a linear operator. More...
 

Additional Inherited Members

- Public Member Functions inherited from Thyra::VectorBase< Scalar >
void assign (const VectorBase< Scalar > &x)
 Vector assignment: More...
 
void randomize (Scalar l, Scalar u)
 Random vector generation: More...
 
void update (Scalar alpha, const VectorBase< Scalar > &x)
 AXPY: More...
 
void linear_combination (const ArrayView< const Scalar > &alpha, const ArrayView< const Ptr< const VectorBase< Scalar > > > &x, const Scalar &beta)
 Linear combination: More...
 
Scalar dot (const VectorBase< Scalar > &x) const
 Euclidean dot product: result = x^H * this. More...
 
Teuchos::ScalarTraits< Scalar >
::magnitudeType 
norm_1 () const
 One (1) norm: result = ||v||1. More...
 
Teuchos::ScalarTraits< Scalar >
::magnitudeType 
norm_2 () const
 Euclidean (2) norm: result = ||v||2. More...
 
Teuchos::ScalarTraits< Scalar >
::magnitudeType 
norm_2 (const VectorBase< Scalar > &x) const
 Weighted Euclidean (2) norm: result = ||v||2. More...
 
Teuchos::ScalarTraits< Scalar >
::magnitudeType 
norm_inf () const
 Infinity norm: result = ||v||inf. More...
 
virtual RCP< const
VectorSpaceBase< Scalar > > 
space () const =0
 Return a smart pointer to the vector space that this vector belongs to. More...
 
void applyOp (const RTOpPack::RTOpT< Scalar > &op, const ArrayView< const Ptr< const VectorBase< Scalar > > > &vecs, const ArrayView< const Ptr< VectorBase< Scalar > > > &targ_vecs, const Ptr< RTOpPack::ReductTarget > &reduct_obj, const Ordinal global_offset) const
 Calls applyOpImpl(). More...
 
void acquireDetachedView (const Range1D &rng, RTOpPack::ConstSubVectorView< Scalar > *sub_vec) const
 Calls acquireDetachedVectorViewImpl(). More...
 
void releaseDetachedView (RTOpPack::ConstSubVectorView< Scalar > *sub_vec) const
 Calls releaseDetachedVectorViewImpl(). More...
 
void acquireDetachedView (const Range1D &rng, RTOpPack::SubVectorView< Scalar > *sub_vec)
 Calls acquireNonconstDetachedVectorViewImpl(). More...
 
void commitDetachedView (RTOpPack::SubVectorView< Scalar > *sub_vec)
 Calls commitDetachedView(). More...
 
void setSubVector (const RTOpPack::SparseSubVectorT< Scalar > &sub_vec)
 Calls setSubVectorImpl(). More...
 
- Public Member Functions inherited from Thyra::MultiVectorBase< Scalar >
void assign (Scalar alpha)
 V = alpha. More...
 
void assign (const MultiVectorBase< Scalar > &mv)
 V = mv. More...
 
void scale (Scalar alpha)
 
void update (Scalar alpha, const MultiVectorBase< Scalar > &mv)
 
void linear_combination (const ArrayView< const Scalar > &alpha, const ArrayView< const Ptr< const MultiVectorBase< Scalar > > > &mv, const Scalar &beta)
 Y.col(j)(i) = beta*Y.col(j)(i) + sum( alpha[k]*X[k].col(j)(i), More...
 
void dots (const MultiVectorBase< Scalar > &mv, const ArrayView< Scalar > &prods) const
 Column-wise Euclidean dot product. More...
 
void norms_1 (const ArrayView< typename ScalarTraits< Scalar >::magnitudeType > &norms) const
 Column-wise 1-norms. More...
 
void norms_2 (const ArrayView< typename ScalarTraits< Scalar >::magnitudeType > &norms) const
 Column-wise 2-norms. More...
 
void norms_inf (const ArrayView< typename ScalarTraits< Scalar >::magnitudeType > &norms) const
 Column-wise infinity-norms. More...
 
RCP< const VectorBase< Scalar > > col (Ordinal j) const
 Calls colImpl(). More...
 
RCP< VectorBase< Scalar > > col (Ordinal j)
 Calls nonconstColImpl(). More...
 
RCP< const MultiVectorBase
< Scalar > > 
subView (const Range1D &colRng) const
 Calls contigSubViewImpl(). More...
 
RCP< MultiVectorBase< Scalar > > subView (const Range1D &colRng)
 Calls nonconstContigSubViewImpl(). More...
 
RCP< const MultiVectorBase
< Scalar > > 
subView (const ArrayView< const int > &cols) const
 nonContigSubViewImpl(). More...
 
RCP< MultiVectorBase< Scalar > > subView (const ArrayView< const int > &cols)
 nonconstNonContigSubViewImpl(). More...
 
void applyOp (const RTOpPack::RTOpT< Scalar > &primary_op, const ArrayView< const Ptr< const MultiVectorBase< Scalar > > > &multi_vecs, const ArrayView< const Ptr< MultiVectorBase< Scalar > > > &targ_multi_vecs, const ArrayView< const Ptr< RTOpPack::ReductTarget > > &reduct_objs, const Ordinal primary_global_offset) const
 Calls mvMultiReductApplyOpImpl(). More...
 
void applyOp (const RTOpPack::RTOpT< Scalar > &primary_op, const RTOpPack::RTOpT< Scalar > &secondary_op, const ArrayView< const Ptr< const MultiVectorBase< Scalar > > > &multi_vecs, const ArrayView< const Ptr< MultiVectorBase< Scalar > > > &targ_multi_vecs, const Ptr< RTOpPack::ReductTarget > &reduct_obj, const Ordinal primary_global_offset) const
 mvSingleReductApplyOpImpl(). More...
 
void acquireDetachedView (const Range1D &rowRng, const Range1D &colRng, RTOpPack::ConstSubMultiVectorView< Scalar > *sub_mv) const
 Calls acquireDetachedMultiVectorViewImpl(). More...
 
void releaseDetachedView (RTOpPack::ConstSubMultiVectorView< Scalar > *sub_mv) const
 Calls releaseDetachedMultiVectorViewImpl(). More...
 
void acquireDetachedView (const Range1D &rowRng, const Range1D &colRng, RTOpPack::SubMultiVectorView< Scalar > *sub_mv)
 Calls acquireNonconstDetachedMultiVectorViewImpl(). More...
 
void commitDetachedView (RTOpPack::SubMultiVectorView< Scalar > *sub_mv)
 Calls commitNonconstDetachedMultiVectorViewImpl(). More...
 
RCP< const LinearOpBase< Scalar > > clone () const
 This function is simply overridden to return this->clone_mv(). More...
 
- Public Member Functions inherited from Thyra::LinearOpBase< Scalar >
bool opSupported (EOpTransp M_trans) const
 Return if the M_trans operation of apply() is supported or not. More...
 
void apply (const EOpTransp M_trans, const MultiVectorBase< Scalar > &X, const Ptr< MultiVectorBase< Scalar > > &Y, const Scalar alpha, const Scalar beta) const
 Apply the linear operator to a multi-vector : Y = alpha*op(M)*X + beta*Y. More...
 
- Public Member Functions inherited from Thyra::RowStatLinearOpBase< Scalar >
bool rowStatIsSupported (const RowStatLinearOpBaseUtils::ERowStat rowStat) const
 Determine if a given row stat is supported. More...
 
void getRowStat (const RowStatLinearOpBaseUtils::ERowStat rowStat, const Ptr< VectorBase< Scalar > > &rowStatVec) const
 Get some statistics about a supported row. More...
 
- Public Member Functions inherited from Thyra::ScaledLinearOpBase< Scalar >
bool supportsScaleLeft () const
 Determines if this objects supports left scaling. More...
 
bool supportsScaleRight () const
 Determines if this objects supports right scaling. More...
 
void scaleLeft (const VectorBase< Scalar > &row_scaling)
 Left scales operator with diagonal scaling operator. More...
 
void scaleRight (const VectorBase< Scalar > &col_scaling)
 Right scales operator with diagonal scaling operator. More...
 
- Protected Member Functions inherited from Thyra::VectorBase< Scalar >
virtual void applyOpImpl (const RTOpPack::RTOpT< Scalar > &op, const ArrayView< const Ptr< const VectorBase< Scalar > > > &vecs, const ArrayView< const Ptr< VectorBase< Scalar > > > &targ_vecs, const Ptr< RTOpPack::ReductTarget > &reduct_obj, const Ordinal global_offset) const =0
 Apply a reduction/transformation operator over a set of vectors: op(op(v[0]...v[nv-1],z[0]...z[nz-1]),(*reduct_obj)) -> z[0]...z[nz-1],(*reduct_obj). More...
 
- Protected Member Functions inherited from Thyra::MultiVectorBase< Scalar >
void absRowSum (const Teuchos::Ptr< Thyra::VectorBase< Scalar > > &output) const
 
void absColSum (const Teuchos::Ptr< Thyra::VectorBase< Scalar > > &output) const
 
virtual RCP< const VectorBase
< Scalar > > 
colImpl (Ordinal j) const
 Return a non-changeable view of a constituent column vector. More...
 
virtual bool rowStatIsSupportedImpl (const RowStatLinearOpBaseUtils::ERowStat rowStat) const
 
virtual void getRowStatImpl (const RowStatLinearOpBaseUtils::ERowStat rowStat, const Ptr< VectorBase< Scalar > > &rowStatVec) const
 
virtual bool supportsScaleLeftImpl () const
 
virtual bool supportsScaleRightImpl () const
 
virtual void scaleLeftImpl (const VectorBase< Scalar > &row_scaling)
 
virtual void scaleRightImpl (const VectorBase< Scalar > &col_scaling)
 
- Protected Member Functions inherited from Thyra::LinearOpBase< Scalar >
- Protected Member Functions inherited from Thyra::RowStatLinearOpBase< Scalar >
- Protected Member Functions inherited from Thyra::ScaledLinearOpBase< Scalar >
- Protected Member Functions inherited from Thyra::MultiVectorDefaultBase< Scalar >
virtual void assignImpl (Scalar alpha)
 Default implementation of assign(scalar) using RTOps. More...
 
virtual void assignMultiVecImpl (const MultiVectorBase< Scalar > &mv)
 Default implementation of assign(MV) using RTOps. More...
 
virtual void scaleImpl (Scalar alpha)
 Default implementation of scale using RTOps. More...
 
virtual void updateImpl (Scalar alpha, const MultiVectorBase< Scalar > &mv)
 Default implementation of update using RTOps. More...
 
virtual void linearCombinationImpl (const ArrayView< const Scalar > &alpha, const ArrayView< const Ptr< const MultiVectorBase< Scalar > > > &mv, const Scalar &beta)
 Default implementation of linear_combination using RTOps. More...
 
virtual void dotsImpl (const MultiVectorBase< Scalar > &mv, const ArrayView< Scalar > &prods) const
 Default implementation of dots using RTOps. More...
 
virtual void norms1Impl (const ArrayView< typename ScalarTraits< Scalar >::magnitudeType > &norms) const
 Default implementation of norms_1 using RTOps. More...
 
virtual void norms2Impl (const ArrayView< typename ScalarTraits< Scalar >::magnitudeType > &norms) const
 Default implementation of norms_2 using RTOps. More...
 
virtual void normsInfImpl (const ArrayView< typename ScalarTraits< Scalar >::magnitudeType > &norms) const
 Default implementation of norms_inf using RTOps. More...
 
virtual void mvMultiReductApplyOpImpl (const RTOpPack::RTOpT< Scalar > &primary_op, const ArrayView< const Ptr< const MultiVectorBase< Scalar > > > &multi_vecs, const ArrayView< const Ptr< MultiVectorBase< Scalar > > > &targ_multi_vecs, const ArrayView< const Ptr< RTOpPack::ReductTarget > > &reduct_objs, const Ordinal primary_global_offset) const
 
virtual void mvSingleReductApplyOpImpl (const RTOpPack::RTOpT< Scalar > &primary_op, const RTOpPack::RTOpT< Scalar > &secondary_op, const ArrayView< const Ptr< const MultiVectorBase< Scalar > > > &multi_vecs, const ArrayView< const Ptr< MultiVectorBase< Scalar > > > &targ_multi_vecs, const Ptr< RTOpPack::ReductTarget > &reduct_obj, const Ordinal primary_global_offset) const
 
- Protected Member Functions inherited from Thyra::LinearOpDefaultBase< Scalar >

Detailed Description

template<class Scalar>
class Thyra::VectorDefaultBase< Scalar >

Convenient node subclass for concrete VectorBase subclasses that relies on a default MultiVectorBase implementation.

Notes for subclass developers

In order to create a concrete subclass of this interface, only two operations must be overridden: space() and applyOp(). Overriding the space() operation requires defining a concrete VectorSpaceBase class (which has only three pure virtual operations if using VectorSpaceDefaultBase).

Note that all of the inherited LinearOpBase and MultiVectorBase functions are overridden in this subclass and are given perfectly good implementations. Therefore, a concrete subclass of VectorDefaultBase should not have to re-override any of these functions.

Definition at line 41 of file Thyra_VectorDefaultBase_decl.hpp.

Member Function Documentation

template<class Scalar >
std::string Thyra::VectorDefaultBase< Scalar >::description ( ) const
virtual

Default description that gives the label, type, and dimenstion .

Reimplemented from Thyra::LinearOpDefaultBase< Scalar >.

Reimplemented in Thyra::DefaultProductVector< Scalar >, Thyra::SpmdVectorDefaultBase< Scalar >, and Thyra::DefaultMultiVectorProductVector< Scalar >.

Definition at line 58 of file Thyra_VectorDefaultBase_def.hpp.

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

Generates a default outputting for all vectors.

Calls on the this->describe(void) function for the name of the class (and possibly its instance name) and then if verbLevel>=VERB_HIGH, then the vector elements themselves are printed as well. The format of the output is is shown below:

type = 'this->description()', size = n
  0:x1
  1:x2
  .
  .
  .
  n-1:xn

The index:value lines are offset an additional Teuchos::OSTab amount. A newline is printed after the last n-1:xn entry.

Reimplemented from Thyra::LinearOpDefaultBase< Scalar >.

Reimplemented in Thyra::DefaultProductVector< Scalar >, and Thyra::DefaultMultiVectorProductVector< Scalar >.

Definition at line 75 of file Thyra_VectorDefaultBase_def.hpp.

template<class Scalar >
RCP< const VectorSpaceBase< Scalar > > Thyra::VectorDefaultBase< Scalar >::range ( ) const
virtual

Returns this->space().

Implements Thyra::LinearOpBase< Scalar >.

Definition at line 101 of file Thyra_VectorDefaultBase_def.hpp.

template<class Scalar >
RCP< const VectorSpaceBase< Scalar > > Thyra::VectorDefaultBase< Scalar >::domain ( ) const
virtual

Returns a DefaultSerialVectorSpace object with dimension 1.

Implements Thyra::LinearOpBase< Scalar >.

Reimplemented in Thyra::TpetraVector< Scalar, LocalOrdinal, GlobalOrdinal, Node >.

Definition at line 115 of file Thyra_VectorDefaultBase_def.hpp.

template<class Scalar >
RCP< MultiVectorBase< Scalar > > Thyra::VectorDefaultBase< Scalar >::clone_mv ( ) const
virtual

Returns this->clone_v().

Reimplemented from Thyra::MultiVectorDefaultBase< Scalar >.

Definition at line 135 of file Thyra_VectorDefaultBase_def.hpp.

template<class Scalar >
RCP< VectorBase< Scalar > > Thyra::VectorDefaultBase< Scalar >::clone_v ( ) const
virtual

Simply creates a new vector and copies the contents from *this.

Implements Thyra::VectorBase< Scalar >.

Definition at line 152 of file Thyra_VectorDefaultBase_def.hpp.

template<class Scalar >
void Thyra::VectorDefaultBase< Scalar >::assignVecImpl ( const VectorBase< Scalar > &  x)
protectedvirtual

Default implementation of assign(vector) using RTOps.

Implements Thyra::VectorBase< Scalar >.

Definition at line 170 of file Thyra_VectorDefaultBase_def.hpp.

template<class Scalar >
void Thyra::VectorDefaultBase< Scalar >::randomizeImpl ( Scalar  l,
Scalar  u 
)
protectedvirtual

Default implementation of randomize using RTOps.

Implements Thyra::VectorBase< Scalar >.

Reimplemented in Thyra::DefaultMultiVectorProductVector< Scalar >, and Thyra::TpetraVector< Scalar, LocalOrdinal, GlobalOrdinal, Node >.

Definition at line 177 of file Thyra_VectorDefaultBase_def.hpp.

template<class Scalar >
void Thyra::VectorDefaultBase< Scalar >::absImpl ( const VectorBase< Scalar > &  x)
protectedvirtual
template<class Scalar >
void Thyra::VectorDefaultBase< Scalar >::reciprocalImpl ( const VectorBase< Scalar > &  x)
protectedvirtual
template<class Scalar >
void Thyra::VectorDefaultBase< Scalar >::eleWiseScaleImpl ( const VectorBase< Scalar > &  x)
protectedvirtual
template<class Scalar >
void Thyra::VectorDefaultBase< Scalar >::updateVecImpl ( Scalar  alpha,
const VectorBase< Scalar > &  x 
)
protectedvirtual

Default implementation of update using RTOps.

Implements Thyra::VectorBase< Scalar >.

Definition at line 219 of file Thyra_VectorDefaultBase_def.hpp.

template<class Scalar >
void Thyra::VectorDefaultBase< Scalar >::linearCombinationVecImpl ( const ArrayView< const Scalar > &  alpha,
const ArrayView< const Ptr< const VectorBase< Scalar > > > &  x,
const Scalar &  beta 
)
protectedvirtual

Default implementation of linear_combination using RTOps.

Implements Thyra::VectorBase< Scalar >.

Definition at line 228 of file Thyra_VectorDefaultBase_def.hpp.

template<class Scalar >
Scalar Thyra::VectorDefaultBase< Scalar >::dotImpl ( const VectorBase< Scalar > &  x) const
protectedvirtual

Default implementation of dot using RTOps.

Implements Thyra::VectorBase< Scalar >.

Definition at line 242 of file Thyra_VectorDefaultBase_def.hpp.

template<class Scalar >
Teuchos::ScalarTraits< Scalar >::magnitudeType Thyra::VectorDefaultBase< Scalar >::norm1Impl ( ) const
protectedvirtual

Default implementation of norm_1 using RTOps.

Implements Thyra::VectorBase< Scalar >.

Definition at line 252 of file Thyra_VectorDefaultBase_def.hpp.

template<class Scalar >
Teuchos::ScalarTraits< Scalar >::magnitudeType Thyra::VectorDefaultBase< Scalar >::norm2Impl ( ) const
protectedvirtual

Default implementation of norm_2 using RTOps.

Implements Thyra::VectorBase< Scalar >.

Definition at line 262 of file Thyra_VectorDefaultBase_def.hpp.

template<class Scalar >
Teuchos::ScalarTraits< Scalar >::magnitudeType Thyra::VectorDefaultBase< Scalar >::norm2WeightedImpl ( const VectorBase< Scalar > &  x) const
protectedvirtual
template<class Scalar >
Teuchos::ScalarTraits< Scalar >::magnitudeType Thyra::VectorDefaultBase< Scalar >::normInfImpl ( ) const
protectedvirtual

Default implementation of norm_inf using RTOps.

Implements Thyra::VectorBase< Scalar >.

Definition at line 286 of file Thyra_VectorDefaultBase_def.hpp.

template<class Scalar >
RCP< VectorBase< Scalar > > Thyra::VectorDefaultBase< Scalar >::nonconstColImpl ( Ordinal  j)
protectedvirtual

Returns Teuchos::rcp(this,false).

Implements Thyra::MultiVectorBase< Scalar >.

Definition at line 299 of file Thyra_VectorDefaultBase_def.hpp.

template<class Scalar >
RCP< const MultiVectorBase< Scalar > > Thyra::VectorDefaultBase< Scalar >::contigSubViewImpl ( const Range1D col_rng) const
protectedvirtual

Returns Teuchos::rcp(this,false).

Reimplemented from Thyra::MultiVectorDefaultBase< Scalar >.

Definition at line 317 of file Thyra_VectorDefaultBase_def.hpp.

template<class Scalar >
RCP< MultiVectorBase< Scalar > > Thyra::VectorDefaultBase< Scalar >::nonconstContigSubViewImpl ( const Range1D col_rng)
protectedvirtual

Returns Teuchos::rcp(this,false).

Reimplemented from Thyra::MultiVectorDefaultBase< Scalar >.

Definition at line 332 of file Thyra_VectorDefaultBase_def.hpp.

template<class Scalar >
RCP< const MultiVectorBase< Scalar > > Thyra::VectorDefaultBase< Scalar >::nonContigSubViewImpl ( const ArrayView< const int > &  cols) const
protectedvirtual

Returns Teuchos::rcp(this,false).

Reimplemented from Thyra::MultiVectorDefaultBase< Scalar >.

Definition at line 347 of file Thyra_VectorDefaultBase_def.hpp.

template<class Scalar >
RCP< MultiVectorBase< Scalar > > Thyra::VectorDefaultBase< Scalar >::nonconstNonContigSubViewImpl ( const ArrayView< const int > &  cols)
protectedvirtual

Returns Teuchos::rcp(this,false).

Reimplemented from Thyra::MultiVectorDefaultBase< Scalar >.

Definition at line 363 of file Thyra_VectorDefaultBase_def.hpp.

template<class Scalar >
void Thyra::VectorDefaultBase< Scalar >::acquireDetachedMultiVectorViewImpl ( const Range1D rowRng,
const Range1D colRng,
RTOpPack::ConstSubMultiVectorView< Scalar > *  sub_mv 
) const
protectedvirtual

Implemented in terms of this->acquireDetachedView().

Reimplemented from Thyra::MultiVectorDefaultBase< Scalar >.

Definition at line 378 of file Thyra_VectorDefaultBase_def.hpp.

template<class Scalar >
void Thyra::VectorDefaultBase< Scalar >::releaseDetachedMultiVectorViewImpl ( RTOpPack::ConstSubMultiVectorView< Scalar > *  sub_mv) const
protectedvirtual

Implemented in terms of this->releaseDetachedView().

Reimplemented from Thyra::MultiVectorDefaultBase< Scalar >.

Definition at line 404 of file Thyra_VectorDefaultBase_def.hpp.

template<class Scalar >
void Thyra::VectorDefaultBase< Scalar >::acquireNonconstDetachedMultiVectorViewImpl ( const Range1D rowRng,
const Range1D colRng,
RTOpPack::SubMultiVectorView< Scalar > *  sub_mv 
)
protectedvirtual

Implemented in terms of this->acquireDetachedView().

Reimplemented from Thyra::MultiVectorDefaultBase< Scalar >.

Definition at line 414 of file Thyra_VectorDefaultBase_def.hpp.

template<class Scalar >
void Thyra::VectorDefaultBase< Scalar >::commitNonconstDetachedMultiVectorViewImpl ( RTOpPack::SubMultiVectorView< Scalar > *  sub_mv)
protectedvirtual

Implemented in terms of this->commitDetachedView().

Reimplemented from Thyra::MultiVectorDefaultBase< Scalar >.

Definition at line 440 of file Thyra_VectorDefaultBase_def.hpp.

template<class Scalar >
void Thyra::VectorDefaultBase< Scalar >::acquireDetachedVectorViewImpl ( const Range1D rng,
RTOpPack::ConstSubVectorView< Scalar > *  sub_vec 
) const
protectedvirtual

This implementation is based on a vector reduction operator class (see RTOpPack::ROpGetSubVector) and calls applyOp(). Note that the footprint of the reduction object (both internal and external state) will be O(rng.size()). For serial applications this is fairly reasonable and will not be a major performance penalty. For parallel applications, however, this is a terrible implementation and must be overridden if rng.size() is large at all. Although, this function should not even be used in case where the vector is very large. If a subclass does override this function, it must also override releaseDetachedView() which has a implementation which is a companion to this function's implementation.

Implements Thyra::VectorBase< Scalar >.

Reimplemented in Thyra::DefaultProductVector< Scalar >, Thyra::DefaultMultiVectorProductVector< Scalar >, Thyra::SpmdVectorDefaultBase< Scalar >, and Thyra::TpetraVector< Scalar, LocalOrdinal, GlobalOrdinal, Node >.

Definition at line 464 of file Thyra_VectorDefaultBase_def.hpp.

template<class Scalar >
void Thyra::VectorDefaultBase< Scalar >::releaseDetachedVectorViewImpl ( RTOpPack::ConstSubVectorView< Scalar > *  sub_vec) const
protectedvirtual

This implementation is a companion to the implementation for the non-const version of acquireDetachedView(). If acquireDetachedView() is overridden by a subclass then this function must be overridden also!

Implements Thyra::VectorBase< Scalar >.

Reimplemented in Thyra::DefaultProductVector< Scalar >, Thyra::DefaultMultiVectorProductVector< Scalar >, and Thyra::SpmdVectorDefaultBase< Scalar >.

Definition at line 492 of file Thyra_VectorDefaultBase_def.hpp.

template<class Scalar >
void Thyra::VectorDefaultBase< Scalar >::acquireNonconstDetachedVectorViewImpl ( const Range1D rng,
RTOpPack::SubVectorView< Scalar > *  sub_vec 
)
protectedvirtual

This implementation is based on a vector reduction operator class (see RTOpPack::ROpGetSubVector) and calls applyOp(). Note that the footprint of the reduction object (both internal and external state) will be O(rng.size()). For serial applications this is fairly reasonable and will not be a major performance penalty. For parallel applications, this will be a terrible thing to do and must be overridden if rng.size() is large at all. If a subclass does override this function, it must also override commitDetachedView() which has a implementation which is a companion to this function's implementation.

Implements Thyra::VectorBase< Scalar >.

Reimplemented in Thyra::DefaultProductVector< Scalar >, Thyra::DefaultMultiVectorProductVector< Scalar >, Thyra::SpmdVectorDefaultBase< Scalar >, and Thyra::TpetraVector< Scalar, LocalOrdinal, GlobalOrdinal, Node >.

Definition at line 502 of file Thyra_VectorDefaultBase_def.hpp.

template<class Scalar >
void Thyra::VectorDefaultBase< Scalar >::commitNonconstDetachedVectorViewImpl ( RTOpPack::SubVectorView< Scalar > *  sub_vec)
protectedvirtual

This function has an implementation which is a companion to the implementation for acquireDetachedView(). If acquireDetachedView() is overridden by a subclass then this function must be overridden also!

Implements Thyra::VectorBase< Scalar >.

Reimplemented in Thyra::DefaultProductVector< Scalar >, Thyra::DefaultMultiVectorProductVector< Scalar >, Thyra::SpmdVectorDefaultBase< Scalar >, and Thyra::TpetraVector< Scalar, LocalOrdinal, GlobalOrdinal, Node >.

Definition at line 525 of file Thyra_VectorDefaultBase_def.hpp.

template<class Scalar >
void Thyra::VectorDefaultBase< Scalar >::setSubVectorImpl ( const RTOpPack::SparseSubVectorT< Scalar > &  sub_vec)
protectedvirtual

This implementation uses a transformation operator class (see RTOpPack::TOpSetSubVector) and calls applyOp(). Be forewarned however, that the operator objects state data (both internal and external) will be order O(sub_vec.subNz()). For serial applications, this is entirely adequate. For parallel applications this may be bad!

Implements Thyra::VectorBase< Scalar >.

Reimplemented in Thyra::DefaultProductVector< Scalar >, and Thyra::DefaultMultiVectorProductVector< Scalar >.

Definition at line 540 of file Thyra_VectorDefaultBase_def.hpp.

template<class Scalar >
bool Thyra::VectorDefaultBase< Scalar >::opSupportedImpl ( EOpTransp  M_trans) const
protectedvirtual

For complex Scalar types returns true for NOTRANS and CONJTRANS and for real types returns true for all values of M_trans.

Implements Thyra::LinearOpBase< Scalar >.

Definition at line 552 of file Thyra_VectorDefaultBase_def.hpp.

template<class Scalar >
void Thyra::VectorDefaultBase< Scalar >::applyImpl ( const EOpTransp  M_trans,
const MultiVectorBase< Scalar > &  X,
const Ptr< MultiVectorBase< Scalar > > &  Y,
const Scalar  alpha,
const Scalar  beta 
) const
protectedvirtual

. Applies vector or its adjoint (transpose) as a linear operator.

Implements Thyra::LinearOpBase< Scalar >.

Reimplemented in Thyra::TpetraVector< Scalar, LocalOrdinal, GlobalOrdinal, Node >.

Definition at line 560 of file Thyra_VectorDefaultBase_def.hpp.


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