19 #ifndef ROOT_Math_GenVector_Polar2D 20 #define ROOT_Math_GenVector_Polar2D 1 63 template <
class CoordSystem >
98 Scalar
R()
const {
return fR;}
127 void SetXY(Scalar
a, Scalar
b);
131 inline static double pi() {
return M_PI; }
173 template <
class CoordSystem >
193 T x()
const {
return X();}
194 T y()
const {
return Y();}
200 #if defined(__MAKECINT__) || defined(G__DICTIONARY) 225 #if defined(__MAKECINT__) || defined(G__DICTIONARY) 239 #if defined(__MAKECINT__) || defined(G__DICTIONARY)
Namespace for new ROOT classes and functions.
void SetY(Scalar a)
set the y coordinate value keeping x constant
void SetR(const T &r)
set the r coordinate value keeping phi constant
void Rotate(T angle)
rotate the vector
Polar2D(const CoordSystem &v)
Construct from any Vector or coordinate system implementing R() and Phi()
void SetPhi(const T &phi)
set the phi coordinate value keeping r constant
Polar2D(const Polar2D &v)
copy constructor
bool operator!=(const Polar2D &rhs) const
Class describing a polar 2D coordinate system based on r and phi Phi is restricted to be in the range...
void SetX(Scalar a)
set the x coordinate value keeping y constant
void Restrict()
restrict abgle hi to be between -PI and PI
bool operator==(const Polar2D &rhs) const
Exact equality.
void Negate()
negate the vector
Polar2D()
Default constructor with r=1,phi=0.
void SetCoordinates(Scalar r, Scalar phi)
Set internal data based on 2 Scalar numbers.
you should not use this method at all Int_t Int_t Double_t Double_t Double_t e
Class describing a 2D cartesian coordinate system (x, y coordinates)
void SetXY(Scalar a, Scalar b)
set all values using cartesian coordinates
void GetCoordinates(Scalar &r, Scalar &phi) const
get internal data into 2 Scalar numbers
Namespace for new Math classes and functions.
Polar2D & operator=(const Polar2D &v)
assignment operator
you should not use this method at all Int_t Int_t Double_t Double_t Double_t Int_t Double_t Double_t Double_t Double_t b
void Scale(T a)
scale by a scalar quantity - for polar coordinates r changes
Polar2D(T r, T phi)
Construct from the polar coordinates: r and phi.