CMS 3D CMS Logo

List of all members | Public Member Functions | Private Attributes | Friends
MaterialAccountingDetector Class Reference

#include <MaterialAccountingDetector.h>

Public Member Functions

void account (const MaterialAccountingStep &step, double begin, double end)
 
void clear (void)
 
const MaterialAccountingStepmaterial () const
 
 MaterialAccountingDetector (void)
 
const GlobalPointposition () const
 

Private Attributes

MaterialAccountingStep m_accounting
 
double m_cosThetaIn
 
double m_cosThetaOut
 
double m_curvilinearIn
 
double m_curvilinearOut
 
GlobalPoint m_position
 

Friends

class MaterialAccountingTrack
 
class TrackingMaterialAnalyser
 

Detailed Description

Definition at line 15 of file MaterialAccountingDetector.h.

Constructor & Destructor Documentation

MaterialAccountingDetector::MaterialAccountingDetector ( void  )
inline

Member Function Documentation

void MaterialAccountingDetector::account ( const MaterialAccountingStep step,
double  begin,
double  end 
)
inline

Definition at line 37 of file MaterialAccountingDetector.h.

References m_accounting, m_cosThetaIn, m_cosThetaOut, m_curvilinearIn, and m_curvilinearOut.

37  {
38  if (end <= m_curvilinearIn)
39  // step before detector
41  else if (begin >= m_curvilinearOut)
42  // step after detector
44  else
45  // step inside detector
46  m_accounting += (m_cosThetaIn + m_cosThetaOut) / 2. * step;
47  }
#define end
Definition: vmac.h:39
#define begin
Definition: vmac.h:32
step
Definition: StallMonitor.cc:94
void MaterialAccountingDetector::clear ( void  )
inline
const MaterialAccountingStep& MaterialAccountingDetector::material ( void  ) const
inline

Definition at line 33 of file MaterialAccountingDetector.h.

References m_accounting.

Referenced by MaterialAccountingGroup::addDetector().

33 { return m_accounting; }
const GlobalPoint& MaterialAccountingDetector::position ( ) const
inline

Friends And Related Function Documentation

friend class MaterialAccountingTrack
friend

Definition at line 16 of file MaterialAccountingDetector.h.

friend class TrackingMaterialAnalyser
friend

Definition at line 17 of file MaterialAccountingDetector.h.

Member Data Documentation

MaterialAccountingStep MaterialAccountingDetector::m_accounting
private

Definition at line 55 of file MaterialAccountingDetector.h.

Referenced by account(), clear(), and material().

double MaterialAccountingDetector::m_cosThetaIn
private
double MaterialAccountingDetector::m_cosThetaOut
private
double MaterialAccountingDetector::m_curvilinearIn
private
double MaterialAccountingDetector::m_curvilinearOut
private
GlobalPoint MaterialAccountingDetector::m_position
private