/search.css" rel="stylesheet" type="text/css"/> /search.js">
| Classes | Job Modules | Data Objects | Services | Algorithms | Tools | Packages | Directories | Tracs |

In This Package:

Public Member Functions | Private Member Functions | Private Attributes | Friends
HepMC::Polarization Class Reference

The Polarization class stores theta and phi for a GenParticle. More...

#include <Polarization.h>

List of all members.

Public Member Functions

 Polarization (double theta=0, double phi=0)
 default constructor
 Polarization (const Polarization &inpolar)
 construct from another polarization object
 Polarization (const ThreeVector &vec3in)
 construct using the polar and azimuthal angles from a ThreeVector
virtual ~Polarization ()
void swap (Polarization &other)
 swap
Polarizationoperator= (const Polarization &inpolar)
 make a copy
bool operator== (const Polarization &) const
 equality requires that theta and phi are equal
bool operator!= (const Polarization &) const
 inequality results if either theta or phi differ
void print (std::ostream &ostr=std::cout) const
 print theta and phi
double theta () const
 returns polar angle in radians
double phi () const
 returns azimuthal angle in radians
ThreeVector normal3d () const
 unit 3 vector for easy manipulation
double set_theta (double theta)
 set polar angle in radians
double set_phi (double phi)
 set azimuthal angle in radians
void set_theta_phi (double theta, double phi)
 set both polar and azimuthal angles in radians
ThreeVector set_normal3d (const ThreeVector &vec3in)
 sets polarization according to direction of 3 vec

Private Member Functions

double valid_theta (double theta)
 private method to return a polar angle in the correct range
double valid_phi (double phi)
 private method to return an azimuthal angle in the correct range

Private Attributes

double m_theta
double m_phi

Friends

std::ostream & operator<< (std::ostream &, const Polarization &)
 print polarization information

Detailed Description

The Polarization class stores theta and phi for a GenParticle.

HepMC::Polarization stores a particle's theta and phi in radians. Use of this information is optional. By default, the polarization is set to zero.

Definition at line 29 of file Polarization.h.


Constructor & Destructor Documentation

HepMC::Polarization::Polarization ( double  theta = 0,
double  phi = 0 
)

default constructor

HepMC::Polarization::Polarization ( const Polarization inpolar)

construct from another polarization object

HepMC::Polarization::Polarization ( const ThreeVector vec3in)

construct using the polar and azimuthal angles from a ThreeVector

virtual HepMC::Polarization::~Polarization ( ) [inline, virtual]

Definition at line 41 of file Polarization.h.

{}

Member Function Documentation

void HepMC::Polarization::swap ( Polarization other)

swap

Polarization& HepMC::Polarization::operator= ( const Polarization inpolar)

make a copy

bool HepMC::Polarization::operator== ( const Polarization a) const [inline]

equality requires that theta and phi are equal

Definition at line 93 of file Polarization.h.

    {
        return ( a.theta() == this->theta() && a.phi() == this->phi() );
    }
bool HepMC::Polarization::operator!= ( const Polarization a) const [inline]

inequality results if either theta or phi differ

Definition at line 98 of file Polarization.h.

    {
        return !( a == *this );
    }
void HepMC::Polarization::print ( std::ostream &  ostr = std::cout) const

print theta and phi

double HepMC::Polarization::theta ( ) const [inline]

returns polar angle in radians

Definition at line 86 of file Polarization.h.

{ return m_theta; }
double HepMC::Polarization::phi ( ) const [inline]

returns azimuthal angle in radians

Definition at line 87 of file Polarization.h.

{ return m_phi; }
ThreeVector HepMC::Polarization::normal3d ( ) const

unit 3 vector for easy manipulation

double HepMC::Polarization::set_theta ( double  theta)

set polar angle in radians

double HepMC::Polarization::set_phi ( double  phi)

set azimuthal angle in radians

void HepMC::Polarization::set_theta_phi ( double  theta,
double  phi 
)

set both polar and azimuthal angles in radians

ThreeVector HepMC::Polarization::set_normal3d ( const ThreeVector vec3in)

sets polarization according to direction of 3 vec

double HepMC::Polarization::valid_theta ( double  theta) [private]

private method to return a polar angle in the correct range

double HepMC::Polarization::valid_phi ( double  phi) [private]

private method to return an azimuthal angle in the correct range


Friends And Related Function Documentation

std::ostream& operator<< ( std::ostream &  ,
const Polarization  
) [friend]

print polarization information


Member Data Documentation

double HepMC::Polarization::m_theta [private]

Definition at line 78 of file Polarization.h.

double HepMC::Polarization::m_phi [private]

Definition at line 79 of file Polarization.h.


The documentation for this class was generated from the following file:
| Classes | Job Modules | Data Objects | Services | Algorithms | Tools | Packages | Directories | Tracs |

Generated on Fri May 16 2014 09:49:37 for HepMC by doxygen 1.7.4