ATLAS Offline Software
Loading...
Searching...
No Matches
TRTDigSettings.h
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2025 CERN for the benefit of the ATLAS collaboration
3*/
4
6// //
7// File: TRTDigSettings.h //
8// //
9// Author: Thomas Kittelmann <kittel@nbi.dk> //
10// //
11// First version: April 2005. Rewritten November 2005. //
12// //
13// Class containing parameters and settings used by //
14// TRT digitization. //
15// //
17
18#ifndef TRT_DIGITIZATION_TRTDIGSETTINGS_H
19#define TRT_DIGITIZATION_TRTDIGSETTINGS_H
20
22
23#include <map>
24#include <string>
25
26class Algorithm;
27class AlgTool;
28namespace InDetDD { class TRT_DetectorManager; }
29
35
36public:
37
40
44 void initialize( const InDetDD::TRT_DetectorManager* detmgr);
45
47 void addPropertiesForOverrideableParameters( Algorithm * alg );
48
50 void addPropertiesForOverrideableParameters( AlgTool * algt );
51
53 void print( const std::string& front = "" ) const;
54
56 void printFlagsForOverrideableParameters( const std::string& front = "" ) const;
57
58 //==============================================================//
59 // Accessor methods //
60 //==============================================================//
61
62 int digVers() const;
63
64 bool useAttenuation() const;
65 double attenuationLength() const;
66
68 double trEfficiencyBarrel(int strawGasType) const;
69
71 double trEfficiencyEndCapA(int strawGasType) const;
72 double trEfficiencyEndCapB(int strawGasType) const;
73
75 double ionisationPotential(int strawGasType) const;
76
78 double smearingFactor(int strawGasType) const;
79
80 //--- Digitization parameters:
81
82 unsigned int digVersion() const;
83 bool useMagneticFieldMap() const;
84
86 double timeInterval() const;
88 unsigned int numberOfBins() const;
90 unsigned int numberOfBinsInEncodingBin() const;
92 double minDiscriminatorWidth() const;
96 double discriminatorDeadTime() const;
97
99 double lowThresholdBar(int strawGasType) const;
100 double lowThresholdEC(int strawGasType) const;
101
103 double highThresholdBarShort(int strawGasType) const;
104 double highThresholdBarLong(int strawGasType) const;
105 double highThresholdECAwheels(int strawGasType) const;
106 double highThresholdECBwheels(int strawGasType) const;
107
109 int htT0shiftBarShort() const;
110 int htT0shiftBarLong() const;
113
115 int ltT0shiftBarShort(int strawGasType) const;
116 int ltT0shiftBarLong(int strawGasType) const;
117 int ltT0shiftECAwheels(int strawGasType) const;
118 int ltT0shiftECBwheels(int strawGasType) const;
119
120 //--- Common straw geometry parameters:
121
123 double innerRadiusOfStraw() const;
124
126 double outerRadiusOfWire() const;
127
129 double lengthOfDeadRegion() const;
130
133 bool timeCorrection() const;
134
137
138 //--- Calculating electronics time shifts:
139
141 double distanceToTimeFactor() const;
143 double maxVertexDisplacement() const;
145 double timeOffsetCalcVertexX() const;
147 double timeOffsetCalcVertexY() const;
149 double timeOffsetCalcVertexZ() const;
154
155 //--- Pile up:
156
158 unsigned int numberOfCrossingsBeforeMain() const;
160 double pileUpSDOsMinEkin() const;//MC Truth saving for pile-up events
161
162 //--- Noise parameters:
163
165 bool noiseInUnhitStraws() const;
167 bool noiseInSimhits() const;
168
169 //--- Composition of electronics noise:
170
177
179 double averageNoiseLevel() const;
180
182 double crossTalkNoiseLevel() const;
184
185 //--- Threshold fluctuations:
186
188 double relativeLowThresholdFluctuation() const; // 0 means no LT fluctuation
190 double relativeHighThresholdFluctuation() const; // 0 means no HT fluctuation
191
192 //--- Field (for effects on drift time):
193
195 double solenoidFieldStrength() const;
196
197 //--- Special runs:
198
200 unsigned int cosmicFlag() const;
202 bool isCTB() const;
204 bool isOverlay() const;
205
206 bool killEndCap() const;
207 bool killBarrel() const;
209 double jitterTimeOffset() const;
211 bool doCosmicTimingPit() const;
212
214 bool doCrosstalk() const;
215
216 unsigned int storeSDO() const;
217
218 bool getT0FromData() const;
219
220 //Delta-ray suppression switch
221 double TrtRangeCutProperty() const;
222
223private:
224 //==============================================================//
225 // Private //
226 //==============================================================//
227
229 void defineVariables();
230
232 void fillDefaults(const InDetDD::TRT_DetectorManager* detmgr);
233
235 void processOverrides();
236
237 //---First a list of data members used for holding the parameters:
239 bool m_getT0FromData = false;
240 unsigned int m_storeSDO = 0U;
241
245 double m_smearingFactor = 0.0;
248
249 double m_timeInterval = 0.0;
250 unsigned int m_numberOfBins = 0U;
251 unsigned int m_numberOfBinsInEncodingBin = 0U;
258
259 double m_lowThresholdBar = 0.0;
260 double m_lowThresholdEC = 0.0;
261
264
267
272
277
282
287
300
301 double m_innerRadiusOfStraw = 0.0;
302 double m_outerRadiusOfWire = 0.0;
303 double m_lengthOfDeadRegion = 0.0;
304
305 bool m_timeCorrection = false;
306
309 double m_pileUpSDOsMinEkin = 0.0;
316
317 double m_trEfficiencyBarrel = 0.0;
326
327 bool m_noiseInUnhitStraws = false;
328 bool m_noiseInSimhits = false;
329
330 bool m_isCTB = false;
331
332 bool m_killEndCap = false;
333 bool m_killBarrel = false;
334 double m_jitterTimeOffset = 0.0;
335 bool m_doCosmicTimingPit = false;
336 bool m_doCrosstalk = false;
337
338 unsigned int m_cosmicFlag = 0U;
339 bool m_isOverlay = false;
340
344 double m_averageNoiseLevel = 0.0;
347
351
352 bool m_useAttenuation = false;
354
356
357 //Now follows infrastructure for handling all the parameters in a robust way:
358
360 void defineNewVariable(const std::string & name,
361 double * datamember,
362 const std::string & description,
363 const std::string & unitname,
364 double unitval,
365 double lowrange,
366 double highrange);
367
369 void defineNewUIntVariable(const std::string & name,
370 unsigned int * datamember,
371 const std::string & description,
372 unsigned int lowrange,
373 unsigned int highrange);
374
376 void defineNewIntVariable(const std::string & name,
377 int * datamember,
378 const std::string & description,
379 int lowrange,
380 int highrange);
381
383 void defineNewBoolVariable(const std::string & name,
384 bool * datamember,
385 const std::string & description);
386
389 std::string description;
391 std::string unitname;
392 double unit{};
393 double okrange_low{};
394 double okrange_high{};
396 };
397
400 std::string description;
401 //Two of these are put to null to indicate type:
403 unsigned int * directvaraddress_uint{};
407 };
408
410 std::map <std::string,doubleparameter> m_doubleparMap;
412 std::map <std::string,intboolparameter> m_intboolparMap;
413
416};
417
418#include "TRTDigSettings.icc"
419
420#endif
AthMessaging(IMessageSvc *msgSvc, const std::string &name)
Constructor.
The Detector Manager for all TRT Detector elements, it acts as the interface to the detector elements...
double m_attenuationLength
double timeOffsetCalcVertexY() const
Get y value of point where particles are assumed to originate.
bool isCTB() const
Query whether CTB (Combined Test Beam 2004) flag is set.
double m_highThresholdECBwheelsKrypton
High threshold discriminator setting Krypton.
double m_trEfficiencyBarrelArgon
Transition Radiation efficiency, barrel, Argon.
double m_relativeHighThresholdFluctuation
Relative high threshold fluctuation.
double m_discriminatorDeadTime
Discriminator dead time.
void defineNewBoolVariable(const std::string &name, bool *datamember, const std::string &description)
Define new bool variable.
int m_ltT0shiftBarShortKr
LT T0 shift.
bool noiseInUnhitStraws() const
Query whether simulation of noise in unhit straws.
double m_trEfficiencyEndCapA
Transition Radiation efficiency, end cap A.
double m_timeOffsetCalcVertexX
x-coord.
double highThresholdBarShort(int strawGasType) const
Get discriminator setting for high threshold.
double ionisationPotential(int strawGasType) const
Get ionisation potential.
int htT0shiftBarLong() const
double outerRadiusOfWire() const
Get radius of signal wire.
bool m_noiseInSimhits
Simulate noise in hit straws.
unsigned int m_numberOfCrossingsBeforeMain
For pileup: BCs before main event.
unsigned int numberOfBins() const
Get number of time bins used for internal shaping of signal.
double slowPeriodicNoisePulseFraction() const
Get slow periodic noise pulse fraction.
unsigned int numberOfCrossingsBeforeMain() const
Get number of simulated bunch crossings before main event (pile up)
double m_slowPeriodicNoisePulseDistance
Slow periodic noise pulse distance (time)
double fastElectronicsNoisePulseDistance() const
Get fast electronics noise pulse distance (time)
double m_timeOffsetCalcVertexY
y-coord.
double timeOffsetCalcVertexX() const
Get x value of point where particles are assumed to originate.
double m_outerRadiusOfWire
Radius of drift wire.
double trEfficiencyEndCapA(int strawGasType) const
Get assumed Transition Radiation efficiency in end caps.
double m_highThresholdECBwheels
High threshold discriminator setting.
double m_trEfficiencyEndCapB
Transition Radiation efficiency, end cap B.
TRTDigSettings()
Parameters and settings for TRT digitization.
void printFlagsForOverrideableParameters(const std::string &front="") const
Print TRT digitization settings overrideable parameters.
double innerRadiusOfStraw() const
Get inner radius of straw.
int m_propertyNotSetMagicNumber_int
double jitterTimeOffset() const
In cosmics, events not correlated with LHC clock.
int ltT0shiftECBwheels(int strawGasType) const
double trEfficiencyEndCapB(int strawGasType) const
double m_trEfficiencyBarrelKrypton
Transition Radiation efficiency, barrel, Krypton.
double relativeLowThresholdFluctuation() const
Get relative low threshold fluctuations (evt to evt & straw to straw)
double highThresholdBarLong(int strawGasType) const
double slowPeriodicNoisePulseDistance() const
Get slow periodic noise pulse distance (time)
void processOverrides()
Overwrite default values by uses values.
double m_distanceToTimeFactor
Fudge factor: time to distance.
bool useAttenuation() const
bool getT0FromData() const
bool doCosmicTimingPit() const
Cosmics timing corresponding to pit setup?
double trEfficiencyBarrel(int strawGasType) const
Get assumed Transition Radiation efficiency in barrel.
void print(const std::string &front="") const
Printing of TRT digitization settings.
unsigned int storeSDO() const
bool timeCorrection() const
Query whether time is corrected for flight and wire propagation delays.
double signalPropagationSpeed() const
Get wire signal propagation speed.
double discriminatorDeadTime() const
Get discriminator dead time.
double m_smearingFactorArgon
Cluster energy smearing factor for Argon mixture.
double lengthOfDeadRegion() const
Get length of dead region at end of straws.
double m_trEfficiencyEndCapAArgon
Transition Radiation efficiency, end cap A, Argon.
bool killBarrel() const
Is barrel killed.
double m_ionisationPotential
Mean ionisation potential.
double timeInterval() const
Get time interval covered by each digit.
double m_highThresholdBarShort
High threshold discriminator setting.
double m_crosstalkNoiseLevel
Average cross talk noise level.
double smearingFactor(int strawGasType) const
Get smearing factor.
int ltT0shiftBarLong(int strawGasType) const
bool m_timeshiftsSymmetricForPhiSectors
Time offset assumed phi symmetric.
double m_timeOffsetCalcVertexZ
z-coord.
void fillDefaults(const InDetDD::TRT_DetectorManager *detmgr)
Fill default values into settable variables.
bool m_isOverlay
Doing overlay.
double highThresholdECAwheels(int strawGasType) const
double m_highThresholdECAwheelsArgon
High threshold discriminator setting Argon.
unsigned int m_storeSDO
Time window in which to store SDOs.
double m_jitterTimeOffset
Event time not correlated with LHC clock.
double lowThresholdEC(int strawGasType) const
double m_highThresholdBarLongKrypton
High threshold discriminator setting Krypton.
double m_slowPeriodicNoisePulseFraction
Slow periodic noise pulse fraction.
double m_highThresholdECAwheelsKrypton
High threshold discriminator setting Krypton.
void addPropertiesForOverrideableParameters(Algorithm *alg)
Add properties for overrideable parameters.
int digVers() const
std::map< std::string, doubleparameter > m_doubleparMap
Map of settable parameters (double)
double m_lowThresholdBarKrypton
Low threshold discriminator setting for Krypton mixture.
bool useMagneticFieldMap() const
bool m_electronicsAreAtFarEnd
Electronics assumed at far end of straw.
bool m_doCrosstalk
Crosstalk noise.
double m_highThresholdECBwheelsArgon
High threshold discriminator setting Argon.
double m_relativeLowThresholdFluctuation
Relative low threshold fluctuation.
double m_lowThresholdBar
Low threshold discriminator setting.
double m_signalPropagationSpeed
Signal propagation time in signal wire.
double m_lowThresholdBarArgon
Low threshold discriminator setting for Argon mixture.
double m_trEfficiencyEndCapBArgon
Transition Radiation efficiency, end cap B, Argon.
double m_highThresholdBarLongArgon
High threshold discriminator setting Argon.
double m_trEfficiencyEndCapBKrypton
Transition Radiation efficiency, end cap B, Krypton.
double m_lowThresholdECKrypton
Low threshold discriminator setting for Krypton mixture.
double m_highThresholdBarLong
High threshold discriminator setting.
double m_maxVertexDisplacement
Max.
double crossTalkNoiseLevel() const
Get average cross talk noise level.
double m_trEfficiencyBarrel
Transition Radiation efficiency, barrel.
double relativeHighThresholdFluctuation() const
Get relative high threshold fluctuations (evt to evt & straw to straw)
int htT0shiftECAwheels() const
double m_averageNoiseLevel
Average noise level.
int m_htT0shiftBarLong
HT T0 shift.
bool isOverlay() const
Get flag used for overlay.
bool m_isCTB
Data is from CTB (Combined Test Beam)
unsigned int m_numberOfBinsInEncodingBin
No.
void defineNewVariable(const std::string &name, double *datamember, const std::string &description, const std::string &unitname, double unitval, double lowrange, double highrange)
Define new double variable.
double m_innerRadiusOfStraw
Inner radius of straw.
bool m_timeCorrection
Corrrect for flight and wire propagation delays.
double m_ionisationPotentialArgon
Mean ionisation potential for Argon mixture.
double m_highThresholdBarShortKrypton
High threshold discriminator setting Krypton.
double m_discriminatorSettlingTime
Discriminator settling time.
double m_smearingFactor
Cluster energy smearing factor.
double m_lowThresholdECArgon
Low threshold discriminator setting for Argon mixture.
double maxVertexDisplacement() const
Get max vertex displacement.
unsigned int m_numberOfBins
No.
double averageNoiseLevel() const
Get average noise level.
unsigned int m_cosmicFlag
Data is cosmics.
double attenuationLength() const
int htT0shiftBarShort() const
T0 shift for HT.
double crossTalkNoiseLevelOtherEnd() const
void defineVariables()
Define settable variables.
double pileUpSDOsMinEkin() const
Get minimum Ekin for pileup track to enter MC-truth.
bool doCrosstalk() const
Switch on crosstalk noise based on Cosmic 08 measurements.
double minDiscriminatorWidth() const
Get the minimum width of discriminator.
double m_lengthOfDeadRegion
Length of dead region at straw end.
std::map< std::string, intboolparameter > m_intboolparMap
Map of settable parameters (int & bool)
bool electronicsAreAtFarEnd() const
Query whether electronics is assumed to be at far end of straw.
bool m_noiseInUnhitStraws
Simulate noise in unhit straws.
double m_trtRangeCutProperty
Electrons xenon range cut in TRT simulation.
int ltT0shiftBarShort(int strawGasType) const
T0 for LT.
double distanceToTimeFactor() const
Get "distanceToTimeFactor" (fugde factor)
double TrtRangeCutProperty() const
int htT0shiftECBwheels() const
double solenoidFieldStrength() const
Get solenoid field strength.
double m_lowThresholdEC
Low threshold discriminator setting.
double m_ionisationPotentialKrypton
Mean ionisation potential for Krypton mixture.
bool m_killBarrel
Disable barrel.
double m_pileUpSDOsMinEkin
Min.
double m_timeInterval
Time interval covered by each digit.
double highThresholdECBwheels(int strawGasType) const
int ltT0shiftECAwheels(int strawGasType) const
double m_propertyNotSetMagicNumber
double m_fastElectronicsNoisePulseDistance
Fast electronics noise pulse distance (time)
void defineNewUIntVariable(const std::string &name, unsigned int *datamember, const std::string &description, unsigned int lowrange, unsigned int highrange)
Define new unsigned int variable.
unsigned int digVersion() const
bool m_killEndCap
Disable end cap.
double timeOffsetCalcVertexZ() const
Get x value of point where particles are assumed to originate.
unsigned int numberOfBinsInEncodingBin() const
Get number of internal time bins corresponding to one low threshold bit.
double m_solenoidFieldStrength
Solenoid field strength.
double m_highThresholdECAwheels
High threshold discriminator setting.
double m_crosstalkNoiseLevelOtherEnd
Average cross talk noise level - other end.
double m_trEfficiencyEndCapAKrypton
Transition Radiation efficiency, end cap A, Krypton.
double m_minDiscriminatorWidth
Min.
double lowThresholdBar(int strawGasType) const
Get discriminator setting for low threshold.
bool m_doCosmicTimingPit
Cosmics pit setup.
void defineNewIntVariable(const std::string &name, int *datamember, const std::string &description, int lowrange, int highrange)
Define new int variable.
double discriminatorSettlingTime() const
Get discriminator settling time.
double m_smearingFactorKrypton
Cluster energy smearing factor for Krypton mixture.
unsigned int cosmicFlag() const
Get flag used for cosmics runs.
double m_highThresholdBarShortArgon
High threshold discriminator setting Argon.
bool noiseInSimhits() const
Query whether simulation of noise in hit straws.
bool killEndCap() const
Is end cap killed.
bool timeshiftsSymmetricForPhiSectors() const
Query whether time offsets are assumed to be symmetric in phi.
std::string description
glabal timer - how long have I taken so far?
Definition hcg.cxx:91
Message Stream Member.
void initialize()
Settable parameter, double.
Settable parameter, int and bool.