37 model_name=
"DsToKKpipi0";
57 phi[1] = -1.45750737501177241029;
58 phi[2] = 1.45694587813248066510;
59 phi[3] = -2.14539596963664980223;
60 phi[4] = -0.51808334601975225553;
61 phi[5] = -1.56645961468228378521;
62 phi[6] = 1.87207969874086810336;
63 phi[7] = -0.92156758917410819265;
64 phi[8] = -0.92156758917410819265;
65 phi[9] = 0.61333399627627738226;
66 phi[10] = 2.95348100053888362737;
67 phi[11] = 2.12806871473955627749;
68 phi[12] = 2.12806871473955627749;
70 phi[13] = 2.14745266587422545257;
71 phi[14] = -0.25044816999225272269;
72 phi[15] = -0.25044816999225272269;
73 phi[16] = 1.52246676387907431405;
74 phi[17] = 1.52246676387907431405;
76 rho[1] = 0.14853586409145513869;
77 rho[2] = 0.06437581911225187525;
78 rho[3] = 0.63500586659756663721;
79 rho[4] = 0.11892962207932455954;
80 rho[5] = 0.06386739319734147102;
81 rho[6] = 1.72035932015034198628;
82 rho[7] = 0.84266300186759934832;
83 rho[8] = 0.84266300186759934832;
84 rho[9] = 5.52084783967448444741;
85 rho[10] = 1.18304173083694408319;
86 rho[11] = 0.37041606275538363491;
87 rho[12] = 0.37041606275538363491;
89 rho[13] = 1.99906320501213841112;
90 rho[14] = 0.28474658039299072243;
91 rho[15] = 0.28474658039299072243;
92 rho[16] = 0.10589240624900675414;
93 rho[17] = 0.10589240624900675414;
137 width1[0] = 0.004249;
138 width1[1] = 0.004249;
139 width1[2] = 0.004249;
207 mass_Pion_N = 0.134977;
217 int GG[4][4] = { {1,0,0,0}, {0,-1,0,0}, {0,0,-1,0}, {0,0,0,-1} };
219 { { {{0,0,0,0}, {0,0,0,0}, {0,0,0,0}, {0,0,0,0} },
220 {{0,0,0,0}, {0,0,0,0}, {0,0,0,1}, {0,0,-1,0}},
221 {{0,0,0,0}, {0,0,0,-1}, {0,0,0,0}, {0,1,0,0} },
222 {{0,0,0,0}, {0,0,1,0}, {0,-1,0,0}, {0,0,0,0} } },
223 { {{0,0,0,0}, {0,0,0,0}, {0,0,0,-1}, {0,0,1,0} },
224 {{0,0,0,0}, {0,0,0,0}, {0,0,0,0}, {0,0,0,0} },
225 {{0,0,0,1}, {0,0,0,0}, {0,0,0,0}, {-1,0,0,0}},
226 {{0,0,-1,0}, {0,0,0,0}, {1,0,0,0}, {0,0,0,0} } },
227 { {{0,0,0,0}, {0,0,0,1}, {0,0,0,0}, {0,-1,0,0}},
228 {{0,0,0,-1}, {0,0,0,0}, {0,0,0,0}, {1,0,0,0} },
229 {{0,0,0,0}, {0,0,0,0}, {0,0,0,0}, {0,0,0,0} },
230 {{0,1,0,0}, {-1,0,0,0}, {0,0,0,0}, {0,0,0,0} } },
231 { {{0,0,0,0}, {0,0,-1,0}, {0,1,0,0}, {0,0,0,0} },
232 {{0,0,1,0}, {0,0,0,0}, {-1,0,0,0}, {0,0,0,0} },
233 {{0,-1,0,0}, {1,0,0,0}, {0,0,0,0}, {0,0,0,0} },
234 {{0,0,0,0}, {0,0,0,0}, {0,0,0,0}, {0,0,0,0} } } };
235 for (
int i=0; i<4; i++) {
236 for (
int j=0; j<4; j++) {
238 for (
int k=0; k<4; k++) {
239 for (
int l=0; l<4; l++) {
240 E[i][j][k][l] = EE[i][j][k][l];
289 double Km[4],Kp[4], Pip[4],
Pi0[4];
290 Km[0] = km.
get(0); Kp[0] = kp.
get(0); Pip[0] = pip.
get(0);
Pi0[0] = pi0.
get(0);
291 Km[1] = km.
get(1); Kp[1] = kp.
get(1); Pip[1] = pip.
get(1);
Pi0[1] = pi0.
get(1);
292 Km[2] = km.
get(2); Kp[2] = kp.
get(2); Pip[2] = pip.
get(2);
Pi0[2] = pi0.
get(2);
293 Km[3] = km.
get(3); Kp[3] = kp.
get(3); Pip[3] = pip.
get(3);
Pi0[3] = pi0.
get(3);
296 int g0[18]={1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1};
297 int g1[18]={1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1};
298 int g2[18]={0,1,2,0,1,2,0,0,0,0,1,0,0,1,0,0,2,2};
300 calEvaMy(Km,Kp,Pip,
Pi0,mass1,mass2,width1,width2,rho,phi,g0,
g1,g2,modetype,nstates,prob);
306void EvtDsToKKpipi0::Com_Multi(
double a1[2],
double a2[2],
double res[2]){
307 res[0] = a1[0]*a2[0]-a1[1]*a2[1];
308 res[1] = a1[1]*a2[0]+a1[0]*a2[1];
310void EvtDsToKKpipi0::Com_Divide(
double a1[2],
double a2[2],
double res[2]){
311 double tmp = a2[0]*a2[0]+a2[1]*a2[1];
312 res[0] = (a1[0]*a2[0]+a1[1]*a2[1])/tmp;
313 res[1] = (a1[1]*a2[0]-a1[0]*a2[1])/tmp;
315double EvtDsToKKpipi0::SCADot(
double a1[4],
double a2[4]){
316 double _cal = a1[0]*a2[0]-a1[1]*a2[1]-a1[2]*a2[2]-a1[3]*a2[3];
319double EvtDsToKKpipi0::barrier(
int l,
double sa,
double sb,
double sc,
double r2){
321 double tmp = sa+sb-sc;
322 double q = 0.25*tmp*tmp/sa-sb;
323 if (
q < 0)
q = fabs(
q);
326 F = sqrt(2.0/(1.0/r2+
q));
331 F = sqrt(13.0/(9.0*(1/(r2*r2))+3.0*
q*(1/r2)+
q*
q));
337void EvtDsToKKpipi0::calt1(
double daug1[4],
double daug2[4],
double t1[4]){
340 for(
int i=0; i<4; i++) {
341 pa[i] = daug1[i] + daug2[i];
342 qa[i] = daug1[i] - daug2[i];
347 for(
int i=0; i<4; i++) {
348 t1[i] = qa[i] - tmp*pa[i];
351void EvtDsToKKpipi0::calt2(
double daug1[4],
double daug2[4],
double t2[4][4]){
354 calt1(daug1,daug2,t1);
355 r = SCADot(t1,t1)/3.0;
356 for(
int i=0; i<4; i++) {
357 pa[i] = daug1[i] + daug2[i];
360 for(
int i=0; i<4; i++) {
361 for(
int j=0; j<4; j++) {
362 t2[i][j] = t1[i]*t1[j] - r*(G[i][j]-pa[i]*pa[j]/p);
366void EvtDsToKKpipi0::Flatte_rhoab(
double sa,
double sb,
double sc,
double rho[2]){
367 double q = (sa+sb-sc)*(sa+sb-sc)/(4*sa)-sb;
369 rho[0]=2* sqrt(
q/sa);
374 rho[1]=2*sqrt(-
q/sa);
377void EvtDsToKKpipi0::propagatora0980(
double mass2,
double mass,
double sx,
double *sb,
double *sc,
double prop[2]){
378 double unit[2]={1.0};
381 Flatte_rhoab(sx,sb[0],sc[0],rho1);
383 Flatte_rhoab(sx,sb[1],sc[1],rho2);
385 double gKK_a980=0.892*0.341, gPiEta_a980=0.341;
386 double tmp1[2]={gKK_a980,0};
388 double tmp2[2]={gPiEta_a980,0};
390 Com_Multi(tmp1,rho1,tmp11);
391 Com_Multi(tmp2,rho2,tmp22);
392 double tmp3[2]={tmp11[0]+tmp22[0],tmp11[1]+tmp22[1]};
394 Com_Multi(tmp3, ci,tmp31);
395 double tmp4[2]={mass2-sx-tmp31[0], -1.0*tmp31[1]};
396 Com_Divide(
unit,tmp4, prop);
398double EvtDsToKKpipi0::wid(
double mass2,
double mass,
double sa,
double sb,
double sc,
double r2,
int l){
402 double tmp1 = sa+tmp;
403 double q = 0.25*tmp1*tmp1/sa-sb;
405 double tmp2 = mass2+tmp;
406 double q0 = 0.25*tmp2*tmp2/mass2-sb;
407 if(q0<0) q0 = fabs(q0);
411 if(l == 0){widm = sqrt(
t)*
mass/m;}
412 else if(l == 1){widm =
t*sqrt(
t)*
mass/m*(1+z0)/(1+z);}
413 else if(l == 2){widm =
t*
t*sqrt(
t)*
mass/m*(9+3*z0+z0*z0)/(9+3*z+z*z);}
416double EvtDsToKKpipi0::widl1(
double mass2,
double mass,
double sa,
double sb,
double sc,
double r2){
420 double tmp1 = sa+tmp;
421 double q = 0.25*tmp1*tmp1/sa-sb;
423 double tmp2 = mass2+tmp;
424 double q0 = 0.25*tmp2*tmp2/mass2-sb;
425 if(q0<0) q0 = fabs(q0);
428 double F = (1+z0)/(1+z);
430 widm =
t*sqrt(
t)*
mass/m*F;
433void EvtDsToKKpipi0::propagatorRBW(
double mass2,
double mass,
double width,
double sa,
double sb,
double sc,
double r2,
int l,
double prop[2]){
438 b[1] = -
mass*width*wid(mass2,
mass,sa,sb,sc,r2,l);
439 Com_Divide(a,
b,prop);
441void EvtDsToKKpipi0::propagatorNBW(
double mass2,
double mass,
double width,
double sa,
double sb,
double sc,
double r2,
int l,
double prop[2]){
447 Com_Divide(a,
b,prop);
449void EvtDsToKKpipi0::propagatorRBWl1(
double mass2,
double mass,
double width,
double sa,
double sb,
double sc,
double r2,
double prop[2]){
454 b[1] = -
mass*width*widl1(mass2,
mass,sa,sb,sc,r2);
455 Com_Divide(a,
b,prop);
457void EvtDsToKKpipi0::propagatorGS(
double mass2,
double mass,
double width,
double sa,
double sb,
double sc,
double r2,
double prop[2]){
460 double tmp1 = sa+tmp;
461 double q2 = 0.25*tmp1*tmp1/sa-sb;
462 if(q2<0) q2 = fabs(q2);
464 double tmp2 = mass2+tmp;
465 double q02 = 0.25*tmp2*tmp2/mass2-sb;
466 if(q02<0) q02 = fabs(q02);
469 double q0 = sqrt(q02);
472 double tmp3 = log(
mass+2*q0)+1.2760418309;
474 double h = GS1*
q/m*(log(m+2*
q)+1.2760418309);
475 double h0 = GS1*q0/
mass*tmp3;
476 double dh = h0*(0.125/q02-0.5/mass2)+GS3/mass2;
477 double d = GS2/q02*tmp3+GS3*
mass/q0-GS4*
mass/q03;
478 double f = mass2/q03*(q2*(h-h0)+(mass2-sa)*q02*dh);
480 a[0] = 1.0+d*width/
mass;
482 b[0] = mass2-sa+width*
f;
483 b[1] = -
mass*width*widl1(mass2,
mass,sa,sb,sc,r2);
484 Com_Divide(a,
b,prop);
486void EvtDsToKKpipi0::KPiSLASS(
double sa,
double sb,
double sc,
double prop[2]){
487 const double m1430 = 1.441;
488 const double sa0 = 2.076481;
489 const double w1430 = 0.193;
490 const double Lass1 = 0.25/sa0;
492 double tmp1 = sa0+tmp;
493 double q0 = Lass1*tmp1*tmp1-sb;
495 double tmp2 = sa+tmp;
496 double qs = 0.25*tmp2*tmp2/sa-sb;
498 double width = w1430*
q*m1430/sqrt(sa*q0);
499 double temp_R = atan(m1430*width/(sa0-sa));
500 if(temp_R<0) temp_R += math_pi;
501 double deltaR = -109.7*math_pi/180.0 + temp_R;
502 double temp_F = atan(0.226*
q/(2.0-3.8194*qs));
503 if(temp_F<0) temp_F += math_pi;
504 double deltaF = 0.1*math_pi/180.0 + temp_F;
505 double deltaS = deltaR + 2.0*deltaF;
506 double t1 = 0.96*
sin(deltaF);
507 double t2 =
sin(deltaR);
513 prop[0] = t1*CF[0] + t2*
CS[0];
514 prop[1] = t1*CF[1] + t2*
CS[1];
517void EvtDsToKKpipi0::calEvaMy(
double* Km,
double* Kp,
double* Pip,
double*
Pi0,
double *mass1,
double *mass2,
double *width1,
double *width2,
double *amp,
double *phase,
int* g0,
int*
g1,
int* g2,
int* modetype,
int nstates,
double & Result){
518 double cof[2], amp_tmp[2], amp_PDF[2], PDF[2];
519 Km[0] = sqrt(0.243719942 + Km[1]*Km[1] + Km[2]*Km[2] + Km[3]*Km[3]);
520 Kp[0] = sqrt(0.243719942 + Kp[1]*Kp[1] + Kp[2]*Kp[2] + Kp[3]*Kp[3]);
521 Pip[0] = sqrt(0.019479785 + Pip[1]*Pip[1] + Pip[2]*Pip[2] + Pip[3]*Pip[3]);
529 double pKstr0[4],pKstrp[4],pKstrm[4],prhop[4],pphi[4],pK10[4],pK11[4],pK12[4],pK13[4],pK14[4],pD[4];
530 for(
int i=0;i!=4;i++){
531 pphi[i] =Km[i]+Kp[i];
532 prhop[i] =Pip[i]+
Pi0[i];
533 pKstr0[i] =Km[i]+Pip[i];
534 pKstrp[i] =Kp[i]+
Pi0[i];
535 pKstrm[i] =Km[i]+
Pi0[i];
536 pK10[i] =pKstrm[i]+Kp[i];
537 pK11[i] =pKstrm[i]+Pip[i];
538 pK12[i] =pKstrp[i]+Km[i];
539 pK13[i] =pKstr0[i]+
Pi0[i];
540 pK14[i] =pphi[i]+
Pi0[i];
541 pD[i] =pphi[i]+prhop[i];
543 double spi0,spionp,skaon1,skaon2,sphi,srhop,skstr0,skstrp,skstrm,sk10,sk11,sk12,sk13,sk14,sD;
544 skaon1 = SCADot(Km,Km);
545 skaon2 = SCADot(Kp,Kp);
546 spionp = SCADot(Pip,Pip);
548 sphi = SCADot(pphi,pphi);
549 srhop = SCADot(prhop,prhop);
550 skstr0 = SCADot(pKstr0,pKstr0);
551 skstrp = SCADot(pKstrp,pKstrp);
552 skstrm = SCADot(pKstrm,pKstrm);
553 sk10 = SCADot(pK10,pK10);
554 sk11 = SCADot(pK11,pK11);
555 sk12 = SCADot(pK12,pK12);
556 sk13 = SCADot(pK13,pK13);
557 sk14 = SCADot(pK14,pK14);
560 double t1phi[4],t1A1[4],t1A2[4],t1rhop[4],t1kstr1[4],t1kstr2[4],t1kstr3[4],t1kstr4[4],t2k11[4][4],t2k12[4][4],t2k13[4][4],t2k14[4][4],t2k21[4][4];
562 calt1(Pip,
Pi0,t1rhop);
563 calt1(Km,Pip,t1kstr1);
564 calt1(Kp,
Pi0,t1kstr2);
565 calt1(Km,
Pi0,t1kstr3);
566 calt1(Kp,
Pi0,t1kstr4);
568 calt1(pKstr0,
Pi0,t1A1);
569 calt1(pKstrm,Pip,t1A2);
571 calt2(pKstr0,
Pi0,t2k11);
572 calt2(pKstrm,Pip,t2k12);
574 calt2(pKstrm,Kp,t2k13);
575 calt2(pKstrp,Km,t2k14);
576 calt2(prhop,Km,t2k21);
578 double B_phi =-1.0, B_rho =-1.0, B_rho_2 =-1.0, B_phirho1=-1.0, B_phirho2=-1.0, B_phi_2 =-1.0;
579 double B_Kstp =-1.0, B_Kst0 =-1.0, B_KsKs1 =-1.0, B_KsKs2 =-1.0, B_Kstp_2 =-1.0, B_Kst0_2 =-1.0, B_DA2 =-1.0;
580 double B_Kstm =-1.0, B_DA1 =-1.0, B_A1 =-1.0, B_A2 =-1.0, B_A1_1 =-1.0, B_K13_1 =-1.0, B_A2_1 =-1.0;
581 double B_D_Arho =-1.0, B_Arho =-1.0, B_K11 =-1.0, B_D11 =-1.0, B_Arho1 =-1.0, B_K14_phi=-1.0, B_A10 =-1.0;
582 double B_K11rho =-1.0, B_D_K11rho=-1.0, B_K14_1 =-1.0, B_K14_2 =-1.0, B_D_K14 =-1.0, B_K14_km =-1.0, B_K14_kp =-1.0;
583 double B_K_Kst0pi0=-1.0, B_D_KK =-1.0, B_K_Kstmpip=-1.0, B_D_K11_2=-1.0, B_K11_21 =-1.0, B_K11_22 =-1.0, B_A12 =-1.0;
587 double mass1sq,mass2sq,tt1,tt2,tt3,tt4;
588 double temp_PDF, tmp1, temp[2],tmp3,temp_PDF1;
589 double pro[2], pro0[2], pro1[2],pro2[2],pro3[2],pro4[2];
590 double t1A[4],t1D[4],t2D[4][4],
B[3];
591 int isKstp=0.0, isKst0=0.0, isKstm=0.0, isRho=0.0, isf0=0.0, isKmPip_S=0.0, isKpPi0_S=0.0, isKmPi0_S=0.0, isPiPi_S=0.0, isA0980=0.0;
592 double proRho[2], proKstp[2], proKstm[2], proKst0[2], proPiPi_S[2], proKmPip_S[2], proKpPi0_S[2], proKmPi0_S[2], proA0980[2], prof0[2];
593 for(
int i=0; i<nstates; i++){
596 cof[0] = amp[i]*
cos(phase[i]);
597 cof[1] = amp[i]*
sin(phase[i]);
598 mass1sq = mass1[i]*mass1[i];
599 mass2sq = mass2[i]*mass2[i];
602 if (B_phi<0.0) B_phi = barrier(1,sphi,skaon1,skaon2,rRes2);
603 if (B_rho<0.0) B_rho = barrier(1,srhop,spionp,spi0,rRes2);
605 for(
int i=0; i<4; i++){
606 temp_PDF += G[i][i]*t1phi[i]*t1rhop[i];
608 tmp1 = B_phi*B_rho*temp_PDF;
611 calt1(pphi,prhop,t1D);
612 for(
int i=0; i<4; i++){
614 for(
int j=0; j<4; j++){
616 for(
int k=0; k<4; k++){
617 tt3=t1phi[k]*G[k][k];
618 for(
int l=0; l<4; l++){
619 temp_PDF += E[i][j][k][l]*tt1*tt2*tt3*t1rhop[l]*G[l][l];
625 B_phirho1 = barrier(1,sD,sphi,srhop,rD2);
626 tmp1 = B_phi*B_rho*B_phirho1*temp_PDF;
630 calt2(pphi,prhop,t2D);
631 for(
int i=0; i<4; i++){
632 tt1=t1phi[i]*G[i][i];
633 for(
int j=0; j<4; j++){
634 temp_PDF += t2D[i][j]*t1rhop[j]*G[j][j]*tt1;
638 B_phirho2 = barrier(2,sD,sphi,srhop,rD2);
639 tmp1 = B_phi*B_rho*B_phirho2*temp_PDF;
643 propagatorGS(mass2sq,mass2[i],width2[i],srhop,spionp,spi0,rRes2,proRho);
646 if(g0[i]==1){propagatorRBWl1(mass1sq,mass1[i],width1[i],sphi,skaon1,skaon2,rRes2,pro0);}
647 else if(g0[i]==0){ pro0[0] = 1; pro0[1] = 0;}
648 if(
g1[i]==1){ pro1[0] = proRho[0]; pro1[1] = proRho[1];}
649 else if(
g1[i]==0){ pro1[0] = 1; pro1[1] = 0;}
650 Com_Multi(pro0,pro1,pro);
651 amp_tmp[0] = tmp1*pro[0];
652 amp_tmp[1] = tmp1*pro[1];
655 else if(modetype[i]==2){
656 if (B_Kst0<0.0) B_Kst0 = barrier(1,skstr0,skaon1,spionp,rRes2);
657 if (B_Kstp<0.0) B_Kstp = barrier(1,skstrp,skaon2,spi0,rRes2);
659 for(
int i=0; i<4; i++){
660 temp_PDF += G[i][i]*t1kstr1[i]*t1kstr2[i];
662 tmp1 = B_Kst0*B_Kstp*temp_PDF;
665 calt1(pKstr0,pKstrp,t1D);
666 for(
int i=0; i<4; i++){
668 for(
int j=0; j<4; j++){
670 for(
int k=0; k<4; k++){
671 tt3=t1kstr1[k]*G[k][k];
672 for(
int l=0; l<4; l++){
673 temp_PDF += E[i][j][k][l]*tt1*tt2*tt3*t1kstr2[l]*G[l][l];
679 B_KsKs1 = barrier(1,sD,skstr0,skstrp,rD2);
680 tmp1 = B_Kst0*B_Kstp*B_KsKs1*temp_PDF;
684 calt2(pKstr0,pKstrp,t2D);
685 for(
int i=0; i<4; i++){
686 tt1 = t1kstr1[i]*G[i][i];
687 for(
int j=0; j<4; j++){
688 temp_PDF += t2D[i][j]*t1kstr2[j]*G[j][j]*tt1;
692 B_KsKs2 = barrier(2,sD,skstr0,skstrp,rD2);
693 tmp1 = B_Kst0*B_Kstp*B_KsKs2*temp_PDF;
697 propagatorRBWl1(mass1sq,mass1[i],width1[i],skstr0,skaon1,spionp,rRes2,proKst0);
701 propagatorRBWl1(mass2sq,mass2[i],width2[i],skstrp,skaon2,spi0,rRes2,proKstp);
704 if(g0[i]==1){pro0[0] = proKst0[0]; pro0[1] = proKst0[1];}
705 else if(g0[i]==0){pro0[0] = 1; pro0[1] = 0;}
706 if(
g1[i]==1){pro1[0] = proKstp[0]; pro1[1] = proKstp[1];}
707 else if(
g1[i]==0){pro1[0] = 1; pro1[1] = 0;}
708 Com_Multi(pro0,pro1,pro);
709 amp_tmp[0] = tmp1*pro[0];
710 amp_tmp[1] = tmp1*pro[1];
713 else if(modetype[i]==3){
715 if(B_DA1<0.0) B_DA1 = barrier(1,sD,sk11,skaon2,rD2);
716 if(B_Kst0<0.0) B_Kst0 = barrier(1,skstr0,skaon1,spionp,rRes2);
719 for(
int i=0; i<4; i++){
720 tt1 = t1D[i]*G[i][i];
721 for(
int j=0; j<4; j++){
722 temp_PDF += tt1*(G[i][j]-pK11[i]*pK11[j]/sk11)*t1kstr1[j]*G[j][j];
725 tmp1 = B_Kst0*B_DA1*temp_PDF;
728 for(
int i=0; i<4; i++){
730 for(
int j=0; j<4; j++){
731 temp_PDF += tt1*t2k11[i][j]*t1kstr1[j]*G[j][j];
734 if(B_A2<0.0) B_A2 = barrier(2,sk11,skstr0,spi0,rRes2);
735 tmp1 = B_Kst0*B_A2*B_DA1*temp_PDF;
738 propagatorRBWl1(mass1sq,mass1[i],width1[i],skstr0,skaon1,spionp,rRes2,proKst0);
742 pro0[0] = proKst0[0]; pro0[1] = proKst0[1];
744 else if(g0[i]==0){pro0[0] = 1; pro0[1] = 0;}
746 propagatorRBW(mass2sq,mass2[i],width2[i],sk11,skstr0,spi0,rRes2,g2[i],pro1);
748 else if(
g1[i]==0){pro1[0] = 1; pro1[1] = 0;}
749 Com_Multi(pro0,pro1,pro);
750 amp_tmp[0] = tmp1*pro[0];
751 amp_tmp[1] = tmp1*pro[1];
754 else if(modetype[i]==333){
756 if(B_DA1<0.0) B_DA1 = barrier(1,sD,sk11,skaon2,rD2);
757 if(B_Kstm<0.0) B_Kstm = barrier(1,skstrm,skaon1,spi0,rRes2);
760 for(
int i=0; i<4; i++){
761 tt1 = t1D[i]*G[i][i];
762 for(
int j=0; j<4; j++){
763 temp_PDF1 += tt1*(G[i][j]-pK11[i]*pK11[j]/sk11)*t1kstr3[j]*G[j][j];
766 tmp3 = B_Kstm*B_DA1*temp_PDF1;
769 for(
int i=0; i<4; i++){
771 for(
int j=0; j<4; j++){
772 temp_PDF1 += tt1*t2k12[i][j]*t1kstr3[j]*G[j][j];
775 if(B_A1<0.0) B_A1 = barrier(2,sk11,skstrm,spionp,rRes2);
776 tmp3 = B_Kstm*B_A1*B_DA1*temp_PDF1;
779 propagatorRBWl1(mass1sq,mass1[i],width1[i],skstrm,skaon1,spi0,rRes2,pro2);
781 else if(g0[i]==0){pro2[0] = 1; pro2[1] = 0;}
783 propagatorRBW(mass2sq,mass2[i],width2[i],sk11,skstrm,spionp,rRes2,g2[i],pro3);
785 else if(
g1[i]==0){pro3[0] = 1; pro3[1] = 0;}
786 Com_Multi(pro2,pro3,pro4);
787 amp_tmp[0] = -1.414*tmp3*pro4[0];
788 amp_tmp[1] = -1.414*tmp3*pro4[1];
791 else if(modetype[i]==4){
793 if(B_rho<0.0) B_rho = barrier(1,srhop,spionp,spi0,rRes2);
794 if(B_D_Arho<0.0) B_D_Arho = barrier(1,sD,sk11,skaon2,rD2);
797 for(
int i=0; i<4; i++){
799 for(
int j=0; j<4; j++){
800 temp_PDF += tt1*(G[i][j]-pK11[i]*pK11[j]/sk11)*t1rhop[j]*G[j][j];
803 tmp1 = B_rho*B_D_Arho*temp_PDF;
806 for(
int i=0; i<4; i++){
808 for(
int j=0; j<4; j++){
809 temp_PDF += tt1*t2k21[i][j]*t1rhop[j]*G[j][j];
813 B_Arho = barrier(2,sk11,srhop,skaon1,rRes2);
814 tmp1 = B_rho*B_Arho*B_D_Arho*temp_PDF;
818 propagatorGS(mass2sq,mass2[i],width2[i],srhop,spionp,spi0,rRes2,proRho);
821 if(g0[i]==1) propagatorRBW(mass1sq,mass1[i],width1[i],sk11,srhop,skaon1,rRes2,g2[i],pro0);
822 else if(g0[i]==0){pro0[0] = 1; pro0[1] = 0;}
823 if(
g1[i]==1){pro1[0] = proRho[0]; pro1[1] = proRho[1];}
824 else if(
g1[i]==0){pro1[0] = 1; pro1[1] = 0;}
825 Com_Multi(pro0,pro1,pro);
826 amp_tmp[0] = tmp1*pro[0];
827 amp_tmp[1] = tmp1*pro[1];
830 else if(modetype[i]==30){
832 double sKmm[2]={skaon1,mass_Pion_N*mass_Pion_N};
833 double sKpp[2]={skaon2,mass_Eta*mass_Eta};
835 propagatora0980(mass1sq,mass1[i],sphi,sKmm,sKpp,proA0980);
838 if(g0[i]==1){pro0[0]=proA0980[0]; pro0[1]=proA0980[1];}
839 else if(g0[i]==0){pro0[0] = 1; pro0[1] = 0;}
840 if(
g1[i]==1)propagatorRBW(mass2sq,mass2[i],width2[i],sk14,sphi,spi0,rRes2,0,pro1);
841 else if(
g1[i]==0){pro1[0] = 1; pro1[1] = 0;}
842 Com_Multi(pro0,pro1,pro);
847 else if(modetype[i]==31){
849 if(B_K14_phi<0.0) B_K14_phi = barrier(1,sk14,sphi,spi0,rRes2);
850 if(B_D_K14<0.0) B_D_K14 = barrier(1,sD,sk14,spionp,rD2);
851 double sKmm[2]={skaon1,mass_Pion_N*mass_Pion_N};
852 double sKpp[2]={skaon2,mass_Eta*mass_Eta};
855 for(
int w=0;
w<4;
w++){
856 temp_PDF += t1D[
w]*t1A[
w]*G[
w][
w];
858 tmp1 = temp_PDF*B_K14_phi*B_D_K14;
860 propagatora0980(mass1sq,mass1[i],sphi,sKmm,sKpp,proA0980);
863 if(g0[i]==1){pro0[0]=proA0980[0]; pro0[1]=proA0980[1];}
864 else if(g0[i]==0){pro0[0] = 1; pro0[1] = 0;}
865 if(
g1[i]==1) propagatorRBWl1(mass2sq,mass2[i],width2[i],sk14,sphi,spi0,rRes2,pro1);
866 else if(
g1[i]==0){pro1[0] = 1; pro1[1] = 0;}
867 Com_Multi(pro0,pro1,pro);
868 amp_tmp[0] = tmp1*pro[0];
869 amp_tmp[1] = tmp1*pro[1];
872 else if(modetype[i]==72){
875 KPiSLASS(skstrm,skaon1,spi0,proKmPi0_S);
879 pro0[0] = proKmPi0_S[0]; pro0[1] = proKmPi0_S[1];
881 else if(g0[i]==0){pro0[0] = 1; pro0[1] = 0;}
883 propagatorRBW(mass2sq,mass2[i],width2[i],sk14,skstrm,skaon2,rRes2,0,pro1);
885 else if(
g1[i]==0){pro1[0] = 1; pro1[1] = 0;}
886 Com_Multi(pro0,pro1,pro);
891 else if(modetype[i]==721){
894 KPiSLASS(skstrp,skaon2,spi0,proKpPi0_S);
898 pro2[0] = proKpPi0_S[0]; pro2[1] = proKpPi0_S[1];
900 else if(g0[i]==0){pro2[0] = 1; pro2[1] = 0;}
902 propagatorRBW(mass2sq,mass2[i],width2[i],sk14,skstrp,skaon1,rRes2,0,pro3);
904 else if(
g1[i]==0){pro3[0] = 1; pro3[1] = 0;}
905 Com_Multi(pro2,pro3,pro4);
906 amp_tmp[0] = pro4[0];
907 amp_tmp[1] = pro4[1];
910 else if(modetype[i]==73){
912 if(B_DA2<0.0) B_DA2 = barrier(1,sD,sk10,spionp,rD2);
913 if(B_Kstm<0.0) B_Kstm = barrier(1,skstrm,skaon1,spi0,rRes2);
916 for(
int i=0; i<4; i++){
917 tt1 = t1D[i]*G[i][i];
918 for(
int j=0; j<4; j++){
919 temp_PDF += tt1*(G[i][j]-pK10[i]*pK10[j]/sk10)*t1kstr3[j]*G[j][j];
922 tmp1 = B_Kstm*B_DA2*temp_PDF;
925 for(
int i=0; i<4; i++){
927 for(
int j=0; j<4; j++){
928 temp_PDF += tt1*t2k13[i][j]*t1kstr3[j]*G[j][j];
931 if(B_A10<0.0) B_A10 = barrier(2,sk10,skstrm,skaon2,rRes2);
932 tmp1 = B_Kstm*B_A10*B_DA2*temp_PDF;
935 propagatorRBWl1(mass1sq,mass1[i],width1[i],skstrm,skaon1,spi0,rRes2,proKstm);
939 pro0[0] = proKstm[0]; pro0[1] = proKstm[1];
941 else if(g0[i]==0){pro0[0] = 1; pro0[1] = 0;}
943 propagatorRBW(mass2sq,mass2[i],width2[i],sk10,skstrm,skaon2,rRes2,g2[i],pro1);
945 else if(
g1[i]==0){pro1[0] = 1; pro1[1] = 0;}
946 Com_Multi(pro0,pro1,pro);
947 amp_tmp[0] = tmp1*pro[0];
948 amp_tmp[1] = tmp1*pro[1];
951 else if(modetype[i]==731){
953 if(B_DA2<0.0) B_DA2 = barrier(1,sD,sk10,spionp,rD2);
954 if(B_Kstp<0.0) B_Kstp = barrier(1,skstrp,skaon2,spi0,rRes2);
957 for(
int i=0; i<4; i++){
958 tt1 = t1D[i]*G[i][i];
959 for(
int j=0; j<4; j++){
960 temp_PDF1 += tt1*(G[i][j]-pK10[i]*pK10[j]/sk10)*t1kstr4[j]*G[j][j];
963 tmp3 = B_Kstp*B_DA2*temp_PDF1;
966 for(
int i=0; i<4; i++){
968 for(
int j=0; j<4; j++){
969 temp_PDF1 += tt1*t2k14[i][j]*t1kstr4[j]*G[j][j];
972 if(B_A12<0.0) B_A12 = barrier(2,sk12,skstrp,skaon1,rRes2);
973 tmp3 = B_Kstp*B_A12*B_DA2*temp_PDF1;
976 propagatorRBWl1(mass1sq,mass1[i],width1[i],skstrp,skaon2,spi0,rRes2,proKstp);
980 pro2[0] = proKstp[0]; pro2[1] = proKstp[1];
982 else if(g0[i]==0){pro2[0] = 1; pro2[1] = 0;}
984 propagatorRBW(mass2sq,mass2[i],width2[i],sk12,skstrp,skaon1,rRes2,g2[i],pro3);
986 else if(
g1[i]==0){pro3[0] = 1; pro3[1] = 0;}
987 Com_Multi(pro2,pro3,pro4);
988 amp_tmp[0] = -tmp3*pro4[0];
989 amp_tmp[1] = -tmp3*pro4[1];
992 else if(modetype[i]==50){
994 if(B_rho<0.0) B_rho = barrier(1,srhop,spionp,spi0,rRes2);
995 if(B_phirho1<0.0) B_phirho1 = barrier(1,sD,sphi,srhop,rD2);
996 calt1(pphi,prhop,t1D);
997 for(
int w=0;
w<4;
w++){
998 temp_PDF += t1D[
w]*t1rhop[
w]*G[
w][
w];
1000 tmp1 = temp_PDF*B_rho*B_phirho1;
1001 double sKmm[2]={skaon1,mass_Pion_N*mass_Pion_N};
1002 double sKpp[2]={skaon2,mass_Eta*mass_Eta};
1004 propagatora0980(mass1sq,mass1[i],sphi,sKmm,sKpp,proA0980);
1008 propagatorGS(mass2sq,mass2[i],width2[i],srhop,spionp,spi0,rRes2,proRho);
1011 if(g0[i]==1){pro0[0]=proA0980[0]; pro0[1]=proA0980[1];}
1012 else if(g0[i]==0){pro0[0] = 1; pro0[1] = 0;}
1013 if(
g1[i]==1){pro1[0] = proRho[0]; pro1[1] = proRho[1];}
1014 else if(
g1[i]==0){pro1[0] = 1; pro1[1] = 0;}
1015 Com_Multi(pro0,pro1,pro);
1016 amp_tmp[0] = tmp1*pro[0];
1017 amp_tmp[1] = tmp1*pro[1];
1020 Com_Multi(amp_tmp,cof,amp_PDF);
1021 PDF[0] += amp_PDF[0];
1022 PDF[1] += amp_PDF[1];
1024 double value = PDF[0]*PDF[0] + PDF[1]*PDF[1];
1025 if(value <=0) value = 1e-20;
double sin(const BesAngle a)
double cos(const BesAngle a)
TFile f("ana_bhabha660a_dqa_mcPat_zy_old.root")
*******INTEGER m_nBinMax INTEGER m_NdiMax !No of bins in histogram for cell exploration division $ !Last vertex $ !Last active cell $ !Last cell in buffer $ !No of sampling when dividing cell $ !No of function total $ !Flag for random ceel for $ !Flag for type of for WtMax $ !Flag which decides whether vertices are included in the sampling $ entire domain is hyp !Maximum effective eevents per saves r n generator level $ !Flag for chat level in !Latex Output unit
****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
void checkSpinDaughter(int d1, EvtSpinType::spintype sp)
void checkSpinParent(EvtSpinType::spintype sp)
void setProbMax(double prbmx)
void checkNDaug(int d1, int d2=-1)
void checkNArg(int a1, int a2=-1, int a3=-1, int a4=-1)
void setProb(double prob)
void getName(std::string &name)
virtual ~EvtDsToKKpipi0()
void decay(EvtParticle *p)
const EvtVector4R & getP4() const
EvtParticle * getDaug(int i)
double initializePhaseSpace(int numdaughter, EvtId *daughters, double poleSize=-1., int whichTwo1=0, int whichTwo2=1)