7 #ifndef __IPCOMPOUNDVECTOR_HPP__ 8 #define __IPCOMPOUNDVECTOR_HPP__ 18 class CompoundVectorSpace;
68 inline Index NComps()
const;
121 virtual void CopyImpl(
126 virtual void ScalImpl(
130 virtual void AxpyImpl(
139 virtual Number Nrm2Impl()
const;
141 virtual Number AsumImpl()
const;
143 virtual Number AmaxImpl()
const;
145 virtual void SetImpl(
149 virtual void ElementWiseDivideImpl(
153 virtual void ElementWiseMultiplyImpl(
157 virtual void ElementWiseMaxImpl(
161 virtual void ElementWiseMinImpl(
165 virtual void ElementWiseReciprocalImpl();
167 virtual void ElementWiseAbsImpl();
169 virtual void ElementWiseSqrtImpl();
171 virtual void ElementWiseSgnImpl();
173 virtual void AddScalarImpl(
177 virtual Number MaxImpl()
const;
179 virtual Number MinImpl()
const;
181 virtual Number SumImpl()
const;
183 virtual Number SumLogsImpl()
const;
187 void AddTwoVectorsImpl(
201 void AddVectorQuotientImpl(
210 virtual bool HasValidNumbersImpl()
const;
213 virtual void PrintImpl(
218 const std::string& name,
220 const std::string& prefix
261 inline const Vector* ConstComp(
296 virtual void SetCompSpace(
309 return ncomp_spaces_;
314 bool create_new =
true 322 return MakeNewCompoundVector();
bool IsValid(const SmartPtr< U > &smart_ptr)
const Index ncomp_spaces_
Number of components.
std::vector< SmartPtr< Vector > > comps_
Components of the compound vector.
double Number
Type of all numbers.
SmartPtr< Vector > GetCompNonConst(Index i)
Return a particular component (non-const version).
virtual CompoundVector * MakeNewCompoundVector(bool create_new=true) const
Method for creating a new vector of this specific type.
EJournalLevel
Print Level Enum.
This file contains a base class for all exceptions and a set of macros to help with exceptions...
Template class for Smart Pointers.
VectorSpace base class, corresponding to the Vector base class.
bool IsCompNull(Index i) const
Check if a particular component is null or not.
U * GetRawPtr(const SmartPtr< U > &smart_ptr)
SmartPtr< const Vector > GetComp(Index i) const
Return a particular component (const version)
~CompoundVectorSpace()
Destructor.
int Index
Type of all indices of vectors, matrices etc.
bool IsCompConst(Index i) const
Check if a particular component is const or not.
const CompoundVectorSpace * owner_space_
Index NComps() const
Number of components of this compound vector.
Class responsible for all message output.
std::vector< SmartPtr< const VectorSpace > > comp_spaces_
std::vector of vector spaces for the components
Index NCompSpaces() const
Accessor method to obtain the number of components.
virtual Vector * MakeNew() const
Pure virtual method for creating a new Vector of the corresponding type.
This vectors space is the vector space for CompoundVector.
EJournalCategory
Category Selection Enum.
const Vector * ConstComp(Index i) const
Class of Vectors consisting of other vectors.
std::vector< SmartPtr< const Vector > > const_comps_