LRAUV  revA
Point3D Class Reference

Wraps three double precision (8-byte) floating point numbers. More...

#include <Point3D.h>

Inheritance diagram for Point3D:
Collaboration diagram for Point3D:

Public Member Functions

void setX (const double x)
 X positive along the vehicle axis, starting at the nose. More...
 
double getX () const
 
void setY (const double y)
 Y. More...
 
double getY () const
 
void setZ (const double z)
 Z. More...
 
double getZ () const
 
void setU (const double u)
 U – shares storage with X, alias for dX/dt. More...
 
double getU () const
 
void setV (const double v)
 V – shares storage with Y, alias for dY/dt. More...
 
double getV () const
 
void setW (const double w)
 W – shares storage with Z, alias for dZ/dt. More...
 
double getW () const
 
 Point3D ()
 Default constructior. More...
 
 Point3D (const double &init)
 Single value constructior. More...
 
 Point3D (const double &x, const double &y, const double &z)
 Multi value constructior. More...
 
 Point3D (const Point3D &value)
 Copy Constructor. More...
 
virtual ~Point3D ()
 Destructor. More...
 
Point3Dcopy () const
 Return a pointer to a new copy. More...
 
virtual Str toString () const
 
Point3Doperator= (const Point3D &rhs)
 
Point3Doperator= (const double rhs)
 
Point3Doperator+= (const Point3D &rhs)
 
Point3Doperator+= (const double rhs)
 
Point3D operator+ (const Point3D &rhs)
 
Point3Doperator-= (const Point3D &rhs)
 
Point3D operator- (const Point3D &rhs)
 
Point3Doperator-= (const double rhs)
 
Point3Doperator*= (const Point3D &rhs)
 
Point3D operator* (const double rhs)
 
Point3Doperator*= (const double rhs)
 
Point3DaddProduct (Matrix3x3 &lhs, Point3D &rhs)
 
Point3DtoAbs ()
 
double getMagnitude () const
 
double & operator[] (int index)
 
const double sum () const
 
const double sumSquared () const
 
virtual double * getPtr1d ()
 Implement abstract I1D method. More...
 
virtual int getM () const
 Implement abstract I2D method. More...
 
- Public Member Functions inherited from I1D< double >
virtual ~I1D ()
 

Protected Attributes

double value_ [3]
 

Additional Inherited Members

- Static Public Member Functions inherited from I1D< double >
static double * New1D (int m, bool extra=false)
 
static void Delete1D (double *array)
 
- Protected Member Functions inherited from I1D< double >
 I1D ()
 
 I1D (const I1D &)
 

Detailed Description

Wraps three double precision (8-byte) floating point numbers.

The 3 numbers are normally accessed as

  • x, y, and z
    -OR-
  • u, v, and w

Constructor & Destructor Documentation

Point3D::Point3D ( )

Default constructior.

References setX(), setY(), and setZ().

Referenced by copy().

Point3D::Point3D ( const double &  init)

Single value constructior.

References setX(), setY(), and setZ().

Point3D::Point3D ( const double &  x,
const double &  y,
const double &  z 
)

Multi value constructior.

References setX(), setY(), and setZ().

Point3D::Point3D ( const Point3D value)

Copy Constructor.

References getX(), getY(), getZ(), setX(), setY(), and setZ().

virtual Point3D::~Point3D ( )
inlinevirtual

Destructor.

Member Function Documentation

Point3D * Point3D::copy ( ) const

Return a pointer to a new copy.

References Point3D().

virtual int Point3D::getM ( ) const
inlinevirtual

Implement abstract I2D method.

Implements I1D< double >.

virtual double* Point3D::getPtr1d ( void  )
inlinevirtual

Implement abstract I1D method.

Implements I1D< double >.

References value_.

Referenced by addProduct(), and Matrix3x3::mult().

Point3D Point3D::operator* ( const double  rhs)

References getX(), getY(), getZ(), setX(), setY(), and setZ().

Point3D & Point3D::operator*= ( const Point3D rhs)

References getX(), getY(), getZ(), setX(), setY(), and setZ().

Point3D & Point3D::operator*= ( const double  rhs)

References getX(), getY(), getZ(), setX(), setY(), and setZ().

Point3D Point3D::operator+ ( const Point3D rhs)

References getX(), getY(), getZ(), setX(), setY(), and setZ().

Point3D & Point3D::operator+= ( const Point3D rhs)

References getX(), getY(), getZ(), setX(), setY(), and setZ().

Point3D & Point3D::operator+= ( const double  rhs)

References getX(), getY(), getZ(), setX(), setY(), and setZ().

Point3D Point3D::operator- ( const Point3D rhs)

References getX(), getY(), getZ(), setX(), setY(), and setZ().

Point3D & Point3D::operator-= ( const Point3D rhs)

References getX(), getY(), getZ(), setX(), setY(), and setZ().

Point3D & Point3D::operator-= ( const double  rhs)

References getX(), getY(), getZ(), setX(), setY(), and setZ().

Point3D & Point3D::operator= ( const Point3D rhs)

References getX(), getY(), getZ(), setX(), setY(), and setZ().

Point3D & Point3D::operator= ( const double  rhs)

References setX(), setY(), and setZ().

double & Point3D::operator[] ( int  index)

References value_.

void Point3D::setX ( const double  x)
inline
const double Point3D::sum ( ) const

References getX(), getY(), and getZ().

const double Point3D::sumSquared ( ) const

References getX(), getY(), and getZ().

Point3D & Point3D::toAbs ( )

References getX(), getY(), getZ(), setX(), setY(), and setZ().

Str Point3D::toString ( ) const
virtual

References value_.

Member Data Documentation

double Point3D::value_[3]
protected

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