Loading [MathJax]/extensions/tex2jax.js
ATLAS Offline Software
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Modules Pages
FastCaloSim.cxx
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration
3 */
4 
5 // Header include
6 #include "FastCaloSim.h"
7 
8 // FastCaloSim includes
12 
13 // Random generator includes
15 
16 // Geant4 particle includes
17 #include "G4Gamma.hh"
18 #include "G4Electron.hh"
19 #include "G4Positron.hh"
20 #include "G4PionPlus.hh"
21 #include "G4PionMinus.hh"
22 
23 //Geant4
24 #include "G4ParticleTable.hh"
25 
26 // CLHEP
27 #include "CLHEP/Random/RandFlat.h"
28 
29 // HepMCHelpers include
31 
32 // G4 sensitive detector includes
33 #include "G4SDManager.hh"
35 
36 #undef FCS_DEBUG
37 
38 FastCaloSim::FastCaloSim(const std::string& name,
39  const ServiceHandle<IAthRNGSvc>& rndmGenSvc,
40  const Gaudi::Property<std::string>& randomEngineName,
41  const PublicToolHandle<IFastCaloSimCaloTransportation>& FastCaloSimCaloTransportation,
42  const PublicToolHandle<IFastCaloSimCaloExtrapolation>& FastCaloSimCaloExtrapolation,
43  const PublicToolHandle<IG4CaloTransportTool>& G4CaloTransportTool,
44  const PublicToolHandle<IPunchThroughSimWrapper>& PunchThroughSimWrapper,
45  const ServiceHandle<ISF::IFastCaloSimParamSvc>& FastCaloSimSvc,
46  const Gaudi::Property<std::string>& CaloCellContainerSDName,
47  const Gaudi::Property<bool>& doG4Transport,
48  const Gaudi::Property<bool>& doPhotons,
49  const Gaudi::Property<bool>& doElectrons,
50  const Gaudi::Property<bool>& doHadrons,
51  const Gaudi::Property<float>& AbsEtaMin,
52  const Gaudi::Property<float>& AbsEtaMax,
53  const Gaudi::Property<float>& EkinMinPhotons,
54  const Gaudi::Property<float>& EkinMaxPhotons,
55  const Gaudi::Property<float>& EkinMinElectrons,
56  const Gaudi::Property<float>& EkinMaxElectrons,
57  const Gaudi::Property<bool>& doEMECFCS,
58  const Gaudi::Property<bool>& doPunchThrough,
60 
61 : G4VFastSimulationModel(name),
62  m_rndmGenSvc(rndmGenSvc), m_randomEngineName(randomEngineName),
63  m_FastCaloSimCaloTransportation(FastCaloSimCaloTransportation),
64  m_FastCaloSimCaloExtrapolation(FastCaloSimCaloExtrapolation),
65  m_G4CaloTransportTool(G4CaloTransportTool),
66  m_PunchThroughSimWrapper(PunchThroughSimWrapper),
67  m_FastCaloSimSvc(FastCaloSimSvc),
68  m_CaloCellContainerSDName(CaloCellContainerSDName),
69  m_doG4Transport(doG4Transport),
70  m_doPhotons(doPhotons),
71  m_doElectrons(doElectrons),
72  m_doHadrons(doHadrons),
73  m_AbsEtaMin(AbsEtaMin),
74  m_AbsEtaMax(AbsEtaMax),
75  m_EkinMinPhotons(EkinMinPhotons),
76  m_EkinMaxPhotons(EkinMaxPhotons),
77  m_EkinMinElectrons(EkinMinElectrons),
78  m_EkinMaxElectrons(EkinMaxElectrons),
79  m_doEMECFCS(doEMECFCS),
80  m_doPunchThrough(doPunchThrough),
81  m_FastCaloSimTool(FastCaloSimTool)
82 {
83 
84 }
85 
86 void FastCaloSim::StartOfAthenaEvent(const EventContext& ctx ){
87 
90 
91  return;
92 }
93 
94 void FastCaloSim::EndOfAthenaEvent(const EventContext&){
95 
96  return;
97 }
98 
99 
100 G4bool FastCaloSim::IsApplicable(const G4ParticleDefinition& particleType)
101 {
102  // Check whether we can simulate the particle with FastCaloSim
103  bool isPhoton = &particleType == G4Gamma::GammaDefinition();
104  bool isElectron = &particleType == G4Electron::ElectronDefinition();
105  bool isPositron = &particleType == G4Positron::PositronDefinition();
106  bool isHadron = MC::isHadron(particleType.GetPDGEncoding());
107 
108  // FastCaloSim is applicable if it is photon, electron, positron or any hadron
109  bool isApplicable = (isPhoton && m_doPhotons) || (isElectron && m_doElectrons) || (isPositron && m_doElectrons) || (isHadron && m_doHadrons);
110 
111  #ifdef FCS_DEBUG
112  const std::string pName = particleType.GetParticleName();
113  G4cout<< "[FastCaloSim::IsApplicable] Got " << pName <<G4endl;
114  if(isApplicable) G4cout<<"[FastCaloSim::IsApplicable] APPLICABLE"<<G4endl;
115  else G4cout<<"[FastCaloSim::IsApplicable] NOT APPLICABLE"<<G4endl;
116  #endif
117 
118 
119  return isApplicable;
120 }
121 
122 G4bool FastCaloSim::ModelTrigger(const G4FastTrack& fastTrack)
123 {
124 
125  #ifdef FCS_DEBUG
126  G4cout<<"[FastCaloSim::ModelTrigger] Got particle with " <<"\n"
127  <<" pdg=" <<fastTrack.GetPrimaryTrack() -> GetDefinition()->GetPDGEncoding() <<"\n"
128  <<" Ekin="<<fastTrack.GetPrimaryTrack() -> GetKineticEnergy() <<"\n"
129  <<" p=" <<fastTrack.GetPrimaryTrack() -> GetMomentum().mag() <<"\n"
130  <<" x=" <<fastTrack.GetPrimaryTrack() -> GetPosition().x() <<"\n"
131  <<" y=" <<fastTrack.GetPrimaryTrack() -> GetPosition().y() <<"\n"
132  <<" z=" <<fastTrack.GetPrimaryTrack() -> GetPosition().z() <<"\n"
133  <<" r=" <<fastTrack.GetPrimaryTrack() -> GetPosition().perp() <<"\n"
134  <<" eta=" <<fastTrack.GetPrimaryTrack() -> GetMomentum().eta() <<"\n"
135  <<" phi=" <<fastTrack.GetPrimaryTrack() -> GetMomentum().phi() <<"\n"
136  <<G4endl;
137  #endif
138 
139  // Get particle definition
140  const G4ParticleDefinition * G4Particle = fastTrack.GetPrimaryTrack() -> GetDefinition();
141  // Get particle kinetic energy
142  const float Ekin = fastTrack.GetPrimaryTrack() -> GetKineticEnergy();
143  // Get particle position eta
144  const float eta_pos = (fastTrack.GetPrimaryTrack() -> GetPosition()).eta();
145 
146  // Check particle type
147  bool isPhoton = G4Particle == G4Gamma::Definition();
148  bool isElectron = G4Particle == G4Electron::Definition();
149  bool isPositron = G4Particle == G4Positron::Definition();
150  bool isPionPlus = G4Particle == G4PionPlus::Definition();
151  bool isPionMinus = G4Particle == G4PionMinus::Definition();
152 
153 
154  // Check if there is a configuration for this PID
155  bool withinEtaRange = (std::abs(eta_pos) > m_AbsEtaMin) && (std::abs(eta_pos) < m_AbsEtaMax);
156  bool withinEkinRangePhotons = isPhoton && (Ekin > m_EkinMinPhotons) && (Ekin < m_EkinMaxPhotons);
157  bool withinEkinRangeElectrons = (isElectron || isPositron) && (Ekin > m_EkinMinElectrons) && (Ekin < m_EkinMaxElectrons);
158 
159 
160  if (!(withinEtaRange && (withinEkinRangePhotons || withinEkinRangeElectrons))) {
161  #ifdef FCS_DEBUG
162  G4cout<<"[FastCaloSim::ModelTrigger] Model not triggered"<<G4endl;
163  #endif
164  return false;
165  }
166 
167  // Simulate particles below 50 keV with Geant4 to have same config as ISF implementation
168  if (fastTrack.GetPrimaryTrack() -> GetKineticEnergy() < 0.05) {
169  #ifdef FCS_DEBUG
170  G4cout<<"[FastCaloSim::ModelTrigger] Particle below 50 keV threshold. Passing to G4. "<<G4endl;
171  #endif
172  return false;
173  }
174 
175  // Check if triggered particle is really on the ID-Calo (parametrization) boundary
176  if (!passedIDCaloBoundary(fastTrack)) {
177  #ifdef FCS_DEBUG
178  G4cout<<"[FastCaloSim::ModelTrigger] Particle failed passedIDCaloBoundary z="<<fastTrack.GetPrimaryTrack() -> GetPosition().z()<<" r="<<fastTrack.GetPrimaryTrack() -> GetPosition().perp()<<G4endl;
179  #endif
180  return false;
181  }
182 
183  // Set minimum kinetic energy of pions and other hadrons required to be passed to FastCaloSim
184  float minEkinPions = 200;
185  float minEkinOtherHadrons = 400;
186 
187  // Pass all photons, electrons and positrons to FastCaloSim
188  if (isPhoton || isElectron || isPositron){
189  #ifdef FCS_DEBUG
190  G4cout<<"[FastCaloSim::ModelTrigger] Model triggered"<<G4endl;
191  #endif
192  return true;
193  }
194 
195  // Require minimum kinetic energy of pions needed to be passed to FastCaloSim
196  if (isPionPlus || isPionMinus){
197  bool passMinEkinPions = Ekin > minEkinPions;
198 
199  #ifdef FCS_DEBUG
200  if(passMinEkinPions) G4cout<<"[FastCaloSim::ModelTrigger] Model triggered"<<G4endl;
201  else G4cout<<"[FastCaloSim::ModelTrigger] Pion with Ekin="<<Ekin<<" below the minimum "<<minEkinPions<<" MeV threshold. Model not triggered."<<G4endl;
202  #endif
203 
204  return passMinEkinPions;
205 
206  }
207 
208  // Require minimum kinetic energy of other hadrons needed to be passed to FastCaloSim
209  bool passMinEkinOtherHadrons = Ekin > minEkinOtherHadrons;
210 
211  #ifdef FCS_DEBUG
212  if(passMinEkinOtherHadrons) G4cout<<"[FastCaloSim::ModelTrigger] Model triggered"<<G4endl;
213  else G4cout<<"[FastCaloSim::ModelTrigger] Other hadron with Ekin="<<Ekin<<" below the minimum "<<minEkinOtherHadrons<<" MeV threshold. Model not triggered."<<G4endl;
214  #endif
215 
216  return passMinEkinOtherHadrons;
217 }
218 
219 void FastCaloSim::DoIt(const G4FastTrack& fastTrack, G4FastStep& fastStep)
220 {
221 
223  TFCSTruthState truthState;
224  TFCSExtrapolationState extrapolState;
225 
226  // Get Geant4 primary track
227  const G4Track * G4PrimaryTrack = fastTrack.GetPrimaryTrack();
228  // Get Geant4 particle definition
229  const G4ParticleDefinition * G4Particle = G4PrimaryTrack -> GetDefinition();
230  // Get Geant4 particle pdgID
231  signed int pdgID = G4Particle -> GetPDGEncoding();
232 
233  // Do not simulate particles below 10 MeV
234  if(G4PrimaryTrack -> GetKineticEnergy() < 10){
235  #ifdef FCS_DEBUG
236  G4cout<<"[FastCaloSim::DoIt] Skipping particle with Ekin: " << G4PrimaryTrack -> GetKineticEnergy() <<" MeV. Below the 10 MeV threshold"<<G4endl;
237  #endif
238  fastStep.KillPrimaryTrack();
239  return;
240  }
241  // Decide on which FastCaloSim parametrization to use (electron, photon or pion)
242  if(G4Particle == G4Electron::Definition() || G4Particle == G4Positron::Definition() || G4Particle == G4Gamma::Definition())
243  {
244  // Use egamma parametrization for simulation of electrons and photons
245  truthState.set_pdgid(pdgID);
246  }
247  else{
248  // Use pion parametrization for simulation of all hadrons
249  truthState.set_pdgid(G4PionPlus::Definition() -> GetPDGEncoding());
250  }
251 
252  // Set the kinematics of the FastCaloSim truth state
253  truthState.SetPtEtaPhiM(G4PrimaryTrack -> GetMomentum().perp(),
254  G4PrimaryTrack -> GetMomentum().eta(),
255  G4PrimaryTrack -> GetMomentum().phi(),
256  G4Particle -> GetPDGMass());
257 
258  // Set the vertex of the FastCaloSim truth state
259  truthState.set_vertex(G4PrimaryTrack -> GetPosition().x(),
260  G4PrimaryTrack -> GetPosition().y(),
261  G4PrimaryTrack -> GetPosition().z());
262 
263 
264  /* For anti protons and anti-neutrons the kinetic energy should be
265  calculated as Ekin = E() + M() instead of E() - M() this is
266  achieved by setting an Ekin offset of 2*M() to the truth state */
267  if(pdgID == -2212 || pdgID == -2112) truthState.set_Ekin_off(2 * G4Particle -> GetPDGMass());
268 
269 
270  // Perform particle transportation through calorimeter system eiher with ATLAS tracking tools or with Geant4
271  std::vector<G4FieldTrack> caloSteps = m_doG4Transport ? m_G4CaloTransportTool -> transport(*G4PrimaryTrack)
272  : m_FastCaloSimCaloTransportation -> transport(&truthState, false);
273 
274  // Extrapolate transported stepos to ID-Calo boundary and all layers of the calorimeter system
275  m_FastCaloSimCaloExtrapolation->extrapolate(extrapolState, &truthState, caloSteps);
276 
277  // Do not simulate further if extrapolation to ID - Calo boundary fails
278  if(extrapolState.IDCaloBoundary_eta() == -999){
279  #ifdef FCS_DEBUG
280  G4cout<<"[FastCaloSim::DoIt] Killing particle as extrapolation failed"<<G4endl;
281  #endif
282  fastStep.KillPrimaryTrack();
283  return;
284  }
285  // Perform the actual FastCaloSim simulation
286  if(m_FastCaloSimSvc->simulate(simState, &truthState, &extrapolState).isFailure()){
287  G4Exception("FastCaloSimSvc", "FailedSimulationCall", FatalException, "FastCaloSimSvc: Simulation call failed.");
288  abort();
289  }
290 
291  #ifdef FCS_DEBUG
292  G4cout<<"[FastCaloSim::DoIt] pdgID of G4PrimaryTrack: " << pdgID << G4endl;
293  G4cout<<"[FastCaloSim::DoIt] Energy returned: " << simState.E() << G4endl;
294  G4cout<<"[FastCaloSim::DoIt] Energy fraction for layer: " << G4endl;
295  for (int s = 0; s < 24; s++) G4cout<<"[FastCaloSim::DoIt] Sampling " << s << " energy " << simState.E(s) << G4endl;
296  #endif
297 
298  // Retrieve the associated CaloCellContainer sensitive detector
299  CaloCellContainerSD * caloCellContainerSD = getCaloCellContainerSD();
300  // Record the cells
301  caloCellContainerSD->recordCells(simState);
302 
303  // Do punchthrough here (secondaries), after the main simulation
304  if (m_doPunchThrough){
305  // necessary for determining particle type and properties (mass etc)
306  G4ParticleTable *ptable = G4ParticleTable::GetParticleTable();
307 
308  // Get simulated energy
309  const double simE = simState.E();
310 
311  // Get energy fraction in layers into vector
312  std::vector<double> simEfrac;
313  for (unsigned int i = 0; i < 24; i++){simEfrac.push_back(simState.Efrac(i));}
314 
315  // run actual method (no return, it will do fastStep.CreateSecondaryTrack(...) under the hood)
316  m_PunchThroughSimWrapper->DoPunchThroughSim(*ptable, m_rngWrapper, simE, simEfrac, fastTrack, fastStep);
317  }
318 
319  // Clean up the auxiliary info from the simulation state
320  simState.DoAuxInfoCleanup();
321 
322  // Finally kill the primary track after all simulation steps done
323  fastStep.KillPrimaryTrack();
324  fastStep.SetPrimaryTrackPathLength(0.0);
325 }
326 
328 
329  G4SDManager *sdm = G4SDManager::GetSDMpointer();
330  G4VSensitiveDetector * vsd = sdm->FindSensitiveDetector((G4String)m_CaloCellContainerSDName);
331 
332  if (!vsd){
333  G4Exception("FastCaloSimSvc", "FailedFindSensitiveDetector", FatalException, "FastCaloSimSvc: Failed getting CaloCellContainer SD.");
334  abort();
335  }
336  // Cast G4VSensitiveDetector to CaloCellContainerSD
337  CaloCellContainerSD * caloCellContainerSD = dynamic_cast<CaloCellContainerSD*>(vsd);
338 
339  if (!caloCellContainerSD){
340  G4Exception("FastCaloSimSvc", "FailedCastSensitiveDetector", FatalException, "FastCaloSimSvc: Failed casting G4VSensitiveDetector.");
341  abort();
342  }
343  return caloCellContainerSD;
344 }
345 
346 
347 G4bool FastCaloSim::passedIDCaloBoundary(const G4FastTrack& fastTrack){
348 
349 
350  /* Method checks if particle has crossed the ID-Calo boundary, defined using three cylinders with pairs of r/z values
351  We also perform a directional check to make sure that the particle does not originate from any backscatter from the MS or CALO */
352 
353  // NOTE:
354  // For the inner beam pipe section, innerBeamPipeZ = 4185 corresponds to original AFII boundary, while
355  // innerBeamPipeZ = 4587 corresponds to the CALO::CALO boundary which should be used instead as there
356  // is no triggering volume at this point and we will trigger slightly later than the AFII boundary, so
357  // passedIDCaloBoundary would fail and we would simulate this part with Geant4
358 
359  // Barrel
360  const float barrelR = 1148;
361  const float barrelZ = 3549.5;
362  // Inner beam pipe section
363  const float innerBeamPipeR = 120;
364  const float innerBeamPipeZ = 4587;
365  // Outer beam pipe section
366  const float outerBeamPipeR = 41;
367  const float outerBeamPipeZ = 6783;
368 
369  // Get particle position
370  const G4ThreeVector particlePosition = fastTrack.GetPrimaryTrack() -> GetPosition();
371  // Get r and z values of position
372  const float r = particlePosition.perp();
373  const float z = particlePosition.z();
374  // Get direction of particle
375  const G4ThreeVector particleDirection = fastTrack.GetPrimaryTrack() -> GetMomentum();
376  // Construct the helper line to decide if particle comes from ID or is backscatter from CALO
377  const G4ThreeVector helperLine = particlePosition + particleDirection;
378 
379  // Set 5cm trigger tolerance, i.e. the 'width' of the trigger boundary
380  // be careful not to set this too low, else Geant4 might overjump your trigger boundary and simulate everything with G4
381  const float triggerTolerance = 50;
382 
383  // Barrel boundary (horizontal surfaces)
384  if (std::abs(z) <= barrelZ + triggerTolerance) {
385  if (r >= barrelR && r < barrelR + triggerTolerance) return helperLine.perp() >= barrelR;
386  }
387  // Beam pipe boundary (horizontal surfaces)
388  if (std::abs(z) >= barrelZ && std::abs(z) <= innerBeamPipeZ + triggerTolerance){
389  if (r >= innerBeamPipeR && r < innerBeamPipeR + triggerTolerance) return helperLine.perp() >= innerBeamPipeR;
390  }
391  if (std::abs(z) >= innerBeamPipeZ && std::abs(z) <= outerBeamPipeZ){
392  if (r >= outerBeamPipeR && r < outerBeamPipeR + triggerTolerance) return helperLine.perp() >= outerBeamPipeR;
393  }
394  // Barrel boundary (vertical surfaces)
395  if (r >= outerBeamPipeR && r<= innerBeamPipeR){
396  if (std::abs(z) >= innerBeamPipeZ && std::abs(z) < innerBeamPipeZ + triggerTolerance) return std::abs(helperLine.z()) >= innerBeamPipeZ;
397  }
398  // Beam pipe boundary (vertical surfaces)
399  if (r >= innerBeamPipeR && r <= barrelR){
400  if (std::abs(z) >= barrelZ && std::abs(z) < barrelZ + triggerTolerance) return std::abs(helperLine.z()) >= barrelZ;
401  }
402 
403  return false;
404 
405 }
406 
FastCaloSimCaloExtrapolation
Definition: FastCaloSimCaloExtrapolation.h:32
ATHRNG::RNGWrapper::setSeed
void setSeed(const std::string &algName, const EventContext &ctx)
Set the random seed using a string (e.g.
Definition: RNGWrapper.h:169
CaloCellContainerSD.h
beamspotman.r
def r
Definition: beamspotman.py:676
FastCaloSim::m_EkinMinPhotons
Gaudi::Property< float > m_EkinMinPhotons
Definition: FastCaloSim.h:106
python.SystemOfUnits.s
int s
Definition: SystemOfUnits.py:131
TFCSSimulationState::DoAuxInfoCleanup
void DoAuxInfoCleanup()
Definition: TFCSSimulationState.cxx:79
phi
Scalar phi() const
phi method
Definition: AmgMatrixBasePlugin.h:67
FastCaloSim::StartOfAthenaEvent
void StartOfAthenaEvent(const EventContext &ctx)
Definition: FastCaloSim.cxx:86
perp
Scalar perp() const
perp method - perpenticular length
Definition: AmgMatrixBasePlugin.h:44
TFCSTruthState::set_Ekin_off
void set_Ekin_off(double val)
Definition: TFCSTruthState.h:23
eta
Scalar eta() const
pseudorapidity method
Definition: AmgMatrixBasePlugin.h:83
CaloCellContainerSD::recordCells
void recordCells(TFCSSimulationState &)
Definition: CaloCellContainerSD.cxx:65
FastCaloSim::m_FastCaloSimTool
FastCaloSimTool * m_FastCaloSimTool
Definition: FastCaloSim.h:116
TFCSSimulationState::Efrac
double Efrac(int sample) const
Definition: TFCSSimulationState.h:44
FastCaloSim::m_FastCaloSimSvc
ServiceHandle< ISF::IFastCaloSimParamSvc > m_FastCaloSimSvc
Definition: FastCaloSim.h:94
FastCaloSim::m_doElectrons
Gaudi::Property< bool > m_doElectrons
Definition: FastCaloSim.h:102
TFCSExtrapolationState
Definition: TFCSExtrapolationState.h:13
FastCaloSim::m_AbsEtaMin
Gaudi::Property< float > m_AbsEtaMin
Definition: FastCaloSim.h:104
x
#define x
particleType
Definition: particleType.h:29
FastCaloSim::m_AbsEtaMax
Gaudi::Property< float > m_AbsEtaMax
Definition: FastCaloSim.h:105
CaloCellContainerSD
Definition: CaloCellContainerSD.h:22
FastCaloSim::getCaloCellContainerSD
CaloCellContainerSD * getCaloCellContainerSD()
Retrieves the associated sensitive detector responsible for writing out the CaloCellContainer.
Definition: FastCaloSim.cxx:327
FastCaloSim::m_FastCaloSimCaloTransportation
PublicToolHandle< IFastCaloSimCaloTransportation > m_FastCaloSimCaloTransportation
Definition: FastCaloSim.h:85
FastCaloSim::m_doPhotons
Gaudi::Property< bool > m_doPhotons
Definition: FastCaloSim.h:101
FastCaloSim.h
FastCaloSim::m_randomEngineName
Gaudi::Property< std::string > m_randomEngineName
Definition: FastCaloSim.h:81
FastCaloSim::m_EkinMaxElectrons
Gaudi::Property< float > m_EkinMaxElectrons
Definition: FastCaloSim.h:109
lumiFormat.i
int i
Definition: lumiFormat.py:85
z
#define z
xAOD::EgammaHelpers::isElectron
bool isElectron(const xAOD::Egamma *eg)
is the object an electron (not Fwd)
Definition: EgammaxAODHelpers.cxx:12
FastCaloSim::EndOfAthenaEvent
void EndOfAthenaEvent(const EventContext &ctx)
Definition: FastCaloSim.cxx:94
FastCaloSim::m_doHadrons
Gaudi::Property< bool > m_doHadrons
Definition: FastCaloSim.h:103
TFCSExtrapolationState::IDCaloBoundary_eta
double IDCaloBoundary_eta() const
Definition: TFCSExtrapolationState.h:63
FastCaloSim::m_PunchThroughSimWrapper
PublicToolHandle< IPunchThroughSimWrapper > m_PunchThroughSimWrapper
Definition: FastCaloSim.h:91
FastCaloSim::m_FastCaloSimCaloExtrapolation
PublicToolHandle< IFastCaloSimCaloExtrapolation > m_FastCaloSimCaloExtrapolation
Definition: FastCaloSim.h:87
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:228
FastCaloSim::m_EkinMinElectrons
Gaudi::Property< float > m_EkinMinElectrons
Definition: FastCaloSim.h:108
isHadron
bool isHadron(const T &p)
Definition: AtlasPID.h:324
FastCaloSim::m_doPunchThrough
Gaudi::Property< bool > m_doPunchThrough
Definition: FastCaloSim.h:113
PunchThroughSimWrapper
Class to wrap PunchThrough simulation inside FastCaloSim; Runs both PunchThroughG4Classifier and Punc...
Definition: PunchThroughSimWrapper.h:35
FastCaloSim::ModelTrigger
G4bool ModelTrigger(const G4FastTrack &) override final
Determines the applicability of the fast sim model to this particular track.
Definition: FastCaloSim.cxx:122
RNGWrapper.h
TFCSTruthState.h
y
#define y
TFCSExtrapolationState.h
xAOD::EgammaHelpers::isPhoton
bool isPhoton(const xAOD::Egamma *eg)
is the object a photon
Definition: EgammaxAODHelpers.cxx:21
FastCaloSimCaloTransportation
Definition: FastCaloSimCaloTransportation.h:21
FastCaloSim::FastCaloSim
FastCaloSim(const std::string &name, const ServiceHandle< IAthRNGSvc > &rndmGenSvc, const Gaudi::Property< std::string > &randomEngineName, const PublicToolHandle< IFastCaloSimCaloTransportation > &FastCaloSimCaloTransportation, const PublicToolHandle< IFastCaloSimCaloExtrapolation > &FastCaloSimCaloExtrapolation, const PublicToolHandle< IG4CaloTransportTool > &G4CaloTransportTool, const PublicToolHandle< IPunchThroughSimWrapper > &PunchThroughSimWrapper, const ServiceHandle< ISF::IFastCaloSimParamSvc > &FastCaloSimSvc, const Gaudi::Property< std::string > &CaloCellContainerSDName, const Gaudi::Property< bool > &doG4Transport, const Gaudi::Property< bool > &doPhotons, const Gaudi::Property< bool > &doElectrons, const Gaudi::Property< bool > &doHadrons, const Gaudi::Property< float > &AbsEtaMin, const Gaudi::Property< float > &AbsEtaMax, const Gaudi::Property< float > &EkinMinPhotons, const Gaudi::Property< float > &EkinMaxPhotons, const Gaudi::Property< float > &EkinMinElectrons, const Gaudi::Property< float > &EkinMaxElectrons, const Gaudi::Property< bool > &doEMECFCS, const Gaudi::Property< bool > &doPunchThrough, FastCaloSimTool *FastCaloSimTool)
Definition: FastCaloSim.cxx:38
TFCSTruthState::set_vertex
void set_vertex(const TLorentzVector &val)
Definition: TFCSTruthState.h:19
FastCaloSim::m_rngWrapper
ATHRNG::RNGWrapper * m_rngWrapper
Definition: FastCaloSim.h:82
FastCaloSim::DoIt
void DoIt(const G4FastTrack &, G4FastStep &) override final
Definition: FastCaloSim.cxx:219
FastCaloSim::m_doG4Transport
Gaudi::Property< bool > m_doG4Transport
Definition: FastCaloSim.h:98
TFCSSimulationState::E
double E() const
Definition: TFCSSimulationState.h:42
TFCSSimulationState.h
FastCaloSim::m_G4CaloTransportTool
PublicToolHandle< IG4CaloTransportTool > m_G4CaloTransportTool
Definition: FastCaloSim.h:89
FastCaloSim::m_CaloCellContainerSDName
Gaudi::Property< std::string > m_CaloCellContainerSDName
Definition: FastCaloSim.h:96
FastCaloSim::passedIDCaloBoundary
G4bool passedIDCaloBoundary(const G4FastTrack &fastTrack)
Check if the particle is located at the proper ID-Calo parametrization boundary and is travelling out...
Definition: FastCaloSim.cxx:347
G4CaloTransportTool
A tool which transports particles through the Geant4 geometry.
Definition: G4CaloTransportTool.h:25
TFCSTruthState
Definition: TFCSTruthState.h:13
TFCSSimulationState
Definition: TFCSSimulationState.h:32
FastCaloSim::IsApplicable
G4bool IsApplicable(const G4ParticleDefinition &) override final
Definition: FastCaloSim.cxx:100
FastCaloSimTool
Definition: FastCaloSimTool.h:27
HepMCHelpers.h
FastCaloSim::m_rndmGenSvc
ServiceHandle< IAthRNGSvc > m_rndmGenSvc
Definition: FastCaloSim.h:80
TFCSTruthState::set_pdgid
void set_pdgid(int val)
Definition: TFCSTruthState.h:18
FastCaloSim::m_EkinMaxPhotons
Gaudi::Property< float > m_EkinMaxPhotons
Definition: FastCaloSim.h:107
ServiceHandle< IAthRNGSvc >