BaryonResUtils.cxx
Go to the documentation of this file.
1 //____________________________________________________________________________
2 /*
3  Copyright (c) 2003-2019, The GENIE Collaboration
4  For the full text of the license visit http://copyright.genie-mc.org
5  or see $GENIE/LICENSE
6 
7  Author: Costas Andreopoulos <costas.andreopoulos \at stfc.ac.uk>
8  University of Liverpool & STFC Rutherford Appleton Lab
9 
10  For the namespace documentation see the corresponding header file.
11 
12  Important revisions after version 2.0.0 :
13  @ Dec 11, 2008 - CA
14  Fixed a bug with the Delta- pdg code. It was incorrectly set to -2214.
15  Now set to 1114. The bug affected the final state nubar RES events.
16  @ Jun 17, 2009 - CA
17  Used resonance codes from PDG/PDGCodes.h
18  @ Oct 20, 2009 - CA
19  Modified ResonanceCharge() to take into account the probe charge (so as
20  to conserve charge in charged lepton scattering)
21  @ Jul 23, 2010 - CA
22  Moved ResonanceCharge(Interaction) to EVGModules/HadronicSystemGenerator
23  to avoid dependency of BaryonResonance package on the Interaction package.
24  Added OrbitalAngularMom(Resonance_t), ResonanceIndex(Resonance_t)
25  Width(Resonance_t) and BWNorm(Resonance_t) functions, previously available
26  through a BaryonResDataSetI implementation. Simplified BaryonResonance
27  package by removing the redundant BaryonResDataPDG, BaryonResDataSetI
28  BreitWignerI, BreitWignerRes, BreitWignerLRes and BaryonResParams classes.
29 
30 */
31 //____________________________________________________________________________
32 
33 #include <cassert>
34 #include <cstdlib>
35 #include <map>
36 
37 #include <TMath.h>
38 
44 #include "Framework/Utils/BWFunc.h"
45 
46 using namespace genie;
47 
48 //____________________________________________________________________________
50 {
51  switch(res) {
52  case kP33_1232 : return "P33(1232)" ; break;
53  case kS11_1535 : return "S11(1535)" ; break;
54  case kD13_1520 : return "D13(1520)" ; break;
55  case kS11_1650 : return "S11(1650)" ; break;
56  case kD13_1700 : return "D13(1700)" ; break;
57  case kD15_1675 : return "D15(1675)" ; break;
58  case kS31_1620 : return "S31(1620)" ; break;
59  case kD33_1700 : return "D33(1700)" ; break;
60  case kP11_1440 : return "P11(1440)" ; break;
61  case kP33_1600 : return "P33(1600)" ; break;
62  case kP13_1720 : return "P13(1720)" ; break;
63  case kF15_1680 : return "F15(1680)" ; break;
64  case kP31_1910 : return "P31(1910)" ; break;
65  case kP33_1920 : return "P33(1920)" ; break;
66  case kF35_1905 : return "F35(1905)" ; break;
67  case kF37_1950 : return "F37(1950)" ; break;
68  case kP11_1710 : return "P11(1710)" ; break;
69  case kF17_1970 : return "F17(1970)" ; break;
70  default: break;
71  }
72  return "unknown resonance!";
73 }
74 //____________________________________________________________________________
76 {
77  if ( strcmp( res,"P33(1232)" ) == 0 ) return kP33_1232;
78  else if( strcmp( res,"S11(1535)" ) == 0 ) return kS11_1535;
79  else if( strcmp( res,"D13(1520)" ) == 0 ) return kD13_1520;
80  else if( strcmp( res,"S11(1650)" ) == 0 ) return kS11_1650;
81  else if( strcmp( res,"D13(1700)" ) == 0 ) return kD13_1700;
82  else if( strcmp( res,"D15(1675)" ) == 0 ) return kD15_1675;
83  else if( strcmp( res,"S31(1620)" ) == 0 ) return kS31_1620;
84  else if( strcmp( res,"D33(1700)" ) == 0 ) return kD33_1700;
85  else if( strcmp( res,"P11(1440)" ) == 0 ) return kP11_1440;
86  else if( strcmp( res,"P33(1600)" ) == 0 ) return kP33_1600;
87  else if( strcmp( res,"P13(1720)" ) == 0 ) return kP13_1720;
88  else if( strcmp( res,"F15(1680)" ) == 0 ) return kF15_1680;
89  else if( strcmp( res,"P31(1910)" ) == 0 ) return kP31_1910;
90  else if( strcmp( res,"P33(1920)" ) == 0 ) return kP33_1920;
91  else if( strcmp( res,"F35(1905)" ) == 0 ) return kF35_1905;
92  else if( strcmp( res,"F37(1950)" ) == 0 ) return kF37_1950;
93  else if( strcmp( res,"P11(1710)" ) == 0 ) return kP11_1710;
94  else if( strcmp( res,"F17(1970)" ) == 0 ) return kF17_1970;
95  else return kNoResonance;
96 }
97 //____________________________________________________________________________
99 {
100  // Delta(1232) code from the standard PDG table.
101  // Higher resonance codes come from MINOS extensions to PDG tables.
102 
103  switch(pdgc) {
104 
105  case (kPdgP33m1232_DeltaM ) : /* Delta- */
106  case (kPdgP33m1232_Delta0 ) : /* Delta0 */
107  case (kPdgP33m1232_DeltaP ) : /* Delta+ */
108  case (kPdgP33m1232_DeltaPP) : /* Delta++ */
109  return kP33_1232; break;
110 
111  case (kPdgS11m1535_N0) : /* N0 */
112  case (kPdgS11m1535_NP) : /* N+ */
113  return kS11_1535; break;
114 
115  case (kPdgD13m1520_N0) : /* N0 */
116  case (kPdgD13m1520_NP) : /* N+ */
117  return kD13_1520; break;
118 
119  case (kPdgS11m1650_N0) : /* N0 */
120  case (kPdgS11m1650_NP) : /* N+ */
121  return kS11_1650; break;
122 
123  case (kPdgD13m1700_N0) : /* N0 */
124  case (kPdgD13m1700_NP) : /* N+ */
125  return kD13_1700; break;
126 
127  case (kPdgD15m1675_N0) : /* N0 */
128  case (kPdgD15m1675_NP) : /* N+ */
129  return kD15_1675; break;
130 
131  case (kPdgS31m1620_DeltaM ) : /* Delta- */
132  case (kPdgS31m1620_Delta0 ) : /* Delta0 */
133  case (kPdgS31m1620_DeltaP ) : /* Delta+ */
134  case (kPdgS31m1620_DeltaPP) : /* Delta++ */
135  return kS31_1620; break;
136 
137  case (kPdgD33m1700_DeltaM ) : /* Delta- */
138  case (kPdgD33m1700_Delta0 ) : /* Delta0 */
139  case (kPdgD33m1700_DeltaP ) : /* Delta+ */
140  case (kPdgD33m1700_DeltaPP) : /* Delta++ */
141  return kD33_1700; break;
142 
143  case (kPdgP11m1440_N0) : /* N0 */
144  case (kPdgP11m1440_NP) : /* N+ */
145  return kP11_1440; break;
146 
147  case (kPdgP13m1720_N0) : /* N0 */
148  case (kPdgP13m1720_NP) : /* N+ */
149  return kP13_1720; break;
150 
151  case (kPdgF15m1680_N0) : /* N0 */
152  case (kPdgF15m1680_NP) : /* N+ */
153  return kF15_1680; break;
154 
155  case (kPdgP31m1910_DeltaM ) : /* Delta- */
156  case (kPdgP31m1910_Delta0 ) : /* Delta0 */
157  case (kPdgP31m1910_DeltaP ) : /* Delta+ */
158  case (kPdgP31m1910_DeltaPP) : /* Delta++ */
159  return kP31_1910; break;
160 
161  case (kPdgP33m1920_DeltaM ) : /* Delta- */
162  case (kPdgP33m1920_Delta0 ) : /* Delta0 */
163  case (kPdgP33m1920_DeltaP ) : /* Delta+ */
164  case (kPdgP33m1920_DeltaPP) : /* Delta++ */
165  return kP33_1920; break;
166 
167  case (kPdgF35m1905_DeltaM ) : /* Delta- */
168  case (kPdgF35m1905_Delta0 ) : /* Delta0 */
169  case (kPdgF35m1905_DeltaP ) : /* Delta+ */
170  case (kPdgF35m1905_DeltaPP) : /* Delta++ */
171  return kF35_1905; break;
172 
173  case (kPdgF37m1950_DeltaM ) : /* Delta- */
174  case (kPdgF37m1950_Delta0 ) : /* Delta0 */
175  case (kPdgF37m1950_DeltaP ) : /* Delta+ */
176  case (kPdgF37m1950_DeltaPP) : /* Delta++ */
177  return kF37_1950; break;
178 
179  case (kPdgP11m1710_N0) : /* N0 */
180  case (kPdgP11m1710_NP) : /* N+ */
181  return kP11_1710; break;
182  }
183 
184  return kNoResonance;
185 }
186 //____________________________________________________________________________
188 {
189  // Delta(1232) code from the standard PDG table
190  // Higher resonance codes come from MINOS extensions to PDG tables
191 
192  switch(res) {
193 
194  case kP33_1232:
195  if(Q == -1) return kPdgP33m1232_DeltaM; /* Delta- */
196  if(Q == 0) return kPdgP33m1232_Delta0; /* Delta0 */
197  if(Q == 1) return kPdgP33m1232_DeltaP; /* Delta+ */
198  if(Q == 2) return kPdgP33m1232_DeltaPP; /* Delta++ */
199  break;
200 
201  case kS11_1535:
202  if(Q == 0) return kPdgS11m1535_N0; /* N0 */
203  if(Q == 1) return kPdgS11m1535_NP; /* N+ */
204  break;
205 
206  case kD13_1520:
207  if(Q == 0) return kPdgD13m1520_N0; /* N0 */
208  if(Q == 1) return kPdgD13m1520_NP; /* N+ */
209  break;
210 
211  case kS11_1650:
212  if(Q == 0) return kPdgS11m1650_N0; /* N0 */
213  if(Q == 1) return kPdgS11m1650_NP; /* N+ */
214  break;
215 
216  case kD13_1700:
217  if(Q == 0) return kPdgD13m1700_N0; /* N0 */
218  if(Q == 1) return kPdgD13m1700_NP; /* N+ */
219  break;
220 
221  case kD15_1675:
222  if(Q == 0) return kPdgD15m1675_N0; /* N0 */
223  if(Q == 1) return kPdgD15m1675_NP; /* N+ */
224  break;
225 
226  case kS31_1620:
227  if(Q == -1) return kPdgS31m1620_DeltaM; /* Delta- */
228  if(Q == 0) return kPdgS31m1620_Delta0; /* Delta0 */
229  if(Q == 1) return kPdgS31m1620_DeltaP; /* Delta+ */
230  if(Q == 2) return kPdgS31m1620_DeltaPP; /* Delta++ */
231  break;
232 
233  case kD33_1700:
234  if(Q == -1) return kPdgD33m1700_DeltaM; /* Delta- */
235  if(Q == 0) return kPdgD33m1700_Delta0; /* Delta0 */
236  if(Q == 1) return kPdgD33m1700_DeltaP; /* Delta+ */
237  if(Q == 2) return kPdgD33m1700_DeltaPP; /* Delta++ */
238  break;
239 
240  case kP11_1440:
241  if(Q == 0) return kPdgP11m1440_N0; /* N0 */
242  if(Q == 1) return kPdgP11m1440_NP; /* N+ */
243  break;
244 
245  case kP33_1600:
246  return 0;
247 
248  case kP13_1720:
249  if(Q == 0) return kPdgP13m1720_N0; /* N0 */
250  if(Q == 1) return kPdgP13m1720_NP; /* N+ */
251  break;
252 
253  case kF15_1680:
254  if(Q == 0) return kPdgF15m1680_N0; /* N0 */
255  if(Q == 1) return kPdgF15m1680_NP; /* N+ */
256  break;
257 
258  case kP31_1910:
259  if(Q == -1) return kPdgP31m1910_DeltaM; /* Delta- */
260  if(Q == 0) return kPdgP31m1910_Delta0; /* Delta0 */
261  if(Q == 1) return kPdgP31m1910_DeltaP; /* Delta+ */
262  if(Q == 2) return kPdgP31m1910_DeltaPP; /* Delta++ */
263  break;
264 
265  case kP33_1920:
266  if(Q == -1) return kPdgP33m1920_DeltaM; /* Delta- */
267  if(Q == 0) return kPdgP33m1920_Delta0; /* Delta0 */
268  if(Q == 1) return kPdgP33m1920_DeltaP; /* Delta+ */
269  if(Q == 2) return kPdgP33m1920_DeltaPP; /* Delta++ */
270  break;
271 
272  case kF35_1905:
273  if(Q == -1) return kPdgF35m1905_DeltaM; /* Delta- */
274  if(Q == 0) return kPdgF35m1905_Delta0; /* Delta0 */
275  if(Q == 1) return kPdgF35m1905_DeltaP; /* Delta+ */
276  if(Q == 2) return kPdgF35m1905_DeltaPP; /* Delta++ */
277  break;
278 
279  case kF37_1950:
280  if(Q == -1) return kPdgF37m1950_DeltaM; /* Delta- */
281  if(Q == 0) return kPdgF37m1950_Delta0; /* Delta0 */
282  if(Q == 1) return kPdgF37m1950_DeltaP; /* Delta+ */
283  if(Q == 2) return kPdgF37m1950_DeltaPP; /* Delta++ */
284  break;
285 
286  case kP11_1710:
287  if(Q == 0) return kPdgP11m1710_N0; /* N0 */
288  if(Q == 1) return kPdgP11m1710_NP; /* N+ */
289  break;
290 
291  case kF17_1970:
292  return 0;
293  break;
294 
295  default:
296  return 0;
297  }
298 
299  return 0;
300 }
301 //____________________________________________________________________________
303 {
304  // Delta(1232) code from the standard PDG table.
305  // Higher resonance codes come from MINOS extensions to PDG tables.
306 
307  switch(pdgc) {
308 
309  /* ------ P33(1232) ------*/
310  case (kPdgP33m1232_DeltaM ) : /* Delta- */
311  case (kPdgP33m1232_Delta0 ) : /* Delta0 */
312  case (kPdgP33m1232_DeltaP ) : /* Delta+ */
313  case (kPdgP33m1232_DeltaPP) : /* Delta++ */
314 
315  /* ------ S11(1535) ------*/
316  case (kPdgS11m1535_N0) : /* N0 */
317  case (kPdgS11m1535_NP) : /* N+ */
318 
319  /* ------ D13(1520) ------*/
320  case (kPdgD13m1520_N0) : /* N0 */
321  case (kPdgD13m1520_NP) : /* N+ */
322 
323  /* ------ S11(1650) ------*/
324  case (kPdgS11m1650_N0) : /* N0 */
325  case (kPdgS11m1650_NP) : /* N+ */
326 
327  /* ------ D13(1700) ------*/
328  case (kPdgD13m1700_N0) : /* N0 */
329  case (kPdgD13m1700_NP) : /* N+ */
330 
331  /* ------ D15(1675) ------*/
332  case (kPdgD15m1675_N0) : /* N0 */
333  case (kPdgD15m1675_NP) : /* N+ */
334 
335  /* ------ S31(1620) ------*/
336  case (kPdgS31m1620_DeltaM ) : /* Delta- */
337  case (kPdgS31m1620_Delta0 ) : /* Delta0 */
338  case (kPdgS31m1620_DeltaP ) : /* Delta+ */
339  case (kPdgS31m1620_DeltaPP) : /* Delta++ */
340 
341  /* ------ D33(1700) ------*/
342  case (kPdgD33m1700_DeltaM ) : /* Delta- */
343  case (kPdgD33m1700_Delta0 ) : /* Delta0 */
344  case (kPdgD33m1700_DeltaP ) : /* Delta+ */
345  case (kPdgD33m1700_DeltaPP) : /* Delta++ */
346 
347  /* ------ P11(1440) ------*/
348  case (kPdgP11m1440_N0) : /* N0 */
349  case (kPdgP11m1440_NP) : /* N+ */
350 
351  /* ------ P33(1600) ------*/
352  // are you?
353 
354  /* ------ P13(1720) ------*/
355  case (kPdgP13m1720_N0) : /* N0 */
356  case (kPdgP13m1720_NP) : /* N+ */
357 
358  /* ------ F15(1680) ------*/
359  case (kPdgF15m1680_N0) : /* N0 */
360  case (kPdgF15m1680_NP) : /* N+ */
361 
362  /* ------ P31(1910) ------*/
363  case (kPdgP31m1910_DeltaM ) : /* Delta- */
364  case (kPdgP31m1910_Delta0 ) : /* Delta0 */
365  case (kPdgP31m1910_DeltaP ) : /* Delta+ */
366  case (kPdgP31m1910_DeltaPP) : /* Delta++ */
367 
368  /* ------ P33(1920) ------*/
369  case (kPdgP33m1920_DeltaM ) : /* Delta- */
370  case (kPdgP33m1920_Delta0 ) : /* Delta0 */
371  case (kPdgP33m1920_DeltaP ) : /* Delta+ */
372  case (kPdgP33m1920_DeltaPP) : /* Delta++ */
373 
374  /* ------ F35(1905) ------*/
375  case (kPdgF35m1905_DeltaM ) : /* Delta- */
376  case (kPdgF35m1905_Delta0 ) : /* Delta0 */
377  case (kPdgF35m1905_DeltaP ) : /* Delta+ */
378  case (kPdgF35m1905_DeltaPP) : /* Delta++ */
379 
380  /* ------ F37(1950) ------*/
381  case (kPdgF37m1950_DeltaM ) : /* Delta- */
382  case (kPdgF37m1950_Delta0 ) : /* Delta0 */
383  case (kPdgF37m1950_DeltaP ) : /* Delta+ */
384  case (kPdgF37m1950_DeltaPP) : /* Delta++ */
385 
386  /* ------ P11(1710) ------*/
387  case (kPdgP11m1710_N0) : /* N0 */
388  case (kPdgP11m1710_NP) : /* N+ */
389 
390  /* ------ F17(1970) ------*/
391  // are you?
392 
393  return true;
394  }
395 
396  return false;
397 }
398 //____________________________________________________________________________
400 {
401  switch(res) {
402 
403  case kP33_1232: return true; break;
404  case kS11_1535: return false; break;
405  case kD13_1520: return false; break;
406  case kS11_1650: return false; break;
407  case kD13_1700: return false; break;
408  case kD15_1675: return false; break;
409  case kS31_1620: return true; break;
410  case kD33_1700: return true; break;
411  case kP11_1440: return false; break;
412  case kP33_1600: return true; break;
413  case kP13_1720: return false; break;
414  case kF15_1680: return false; break;
415  case kP31_1910: return true; break;
416  case kP33_1920: return true; break;
417  case kF35_1905: return true; break;
418  case kF37_1950: return true; break;
419  case kP11_1710: return false; break;
420  case kF17_1970: return false; break;
421  default:
422  // should not be here - meaningless to return anything
423  assert(false);
424  }
425  return false;
426 }
427 //____________________________________________________________________________
428 // The values of resonance mass and width is taken from
429 // M. Tanabashi et al. (Particle Data Group) Phys. Rev. D 98, 030001
431 {
432  return (! utils::res::IsDelta(res) );
433 }
434 //____________________________________________________________________________
436 {
437  switch(res) {
438  case kP33_1232 : return 1.232 * units::GeV ; break;
439  case kS11_1535 : return 1.535 * units::GeV ; break;
440  case kD13_1520 : return 1.515 * units::GeV ; break;
441  case kS11_1650 : return 1.655 * units::GeV ; break;
442  case kD13_1700 : return 1.700 * units::GeV ; break;
443  case kD15_1675 : return 1.675 * units::GeV ; break;
444  case kS31_1620 : return 1.630 * units::GeV ; break;
445  case kD33_1700 : return 1.700 * units::GeV ; break;
446  case kP11_1440 : return 1.430 * units::GeV ; break;
447  case kP33_1600 : return 1.600 * units::GeV ; break;
448  case kP13_1720 : return 1.720 * units::GeV ; break;
449  case kF15_1680 : return 1.685 * units::GeV ; break;
450  case kP31_1910 : return 1.890 * units::GeV ; break;
451  case kP33_1920 : return 1.920 * units::GeV ; break;
452  case kF35_1905 : return 1.880 * units::GeV ; break;
453  case kF37_1950 : return 1.930 * units::GeV ; break;
454  case kP11_1710 : return 1.710 * units::GeV ; break;
455  case kF17_1970 : return 2.190 * units::GeV ; break;
456  default: break;
457  }
458  return -1;
459 }
460 //____________________________________________________________________________
462 {
463  switch(res) {
464  case kP33_1232 : return 0.117 * units::GeV ; break;
465  case kS11_1535 : return 0.150 * units::GeV ; break;
466  case kD13_1520 : return 0.115 * units::GeV ; break;
467  case kS11_1650 : return 0.140 * units::GeV ; break;
468  case kD13_1700 : return 0.150 * units::GeV ; break;
469  case kD15_1675 : return 0.150 * units::GeV ; break;
470  case kS31_1620 : return 0.140 * units::GeV ; break;
471  case kD33_1700 : return 0.300 * units::GeV ; break;
472  case kP11_1440 : return 0.350 * units::GeV ; break;
473  case kP33_1600 : return 0.320 * units::GeV ; break;
474  case kP13_1720 : return 0.250 * units::GeV ; break;
475  case kF15_1680 : return 0.130 * units::GeV ; break;
476  case kP31_1910 : return 0.280 * units::GeV ; break;
477  case kP33_1920 : return 0.260 * units::GeV ; break;
478  case kF35_1905 : return 0.330 * units::GeV ; break;
479  case kF37_1950 : return 0.285 * units::GeV ; break;
480  case kP11_1710 : return 0.100 * units::GeV ; break;
481  case kF17_1970 : return 0.500 * units::GeV ; break;
482  default: break;
483  }
484  return -1;
485 }
486 //____________________________________________________________________________
487 double genie::utils::res::BWNorm(Resonance_t res, double N0ResMaxNWidths, double N2ResMaxNWidths, double GnResMaxNWidths)
488 {
489  static genie::utils::res::CacheBWNorm cbwn;
490  if (res==kNoResonance) return -1;
491  if (cbwn.cache[res]!=0) return cbwn.cache[res];
492 
493 
494  // Get baryon resonance parameters
495  int IR = utils::res::ResonanceIndex (res);
496  int LR = utils::res::OrbitalAngularMom (res);
497  double MR = utils::res::Mass (res);
498  double WR = utils::res::Width (res);
499 
500  // imported part of code from src/contrib/misc/bwnorm.C
501 
502  double NW = GnResMaxNWidths;
503  if(IR==2) NW = N2ResMaxNWidths;
504  if(IR==0) NW = N0ResMaxNWidths;
505 
506  double Wmin = 0.001;
507  double Wmax = MR + NW*WR;
508  int N = 1000* TMath::Nint( (Wmax-Wmin)/WR );
509  if(N%2==0) N++;
510 
511  double dW = (Wmax-Wmin)/(N-1);
512 
513  double sum = 0.5 * (genie::utils::bwfunc::BreitWignerL(Wmin,LR,MR,WR,1.0) + genie::utils::bwfunc::BreitWignerL(Wmax,LR,MR,WR,1.0));
514 
515  for(int i=1; i<N-1; i++) {
516  double W = Wmin + i*dW;
517  sum += ( genie::utils::bwfunc::BreitWignerL(W,LR,MR,WR,1.0) * (i%2+1) );
518  }
519  sum *= (2.*dW/3.);
520  cbwn.cache[res]=sum;
521  return cbwn.cache[res];
522 }
523 //____________________________________________________________________________
525 {
526  switch(res) {
527  case kP33_1232: return 1; break;
528  case kS11_1535: return 0; break;
529  case kD13_1520: return 2; break;
530  case kS11_1650: return 0; break;
531  case kD13_1700: return 2; break;
532  case kD15_1675: return 2; break;
533  case kS31_1620: return 0; break;
534  case kD33_1700: return 2; break;
535  case kP11_1440: return 1; break;
536  case kP33_1600: return 1; break;
537  case kP13_1720: return 1; break;
538  case kF15_1680: return 3; break;
539  case kP31_1910: return 1; break;
540  case kP33_1920: return 1; break;
541  case kF35_1905: return 3; break;
542  case kF37_1950: return 3; break;
543  case kP11_1710: return 1; break;
544  case kF17_1970: return 3; break;
545  default:
546  // should not be here - meaningless to return anything
547  gAbortingInErr = true;
548  LOG("BaryonRes", pFATAL)
549  << "Unknown resonance " << res;
550  exit(1);
551  }
552  return 0;
553 }
554 //____________________________________________________________________________
556 {
557  switch(res) {
558  case kP33_1232: return 0; break;
559  case kS11_1535: return 1; break;
560  case kD13_1520: return 1; break;
561  case kS11_1650: return 1; break;
562  case kD13_1700: return 1; break;
563  case kD15_1675: return 1; break;
564  case kS31_1620: return 1; break;
565  case kD33_1700: return 1; break;
566  case kP11_1440: return 2; break;
567  case kP33_1600: return 2; break;
568  case kP13_1720: return 2; break;
569  case kF15_1680: return 2; break;
570  case kP31_1910: return 2; break;
571  case kP33_1920: return 2; break;
572  case kF35_1905: return 2; break;
573  case kF37_1950: return 2; break;
574  case kP11_1710: return 2; break;
575  case kF17_1970: return 2; break;
576  default:
577  // should not be here - meaningless to return anything
578  gAbortingInErr = true;
579  LOG("BaryonRes", pFATAL)
580  << "Unknown resonance " << res;
581  exit(1);
582  }
583  return 0;
584 }
585 //____________________________________________________________________________
bool IsDelta(Resonance_t res)
is it a Delta resonance?
const int kPdgP31m1910_DeltaP
Definition: PDGCodes.h:118
const int kPdgS31m1620_DeltaM
Definition: PDGCodes.h:102
const int kPdgP33m1232_DeltaPP
Definition: PDGCodes.h:91
Resonance_t FromString(const char *res)
string -> resonance id
const int kPdgF35m1905_DeltaM
Definition: PDGCodes.h:124
THE MAIN GENIE PROJECT NAMESPACE
Definition: GeneratorBase.h:8
const int kPdgD15m1675_N0
Definition: PDGCodes.h:100
const int kPdgF35m1905_Delta0
Definition: PDGCodes.h:125
const int kPdgF15m1680_NP
Definition: PDGCodes.h:115
const int kPdgD33m1700_Delta0
Definition: PDGCodes.h:107
const int kPdgD13m1700_NP
Definition: PDGCodes.h:99
#define pFATAL
Definition: Messenger.h:57
cached breit-wigner normalization factor
double Wmax[kNWBins]
double Mass(Resonance_t res)
resonance mass (GeV)
const int kPdgS11m1650_N0
Definition: PDGCodes.h:96
double Width(Resonance_t res)
resonance width (GeV)
const int kPdgF37m1950_DeltaM
Definition: PDGCodes.h:128
const int kPdgF37m1950_DeltaP
Definition: PDGCodes.h:130
double BreitWignerL(double W, int L, double mass, double width0, double norm)
Definition: BWFunc.cxx:107
const int kPdgS11m1535_N0
Definition: PDGCodes.h:92
double BWNorm(Resonance_t res, double N0ResMaxNWidths=6, double N2ResMaxNWidths=2, double GnResMaxNWidths=4)
breit-wigner normalization factor
enum genie::EResonance Resonance_t
bool IsN(Resonance_t res)
is it an N resonance?
const int kPdgP33m1232_DeltaP
Definition: PDGCodes.h:90
const int kPdgP33m1232_DeltaM
Definition: PDGCodes.h:88
const int kPdgP31m1910_DeltaM
Definition: PDGCodes.h:116
const int kPdgF37m1950_Delta0
Definition: PDGCodes.h:129
const int kPdgD33m1700_DeltaPP
Definition: PDGCodes.h:109
const int kPdgF35m1905_DeltaP
Definition: PDGCodes.h:126
int PdgCode(Resonance_t res, int Q)
(resonance id, charge) -> PDG code
#define LOG(stream, priority)
A macro that returns the requested log4cpp::Category appending a string (using the FILE...
Definition: Messenger.h:97
const int kPdgD15m1675_NP
Definition: PDGCodes.h:101
const int kPdgF35m1905_DeltaPP
Definition: PDGCodes.h:127
const int kPdgS31m1620_DeltaPP
Definition: PDGCodes.h:105
const int kPdgP31m1910_DeltaPP
Definition: PDGCodes.h:119
const int kPdgP33m1920_DeltaPP
Definition: PDGCodes.h:123
const int kPdgP31m1910_Delta0
Definition: PDGCodes.h:117
int OrbitalAngularMom(Resonance_t res)
orbital angular momentum
const int kPdgP33m1920_DeltaP
Definition: PDGCodes.h:122
const int kPdgD33m1700_DeltaM
Definition: PDGCodes.h:106
const int kPdgP33m1920_DeltaM
Definition: PDGCodes.h:120
const int kPdgF37m1950_DeltaPP
Definition: PDGCodes.h:131
const int kPdgD13m1520_NP
Definition: PDGCodes.h:95
const int kPdgF15m1680_N0
Definition: PDGCodes.h:114
const int kPdgP11m1710_N0
Definition: PDGCodes.h:132
const int kPdgS11m1650_NP
Definition: PDGCodes.h:97
Resonance_t FromPdgCode(int pdgc)
PDG code -> resonance id.
const int kPdgP33m1232_Delta0
Definition: PDGCodes.h:89
const int kPdgP13m1720_N0
Definition: PDGCodes.h:112
const int kPdgP11m1440_N0
Definition: PDGCodes.h:110
const int kPdgP33m1920_Delta0
Definition: PDGCodes.h:121
const int kPdgD13m1520_N0
Definition: PDGCodes.h:94
const int kPdgP11m1440_NP
Definition: PDGCodes.h:111
const int kPdgS31m1620_Delta0
Definition: PDGCodes.h:103
exit(0)
assert(nhit_max >=nhit_nbins)
const char * AsString(Resonance_t res)
resonance id -> string
double Wmin[kNWBins]
bool IsBaryonResonance(int pdgc)
is input a baryon resonance?
const int kPdgP11m1710_NP
Definition: PDGCodes.h:133
const int kPdgS11m1535_NP
Definition: PDGCodes.h:93
Double_t sum
Definition: plot.C:31
static const double GeV
Definition: Units.h:29
bool gAbortingInErr
Definition: Messenger.cxx:56
#define W(x)
const int kPdgS31m1620_DeltaP
Definition: PDGCodes.h:104
Most commonly used PDG codes. A set of utility functions to handle PDG codes is provided in PDGUtils...
const int kPdgP13m1720_NP
Definition: PDGCodes.h:113
std::map< genie::EResonance, double > cache
int ResonanceIndex(Resonance_t res)
resonance idx, quark model / SU(6)
const int kPdgD13m1700_N0
Definition: PDGCodes.h:98
const int kPdgD33m1700_DeltaP
Definition: PDGCodes.h:108