ATLAS Offline Software
Loading...
Searching...
No Matches
TRTProcessingOfStraw.h
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2026 CERN for the benefit of the ATLAS collaboration
3*/
4
5#ifndef TRT_DIGITIZATION_TRTPROCESSINGOFSTRAW_H
6#define TRT_DIGITIZATION_TRTPROCESSINGOFSTRAW_H
7
9
10//Hit classes
12//Particle Table
13#include "HepPDT/ParticleDataTable.hh"
14
16
18
20// MagField cache
23
25
27
29
30#include "CLHEP/Random/RandomEngine.h"
32
33#include <memory>
34#include <vector>
35
36class TRTDigit;
38class TRTNoise;
39class TRTDigCondBase;
40
42class ITRT_PAITool;
44
45namespace InDetDD {
48}
49
50class TRTDigSettings;
51
58public:
65 TRTNoise * noise,
66 TRTDigCondBase* digcond,
67 const HepPDT::ParticleDataTable*,
68 const TRT_ID*,
69 ITRT_PAITool* = nullptr,
70 ITRT_PAITool* = nullptr,
71 const ITRT_CalDbTool* = nullptr);
74
77
98 const InDetDD::TRT_DetElementContainer* detElements,
101 TRTDigit& outdigit,
102 bool & m_alreadyPrintedPDGcodeWarning,
103 double m_cosmicEventPhase, //const ComTime* m_ComTime,
104 int strawGasType,
105 bool emulationArflag,
106 bool emulationKrflag,
107 CLHEP::HepRandomEngine* rndmEngine,
108 CLHEP::HepRandomEngine* elecProcRndmEngine,
109 CLHEP::HepRandomEngine* elecNoiseRndmEngine,
110 CLHEP::HepRandomEngine* paiRndmEngine );
111
112private:
113
114 //NB copy-constructor and assignment operator declared, but not defined.
117
119 void Initialize(const ITRT_CalDbTool *);
120
127
129 bool m_timeCorrection = false;
130
133
134 bool m_useAttenuation = false;
136
137 double m_maxCrossingTime = 0.0;
138 double m_minCrossingTime = 0.0;
139 double m_shiftOfZeroPoint = 0.0;
140
143
145
146
151
152 const HepPDT::ParticleDataTable* m_pParticleTable;
153
155 class cluster {
156 public:
157 cluster(double e, double t, double x, double y, double z) :
158 energy(e), time(t), xpos(x), ypos(y), zpos(z) {};
159 double energy;
160 double time;
161 double xpos;
162 double ypos;
163 double zpos;
164 };
165
166 std::vector<cluster> m_clusterlist;
167 std::vector<TRTElectronicsProcessing::Deposit> m_depositList;
168
189 void addClustersFromStep ( const double& scaledKineticEnergy,
190 const double& particleCharge,
191 const double& timeOfHit,
192 const double& prex,
193 const double& prey,
194 const double& prez,
195 const double& postx,
196 const double& posty,
197 const double& postz,
198 std::vector<cluster>& clusterlist,
199 int strawGasType,
200 CLHEP::HepRandomEngine* rndmEngine,
201 CLHEP::HepRandomEngine* paiRndmEngine);
218 void ClustersToDeposits (MagField::AtlasFieldCache& fieldCache, const int& hitID,
219 const std::vector<cluster>& clusters,
220 std::vector<TRTElectronicsProcessing::Deposit>& deposits,
221 Amg::Vector3D TRThitGlobalPos,
222 double m_cosmicEventPhase, // const ComTime* m_ComTime
223 int strawGasType,
224 CLHEP::HepRandomEngine* rndmEngine);
225
226 double setClusterZ(double cluster_z_in, bool isLong, bool isShort, bool isEC) const;
227
228 std::vector<double> m_drifttimes; // electron drift times
229 std::vector<double> m_expattenuation; // tabulation of exp()
230 unsigned int m_maxelectrons = 0U; // maximum number of them (minmum is 100 for the Gaussian approx to be ok);
231
233
235 , const TimedHitPtr<TRTUncompressedHit> *theHit
236 , const InDetDD::TRT_DetElementContainer* detElements);
237
238 std::unique_ptr<CLHEP::RandBinomialFixedP> m_randBinomialXe{};
239 std::unique_ptr<CLHEP::RandBinomialFixedP> m_randBinomialKr{};
240 std::unique_ptr<CLHEP::RandBinomialFixedP> m_randBinomialAr{};
241
242protected:
244
245};
246
247#endif
abstract interface to TRT calibration constants
This is an Identifier helper class for the TRT subdetector.
#define y
#define x
#define z
AthMessaging(IMessageSvc *msgSvc, const std::string &name)
Constructor.
abstract interface to TRT calibration constants
Give and AlgTool interface to the PAI model.
Class to hold different TRT detector elements structures.
The Detector Manager for all TRT Detector elements, it acts as the interface to the detector elements...
Local cache for magnetic field (based on MagFieldServices/AtlasFieldSvcTLS.h)
Communication with CondDB.
Class containing parameters and settings used by TRT digitization.
Class for TRT digits.
Definition TRTDigit.h:11
Simulation of noise hits in the TRT.
Definition TRTNoise.h:39
cluster(double e, double t, double x, double y, double z)
Amg::Vector3D getGlobalPosition(int hitID, const TimedHitPtr< TRTUncompressedHit > *theHit, const InDetDD::TRT_DetElementContainer *detElements)
std::unique_ptr< CLHEP::RandBinomialFixedP > m_randBinomialXe
const HepPDT::ParticleDataTable * m_pParticleTable
TRTProcessingOfStraw(const TRTDigSettings *, const InDetDD::TRT_DetectorManager *, ITRT_PAITool *, ITRT_SimDriftTimeTool *, TRTElectronicsProcessing *ep, TRTNoise *noise, TRTDigCondBase *digcond, const HepPDT::ParticleDataTable *, const TRT_ID *, ITRT_PAITool *=nullptr, ITRT_PAITool *=nullptr, const ITRT_CalDbTool *=nullptr)
Constructor: Calls Initialize method.
TRTDigCondBase * m_pDigConditions
std::unique_ptr< CLHEP::RandBinomialFixedP > m_randBinomialKr
std::vector< cluster > m_clusterlist
TRTProcessingOfStraw(const TRTProcessingOfStraw &)
void ClustersToDeposits(MagField::AtlasFieldCache &fieldCache, const int &hitID, const std::vector< cluster > &clusters, std::vector< TRTElectronicsProcessing::Deposit > &deposits, Amg::Vector3D TRThitGlobalPos, double m_cosmicEventPhase, int strawGasType, CLHEP::HepRandomEngine *rndmEngine)
Transform the ioniation clusters along the particle trajectory inside a straw to energy deposits (i....
std::unique_ptr< CLHEP::RandBinomialFixedP > m_randBinomialAr
TRTElectronicsProcessing * m_pElectronicsProcessing
void addClustersFromStep(const double &scaledKineticEnergy, const double &particleCharge, const double &timeOfHit, const double &prex, const double &prey, const double &prez, const double &postx, const double &posty, const double &postz, std::vector< cluster > &clusterlist, int strawGasType, CLHEP::HepRandomEngine *rndmEngine, CLHEP::HepRandomEngine *paiRndmEngine)
This is the main function for re-simulation of the ionisation in the active gas via the PAI model.
void Initialize(const ITRT_CalDbTool *)
Initialize.
std::vector< TRTElectronicsProcessing::Deposit > m_depositList
std::vector< double > m_expattenuation
bool m_timeCorrection
Time to be corrected for flight and wire propagation delays false when beamType='cosmics'.
TimedHitCollection< TRTUncompressedHit >::const_iterator hitCollConstIter
void ProcessStraw(MagField::AtlasFieldCache &fieldCache, const InDetDD::TRT_DetElementContainer *detElements, hitCollConstIter i, hitCollConstIter e, TRTDigit &outdigit, bool &m_alreadyPrintedPDGcodeWarning, double m_cosmicEventPhase, int strawGasType, bool emulationArflag, bool emulationKrflag, CLHEP::HepRandomEngine *rndmEngine, CLHEP::HepRandomEngine *elecProcRndmEngine, CLHEP::HepRandomEngine *elecNoiseRndmEngine, CLHEP::HepRandomEngine *paiRndmEngine)
Process this straw all the way from Geant4 hit to output digit.
std::vector< double > m_drifttimes
TRTTimeCorrection * m_pTimeCorrection
const TRTDigSettings * m_settings
ITRT_SimDriftTimeTool * m_pSimDriftTimeTool
const InDetDD::TRT_DetectorManager * m_detmgr
double setClusterZ(double cluster_z_in, bool isLong, bool isShort, bool isEC) const
TRTProcessingOfStraw & operator=(const TRTProcessingOfStraw &)
Time correction.
This is an Identifier helper class for the TRT subdetector.
Definition TRT_ID.h:82
TimedVector::const_iterator const_iterator
a smart pointer to a hit that also provides access to the extended timing info of the host event.
Definition TimedHitPtr.h:18
Eigen::Matrix< double, 3, 1 > Vector3D
Message Stream Member.