ATLAS Offline Software
PunchThroughParticle.cxx
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration
3 */
4 
6 // PunchThroughParticle.cxx, (c) ATLAS Detector software
8 
9 // class header
10 #include "PunchThroughParticle.h"
11 
12 // ROOT
13 #include "TH2F.h"
14 
15 /*=========================================================================
16  * DESCRIPTION OF FUNCTION:
17  * ==> see headerfile
18  *=======================================================================*/
20  m_pdgId(pdg),
21  m_doAnti(doAnti),
22  m_minEnergy(0.),
23  m_maxNum(-1),
24  m_numParticlesFactor(1.),
25  m_energyFactor(1.),
26  m_posAngleFactor(1.),
27  m_momAngleFactor(1.),
28  m_corrPdg(0),
29  m_corrMinEnergy(0),
30  m_corrFullEnergy(0),
31  m_histCorrLowE(nullptr),
32  m_histCorrHighE(nullptr),
33  m_corrHistDomains(nullptr),
34  m_pdfNumParticles(nullptr), //does this number ever change?
35  m_pdf_pca0(nullptr),
36  m_pdf_pca1(nullptr),
37  m_pdf_pca2(nullptr),
38  m_pdf_pca3(nullptr),
39  m_pdf_pca4(nullptr)
40 { }
41 
42 /*=========================================================================
43  * DESCRIPTION OF FUNCTION:
44  * ==> see headerfile
45  *=======================================================================*/
47 {
48  delete[] m_corrHistDomains;
49 }
50 
51 /*=========================================================================
52  * DESCRIPTION OF FUNCTION:
53  * ==> see headerfile
54  *=======================================================================*/
55 
57 {
58  m_minEnergy = minEnergy;
59 }
60 
61 /*=========================================================================
62  * DESCRIPTION OF FUNCTION:
63  * ==> see headerfile
64  *=======================================================================*/
65 
67 {
68  m_maxNum = maxNum;
69 }
70 
71 /*=========================================================================
72  * DESCRIPTION OF FUNCTION:
73  * ==> see headerfile
74  *=======================================================================*/
75 
77 {
78  m_numParticlesFactor = numFactor;
79 }
80 
81 /*=========================================================================
82  * DESCRIPTION OF FUNCTION:
83  * ==> see headerfile
84  *=======================================================================*/
85 
87 {
88  m_energyFactor = energyFactor;
89 }
90 
91 
92 /*=========================================================================
93  * DESCRIPTION OF FUNCTION:
94  * ==> see headerfile
95  *=======================================================================*/
97 {
98  m_posAngleFactor = posAngleFactor;
99 }
100 
101 /*=========================================================================
102  * DESCRIPTION OF FUNCTION:
103  * ==> see headerfile
104  *=======================================================================*/
106 {
107  m_momAngleFactor = momAngleFactor;
108 }
109 
110 /*=========================================================================
111  * DESCRIPTION OF FUNCTION:
112  * ==> see headerfile
113  *=======================================================================*/
114 
115 void ISF::PunchThroughParticle::setNumParticlesPDF(std::unique_ptr<PDFcreator> pdf)
116 {
117  m_pdfNumParticles = std::move(pdf);
118 }
119 
120 /*=========================================================================
121  * DESCRIPTION OF FUNCTION:
122  * ==> see headerfile
123  *=======================================================================*/
124 
126  TH2F *histLowE, TH2F *histHighE,
127  double minCorrelationEnergy,
128  double fullCorrelationEnergy,
129  double lowE,
130  double midE,
131  double upperE)
132 {
133  m_corrPdg = corrPdg;
134  m_histCorrLowE = histLowE;
135  m_histCorrHighE = histHighE;
136  m_corrMinEnergy = minCorrelationEnergy;
137  m_corrFullEnergy = fullCorrelationEnergy;
138 
139  m_corrHistDomains = new double [3];
140  m_corrHistDomains[0] = lowE;
141  m_corrHistDomains[1] = midE;
142  m_corrHistDomains[2] = upperE;
143 }
144 
145 /*=========================================================================
146  * DESCRIPTION OF FUNCTION:
147 
148  * ==> see headerfile
149  *=======================================================================*/
150 
151 void ISF::PunchThroughParticle::setPCA0PDF(std::unique_ptr<PDFcreator> pdf)
152 {
153  m_pdf_pca0 = std::move(pdf);
154 }
155 
156 /*=========================================================================
157  * DESCRIPTION OF FUNCTION:
158  * ==> see headerfile
159  *=======================================================================*/
160 
161 void ISF::PunchThroughParticle::setPCA1PDF(std::unique_ptr<PDFcreator> pdf)
162 {
163  m_pdf_pca1 = std::move(pdf);
164 }
165 
166 /*=========================================================================
167  * DESCRIPTION OF FUNCTION:
168  * ==> see headerfile
169  *=======================================================================*/
170 
171 void ISF::PunchThroughParticle::setPCA2PDF(std::unique_ptr<PDFcreator> pdf)
172 {
173  m_pdf_pca2 = std::move(pdf);
174 }
175 
176 /*=========================================================================
177  * DESCRIPTION OF FUNCTION:
178  * ==> see headerfile
179  *=======================================================================*/
180 void ISF::PunchThroughParticle::setPCA3PDF(std::unique_ptr<PDFcreator> pdf)
181 {
182  m_pdf_pca3 = std::move(pdf);
183 }
184 
185 /*=========================================================================
186  * DESCRIPTION OF FUNCTION:
187  * ==> see headerfile
188  *=======================================================================*/
189 void ISF::PunchThroughParticle::setPCA4PDF(std::unique_ptr<PDFcreator> pdf)
190 {
191  m_pdf_pca4 = std::move(pdf);
192 }
PunchThroughParticle.h
ISF::PunchThroughParticle::setPCA2PDF
void setPCA2PDF(std::unique_ptr< PDFcreator > pdf)
set the PDFcreator for the deltaPhi distribution
Definition: PunchThroughParticle.cxx:171
ISF::PunchThroughParticle::~PunchThroughParticle
~PunchThroughParticle()
destructor
Definition: PunchThroughParticle.cxx:46
ISF::PunchThroughParticle::setPCA4PDF
void setPCA4PDF(std::unique_ptr< PDFcreator > pdf)
set the PDFcreator for the momentumDeltaPhi distribution
Definition: PunchThroughParticle.cxx:189
ISF::PunchThroughParticle::setNumParticlesPDF
void setNumParticlesPDF(std::unique_ptr< PDFcreator > pdf)
set the PDFcreator for the number of exit particles distribution
Definition: PunchThroughParticle.cxx:115
python.TrigEgammaMonitorHelper.TH2F
def TH2F(name, title, nxbins, bins_par2, bins_par3, bins_par4, bins_par5=None, bins_par6=None, path='', **kwargs)
Definition: TrigEgammaMonitorHelper.py:45
ISF::PunchThroughParticle::PunchThroughParticle
PunchThroughParticle(int pdg, bool doAnti=false)
set this particle's pdg code and if anti-particle should be done or not
Definition: PunchThroughParticle.cxx:19
ISF::PunchThroughParticle::setCorrelation
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
Definition: PunchThroughParticle.cxx:125
ISF::PunchThroughParticle::setPCA3PDF
void setPCA3PDF(std::unique_ptr< PDFcreator > pdf)
set the PDFcreator for the momentumDeltaTheta distribution
Definition: PunchThroughParticle.cxx:180
ISF::PunchThroughParticle::setPCA0PDF
void setPCA0PDF(std::unique_ptr< PDFcreator > pdf)
set the PDFcreator for the energy distribution
Definition: PunchThroughParticle.cxx:151
ISF::PunchThroughParticle::setMomAngleFactor
void setMomAngleFactor(double momAngleFactor)
to scale the momentum deviation of created particles
Definition: PunchThroughParticle.cxx:105
ISF::PunchThroughParticle::setMaxNumParticles
void setMaxNumParticles(int maxNum)
the maximum number of particles which will be created
Definition: PunchThroughParticle.cxx:66
ISF::PunchThroughParticle::setPosAngleFactor
void setPosAngleFactor(double momAngleFactor)
to scale the position deflection angles
Definition: PunchThroughParticle.cxx:96
ISF::PunchThroughParticle::setEnergyFactor
void setEnergyFactor(double energyFactor)
to scale the energy of created particles
Definition: PunchThroughParticle.cxx:86
PowhegPythia8EvtGen_jetjet.pdf
pdf
Definition: PowhegPythia8EvtGen_jetjet.py:4
ISF::PunchThroughParticle::setMinEnergy
void setMinEnergy(double minEnergy)
set methods
Definition: PunchThroughParticle.cxx:56
ISF::PunchThroughParticle::setPCA1PDF
void setPCA1PDF(std::unique_ptr< PDFcreator > pdf)
set the PDFcreator for the deltaTheta distribution
Definition: PunchThroughParticle.cxx:161
ISF::PunchThroughParticle::setNumParticlesFactor
void setNumParticlesFactor(double numFactor)
to scale the number of punch-through particles
Definition: PunchThroughParticle.cxx:76