Get the interaction type of an event.
20 if (mcPrimaryList.empty())
21 throw StatusCodeException(STATUS_CODE_NOT_INITIALIZED);
23 InteractionParameters parameters;
28 if (OTHER_INTERACTION != cosmicRayHypothesis)
29 return cosmicRayHypothesis;
33 if (1 == parameters.m_nMuons)
34 return BEAM_PARTICLE_MU;
35 if (1 == parameters.m_nProtons)
36 return BEAM_PARTICLE_P;
37 if (1 == parameters.m_nElectrons)
38 return BEAM_PARTICLE_E;
39 if (1 == parameters.m_nPhotons)
40 return BEAM_PARTICLE_PHOTON;
41 if (1 == parameters.m_nPiPlus)
42 return BEAM_PARTICLE_PI_PLUS;
43 if (1 == parameters.m_nPiMinus)
44 return BEAM_PARTICLE_PI_MINUS;
45 if (1 == parameters.m_nKaonPlus)
46 return BEAM_PARTICLE_KAON_PLUS;
47 if (1 == parameters.m_nKaonMinus)
48 return BEAM_PARTICLE_KAON_MINUS;
50 return BEAM_PARTICLE_OTHER;
53 const MCParticle *pMCNeutrino(
nullptr);
55 for (
const MCParticle *
const pMCPrimary : mcPrimaryList)
59 throw StatusCodeException(STATUS_CODE_INVALID_PARAMETER);
65 throw StatusCodeException(STATUS_CODE_FAILURE);
69 if (1001 == nuNuanceCode)
71 if ((1 == parameters.m_nNonNeutrons) && (1 == parameters.m_nMuons) && (0 == parameters.m_nProtons))
73 if ((2 == parameters.m_nNonNeutrons) && (1 == parameters.m_nMuons) && (1 == parameters.m_nProtons))
75 if ((3 == parameters.m_nNonNeutrons) && (1 == parameters.m_nMuons) && (2 == parameters.m_nProtons))
77 if ((4 == parameters.m_nNonNeutrons) && (1 == parameters.m_nMuons) && (3 == parameters.m_nProtons))
78 return CCQEL_MU_P_P_P;
79 if ((5 == parameters.m_nNonNeutrons) && (1 == parameters.m_nMuons) && (4 == parameters.m_nProtons))
80 return CCQEL_MU_P_P_P_P;
81 if ((6 == parameters.m_nNonNeutrons) && (1 == parameters.m_nMuons) && (5 == parameters.m_nProtons))
82 return CCQEL_MU_P_P_P_P_P;
84 if ((1 == parameters.m_nNonNeutrons) && (1 == parameters.m_nElectrons) && (0 == parameters.m_nProtons))
86 if ((2 == parameters.m_nNonNeutrons) && (1 == parameters.m_nElectrons) && (1 == parameters.m_nProtons))
88 if ((3 == parameters.m_nNonNeutrons) && (1 == parameters.m_nElectrons) && (2 == parameters.m_nProtons))
90 if ((4 == parameters.m_nNonNeutrons) && (1 == parameters.m_nElectrons) && (3 == parameters.m_nProtons))
92 if ((5 == parameters.m_nNonNeutrons) && (1 == parameters.m_nElectrons) && (4 == parameters.m_nProtons))
93 return CCQEL_E_P_P_P_P;
94 if ((6 == parameters.m_nNonNeutrons) && (1 == parameters.m_nElectrons) && (5 == parameters.m_nProtons))
95 return CCQEL_E_P_P_P_P_P;
98 if (1002 == nuNuanceCode)
100 if ((1 == parameters.m_nNonNeutrons) && (1 == parameters.m_nProtons))
102 if ((2 == parameters.m_nNonNeutrons) && (2 == parameters.m_nProtons))
104 if ((3 == parameters.m_nNonNeutrons) && (3 == parameters.m_nProtons))
106 if ((4 == parameters.m_nNonNeutrons) && (4 == parameters.m_nProtons))
107 return NCQEL_P_P_P_P;
108 if ((5 == parameters.m_nNonNeutrons) && (5 == parameters.m_nProtons))
109 return NCQEL_P_P_P_P_P;
112 if ((nuNuanceCode >= 1003) && (nuNuanceCode <= 1005))
114 if ((1 == parameters.m_nNonNeutrons) && (1 == parameters.m_nMuons) && (0 == parameters.m_nProtons))
116 if ((2 == parameters.m_nNonNeutrons) && (1 == parameters.m_nMuons) && (1 == parameters.m_nProtons))
118 if ((3 == parameters.m_nNonNeutrons) && (1 == parameters.m_nMuons) && (2 == parameters.m_nProtons))
120 if ((4 == parameters.m_nNonNeutrons) && (1 == parameters.m_nMuons) && (3 == parameters.m_nProtons))
121 return CCRES_MU_P_P_P;
122 if ((5 == parameters.m_nNonNeutrons) && (1 == parameters.m_nMuons) && (4 == parameters.m_nProtons))
123 return CCRES_MU_P_P_P_P;
124 if ((6 == parameters.m_nNonNeutrons) && (1 == parameters.m_nMuons) && (5 == parameters.m_nProtons))
125 return CCRES_MU_P_P_P_P_P;
127 if ((2 == parameters.m_nNonNeutrons) && (1 == parameters.m_nMuons) && (0 == parameters.m_nProtons) && (1 == parameters.m_nPiPlus))
128 return CCRES_MU_PIPLUS;
129 if ((3 == parameters.m_nNonNeutrons) && (1 == parameters.m_nMuons) && (1 == parameters.m_nProtons) && (1 == parameters.m_nPiPlus))
130 return CCRES_MU_P_PIPLUS;
131 if ((4 == parameters.m_nNonNeutrons) && (1 == parameters.m_nMuons) && (2 == parameters.m_nProtons) && (1 == parameters.m_nPiPlus))
132 return CCRES_MU_P_P_PIPLUS;
133 if ((5 == parameters.m_nNonNeutrons) && (1 == parameters.m_nMuons) && (3 == parameters.m_nProtons) && (1 == parameters.m_nPiPlus))
134 return CCRES_MU_P_P_P_PIPLUS;
135 if ((6 == parameters.m_nNonNeutrons) && (1 == parameters.m_nMuons) && (4 == parameters.m_nProtons) && (1 == parameters.m_nPiPlus))
136 return CCRES_MU_P_P_P_P_PIPLUS;
137 if ((7 == parameters.m_nNonNeutrons) && (1 == parameters.m_nMuons) && (5 == parameters.m_nProtons) && (1 == parameters.m_nPiPlus))
138 return CCRES_MU_P_P_P_P_P_PIPLUS;
140 if ((2 == parameters.m_nNonNeutrons) && (1 == parameters.m_nMuons) && (0 == parameters.m_nProtons) && (1 == parameters.m_nPhotons))
141 return CCRES_MU_PHOTON;
142 if ((3 == parameters.m_nNonNeutrons) && (1 == parameters.m_nMuons) && (1 == parameters.m_nProtons) && (1 == parameters.m_nPhotons))
143 return CCRES_MU_P_PHOTON;
144 if ((4 == parameters.m_nNonNeutrons) && (1 == parameters.m_nMuons) && (2 == parameters.m_nProtons) && (1 == parameters.m_nPhotons))
145 return CCRES_MU_P_P_PHOTON;
146 if ((5 == parameters.m_nNonNeutrons) && (1 == parameters.m_nMuons) && (3 == parameters.m_nProtons) && (1 == parameters.m_nPhotons))
147 return CCRES_MU_P_P_P_PHOTON;
148 if ((6 == parameters.m_nNonNeutrons) && (1 == parameters.m_nMuons) && (4 == parameters.m_nProtons) && (1 == parameters.m_nPhotons))
149 return CCRES_MU_P_P_P_P_PHOTON;
150 if ((7 == parameters.m_nNonNeutrons) && (1 == parameters.m_nMuons) && (5 == parameters.m_nProtons) && (1 == parameters.m_nPhotons))
151 return CCRES_MU_P_P_P_P_P_PHOTON;
153 if ((3 == parameters.m_nNonNeutrons) && (1 == parameters.m_nMuons) && (0 == parameters.m_nProtons) && (2 == parameters.m_nPhotons))
154 return CCRES_MU_PIZERO;
155 if ((4 == parameters.m_nNonNeutrons) && (1 == parameters.m_nMuons) && (1 == parameters.m_nProtons) && (2 == parameters.m_nPhotons))
156 return CCRES_MU_P_PIZERO;
157 if ((5 == parameters.m_nNonNeutrons) && (1 == parameters.m_nMuons) && (2 == parameters.m_nProtons) && (2 == parameters.m_nPhotons))
158 return CCRES_MU_P_P_PIZERO;
159 if ((6 == parameters.m_nNonNeutrons) && (1 == parameters.m_nMuons) && (3 == parameters.m_nProtons) && (2 == parameters.m_nPhotons))
160 return CCRES_MU_P_P_P_PIZERO;
161 if ((7 == parameters.m_nNonNeutrons) && (1 == parameters.m_nMuons) && (4 == parameters.m_nProtons) && (2 == parameters.m_nPhotons))
162 return CCRES_MU_P_P_P_P_PIZERO;
163 if ((8 == parameters.m_nNonNeutrons) && (1 == parameters.m_nMuons) && (5 == parameters.m_nProtons) && (2 == parameters.m_nPhotons))
164 return CCRES_MU_P_P_P_P_P_PIZERO;
166 if ((1 == parameters.m_nNonNeutrons) && (1 == parameters.m_nElectrons) && (0 == parameters.m_nProtons))
168 if ((2 == parameters.m_nNonNeutrons) && (1 == parameters.m_nElectrons) && (1 == parameters.m_nProtons))
170 if ((3 == parameters.m_nNonNeutrons) && (1 == parameters.m_nElectrons) && (2 == parameters.m_nProtons))
172 if ((4 == parameters.m_nNonNeutrons) && (1 == parameters.m_nElectrons) && (3 == parameters.m_nProtons))
173 return CCRES_E_P_P_P;
174 if ((5 == parameters.m_nNonNeutrons) && (1 == parameters.m_nElectrons) && (4 == parameters.m_nProtons))
175 return CCRES_E_P_P_P_P;
176 if ((6 == parameters.m_nNonNeutrons) && (1 == parameters.m_nElectrons) && (5 == parameters.m_nProtons))
177 return CCRES_E_P_P_P_P_P;
179 if ((2 == parameters.m_nNonNeutrons) && (1 == parameters.m_nElectrons) && (0 == parameters.m_nProtons) && (1 == parameters.m_nPiPlus))
180 return CCRES_E_PIPLUS;
181 if ((3 == parameters.m_nNonNeutrons) && (1 == parameters.m_nElectrons) && (1 == parameters.m_nProtons) && (1 == parameters.m_nPiPlus))
182 return CCRES_E_P_PIPLUS;
183 if ((4 == parameters.m_nNonNeutrons) && (1 == parameters.m_nElectrons) && (2 == parameters.m_nProtons) && (1 == parameters.m_nPiPlus))
184 return CCRES_E_P_P_PIPLUS;
185 if ((5 == parameters.m_nNonNeutrons) && (1 == parameters.m_nElectrons) && (3 == parameters.m_nProtons) && (1 == parameters.m_nPiPlus))
186 return CCRES_E_P_P_P_PIPLUS;
187 if ((6 == parameters.m_nNonNeutrons) && (1 == parameters.m_nElectrons) && (4 == parameters.m_nProtons) && (1 == parameters.m_nPiPlus))
188 return CCRES_E_P_P_P_P_PIPLUS;
189 if ((7 == parameters.m_nNonNeutrons) && (1 == parameters.m_nElectrons) && (5 == parameters.m_nProtons) && (1 == parameters.m_nPiPlus))
190 return CCRES_E_P_P_P_P_P_PIPLUS;
192 if ((2 == parameters.m_nNonNeutrons) && (1 == parameters.m_nElectrons) && (0 == parameters.m_nProtons) && (1 == parameters.m_nPhotons))
193 return CCRES_E_PHOTON;
194 if ((3 == parameters.m_nNonNeutrons) && (1 == parameters.m_nElectrons) && (1 == parameters.m_nProtons) && (1 == parameters.m_nPhotons))
195 return CCRES_E_P_PHOTON;
196 if ((4 == parameters.m_nNonNeutrons) && (1 == parameters.m_nElectrons) && (2 == parameters.m_nProtons) && (1 == parameters.m_nPhotons))
197 return CCRES_E_P_P_PHOTON;
198 if ((5 == parameters.m_nNonNeutrons) && (1 == parameters.m_nElectrons) && (3 == parameters.m_nProtons) && (1 == parameters.m_nPhotons))
199 return CCRES_E_P_P_P_PHOTON;
200 if ((6 == parameters.m_nNonNeutrons) && (1 == parameters.m_nElectrons) && (4 == parameters.m_nProtons) && (1 == parameters.m_nPhotons))
201 return CCRES_E_P_P_P_P_PHOTON;
202 if ((7 == parameters.m_nNonNeutrons) && (1 == parameters.m_nElectrons) && (5 == parameters.m_nProtons) && (1 == parameters.m_nPhotons))
203 return CCRES_E_P_P_P_P_P_PHOTON;
205 if ((3 == parameters.m_nNonNeutrons) && (1 == parameters.m_nElectrons) && (0 == parameters.m_nProtons) && (2 == parameters.m_nPhotons))
206 return CCRES_E_PIZERO;
207 if ((4 == parameters.m_nNonNeutrons) && (1 == parameters.m_nElectrons) && (1 == parameters.m_nProtons) && (2 == parameters.m_nPhotons))
208 return CCRES_E_P_PIZERO;
209 if ((5 == parameters.m_nNonNeutrons) && (1 == parameters.m_nElectrons) && (2 == parameters.m_nProtons) && (2 == parameters.m_nPhotons))
210 return CCRES_E_P_P_PIZERO;
211 if ((6 == parameters.m_nNonNeutrons) && (1 == parameters.m_nElectrons) && (3 == parameters.m_nProtons) && (2 == parameters.m_nPhotons))
212 return CCRES_E_P_P_P_PIZERO;
213 if ((7 == parameters.m_nNonNeutrons) && (1 == parameters.m_nElectrons) && (4 == parameters.m_nProtons) && (2 == parameters.m_nPhotons))
214 return CCRES_E_P_P_P_P_PIZERO;
215 if ((8 == parameters.m_nNonNeutrons) && (1 == parameters.m_nElectrons) && (5 == parameters.m_nProtons) && (2 == parameters.m_nPhotons))
216 return CCRES_E_P_P_P_P_P_PIZERO;
219 if ((nuNuanceCode >= 1006) && (nuNuanceCode <= 1009))
221 if ((1 == parameters.m_nNonNeutrons) && (1 == parameters.m_nProtons))
223 if ((2 == parameters.m_nNonNeutrons) && (2 == parameters.m_nProtons))
225 if ((3 == parameters.m_nNonNeutrons) && (3 == parameters.m_nProtons))
227 if ((4 == parameters.m_nNonNeutrons) && (4 == parameters.m_nProtons))
228 return NCRES_P_P_P_P;
229 if ((5 == parameters.m_nNonNeutrons) && (5 == parameters.m_nProtons))
230 return NCRES_P_P_P_P_P;
232 if ((1 == parameters.m_nNonNeutrons) && (0 == parameters.m_nProtons) && (1 == parameters.m_nPiPlus))
234 if ((2 == parameters.m_nNonNeutrons) && (1 == parameters.m_nProtons) && (1 == parameters.m_nPiPlus))
235 return NCRES_P_PIPLUS;
236 if ((3 == parameters.m_nNonNeutrons) && (2 == parameters.m_nProtons) && (1 == parameters.m_nPiPlus))
237 return NCRES_P_P_PIPLUS;
238 if ((4 == parameters.m_nNonNeutrons) && (3 == parameters.m_nProtons) && (1 == parameters.m_nPiPlus))
239 return NCRES_P_P_P_PIPLUS;
240 if ((5 == parameters.m_nNonNeutrons) && (4 == parameters.m_nProtons) && (1 == parameters.m_nPiPlus))
241 return NCRES_P_P_P_P_PIPLUS;
242 if ((6 == parameters.m_nNonNeutrons) && (5 == parameters.m_nProtons) && (1 == parameters.m_nPiPlus))
243 return NCRES_P_P_P_P_P_PIPLUS;
245 if ((1 == parameters.m_nNonNeutrons) && (0 == parameters.m_nProtons) && (1 == parameters.m_nPiMinus))
246 return NCRES_PIMINUS;
247 if ((2 == parameters.m_nNonNeutrons) && (1 == parameters.m_nProtons) && (1 == parameters.m_nPiMinus))
248 return NCRES_P_PIMINUS;
249 if ((3 == parameters.m_nNonNeutrons) && (2 == parameters.m_nProtons) && (1 == parameters.m_nPiMinus))
250 return NCRES_P_P_PIMINUS;
251 if ((4 == parameters.m_nNonNeutrons) && (3 == parameters.m_nProtons) && (1 == parameters.m_nPiMinus))
252 return NCRES_P_P_P_PIMINUS;
253 if ((5 == parameters.m_nNonNeutrons) && (4 == parameters.m_nProtons) && (1 == parameters.m_nPiMinus))
254 return NCRES_P_P_P_P_PIMINUS;
255 if ((6 == parameters.m_nNonNeutrons) && (5 == parameters.m_nProtons) && (1 == parameters.m_nPiMinus))
256 return NCRES_P_P_P_P_P_PIMINUS;
258 if ((1 == parameters.m_nNonNeutrons) && (0 == parameters.m_nProtons) && (1 == parameters.m_nPhotons))
260 if ((2 == parameters.m_nNonNeutrons) && (1 == parameters.m_nProtons) && (1 == parameters.m_nPhotons))
261 return NCRES_P_PHOTON;
262 if ((3 == parameters.m_nNonNeutrons) && (2 == parameters.m_nProtons) && (1 == parameters.m_nPhotons))
263 return NCRES_P_P_PHOTON;
264 if ((4 == parameters.m_nNonNeutrons) && (3 == parameters.m_nProtons) && (1 == parameters.m_nPhotons))
265 return NCRES_P_P_P_PHOTON;
266 if ((5 == parameters.m_nNonNeutrons) && (4 == parameters.m_nProtons) && (1 == parameters.m_nPhotons))
267 return NCRES_P_P_P_P_PHOTON;
268 if ((6 == parameters.m_nNonNeutrons) && (5 == parameters.m_nProtons) && (1 == parameters.m_nPhotons))
269 return NCRES_P_P_P_P_P_PHOTON;
271 if ((2 == parameters.m_nNonNeutrons) && (0 == parameters.m_nProtons) && (2 == parameters.m_nPhotons))
273 if ((3 == parameters.m_nNonNeutrons) && (1 == parameters.m_nProtons) && (2 == parameters.m_nPhotons))
274 return NCRES_P_PIZERO;
275 if ((4 == parameters.m_nNonNeutrons) && (2 == parameters.m_nProtons) && (2 == parameters.m_nPhotons))
276 return NCRES_P_P_PIZERO;
277 if ((5 == parameters.m_nNonNeutrons) && (3 == parameters.m_nProtons) && (2 == parameters.m_nPhotons))
278 return NCRES_P_P_P_PIZERO;
279 if ((6 == parameters.m_nNonNeutrons) && (4 == parameters.m_nProtons) && (2 == parameters.m_nPhotons))
280 return NCRES_P_P_P_P_PIZERO;
281 if ((7 == parameters.m_nNonNeutrons) && (5 == parameters.m_nProtons) && (2 == parameters.m_nPhotons))
282 return NCRES_P_P_P_P_P_PIZERO;
285 if (1091 == nuNuanceCode)
287 if ((1 == parameters.m_nNonNeutrons) && (1 == parameters.m_nMuons) && (0 == parameters.m_nProtons))
289 if ((2 == parameters.m_nNonNeutrons) && (1 == parameters.m_nMuons) && (1 == parameters.m_nProtons))
291 if ((3 == parameters.m_nNonNeutrons) && (1 == parameters.m_nMuons) && (2 == parameters.m_nProtons))
293 if ((4 == parameters.m_nNonNeutrons) && (1 == parameters.m_nMuons) && (3 == parameters.m_nProtons))
294 return CCDIS_MU_P_P_P;
295 if ((5 == parameters.m_nNonNeutrons) && (1 == parameters.m_nMuons) && (4 == parameters.m_nProtons))
296 return CCDIS_MU_P_P_P_P;
297 if ((6 == parameters.m_nNonNeutrons) && (1 == parameters.m_nMuons) && (5 == parameters.m_nProtons))
298 return CCDIS_MU_P_P_P_P_P;
300 if ((2 == parameters.m_nNonNeutrons) && (1 == parameters.m_nMuons) && (0 == parameters.m_nProtons) && (1 == parameters.m_nPiPlus))
301 return CCDIS_MU_PIPLUS;
302 if ((3 == parameters.m_nNonNeutrons) && (1 == parameters.m_nMuons) && (1 == parameters.m_nProtons) && (1 == parameters.m_nPiPlus))
303 return CCDIS_MU_P_PIPLUS;
304 if ((4 == parameters.m_nNonNeutrons) && (1 == parameters.m_nMuons) && (2 == parameters.m_nProtons) && (1 == parameters.m_nPiPlus))
305 return CCDIS_MU_P_P_PIPLUS;
306 if ((5 == parameters.m_nNonNeutrons) && (1 == parameters.m_nMuons) && (3 == parameters.m_nProtons) && (1 == parameters.m_nPiPlus))
307 return CCDIS_MU_P_P_P_PIPLUS;
308 if ((6 == parameters.m_nNonNeutrons) && (1 == parameters.m_nMuons) && (4 == parameters.m_nProtons) && (1 == parameters.m_nPiPlus))
309 return CCDIS_MU_P_P_P_P_PIPLUS;
310 if ((7 == parameters.m_nNonNeutrons) && (1 == parameters.m_nMuons) && (5 == parameters.m_nProtons) && (1 == parameters.m_nPiPlus))
311 return CCDIS_MU_P_P_P_P_P_PIPLUS;
313 if ((2 == parameters.m_nNonNeutrons) && (1 == parameters.m_nMuons) && (0 == parameters.m_nProtons) && (1 == parameters.m_nPhotons))
314 return CCDIS_MU_PHOTON;
315 if ((3 == parameters.m_nNonNeutrons) && (1 == parameters.m_nMuons) && (1 == parameters.m_nProtons) && (1 == parameters.m_nPhotons))
316 return CCDIS_MU_P_PHOTON;
317 if ((4 == parameters.m_nNonNeutrons) && (1 == parameters.m_nMuons) && (2 == parameters.m_nProtons) && (1 == parameters.m_nPhotons))
318 return CCDIS_MU_P_P_PHOTON;
319 if ((5 == parameters.m_nNonNeutrons) && (1 == parameters.m_nMuons) && (3 == parameters.m_nProtons) && (1 == parameters.m_nPhotons))
320 return CCDIS_MU_P_P_P_PHOTON;
321 if ((6 == parameters.m_nNonNeutrons) && (1 == parameters.m_nMuons) && (4 == parameters.m_nProtons) && (1 == parameters.m_nPhotons))
322 return CCDIS_MU_P_P_P_P_PHOTON;
323 if ((7 == parameters.m_nNonNeutrons) && (1 == parameters.m_nMuons) && (5 == parameters.m_nProtons) && (1 == parameters.m_nPhotons))
324 return CCDIS_MU_P_P_P_P_P_PHOTON;
326 if ((3 == parameters.m_nNonNeutrons) && (1 == parameters.m_nMuons) && (0 == parameters.m_nProtons) && (2 == parameters.m_nPhotons))
327 return CCDIS_MU_PIZERO;
328 if ((4 == parameters.m_nNonNeutrons) && (1 == parameters.m_nMuons) && (1 == parameters.m_nProtons) && (2 == parameters.m_nPhotons))
329 return CCDIS_MU_P_PIZERO;
330 if ((5 == parameters.m_nNonNeutrons) && (1 == parameters.m_nMuons) && (2 == parameters.m_nProtons) && (2 == parameters.m_nPhotons))
331 return CCDIS_MU_P_P_PIZERO;
332 if ((6 == parameters.m_nNonNeutrons) && (1 == parameters.m_nMuons) && (3 == parameters.m_nProtons) && (2 == parameters.m_nPhotons))
333 return CCDIS_MU_P_P_P_PIZERO;
334 if ((7 == parameters.m_nNonNeutrons) && (1 == parameters.m_nMuons) && (4 == parameters.m_nProtons) && (2 == parameters.m_nPhotons))
335 return CCDIS_MU_P_P_P_P_PIZERO;
336 if ((8 == parameters.m_nNonNeutrons) && (1 == parameters.m_nMuons) && (5 == parameters.m_nProtons) && (2 == parameters.m_nPhotons))
337 return CCDIS_MU_P_P_P_P_P_PIZERO;
340 if (1092 == nuNuanceCode)
342 if ((1 == parameters.m_nNonNeutrons) && (1 == parameters.m_nProtons))
344 if ((2 == parameters.m_nNonNeutrons) && (2 == parameters.m_nProtons))
346 if ((3 == parameters.m_nNonNeutrons) && (3 == parameters.m_nProtons))
348 if ((4 == parameters.m_nNonNeutrons) && (4 == parameters.m_nProtons))
349 return NCDIS_P_P_P_P;
350 if ((5 == parameters.m_nNonNeutrons) && (5 == parameters.m_nProtons))
351 return NCDIS_P_P_P_P_P;
353 if ((1 == parameters.m_nNonNeutrons) && (0 == parameters.m_nProtons) && (1 == parameters.m_nPiPlus))
355 if ((2 == parameters.m_nNonNeutrons) && (1 == parameters.m_nProtons) && (1 == parameters.m_nPiPlus))
356 return NCDIS_P_PIPLUS;
357 if ((3 == parameters.m_nNonNeutrons) && (2 == parameters.m_nProtons) && (1 == parameters.m_nPiPlus))
358 return NCDIS_P_P_PIPLUS;
359 if ((4 == parameters.m_nNonNeutrons) && (3 == parameters.m_nProtons) && (1 == parameters.m_nPiPlus))
360 return NCDIS_P_P_P_PIPLUS;
361 if ((5 == parameters.m_nNonNeutrons) && (4 == parameters.m_nProtons) && (1 == parameters.m_nPiPlus))
362 return NCDIS_P_P_P_P_PIPLUS;
363 if ((6 == parameters.m_nNonNeutrons) && (5 == parameters.m_nProtons) && (1 == parameters.m_nPiPlus))
364 return NCDIS_P_P_P_P_P_PIPLUS;
366 if ((1 == parameters.m_nNonNeutrons) && (0 == parameters.m_nProtons) && (1 == parameters.m_nPiMinus))
367 return NCDIS_PIMINUS;
368 if ((2 == parameters.m_nNonNeutrons) && (1 == parameters.m_nProtons) && (1 == parameters.m_nPiMinus))
369 return NCDIS_P_PIMINUS;
370 if ((3 == parameters.m_nNonNeutrons) && (2 == parameters.m_nProtons) && (1 == parameters.m_nPiMinus))
371 return NCDIS_P_P_PIMINUS;
372 if ((4 == parameters.m_nNonNeutrons) && (3 == parameters.m_nProtons) && (1 == parameters.m_nPiMinus))
373 return NCDIS_P_P_P_PIMINUS;
374 if ((5 == parameters.m_nNonNeutrons) && (4 == parameters.m_nProtons) && (1 == parameters.m_nPiMinus))
375 return NCDIS_P_P_P_P_PIMINUS;
376 if ((6 == parameters.m_nNonNeutrons) && (5 == parameters.m_nProtons) && (1 == parameters.m_nPiMinus))
377 return NCDIS_P_P_P_P_P_PIMINUS;
379 if ((1 == parameters.m_nNonNeutrons) && (0 == parameters.m_nProtons) && (1 == parameters.m_nPhotons))
381 if ((2 == parameters.m_nNonNeutrons) && (1 == parameters.m_nProtons) && (1 == parameters.m_nPhotons))
382 return NCDIS_P_PHOTON;
383 if ((3 == parameters.m_nNonNeutrons) && (2 == parameters.m_nProtons) && (1 == parameters.m_nPhotons))
384 return NCDIS_P_P_PHOTON;
385 if ((4 == parameters.m_nNonNeutrons) && (3 == parameters.m_nProtons) && (1 == parameters.m_nPhotons))
386 return NCDIS_P_P_P_PHOTON;
387 if ((5 == parameters.m_nNonNeutrons) && (4 == parameters.m_nProtons) && (1 == parameters.m_nPhotons))
388 return NCDIS_P_P_P_P_PHOTON;
389 if ((6 == parameters.m_nNonNeutrons) && (5 == parameters.m_nProtons) && (1 == parameters.m_nPhotons))
390 return NCDIS_P_P_P_P_P_PHOTON;
392 if ((2 == parameters.m_nNonNeutrons) && (0 == parameters.m_nProtons) && (2 == parameters.m_nPhotons))
394 if ((3 == parameters.m_nNonNeutrons) && (1 == parameters.m_nProtons) && (2 == parameters.m_nPhotons))
395 return NCDIS_P_PIZERO;
396 if ((4 == parameters.m_nNonNeutrons) && (2 == parameters.m_nProtons) && (2 == parameters.m_nPhotons))
397 return NCDIS_P_P_PIZERO;
398 if ((5 == parameters.m_nNonNeutrons) && (3 == parameters.m_nProtons) && (2 == parameters.m_nPhotons))
399 return NCDIS_P_P_P_PIZERO;
400 if ((6 == parameters.m_nNonNeutrons) && (4 == parameters.m_nProtons) && (2 == parameters.m_nPhotons))
401 return NCDIS_P_P_P_P_PIZERO;
402 if ((7 == parameters.m_nNonNeutrons) && (5 == parameters.m_nProtons) && (2 == parameters.m_nPhotons))
403 return NCDIS_P_P_P_P_P_PIZERO;
406 if (1096 == nuNuanceCode)
408 if (1097 == nuNuanceCode)
411 return OTHER_INTERACTION;
static unsigned int GetNuanceCode(const pandora::MCParticle *const pMCParticle)
Get the nuance code of an MCParticle.
static void SetInteractionParameters(const pandora::MCParticleList &mcPrimaryList, InteractionParameters ¶meters)
Set parameters describing the number and species of primary interaction products. ...
static bool IsBeamParticle(const pandora::MCParticle *const pMCParticle)
Returns true if passed a primary beam MCParticle.
static const pandora::MCParticle * GetParentMCParticle(const pandora::MCParticle *const pMCParticle)
Get the parent mc particle.
InteractionType
InteractionType enum.
static InteractionType CosmicRayHypothesis(const pandora::MCParticleList &mcPrimaryList, const InteractionParameters ¶meters)
Get the interaction type of an event under a cosmic ray hypothesis.
static bool IsBeamNeutrinoFinalState(const pandora::MCParticle *const pMCParticle)
Returns true if passed a primary neutrino final state MCParticle.