BALL::TVector4< T > Class Template Reference
[Four-dimensional vector.]

#include <BALL/MATHS/vector4.h>

List of all members.

Public Member Functions

Constructors and Destructors

 TVector4 ()
 TVector4 (const T *ptr) throw (Exception::NullPointer)
 TVector4 (const T &value)
 TVector4 (const T &x, const T &y, const T &z, const T &h=(T) 1)
 TVector4 (const TVector4 &vector)
virtual ~TVector4 ()
virtual void clear ()
Assignment

void set (const T *ptr) throw (Exception::NullPointer)
void set (const T &rx, const T &ry, const T &rz, const T &rh=(T) 1)
void set (const TVector4 &vector)
TVector4operator= (const T *ptr) throw (Exception::NullPointer)
TVector4operator= (const TVector4 &vector)
TVector4operator= (T value)
void get (T *ptr) const throw (Exception::NullPointer)
void get (T &rx, T &ry, T &rz, T &rh) const
void get (TVector4 &vector) const
void swap (TVector4 &vector)
Arithmetic operators

TVector4 operator+ () const
TVector4 operator- () const
TVector4operator+= (const TVector4 &vector)
TVector4operator-= (const TVector4 &vector)
TVector4 operator* (const T &scalar)
TVector4operator*= (const T &scalar)
TVector4 operator/ (const T &scalar) throw (Exception::DivisionByZero)
TVector4operator/= (const T &scalar) throw (Exception::DivisionByZero)
operator* (const TVector4 &vector) const
getDistance (const TVector4 &vector) const
getSquareDistance (const TVector4 &vector) const
Predicates

bool operator== (const TVector4 &vector) const
bool operator!= (const TVector4 &vector) const
bool isOrthogonalTo (const TVector4 &vector) const
Debugging and Diagnostics

bool isValid () const
void dump (std::ostream &s=std::cout, Size depth=0) const

Public Attributes

Attributes

All vector components are public members for convenience.

x
y
z
h

Accessors



getLength () const
getSquareLength () const
TVector4normalize () throw (Exception::DivisionByZero)
void set (const T &value=(T) 1)
T & operator[] (Position position) throw (Exception::IndexOverflow)
const T & operator[] (Position position) const throw (Exception::IndexOverflow)
static const TVector4getZero ()
static const TVector4getUnit ()

Detailed Description

template<typename T>
class BALL::TVector4< T >

Generic Four-Dimensional Vector. Representation of points and vectors in four-dimensional space.

Definition at line 54 of file vector4.h.

Generated by  doxygen 1.6.3