IMP  2.2.1
The Integrative Modeling Platform
IMP::algebra::VectorD< D > Class Template Reference

A Cartesian vector in D-dimensions. More...

#include <IMP/algebra/VectorD.h>

+ Inheritance diagram for IMP::algebra::VectorD< D >:

Public Member Functions

template<class Range >
 VectorD (const Range &r)
 
template<int OD>
 VectorD (const VectorD< OD > &o)
 
template<class It >
 VectorD (It b, It e)
 
VectorD get_unit_vector () const
 
double operator* (const VectorD &o) const
 
VectorD operator* (double s) const
 
VectorDoperator*= (double f)
 
VectorD operator+ (VectorD ret) const
 
VectorDoperator+= (const VectorD &o)
 
VectorD operator- () const
 
VectorD operator- (const VectorD &o) const
 
VectorDoperator-= (const VectorD &o)
 
VectorD operator/ (double s) const
 
VectorDoperator/= (double f)
 
template<class R >
VectorDoperator= (const R &o)
 
- Public Member Functions inherited from IMP::algebra::VectorBaseD< D >
template<class Range >
 VectorBaseD (const Range &r)
 
 VectorBaseD ()
 Default constructor.
 
iterator begin ()
 
const_iterator begin () const
 
iterator coordinates_begin ()
 
const_iterator coordinates_begin () const
 
iterator coordinates_end ()
 
const_iterator coordinates_end () const
 
iterator end ()
 
const_iterator end () const
 
Floats get_coordinates () const
 
const double * get_data () const
 
unsigned int get_dimension () const
 
double get_magnitude () const
 
double get_scalar_product (const VectorBaseD< D > &o) const
 
double get_squared_magnitude () const
 
template<class R >
VectorBaseD< D > & operator= (const R &r)
 
double operator[] (unsigned int i) const
 
double & operator[] (unsigned int i)
 

Additional Inherited Members

- Public Types inherited from IMP::algebra::VectorBaseD< D >
typedef const double * const_iterator
 
typedef const double & const_reference
 
typedef std::ptrdiff_t difference_type
 
typedef double * iterator
 
typedef
std::random_access_iterator_tag 
iterator_category
 
typedef double * pointer
 
typedef double & reference
 
typedef double value_type
 
- Static Public Attributes inherited from IMP::algebra::VectorBaseD< D >
static const int DIMENSION = D
 

Detailed Description

template<int D>
class IMP::algebra::VectorD< D >

Store a vector of Cartesian coordinates. It supports all expected mathematical operators, including using * for the dot product.

See Also
Vector3D
Vector2D

See geometric primitives for more information.

Definition at line 52 of file VectorD.h.

Constructor & Destructor Documentation

template<int D>
template<class Range >
IMP::algebra::VectorD< D >::VectorD ( const Range &  r)
explicit

Will accept a list of floats from python.

Definition at line 55 of file VectorD.h.

template<int D>
template<class It >
IMP::algebra::VectorD< D >::VectorD ( It  b,
It  e 
)

The distance between b and e must be equal to D . \

Definition at line 55 of file VectorD.h.


The documentation for this class was generated from the following file: