#include <MLAPI_MultiVector.h>


Public Member Functions | |
| bool | IsAlias (const MultiVector &rhs) const |
| MultiVector () | |
| Default constructor. | |
| MultiVector (const Space &VectorSpace, const int NumVectors=1, bool SetToZero=true) | |
| Constructor for a given Space. | |
| MultiVector (const Space &VectorSpace, double **Values, const int NumVectors=1) | |
| Constructor with a given Space, and user-provided array of values. | |
| MultiVector (const Space &VectorSpace, Teuchos::RefCountPtr< DoubleVector > RCPValues) | |
| Constructor with a given Space, and user-provided RefCountPtr. | |
| MultiVector (const Space &VectorSpace, std::vector< Teuchos::RefCountPtr< DoubleVector > > RCPValues) | |
| Constructor with a given Space, and user-provided array of values. | |
| MultiVector (const MultiVector &rhs) | |
| Copy constructor. | |
| ~MultiVector () | |
| Destructor. | |
| void | Reshape () |
Resets this object. | |
| void | Reshape (const Space &S, const int NumVectors=1, const bool SetToZero=true) |
| Sets the space of this vector. | |
| void | Append (const int NumVectors=1, const bool SetToZero=true) |
| Appends a new vector. | |
| void | Append (MultiVector rhs) |
| Appends a new vector. | |
| void | Delete (const int v) |
| Deletes the last vector. | |
| MultiVector & | operator= (double rhs) |
Sets all elements of this vector to rhs. | |
| MultiVector & | operator= (const MultiVector &rhs) |
Copies the rhs into this object. | |
| MultiVector & | operator= (const BaseLinearCombination &rhs) |
| Sets the elements from the input BaseLinearCombination. | |
| bool | operator== (const MultiVector &rhs) const |
| MultiVector & | operator= (const string &Label) |
Sets the name of this object, does not touch vector elements or space. | |
| const double & | operator() (const int i) const |
Returns the value of local element i (const version). | |
| double & | operator() (const int i) |
Returns the value of local element i (non-const version). | |
| const double & | operator() (const int i, const int v) const |
Returns the value of local element i. | |
| double & | operator() (const int i, const int v) |
Returns the value of local element i (non-const version). | |
| const Space & | GetVectorSpace () const |
Returns the Space on which this vector is defined. | |
| Space & | GetVectorSpace () |
Returns the Space on which this vector is defined (non-const). | |
| int | GetNumVectors () const |
| Returns the number of vectors. | |
| int | GetMyLength () const |
| Returns the local length of each vector. | |
| int | GetGlobalLength () const |
| Returns the global length of each vector. | |
| double * | GetValues (const int v) |
| Returns a pointer to the double array (non-const version). | |
| const double * | GetValues (const int v) const |
| Returns a pointer to the double array (const version). | |
| Teuchos::RefCountPtr < DoubleVector > & | GetRCPValues (const int v) |
| Returns a pointer to the double array (non-const version). | |
| const Teuchos::RefCountPtr < DoubleVector > & | GetRCPValues (const int v) const |
| Returns a pointer to the double array (const version). | |
| void | SetRCPValues (const Teuchos::RefCountPtr< DoubleVector > &RCPValues, const int v) |
| Sets the RefCountPtr<Values_>. | |
| void | Update (const double alpha, int v=-1) |
| Sets this(v) = rhs. | |
| void | Update (const MultiVector &rhs) |
| Sets this = rhs. | |
| void | Update (double alpha, const MultiVector &rhs) |
| Sets this = alpha * rhs. | |
| void | Update (double alpha, const MultiVector &x, double beta, const MultiVector &y) |
| Sets this = alpha * x + beta * y. | |
| void | Update (double alpha, const MultiVector &rhs, double beta) |
| Sets this = alpha * rhs + beta * this. | |
| double | DotProduct (const MultiVector &rhs, int v=-1) const |
Computes the dot product between this vector and rhs. | |
| double | Norm2 (int v=-1) const |
Computes the 2-norm of this vector. | |
| double | NormInf (int v=-1) const |
Computes the infinite norm of this vector. | |
| double | NormOne (int v=-1) const |
Computes the one norm of this vector. | |
| void | Reciprocal (int v=-1) |
| Replaces each element of the vector with its reciprocal. | |
| void | Scale (const double Factor, int v=-1) |
| Scales each element by the specified factor. | |
| void | Random (int v=-1) |
| Populates the vector with random elements. | |
| void | Sort (int v=-1, const bool IsIncreasing=false) |
| Sorts the component of the vector. | |
| virtual std::ostream & | Print (std::ostream &os, const bool verbose=true) const |
Prints basic information about this object on ostream. | |
Private Member Functions | |
| void | SetRCPLength (const int NumVectors) |
| Sets the length of RCPValues_ array. | |
| void | Initialize () |
Initialize this object. | |
| void | CheckSpaces (const MultiVector rhs) const |
Verifies that rhs is compatible with this, and not its alias. | |
| void | CheckEntry (const int i) const |
| Verifies that the requested component is actually stored. | |
| void | CheckVector (const int v) const |
| Verifies that the requested component is actually stored. | |
| void | CheckNumVectors (const int NumVectors) const |
| Verifies the number of vectors. | |
| void | CheckSingleVector () const |
| Verifies that only one vector is stored. | |
Private Attributes | |
| std::vector < Teuchos::RefCountPtr < DoubleVector > > | RCPValues_ |
| Pointer to locally own values. | |
| Space | VectorSpace_ |
| Data layout. | |
| int | NumVectors_ |
| Number of vectors. | |
| MLAPI::MultiVector::MultiVector | ( | ) | [inline] |
| MLAPI::MultiVector::MultiVector | ( | const Space & | VectorSpace, | |
| const int | NumVectors = 1, |
|||
| bool | SetToZero = true | |||
| ) | [inline] |
| MLAPI::MultiVector::MultiVector | ( | const Space & | VectorSpace, | |
| double ** | Values, | |||
| const int | NumVectors = 1 | |||
| ) | [inline] |
| MLAPI::MultiVector::MultiVector | ( | const Space & | VectorSpace, | |
| Teuchos::RefCountPtr< DoubleVector > | RCPValues | |||
| ) | [inline] |
| MLAPI::MultiVector::MultiVector | ( | const Space & | VectorSpace, | |
| std::vector< Teuchos::RefCountPtr< DoubleVector > > | RCPValues | |||
| ) | [inline] |
| MLAPI::MultiVector::MultiVector | ( | const MultiVector & | rhs | ) | [inline] |
| MLAPI::MultiVector::~MultiVector | ( | ) | [inline] |
| void MLAPI::MultiVector::Append | ( | MultiVector | rhs | ) | [inline] |
| void MLAPI::MultiVector::Append | ( | const int | NumVectors = 1, |
|
| const bool | SetToZero = true | |||
| ) | [inline] |
| void MLAPI::MultiVector::CheckEntry | ( | const int | i | ) | const [inline, private] |
| void MLAPI::MultiVector::CheckNumVectors | ( | const int | NumVectors | ) | const [inline, private] |
| void MLAPI::MultiVector::CheckSingleVector | ( | ) | const [inline, private] |
| void MLAPI::MultiVector::CheckSpaces | ( | const MultiVector | rhs | ) | const [inline, private] |
| void MLAPI::MultiVector::CheckVector | ( | const int | v | ) | const [inline, private] |
| void MLAPI::MultiVector::Delete | ( | const int | v | ) | [inline] |
| double MLAPI::MultiVector::DotProduct | ( | const MultiVector & | rhs, | |
| int | v = -1 | |||
| ) | const [inline] |
| int MLAPI::MultiVector::GetGlobalLength | ( | ) | const [inline] |
| int MLAPI::MultiVector::GetMyLength | ( | ) | const [inline] |
| int MLAPI::MultiVector::GetNumVectors | ( | ) | const [inline] |
| const Teuchos::RefCountPtr<DoubleVector>& MLAPI::MultiVector::GetRCPValues | ( | const int | v | ) | const [inline] |
| Teuchos::RefCountPtr<DoubleVector>& MLAPI::MultiVector::GetRCPValues | ( | const int | v | ) | [inline] |
| const double* MLAPI::MultiVector::GetValues | ( | const int | v | ) | const [inline] |
| double* MLAPI::MultiVector::GetValues | ( | const int | v | ) | [inline] |
| Space& MLAPI::MultiVector::GetVectorSpace | ( | ) | [inline] |
| const Space& MLAPI::MultiVector::GetVectorSpace | ( | ) | const [inline] |
| void MLAPI::MultiVector::Initialize | ( | ) | [inline, private] |
| bool MLAPI::MultiVector::IsAlias | ( | const MultiVector & | rhs | ) | const [inline] |
| double MLAPI::MultiVector::Norm2 | ( | int | v = -1 |
) | const [inline] |
| double MLAPI::MultiVector::NormInf | ( | int | v = -1 |
) | const [inline] |
| double MLAPI::MultiVector::NormOne | ( | int | v = -1 |
) | const [inline] |
| double& MLAPI::MultiVector::operator() | ( | const int | i, | |
| const int | v | |||
| ) | [inline] |
| const double& MLAPI::MultiVector::operator() | ( | const int | i, | |
| const int | v | |||
| ) | const [inline] |
| double& MLAPI::MultiVector::operator() | ( | const int | i | ) | [inline] |
| const double& MLAPI::MultiVector::operator() | ( | const int | i | ) | const [inline] |
| MultiVector& MLAPI::MultiVector::operator= | ( | const string & | Label | ) | [inline] |
| MultiVector& MLAPI::MultiVector::operator= | ( | const BaseLinearCombination & | rhs | ) | [inline] |
| MultiVector& MLAPI::MultiVector::operator= | ( | const MultiVector & | rhs | ) | [inline] |
| MultiVector& MLAPI::MultiVector::operator= | ( | double | rhs | ) | [inline] |
| bool MLAPI::MultiVector::operator== | ( | const MultiVector & | rhs | ) | const [inline] |
| virtual std::ostream& MLAPI::MultiVector::Print | ( | std::ostream & | os, | |
| const bool | verbose = true | |||
| ) | const [inline, virtual] |
Implements MLAPI::BaseObject.
| void MLAPI::MultiVector::Random | ( | int | v = -1 |
) | [inline] |
| void MLAPI::MultiVector::Reciprocal | ( | int | v = -1 |
) | [inline] |
| void MLAPI::MultiVector::Reshape | ( | const Space & | S, | |
| const int | NumVectors = 1, |
|||
| const bool | SetToZero = true | |||
| ) | [inline] |
| void MLAPI::MultiVector::Reshape | ( | ) | [inline] |
| void MLAPI::MultiVector::Scale | ( | const double | Factor, | |
| int | v = -1 | |||
| ) | [inline] |
| void MLAPI::MultiVector::SetRCPLength | ( | const int | NumVectors | ) | [inline, private] |
| void MLAPI::MultiVector::SetRCPValues | ( | const Teuchos::RefCountPtr< DoubleVector > & | RCPValues, | |
| const int | v | |||
| ) | [inline] |
| void MLAPI::MultiVector::Sort | ( | int | v = -1, |
|
| const bool | IsIncreasing = false | |||
| ) | [inline] |
| void MLAPI::MultiVector::Update | ( | double | alpha, | |
| const MultiVector & | rhs, | |||
| double | beta | |||
| ) | [inline] |
| void MLAPI::MultiVector::Update | ( | double | alpha, | |
| const MultiVector & | x, | |||
| double | beta, | |||
| const MultiVector & | y | |||
| ) | [inline] |
| void MLAPI::MultiVector::Update | ( | double | alpha, | |
| const MultiVector & | rhs | |||
| ) | [inline] |
| void MLAPI::MultiVector::Update | ( | const MultiVector & | rhs | ) | [inline] |
| void MLAPI::MultiVector::Update | ( | const double | alpha, | |
| int | v = -1 | |||
| ) | [inline] |
int MLAPI::MultiVector::NumVectors_ [private] |
std::vector<Teuchos::RefCountPtr<DoubleVector> > MLAPI::MultiVector::RCPValues_ [private] |
Space MLAPI::MultiVector::VectorSpace_ [private] |