31#define PRECISION ( 1.e-3 )
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),
49 _kmatrix_index(-1),_fr12prod(0.,0.),_fr13prod(0.,0.),_fr14prod(0.,0.),_fr15prod(0.,0.),_s0prod(0.),
50 _a(0.),_r(0.),_Blass(0.),_phiB(0.),_R(0.),_phiR(0.)
56 assert(_typeN != K_MATRIX && _typeN != K_MATRIX_I && _typeN != K_MATRIX_II);
63 double m0_mix,
double g0_mix,
double delta_mix,
EvtComplex amp_mix)
70 _massFirst(dp.m(
first(pairRes))),_massSecond(dp.m(
second(pairRes))),
71 _m0_mix(m0_mix),_g0_mix(g0_mix),_delta_mix(delta_mix),_amp_mix(amp_mix),
72 _g1(-1.),_g2(-1.),_coupling2(Undefined),
73 _kmatrix_index(-1),_fr12prod(0.,0.),_fr13prod(0.,0.),_fr14prod(0.,0.),_fr15prod(0.,0.),_s0prod(0.),
74 _a(0.),_r(0.),_Blass(0.),_phiB(0.),_R(0.),_phiR(0.)
81 assert(_typeN != K_MATRIX && _typeN != K_MATRIX_I && _typeN != K_MATRIX_II);
93 _massFirst(dp.m(
first(pairRes))),_massSecond(dp.m(
second(pairRes))),
94 _m0_mix(-1.),_g0_mix(0.),_delta_mix(0.),_amp_mix(0.,0.),
95 _g1(g1),_g2(g2),_coupling2(coupling2),
96 _kmatrix_index(-1),_fr12prod(0.,0.),_fr13prod(0.,0.),_fr14prod(0.,0.),_fr15prod(0.,0.),_s0prod(0.),
97 _a(0.),_r(0.),_Blass(0.),_phiB(0.),_R(0.),_phiR(0.)
103 assert(_coupling2 != Undefined);
104 assert(_typeN != K_MATRIX && _typeN != K_MATRIX_I && _typeN != K_MATRIX_II);
105 assert(_typeN != LASS);
106 assert(_typeN != NBW);
117 _massFirst(dp.m(
first(pairRes))),_massSecond(dp.m(
second(pairRes))),
118 _m0_mix(-1.),_g0_mix(0.),_delta_mix(0.),_amp_mix(0.,0.),
119 _g1(-1.),_g2(-1.),_coupling2(Undefined),
120 _kmatrix_index(-1),_fr12prod(fr12prod),_fr13prod(fr13prod),_fr14prod(fr14prod),_fr15prod(fr15prod),_s0prod(s0prod),
121 _a(0.),_r(0.),_Blass(0.),_phiB(0.),_R(0.),_phiR(0.)
123 assert(_typeN==K_MATRIX || _typeN==K_MATRIX_I || _typeN==K_MATRIX_II);
125 if (nameIndex==
"Pole1") _kmatrix_index=1;
126 else if (nameIndex==
"Pole2") _kmatrix_index=2;
127 else if (nameIndex==
"Pole3") _kmatrix_index=3;
128 else if (nameIndex==
"Pole4") _kmatrix_index=4;
129 else if (nameIndex==
"Pole5") _kmatrix_index=5;
130 else if (nameIndex==
"f11prod") _kmatrix_index=6;
137 double m0,
double g0,
double a,
double r,
double B,
double phiB,
double R,
double phiR)
142 _massFirst(dp.m(
first(pairRes))),_massSecond(dp.m(
second(pairRes))),
143 _m0_mix(-1.),_g0_mix(0.),_delta_mix(0.),_amp_mix(0.,0.),
144 _g1(-1.),_g2(-1.),_coupling2(Undefined),
145 _kmatrix_index(-1),_fr12prod(0.,0.),_fr13prod(0.,0.),_fr14prod(0.,0.),_fr15prod(0.,0.),_s0prod(0.),
146 _a(a),_r(r),_Blass(
B),_phiB(phiB),_R(
R),_phiR(phiR)
157 _pairAng(other._pairAng),
158 _pairRes(other._pairRes),
160 _typeN(other._typeN),
161 _m0(other._m0),_g0(other._g0),
162 _vb(other._vb),_vd(other._vd),
163 _massFirst(other._massFirst),_massSecond(other._massSecond),
164 _m0_mix(other._m0_mix),_g0_mix(other._g0_mix),_delta_mix(other._delta_mix),_amp_mix(other._amp_mix),
165 _g1(other._g1),_g2(other._g2),_coupling2(other._coupling2),
166 _kmatrix_index(other._kmatrix_index),
167 _fr12prod(other._fr12prod),_fr13prod(other._fr13prod),_fr14prod(other._fr14prod),_fr15prod(other._fr15prod),
168 _s0prod(other._s0prod),
169 _a(other._a),_r(other._r),_Blass(other._Blass),_phiB(other._phiB),_R(other._R),_phiR(other._phiR)
179 double m = sqrt(
x.q(_pairRes));
183 return Fvector( m*m, _kmatrix_index );
196 prop = propBreitWigner(_m0,_g0,m);
198 prop = propGauss(_m0,_g0,m);
202 double g = (_g0<=0. || _vd.
pD()<=0.)? -_g0 : _g0*_vd.
widthFactor(vd);
205 assert(_massFirst==_massSecond);
206 prop = propGounarisSakurai(_m0,fabs(_g0),_vd.
pD(),m,g,vd.
p());
209 prop = propBreitWignerRel(_m0,g,m);
214 switch (_coupling2) {
216 G1 = _g1*_g1*psFactor(_massFirst,_massSecond,m);
218 G2 = _g2*_g2*psFactor(mPic,mPic,m);
222 G1 = _g1*_g1*psFactor(_massFirst,_massSecond,m);
224 G2 = _g2*_g2*psFactor(mPiz,mPiz,m);
228 G1 = _g1*_g1*psFactor(_massFirst,_massSecond,m);
231 G2 = _g2*_g2*psFactor(mPic,mPic,mPiz,mPiz,m);
235 G1 = _g1*_g1*psFactor(_massFirst,_massSecond,m);
237 G2 = _g2*_g2*psFactor(mKc,mKc,m);
241 G1 = _g1*_g1*psFactor(_massFirst,_massSecond,m);
243 G2 = _g2*_g2*psFactor(mKz,mKz,m);
247 G1 = _g1*_g1*psFactor(_massFirst,_massSecond,m);
250 G2 = _g2*_g2*psFactor(mKc,mKc,mKz,mKz,m);
254 G1 = _g1*_g1*psFactor(_massFirst,_massSecond,m);
257 G2 = _g2*_g2*psFactor(mEta,mPic,m);
261 G1 = _g1*_g1*psFactor(_massFirst,_massSecond,m);
264 G2 = _g2*_g2*psFactor(mEta,mPiz,m);
270 G1 = _g1*psFactor(mPic,mPic,m);
274 G2 = _g2*psFactor(mKc,mKc,mKz,mKz,m);
278 std::cout <<
"EvtDalitzReso:evaluate(): PANIC, wrong coupling2 state." << std::endl;
283 if (_coupling2 !=
WA76)
284 prop = _g1*propBreitWignerRelCoupled(_m0,G1,G2,m);
294 amp *= numerator(
x,vb,vd);
300 prop_mix = propBreitWigner(_m0_mix,_g0_mix,m);
304 prop_mix = propBreitWignerRel(_m0_mix,g_mix,m);
306 amp *= mixFactor(prop,prop_mix);
313EvtComplex EvtDalitzReso::psFactor(
double & ma,
double & mb,
double& m)
321 double phaseFactor_analyticalCont = -0.5*(sqrt(4*ma*ma/
s-1)+sqrt(4*mb*mb/
s-1));
322 return EvtComplex(phaseFactor_analyticalCont,0);
327EvtComplex EvtDalitzReso::psFactor(
double & ma1,
double & mb1,
double & ma2,
double & mb2,
double& m)
329 return 0.5*(psFactor(ma1,mb1,m)+psFactor(ma2,mb2,m));
333EvtComplex EvtDalitzReso::propGauss(
const double& m0,
const double& s0,
const double& m)
341EvtComplex EvtDalitzReso::propBreitWigner(
const double& m0,
const double& g0,
const double& m)
348EvtComplex EvtDalitzReso::propBreitWignerRel(
const double& m0,
const double& g0,
const double& m)
356EvtComplex EvtDalitzReso::propBreitWignerRel(
const double& m0,
const EvtComplex& g0,
const double& m)
366 return 1./(m0*m0-m*m-(g1+g2));
369EvtComplex EvtDalitzReso::propGounarisSakurai(
const double& m0,
const double& g0,
const double& k0,
370 const double& m,
const double& g,
const double& k)
374 return (1.+GS_d(m0,k0)*g0/m0)/(m0*m0-m*m-
EvtComplex(0.,m*g)+GS_f(m0,g0,k0,m,k));
378inline double EvtDalitzReso::GS_f(
const double& m0,
const double& g0,
const double& k0,
const double& m,
const double& k)
384 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) );
387inline double EvtDalitzReso::GS_h(
const double& m,
const double& k)
388{
return 2./
EvtConst::pi*k/m*log((m+2.*k)/(2.*_massFirst)) ;}
390inline double EvtDalitzReso::GS_dhods(
const double& m0,
const double& k0)
391{
return GS_h(m0,k0)*( 0.125/(k0*k0) - 0.5/(m0*m0) ) + 0.5/(
EvtConst::pi*m0*m0) ;}
393inline double EvtDalitzReso::GS_d(
const double& m0,
const double& k0)
394{
return 3./
EvtConst::pi*_massFirst*_massFirst/(k0*k0)*log((m0+2.*k0)/(2.*_massFirst)) +
425 ret = _m0*_m0 * angDep(x);
453 ret = qCA - qBC + (M2 - mC2)*(mB2 - mA2)/m02;
455 double x1 = qBC - qCA + (M2 - mC2)*(mA2 - mB2)/m02;
456 double x2 = M2 - mC2;
457 double x3 = qAB - 2*M2 - 2*mC2 + x2*x2/m02;
458 double x4 = mA2 - mB2;
459 double x5 = qAB - 2*mB2 - 2*mA2 + x4*x4/m02;
460 ret = x1*x1 - x3*x5/3.;
472 double cosTh =
x.cosTh(_pairAng,_pairRes);
473 if(fabs(cosTh) > 1.) {
474 report(
INFO,
"EvtGen") <<
"cosTh " << cosTh << std::endl;
485 double Delta = _delta_mix*(_m0+_m0_mix);
486 return 1/(1-Delta*Delta*prop*prop_mix)*(1+_amp_mix*Delta*prop_mix);
491EvtComplex EvtDalitzReso::Fvector(
double s,
int index )
493 assert(index>=1 && index<=6);
508 if (solution==0) { std::cout <<
"EvtDalitzReso::Fvector() error. Kmatrix solution incorrectly chosen ! " << std::endl; abort(); }
510 if (solution == 3 ) {
551 }
else if (solution == 1) {
592 }
else if (solution == 2) {
635 double rho1sq,rho2sq,rho4sq,rho5sq;
643 double metap=0.95778;
647 for(
int i=0;i<5;i++) {
648 for(
int j=0;j<5;j++) {
658 else if (solution == 1)
660 else if (solution == 2)
670 }
else if (solution == 1) {
676 }
else if (solution == 2) {
690 rho1sq = 1. - pow(
mpi +
mpi, 2 ) /
s;
696 rho2sq = 1. - pow( mK + mK, 2 ) /
s;
706 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;
707 double cont32 = sqrt(1.0-(16.0*
mpi*
mpi));
719 rho5sq = 1. - pow(
meta + metap, 2 ) /
s;
725 double smallTerm = 1;
728 for (
int pole = 0; pole < 5; pole++ )
729 if ( fabs( pow( ma[ pole ], 2 ) -
s ) <
PRECISION )
730 smallTerm = pow( ma[ pole ], 2 ) -
s;
734 for(
int i=0;i<5;i++) {
735 for(
int j=0;j<5;j++) {
736 for (
int pole_index=0;pole_index<5;pole_index++) {
737 double A=g[pole_index][i]*g[pole_index][j];
738 double B=ma[pole_index]*ma[pole_index]-
s;
743 K[ i ][ j ] +=
EvtComplex( A / B, 0 ) * smallTerm;
749 for(
int i=0;i<5;i++) {
750 for(
int j=0;j<5;j++) {
751 double C=
f[i][j]*(1.0-s_scatt);
752 double D=(
s-s_scatt);
759 for(
int i=0;i<5;i++) {
760 for(
int j=0;j<5;j++) {
761 double E=(
s-(sa*
mpi*
mpi*0.5))*(1.0-sa_0);
772 for (
int row = 0; row < 5; row++ )
773 for (
int col = 0; col < 5; col++ )
774 mat( row, col ) = ( row == col ) * smallTerm -
EvtComplex( 0., 1. ) * K[ row ][ col ] * rho[ col ];
778 vector< EvtComplex > U1j;
779 for (
int j = 0; j < 5; j++ )
780 U1j.push_back( (*matInverse)[ 0 ][ j ] );
788 for(
int j=0;j<5;j++) {
790 double bottom = ma[index-1]*ma[index-1]-
s;
795 value += top / bottom * smallTerm;
800 value += U1j[1]*_fr12prod;
801 value += U1j[2]*_fr13prod;
802 value += U1j[3]*_fr14prod;
803 value += U1j[4]*_fr15prod;
805 value *= (1-_s0prod)/(
s-_s0prod) * smallTerm;
820 double cot_deltaB = 1.0/(_a*
q) + 0.5*_r*
q;
821 double deltaB = atan( 1.0/cot_deltaB);
822 double totalB = deltaB + _phiB ;
825 double deltaR = atan((_m0*GammaM/(_m0*_m0 -
s)));
826 double totalR = deltaR + _phiR ;
double sin(const BesAngle a)
double cos(const BesAngle a)
EvtComplex exp(const EvtComplex &c)
ostream & report(Severity severity, const char *facility)
****INTEGER imax DOUBLE PRECISION m_pi *DOUBLE PRECISION m_amfin DOUBLE PRECISION m_Chfin DOUBLE PRECISION m_Xenph DOUBLE PRECISION m_sinw2 DOUBLE PRECISION m_GFermi DOUBLE PRECISION m_MfinMin DOUBLE PRECISION m_ta2 INTEGER m_out INTEGER m_KeyFSR INTEGER m_KeyQCD *COMMON c_Semalib $ !copy of input $ !CMS energy $ !beam mass $ !final mass $ !beam charge $ !final charge $ !smallest final mass $ !Z mass $ !Z width $ !EW mixing angle $ !Gmu Fermi $ alphaQED at q
***************************************************************************************Pseudo Class RRes *****************************************************************************************Parameters and physical constants **Maarten sept ************************************************************************DOUBLE PRECISION xsmu **************************************************************************PARTICLE DATA all others are from PDG *Only resonances with known widths into electron pairs are sept ************************************************************************C Declarations C
static const double twoPi
double m(EvtCyclic3::Index i) const
EvtComplex evaluate(const EvtDalitzPoint &p)
static double getMass(EvtId i)
static EvtId getId(const std::string &name)
static int getSpin2(spintype stype)
double p(Index i=AB) const
double formFactor(EvtTwoBodyKine x) const
double widthFactor(EvtTwoBodyKine x) const
double phaseSpaceFactor(EvtTwoBodyKine x, EvtTwoBodyKine::Index) const
static double d(int j, int m1, int m2, double theta)
TFile f("ana_bhabha660a_dqa_mcPat_zy_old.root")
Index common(Pair i, Pair j)
Pair combine(Index i, Index j)
Index other(Index i, Index j)
complex_t R(double Q2, double M2, double G, double Mp2, double Mm2)