- Main Page
- Classes
- Files

- Class List
- Class Hierarchy
- Class Members

# TVector Class Reference

`#include <tvector.h>`

List of all members.

## Public Types
| INVALID
| DEFAULT
| UNIT
enum | TStatus { INVALID, DEFAULT, UNIT }
## Public Member Functions
| TVector ()
| TVector (double x, double y, double z)
| TVector (const TRay &line1, const TRay &line2)
double | X () const
double | Y () const
double | Z () const
int | isUnit () const
int | isDefault () const
int | isValid () const
TVector & | unit ()
TVector & | Default ()
double | mag () const
double | magSqr () const
double | dot (const TVector &v) const
double | dist (const TVector &v) const
double | distSqr (const TVector &v) const
TVector | operator- () const
TVector & | operator+= (const TVector &v)
TVector & | operator-= (const TVector &v)
TVector & | operator *= (const TVector &v)
TVector & | operator *= (const double &scale)
TVector | operator+ (const TVector &v) const
TVector | operator- (const TVector &v) const
TVector | operator * (const TVector &v) const
TVector | operator * (const double &scale) const
## Static Public Member Functions
static TVector & | unit (const TVector &v, TVector &result)
static TVector | unit (const TVector &v)
static TVector | Default (const TVector &v, TVector &result)
static TVector | Default (const TVector &v)
static double | dot (const TVector &v1, const TVector &v2)
static TVector & | add (const TVector &v1, const TVector &v2, TVector &result)
static TVector & | subtract (const TVector &v1, const TVector &v2, TVector &result)
static TVector & | cross (const TVector &v1, const TVector &v2, TVector &result)
static TVector & | invert (const TVector &v1, TVector &result)
static TVector & | multiply (const TVector &v1, const double &scale, TVector &result)
static TVector | getVectorAngleMoved (const TVector &v1, double GammaAngle)
static TVector | getVectorAngleMoved2 (const TVector &v1, double GammaAngle)
## Private Member Functions
| TVector (double x, double y, double z, TStatus s)
ostream & | write (ostream &out) const
istream & | read (istream &in)
## Private Attributes
double | _x
double | _y
double | _z
TStatus | _Status
## Friends
ostream & | operator<< (ostream &out, const TVector &o)
istream & | operator>> (istream &in, TVector &o)

## Member Enumeration Documentation

enum TVector::TStatus

Enumerator:

  INVALID |
  DEFAULT |
  UNIT |

## Constructor & Destructor Documentation

TVector::TVector | ( | double | x,
|  | double | y,
|  | double | z,
|  | TStatus | s |
| ) |  |  | `[inline, private]`

TVector::TVector | ( |  | ) | `[inline]`

TVector::TVector | ( | double | x,
|  | double | y,
|  | double | z |
| ) |  |  | `[inline]`

TVector::TVector | ( | const TRay & | line1,
|  | const TRay & | line2 |
| ) |  |  |

## Member Function Documentation

TVector & TVector::add | ( | const TVector & | v1,
|  | const TVector & | v2,
|  | TVector & | result |
| ) |  |  | `[static]`

TVector & TVector::cross | ( | const TVector & | v1,
|  | const TVector & | v2,
|  | TVector & | result |
| ) |  |  | `[static]`

static TVector TVector::Default | ( | const TVector & | v | ) | `[inline, static]`

static TVector TVector::Default | ( | const TVector & | v,
|  | TVector & | result |
| ) |  |  | `[inline, static]`

TVector & TVector::Default | ( |  | ) |

double TVector::dist | ( | const TVector & | v | ) | const`[inline]`

double TVector::distSqr | ( | const TVector & | v | ) | const`[inline]`

static double TVector::dot | ( | const TVector & | v1,
|  | const TVector & | v2 |
| ) |  |  | `[inline, static]`

double TVector::dot | ( | const TVector & | v | ) | const`[inline]`

TVector TVector::getVectorAngleMoved | ( | const TVector & | v1,
|  | double | GammaAngle |
| ) |  |  | `[static]`

TVector TVector::getVectorAngleMoved2 | ( | const TVector & | v1,
|  | double | GammaAngle |
| ) |  |  | `[static]`

TVector & TVector::invert | ( | const TVector & | v1,
|  | TVector & | result |
| ) |  |  | `[static]`

int TVector::isDefault | ( |  | ) | const`[inline]`

int TVector::isUnit | ( |  | ) | const`[inline]`

int TVector::isValid | ( |  | ) | const`[inline]`

double TVector::mag | ( |  | ) | const`[inline]`

double TVector::magSqr | ( |  | ) | const`[inline]`

TVector & TVector::multiply | ( | const TVector & | v1,
|  | const double & | scale,
|  | TVector & | result |
| ) |  |  | `[static]`

TVector TVector::operator * | ( | const double & | scale | ) | const`[inline]`

TVector TVector::operator * | ( | const TVector & | v | ) | const`[inline]`

TVector& TVector::operator *= | ( | const double & | scale | ) | `[inline]`

TVector& TVector::operator *= | ( | const TVector & | v | ) | `[inline]`

TVector TVector::operator+ | ( | const TVector & | v | ) | const`[inline]`

TVector& TVector::operator+= | ( | const TVector & | v | ) | `[inline]`

TVector TVector::operator- | ( | const TVector & | v | ) | const`[inline]`

TVector TVector::operator- | ( |  | ) | const`[inline]`

TVector& TVector::operator-= | ( | const TVector & | v | ) | `[inline]`

istream & TVector::read | ( | istream & | in | ) | `[private]`

TVector & TVector::subtract | ( | const TVector & | v1,
|  | const TVector & | v2,
|  | TVector & | result |
| ) |  |  | `[static]`

static TVector TVector::unit | ( | const TVector & | v | ) | `[inline, static]`

static TVector& TVector::unit | ( | const TVector & | v,
|  | TVector & | result |
| ) |  |  | `[inline, static]`

TVector & TVector::unit | ( |  | ) |

ostream & TVector::write | ( | ostream & | out | ) | const`[private]`

double TVector::X | ( |  | ) | const`[inline]`

double TVector::Y | ( |  | ) | const`[inline]`

double TVector::Z | ( |  | ) | const`[inline]`

## Friends And Related Function Documentation

ostream& operator<< | ( | ostream & | out,
|  | const TVector & | o |
| ) |  |  | `[friend]`

istream& operator>> | ( | istream & | in,
|  | TVector & | o |
| ) |  |  | `[friend]`

## Member Data Documentation

TStatus TVector::_Status`[private]`

double TVector::_x`[private]`

double TVector::_y`[private]`

double TVector::_z`[private]`

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

- src/vectorMath/tvector.h
- src/vectorMath/tvector.cpp