ATLAS Offline Software
Loading...
Searching...
No Matches
G4Atlas/G4AtlasTools/src/PunchThroughParticle.cxx
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration
3*/
4
6// PunchThroughParticle.cxx, (c) ATLAS Detector software
8
9// class header
11
12// ROOT
13#include "TH2F.h"
14
16 m_pdgId(pdg),
17 m_doAnti(doAnti),
18 m_minEnergy(0.),
19 m_maxNum(-1),
24 m_corrPdg(0),
27 m_histCorrLowE(nullptr),
28 m_histCorrHighE(nullptr),
29 m_corrHistDomains(nullptr),
30 m_pdfNumParticles(nullptr), //does this number ever change?
31 m_pdf_pca0(nullptr),
32 m_pdf_pca1(nullptr),
33 m_pdf_pca2(nullptr),
34 m_pdf_pca3(nullptr),
35 m_pdf_pca4(nullptr)
36{ }
37
42
44{
45 m_minEnergy = minEnergy;
46}
47
49{
50 m_maxNum = maxNum;
51}
52
54{
55 m_numParticlesFactor = numFactor;
56}
57
59{
60 m_energyFactor = energyFactor;
61}
62
63void PunchThroughParticle::setPosAngleFactor(double posAngleFactor)
64{
65 m_posAngleFactor = posAngleFactor;
66}
67
68void PunchThroughParticle::setMomAngleFactor(double momAngleFactor)
69{
70 m_momAngleFactor = momAngleFactor;
71}
72
73void PunchThroughParticle::setNumParticlesPDF(std::unique_ptr<PunchThroughPDFCreator> pdf)
74{
75 m_pdfNumParticles = std::move(pdf);
76}
77
79 TH2F *histLowE, TH2F *histHighE,
80 double minCorrelationEnergy,
81 double fullCorrelationEnergy,
82 double lowE,
83 double midE,
84 double upperE)
85{
86 m_corrPdg = corrPdg;
87 m_histCorrLowE = histLowE;
88 m_histCorrHighE = histHighE;
89 m_corrMinEnergy = minCorrelationEnergy;
90 m_corrFullEnergy = fullCorrelationEnergy;
91
92 m_corrHistDomains = new double [3];
93 m_corrHistDomains[0] = lowE;
94 m_corrHistDomains[1] = midE;
95 m_corrHistDomains[2] = upperE;
96}
97
98void PunchThroughParticle::setPCA0PDF(std::unique_ptr<PunchThroughPDFCreator> pdf)
99{
100 m_pdf_pca0 = std::move(pdf);
101}
102
103void PunchThroughParticle::setPCA1PDF(std::unique_ptr<PunchThroughPDFCreator> pdf)
104{
105 m_pdf_pca1 = std::move(pdf);
106}
107
108void PunchThroughParticle::setPCA2PDF(std::unique_ptr<PunchThroughPDFCreator> pdf)
109{
110 m_pdf_pca2 = std::move(pdf);
111}
112
113void PunchThroughParticle::setPCA3PDF(std::unique_ptr<PunchThroughPDFCreator> pdf)
114{
115 m_pdf_pca3 = std::move(pdf);
116}
117
118void PunchThroughParticle::setPCA4PDF(std::unique_ptr<PunchThroughPDFCreator> pdf)
119{
120 m_pdf_pca4 = std::move(pdf);
121}
int m_maxNum
the maximum number of particles which will be created
void setPCA4PDF(std::unique_ptr< PunchThroughPDFCreator > pdf)
set the PunchThroughPDFCreator for the momentumDeltaPhi distribution
int m_corrPdg
all following stores the right distributions for all properties of the punch-through particles
double * m_corrHistDomains
correlation histogram domains
double m_minEnergy
some cut-parameters which will be set via python
void setPCA1PDF(std::unique_ptr< PunchThroughPDFCreator > pdf)
set the PunchThroughPDFCreator for the deltaTheta distribution
double m_corrFullEnergy
holds the energy threshold above which a particle correlation is fully developed
std::unique_ptr< PunchThroughPDFCreator > m_pdf_pca0
energy of punch-through particles
void setNumParticlesPDF(std::unique_ptr< PunchThroughPDFCreator > pdf)
set the PunchThroughPDFCreator for the number of exit particles distribution
std::unique_ptr< PunchThroughPDFCreator > m_pdfNumParticles
number of punch-through particles
PunchThroughParticle(int pdg, bool doAnti=false)
set this particle's pdg code and if anti-particle should be done or not
std::unique_ptr< PunchThroughPDFCreator > m_pdf_pca4
delta phi angle of punch-through particle momentum
void setCorrelation(int corrPdg, TH2F *histLowE, TH2F *histHighE, double minCorrE=0., double fullCorrE=0., double lowE=0., double midE=0., double upperE=0.)
set the correlated particle type + correlation histograms
void setPosAngleFactor(double momAngleFactor)
to scale the position deflection angles
void setMomAngleFactor(double momAngleFactor)
to scale the momentum deviation of created particles
void setPCA3PDF(std::unique_ptr< PunchThroughPDFCreator > pdf)
set the PunchThroughPDFCreator for the momentumDeltaTheta distribution
TH2F * m_histCorrLowE
low energy correlation histogram (x:this particle, y:the correlated particle)
void setEnergyFactor(double energyFactor)
to scale the energy of created particles
std::unique_ptr< PunchThroughPDFCreator > m_pdf_pca3
delta theta angle of punch-through particle momentum
void setMaxNumParticles(int maxNum)
the maximum number of particles which will be created
void setNumParticlesFactor(double numFactor)
to scale the number of punch-through particles
int m_pdgId
distribution parameters for the momentum delta phi
double m_energyFactor
scale the energy of this particle type
double m_momAngleFactor
scale the momentum deviation
TH2F * m_histCorrHighE
high energy correlation histogram (x:this particle, y:the correlated particle)
double m_numParticlesFactor
some tuning-parameters which will be set via python
double m_posAngleFactor
scale the position deflection angles
double m_corrMinEnergy
below this energy threshold, no particle correlation is computed
std::unique_ptr< PunchThroughPDFCreator > m_pdf_pca2
phi deviation of punch-through particles
void setPCA2PDF(std::unique_ptr< PunchThroughPDFCreator > pdf)
set the PunchThroughPDFCreator for the deltaPhi distribution
void setPCA0PDF(std::unique_ptr< PunchThroughPDFCreator > pdf)
set the PunchThroughPDFCreator for the energy distribution
std::unique_ptr< PunchThroughPDFCreator > m_pdf_pca1
theta deviation of punch-through particles