Xpetra
Version of the Day
|
#include <Xpetra_TpetraVector_fwd.hpp>
Public Member Functions | |
Scalar | dot (const Vector< Scalar, LocalOrdinal, GlobalOrdinal, Node > &a) const |
Computes dot product of this Vector against input Vector x. More... | |
Public Member Functions inherited from Xpetra::Vector< Scalar, LocalOrdinal, GlobalOrdinal, Node > | |
virtual | ~Vector () |
Destructor. More... | |
Public Member Functions inherited from Xpetra::MultiVector< Scalar, LocalOrdinal, GlobalOrdinal, Node > | |
virtual | ~MultiVector () |
Destructor. More... | |
MultiVector< Scalar, LocalOrdinal, GlobalOrdinal, Node > & | operator= (const MultiVector< Scalar, LocalOrdinal, GlobalOrdinal, Node > &rhs) |
Assignment operator: Does a deep copy. More... | |
virtual void | replaceMap (const RCP< const Map< LocalOrdinal, GlobalOrdinal, Node >> &map)=0 |
virtual void | Xpetra_randomize () |
Set multi-vector values to random numbers. XPetra implementation. More... | |
Public Member Functions inherited from Xpetra::DistObject< Scalar, LocalOrdinal, GlobalOrdinal, Node > | |
virtual | ~DistObject () |
Destructor. More... | |
Public Member Functions inherited from Xpetra::TpetraMultiVector< Scalar, LocalOrdinal, GlobalOrdinal, Node > | |
void | elementWiseMultiply (Scalar scalarAB, const Vector< Scalar, LocalOrdinal, GlobalOrdinal, Node > &A, const MultiVector< Scalar, LocalOrdinal, GlobalOrdinal, Node > &B, Scalar scalarThis) |
Element-wise multiply of a Vector A with a TpetraMultiVector B. More... | |
void | randomize (bool bUseXpetraImplementation=false) |
Set multi-vector values to random numbers. More... | |
Teuchos::RCP< const Map < LocalOrdinal, GlobalOrdinal, Node > > | getMap () const |
The Map describing the parallel distribution of this object. More... | |
void | doImport (const DistObject< Scalar, LocalOrdinal, GlobalOrdinal, Node > &source, const Import< LocalOrdinal, GlobalOrdinal, Node > &importer, CombineMode CM) |
Import data into this object using an Import object ("forward mode"). More... | |
void | doExport (const DistObject< Scalar, LocalOrdinal, GlobalOrdinal, Node > &dest, const Import< LocalOrdinal, GlobalOrdinal, Node > &importer, CombineMode CM) |
Export data into this object using an Import object ("reverse mode"). More... | |
void | doImport (const DistObject< Scalar, LocalOrdinal, GlobalOrdinal, Node > &source, const Export< LocalOrdinal, GlobalOrdinal, Node > &exporter, CombineMode CM) |
Import data into this object using an Export object ("reverse mode"). More... | |
void | doExport (const DistObject< Scalar, LocalOrdinal, GlobalOrdinal, Node > &dest, const Export< LocalOrdinal, GlobalOrdinal, Node > &exporter, CombineMode CM) |
Export data into this object using an Export object ("forward mode"). More... | |
void | replaceMap (const RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > &map) |
TpetraMultiVector (const Teuchos::RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > &map, size_t NumVectors, bool zeroOut=true) | |
Basic constuctor. More... | |
TpetraMultiVector (const MultiVector< Scalar, LocalOrdinal, GlobalOrdinal, Node > &source) | |
Copy constructor (performs a deep copy). More... | |
TpetraMultiVector (const Teuchos::RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > &map, const Teuchos::ArrayView< const Scalar > &A, size_t LDA, size_t NumVectors) | |
Create multivector by copying two-dimensional array of local data. More... | |
TpetraMultiVector (const Teuchos::RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > &map, const Teuchos::ArrayView< const Teuchos::ArrayView< const Scalar > > &ArrayOfPtrs, size_t NumVectors) | |
Create multivector by copying array of views of local data. More... | |
virtual | ~TpetraMultiVector () |
Destructor (virtual for memory safety of derived classes). More... | |
void | replaceGlobalValue (GlobalOrdinal globalRow, size_t vectorIndex, const Scalar &value) |
Replace value, using global (row) index. More... | |
void | sumIntoGlobalValue (GlobalOrdinal globalRow, size_t vectorIndex, const Scalar &value) |
Add value to existing value, using global (row) index. More... | |
void | replaceLocalValue (LocalOrdinal myRow, size_t vectorIndex, const Scalar &value) |
Replace value, using local (row) index. More... | |
void | sumIntoLocalValue (LocalOrdinal myRow, size_t vectorIndex, const Scalar &value) |
Add value to existing value, using local (row) index. More... | |
void | putScalar (const Scalar &value) |
Set all values in the multivector with the given value. More... | |
void | reduce () |
Sum values of a locally replicated multivector across all processes. More... | |
Teuchos::RCP< const Vector < Scalar, LocalOrdinal, GlobalOrdinal, Node > > | getVector (size_t j) const |
Return a Vector which is a const view of column j. More... | |
Teuchos::RCP< Vector< Scalar, LocalOrdinal, GlobalOrdinal, Node > > | getVectorNonConst (size_t j) |
Return a Vector which is a nonconst view of column j. More... | |
Teuchos::ArrayRCP< const Scalar > | getData (size_t j) const |
Const view of the local values in a particular vector of this multivector. More... | |
Teuchos::ArrayRCP< Scalar > | getDataNonConst (size_t j) |
View of the local values in a particular vector of this multivector. More... | |
void | get1dCopy (Teuchos::ArrayView< Scalar > A, size_t LDA) const |
Fill the given array with a copy of this multivector's local values. More... | |
void | get2dCopy (Teuchos::ArrayView< const Teuchos::ArrayView< Scalar > > ArrayOfPtrs) const |
Fill the given array with a copy of this multivector's local values. More... | |
Teuchos::ArrayRCP< const Scalar > | get1dView () const |
Const persisting (1-D) view of this multivector's local values. More... | |
Teuchos::ArrayRCP < Teuchos::ArrayRCP< const Scalar > > | get2dView () const |
Return const persisting pointers to values. More... | |
Teuchos::ArrayRCP< Scalar > | get1dViewNonConst () |
Nonconst persisting (1-D) view of this multivector's local values. More... | |
Teuchos::ArrayRCP < Teuchos::ArrayRCP< Scalar > > | get2dViewNonConst () |
Return non-const persisting pointers to values. More... | |
void | dot (const MultiVector< Scalar, LocalOrdinal, GlobalOrdinal, Node > &A, const Teuchos::ArrayView< Scalar > &dots) const |
Compute dot product of each corresponding pair of vectors, dots[i] = this[i].dot(A[i]). More... | |
void | abs (const MultiVector< Scalar, LocalOrdinal, GlobalOrdinal, Node > &A) |
Put element-wise absolute values of input Multi-vector in target: A = abs(this). More... | |
void | reciprocal (const MultiVector< Scalar, LocalOrdinal, GlobalOrdinal, Node > &A) |
Put element-wise reciprocal values of input Multi-vector in target, this(i,j) = 1/A(i,j). More... | |
void | scale (const Scalar &alpha) |
Scale the current values of a multi-vector, this = alpha*this. More... | |
void | scale (Teuchos::ArrayView< const Scalar > alpha) |
Scale the current values of a multi-vector, this[j] = alpha[j]*this[j]. More... | |
void | scale (const Scalar &alpha, const MultiVector< Scalar, LocalOrdinal, GlobalOrdinal, Node > &A) |
Replace multi-vector values with scaled values of A, this = alpha*A. More... | |
void | update (const Scalar &alpha, const MultiVector< Scalar, LocalOrdinal, GlobalOrdinal, Node > &A, const Scalar &beta) |
Update multi-vector values with scaled values of A, this = beta*this + alpha*A. More... | |
void | update (const Scalar &alpha, const MultiVector< Scalar, LocalOrdinal, GlobalOrdinal, Node > &A, const Scalar &beta, const MultiVector< Scalar, LocalOrdinal, GlobalOrdinal, Node > &B, const Scalar &gamma) |
Update multi-vector with scaled values of A and B, this = gamma*this + alpha*A + beta*B. More... | |
void | norm1 (const Teuchos::ArrayView< typename Teuchos::ScalarTraits< Scalar >::magnitudeType > &norms) const |
Compute 1-norm of each vector in multi-vector. More... | |
void | norm2 (const Teuchos::ArrayView< typename Teuchos::ScalarTraits< Scalar >::magnitudeType > &norms) const |
void | normInf (const Teuchos::ArrayView< typename Teuchos::ScalarTraits< Scalar >::magnitudeType > &norms) const |
Compute Inf-norm of each vector in multi-vector. More... | |
void | meanValue (const Teuchos::ArrayView< Scalar > &means) const |
Compute mean (average) value of each vector in multi-vector. The outcome of this routine is undefined for non-floating point scalar types (e.g., int). More... | |
void | multiply (Teuchos::ETransp transA, Teuchos::ETransp transB, const Scalar &alpha, const MultiVector< Scalar, LocalOrdinal, GlobalOrdinal, Node > &A, const MultiVector< Scalar, LocalOrdinal, GlobalOrdinal, Node > &B, const Scalar &beta) |
Matrix-matrix multiplication: this = beta*this + alpha*op(A)*op(B). More... | |
size_t | getNumVectors () const |
Number of columns in the multivector. More... | |
size_t | getLocalLength () const |
Local number of rows on the calling process. More... | |
global_size_t | getGlobalLength () const |
Global number of rows in the multivector. More... | |
bool | isSameSize (const MultiVector< Scalar, LocalOrdinal, GlobalOrdinal, Node > &vec) const |
TpetraMultiVector (const Teuchos::RCP< Tpetra::MultiVector< Scalar, LocalOrdinal, GlobalOrdinal, Node > > &vec) | |
TpetraMultiVector constructor to wrap a Tpetra::MultiVector object. More... | |
RCP< Tpetra::MultiVector < Scalar, LocalOrdinal, GlobalOrdinal, Node > > | getTpetra_MultiVector () const |
Get the underlying Tpetra multivector. More... | |
void | setSeed (unsigned int seed) |
Set seed for Random function. More... | |
Constructor/Destructor Methods | |
TpetraVector (const Teuchos::RCP< const Map< LocalOrdinal, GlobalOrdinal, Node >> &map, bool zeroOut=true) | |
Sets all vector entries to zero. More... | |
TpetraVector (const Teuchos::RCP< const Map< LocalOrdinal, GlobalOrdinal, Node >> &map, const Teuchos::ArrayView< const Scalar > &A) | |
Set multi-vector values from an array using Teuchos memory management classes. (copy) More... | |
virtual | ~TpetraVector () |
Destructor. More... | |
Post-construction modification routines | |
void | replaceGlobalValue (GlobalOrdinal globalRow, const Scalar &value) |
Replace current value at the specified location with specified value. More... | |
void | sumIntoGlobalValue (GlobalOrdinal globalRow, const Scalar &value) |
Adds specified value to existing value at the specified location. More... | |
void | replaceLocalValue (LocalOrdinal myRow, const Scalar &value) |
Replace current value at the specified location with specified values. More... | |
void | sumIntoLocalValue (LocalOrdinal myRow, const Scalar &value) |
Adds specified value to existing value at the specified location. More... | |
Mathematical methods | |
Teuchos::ScalarTraits< Scalar > ::magnitudeType | norm1 () const |
Return 1-norm of this Vector. More... | |
Teuchos::ScalarTraits< Scalar > ::magnitudeType | norm2 () const |
Compute 2-norm of this Vector. More... | |
Teuchos::ScalarTraits< Scalar > ::magnitudeType | normInf () const |
Compute Inf-norm of this Vector. More... | |
Scalar | meanValue () const |
Compute mean (average) value of this Vector. More... | |
Overridden from Teuchos::Describable | |
std::string | description () const |
Return a simple one-line description of this object. More... | |
void | describe (Teuchos::FancyOStream &out, const Teuchos::EVerbosityLevel verbLevel=Teuchos::Describable::verbLevel_default) const |
Print the object with some verbosity level to an FancyOStream object. More... | |
Xpetra specific | |
TpetraVector (const Teuchos::RCP< Tpetra::Vector< Scalar, LocalOrdinal, GlobalOrdinal, Node >> &vec) | |
TpetraMultiVector constructor to wrap a Tpetra::MultiVector object. More... | |
RCP< Tpetra::Vector< Scalar, LocalOrdinal, GlobalOrdinal, Node > > | getTpetra_Vector () const |
Get the underlying Tpetra multivector. More... | |
Additional Inherited Members | |
Public Types inherited from Xpetra::Vector< Scalar, LocalOrdinal, GlobalOrdinal, Node > | |
using | scalar_type = Scalar |
using | local_ordinal_type = LocalOrdinal |
using | global_ordinal_type = GlobalOrdinal |
using | node_type = Node |
Public Types inherited from Xpetra::MultiVector< Scalar, LocalOrdinal, GlobalOrdinal, Node > | |
typedef Scalar | scalar_type |
typedef LocalOrdinal | local_ordinal_type |
typedef GlobalOrdinal | global_ordinal_type |
typedef Node | node_type |
Protected Member Functions inherited from Xpetra::TpetraMultiVector< Scalar, LocalOrdinal, GlobalOrdinal, Node > | |
virtual void | assign (const MultiVector< Scalar, LocalOrdinal, GlobalOrdinal, Node > &rhs) |
Implementation of the assignment operator (operator=); does a deep copy. More... | |
Definition at line 51 of file Xpetra_TpetraVector_fwd.hpp.
Xpetra::TpetraVector< Scalar, LocalOrdinal, GlobalOrdinal, Node >::TpetraVector | ( | const Teuchos::RCP< const Map< LocalOrdinal, GlobalOrdinal, Node >> & | map, |
bool | zeroOut = true |
||
) |
Sets all vector entries to zero.
Definition at line 56 of file Xpetra_TpetraVector_def.hpp.
Xpetra::TpetraVector< Scalar, LocalOrdinal, GlobalOrdinal, Node >::TpetraVector | ( | const Teuchos::RCP< const Map< LocalOrdinal, GlobalOrdinal, Node >> & | map, |
const Teuchos::ArrayView< const Scalar > & | A | ||
) |
Set multi-vector values from an array using Teuchos memory management classes. (copy)
Definition at line 65 of file Xpetra_TpetraVector_def.hpp.
|
virtual |
Destructor.
Definition at line 74 of file Xpetra_TpetraVector_def.hpp.
Xpetra::TpetraVector< Scalar, LocalOrdinal, GlobalOrdinal, Node >::TpetraVector | ( | const Teuchos::RCP< Tpetra::Vector< Scalar, LocalOrdinal, GlobalOrdinal, Node >> & | vec | ) |
TpetraMultiVector constructor to wrap a Tpetra::MultiVector object.
Definition at line 191 of file Xpetra_TpetraVector_def.hpp.
|
virtual |
Replace current value at the specified location with specified value.
Implements Xpetra::Vector< Scalar, LocalOrdinal, GlobalOrdinal, Node >.
Definition at line 82 of file Xpetra_TpetraVector_def.hpp.
|
virtual |
Adds specified value to existing value at the specified location.
Implements Xpetra::Vector< Scalar, LocalOrdinal, GlobalOrdinal, Node >.
Definition at line 92 of file Xpetra_TpetraVector_def.hpp.
|
virtual |
Replace current value at the specified location with specified values.
Implements Xpetra::Vector< Scalar, LocalOrdinal, GlobalOrdinal, Node >.
Definition at line 102 of file Xpetra_TpetraVector_def.hpp.
|
virtual |
Adds specified value to existing value at the specified location.
Implements Xpetra::Vector< Scalar, LocalOrdinal, GlobalOrdinal, Node >.
Definition at line 112 of file Xpetra_TpetraVector_def.hpp.
|
virtual |
Return 1-norm of this Vector.
Implements Xpetra::Vector< Scalar, LocalOrdinal, GlobalOrdinal, Node >.
Definition at line 122 of file Xpetra_TpetraVector_def.hpp.
|
virtual |
Compute 2-norm of this Vector.
Implements Xpetra::Vector< Scalar, LocalOrdinal, GlobalOrdinal, Node >.
Definition at line 132 of file Xpetra_TpetraVector_def.hpp.
|
virtual |
Compute Inf-norm of this Vector.
Implements Xpetra::Vector< Scalar, LocalOrdinal, GlobalOrdinal, Node >.
Definition at line 142 of file Xpetra_TpetraVector_def.hpp.
|
virtual |
Compute mean (average) value of this Vector.
Implements Xpetra::Vector< Scalar, LocalOrdinal, GlobalOrdinal, Node >.
Definition at line 152 of file Xpetra_TpetraVector_def.hpp.
|
virtual |
Return a simple one-line description of this object.
Reimplemented from Xpetra::TpetraMultiVector< Scalar, LocalOrdinal, GlobalOrdinal, Node >.
Definition at line 162 of file Xpetra_TpetraVector_def.hpp.
|
virtual |
Print the object with some verbosity level to an FancyOStream object.
Reimplemented from Xpetra::TpetraMultiVector< Scalar, LocalOrdinal, GlobalOrdinal, Node >.
Definition at line 172 of file Xpetra_TpetraVector_def.hpp.
|
virtual |
Computes dot product of this Vector against input Vector x.
Implements Xpetra::Vector< Scalar, LocalOrdinal, GlobalOrdinal, Node >.
Definition at line 182 of file Xpetra_TpetraVector_def.hpp.
RCP< Tpetra::Vector< Scalar, LocalOrdinal, GlobalOrdinal, Node > > Xpetra::TpetraVector< Scalar, LocalOrdinal, GlobalOrdinal, Node >::getTpetra_Vector | ( | ) | const |
Get the underlying Tpetra multivector.
Definition at line 200 of file Xpetra_TpetraVector_def.hpp.