evtgen is hosted by Hepforge, IPPP Durham
EvtGen  2.0.0
Monte Carlo generator of particle decays, in particular the weak decays of heavy flavour particles such as B mesons.
EvtResonance.cpp
Go to the documentation of this file.
1 
2 /***********************************************************************
3 * Copyright 1998-2020 CERN for the benefit of the EvtGen authors *
4 * *
5 * This file is part of EvtGen. *
6 * *
7 * EvtGen is free software: you can redistribute it and/or modify *
8 * it under the terms of the GNU General Public License as published by *
9 * the Free Software Foundation, either version 3 of the License, or *
10 * (at your option) any later version. *
11 * *
12 * EvtGen is distributed in the hope that it will be useful, *
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of *
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
15 * GNU General Public License for more details. *
16 * *
17 * You should have received a copy of the GNU General Public License *
18 * along with EvtGen. If not, see <https://www.gnu.org/licenses/>. *
19 ***********************************************************************/
20 
22 
23 #include "EvtGenBase/EvtComplex.hh"
24 #include "EvtGenBase/EvtConst.hh"
25 #include "EvtGenBase/EvtKine.hh"
26 #include "EvtGenBase/EvtPatches.hh"
27 #include "EvtGenBase/EvtReport.hh"
29 
30 #include <math.h>
31 using std::endl;
32 
34 {
35  if ( &n == this )
36  return *this;
37  _p4_p = n._p4_p;
38  _p4_d1 = n._p4_d1;
39  _p4_d2 = n._p4_d2;
40  _ampl = n._ampl;
41  _theta = n._theta;
42  _gamma = n._gamma;
43  _spin = n._spin;
44  _bwm = n._bwm;
45  return *this;
46 }
47 
49  const EvtVector4R& p4_d2, double ampl, double theta,
50  double gamma, double bwm, int spin ) :
51  _p4_p( p4_p ),
52  _p4_d1( p4_d1 ),
53  _p4_d2( p4_d2 ),
54  _ampl( ampl ),
55  _theta( theta ),
56  _gamma( gamma ),
57  _bwm( bwm ),
58  _spin( spin )
59 {
60 }
61 
63 {
64  double pi180inv = 1.0 / EvtConst::radToDegrees;
65 
66  EvtComplex ampl;
67  //EvtVector4R _p4_d3 = _p4_p-_p4_d1-_p4_d2;
68 
69  //get cos of the angle between the daughters from their 4-momenta
70  //and the 4-momentum of the parent
71 
72  //in general, EvtDecayAngle(parent, part1+part2, part1) gives the angle
73  //the missing particle (not listed in the arguments) makes
74  //with part2 in the rest frame of both
75  //listed particles (12)
76 
77  //angle 3 makes with 2 in rest frame of 12 (CS3)
78  double cos_phi_0 = EvtDecayAngle( _p4_p, _p4_d1 + _p4_d2, _p4_d1 );
79  //angle 3 makes with 1 in 12 is, of course, -cos_phi_0
80 
81  switch ( _spin ) {
82  case 0:
83  ampl = ( _ampl *
84  EvtComplex( cos( _theta * pi180inv ),
85  sin( _theta * pi180inv ) ) *
86  sqrt( _gamma / EvtConst::twoPi ) *
87  ( 1.0 / ( ( _p4_d1 + _p4_d2 ).mass() - _bwm -
88  EvtComplex( 0.0, 0.5 * _gamma ) ) ) );
89  break;
90 
91  case 1:
92  ampl = ( _ampl *
93  EvtComplex( cos( _theta * pi180inv ),
94  sin( _theta * pi180inv ) ) *
95  sqrt( _gamma / EvtConst::twoPi ) *
96  ( cos_phi_0 / ( ( _p4_d1 + _p4_d2 ).mass() - _bwm -
97  EvtComplex( 0.0, 0.5 * _gamma ) ) ) );
98  break;
99 
100  case 2:
101  ampl = ( _ampl *
102  EvtComplex( cos( _theta * pi180inv ),
103  sin( _theta * pi180inv ) ) *
104  sqrt( _gamma / EvtConst::twoPi ) *
105  ( ( 1.5 * cos_phi_0 * cos_phi_0 - 0.5 ) /
106  ( ( _p4_d1 + _p4_d2 ).mass() - _bwm -
107  EvtComplex( 0.0, 0.5 * _gamma ) ) ) );
108  break;
109 
110  case 3:
111  ampl = ( _ampl *
112  EvtComplex( cos( _theta * pi180inv ),
113  sin( _theta * pi180inv ) ) *
114  sqrt( _gamma / EvtConst::twoPi ) *
115  ( ( 2.5 * cos_phi_0 * cos_phi_0 * cos_phi_0 -
116  1.5 * cos_phi_0 ) /
117  ( ( _p4_d1 + _p4_d2 ).mass() - _bwm -
118  EvtComplex( 0.0, 0.5 * _gamma ) ) ) );
119  break;
120 
121  default:
122  EvtGenReport( EVTGEN_DEBUG, "EvtGen" )
123  << "EvtGen: wrong spin in EvtResonance" << endl;
124  ampl = EvtComplex( 0.0 );
125  break;
126  }
127 
128  return ampl;
129 }
130 
132 {
133  //this function returns relativistic Breit-Wigner amplitude
134  //for a given resonance (for P-wave decays of scalars only at the moment!)
135 
136  EvtComplex BW;
137  EvtVector4R _p4_d3 = _p4_p - _p4_d1 - _p4_d2;
138  EvtVector4R _p4_12 = _p4_d1 + _p4_d2;
139 
140  double msq13 = ( _p4_d1 + _p4_d3 ).mass2();
141  double msq23 = ( _p4_d2 + _p4_d3 ).mass2();
142  double msqParent = _p4_p.mass2();
143  double msq1 = _p4_d1.mass2();
144  double msq2 = _p4_d2.mass2();
145  double msq3 = _p4_d3.mass2();
146 
147  double M;
148 
149  double p2 = sqrt( ( _p4_12.mass2() - ( _p4_d1.mass() + _p4_d2.mass() ) *
150  ( _p4_d1.mass() + _p4_d2.mass() ) ) *
151  ( _p4_12.mass2() - ( _p4_d1.mass() - _p4_d2.mass() ) *
152  ( _p4_d1.mass() - _p4_d2.mass() ) ) ) /
153  ( 2.0 * _p4_12.mass() );
154 
155  double p2R = sqrt( ( _bwm * _bwm - ( _p4_d1.mass() + _p4_d2.mass() ) *
156  ( _p4_d1.mass() + _p4_d2.mass() ) ) *
157  ( _bwm * _bwm - ( _p4_d1.mass() - _p4_d2.mass() ) *
158  ( _p4_d1.mass() - _p4_d2.mass() ) ) ) /
159  ( 2.0 * _bwm );
160 
161  double gam, R;
162 
163  if ( i == 1 ) {
164  R = 2.0 / ( 0.197 );
165 
166  } else
167  R = 5.0 / ( 0.197 );
168 
169  gam = _gamma * ( _bwm / _p4_12.mass() ) * ( p2 / p2R ) * ( p2 / p2R ) *
170  ( p2 / p2R ) * ( ( 1 + R * R * p2R * p2R ) / ( 1 + R * R * p2 * p2 ) );
171  M = ( msq13 - msq23 -
172  ( msqParent - msq3 ) * ( msq1 - msq2 ) / ( _bwm * _bwm ) ) *
173  sqrt( ( 1 + R * R * p2R * p2R ) / ( 1 + R * R * p2 * p2 ) );
174 
175  BW = sqrt( _gamma ) * M /
176  ( ( _bwm * _bwm - _p4_12.mass2() ) -
177  EvtComplex( 0.0, 1.0 ) * gam * _bwm );
178 
179  return BW;
180 }
EvtResonance(const EvtVector4R &p4_p, const EvtVector4R &p4_d1, const EvtVector4R &p4_d2, double ampl=0.0, double theta=0.0, double gamma=0.0, double bwm=0.0, int spin=0)
EvtResonance & operator=(const EvtResonance &)
std::ostream & EvtGenReport(EvtGenSeverity severity, const char *facility=0)
Definition: EvtReport.cpp:33
EvtComplex resAmpl()
double mass() const
Definition: EvtVector4R.cpp:49
static const double twoPi
Definition: EvtConst.hh:27
EvtVector4R _p4_d2
Definition: EvtResonance.hh:65
EvtComplex relBrWig(int i)
double mass2() const
Definition: EvtVector4R.hh:100
EvtVector4R _p4_p
Definition: EvtResonance.hh:65
double EvtDecayAngle(const EvtVector4R &, const EvtVector4R &, const EvtVector4R &)
Definition: EvtKine.cpp:33
static const double radToDegrees
Definition: EvtConst.hh:28
EvtVector4R _p4_d1
Definition: EvtResonance.hh:65