MINT2
FocusFlatte.cpp
Go to the documentation of this file.
1 // author: Jonas Rademacker (Jonas.Rademacker@bristol.ac.uk)
2 // status: Mon 9 Feb 2009 19:18:04 GMT
3 #include "Mint/FocusFlatte.h"
4 
7 
8 #include <cmath>
9 #include <iostream>
10 
11 using namespace std;
12 using namespace MINT;
13 
14 double FocusFlatte::gPi()const{
15  return _gPi;
16 }
17 double FocusFlatte::gK()const{
18  return _gK_by_gPi * gPi();
19 }
20 
21 double FocusFlatte::pdgMass(int PDG_ID) {
22  return ParticlePropertiesList::mass(PDG_ID);
23 }
25  if (_pi0Mass <= 0){
26  _pi0Mass = pdgMass(111);
27  }
28  return _pi0Mass;
29 }
31  if (_piPlusMass <= 0){
32  _piPlusMass = pdgMass(211);
33  }
34  return _piPlusMass;
35 }
37  if (_K0Mass <= 0){
38  _K0Mass = pdgMass(311);
39  }
40  return _K0Mass;
41 }
43  if (_KPlusMass <= 0){
44  _KPlusMass = pdgMass(321);
45  }
46  return _KPlusMass;
47 }
48 
49 std::complex<double> FocusFlatte::aSqrtTerm(double m0, double m){
50  bool dbThis=false;
51  double a2 = 1.0 - (2*m0/m)*(2*m0/m);
52  std::complex<double> a;
53 
54  if(a2 < 0){
55  if(dbThis){
56  cout << "WARNING in FocusFlatte::aSqrtTerm()"
57  << " sqrt( 1.0 - (2m0/m)^2 ) imaginary"
58  << " (returning an imaginary number)."
59  << endl;
60  }
61  std::complex<double> i(0.0, 1.0);
62  a = i * a2;
63  }else{
64  std::complex<double> unit(1.0, 0.0);
65  a = ((std::complex<double>) sqrt(a2)) * unit;
66  }
67  return a;
68 }
69 
70 std::complex<double> FocusFlatte::complexGofM(){
71  bool dbThis=false;
72 
73  double m = BW_BW::mumsRecoMass();
74 
75  std::complex<double> Gpipi = (1./3.) * aSqrtTerm( mPi0(), m )
76  + (2./3.) * aSqrtTerm( mPiPlus(), m );
77 
78 
79  std::complex<double> GKK = (1./2.) * aSqrtTerm( mK0(), m )
80  + (1./2.) * aSqrtTerm( mKPlus(), m );
81 
82  std::complex<double> FlatteWidth = gPi() * Gpipi + gK() * GKK;
83  if(dbThis){
84  cout << "LAURENS CLASS FocusFlatte: compare Flatte Width = " << FlatteWidth
85  << " BW_BW::GofM() " << BW_BW::GofM()
86  << endl;
87  }
88  return FlatteWidth;
89 }
90 
92  cout << "ERROR FocusFlatte::GofM() called should not have happenned!" <<endl;
93  std::complex<double> val = complexGofM();
94  return abs(val);
95 }
96 
97 std::complex<double> FocusFlatte::BreitWigner() {
98  // double mpdg = mumsPDGMass();
99  double mpdg = mumsMass();
100  std::complex<double> i(0.0, 1.0);
101  std::complex<double> invBW = (((std::complex<double>) mpdg*mpdg -
102  mumsRecoMass2()) - i * mpdg * complexGofM());
103  return 1.*GeV*GeV/invBW;
104 
105 }
double gPi() const
Definition: FocusFlatte.cpp:14
double gK() const
Definition: FocusFlatte.cpp:17
static std::complex< double > aSqrtTerm(double a, double b)
Definition: FocusFlatte.cpp:49
static double pdgMass(int PDG_ID)
Definition: FocusFlatte.cpp:21
virtual std::complex< double > BreitWigner()
Definition: FocusFlatte.cpp:97
double mPiPlus()
Definition: FocusFlatte.cpp:30
double mPi0()
Definition: FocusFlatte.cpp:24
double mKPlus()
Definition: FocusFlatte.cpp:42
static const double m
static const double GeV
double mK0()
Definition: FocusFlatte.cpp:36
virtual double GofM()
Definition: BW_BW.cpp:1035
virtual double mumsRecoMass() const
Definition: BW_BW.cpp:631
static double mass(const std::string &name)
virtual double GofM()
Definition: FocusFlatte.cpp:91
std::complex< double > complexGofM()
Definition: FocusFlatte.cpp:70