9#include <EvtGenBase/EvtPatches.hh>
10#include <EvtGenBase/EvtParticle.hh>
11#include <EvtGenBase/EvtGenKine.hh>
12#include <EvtGenBase/EvtPDL.hh>
13#include <EvtGenBase/EvtReport.hh>
14#include <EvtGenBase/EvtComplex.hh>
15#include <EvtGenBase/EvtDecayTable.hh>
18#include <generators/evtgen/EvtGenModelRegister.h>
19#include <generators/evtgen/models/besiii/EvtDToKSpipipi.h>
30 EvtDToKSpipipi::~EvtDToKSpipipi() {}
32 std::string EvtDToKSpipipi::getName()
37 EvtDecayBase* EvtDToKSpipipi::clone()
39 return new EvtDToKSpipipi;
42 void EvtDToKSpipipi::init()
46 checkSpinParent(EvtSpinType::SCALAR);
54 mK1270 = 1.272; mK1400 = 1.403;
55 GK1270 = 0.09; GK1400 = 0.174;
56 mKstr = 0.89166; mrho = 0.77549;
57 GKstr = 0.0462; Grho = 0.1491;
122 int GG[4][4] = { {1, 0, 0, 0}, {0, -1, 0, 0}, {0, 0, -1, 0}, {0, 0, 0, -1} };
123 int EE[4][4][4][4] = {
124 { {{0, 0, 0, 0}, {0, 0, 0, 0}, {0, 0, 0, 0}, {0, 0, 0, 0} },
125 {{0, 0, 0, 0}, {0, 0, 0, 0}, {0, 0, 0, 1}, {0, 0, -1, 0}},
126 {{0, 0, 0, 0}, {0, 0, 0, -1}, {0, 0, 0, 0}, {0, 1, 0, 0} },
127 {{0, 0, 0, 0}, {0, 0, 1, 0}, {0, -1, 0, 0}, {0, 0, 0, 0} }
129 { {{0, 0, 0, 0}, {0, 0, 0, 0}, {0, 0, 0, -1}, {0, 0, 1, 0} },
130 {{0, 0, 0, 0}, {0, 0, 0, 0}, {0, 0, 0, 0}, {0, 0, 0, 0} },
131 {{0, 0, 0, 1}, {0, 0, 0, 0}, {0, 0, 0, 0}, {-1, 0, 0, 0}},
132 {{0, 0, -1, 0}, {0, 0, 0, 0}, {1, 0, 0, 0}, {0, 0, 0, 0} }
134 { {{0, 0, 0, 0}, {0, 0, 0, 1}, {0, 0, 0, 0}, {0, -1, 0, 0}},
135 {{0, 0, 0, -1}, {0, 0, 0, 0}, {0, 0, 0, 0}, {1, 0, 0, 0} },
136 {{0, 0, 0, 0}, {0, 0, 0, 0}, {0, 0, 0, 0}, {0, 0, 0, 0} },
137 {{0, 1, 0, 0}, {-1, 0, 0, 0}, {0, 0, 0, 0}, {0, 0, 0, 0} }
139 { {{0, 0, 0, 0}, {0, 0, -1, 0}, {0, 1, 0, 0}, {0, 0, 0, 0} },
140 {{0, 0, 1, 0}, {0, 0, 0, 0}, {-1, 0, 0, 0}, {0, 0, 0, 0} },
141 {{0, -1, 0, 0}, {1, 0, 0, 0}, {0, 0, 0, 0}, {0, 0, 0, 0} },
142 {{0, 0, 0, 0}, {0, 0, 0, 0}, {0, 0, 0, 0}, {0, 0, 0, 0} }
145 for (
int i = 0; i < 4; i++) {
146 for (
int j = 0; j < 4; j++) {
148 for (
int k = 0; k < 4; k++) {
149 for (
int l = 0; l < 4; l++) {
150 E[i][j][k][l] = EE[i][j][k][l];
157 void EvtDToKSpipipi::initProbMax()
162 void EvtDToKSpipipi::decay(EvtParticle* p)
183 p->initializePhaseSpace(getNDaug(), getDaugs());
184 EvtVector4R Ks0 = p->getDaug(0)->getP4();
185 EvtVector4R pi1 = p->getDaug(1)->getP4();
186 EvtVector4R pi2 = p->getDaug(2)->getP4();
187 EvtVector4R pi3 = p->getDaug(3)->getP4();
189 double Ks[4], Pip1[4], Pip2[4], Pim[4];
190 Ks[0] = Ks0.get(0); Pip1[0] = pi1.get(0); Pip2[0] = pi2.get(0); Pim[0] = pi3.get(0);
191 Ks[1] = Ks0.get(1); Pip1[1] = pi1.get(1); Pip2[1] = pi2.get(1); Pim[1] = pi3.get(1);
192 Ks[2] = Ks0.get(2); Pip1[2] = pi1.get(2); Pip2[2] = pi2.get(2); Pim[2] = pi3.get(2);
193 Ks[3] = Ks0.get(3); Pip1[3] = pi1.get(3); Pip2[3] = pi2.get(3); Pim[3] = pi3.get(3);
194 double prob =
calPDF(Ks, Pip1, Pip2, Pim);
202 double P14[4], P24[4], P34[4];
203 for (
int i = 0; i < 4; i++) {
204 P14[i] = Ks[i] + Pim[i];
205 P24[i] = Pip1[i] + Pim[i];
206 P34[i] = Pip2[i] + Pim[i];
210 PDF[0] =
D2AP_A2VP(Ks, Pip2, Pip1, Pim, 0) *
getprop(P24, Pip2, ma1, Ga1, 1, 0) *
211 getprop(Pip1, Pim, mrho, Grho, 2, 1) +
213 getprop(Pip2, Pim, mrho, Grho, 2, 1);
214 PDF[1] =
D2AP_A2VP(Ks, Pip2, Pip1, Pim, 2) *
getprop(P24, Pip2, ma1, Ga1, 1, 2) *
215 getprop(Pip1, Pim, mrho, Grho, 2, 1) +
217 getprop(Pip2, Pim, mrho, Grho, 2, 1);
219 PDF[2] = D2AP_A2SP(Ks, Pip2, Pip1, Pim) *
getprop(P24, Pip2, ma1, Ga1, 1, 1) *
220 getprop(Pip1, Pim, msigma, Gsigma, 4, 0) +
221 D2AP_A2SP(Ks, Pip1, Pip2, Pim) *
getprop(P34, Pip1, ma1, Ga1, 1, 1) *
222 getprop(Pip2, Pim, msigma, Gsigma, 4, 0);
226 PDF[3] =
D2AP_A2VP(Pip2, Pip1, Ks, Pim, 0) *
getprop(P14, Pip1, mK1400, GK1400, 1, 0) *
227 getprop(Ks, Pim, mKstr, GKstr, 1, 1) +
228 D2AP_A2VP(Pip1, Pip2, Ks, Pim, 0) *
getprop(P14, Pip2, mK1400, GK1400, 1, 0) *
229 getprop(Ks, Pim, mKstr, GKstr, 1, 1);
231 PDF[4] =
D2AP_A2VP(Pip2, Pip1, Ks, Pim, 2) *
getprop(P14, Pip1, mK1400, GK1400, 1, 2) *
232 getprop(Ks, Pim, mKstr, GKstr, 1, 1) +
233 D2AP_A2VP(Pip1, Pip2, Ks, Pim, 2) *
getprop(P14, Pip2, mK1400, GK1400, 1, 2) *
234 getprop(Ks, Pim, mKstr, GKstr, 1, 1);
237 PDF[5] =
D2AP_A2VP(Pip2, Ks, Pip1, Pim, 0) *
getprop(P24, Ks, mK1270, GK1270, 0, 0) *
238 getprop(Pip1, Pim, mrho, Grho, 2, 1) +
239 D2AP_A2VP(Pip1, Ks, Pip2, Pim, 0) *
getprop(P34, Ks, mK1270, GK1270, 0, 0) *
240 getprop(Pip2, Pim, mrho, Grho, 2, 1);
242 PDF[6] =
D2AP_A2VP(Pip2, Ks, Pip1, Pim, 0) *
getprop(Pip1, Pim, mrho, Grho, 2, 1) +
244 PDF[7] =
D2AP_A2VP(Pip2, Ks, Pip1, Pim, 2) *
getprop(Pip1, Pim, mrho, Grho, 2, 1) +
247 PDF[8] = D2PP_P2VP(Pip2, Ks, Pip1, Pim) *
getprop(P24, Ks, mK1460, GK1460, 1, 1) *
248 getprop(Pip1, Pim, mrho, Grho, 2, 1) +
249 D2PP_P2VP(Pip1, Ks, Pip2, Pim) *
getprop(P34, Ks, mK1460, GK1460, 1, 1) *
250 getprop(Pip2, Pim, mrho, Grho, 2, 1);
252 PDF[9] =
D2AP_A2VP(Pip2, Pip1, Ks, Pim, 0) *
getprop(P14, Pip1, mK1650, GK1650, 1, 0) *
253 getprop(Ks, Pim, mKstr, GKstr, 1, 1) +
254 D2AP_A2VP(Pip1, Pip2, Ks, Pim, 0) *
getprop(P14, Pip2, mK1650, GK1650, 1, 0) *
255 getprop(Ks, Pim, mKstr, GKstr, 1, 1);
257 PDF[10] = D2AP_A2SP(Pip2, Ks, Pip1, Pim) + D2AP_A2SP(Pip1, Ks, Pip2, Pim);
259 EvtComplex corr(2, 0);
260 PDF[11] = corr * PHSP(Ks, Pim);
262 PDF[12] = D2PP_P2VP(Pip2, Pip1, Ks, Pim) *
getprop(P14, Pip1, mK1460, GK1460, 1, 1) *
263 getprop(Ks, Pim, mKstr, GKstr, 1, 1) +
264 D2PP_P2VP(Pip1, Pip2, Ks, Pim) *
getprop(P14, Pip2, mK1460, GK1460, 1, 1) *
265 getprop(Ks, Pim, mKstr, GKstr, 1, 1);
268 EvtComplex pdf, module;
269 pdf = EvtComplex(0, 0);
270 for (
int i = 0; i < 13; i++) {
271 cof = EvtComplex(rho[i] * cos(phi[i]), rho[i] * sin(phi[i]));
272 pdf = pdf + cof * PDF[i];
274 module = conj(pdf) * pdf;
276 value = real(module);
277 return (value <= 0) ? 1e-20 : value;
283 double m1430 = 1.463;
284 double sa0 = m1430 * m1430;
285 double w1430 = 0.233;
286 double q0 = (sa0 + sb - sc) * (sa0 + sb - sc) / (4 * sa0) - sb;
287 if (q0 < 0) q0 = 1e-16;
288 double qs = (sa + sb - sc) * (sa + sb - sc) / (4 * sa) - sb;
290 double width_ = w1430 * q * m1430 /
sqrt(sa * q0);
291 double temp_R =
atan(m1430 * width_ / (sa0 - sa));
292 if (temp_R < 0) temp_R += math_pi;
293 double deltaR = -5.31 + temp_R;
294 double temp_F =
atan(2 * 1.07 * q / (2 + (-1.8) * 1.07 * qs));
295 if (temp_F < 0) temp_F += math_pi;
296 double deltaF = 2.33 + temp_F;
297 EvtComplex cR(cos(deltaR), sin(deltaR));
298 EvtComplex cF(cos(deltaF), sin(deltaF));
299 EvtComplex amp = 0.8 * sin(deltaF) * cF + sin(deltaR) * cR * cF * cF;
305 EvtComplex amp_PDF(0, 0);
306 double t1V[4], t1D[4], t2A[4][4];
307 double sa[3], sb[3], sc[3], B[3];
308 double pV[4], pA[4], pD[4];
309 for (
int i = 0; i != 4; i++) {
310 pV[i] = P3[i] + P4[i];
311 pA[i] = pV[i] + P2[i];
312 pD[i] = pA[i] + P1[i];
323 B[0] =
barrier(1, sa[0], sb[0], sc[0], 3);
324 B[2] =
barrier(1, sa[2], sb[2], sc[2], rD);
328 for (
int i = 0; i != 4; i++) {
329 for (
int j = 0; j != 4; j++) {
330 temp_PDF += t1D[i] * (G[i][j] - pA[i] * pA[j] / sa[1]) * t1V[j] * (G[i][i]) * (G[j][j]);
337 for (
int i = 0; i != 4; i++) {
338 for (
int j = 0; j != 4; j++) {
339 temp_PDF += t1D[i] * t2A[i][j] * t1V[j] * (G[i][i]) * (G[j][j]);
342 B[1] =
barrier(2, sa[1], sb[1], sc[1], 3);
344 amp_PDF = temp_PDF * B[0] * B[1] * B[2];
347 EvtComplex EvtDToKSpipipi::D2AP_A2SP(
double P1[],
double P2[],
double P3[],
double P4[])
350 EvtComplex amp_PDF(0, 0);
352 double sa[3], sb[3], sc[3], B[3];
353 double t1D[4], t1A[4];
354 double pS[4], pA[4], pD[4];
355 for (
int i = 0; i != 4; i++) {
356 pS[i] = P3[i] + P4[i];
357 pA[i] = pS[i] + P2[i];
358 pD[i] = pA[i] + P1[i];
369 B[1] =
barrier(1, sa[1], sb[1], sc[1], 3);
370 B[2] =
barrier(1, sa[2], sb[2], sc[2], rD);
373 for (
int i = 0; i != 4; i++) {
374 temp_PDF += t1D[i] * t1A[i] * (G[i][i]);
376 amp_PDF = temp_PDF * B[1] * B[2];
379 EvtComplex EvtDToKSpipipi::D2PP_P2VP(
double P1[],
double P2[],
double P3[],
double P4[])
382 EvtComplex amp_PDF(0, 0);
384 double sa[3], sb[3], sc[3], B[3];
386 double pV[4], pP[4], pD[4];
387 for (
int i = 0; i != 4; i++) {
388 pV[i] = P3[i] + P4[i];
389 pP[i] = pV[i] + P2[i];
390 pD[i] = pP[i] + P1[i];
401 B[0] =
barrier(1, sa[0], sb[0], sc[0], 3);
402 B[1] =
barrier(1, sa[1], sb[1], sc[1], 3);
404 for (
int i = 0; i != 4; i++) {
405 temp_PDF += P2[i] * t1V[i] * (G[i][i]);
407 amp_PDF = temp_PDF * B[0] * B[1];
410 EvtComplex EvtDToKSpipipi::PHSP(
double Km[],
double Pip[])
412 EvtComplex amp_PDF(0, 0);
415 for (
int i = 0; i != 4; i++) {
416 KPi[i] = Km[i] + Pip[i];
432 EvtComplex prop1, prop2, prop;
433 EvtComplex one(1, 0);
435 for (
int i = 0; i < 4; i++) {
436 pR[i] = daug1[i] + daug2[i];
440 sb =
dot(daug1, daug1);
441 sc =
dot(daug2, daug2);
442 if (flag == 0)
return propogator(mass_, width_, sa);
443 if (flag == 1)
return propagatorRBW(mass_, width_, sa, sb, sc, 3.0, L);
445 prop1 =
propagatorGS(mass_, width_, sa, sb, sc, 3.0, L);
447 EvtComplex coef_omega(rho_omega * cos(phi_omega), rho_omega * sin(phi_omega));
448 prop = prop1 * (one + 0.783 * 0.783 * coef_omega * prop2);
456 double f = 0.5843 + 1.6663 * sa;
458 double mpi2 = mass_Pion * mass_Pion;
459 double mass2 = M * M;
460 double g1_ =
f * (sa - mpi2 / 2) / (mass2 - mpi2 / 2) * exp((mass2 - sa) / 1.082);
461 EvtComplex rho1s =
rhoab(sa, sb, sc);
462 EvtComplex rho1M =
rhoab(mass2, sb, sc);
463 EvtComplex rho2s =
rho4Pi(sa);
464 EvtComplex rho2M =
rho4Pi(mass2);
465 prop = 1.0 / (M * M - sa - ci * M * (g1_ * rho1s / rho1M + 0.0024 * rho2s / rho2M));
472 EvtComplex one(1, 0);
473 double q = (sa + sb - sc) * (sa + sb - sc) / (4 * sa) - sb;
476 if (q > 0) rho_ = one *
sqrt(q / sa);
477 if (q < 0) rho_ = ci *
sqrt(-q / sa);
483 double mpi_ = 0.13957;
484 EvtComplex one(1, 0);
485 EvtComplex rho_(0, 0);
487 double temp = 1 - 16 * mpi_ * mpi_ / sa;
488 if (temp > 0) rho_ = one *
sqrt(temp) / (1 + exp(9.8 - 3.5 * sa));
489 if (temp < 0) rho_ = ci *
sqrt(-temp) / (1 + exp(9.8 - 3.5 * sa));
496 EvtComplex prop = 1.0 / (mass_ * mass_ - sx - ci * mass_ * width_);
501 double widm(0.), q(0.), q0(0.);
502 double sa0 = mass_ * mass_;
504 q =
Qabcs(sa, sb, sc);
505 q0 =
Qabcs(sa0, sb, sc);
512 if (l == 1) F =
sqrt((1 + z0) / (1 + z));
513 if (l == 2) F =
sqrt((9 + 3 * z0 + z0 * z0) / (9 + 3 * z + z * z));
514 widm = pow(t, l + 0.5) * mass_ / m * F * F;
520 h = 2 / pi * q / m * log((m + 2 * q) / (2 * mpi));
525 double dh =
h(mass_, q0) * (1.0 / (8 * q0 * q0) - 1.0 / (2 * mass_ * mass_)) + 1.0 / (2 * pi * mass_ * mass_);
528 double EvtDToKSpipipi::f(
const double mass_,
const double sx,
const double q0,
const double q)
const
531 double f = mass_ * mass_ / (pow(q0, 3)) * (q * q * (
h(m, q) -
h(mass_, q0)) + (mass_ * mass_ - sx) * q0 * q0 *
dh(mass_, q0));
536 double d = 3.0 / pi * mpi * mpi / (q0 * q0) * log((mass_ + 2 * q0) / (2 * mpi)) + mass_ / (2 * pi * q0) - (mpi * mpi * mass_) /
541 const double sc,
const double r,
const int l)
const
544 EvtComplex prop = 1.0 / (mass_ * mass_ - sa - ci * mass_ * width_ *
wid(mass_, sa, sb, sc, r, l));
548 const double r,
const int l)
const
551 double q =
Qabcs(sa, sb, sc);
552 double sa0 = mass_ * mass_;
553 double q0 =
Qabcs(sa0, sb, sc);
556 EvtComplex prop = (1 +
d(mass_, q0) * width_ / mass_) / (mass_ * mass_ - sa + width_ *
f(mass_, sa, q0,
557 q) - ci * mass_ * width_ *
wid(mass_, sa, sb, sc, r, l));
563 for (
int i = 0; i != 4; i++) {
564 dot += a1[i] * a2[i] * G[i][i];
570 double Qabcs = (sa + sb - sc) * (sa + sb - sc) / (4 * sa) - sb;
576 double q =
Qabcs(sa, sb, sc);
585 F =
sqrt((2 * z) / (1 + z));
588 F =
sqrt((13 * z * z) / (9 + 3 * z + z * z));
596 for (
int i = 0; i != 4; i++) {
597 pa[i] = daug1[i] + daug2[i];
598 qa[i] = daug1[i] - daug2[i];
602 for (
int i = 0; i != 4; i++) {
603 t1[i] = qa[i] - pq / p * pa[i];
610 calt1(daug1, daug2, t1);
612 for (
int i = 0; i != 4; i++) {
613 pa[i] = daug1[i] + daug2[i];
616 for (
int i = 0; i != 4; i++) {
617 for (
int j = 0; j != 4; j++) {
618 t2[i][j] = t1[i] * t1[j] - 1.0 / 3 * r * (G[i][j] - pa[i] * pa[j] / p);
double mD
Fixed parameters.
EvtComplex getprop(double daug1[], double daug2[], double mass, double width, int flag, int L)
Propagator Lineshapes.
double f(const double mass, const double sx, const double q0, const double q) const
f function in Gounaris-Sakurai lineshape
EvtComplex D2AP_A2VP(double P1[], double P2[], double P3[], double P4[], int L)
Amplitude modes.
EvtComplex propagatorGS(const double mass, const double width, const double sa, const double sb, const double sc, const double r, const int l) const
Gounaris-Sakurai lineshape Function.
double calPDF(double Km[], double Pip1[], double Pip2[], double Pim[])
Probability distribution function of the decay.
double Qabcs(const double sa, const double sb, const double sc) const
Magnitudes of daughter particle momenta in the rest system of the mother particle.
void calt1(double daug1[], double daug2[], double t1[]) const
Covariant Spin-1 Projector.
EvtComplex propogator(const double mass, const double width, const double sx) const
Relativistic Breit-Wigner Lineshape Function (Fixed Width)
EvtComplex KPiSFormfactor(const double sa, const double sb, const double sc, const double r)
K pi S-wave form factor.
EvtComplex propagatorRBW(const double mass, const double width, const double sa, const double sb, const double sc, const double r, const int l) const
Relativistic Breit-Wigner Lineshape Function.
double dh(const double mass, const double q0) const
derivative h function in Gounaris-Sakurai lineshape
double wid(const double mass, const double sa, const double sb, const double sc, const double r, const int l) const
Energy Dependent Width.
double barrier(const double l, const double sa, const double sb, const double sc, const double r) const
Blatt-Weisskopf barrier factors.
double d(const double mass, const double q0) const
d function in Gounaris-Sakurai lineshape
double atan(double a)
atan for double
EvtComplex rho4Pi(const double sa)
Two-body Phase-space Function (Two Pions)
EvtComplex rhoab(const double sa, const double sb, const double sc)
Two-body Phase-space Function.
#define B2_EVTGEN_REGISTER_MODEL(classname)
Class to register B2_EVTGEN_REGISTER_MODEL.
double sqrt(double a)
sqrt for double
void calt2(double daug1[], double daug2[], double t2[][4]) const
Covariant Spin-2 Projector.
double h(const double m, const double q) const
h function in Gounaris-Sakurai lineshape
double dot(double *a1, double *a2) const
Four-Vector Scalar Product.
Abstract base class for different kinds of events.