1#ifndef included_AMP_EpetraVectorOperations
2#define included_AMP_EpetraVectorOperations
5#include "AMP/vectors/operations/default/VectorOperationsDefault.h"
8#include <Epetra_Vector.h>
A linear algebra engine that uses Epetra.
void subtract(const VectorData &x, const VectorData &y, VectorData &z) override
Subtracts one vector from another. For Vectors, .
void abs(const VectorData &x, VectorData &z) override
Set this to the component-wise absolute value of a vector. .
void setRandomValues(VectorData &x) override
Set data in this vector to random values.
void scale(const Scalar &alpha, const VectorData &x, VectorData &y) override
Set vector equal to scaled input. For Vectors, .
Scalar L2Norm(const VectorData &x) const override
Return discrete -norm of this vector.
void setToScalar(const Scalar &alpha, VectorData &z) override
Set all compenents of a vector to a scalar. For Vectors, the components of z are set to .
void multiply(const VectorData &x, const VectorData &y, VectorData &z) override
Component-wise multiply one vector with another. For Vectors, .
void divide(const VectorData &x, const VectorData &y, VectorData &z) override
Component-wise divide one vector by another. For Vectors, .
void reciprocal(const VectorData &x, VectorData &y) override
Set this to the component-wise reciprocal of a vector. .
Scalar dot(const VectorData &x, const VectorData &y) const override
Return the dot product of this vector with the argument vector.
void add(const VectorData &x, const VectorData &y, VectorData &z) override
Adds two vectors. For Vectors, .
void scale(const Scalar &alpha, VectorData &x) override
Scale a vector. For Vectors, .
Scalar max(const VectorData &x) const override
Return the maximum value of the vector. .
void linearSum(const Scalar &alpha, const VectorData &x, const Scalar &beta, const VectorData &y, VectorData &z) override
Set a vector to be a linear combination of two vectors. .
void axpby(const Scalar &alpha, const Scalar &beta, const VectorData &x, VectorData &y) override
Set this vector alpha * x + this. .
Scalar min(const VectorData &x) const override
Return the minimum value of the vector. .
void axpy(const Scalar &alpha, const VectorData &x, const VectorData &y, VectorData &z) override
Set this vector to alpha * x + y. .
Scalar maxNorm(const VectorData &x) const override
Return the -norm of this vector.
Scalar L1Norm(const VectorData &x) const override
Return discrete -norm of this vector.
A class used to hold vector data.
A default set of vector operations.
virtual Scalar wrmsNorm(const VectorData &x, const VectorData &y) const
Return a weighted norm of a vector.
void axpby(const Scalar &alpha, const Scalar &beta, const VectorData &x, VectorData &y) override
Set this vector alpha * x + this. .
void scale(const Scalar &alpha, const VectorData &x, VectorData &y) override
Set vector equal to scaled input. For Vectors, .
virtual Scalar max(const VectorData &x) const
Return the maximum value of the vector. .
void multiply(const VectorData &x, const VectorData &y, VectorData &z) override
Component-wise multiply one vector with another. For Vectors, .
Scalar localL2Norm(const VectorData &x) const override
Return local discrete -norm of this vector.
virtual Scalar min(const VectorData &x) const
Return the minimum value of the vector. .
virtual Scalar maxNorm(const VectorData &x) const
Return the -norm of this vector.
virtual Scalar L1Norm(const VectorData &x) const
Return discrete -norm of this vector.
virtual Scalar wrmsNormMask(const VectorData &x, const VectorData &mask, const VectorData &y) const
Return a weighted norm of a subset of a vector.
virtual Scalar minQuotient(const VectorData &x, const VectorData &y) const
Returns the minimum of the quotient of two vectors:
void add(const VectorData &x, const VectorData &y, VectorData &z) override
Adds two vectors. For Vectors, .
virtual Scalar dot(const VectorData &x, const VectorData &y) const
Return the dot product of this vector with the argument vector.
void abs(const VectorData &x, VectorData &z) override
Set this to the component-wise absolute value of a vector. .
void axpy(const Scalar &alpha, const VectorData &x, const VectorData &y, VectorData &z) override
Set this vector to alpha * x + y. .
void divide(const VectorData &x, const VectorData &y, VectorData &z) override
Component-wise divide one vector by another. For Vectors, .
Scalar localL1Norm(const VectorData &x) const override
Return local discrete -norm of this vector.
void subtract(const VectorData &x, const VectorData &y, VectorData &z) override
Subtracts one vector from another. For Vectors, .
void setRandomValues(VectorData &x) override
Set data in this vector to random values.
void reciprocal(const VectorData &x, VectorData &y) override
Set this to the component-wise reciprocal of a vector. .
Scalar localMin(const VectorData &x) const override
Return the local minimum value of the vector. .
Scalar localMaxNorm(const VectorData &x) const override
Return the local -norm of this vector.
Scalar localMax(const VectorData &x) const override
Return the local maximum value of the vector. .
Scalar localDot(const VectorData &x, const VectorData &y) const override
Return the local dot product of this vector with the argument vector.
virtual Scalar L2Norm(const VectorData &x) const
Return discrete -norm of this vector.
void linearSum(const Scalar &alpha, const VectorData &x, const Scalar &beta, const VectorData &y, VectorData &z) override
Set a vector to be a linear combination of two vectors. .
Scalar is a class used to store a scalar variable that may be different types/precision.
#define DISABLE_WARNINGS
Re-enable warnings.
#define ENABLE_WARNINGS
Suppress all warnings.