Vector class that include the boost::ublas::vector. More...
#include <jrl/mal/boostvector.hh>
Public Member Functions | |
Constructors | |
Vector (const InternalVector::size_type size=0) | |
Classical constructor. More... | |
Vector (InternalVector *clone, const bool proprio=false) | |
Build only the capsule around a already existing boost vector object. More... | |
Vector (const Vector ©) | |
Build a new internal vector from existing boost vector object by copying the data. More... | |
virtual | ~Vector (void) |
InternalVector & | accessToMotherLib (void) |
Access to the boost internal vector. More... | |
const InternalVector & | accessToMotherLib (void) const |
Access to the boost internal vector. More... | |
Vector & | initFromMotherLib (const InternalVector &bv) |
Copy the values and data of an existing boost vector. More... | |
Modifiors | |
unsigned int | size (void) const |
Vector & | resize (const InternalVector::size_type nbRows, const bool setZero=true) |
Vector & | fill (const FloatType value) |
Vector & | setZero (void) |
Vector & | opposite (Vector &res) const |
Vector | opposite (void) const |
Accessors | |
Access to an element, a block of element or the hidden double-array matrix. | |
const FloatType * | datablock (void) const |
Access to the C-style double matrix. More... | |
FloatType * | datablock (void) |
Access to the C-style double matrix. More... | |
const FloatType & | elementAt (const InternalVector::size_type row) const |
Access to the i-th element in R-only. More... | |
FloatType & | elementAt (const InternalVector::size_type row) |
Access to the i-th element in RW-mode. More... | |
Vector & | extract (const InternalVector::size_type top, const InternalVector::size_type nbrows, Vector &C) const |
Extract a part of the vector. More... | |
Vector | extract (const InternalVector::size_type top, const InternalVector::size_type nbrows) const |
Extract a part of the vector. More... | |
Protected Attributes | |
InternalVector | staticVector |
InternalVector * | dynamicVector |
InternalVector & | vector |
bool | proprio |
Static Protected Attributes | |
static const bool | AUTORESIZE = true |
static const bool | CHECKRESIZE = true |
Friends | |
class | Matrix |
Scalar Operator E->R | |
FloatType | norm (void) const |
FloatType | norm1 (void) const |
Norm 1 sum( |xi| ) More... | |
FloatType | max (void) const |
Not implemented yet. More... | |
FloatType | min (void) const |
Not implemented yet. More... | |
FloatType | sumSquare (void) const |
Not implemented yet. More... | |
FloatType | normInfty (void) const |
Infinity norm: max( |xi| ). More... | |
FloatType | scalarProduct (const Vector &v2) const |
Scalar product: v1.v2 = sum( x1*x2 ). More... | |
static FloatType | scalarProduct (const Vector &v1, const Vector &v2) |
Scalar product: v1.v2 = sum( x1*x2 ). More... | |
Operator Functions ExE->E | |
Vector & | crossProduct (const Vector &v2, Vector &res) const |
Vector | crossProduct (const Vector &v2) |
Vector | multiply (const Vector &v2) const |
Vector & | multiply (const Vector &v2, Vector &res) const |
Vector | multiply (const FloatType x) const |
Vector & | multiply (const FloatType x, Vector &res) const |
Vector | addition (const Vector &v2) const |
Vector & | addition (const Vector &v2, Vector &res) const |
Vector | substraction (const Vector &v2) const |
Vector & | substraction (const Vector &v2, Vector &res) const |
static Vector & | crossProduct (const Vector &v1, const Vector &v2, Vector &res) |
static Vector & | multiply (const Vector &v1, const Vector &v2, Vector &res) |
static Vector & | multiply (const Vector &v1, const FloatType x, Vector &res) |
static Vector & | addition (const Vector &v1, const Vector &v2, Vector &res) |
static Vector & | substraction (const Vector &v1, const Vector &v2, Vector &res) |
Operators | |
Classical operators: use v1 + v2 for addition, v1(i) for i-th element... | |
Vector | operator+ (const Vector &v1, const Vector &v2) |
Vector | operator- (const Vector &v1, const Vector &v2) |
Vector | operator* (const Vector &v1, const Vector &v2) |
Vector | operator* (const Vector &v1, const FloatType x) |
Vector | operator* (const FloatType x, const Vector &v1) |
Vector | operator- (const Vector &v1) |
std::istream & | operator>> (std::istream &is, Vector &v1) |
std::ostream & | operator<< (std::ostream &os, const Vector &v1) |
Vector & | operator+= (const Vector &v1) |
Vector & | operator-= (const Vector &v1) |
Vector & | operator*= (const Vector &v1) |
Vector & | operator*= (const FloatType x) |
const FloatType & | operator() (const InternalVector::size_type i) const |
FloatType & | operator() (const InternalVector::size_type i) |
Vector & | operator= (const Vector &v1) |
Internal functions (autoresize) | |
bool | autoresize (void) |
static void | _resize (InternalVector &vct1, const InternalVector &vct2) |
static bool | _checksize (const InternalVector &vct1, const InternalVector &vct2) |
static bool | _checksizeVerb (const InternalVector &vct1, const InternalVector &vct2) |
static bool | _checksize (const InternalVector &vct1, const InternalVector::size_type s2) |
static bool | _checksizeVerb (const InternalVector &vct1, const InternalVector::size_type s2) |
Vector class that include the boost::ublas::vector.
The class simply encapsulates the ublas::vector object, and implement a set of standard functions. When the maal::boost::Vector object is constructed, it automatically builds the internal ublas::vector object. The internal object can be access through accessToMotherLib. Finally, it is possible to build the capsule around an existing boost ublas::vector through the appropriate constructor.
|
inline |
Classical constructor.
Build the internal vector from the demanded size.
|
inline |
Build only the capsule around a already existing boost vector object.
|
inline |
Build a new internal vector from existing boost vector object by copying the data.
|
inlinevirtual |
References dynamicVector.
|
inlinestaticprotected |
Referenced by addition(), crossProduct(), elementAt(), extract(), multiply(), and substraction().
|
inlinestaticprotected |
|
inlinestaticprotected |
|
inlinestaticprotected |
|
inlinestaticprotected |
Referenced by crossProduct(), and multiply().
|
inline |
Access to the boost internal vector.
References vector.
|
inline |
Access to the boost internal vector.
References vector.
|
inlinestatic |
References addition().
Referenced by addition(), and operator+=().
References addition(), and size().
References _checksize(), MAAL_CHECKVERBOSE, and vector.
|
inline |
References AUTORESIZE.
|
inlinestatic |
References crossProduct().
Referenced by crossProduct().
References _checksize(), _resize(), MAAL_CHECKVERBOSE, and vector.
References crossProduct(), and size().
|
inline |
Access to the C-style double matrix.
References VRAWDATA.
|
inline |
Access to the C-style double matrix.
References VRAWDATA.
|
inline |
Access to the i-th element in R-only.
This C-style function is equivalent to the C++ operator().
References _checksize(), MAAL_CHECKVERBOSE, and vector.
Referenced by operator()().
|
inline |
Access to the i-th element in RW-mode.
This C-style function is equivalent to the C++ operator().
References _checksize(), MAAL_CHECKVERBOSE, and vector.
|
inline |
Extract a part of the vector.
Not implemented yet.
References _checksize(), MAAL_CHECKVERBOSE, and vector.
Referenced by extract().
|
inline |
|
inline |
Copy the values and data of an existing boost vector.
|
inline |
Not implemented yet.
References ML_NOT_IMPLEMENTED.
|
inline |
Not implemented yet.
References ML_NOT_IMPLEMENTED.
|
inlinestatic |
References multiply().
Referenced by multiply(), and operator*=().
References multiply(), and size().
References _checksize(), _resize(), MAAL_CHECKVERBOSE, size(), and vector.
|
inlinestatic |
References multiply().
References multiply(), and size().
References vector.
|
inline |
|
inline |
Norm 1 sum( |xi| )
|
inline |
Infinity norm: max( |xi| ).
|
inline |
References vector.
|
inline |
References elementAt().
References multiply().
References multiply().
References addition().
References substraction().
|
inline |
References resize(), and setZero().
Referenced by maal::boost::Matrix::getDiagonal(), and resize().
Scalar product: v1.v2 = sum( x1*x2 ).
References vector.
|
inlinestatic |
Scalar product: v1.v2 = sum( x1*x2 ).
References vector.
|
inline |
Referenced by addition(), crossProduct(), fill(), multiply(), opposite(), maal::boost::Matrix::setDiagonal(), and substraction().
|
inlinestatic |
References substraction().
Referenced by operator-=(), and substraction().
References size(), and substraction().
References _checksize(), MAAL_CHECKVERBOSE, and vector.
|
inline |
Not implemented yet.
References ML_NOT_IMPLEMENTED.
|
friend |
|
friend |
|
friend |
|
staticprotected |
Referenced by autoresize().
|
staticprotected |
|
protected |
Referenced by ~Vector().
|
protected |
|
protected |
|
protected |