ROOT  6.07/01
Reference Guide
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
List of all members | Public Types | Public Member Functions | Private Member Functions | Static Private Member Functions | Private Attributes | List of all members
ROOT::Math::Polar3D< T > Class Template Reference

template<class T>
class ROOT::Math::Polar3D< T >

Class describing a polar coordinate system based on r, theta and phi Phi is restricted to be in the range [-PI,PI)

Class describing a 3D Polar coordinate system (r, theta, phi coordinates)

Definition at line 46 of file Polar3D.h.

Public Types

typedef T Scalar
 

Public Member Functions

 Polar3D ()
 Default constructor with r=theta=phi=0. More...
 
 Polar3D (T r, T theta, T phi)
 Construct from the polar coordinates: r, theta and phi. More...
 
template<class CoordSystem >
 Polar3D (const CoordSystem &v)
 Construct from any Vector or coordinate system implementing R(), Theta() and Phi() More...
 
 Polar3D (const Polar3D &v)
 copy constructor More...
 
Polar3Doperator= (const Polar3D &v)
 assignment operator More...
 
void SetCoordinates (const Scalar src[])
 Set internal data based on an array of 3 Scalar numbers. More...
 
void GetCoordinates (Scalar dest[]) const
 get internal data into an array of 3 Scalar numbers More...
 
void SetCoordinates (Scalar r, Scalar theta, Scalar phi)
 Set internal data based on 3 Scalar numbers. More...
 
void GetCoordinates (Scalar &r, Scalar &theta, Scalar &phi) const
 get internal data into 3 Scalar numbers More...
 
Scalar R () const
 
Scalar Phi () const
 
Scalar Theta () const
 
Scalar Rho () const
 
Scalar X () const
 
Scalar Y () const
 
Scalar Z () const
 
Scalar Mag2 () const
 
Scalar Perp2 () const
 
Scalar Eta () const
 
void SetR (const T &r)
 set the r coordinate value keeping theta and phi constant More...
 
void SetTheta (const T &theta)
 set the theta coordinate value keeping r and phi constant More...
 
void SetPhi (const T &phi)
 set the phi coordinate value keeping r and theta constant More...
 
void SetXYZ (Scalar x, Scalar y, Scalar z)
 set all values using cartesian coordinates More...
 
void Scale (T a)
 scale by a scalar quantity - for polar coordinates r changes More...
 
void Negate ()
 negate the vector More...
 
template<class CoordSystem >
Polar3Doperator= (const CoordSystem &c)
 generic assignment operator from any coordinate system More...
 
bool operator== (const Polar3D &rhs) const
 Exact equality. More...
 
bool operator!= (const Polar3D &rhs) const
 
T x () const
 
T y () const
 
T z () const
 

Private Member Functions

void Restrict ()
 

Static Private Member Functions

static Scalar pi ()
 

Private Attributes

T fR
 
T fTheta
 
T fPhi
 

#include <Math/GenVector/Polar3D.h>

Member Typedef Documentation

template<class T>
typedef T ROOT::Math::Polar3D< T >::Scalar

Definition at line 50 of file Polar3D.h.

Constructor & Destructor Documentation

template<class T>
ROOT::Math::Polar3D< T >::Polar3D ( )
inline

Default constructor with r=theta=phi=0.

Definition at line 55 of file Polar3D.h.

template<class T>
ROOT::Math::Polar3D< T >::Polar3D ( T  r,
T  theta,
T  phi 
)
inline

Construct from the polar coordinates: r, theta and phi.

Definition at line 60 of file Polar3D.h.

template<class T>
template<class CoordSystem >
ROOT::Math::Polar3D< T >::Polar3D ( const CoordSystem &  v)
inlineexplicit

Construct from any Vector or coordinate system implementing R(), Theta() and Phi()

Definition at line 67 of file Polar3D.h.

template<class T>
ROOT::Math::Polar3D< T >::Polar3D ( const Polar3D< T > &  v)
inline

copy constructor

Definition at line 76 of file Polar3D.h.

Member Function Documentation

template<class T>
Scalar ROOT::Math::Polar3D< T >::Eta ( ) const
inline

Definition at line 124 of file Polar3D.h.

template<class T>
void ROOT::Math::Polar3D< T >::GetCoordinates ( Scalar  dest[]) const
inline

get internal data into an array of 3 Scalar numbers

Definition at line 98 of file Polar3D.h.

template<class T>
void ROOT::Math::Polar3D< T >::GetCoordinates ( Scalar r,
Scalar theta,
Scalar phi 
) const
inline

get internal data into 3 Scalar numbers

Definition at line 110 of file Polar3D.h.

template<class T>
Scalar ROOT::Math::Polar3D< T >::Mag2 ( ) const
inline

Definition at line 120 of file Polar3D.h.

template<class T>
void ROOT::Math::Polar3D< T >::Negate ( )
inline

negate the vector

Definition at line 185 of file Polar3D.h.

Referenced by ROOT::Math::Polar3D< T >::Scale().

template<class T>
bool ROOT::Math::Polar3D< T >::operator!= ( const Polar3D< T > &  rhs) const
inline

Definition at line 208 of file Polar3D.h.

template<class T>
Polar3D& ROOT::Math::Polar3D< T >::operator= ( const Polar3D< T > &  v)
inline

assignment operator

Definition at line 82 of file Polar3D.h.

template<class T>
template<class CoordSystem >
Polar3D& ROOT::Math::Polar3D< T >::operator= ( const CoordSystem &  c)
inline

generic assignment operator from any coordinate system

Definition at line 195 of file Polar3D.h.

template<class T>
bool ROOT::Math::Polar3D< T >::operator== ( const Polar3D< T > &  rhs) const
inline

Exact equality.

Definition at line 205 of file Polar3D.h.

Referenced by ROOT::Math::Polar3D< T >::operator!=().

template<class T>
Scalar ROOT::Math::Polar3D< T >::Perp2 ( ) const
inline

Definition at line 121 of file Polar3D.h.

template<class T>
Scalar ROOT::Math::Polar3D< T >::Phi ( ) const
inline
template<class T>
static Scalar ROOT::Math::Polar3D< T >::pi ( )
inlinestaticprivate
template<class T>
Scalar ROOT::Math::Polar3D< T >::R ( ) const
inline

Definition at line 113 of file Polar3D.h.

Referenced by ROOT::Math::Polar3D< T >::operator=().

template<class T>
void ROOT::Math::Polar3D< T >::Restrict ( )
inlineprivate
template<class T>
Scalar ROOT::Math::Polar3D< T >::Rho ( ) const
inline
template<class T>
void ROOT::Math::Polar3D< T >::Scale ( T  a)
inline

scale by a scalar quantity - for polar coordinates r changes

Definition at line 173 of file Polar3D.h.

template<class T>
void ROOT::Math::Polar3D< T >::SetCoordinates ( const Scalar  src[])
inline

Set internal data based on an array of 3 Scalar numbers.

Definition at line 92 of file Polar3D.h.

template<class T>
void ROOT::Math::Polar3D< T >::SetCoordinates ( Scalar  r,
Scalar  theta,
Scalar  phi 
)
inline

Set internal data based on 3 Scalar numbers.

Definition at line 104 of file Polar3D.h.

template<class T>
void ROOT::Math::Polar3D< T >::SetPhi ( const T phi)
inline

set the phi coordinate value keeping r and theta constant

Definition at line 149 of file Polar3D.h.

template<class T>
void ROOT::Math::Polar3D< T >::SetR ( const T r)
inline

set the r coordinate value keeping theta and phi constant

Definition at line 135 of file Polar3D.h.

template<class T>
void ROOT::Math::Polar3D< T >::SetTheta ( const T theta)
inline

set the theta coordinate value keeping r and phi constant

Definition at line 142 of file Polar3D.h.

template<class T >
void ROOT::Math::Polar3D< T >::SetXYZ ( Scalar  x,
Scalar  y,
Scalar  z 
)

set all values using cartesian coordinates

Definition at line 272 of file Polar3D.h.

template<class T>
Scalar ROOT::Math::Polar3D< T >::Theta ( ) const
inline

Definition at line 115 of file Polar3D.h.

Referenced by ROOT::Math::Polar3D< T >::operator=().

template<class T>
Scalar ROOT::Math::Polar3D< T >::X ( ) const
inline

Definition at line 117 of file Polar3D.h.

Referenced by ROOT::Math::Polar3D< T >::x().

template<class T>
T ROOT::Math::Polar3D< T >::x ( ) const
inline

Definition at line 215 of file Polar3D.h.

template<class T>
Scalar ROOT::Math::Polar3D< T >::Y ( ) const
inline

Definition at line 118 of file Polar3D.h.

Referenced by ROOT::Math::Polar3D< T >::y().

template<class T>
T ROOT::Math::Polar3D< T >::y ( ) const
inline

Definition at line 216 of file Polar3D.h.

template<class T>
Scalar ROOT::Math::Polar3D< T >::Z ( ) const
inline
template<class T>
T ROOT::Math::Polar3D< T >::z ( ) const
inline

Definition at line 217 of file Polar3D.h.

Member Data Documentation

template<class T>
T ROOT::Math::Polar3D< T >::fPhi
private
template<class T>
T ROOT::Math::Polar3D< T >::fR
private
template<class T>
T ROOT::Math::Polar3D< T >::fTheta
private
Collaboration diagram for ROOT::Math::Polar3D< T >:
[legend]

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