geom::VecNd< n > Class Template Reference

#include <Points.h>

List of all members.

Public Types

typedef double Coord
enum  { Dim = n }
 Allow access to the dimension of the point. More...

Public Member Functions

 VecNd ()
 Default constructor; creates a vector of all zeros.
 VecNd (double a, double b)
 Constructor for a 2-d vector.
 VecNd (double a, double b, double c)
 Constructor for a 3-d vector.
 VecNd (double a, double b, double c, double d)
 Constructor for a 4-d vector.
 VecNd (const PointNd< n > &)
 Construct a VecNd from a PointNd.
double operator[] (int ii) const
 Return a coordinate of the vector.
double & operator[] (int ii)
 Return a coordinate of the vector by reference.
VecNd< n > & operator+= (const VecNd< n > &)
 Add + assign op.
VecNd< n > & operator-= (const VecNd< n > &)
 Subtract + assign op.
VecNd< n > & operator *= (double)
 Multiply by a scalar + assign.
VecNd< n > & operator/= (double)
 Divide by a scalar + assign.
void makeZero ()
 Set all coordinates to zero.

Friends

class boost::serialization::access


Detailed Description

template<int n>
class geom::VecNd< n >

An n-dimensional vector.
Parameters:
n The dimension of the vector.


Member Typedef Documentation

template<int n>
typedef double geom::VecNd< n >::Coord
 


Member Enumeration Documentation

template<int n>
anonymous enum
 

Allow access to the dimension of the point.

Enumerator:
Dim 


Constructor & Destructor Documentation

template<int n>
geom::VecNd< n >::VecNd  )  [inline]
 

Default constructor; creates a vector of all zeros.

template<int n>
geom::VecNd< n >::VecNd double  a,
double  b
[inline]
 

Constructor for a 2-d vector.

template<int n>
geom::VecNd< n >::VecNd double  a,
double  b,
double  c
[inline]
 

Constructor for a 3-d vector.

template<int n>
geom::VecNd< n >::VecNd double  a,
double  b,
double  c,
double  d
[inline]
 

Constructor for a 4-d vector.

template<int n>
geom::VecNd< n >::VecNd const PointNd< n > &   )  [inline, explicit]
 

Construct a VecNd from a PointNd.


Member Function Documentation

template<int n>
void geom::VecNd< n >::makeZero  )  [inline]
 

Set all coordinates to zero.

template<int n>
VecNd< n > & geom::VecNd< n >::operator *= double   )  [inline]
 

Multiply by a scalar + assign.

template<int n>
VecNd< n > & geom::VecNd< n >::operator+= const VecNd< n > &   )  [inline]
 

Add + assign op.

template<int n>
VecNd< n > & geom::VecNd< n >::operator-= const VecNd< n > &   )  [inline]
 

Subtract + assign op.

template<int n>
VecNd< n > & geom::VecNd< n >::operator/= double   )  [inline]
 

Divide by a scalar + assign.

template<int n>
double& geom::VecNd< n >::operator[] int  ii  )  [inline]
 

Return a coordinate of the vector by reference.

template<int n>
double geom::VecNd< n >::operator[] int  ii  )  const [inline]
 

Return a coordinate of the vector.


Friends And Related Function Documentation

template<int n>
friend class boost::serialization::access [friend]
 


The documentation for this class was generated from the following file:
Generated on Tue Jan 29 21:37:58 2008 for VoluMill Universal Client by  doxygen 1.4.6