CMS 3D CMS Logo

CSCGasCollisions.h
Go to the documentation of this file.
1 #ifndef MU_END_CSC_GAS_COLLISIONS_H
2 #define MU_END_CSC_GAS_COLLISIONS_H
3 
19 
20 #include <string>
21 #include <vector>
22 
23 namespace CLHEP {
24  class HepRandomEngine;
25 }
26 
28 public:
30  virtual ~CSCGasCollisions();
31 
32  void setParticleDataTable(const ParticleDataTable *pdt);
33 
34  void simulate(const PSimHit &,
35  std::vector<LocalPoint> &clusters,
36  std::vector<int> &electrons,
37  CLHEP::HepRandomEngine *);
38 
39  bool dumpGasCollisions(void) const { return dumpGasCollisions_; }
40  bool saveGasCollisions(void) const { return saveGasCollisions_; }
41 
42  static const int N_GAMMA = 21;
43  static const int N_ENERGY = 63;
44  static const int N_ENTRIES = N_GAMMA * N_ENERGY;
45  static const int MAX_STEPS = 400;
46 
47 private:
48  void readCollisionTable();
49  void fillCollisionsForThisGamma(float, std::vector<float> &) const;
50  float lnEnergyLoss(float, const std::vector<float> &) const;
51  double generateStep(double avCollisions, CLHEP::HepRandomEngine *) const;
52  float generateEnergyLoss(double avCollisions,
53  double anmin,
54  double anmax,
55  const std::vector<float> &collisions,
56  CLHEP::HepRandomEngine *) const;
57 
58  void ionize(double energyTransferred, LocalPoint startHere) const;
59 
60  void writeSummary(int n_try, int n_steps, double sum_steps, float dedx, const PSimHit &simhit) const;
61 
62  const std::string me; // class name
63  double gasDensity; // Density of CSC gas mix
64  // The question of what is reasonable for deCut is complex. But it seems clear
65  // that this simulation is not credible if any delta electrons generated here
66  // have ranges more than a few mm, or equivalently, energies above a few keV.
67  // deCut = 1000 = 1 keV
68  // deCut = 10000 = 10 keV
69  double deCut; // Delta electron cutoff in eV (Match GEANT!)
70  double eion; // ionization threshold (eV) (min. E for ionizatiom)
71  double ework; // effective work function (av. energy to create one ion pair)
72  double clusterExtent; // Precision of localization of ion clus. Typically 10
73  // microns.
74 
75  std::vector<float> theGammaBins;
76  std::vector<float> theEnergyBins;
77  std::vector<float> theCollisionTable;
78 
79  CSCCrossGap *theCrossGap; // Owned by CSCGasCollisions
81  bool saveGasCollisions_; // write file of collisions details (not yet
82  // implemented in cmssw)
83  bool dumpGasCollisions_; // flag to write summary
84 };
85 
86 #endif
CSCGasCollisions::theEnergyBins
std::vector< float > theEnergyBins
Definition: CSCGasCollisions.h:76
CSCGasCollisions::~CSCGasCollisions
virtual ~CSCGasCollisions()
Definition: CSCGasCollisions.cc:87
CSCGasCollisions::ionize
void ionize(double energyTransferred, LocalPoint startHere) const
Definition: CSCGasCollisions.cc:320
CSCGasCollisions::MAX_STEPS
static const int MAX_STEPS
Definition: CSCGasCollisions.h:45
CSCGasCollisions::CSCGasCollisions
CSCGasCollisions(const edm::ParameterSet &pset)
Definition: CSCGasCollisions.cc:58
CSCGasCollisions::N_ENTRIES
static const int N_ENTRIES
Definition: CSCGasCollisions.h:44
CSCCrossGap.h
CSCCrossGap
Definition: CSCCrossGap.h:22
CSCGasCollisions::generateStep
double generateStep(double avCollisions, CLHEP::HepRandomEngine *) const
Definition: CSCGasCollisions.cc:278
CSCGasCollisions::readCollisionTable
void readCollisionTable()
Definition: CSCGasCollisions.cc:92
CSCGasCollisions::eion
double eion
Definition: CSCGasCollisions.h:70
CSCGasCollisions::saveGasCollisions
bool saveGasCollisions(void) const
Definition: CSCGasCollisions.h:40
CSCGasCollisions::dumpGasCollisions_
bool dumpGasCollisions_
Definition: CSCGasCollisions.h:83
PSimHit.h
Point3DBase< float, LocalTag >
CSCGasCollisions::gasDensity
double gasDensity
Definition: CSCGasCollisions.h:63
CSCGasCollisions::fillCollisionsForThisGamma
void fillCollisionsForThisGamma(float, std::vector< float > &) const
Definition: CSCGasCollisions.cc:551
CSCGasCollisions::theCrossGap
CSCCrossGap * theCrossGap
Definition: CSCGasCollisions.h:79
CLHEP
Definition: CocoaGlobals.h:27
AlCaHLTBitMon_QueryRunRegistry.string
string
Definition: AlCaHLTBitMon_QueryRunRegistry.py:256
CSCGasCollisions::theCollisionTable
std::vector< float > theCollisionTable
Definition: CSCGasCollisions.h:77
bsc_activity_cfg.clusters
clusters
Definition: bsc_activity_cfg.py:36
CSCGasCollisions::writeSummary
void writeSummary(int n_try, int n_steps, double sum_steps, float dedx, const PSimHit &simhit) const
Definition: CSCGasCollisions.cc:398
CSCGasCollisions::generateEnergyLoss
float generateEnergyLoss(double avCollisions, double anmin, double anmax, const std::vector< float > &collisions, CLHEP::HepRandomEngine *) const
Definition: CSCGasCollisions.cc:294
CSCGasCollisions::ework
double ework
Definition: CSCGasCollisions.h:71
edm::ParameterSet
Definition: ParameterSet.h:36
ParticleDataTable.h
CSCGasCollisions::clusterExtent
double clusterExtent
Definition: CSCGasCollisions.h:72
CSCGasCollisions::dumpGasCollisions
bool dumpGasCollisions(void) const
Definition: CSCGasCollisions.h:39
CSCGasCollisions::simulate
void simulate(const PSimHit &, std::vector< LocalPoint > &clusters, std::vector< int > &electrons, CLHEP::HepRandomEngine *)
Definition: CSCGasCollisions.cc:151
CSCGasCollisions::lnEnergyLoss
float lnEnergyLoss(float, const std::vector< float > &) const
Definition: CSCGasCollisions.cc:520
CSCGasCollisions::N_ENERGY
static const int N_ENERGY
Definition: CSCGasCollisions.h:43
CSCGasCollisions::N_GAMMA
static const int N_GAMMA
Definition: CSCGasCollisions.h:42
CSCGasCollisions::deCut
double deCut
Definition: CSCGasCollisions.h:69
CSCGasCollisions::setParticleDataTable
void setParticleDataTable(const ParticleDataTable *pdt)
Definition: CSCGasCollisions.cc:149
CSCGasCollisions::saveGasCollisions_
bool saveGasCollisions_
Definition: CSCGasCollisions.h:81
pwdgSkimBPark_cfi.electrons
electrons
Definition: pwdgSkimBPark_cfi.py:6
CSCGasCollisions::theGammaBins
std::vector< float > theGammaBins
Definition: CSCGasCollisions.h:75
LocalPoint.h
CSCGasCollisions::me
const std::string me
Definition: CSCGasCollisions.h:62
CSCGasCollisions
Definition: CSCGasCollisions.h:27
ParameterSet.h
PSimHit
Definition: PSimHit.h:15
ParticleDataTable
HepPDT::ParticleDataTable ParticleDataTable
Definition: ParticleDataTable.h:8
CSCGasCollisions::theParticleDataTable
const ParticleDataTable * theParticleDataTable
Definition: CSCGasCollisions.h:80
muonDTDigis_cfi.pset
pset
Definition: muonDTDigis_cfi.py:27