All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Public Member Functions | Private Attributes | List of all members
detinfo::DetectorPropertiesData Class Reference

#include <DetectorPropertiesData.h>

Public Member Functions

 DetectorPropertiesData (DetectorProperties const &properties, double x_ticks_coefficient, std::vector< std::vector< std::vector< double >>> &&x_ticks_offsets, std::vector< std::vector< double >> &&drift_direction)
 
double Efield (unsigned int planegap=0) const
 kV/cm More...
 
double DriftVelocity (double efield=0., double temperature=0.) const
 cm/us More...
 
double BirksCorrection (double dQdX) const
 dQ/dX in electrons/cm, returns dE/dX in MeV/cm. More...
 
double BirksCorrection (double dQdX, double EField) const
 
double ModBoxCorrection (double dQdX) const
 
double ModBoxCorrection (double dQdX, double EField) const
 
double ElectronLifetime () const
 
double Density (double temperature=0.) const
 Returns argon density at a given temperature. More...
 
double Temperature () const
 In kelvin. More...
 
double Eloss (double mom, double mass, double tcut) const
 Restricted mean energy loss (dE/dx) More...
 
double ElossVar (double mom, double mass) const
 Energy loss fluctuation ( $ \sigma_{E}^2 / x $) More...
 
double ElectronsToADC () const
 
unsigned int NumberTimeSamples () const
 
unsigned int ReadOutWindowSize () const
 
double TimeOffsetU () const
 
double TimeOffsetV () const
 
double TimeOffsetZ () const
 
double TimeOffsetY () const
 
double ConvertXToTicks (double X, int p, int t, int c) const
 
double ConvertXToTicks (double X, geo::PlaneID const &planeid) const
 
double ConvertTicksToX (double ticks, int p, int t, int c) const
 
double ConvertTicksToX (double ticks, geo::PlaneID const &planeid) const
 
double GetXTicksOffset (int p, int t, int c) const
 
double GetXTicksOffset (geo::PlaneID const &planeid) const
 
double GetXTicksCoefficient (int t, int c) const
 
double GetXTicksCoefficient (geo::TPCID const &tpcid) const
 
double GetXTicksCoefficient () const
 
bool SimpleBoundary () const
 

Private Attributes

detinfo::DetectorProperties const & fProperties
 
double const fXTicksCoefficient
 
std::vector< std::vector
< std::vector< double >
> > const 
fXTicksOffsets
 
std::vector< std::vector
< double > > const 
fDriftDirection
 

Detailed Description

Definition at line 11 of file DetectorPropertiesData.h.

Constructor & Destructor Documentation

detinfo::DetectorPropertiesData::DetectorPropertiesData ( DetectorProperties const &  properties,
double  x_ticks_coefficient,
std::vector< std::vector< std::vector< double >>> &&  x_ticks_offsets,
std::vector< std::vector< double >> &&  drift_direction 
)
explicit

Definition at line 4 of file DetectorPropertiesData.cc.

10  : fProperties{properties}
11  , fXTicksCoefficient{x_ticks_coefficient}
12  , fXTicksOffsets{move(x_ticks_offsets)}
13  , fDriftDirection{move(drift_direction)}
14 {}
std::vector< std::vector< std::vector< double > > > const fXTicksOffsets
detinfo::DetectorProperties const & fProperties
std::vector< std::vector< double > > const fDriftDirection

Member Function Documentation

double detinfo::DetectorPropertiesData::BirksCorrection ( double  dQdX) const

dQ/dX in electrons/cm, returns dE/dX in MeV/cm.

Definition at line 29 of file DetectorPropertiesData.cc.

30 {
31  return fProperties.BirksCorrection(dQdX, Efield());
32 }
virtual double BirksCorrection(double dQdX) const =0
dQ/dX in electrons/cm, returns dE/dX in MeV/cm.
double Efield(unsigned int planegap=0) const
kV/cm
detinfo::DetectorProperties const & fProperties
double detinfo::DetectorPropertiesData::BirksCorrection ( double  dQdX,
double  EField 
) const

Definition at line 34 of file DetectorPropertiesData.cc.

35 {
36  return fProperties.BirksCorrection(dQdX, EField);
37 }
virtual double BirksCorrection(double dQdX) const =0
dQ/dX in electrons/cm, returns dE/dX in MeV/cm.
detinfo::DetectorProperties const & fProperties
double detinfo::DetectorPropertiesData::ConvertTicksToX ( double  ticks,
int  p,
int  t,
int  c 
) const

Definition at line 115 of file DetectorPropertiesData.cc.

119 {
120  return (ticks - fXTicksOffsets.at(c).at(t).at(p)) * fXTicksCoefficient *
121  fDriftDirection.at(c).at(t);
122 }
std::vector< std::vector< std::vector< double > > > const fXTicksOffsets
pdgs p
Definition: selectors.fcl:22
tick ticks
Alias for common language habits.
Definition: electronics.h:78
std::vector< std::vector< double > > const fDriftDirection
double detinfo::DetectorPropertiesData::ConvertTicksToX ( double  ticks,
geo::PlaneID const &  planeid 
) const

Definition at line 125 of file DetectorPropertiesData.cc.

127 {
128  return ConvertTicksToX(ticks, planeid.Plane, planeid.TPC, planeid.Cryostat);
129 }
tick ticks
Alias for common language habits.
Definition: electronics.h:78
double ConvertTicksToX(double ticks, int p, int t, int c) const
double detinfo::DetectorPropertiesData::ConvertXToTicks ( double  X,
int  p,
int  t,
int  c 
) const

Definition at line 99 of file DetectorPropertiesData.cc.

103 {
104  return (X / (fXTicksCoefficient * fDriftDirection.at(c).at(t)) +
105  fXTicksOffsets.at(c).at(t).at(p));
106 }
std::vector< std::vector< std::vector< double > > > const fXTicksOffsets
pdgs p
Definition: selectors.fcl:22
then echo echo For and will not be changed by echo further linking echo echo B echo The symbol is in the uninitialized data multiple common symbols may appear with the echo same name If the symbol is defined the common echo symbols are treated as undefined references For more echo details on common see the discussion of warn common echo in *Note Linker see the discussion of warn common echo in *Note Linker such as a global int variable echo as opposed to a large global array echo echo I echo The symbol is an indirect reference to another symbol This echo is a GNU extension to the a out object file format which is echo rarely used echo echo N echo The symbol is a debugging symbol echo echo R echo The symbol is in a read only data section echo echo S echo The symbol is in an uninitialized data section for small echo objects echo echo T echo The symbol is in the the normal defined echo symbol is used with no error When a weak undefined symbol echo is linked and the symbol is not the value of the echo weak symbol becomes zero with no error echo echo W echo The symbol is a weak symbol that has not been specifically echo tagged as a weak object symbol When a weak defined symbol echo is linked with a normal defined the normal defined echo symbol is used with no error When a weak undefined symbol echo is linked and the symbol is not the value of the echo weak symbol becomes zero with no error echo echo echo The symbol is a stabs symbol in an a out object file In echo this the next values printed are the stabs other echo the stabs desc and the stab type Stabs symbols are echo used to hold debugging information For more echo see *Note or object file format specific echo echo For Mac OS X
std::vector< std::vector< double > > const fDriftDirection
double detinfo::DetectorPropertiesData::ConvertXToTicks ( double  X,
geo::PlaneID const &  planeid 
) const

Definition at line 109 of file DetectorPropertiesData.cc.

110 {
111  return ConvertXToTicks(X, planeid.Plane, planeid.TPC, planeid.Cryostat);
112 }
then echo echo For and will not be changed by echo further linking echo echo B echo The symbol is in the uninitialized data multiple common symbols may appear with the echo same name If the symbol is defined the common echo symbols are treated as undefined references For more echo details on common see the discussion of warn common echo in *Note Linker see the discussion of warn common echo in *Note Linker such as a global int variable echo as opposed to a large global array echo echo I echo The symbol is an indirect reference to another symbol This echo is a GNU extension to the a out object file format which is echo rarely used echo echo N echo The symbol is a debugging symbol echo echo R echo The symbol is in a read only data section echo echo S echo The symbol is in an uninitialized data section for small echo objects echo echo T echo The symbol is in the the normal defined echo symbol is used with no error When a weak undefined symbol echo is linked and the symbol is not the value of the echo weak symbol becomes zero with no error echo echo W echo The symbol is a weak symbol that has not been specifically echo tagged as a weak object symbol When a weak defined symbol echo is linked with a normal defined the normal defined echo symbol is used with no error When a weak undefined symbol echo is linked and the symbol is not the value of the echo weak symbol becomes zero with no error echo echo echo The symbol is a stabs symbol in an a out object file In echo this the next values printed are the stabs other echo the stabs desc and the stab type Stabs symbols are echo used to hold debugging information For more echo see *Note or object file format specific echo echo For Mac OS X
double ConvertXToTicks(double X, int p, int t, int c) const
double detinfo::DetectorPropertiesData::Density ( double  temperature = 0.) const

Returns argon density at a given temperature.

Parameters
temperaturethe temperature in kelvin
Returns
argon density in g/cm^3

Density is nearly a linear function of temperature. See the NIST tables for details Slope is between -6.2 and -6.1, intercept is 1928 kg/m^3. This parameterization will be good to better than 0.5%.g/cm^3

Definition at line 75 of file DetectorPropertiesData.cc.

76 {
77  return fProperties.Density(temperature);
78 }
virtual double Density(double temperature) const =0
Returns argon density at a given temperature.
detinfo::DetectorProperties const & fProperties
double detinfo::DetectorPropertiesData::DriftVelocity ( double  efield = 0.,
double  temperature = 0. 
) const

cm/us

Definition at line 23 of file DetectorPropertiesData.cc.

24 {
25  return fProperties.DriftVelocity(efield, temperature);
26 }
virtual double DriftVelocity(double efield=0., double temperature=0.) const =0
detinfo::DetectorProperties const & fProperties
double detinfo::DetectorPropertiesData::Efield ( unsigned int  planegap = 0) const

kV/cm

Definition at line 17 of file DetectorPropertiesData.cc.

18 {
19  return fProperties.Efield(planegap);
20 }
virtual double Efield(unsigned int planegap=0) const =0
Returns the nominal electric field in the specified volume.
detinfo::DetectorProperties const & fProperties
double detinfo::DetectorPropertiesData::ElectronLifetime ( ) const

Definition at line 69 of file DetectorPropertiesData.cc.

70 {
72 }
virtual double ElectronLifetime() const =0
Returns the attenuation constant for ionization electrons.
detinfo::DetectorProperties const & fProperties
double detinfo::DetectorPropertiesData::ElectronsToADC ( ) const

Definition at line 51 of file DetectorPropertiesData.cc.

52 {
53  return fProperties.ElectronsToADC();
54 }
detinfo::DetectorProperties const & fProperties
virtual double ElectronsToADC() const =0
double detinfo::DetectorPropertiesData::Eloss ( double  mom,
double  mass,
double  tcut 
) const

Restricted mean energy loss (dE/dx)

Parameters
mommomentum of incident particle [GeV/c]
massmass of incident particle [GeV/c^2]
tcutmaximum kinetic energy of delta rays [MeV]; 0 for unlimited
Returns
the restricted mean energy loss (dE/dx) in units of MeV/cm

Returned value is always positive. For unrestricted mean energy loss, set tcut = 0 (special case), or tcut large.

Based on Bethe-Bloch formula as contained in particle data book. Material parameters are from the configuration.

Definition at line 87 of file DetectorPropertiesData.cc.

88 {
89  return fProperties.Eloss(mom, mass, tcut);
90 }
virtual double Eloss(double mom, double mass, double tcut) const =0
Restricted mean energy loss ( )
detinfo::DetectorProperties const & fProperties
float mass
Definition: dedx.py:47
double detinfo::DetectorPropertiesData::ElossVar ( double  mom,
double  mass 
) const

Energy loss fluctuation ( $ \sigma_{E}^2 / x $)

Parameters
mommomentum of incident particle in [GeV/c]
massmass of incident particle [GeV/c^2]
Returns
energy loss fluctuation in MeV^2/cm

Based on Bichsel formula referred to but not given in PDG.

Definition at line 93 of file DetectorPropertiesData.cc.

94 {
95  return fProperties.ElossVar(mom, mass);
96 }
detinfo::DetectorProperties const & fProperties
virtual double ElossVar(double mom, double mass) const =0
Energy loss fluctuation ( )
float mass
Definition: dedx.py:47
double detinfo::DetectorPropertiesData::GetXTicksCoefficient ( int  t,
int  c 
) const

Definition at line 160 of file DetectorPropertiesData.cc.

161 {
162  return fXTicksCoefficient * fDriftDirection.at(c).at(t);
163 }
std::vector< std::vector< double > > const fDriftDirection
double detinfo::DetectorPropertiesData::GetXTicksCoefficient ( geo::TPCID const &  tpcid) const
double detinfo::DetectorPropertiesData::GetXTicksCoefficient ( ) const

Definition at line 166 of file DetectorPropertiesData.cc.

167 {
168  return fXTicksCoefficient;
169 }
double detinfo::DetectorPropertiesData::GetXTicksOffset ( int  p,
int  t,
int  c 
) const

Definition at line 148 of file DetectorPropertiesData.cc.

149 {
150  return fXTicksOffsets.at(c).at(t).at(p);
151 }
std::vector< std::vector< std::vector< double > > > const fXTicksOffsets
pdgs p
Definition: selectors.fcl:22
double detinfo::DetectorPropertiesData::GetXTicksOffset ( geo::PlaneID const &  planeid) const

Definition at line 154 of file DetectorPropertiesData.cc.

155 {
156  return GetXTicksOffset(planeid.Plane, planeid.TPC, planeid.Cryostat);
157 }
double GetXTicksOffset(int p, int t, int c) const
double detinfo::DetectorPropertiesData::ModBoxCorrection ( double  dQdX) const

Definition at line 40 of file DetectorPropertiesData.cc.

41 {
42  return fProperties.ModBoxCorrection(dQdX, Efield());
43 }
virtual double ModBoxCorrection(double dQdX) const =0
double Efield(unsigned int planegap=0) const
kV/cm
detinfo::DetectorProperties const & fProperties
double detinfo::DetectorPropertiesData::ModBoxCorrection ( double  dQdX,
double  EField 
) const

Definition at line 45 of file DetectorPropertiesData.cc.

46 {
47  return fProperties.ModBoxCorrection(dQdX, EField);
48 }
virtual double ModBoxCorrection(double dQdX) const =0
detinfo::DetectorProperties const & fProperties
unsigned int detinfo::DetectorPropertiesData::NumberTimeSamples ( ) const

Definition at line 57 of file DetectorPropertiesData.cc.

58 {
60 }
virtual unsigned int NumberTimeSamples() const =0
detinfo::DetectorProperties const & fProperties
unsigned int detinfo::DetectorPropertiesData::ReadOutWindowSize ( ) const

Definition at line 63 of file DetectorPropertiesData.cc.

64 {
66 }
detinfo::DetectorProperties const & fProperties
virtual unsigned int ReadOutWindowSize() const =0
bool detinfo::DetectorPropertiesData::SimpleBoundary ( ) const

Definition at line 172 of file DetectorPropertiesData.cc.

173 {
174  return fProperties.SimpleBoundary();
175 }
virtual bool SimpleBoundary() const =0
detinfo::DetectorProperties const & fProperties
double detinfo::DetectorPropertiesData::Temperature ( ) const

In kelvin.

Definition at line 81 of file DetectorPropertiesData.cc.

82 {
83  return fProperties.Temperature();
84 }
virtual double Temperature() const =0
detinfo::DetectorProperties const & fProperties
double detinfo::DetectorPropertiesData::TimeOffsetU ( ) const

Definition at line 132 of file DetectorPropertiesData.cc.

133 {
134  return fProperties.TimeOffsetU();
135 }
virtual double TimeOffsetU() const =0
detinfo::DetectorProperties const & fProperties
double detinfo::DetectorPropertiesData::TimeOffsetV ( ) const

Definition at line 137 of file DetectorPropertiesData.cc.

138 {
139  return fProperties.TimeOffsetV();
140 }
virtual double TimeOffsetV() const =0
detinfo::DetectorProperties const & fProperties
double detinfo::DetectorPropertiesData::TimeOffsetY ( ) const
double detinfo::DetectorPropertiesData::TimeOffsetZ ( ) const

Definition at line 142 of file DetectorPropertiesData.cc.

143 {
144  return fProperties.TimeOffsetZ();
145 }
virtual double TimeOffsetZ() const =0
detinfo::DetectorProperties const & fProperties

Member Data Documentation

std::vector<std::vector<double> > const detinfo::DetectorPropertiesData::fDriftDirection
private

Definition at line 99 of file DetectorPropertiesData.h.

detinfo::DetectorProperties const& detinfo::DetectorPropertiesData::fProperties
private

Definition at line 96 of file DetectorPropertiesData.h.

double const detinfo::DetectorPropertiesData::fXTicksCoefficient
private

Definition at line 97 of file DetectorPropertiesData.h.

std::vector<std::vector<std::vector<double> > > const detinfo::DetectorPropertiesData::fXTicksOffsets
private

Definition at line 98 of file DetectorPropertiesData.h.


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