1 #include "EvtGenBase/EvtPatches.hh"
2 /*****************************************************************************
3 * Project: BaBar detector at the SLAC PEP-II B-factory
5 * File: $Id: EvtDalitzReso.cpp,v 1.1 2009-03-16 16:47:51 robbep Exp $
8 * Class to compute Dalitz amplitudes based on many models that cannot be
9 * handled with EvtResonance.
11 * Modification history:
12 * Jordi Garra Ticó 2008/07/03 File created
13 *****************************************************************************/
21 #include "EvtGenBase/EvtParticle.hh"
22 #include "EvtGenBase/EvtGenKine.hh"
23 #include "EvtGenBase/EvtPDL.hh"
24 #include "EvtGenBase/EvtReport.hh"
25 #include "EvtGenBase/EvtMatrix.hh"
26 #include "EvtGenBase/EvtDalitzReso.hh"
28 #include "EvtGenBase/EvtdFunction.hh"
29 #include "EvtGenBase/EvtCyclic3.hh"
31 #define PRECISION ( 1.e-3 )
33 using EvtCyclic3::Index;
34 using EvtCyclic3::Pair;
37 // single Breit-Wigner
38 EvtDalitzReso::EvtDalitzReso(const EvtDalitzPlot& dp, Pair pairAng, Pair pairRes,
39 EvtSpinType::spintype spin, double m0, double g0, NumType typeN, double f_b, double f_d)
46 _massFirst(dp.m(first(pairRes))),_massSecond(dp.m(second(pairRes))),
47 _m0_mix(-1.),_g0_mix(0.),_delta_mix(0.),_amp_mix(0.,0.),
48 _g1(-1.),_g2(-1.),_coupling2(Undefined),
50 _kmatrix_index(-1),_fr12prod(0.,0.),_fr13prod(0.,0.),_fr14prod(0.,0.),_fr15prod(0.,0.),_s0prod(0.),
51 _a(0.),_r(0.),_Blass(0.),_phiB(0.),_R(0.),_phiR(0.),_cutoff(-1.), _scaleByMOverQ(false),
54 _vb = EvtTwoBodyVertex(_m0,_dp.m(EvtCyclic3::other(_pairRes)),_dp.bigM(),_spin);
55 _vd = EvtTwoBodyVertex(_massFirst,_massSecond,_m0,_spin);
56 _vb.set_f( _f_b ); // Default values for Blatt-Weisskopf factors are 0.0 and 1.5.
58 assert(_typeN != K_MATRIX && _typeN != K_MATRIX_I && _typeN != K_MATRIX_II); // single BW cannot be K-matrix
62 // Breit-Wigner with electromagnetic mass mixing
63 EvtDalitzReso::EvtDalitzReso(const EvtDalitzPlot& dp, Pair pairAng, Pair pairRes,
64 EvtSpinType::spintype spin, double m0, double g0, NumType typeN,
65 double m0_mix, double g0_mix, double delta_mix, EvtComplex amp_mix)
72 _massFirst(dp.m(first(pairRes))),_massSecond(dp.m(second(pairRes))),
73 _m0_mix(m0_mix),_g0_mix(g0_mix),_delta_mix(delta_mix),_amp_mix(amp_mix),
74 _g1(-1.),_g2(-1.),_coupling2(Undefined),
76 _kmatrix_index(-1),_fr12prod(0.,0.),_fr13prod(0.,0.),_fr14prod(0.,0.),_fr15prod(0.,0.),_s0prod(0.),
77 _a(0.),_r(0.),_Blass(0.),_phiB(0.),_R(0.),_phiR(0.),_cutoff(-1.), _scaleByMOverQ(false),
80 _vb = EvtTwoBodyVertex(_m0,_dp.m(EvtCyclic3::other(_pairRes)),_dp.bigM(),_spin);
81 _vd = EvtTwoBodyVertex(_massFirst,_massSecond,_m0,_spin);
82 _vb.set_f( 0.0 ); // Default values for Blatt-Weisskopf factors.
84 // single BW (with electromagnetic mixing) cannot be K-matrix
85 assert(_typeN != K_MATRIX && _typeN != K_MATRIX_I && _typeN != K_MATRIX_II);
88 // coupled Breit-Wigner
89 EvtDalitzReso::EvtDalitzReso(const EvtDalitzPlot& dp, Pair pairAng, Pair pairRes,
90 EvtSpinType::spintype spin, double m0, NumType typeN, double g1, double g2, CouplingType coupling2)
97 _massFirst(dp.m(first(pairRes))),_massSecond(dp.m(second(pairRes))),
98 _m0_mix(-1.),_g0_mix(0.),_delta_mix(0.),_amp_mix(0.,0.),
99 _g1(g1),_g2(g2),_coupling2(coupling2),
100 _f_b(0.0), _f_d(1.5),
101 _kmatrix_index(-1),_fr12prod(0.,0.),_fr13prod(0.,0.),_fr14prod(0.,0.),_fr15prod(0.,0.),_s0prod(0.),
102 _a(0.),_r(0.),_Blass(0.),_phiB(0.),_R(0.),_phiR(0.),_cutoff(-1.), _scaleByMOverQ(false),
105 _vb = EvtTwoBodyVertex(_m0,_dp.m(EvtCyclic3::other(_pairRes)),_dp.bigM(),_spin);
106 _vd = EvtTwoBodyVertex(_massFirst,_massSecond,_m0,_spin);
107 _vb.set_f( 0.0 ); // Default values for Blatt-Weisskopf factors.
109 assert(_coupling2 != Undefined);
110 assert(_typeN != K_MATRIX && _typeN != K_MATRIX_I && _typeN != K_MATRIX_II); // coupled BW cannot be K-matrix
111 assert(_typeN != LASS); // coupled BW cannot be LASS
112 assert(_typeN != NBW); // for coupled BW, only relativistic BW
117 EvtDalitzReso::EvtDalitzReso(const EvtDalitzPlot& dp, Pair pairRes, std::string nameIndex, NumType typeN,
118 EvtComplex fr12prod, EvtComplex fr13prod, EvtComplex fr14prod, EvtComplex fr15prod, double s0prod)
123 _massFirst(dp.m(first(pairRes))),_massSecond(dp.m(second(pairRes))),
124 _m0_mix(-1.),_g0_mix(0.),_delta_mix(0.),_amp_mix(0.,0.),
125 _g1(-1.),_g2(-1.),_coupling2(Undefined),
127 _kmatrix_index(-1),_fr12prod(fr12prod),_fr13prod(fr13prod),_fr14prod(fr14prod),_fr15prod(fr15prod),_s0prod(s0prod),
128 _a(0.),_r(0.),_Blass(0.),_phiB(0.),_R(0.),_phiR(0.),_cutoff(-1.), _scaleByMOverQ(false),
131 assert(_typeN==K_MATRIX || _typeN==K_MATRIX_I || _typeN==K_MATRIX_II);
132 _spin=EvtSpinType::SCALAR;
133 if (nameIndex=="Pole1") _kmatrix_index=1;
134 else if (nameIndex=="Pole2") _kmatrix_index=2;
135 else if (nameIndex=="Pole3") _kmatrix_index=3;
136 else if (nameIndex=="Pole4") _kmatrix_index=4;
137 else if (nameIndex=="Pole5") _kmatrix_index=5;
138 else if (nameIndex=="f11prod") _kmatrix_index=6;
143 // LASS parameterization
144 EvtDalitzReso::EvtDalitzReso(const EvtDalitzPlot& dp, Pair pairRes,
145 double m0, double g0, double a, double r, double B, double phiB, double R, double phiR, double cutoff, bool scaleByMOverQ)
150 _massFirst(dp.m(first(pairRes))),_massSecond(dp.m(second(pairRes))),
151 _m0_mix(-1.),_g0_mix(0.),_delta_mix(0.),_amp_mix(0.,0.),
152 _g1(-1.),_g2(-1.),_coupling2(Undefined),
153 _f_b(0.0), _f_d(1.5),
154 _kmatrix_index(-1),_fr12prod(0.,0.),_fr13prod(0.,0.),_fr14prod(0.,0.),_fr15prod(0.,0.),_s0prod(0.),
155 _a(a),_r(r),_Blass(B),_phiB(phiB),_R(R),_phiR(phiR), _cutoff(cutoff), _scaleByMOverQ(scaleByMOverQ),
158 _spin=EvtSpinType::SCALAR;
159 _vd = EvtTwoBodyVertex(_massFirst,_massSecond,_m0,_spin);
160 _vd.set_f( 1.5 ); // Default values for Blatt-Weisskopf factors.
165 EvtDalitzReso::EvtDalitzReso(const EvtDalitzPlot& dp, EvtCyclic3::Pair pairRes, double m0)
170 _massFirst(dp.m(first(pairRes))),_massSecond(dp.m(second(pairRes))),
171 _m0_mix(-1.),_g0_mix(0.),_delta_mix(0.),_amp_mix(0.,0.),
172 _g1(-1.),_g2(-1.),_coupling2(Undefined),
174 _kmatrix_index(-1),_fr12prod(0.,0.),_fr13prod(0.,0.),_fr14prod(0.,0.),_fr15prod(0.,0.),_s0prod(0.),
175 _a(0.),_r(0.),_Blass(0.),_phiB(0.),_R(0.),_phiR(0.),_cutoff(-1.), _scaleByMOverQ(false),
178 _spin=EvtSpinType::SCALAR;
182 EvtDalitzReso::EvtDalitzReso(const EvtDalitzReso& other)
184 _pairAng(other._pairAng),
185 _pairRes(other._pairRes),
187 _typeN(other._typeN),
188 _m0(other._m0),_g0(other._g0),
189 _vb(other._vb),_vd(other._vd),
190 _massFirst(other._massFirst),_massSecond(other._massSecond),
191 _m0_mix(other._m0_mix),_g0_mix(other._g0_mix),_delta_mix(other._delta_mix),_amp_mix(other._amp_mix),
192 _g1(other._g1),_g2(other._g2),_coupling2(other._coupling2),
193 _f_b(other._f_b), _f_d(other._f_d),
194 _kmatrix_index(other._kmatrix_index),
195 _fr12prod(other._fr12prod),_fr13prod(other._fr13prod),_fr14prod(other._fr14prod),_fr15prod(other._fr15prod),
196 _s0prod(other._s0prod),
197 _a(other._a),_r(other._r),_Blass(other._Blass),_phiB(other._phiB),_R(other._R),_phiR(other._phiR),_cutoff(other._cutoff), _scaleByMOverQ(other._scaleByMOverQ),
198 _alpha(other._alpha),
199 _flatteParams(other._flatteParams)
203 EvtDalitzReso::~EvtDalitzReso()
207 EvtComplex EvtDalitzReso::evaluate(const EvtDalitzPoint& x)
209 double m = sqrt(x.q(_pairRes));
212 return EvtComplex(1.0,0.0);
214 if (_typeN==NON_RES_LIN)
217 if (_typeN==NON_RES_EXP)
218 return exp(-_alpha*m*m);
220 // do use always hash table (speed up fitting)
221 if (_typeN==K_MATRIX || _typeN==K_MATRIX_I || _typeN==K_MATRIX_II)
222 return Fvector( m*m, _kmatrix_index );
230 EvtComplex amp(1.0,0.0);
232 if (fabs(_dp.bigM() - x.bigM()) > 0.000001) {
233 _vb = EvtTwoBodyVertex(_m0,_dp.m(EvtCyclic3::other(_pairRes)),x.bigM(),_spin);
236 EvtTwoBodyKine vb(m,x.m(EvtCyclic3::other(_pairRes)),x.bigM());
237 EvtTwoBodyKine vd(_massFirst,_massSecond,m);
239 EvtComplex prop(0,0);
241 prop = propBreitWigner(_m0,_g0,m);
242 } else if (_typeN==GAUSS_CLEO || _typeN==GAUSS_CLEO_ZEMACH) {
243 prop = propGauss(_m0,_g0,m);
245 if (_coupling2==Undefined) {
247 double g = (_g0<=0. || _vd.pD()<=0.)? -_g0 : _g0*_vd.widthFactor(vd); // running width
248 if (_typeN==GS_CLEO || _typeN==GS_CLEO_ZEMACH) {
249 // Gounaris-Sakurai (GS)
250 assert(_massFirst==_massSecond);
251 prop = propGounarisSakurai(_m0,fabs(_g0),_vd.pD(),m,g,vd.p());
253 // standard relativistic BW
254 prop = propBreitWignerRel(_m0,g,m);
259 switch (_coupling2) {
261 G1 = _g1*_g1*psFactor(_massFirst,_massSecond,m);
262 static double mPic = EvtPDL::getMass( EvtPDL::getId( "pi+" ) );
263 G2 = _g2*_g2*psFactor(mPic,mPic,m);
267 G1 = _g1*_g1*psFactor(_massFirst,_massSecond,m);
268 static double mPiz = EvtPDL::getMass( EvtPDL::getId( "pi0" ) );
269 G2 = _g2*_g2*psFactor(mPiz,mPiz,m);
273 G1 = _g1*_g1*psFactor(_massFirst,_massSecond,m);
274 static double mPic = EvtPDL::getMass( EvtPDL::getId( "pi+" ) );
275 static double mPiz = EvtPDL::getMass( EvtPDL::getId( "pi0" ) );
276 G2 = _g2*_g2*psFactor(mPic,mPic,mPiz,mPiz,m);
280 G1 = _g1*_g1*psFactor(_massFirst,_massSecond,m);
281 static double mKc = EvtPDL::getMass( EvtPDL::getId( "K+" ) );
282 G2 = _g2*_g2*psFactor(mKc,mKc,m);
286 G1 = _g1*_g1*psFactor(_massFirst,_massSecond,m);
287 static double mKz = EvtPDL::getMass( EvtPDL::getId( "K0" ) );
288 G2 = _g2*_g2*psFactor(mKz,mKz,m);
292 G1 = _g1*_g1*psFactor(_massFirst,_massSecond,m);
293 static double mKc = EvtPDL::getMass( EvtPDL::getId( "K+" ) );
294 static double mKz = EvtPDL::getMass( EvtPDL::getId( "K0" ) );
295 G2 = _g2*_g2*psFactor(mKc,mKc,mKz,mKz,m);
299 G1 = _g1*_g1*psFactor(_massFirst,_massSecond,m);
300 static double mEta = EvtPDL::getMass( EvtPDL::getId( "eta" ) );
301 static double mPic = EvtPDL::getMass( EvtPDL::getId( "pi+" ) );
302 G2 = _g2*_g2*psFactor(mEta,mPic,m);
306 G1 = _g1*_g1*psFactor(_massFirst,_massSecond,m);
307 static double mEta = EvtPDL::getMass( EvtPDL::getId( "eta" ) );
308 static double mPiz = EvtPDL::getMass( EvtPDL::getId( "pi0" ) );
309 G2 = _g2*_g2*psFactor(mEta,mPiz,m);
313 static double mPic = EvtPDL::getMass( EvtPDL::getId( "pi+" ) );
314 //G1 = _g1*_g1*psFactor(mPic,mPic,m);
315 G1 = _g1*psFactor(mPic,mPic,m);
316 static double mKc = EvtPDL::getMass( EvtPDL::getId( "K+" ) );
317 static double mKz = EvtPDL::getMass( EvtPDL::getId( "K0" ) );
318 //G2 = _g2*_g2*psFactor(mKc,mKc,mKz,mKz,m);
319 G2 = _g2*psFactor(mKc,mKc,mKz,mKz,m);
323 std::cout << "EvtDalitzReso:evaluate(): PANIC, wrong coupling2 state." << std::endl;
327 // calculate standard couple BW propagator
328 if (_coupling2 != WA76)
329 prop = _g1*propBreitWignerRelCoupled(_m0,G1,G2,m);
334 // Compute form-factors (Blatt-Weisskopf penetration factor)
335 amp *= _vb.formFactor(vb);
336 amp *= _vd.formFactor(vd);
338 // Compute numerator (angular distribution)
339 amp *= numerator(x,vb,vd);
341 // Compute electromagnetic mass mixing factor
345 prop_mix = propBreitWigner(_m0_mix,_g0_mix,m);
347 assert(_g1<0.); // running width only
348 double g_mix = _g0_mix*_vd.widthFactor(vd);
349 prop_mix = propBreitWignerRel(_m0_mix,g_mix,m);
351 amp *= mixFactor(prop,prop_mix);
358 EvtComplex EvtDalitzReso::psFactor(double & ma, double & mb, double& m)
361 EvtTwoBodyKine vd(ma,mb,m);
362 return EvtComplex(0,2*vd.p()/m);
364 // analytical continuation
366 double phaseFactor_analyticalCont = -0.5*(sqrt(4*ma*ma/s-1)+sqrt(4*mb*mb/s-1));
367 return EvtComplex(phaseFactor_analyticalCont,0);
372 EvtComplex EvtDalitzReso::psFactor(double & ma1,double & mb1, double & ma2, double & mb2, double& m)
374 return 0.5*(psFactor(ma1,mb1,m)+psFactor(ma2,mb2,m));
378 EvtComplex EvtDalitzReso::propGauss(const double& m0, const double& s0, const double& m)
381 double gauss = 1./sqrt(EvtConst::twoPi)/s0*exp(-(m-m0)*(m-m0)/2./(s0*s0));
382 return EvtComplex(gauss,0.);
386 EvtComplex EvtDalitzReso::propBreitWigner(const double& m0, const double& g0, const double& m)
388 // non-relativistic BW
389 return sqrt(g0/EvtConst::twoPi)/(m-m0-EvtComplex(0.0,g0/2.));
393 EvtComplex EvtDalitzReso::propBreitWignerRel(const double& m0, const double& g0, const double& m)
395 // relativistic BW with real width
396 return 1./(m0*m0-m*m-EvtComplex(0.,m0*g0));
401 EvtComplex EvtDalitzReso::propBreitWignerRel(const double& m0, const EvtComplex& g0, const double& m)
403 // relativistic BW with complex width
404 return 1./(m0*m0-m*m-EvtComplex(0.,m0)*g0);
408 EvtComplex EvtDalitzReso::propBreitWignerRelCoupled(const double& m0, const EvtComplex& g1, const EvtComplex& g2, const double& m)
410 // relativistic coupled BW
411 return 1./(m0*m0-m*m-(g1+g2));
414 EvtComplex EvtDalitzReso::propGounarisSakurai(const double& m0, const double& g0, const double& k0,
415 const double& m, const double& g, const double& k)
417 // Gounaris-Sakurai parameterization of pi+pi- P wave. PRD, Vol61, 112002. PRL, Vol21, 244.
418 // Expressions taken from BAD637v4, after fixing the imaginary part of the BW denominator: i M_R Gamma_R(s) --> i sqrt(s) Gamma_R(s)
419 return (1.+GS_d(m0,k0)*g0/m0)/(m0*m0-m*m-EvtComplex(0.,m*g)+GS_f(m0,g0,k0,m,k));
423 inline double EvtDalitzReso::GS_f(const double& m0, const double& g0, const double& k0, const double& m, const double& k)
426 // m0: nominal resonance mass
427 // k: momentum of pion in resonance rest frame (at m)
428 // k0: momentum of pion in resonance rest frame (at nominal resonance mass)
429 return g0*m0*m0/(k0*k0*k0)*( k*k*(GS_h(m,k)-GS_h(m0,k0)) + (m0*m0-m*m)*k0*k0*GS_dhods(m0,k0) );
432 inline double EvtDalitzReso::GS_h(const double& m, const double& k)
433 {return 2./EvtConst::pi*k/m*log((m+2.*k)/(2.*_massFirst)) ;}
435 inline double EvtDalitzReso::GS_dhods(const double& m0, const double& k0)
436 {return GS_h(m0,k0)*( 0.125/(k0*k0) - 0.5/(m0*m0) ) + 0.5/(EvtConst::pi*m0*m0) ;}
438 inline double EvtDalitzReso::GS_d(const double& m0, const double& k0)
439 {return 3./EvtConst::pi*_massFirst*_massFirst/(k0*k0)*log((m0+2.*k0)/(2.*_massFirst)) +
440 m0/(2.*EvtConst::pi*k0) - _massFirst*_massFirst*m0/(EvtConst::pi*k0*k0*k0) ;}
443 EvtComplex EvtDalitzReso::numerator(const EvtDalitzPoint& x, const EvtTwoBodyKine& vb, const EvtTwoBodyKine& vd)
445 EvtComplex ret(0.,0.);
447 // Non-relativistic Breit-Wigner
452 // Standard relativistic Zemach propagator
453 else if(RBW_ZEMACH == _typeN) {
454 ret = _vd.phaseSpaceFactor(vd,EvtTwoBodyKine::AB)*angDep(x);
457 // Standard relativistic Zemach propagator
458 else if(RBW_ZEMACH2 == _typeN) {
459 ret = _vd.phaseSpaceFactor(vd,EvtTwoBodyKine::AB)*_vb.phaseSpaceFactor(vb,EvtTwoBodyKine::AB)*angDep(x);
460 if(_spin == EvtSpinType::VECTOR) {
462 } else if(_spin == EvtSpinType::TENSOR) {
464 } else if(_spin != EvtSpinType::SCALAR)
468 // Kuehn-Santamaria normalization:
469 else if(RBW_KUEHN == _typeN) {
470 ret = _m0*_m0 * angDep(x);
474 else if( ( RBW_CLEO == _typeN ) || ( GS_CLEO == _typeN ) ||
475 ( RBW_CLEO_ZEMACH == _typeN ) || ( GS_CLEO_ZEMACH == _typeN ) ||
476 ( GAUSS_CLEO == _typeN ) || ( GAUSS_CLEO_ZEMACH == _typeN)) {
478 Index iA = other(_pairAng); // A = other(BC)
479 Index iB = common(_pairRes,_pairAng); // B = common(AB,BC)
480 Index iC = other(_pairRes); // C = other(AB)
486 double qAB = x.q(combine(iA,iB));
487 double qBC = x.q(combine(iB,iC));
488 double qCA = x.q(combine(iC,iA));
491 double m02 = ((RBW_CLEO_ZEMACH == _typeN)||(GS_CLEO_ZEMACH == _typeN)||(GAUSS_CLEO_ZEMACH == _typeN))? qAB : _m0*_m0;
496 if (_spin == EvtSpinType::SCALAR) ret = EvtComplex(1.,0.);
497 else if(_spin == EvtSpinType::VECTOR) {
498 ret = qCA - qBC + (M2 - mC2)*(mB2 - mA2)/m02;
499 } else if(_spin == EvtSpinType::TENSOR) {
500 double x1 = qBC - qCA + (M2 - mC2)*(mA2 - mB2)/m02;
501 double x2 = M2 - mC2;
502 double x3 = qAB - 2*M2 - 2*mC2 + x2*x2/m02;
503 double x4 = mA2 - mB2;
504 double x5 = qAB - 2*mB2 - 2*mA2 + x4*x4/m02;
505 ret = x1*x1 - x3*x5/3.;
513 double EvtDalitzReso::angDep(const EvtDalitzPoint& x)
515 // Angular dependece for factorizable amplitudes
516 // unphysical cosines indicate we are in big trouble
517 double cosTh = x.cosTh(_pairAng,_pairRes); // angle between common(reso,ang) and other(reso)
518 if(fabs(cosTh) > 1.) {
519 report(INFO,"EvtGen") << "cosTh " << cosTh << std::endl;
523 // in units of half-spin
524 return EvtdFunction::d(EvtSpinType::getSpin2(_spin),2*0,2*0,acos(cosTh));
528 EvtComplex EvtDalitzReso::mixFactor(EvtComplex prop, EvtComplex prop_mix)
530 double Delta = _delta_mix*(_m0+_m0_mix);
531 return 1/(1-Delta*Delta*prop*prop_mix)*(1+_amp_mix*Delta*prop_mix);
536 EvtComplex EvtDalitzReso::Fvector( double s, int index )
538 assert(index>=1 && index<=6);
540 //Define the complex coupling constant
541 //The convection is as follow
547 //The first index is the resonace-pole index
549 double g[5][5]; // Coupling constants. The first index is the pole index. The second index is the decay channel
550 double ma[5]; // Pole masses. The unit is in GeV
552 int solution = (_typeN==K_MATRIX)? 3 : ( (_typeN==K_MATRIX_I)? 1 : ( (_typeN==K_MATRIX_II)? 2 : 0 ) ) ;
553 if (solution==0) { std::cout << "EvtDalitzReso::Fvector() error. Kmatrix solution incorrectly chosen ! " << std::endl; abort(); }
555 if (solution == 3 ) {
557 // coupling constants
596 } else if (solution == 1) { // solnI.txt
598 // coupling constants
637 } else if (solution == 2) { // solnIIa.txt
639 // coupling constants
679 //Now define the K-matrix pole
680 double rho1sq,rho2sq,rho4sq,rho5sq;
684 //Initalize the mass of the resonance
686 double mK=0.493677; //using charged K value
687 double meta=0.54775; //using PDG value
688 double metap=0.95778; //using PDG value
690 //Initialize the matrix to value zero
692 for(int i=0;i<5;i++) {
693 for(int j=0;j<5;j++) {
694 K[i][j]=EvtComplex(0,0);
699 //Input the _f[i][j] scattering data
703 else if (solution == 1)
705 else if (solution == 2)
710 f[0][0]=0.23399; // f^scatt
715 }else if (solution == 1) {
716 f[0][0]=0.04214; // f^scatt
721 }else if (solution == 2) {
722 f[0][0]=0.26447; // f^scatt
733 //Now construct the phase-space factor
734 //For eta-eta' there is no difference term
735 rho1sq = 1. - pow( mpi + mpi, 2 ) / s; //pi+ pi- phase factor
737 rho[ 0 ] = EvtComplex( sqrt( rho1sq ), 0 );
739 rho[ 0 ] = EvtComplex( 0, sqrt( -rho1sq ) );
741 rho2sq = 1. - pow( mK + mK, 2 ) / s;
743 rho[ 1 ] = EvtComplex( sqrt( rho2sq ), 0 );
745 rho[ 1 ] = EvtComplex( 0, sqrt( -rho2sq ) );
747 //using the A&S 4pi phase space Factor:
751 double real = 1.2274 + .00370909 / ( s * s ) - .111203 / s - 6.39017 * s + 16.8358*s*s - 21.8845*s*s*s + 11.3153*s*s*s*s;
752 double cont32 = sqrt(1.0-(16.0*mpi*mpi));
753 rho[ 2 ] = EvtComplex( cont32 * real, 0 );
756 rho[ 2 ] = EvtComplex( sqrt( 1. - 16. * mpi * mpi / s ), 0 );
758 rho4sq = 1. - pow( meta + meta, 2 ) / s;
760 rho[ 3 ] = EvtComplex( sqrt( rho4sq ), 0 );
762 rho[ 3 ] = EvtComplex( 0, sqrt( -rho4sq ) );
764 rho5sq = 1. - pow( meta + metap, 2 ) / s;
766 rho[ 4 ] = EvtComplex( sqrt( rho5sq ), 0 );
768 rho[ 4 ] = EvtComplex( 0, sqrt( -rho5sq ) );
770 double smallTerm = 1; // Factor to prevent divergences.
772 // Check if some pole may arise problems.
773 for ( int pole = 0; pole < 5; pole++ )
774 if ( fabs( pow( ma[ pole ], 2 ) - s ) < PRECISION )
775 smallTerm = pow( ma[ pole ], 2 ) - s;
777 //now sum all the pole
778 //equation (3) in the E791 K-matrix paper
779 for(int i=0;i<5;i++) {
780 for(int j=0;j<5;j++) {
781 for (int pole_index=0;pole_index<5;pole_index++) {
782 double A=g[pole_index][i]*g[pole_index][j];
783 double B=ma[pole_index]*ma[pole_index]-s;
785 if ( fabs( B ) < PRECISION )
786 K[ i ][ j ] += EvtComplex( A , 0 );
788 K[ i ][ j ] += EvtComplex( A / B, 0 ) * smallTerm;
793 //now add the SVT part
794 for(int i=0;i<5;i++) {
795 for(int j=0;j<5;j++) {
796 double C=f[i][j]*(1.0-s_scatt);
797 double D=(s-s_scatt);
798 K[ i ][ j ] += EvtComplex( C / D, 0 ) * smallTerm;
802 //Fix the bug in the FOCUS paper
803 //Include the Alder zero term:
804 for(int i=0;i<5;i++) {
805 for(int j=0;j<5;j++) {
806 double E=(s-(sa*mpi*mpi*0.5))*(1.0-sa_0);
808 K[ i ][ j ] *= EvtComplex(E/F,0);
812 //This is not correct!
814 static EvtMatrix< EvtComplex > mat;
815 mat.setRange( 5 ); // Try to do in only the first time. DEFINE ALLOCATION IN CONSTRUCTOR.
817 for ( int row = 0; row < 5; row++ )
818 for ( int col = 0; col < 5; col++ )
819 mat( row, col ) = ( row == col ) * smallTerm - EvtComplex( 0., 1. ) * K[ row ][ col ] * rho[ col ];
822 EvtMatrix< EvtComplex >* matInverse = mat.inverse(); //The 1st row of the inverse matrix. This matrix is {(I-iKp)^-1}_0j
823 vector< EvtComplex > U1j;
824 for ( int j = 0; j < 5; j++ )
825 U1j.push_back( (*matInverse)[ 0 ][ j ] );
829 //this calculates final F0 factor
830 EvtComplex value( 0, 0 );
832 //this calculates the beta_idx Factors
833 for(int j=0;j<5;j++) { // sum for 5 channel
834 EvtComplex top = U1j[j]*g[index-1][j];
835 double bottom = ma[index-1]*ma[index-1]-s;
837 if ( fabs( bottom ) < PRECISION )
840 value += top / bottom * smallTerm;
843 //this calculates fprod Factors
845 value += U1j[1]*_fr12prod;
846 value += U1j[2]*_fr13prod;
847 value += U1j[3]*_fr14prod;
848 value += U1j[4]*_fr15prod;
850 value *= (1-_s0prod)/(s-_s0prod) * smallTerm;
857 //replace Breit-Wigner with LASS
858 EvtComplex EvtDalitzReso::lass(double s)
860 EvtTwoBodyKine vd(_massFirst,_massSecond, sqrt(s));
862 double GammaM = _g0*_vd.widthFactor(vd); // running width;
864 //calculate the background phase motion
865 double cot_deltaB = 1.0/(_a*q) + 0.5*_r*q;
866 double deltaB = atan( 1.0/cot_deltaB);
867 double totalB = deltaB + _phiB ;
869 //calculate the resonant phase motion
870 double deltaR = atan((_m0*GammaM/(_m0*_m0 - s)));
871 double totalR = deltaR + _phiR ;
874 EvtComplex bkgB,resT;
875 bkgB = EvtComplex(_Blass*sin(totalB),0)*EvtComplex(cos(totalB),sin(totalB));
876 resT = EvtComplex(_R*sin(deltaR),0)*EvtComplex(cos(totalR),sin(totalR))*EvtComplex(cos(2*totalB),sin(2*totalB));
879 if(_cutoff>0 && sqrt(s)>_cutoff) T = resT;
880 else T = bkgB + resT;
882 if(_scaleByMOverQ) T*=(sqrt(s)/q);
888 EvtComplex EvtDalitzReso::flatte(const double& m) {
892 for (vector<EvtFlatteParam>::const_iterator param = _flatteParams.begin();
893 param != _flatteParams.end();
895 double m1 = (*param).m1(); double m2 = (*param).m2();
896 double g = (*param).g();
897 w += (g*g*sqrtCplx((1-((m1-m2)*(m1-m2))/(m*m))*(1-((m1+m2)*(m1+m2))/(m*m))));
900 EvtComplex denom = _m0*_m0 - m*m - EvtComplex(0,1)*w;
902 return EvtComplex(1.0,0.0)/denom;