ROOT 6.13/01 Reference Guide |
TVector2 is a general two vector class, which can be used for the description of different vectors in 2D.
Definition at line 18 of file TVector2.h.
Public Types | |
typedef Double_t | Scalar |
Public Member Functions | |
TVector2 () | |
Constructor. More... | |
TVector2 (Double_t *s) | |
Constructor. More... | |
TVector2 (Double_t x0, Double_t y0) | |
Constructor. More... | |
virtual | ~TVector2 () |
Double_t | DeltaPhi (const TVector2 &v) const |
Double_t | Mod () const |
Return modulo of this vector. More... | |
Double_t | Mod2 () const |
TVector2 | Norm (const TVector2 &v) const |
Double_t | operator*= (TVector2 const &v) |
TVector2 & | operator*= (Double_t s) |
TVector2 & | operator+= (TVector2 const &v) |
TVector2 & | operator-= (TVector2 const &v) |
TVector2 & | operator/= (Double_t s) |
TVector2 & | operator= (TVector2 const &v) |
TVector2 | Ort () const |
Double_t | Phi () const |
Return vector phi. More... | |
void | Print (Option_t *option="") const |
TVector2 | Proj (const TVector2 &v) const |
Double_t | Px () const |
Double_t | Py () const |
TVector2 | Rotate (Double_t phi) const |
Rotation by phi. More... | |
void | Set (const TVector2 &v) |
void | Set (Double_t x0, Double_t y0) |
void | Set (float x0, float y0) |
void | SetMagPhi (Double_t mag, Double_t phi) |
Set vector using mag and phi. More... | |
void | SetX (Double_t x0) |
void | SetY (Double_t y0) |
TVector2 | Unit () const |
Return module normalized to 1. More... | |
Double_t | X () const |
Double_t | Y () const |
Static Public Member Functions | |
static Double_t | Phi_0_2pi (Double_t x) |
Returns phi angle in the interval [0,2*PI) More... | |
static Double_t | Phi_mpi_pi (Double_t x) |
Returns phi angle in the interval [-PI,PI) More... | |
Protected Attributes | |
Double_t | fX |
Double_t | fY |
Friends | |
Double_t | operator* (const TVector2 &, const TVector2 &) |
TVector2 | operator* (const TVector2 &, Double_t) |
TVector2 | operator* (Double_t, const TVector2 &) |
TVector2 | operator+ (const TVector2 &, const TVector2 &) |
TVector2 | operator+ (const TVector2 &, Double_t) |
TVector2 | operator+ (Double_t, const TVector2 &) |
TVector2 | operator- (const TVector2 &, const TVector2 &) |
TVector2 | operator- (const TVector2 &, Double_t) |
TVector2 | operator/ (const TVector2 &, Double_t) |
Double_t | operator^ (const TVector2 &, const TVector2 &) |
#include <TVector2.h>
typedef Double_t TVector2::Scalar |
Definition at line 31 of file TVector2.h.
TVector2::TVector2 | ( | ) |
Constructor.
Definition at line 31 of file TVector2.cxx.
TVector2::TVector2 | ( | Double_t * | s | ) |
Constructor.
Definition at line 40 of file TVector2.cxx.
TVector2::TVector2 | ( | Double_t | x0, |
Double_t | y0 | ||
) |
Constructor.
Definition at line 49 of file TVector2.cxx.
|
virtual |
Definition at line 57 of file TVector2.cxx.
|
inline |
Definition at line 166 of file TVector2.h.
Double_t TVector2::Mod | ( | ) | const |
Return modulo of this vector.
Definition at line 64 of file TVector2.cxx.
|
inline |
Definition at line 67 of file TVector2.h.
Definition at line 172 of file TVector2.h.
|
inline |
Definition at line 119 of file TVector2.h.
|
inline |
Definition at line 121 of file TVector2.h.
Definition at line 114 of file TVector2.h.
Definition at line 115 of file TVector2.h.
|
inline |
Definition at line 122 of file TVector2.h.
Definition at line 113 of file TVector2.h.
|
inline |
Definition at line 168 of file TVector2.h.
Double_t TVector2::Phi | ( | ) | const |
Return vector phi.
Definition at line 80 of file TVector2.cxx.
|
static |
Returns phi angle in the interval [0,2*PI)
Definition at line 88 of file TVector2.cxx.
|
static |
Returns phi angle in the interval [-PI,PI)
Definition at line 101 of file TVector2.cxx.
void TVector2::Print | ( | Option_t * | option = "" | ) | const |
Definition at line 152 of file TVector2.cxx.
Definition at line 170 of file TVector2.h.
|
inline |
Definition at line 70 of file TVector2.h.
|
inline |
Definition at line 71 of file TVector2.h.
TVector2 TVector2::Rotate | ( | Double_t | phi | ) | const |
Rotation by phi.
Definition at line 114 of file TVector2.cxx.
|
inline |
Definition at line 176 of file TVector2.h.
|
inline |
Definition at line 177 of file TVector2.h.
|
inline |
Definition at line 178 of file TVector2.h.
void TVector2::SetMagPhi | ( | Double_t | mag, |
Double_t | phi | ||
) |
Set vector using mag and phi.
Definition at line 122 of file TVector2.cxx.
|
inline |
Definition at line 179 of file TVector2.h.
|
inline |
Definition at line 180 of file TVector2.h.
TVector2 TVector2::Unit | ( | ) | const |
Return module normalized to 1.
Definition at line 72 of file TVector2.cxx.
|
inline |
Definition at line 72 of file TVector2.h.
|
inline |
Definition at line 73 of file TVector2.h.
Definition at line 154 of file TVector2.h.
Definition at line 146 of file TVector2.h.
Definition at line 150 of file TVector2.h.
Definition at line 126 of file TVector2.h.
Definition at line 130 of file TVector2.h.
Definition at line 134 of file TVector2.h.
Definition at line 138 of file TVector2.h.
Definition at line 142 of file TVector2.h.
Definition at line 158 of file TVector2.h.
Definition at line 162 of file TVector2.h.
|
protected |
Definition at line 24 of file TVector2.h.
|
protected |
Definition at line 25 of file TVector2.h.