queso-0.57.1
|
Class for vector operations using GSL library. More...
#include <GslVector.h>
Public Member Functions | |
void | sort () |
This function sorts the elements of the vector this in ascending numerical order. More... | |
void | matlabDiff (unsigned int firstPositionToStoreDiff, double valueForRemainderPosition, GslVector &outputVec) const |
void | matlabLinearInterpExtrap (const GslVector &x1Vec, const GslVector &y1Vec, const GslVector &x2Vec) |
void | mpiBcast (int srcRank, const MpiComm &bcastComm) |
void | mpiAllReduce (RawType_MPI_Op mpiOperation, const MpiComm &opComm, GslVector &resultVec) const |
void | mpiAllQuantile (double probability, const MpiComm &opComm, GslVector &resultVec) const |
void | subWriteContents (const std::string &varNamePrefix, const std::string &fileName, const std::string &fileType, const std::set< unsigned int > &allowedSubEnvIds) const |
void | subReadContents (const std::string &fileName, const std::string &fileType, const std::set< unsigned int > &allowedSubEnvIds) |
gsl_vector * | data () const |
Constructor/Destructor methods. | |
GslVector (const BaseEnvironment &env, const Map &map) | |
Construct a zero vector. More... | |
GslVector (const BaseEnvironment &env, const Map &map, double value) | |
Construct a vector with all entries set to value . More... | |
GslVector (const BaseEnvironment &env, double d1, double d2, const Map &map) | |
Construct a vector linearly interpolating from d1 to d2 ,. More... | |
GslVector (const GslVector &v, double start, double end) | |
Construct a vector, with length the same as v , with evenly spaced numbers from start to end , inclusive. More... | |
GslVector (const GslVector &y) | |
Construct a vector equal to y . More... | |
~GslVector () | |
Destructor. More... | |
Set methods. | |
GslVector & | operator= (const GslVector &rhs) |
Copies values from vector rhs to this . More... | |
GslVector & | operator*= (double a) |
Stores in this the coordinate-wise multiplication of this and a. More... | |
GslVector & | operator/= (double a) |
Stores in this the coordinate-wise division of this by a. More... | |
GslVector & | operator*= (const GslVector &rhs) |
Stores in this the coordinate-wise multiplication of this with rhs. More... | |
GslVector & | operator/= (const GslVector &rhs) |
Stores in this the coordinate-wise division of this by rhs. More... | |
GslVector & | operator+= (const GslVector &rhs) |
Stores in this the coordinate-wise addition of this and rhs. More... | |
GslVector & | operator-= (const GslVector &rhs) |
Stores in this the coordinate-wise subtraction of this by rhs. More... | |
void | cwSet (double value) |
Component-wise sets all values to this with value. More... | |
void | cwSetGaussian (double mean, double stdDev) |
This function sets component-wise Gaussian random variates, with mean mean and standard deviation stdDev. More... | |
void | cwSetGaussian (const GslVector &meanVec, const GslVector &stdDevVec) |
This function sets component-wise Gaussian random variates, with vectors for mean and standard deviation. More... | |
void | cwSetUniform (const GslVector &aVec, const GslVector &bVec) |
This function sets component-wise a number uniformly distributed in the range of elements of [aVec,bVec]. More... | |
void | cwSetBeta (const GslVector &alpha, const GslVector &beta) |
This function returns a random variate from the beta distribution, with vector parameters alpha and beta. More... | |
void | cwSetGamma (const GslVector &a, const GslVector &b) |
This function returns a random variate from the gamma distribution with vector parameters a and b. More... | |
void | cwSetInverseGamma (const GslVector &alpha, const GslVector &beta) |
This function returns a random variate from the inverse gamma distribution with vector parameters alpha and beta. More... | |
void | cwSetConcatenated (const GslVector &v1, const GslVector &v2) |
This function concatenates GslVector v1 and GslVector v2 into this . More... | |
void | cwSetConcatenated (const std::vector< const GslVector * > &vecs) |
This function concatenates vectors v1 and v2 into this vector. More... | |
void | cwSet (unsigned int initialPos, const GslVector &vec) |
This function sets the vector vec into this starting at position initialPos. More... | |
void | cwExtract (unsigned int initialPos, GslVector &vec) const |
This function sets the values of this starting at position initialPos ans saves them in vector vec. More... | |
void | cwInvert () |
This function inverts component-wise the element values of this . More... | |
void | cwSqrt () |
This function returns component-wise the square-root of this . More... | |
Accessor methods. | |
double & | operator[] (unsigned int i) |
Element access method (non-const). More... | |
const double & | operator[] (unsigned int i) const |
Element access method (const). More... | |
Attribute methods. | |
unsigned int | sizeLocal () const |
Returns the length of this vector. More... | |
unsigned int | sizeGlobal () const |
Returns the global length of this vector. More... | |
double | getMaxValue () const |
Returns the maximum value in the vector this . More... | |
double | getMinValue () const |
Returns minimum value in the vector this . More... | |
int | getMaxValueIndex () const |
This function returns the index of the maximum value in the vector this . More... | |
int | getMinValueIndex () const |
This function returns the index of the minimum value in the vector this . More... | |
void | getMaxValueAndIndex (double &value, int &index) |
This function returns maximum value in the vector this and its the index. More... | |
void | getMinValueAndIndex (double &value, int &index) |
This function returns minimum value in the vector this and its the index. More... | |
GslVector | abs () const |
This function returns absolute value of elements in this . More... | |
Mathematical methods. | |
double | norm2Sq () const |
Returns the 2-norm squared of this vector. More... | |
double | norm2 () const |
Returns the 2-norm (Euclidean norm) of the vector. More... | |
double | norm1 () const |
Returns the 1-norm of the vector. More... | |
double | normInf () const |
Returns the infinity-norm (maximum norm) of the vector. More... | |
double | sumOfComponents () const |
Returns the sum of the components of the vector. More... | |
I/O methods. | |
void | print (std::ostream &os) const |
Print method. Defines the behavior of the std::ostream << operator inherited from the Object class. More... | |
Comparison methods. | |
bool | atLeastOneComponentSmallerThan (const GslVector &rhs) const |
This function returns true if at least one component of this is smaller than the respective component of rhs. More... | |
bool | atLeastOneComponentBiggerThan (const GslVector &rhs) const |
This function returns true if at least one component of this is bigger than the respective component of rhs. More... | |
bool | atLeastOneComponentSmallerOrEqualThan (const GslVector &rhs) const |
This function returns true if at least one component of this is smaller than or equal to the respective component of rhs. More... | |
bool | atLeastOneComponentBiggerOrEqualThan (const GslVector &rhs) const |
This function returns true if at least one component of this is bigger than or equal to the respective component of rhs. More... | |
Public Member Functions inherited from QUESO::Vector | |
Vector (const BaseEnvironment &env, const Map &map) | |
Shaped Constructor. More... | |
virtual | ~Vector () |
Virtual Destructor. More... | |
const BaseEnvironment & | env () const |
const Map & | map () const |
unsigned int | numOfProcsForStorage () const |
void | setPrintHorizontally (bool value) const |
Determines whether vector should be printed horizontally. More... | |
bool | getPrintHorizontally () const |
Checks if vector is printed horizontally. More... | |
void | setPrintScientific (bool value) const |
Determines whether vector should be printed in Scientific Notation. More... | |
bool | getPrintScientific () const |
Checks if the vector should be printed in Scientific Notation. More... | |
Private Member Functions | |
GslVector () | |
Default Constructor. More... | |
void | copy (const GslVector &src) |
This function copies the elements of the vector src into this . More... | |
Private Attributes | |
gsl_vector * | m_vec |
GSL vector. More... | |
Additional Inherited Members | |
Protected Member Functions inherited from QUESO::Vector | |
virtual void | base_copy (const Vector &src) |
Copies base data from vector src to this vector. More... | |
Protected Attributes inherited from QUESO::Vector | |
const BaseEnvironment & | m_env |
Environment variable. More... | |
const Map | m_map |
Mapping variable. More... | |
const Map & | m_map |
Mapping variable. More... | |
bool | m_printHorizontally |
Flag for either or not print this matrix horizontally. More... | |
bool | m_printScientific |
Flag for either or not print this matrix in scientific notation. More... | |
Class for vector operations using GSL library.
This class creates and provides basic support for vectors of templated type as a specialization of Vector using GSL vectors, which are defined by an encapsulated gsl_vector structure.
Definition at line 49 of file GslVector.h.
QUESO::GslVector::GslVector | ( | const BaseEnvironment & | env, |
const Map & | map | ||
) |
Construct a zero vector.
Definition at line 34 of file GslVector.C.
References QUESO::Vector::m_map, m_vec, QUESO::Map::NumGlobalElements(), QUESO::Map::NumMyElements(), and QUESO::queso_require_equal_to_msg.
QUESO::GslVector::GslVector | ( | const BaseEnvironment & | env, |
const Map & | map, | ||
double | value | ||
) |
Construct a vector with all entries set to value
.
Definition at line 57 of file GslVector.C.
References cwSet(), QUESO::Vector::m_map, m_vec, QUESO::Map::NumGlobalElements(), QUESO::Map::NumMyElements(), and QUESO::queso_require_equal_to_msg.
QUESO::GslVector::GslVector | ( | const BaseEnvironment & | env, |
double | d1, | ||
double | d2, | ||
const Map & | map | ||
) |
Construct a vector linearly interpolating from d1
to d2
,.
Definition at line 77 of file GslVector.C.
References QUESO::Vector::m_map, m_vec, QUESO::Map::NumGlobalElements(), QUESO::Map::NumMyElements(), and QUESO::queso_require_equal_to_msg.
QUESO::GslVector::GslVector | ( | const GslVector & | v, |
double | start, | ||
double | end | ||
) |
Construct a vector, with length the same as v
, with evenly spaced numbers from start
to end
, inclusive.
Definition at line 100 of file GslVector.C.
References QUESO::Vector::m_map, m_vec, QUESO::Vector::map(), QUESO::Map::NumGlobalElements(), QUESO::Map::NumMyElements(), and QUESO::queso_require_equal_to_msg.
QUESO::GslVector::GslVector | ( | const GslVector & | y | ) |
Construct a vector equal to y
.
Definition at line 123 of file GslVector.C.
References copy(), QUESO::Vector::m_map, m_vec, QUESO::Vector::map(), QUESO::Map::NumGlobalElements(), QUESO::Map::NumMyElements(), and QUESO::queso_require_equal_to_msg.
QUESO::GslVector::~GslVector | ( | ) |
|
private |
Default Constructor.
Creates an empty vector of no length.
GslVector QUESO::GslVector::abs | ( | ) | const |
This function returns absolute value of elements in this
.
Definition at line 1082 of file GslVector.C.
References QUESO::size, and sizeLocal().
Referenced by QUESO::GslMatrix::largestEigen(), and QUESO::GslMatrix::smallestEigen().
bool QUESO::GslVector::atLeastOneComponentBiggerOrEqualThan | ( | const GslVector & | rhs | ) | const |
This function returns true if at least one component of this
is bigger than or equal to the respective component of rhs.
Definition at line 1024 of file GslVector.C.
References QUESO::queso_require_equal_to_msg, QUESO::size, and sizeLocal().
bool QUESO::GslVector::atLeastOneComponentBiggerThan | ( | const GslVector & | rhs | ) | const |
This function returns true if at least one component of this
is bigger than the respective component of rhs.
Definition at line 992 of file GslVector.C.
References QUESO::queso_require_equal_to_msg, QUESO::size, and sizeLocal().
bool QUESO::GslVector::atLeastOneComponentSmallerOrEqualThan | ( | const GslVector & | rhs | ) | const |
This function returns true if at least one component of this
is smaller than or equal to the respective component of rhs.
Definition at line 1008 of file GslVector.C.
References QUESO::queso_require_equal_to_msg, QUESO::size, and sizeLocal().
bool QUESO::GslVector::atLeastOneComponentSmallerThan | ( | const GslVector & | rhs | ) | const |
This function returns true if at least one component of this
is smaller than the respective component of rhs.
Definition at line 976 of file GslVector.C.
References QUESO::queso_require_equal_to_msg, QUESO::size, and sizeLocal().
|
private |
This function copies the elements of the vector src into this
.
Definition at line 230 of file GslVector.C.
References QUESO::Vector::base_copy(), and m_vec.
Referenced by GslVector(), and operator=().
void QUESO::GslVector::cwExtract | ( | unsigned int | initialPos, |
GslVector & | vec | ||
) | const |
This function sets the values of this starting at position initialPos ans saves them in vector vec.
Definition at line 496 of file GslVector.C.
References sizeLocal().
|
virtual |
This function inverts component-wise the element values of this
.
Implements QUESO::Vector.
Definition at line 510 of file GslVector.C.
References QUESO::size, and sizeLocal().
Referenced by QUESO::operator/().
|
virtual |
Component-wise sets all values to this
with value.
Implements QUESO::Vector.
Definition at line 327 of file GslVector.C.
References QUESO::size, and sizeLocal().
Referenced by QUESO::GslOptimizer::GslOptimizer(), GslVector(), QUESO::GslMatrix::inverse(), and QUESO::GslOptimizer::setFstepSize().
void QUESO::GslVector::cwSet | ( | unsigned int | initialPos, |
const GslVector & | vec | ||
) |
This function sets the vector vec into this
starting at position initialPos.
Definition at line 482 of file GslVector.C.
References sizeLocal().
This function returns a random variate from the beta distribution, with vector parameters alpha and beta.
Definition at line 366 of file GslVector.C.
References QUESO::RngBase::betaSample(), QUESO::BaseEnvironment::displayVerbosity(), QUESO::BaseEnvironment::fullRank(), QUESO::Vector::m_env, QUESO::queso_require_equal_to_msg, QUESO::BaseEnvironment::rngObject(), sizeLocal(), and QUESO::BaseEnvironment::subDisplayFile().
This function concatenates GslVector v1 and GslVector v2 into this
.
Definition at line 449 of file GslVector.C.
References QUESO::queso_require_equal_to_msg, and sizeLocal().
void QUESO::GslVector::cwSetConcatenated | ( | const std::vector< const GslVector * > & | vecs | ) |
This function concatenates vectors v1
and v2
into this
vector.
Definition at line 465 of file GslVector.C.
References QUESO::queso_require_equal_to_msg, and sizeLocal().
This function returns a random variate from the gamma distribution with vector parameters a and b.
Definition at line 423 of file GslVector.C.
References QUESO::RngBase::gammaSample(), QUESO::Vector::m_env, QUESO::queso_require_equal_to_msg, QUESO::BaseEnvironment::rngObject(), and sizeLocal().
|
virtual |
This function sets component-wise Gaussian random variates, with mean mean and standard deviation stdDev.
Implements QUESO::Vector.
Definition at line 338 of file GslVector.C.
References QUESO::RngBase::gaussianSample(), QUESO::Vector::m_env, QUESO::BaseEnvironment::rngObject(), and sizeLocal().
This function sets component-wise Gaussian random variates, with vectors for mean and standard deviation.
Definition at line 348 of file GslVector.C.
References QUESO::RngBase::gaussianSample(), QUESO::Vector::m_env, QUESO::BaseEnvironment::rngObject(), and sizeLocal().
This function returns a random variate from the inverse gamma distribution with vector parameters alpha and beta.
Definition at line 436 of file GslVector.C.
References QUESO::RngBase::gammaSample(), QUESO::Vector::m_env, QUESO::queso_require_equal_to_msg, QUESO::BaseEnvironment::rngObject(), and sizeLocal().
This function sets component-wise a number uniformly distributed in the range of elements of [aVec,bVec].
Definition at line 357 of file GslVector.C.
References QUESO::Vector::m_env, QUESO::BaseEnvironment::rngObject(), sizeLocal(), and QUESO::RngBase::uniformSample().
void QUESO::GslVector::cwSqrt | ( | ) |
This function returns component-wise the square-root of this
.
Definition at line 521 of file GslVector.C.
References QUESO::size, and sizeLocal().
gsl_vector * QUESO::GslVector::data | ( | ) | const |
Definition at line 970 of file GslVector.C.
References m_vec.
Referenced by QUESO::GslMatrix::eigen(), QUESO::GslMatrix::internalSvd(), QUESO::GslMatrix::invertMultiply(), QUESO::GslMatrix::invertMultiplyForceLU(), QUESO::GslMatrix::setColumn(), QUESO::GslMatrix::setRow(), and QUESO::GslMatrix::svdSolve().
double QUESO::GslVector::getMaxValue | ( | ) | const |
Returns the maximum value in the vector this
.
Definition at line 1040 of file GslVector.C.
References m_vec.
Referenced by getMaxValueAndIndex().
void QUESO::GslVector::getMaxValueAndIndex | ( | double & | value, |
int & | index | ||
) |
This function returns maximum value in the vector this
and its the index.
Definition at line 1064 of file GslVector.C.
References getMaxValue(), and getMaxValueIndex().
int QUESO::GslVector::getMaxValueIndex | ( | ) | const |
This function returns the index of the maximum value in the vector this
.
Definition at line 1052 of file GslVector.C.
References m_vec.
Referenced by getMaxValueAndIndex().
double QUESO::GslVector::getMinValue | ( | ) | const |
Returns minimum value in the vector this
.
Definition at line 1046 of file GslVector.C.
References m_vec.
Referenced by getMinValueAndIndex().
void QUESO::GslVector::getMinValueAndIndex | ( | double & | value, |
int & | index | ||
) |
This function returns minimum value in the vector this
and its the index.
Definition at line 1073 of file GslVector.C.
References getMinValue(), and getMinValueIndex().
int QUESO::GslVector::getMinValueIndex | ( | ) | const |
This function returns the index of the minimum value in the vector this
.
Definition at line 1058 of file GslVector.C.
References m_vec.
Referenced by getMinValueAndIndex().
void QUESO::GslVector::matlabDiff | ( | unsigned int | firstPositionToStoreDiff, |
double | valueForRemainderPosition, | ||
GslVector & | outputVec | ||
) | const |
Definition at line 532 of file GslVector.C.
References QUESO::queso_require_equal_to_msg, QUESO::size, and sizeLocal().
void QUESO::GslVector::matlabLinearInterpExtrap | ( | const GslVector & | x1Vec, |
const GslVector & | y1Vec, | ||
const GslVector & | x2Vec | ||
) |
Definition at line 557 of file GslVector.C.
References QUESO::queso_require_equal_to_msg, and sizeLocal().
Referenced by QUESO::GslMatrix::matlabLinearInterpExtrap().
void QUESO::GslVector::mpiAllQuantile | ( | double | probability, |
const MpiComm & | opComm, | ||
GslVector & | resultVec | ||
) | const |
Definition at line 711 of file GslVector.C.
References QUESO::MpiComm::Bcast(), QUESO::MpiComm::Gather(), QUESO::MpiComm::MyPID(), QUESO::MpiComm::NumProc(), QUESO::queso_require_equal_to_msg, QUESO::size, and sizeLocal().
void QUESO::GslVector::mpiAllReduce | ( | RawType_MPI_Op | mpiOperation, |
const MpiComm & | opComm, | ||
GslVector & | resultVec | ||
) | const |
Definition at line 690 of file GslVector.C.
References QUESO::MpiComm::Allreduce(), QUESO::MpiComm::MyPID(), QUESO::queso_require_equal_to_msg, QUESO::size, and sizeLocal().
void QUESO::GslVector::mpiBcast | ( | int | srcRank, |
const MpiComm & | bcastComm | ||
) |
Definition at line 635 of file GslVector.C.
References QUESO::MpiComm::Allreduce(), QUESO::MpiComm::Barrier(), QUESO::MpiComm::Bcast(), QUESO::MpiComm::MyPID(), QUESO::MpiComm::NumProc(), QUESO::queso_require_equal_to_msg, and sizeLocal().
double QUESO::GslVector::norm1 | ( | ) | const |
Returns the 1-norm of the vector.
Definition at line 287 of file GslVector.C.
References QUESO::size, and sizeLocal().
double QUESO::GslVector::norm2 | ( | ) | const |
Returns the 2-norm (Euclidean norm) of the vector.
Definition at line 281 of file GslVector.C.
References norm2Sq().
Referenced by QUESO::GslMatrix::invertMultiply().
double QUESO::GslVector::norm2Sq | ( | ) | const |
Returns the 2-norm squared of this vector.
Definition at line 275 of file GslVector.C.
References QUESO::scalarProduct().
Referenced by norm2().
double QUESO::GslVector::normInf | ( | ) | const |
Returns the infinity-norm (maximum norm) of the vector.
Definition at line 300 of file GslVector.C.
References QUESO::size, and sizeLocal().
GslVector & QUESO::GslVector::operator*= | ( | double | a | ) |
Stores in this
the coordinate-wise multiplication of this
and a.
Definition at line 166 of file GslVector.C.
References m_vec.
Stores in this
the coordinate-wise multiplication of this
with rhs.
Definition at line 183 of file GslVector.C.
References QUESO::queso_require_equal_to_msg, and sizeLocal().
Stores in this
the coordinate-wise addition of this
and rhs.
Definition at line 211 of file GslVector.C.
References m_vec.
Stores in this
the coordinate-wise subtraction of this
by rhs.
Definition at line 220 of file GslVector.C.
References m_vec.
GslVector & QUESO::GslVector::operator/= | ( | double | a | ) |
Stores in this
the coordinate-wise division of this
by a.
Definition at line 175 of file GslVector.C.
Stores in this
the coordinate-wise division of this
by rhs.
Definition at line 197 of file GslVector.C.
References QUESO::queso_require_equal_to_msg, and sizeLocal().
Copies values from vector rhs to this
.
Definition at line 150 of file GslVector.C.
References copy(), QUESO::queso_require_equal_to_msg, and sizeLocal().
|
inline |
Element access method (non-const).
Returns the i-th element if x[i] is specified, the expression x(i) will return the same element.
Definition at line 271 of file GslVector.h.
References m_vec.
|
inline |
Element access method (const).
Returns the i-th element if x[i] is specified, the expression x(i) will return the same element.
Definition at line 279 of file GslVector.h.
References m_vec.
|
virtual |
Print method. Defines the behavior of the std::ostream << operator inherited from the Object class.
Implements QUESO::Vector.
Definition at line 743 of file GslVector.C.
References QUESO::Vector::m_printHorizontally, QUESO::Vector::m_printScientific, QUESO::size, and sizeLocal().
Referenced by QUESO::operator<<().
|
virtual |
Returns the global length of this vector.
Implements QUESO::Vector.
Definition at line 267 of file GslVector.C.
References QUESO::Vector::m_map, m_vec, QUESO::Map::NumGlobalElements(), and QUESO::queso_require_equal_to_msg.
|
virtual |
Returns the length of this vector.
Implements QUESO::Vector.
Definition at line 241 of file GslVector.C.
References QUESO::Vector::m_map, m_vec, QUESO::Map::NumMyElements(), and QUESO::queso_require_equal_to_msg.
Referenced by abs(), atLeastOneComponentBiggerOrEqualThan(), atLeastOneComponentBiggerThan(), atLeastOneComponentSmallerOrEqualThan(), atLeastOneComponentSmallerThan(), cwExtract(), cwInvert(), cwSet(), cwSetBeta(), cwSetConcatenated(), cwSetGamma(), cwSetGaussian(), cwSetInverseGamma(), cwSetUniform(), cwSqrt(), QUESO::GslMatrix::eigen(), QUESO::GslMatrix::fillWithTensorProduct(), QUESO::GslMatrix::getColumn(), QUESO::GslMatrix::getRow(), QUESO::GslMatrix::GslMatrix(), QUESO::GslBlockMatrix::invertMultiply(), QUESO::GslMatrix::invertMultiply(), QUESO::GslMatrix::invertMultiplyForceLU(), QUESO::GslMatrix::largestEigen(), QUESO::leftDiagScaling(), matlabDiff(), matlabLinearInterpExtrap(), QUESO::GslMatrix::matlabLinearInterpExtrap(), QUESO::matrixProduct(), mpiAllQuantile(), mpiAllReduce(), mpiBcast(), QUESO::GslMatrix::multiply(), norm1(), normInf(), operator*=(), operator/=(), operator=(), QUESO::operator==(), print(), QUESO::GslMatrix::rank(), QUESO::rightDiagScaling(), QUESO::scalarProduct(), QUESO::GslMatrix::setColumn(), QUESO::GslOptimizer::setInitialPoint(), QUESO::GslMatrix::setRow(), QUESO::GslMatrix::smallestEigen(), subReadContents(), subWriteContents(), sumOfComponents(), QUESO::GslMatrix::svd(), and QUESO::GslMatrix::svdSolve().
|
virtual |
This function sorts the elements of the vector this
in ascending numerical order.
Implements QUESO::Vector.
Definition at line 627 of file GslVector.C.
References m_vec.
void QUESO::GslVector::subReadContents | ( | const std::string & | fileName, |
const std::string & | fileType, | ||
const std::set< unsigned int > & | allowedSubEnvIds | ||
) |
Definition at line 843 of file GslVector.C.
References QUESO::BaseEnvironment::closeFile(), QUESO::BaseEnvironment::fullRank(), QUESO::FilePtrSetStruct::ifsVar, QUESO::Vector::m_env, QUESO::Vector::numOfProcsForStorage(), QUESO::BaseEnvironment::openInputFile(), QUESO::queso_require_equal_to_msg, sizeLocal(), QUESO::BaseEnvironment::subDisplayFile(), and QUESO::BaseEnvironment::subRank().
void QUESO::GslVector::subWriteContents | ( | const std::string & | varNamePrefix, |
const std::string & | fileName, | ||
const std::string & | fileType, | ||
const std::set< unsigned int > & | allowedSubEnvIds | ||
) | const |
Definition at line 803 of file GslVector.C.
References QUESO::BaseEnvironment::closeFile(), QUESO::Vector::getPrintHorizontally(), QUESO::Vector::getPrintScientific(), QUESO::Vector::m_env, QUESO::Vector::numOfProcsForStorage(), QUESO::FilePtrSetStruct::ofsVar, QUESO::BaseEnvironment::openOutputFile(), QUESO::Vector::setPrintHorizontally(), QUESO::Vector::setPrintScientific(), sizeLocal(), QUESO::BaseEnvironment::subIdString(), and QUESO::BaseEnvironment::subRank().
double QUESO::GslVector::sumOfComponents | ( | ) | const |
Returns the sum of the components of the vector.
Definition at line 315 of file GslVector.C.
References QUESO::size, and sizeLocal().
|
private |
GSL vector.
Definition at line 253 of file GslVector.h.
Referenced by copy(), data(), getMaxValue(), getMaxValueIndex(), getMinValue(), getMinValueIndex(), GslVector(), operator*=(), operator+=(), operator-=(), operator[](), sizeGlobal(), sizeLocal(), sort(), and ~GslVector().