9#include "generators/evtgen/EvtGenModelRegister.h"
10#include "generators/evtgen/models/EvtBToDstarlnuNP.h"
12#include "EvtGenBase/EvtGenKine.hh"
13#include "EvtGenBase/EvtPDL.hh"
14#include "EvtGenBase/EvtParticle.hh"
15#include "EvtGenBase/EvtDiracSpinor.hh"
16#include "EvtGenBase/EvtTensor4C.hh"
17#include "EvtGenBase/EvtVector4C.hh"
18#include "EvtGenBase/EvtScalarParticle.hh"
27 return "BTODSTARLNUNP";
37 p->initializePhaseSpace(getNDaug(), getDaugs());
51 if (!(n == 0 || (n - 1) % 3 == 0)) {
52 EvtGenReport(EVTGEN_ERROR,
"EvtGen")
53 <<
"Error in parameters in the BTODSTARLNUNP decay model." << endl;
54 EvtGenReport(EVTGEN_ERROR,
"EvtGen")
55 <<
"Will terminate execution!" << endl;
64 checkSpinParent(EvtSpinType::SCALAR);
65 checkSpinDaughter(1, EvtSpinType::DIRAC);
66 checkSpinDaughter(2, EvtSpinType::NEUTRINO);
68 EvtId mId = getDaug(0);
69 EvtId IdDst0 = EvtPDL::getId(
"D*0"), IdaDst0 = EvtPDL::getId(
"anti-D*0"),
70 IdDstp = EvtPDL::getId(
"D*+"), IdDstm = EvtPDL::getId(
"D*-");
71 if (mId != IdDst0 && mId != IdaDst0 && mId != IdDstp && mId != IdDstm) {
72 EvtGenReport(EVTGEN_ERROR,
"EvtGen")
73 <<
"EvtBToDstarlnuNP generator expected a D* 1st daughter, found: "
74 << EvtPDL::name(getDaug(0)) << endl;
75 EvtGenReport(EVTGEN_ERROR,
"EvtGen")
76 <<
"Will terminate execution!" << endl;
80 auto getInteger = [
this](
int i) ->
int {
82 if (a -
static_cast<int>(a) != 0)
84 EvtGenReport(EVTGEN_ERROR,
"EvtGen")
85 <<
"Parameters is not integer in the BTODSTARLNUNP decay model: " << i <<
" " << a << endl;
86 EvtGenReport(EVTGEN_ERROR,
"EvtGen")
87 <<
"Will terminate execution!" << endl;
90 return static_cast<int>(a);
94 int i = 0, coordsyst = getInteger(i++);
96 int id = getInteger(i++);
97 double a0 = getArg(i++);
98 double a1 = getArg(i++);
99 EvtComplex c = (coordsyst) ? EvtComplex(a0 * cos(a1), a0 * sin(a1)) : EvtComplex(a0, a1);
100 if (
id == 0)
_Cvl = c;
101 if (
id == 1)
_Cvr = c;
102 if (
id == 2)
_Csl = c;
103 if (
id == 3)
_Csr = c;
104 if (
id == 4)
_cT = c;
109static EvtTensor4C asymProd(
const EvtVector4R& a,
const EvtVector4R& b)
115 double t01 = a.get(2) * b.get(3) - a.get(3) * b.get(2);
118 double t02 = a.get(3) * b.get(1) - a.get(1) * b.get(3);
121 double t03 = a.get(1) * b.get(2) - a.get(2) * b.get(1);
124 double t12 = a.get(0) * b.get(3) - a.get(3) * b.get(0);
127 double t13 = a.get(2) * b.get(0) - a.get(0) * b.get(2);
130 double t23 = a.get(0) * b.get(1) - a.get(1) * b.get(0);
136static EvtComplex asymProd(
const EvtTensor4C& t1,
const EvtTensor4C& t2)
141 sum += t1.get(0, 1) * t2.get(2, 3);
142 sum -= t1.get(0, 1) * t2.get(3, 2);
143 sum -= t1.get(0, 2) * t2.get(1, 3);
144 sum += t1.get(0, 2) * t2.get(3, 1);
145 sum += t1.get(0, 3) * t2.get(1, 2);
146 sum -= t1.get(0, 3) * t2.get(2, 1);
147 sum -= t1.get(1, 0) * t2.get(2, 3);
148 sum += t1.get(1, 0) * t2.get(3, 2);
149 sum += t1.get(1, 2) * t2.get(0, 3);
150 sum -= t1.get(1, 2) * t2.get(3, 0);
151 sum -= t1.get(1, 3) * t2.get(0, 2);
152 sum += t1.get(1, 3) * t2.get(2, 0);
153 sum += t1.get(2, 0) * t2.get(1, 3);
154 sum -= t1.get(2, 0) * t2.get(3, 1);
155 sum -= t1.get(2, 1) * t2.get(0, 3);
156 sum += t1.get(2, 1) * t2.get(3, 0);
157 sum += t1.get(2, 3) * t2.get(0, 1);
158 sum -= t1.get(2, 3) * t2.get(1, 0);
159 sum -= t1.get(3, 0) * t2.get(1, 2);
160 sum += t1.get(3, 0) * t2.get(2, 1);
161 sum += t1.get(3, 1) * t2.get(0, 2);
162 sum -= t1.get(3, 1) * t2.get(2, 0);
163 sum -= t1.get(3, 2) * t2.get(0, 1);
164 sum += t1.get(3, 2) * t2.get(1, 0);
171static void getFF(
double mB,
double mV,
double q2,
172 double& V,
double& A0,
double& A1,
double& A2,
double& T1,
double& T2,
double& T3)
176 const double m_c = 1.27,
179 double rmB = 1 / mB, r = mV / mB, r2 = r * r;
180 double c = 0.5 /
sqrt(mB * mV), mBaV = mB + mV, mBsV = mB - mV, rmBaV = 1 / mBaV, rmBsV = 1 / mBsV;
181 double w = (mB * mB + mV * mV - q2) / (2 * mB * mV), w2 = w * w, sqrtwa1 =
sqrt(w + 1);
182 double u = 1 + r2 - 2 * r * w;
183 double z = (sqrtwa1 -
sqrt(2)) / (sqrtwa1 +
sqrt(2));
200 a0F1 = a0f * (1 - r) / (
sqrt(2) * pow(1 +
sqrt(r), 2)),
203 a2F1 = -0.5162 * (104.455 * a0f + 34.7622 * a1F1 - 29.3161 * (a0F2 + 0.0557 * a1F2 + 0.0031 * a2F2)),
206 chi1minT0 = 5.131e-4,
207 chi1plusT0 = 3.894e-4,
208 chi1plusL0 = 1.9421e-2;
211 auto BlaschkeFactor = [mB, mV](
double zl,
unsigned n,
const double * m) ->
double {
212 double B = 1, t2 =
sqrt(4 * mB * mV), mBV = mB + mV, mBV2 = mBV * mBV;
213 for (
unsigned i = 0; i < n; i++)
215 double t1 =
sqrt(mBV2 - m[i] * m[i]), zp = (t1 - t2) / (t1 + t2);
216 B *= (zl - zp) / (1 - zl * zp);
221 static const double mP1plus[] = {6.739, 6.750, 7.145, 7.150};
222 double P1plus = BlaschkeFactor(z,
sizeof(mP1plus) /
sizeof(mP1plus[0]), mP1plus);
224 static const double mP1min[] = {6.329, 6.920, 7.020};
225 double P1min = BlaschkeFactor(z,
sizeof(mP1min) /
sizeof(mP1min[0]), mP1min);
227 static const double mP0min[] = {6.275, 6.842, 7.250};
228 double P0min = BlaschkeFactor(z,
sizeof(mP0min) /
sizeof(mP0min[0]), mP0min);
231 double zm = 1 - z, zp = 1 + z, szm =
sqrt(zm), d1 = (1 + r) * zm + 2 *
sqrt(r) * zp, d2 = d1 * d1, d4 = d2 * d2;
232 double phif = 4 * r / (mB * mB) *
sqrt(nI / (3 * M_PI * chi1plusT0)) * zp * (zm * szm) / d4;
233 double phig = 16 * r2 *
sqrt(nI / (3 * M_PI * chi1minT0)) * zp * zp / (szm * d4);
234 double phiF1 = 4 * r / (mB * mB * mB) *
sqrt(nI / (6 * M_PI * chi1plusT0)) * zp * (zm * zm * szm) / (d4 * d1);
235 double phiF2 = 8 *
sqrt(2) * r2 *
sqrt(nI / (M_PI * chi1plusL0)) * zp * zp / (szm * d4);
238 double ffunc = (a0f + z * (a1f + z * (a2f))) / (P1plus * phif);
239 double gfunc = (a0g + z * (a1g + z * (a2g))) / (P1min * phig);
240 double F1func = (a0F1 + z * (a1F1 + z * (a2F1))) / (P1plus * phiF1);
241 double F2func = (a0F2 + z * (a1F2 + z * (a2F2))) / (P0min * phiF2);
245 double hVw = mB *
sqrt(r) * gfunc;
246 double hA1w = ffunc / (mB *
sqrt(r) * (1 + w));
247 double hA2w = hA1w / (1 - w) + (F1func * (w - r) - F2func * mB * mB * r * (w2 - 1)) / (mB * mB *
sqrt(r) * u * (w2 - 1));
248 double hA3w = (F1func * (r * w - 1) + mB * mB *
sqrt(r) * (1 + w) * (F2func * r *
sqrt(r) * (w - 1) + hA1w * w * u)) /
249 (mB * mB *
sqrt(r) * u * (w2 - 1));
252 double cA1 = (m_b - m_c) * rmBsV * hA1w, cV = (m_b + m_c) * rmBaV * hVw;
253 double hT1 = (0.5 * ((1 - r) * (1 - r) * (w + 1) * cA1 - (1 + r) * (1 + r) * (w - 1) * cV)) / u;
254 double hT2 = (0.5 * (1 - r2) * (w + 1) * (cA1 - cV)) / u;
255 double hT3 = (-0.5 * (2 * r * (w + 1) * cA1 + (m_b - m_c) * rmBsV * u * (hA3w - r * hA2w) - (1 + r) * (1 + r) * cV)) / (u *
263 A0 = c * ((mBaV * mBaV - q2) / (2 * mV) * hA1w - (mBaV * mBsV + q2) / (2 * mB) * hA2w - (mBaV * mBsV - q2) / (2 * mV) * hA3w);
264 A1 = c * (mBaV * mBaV - q2) / mBaV * hA1w;
265 A2 = c * mBaV * (hA3w + r * hA2w);
266 T1 = c * (mBaV * hT1 - mBsV * hT2);
267 T2 = c * ((mBaV - q2 * rmBaV) * hT1 - (mBsV - q2 * rmBsV) * hT2);
268 T3 = c * (mBsV * hT1 - mBaV * hT2 - 2 * mBaV * mBsV * rmB * hT3);
271static EvtId EM, MUM, TAUM, EP, MUP, TAUP, D0, D0B, DP, DM, DSM, DSP;
272static bool cafirst =
true;
277 EM = EvtPDL::getId(
"e-"); EP = EvtPDL::getId(
"e+");
278 MUM = EvtPDL::getId(
"mu-"); MUP = EvtPDL::getId(
"mu+");
279 TAUM = EvtPDL::getId(
"tau-"); TAUP = EvtPDL::getId(
"tau+");
281 D0 = EvtPDL::getId(
"D0"); D0B = EvtPDL::getId(
"anti-D0");
282 DP = EvtPDL::getId(
"D+"); DM = EvtPDL::getId(
"D-");
283 DSP = EvtPDL::getId(
"D_s+"); DSM = EvtPDL::getId(
"D_s-");
287 *pvm = parent->getDaug(0),
288 *plp = parent->getDaug(1),
289 *pnu = parent->getDaug(2);
290 EvtId pId = parent->getId(), lId = plp->getId();
293 EvtVector4R q = plp->getP4() + pnu->getP4();
294 double q2 = q.mass2(), m_V = pvm->mass(), m_B = parent->mass();
295 double m_BaV = m_B + m_V, m_BsV = m_B - m_V;
297 double a1f, a2f, vf, a0f, a3f;
300 getFF(m_B, m_V, q2, vf, a0f, a1f, a2f, T1, T2, T3);
301 a3f = (m_BaV * a1f - m_BsV * a2f) / (2.0 * m_V);
303 double c1 = (m_BaV * m_BsV * (T1 - T2)) / q2;
304 double c2 = (T1 - T2 - T3 * q2 / (m_BaV * m_BsV)) * 2 / q2;
306 if (pId == D0 || pId == D0B || pId == DP || pId == DM || pId == DSP || pId == DSM)
309 EvtVector4R p(m_B, 0., 0., 0.);
310 const EvtVector4R& k = pvm->getP4();
311 EvtVector4R pak = p + k;
314 nu = pnu->spParentNeutrino(), lp0 = plp->spParent(0), lp1 = plp->spParent(1);
318 EvtVector4C l1, l2, a1, a2;
319 EvtTensor4C z1, z2, w1, w2;
320 if (lId == EM || lId == MUM || lId == TAUM) {
321 l1 = EvtLeptonVCurrent(nu, lp0);
322 l2 = EvtLeptonVCurrent(nu, lp1);
323 a1 = EvtLeptonACurrent(nu, lp0);
324 a2 = EvtLeptonACurrent(nu, lp1);
325 p1 = EvtLeptonPCurrent(nu, lp0);
326 p2 = EvtLeptonPCurrent(nu, lp1);
327 z1 = EvtLeptonTCurrent(nu, lp0);
328 z2 = EvtLeptonTCurrent(nu, lp1);
329 }
else if (lId == EP || lId == MUP || lId == TAUP) {
331 l1 = EvtLeptonVCurrent(lp0, nu);
332 l2 = EvtLeptonVCurrent(lp1, nu);
333 a1 = EvtLeptonACurrent(lp0, nu);
334 a2 = EvtLeptonACurrent(lp1, nu);
335 p1 = EvtLeptonPCurrent(lp0, nu);
336 p2 = EvtLeptonPCurrent(lp1, nu);
337 z1 = EvtLeptonTCurrent(lp0, nu);
338 z2 = EvtLeptonTCurrent(lp1, nu);
342 double m_c = 1.27, m_b = 4.18;
345 EvtComplex C_V_L = 1,
354 EvtTensor4C tA = (a1f * m_BaV) * EvtTensor4C::g();
355 tA.addDirProd(-(a2f / m_BaV) * p, pak);
356 tA.addDirProd(-2 * m_V / q2 * (a3f - a0f) * p, q);
359 EvtTensor4C tV = EvtComplex(0.0, (-2 * vf / m_BaV)) * asymProd(p, k);
361 EvtTensor4C tVA = 0.5 * (C_V_L + C_V_R) * tV + 0.5 * (C_V_R - C_V_L) * tA;
363 EvtComplex tS = 0.5 * (C_S_R - C_S_L) * 2 * m_V / (m_b + m_c) * a0f;
366 EvtVector4C qc1(q); qc1 *= c1;
368 EvtComplex sum1, sum2, TT1, TT2;
369 for (
int i = 0; i < 3; i++) {
370 EvtVector4C eps = pvm->epsParent(i).conj(), epsTVA = tVA.cont1(eps);
371 EvtComplex epsq = eps * q, epsqc2 = epsq * c2;
374 for (
int i2 = 0; i2 < 4; i2++) {
375 for (
int i3 = 0; i3 < 4; i3++) {
376 tt.set(i2, i3, eps.get(i2) * (-pak.get(i3) + qc1.get(i3)) + p.get(i2)*k.get(i3)*epsqc2);
379 if (lId == EM || lId == MUM || lId == TAUM) {
380 TT1 = EvtComplex(0.0, 1.0) * C_T * (asymProd(z1, tt));
381 TT2 = EvtComplex(0.0, 1.0) * C_T * (asymProd(z2, tt));
382 sum1 = l1.cont(epsTVA) - a1.cont(epsTVA) - epsq * tS * p1 + TT1;
383 sum2 = l2.cont(epsTVA) - a2.cont(epsTVA) - epsq * tS * p2 + TT2;
384 }
else if (lId == EP || lId == MUP || lId == TAUP) {
385 TT1 = EvtComplex(0.0, -1.0) * conj(C_T) * (asymProd(z1, tt));
386 TT2 = EvtComplex(0.0, -1.0) * conj(C_T) * (asymProd(z2, tt));
387 sum1 = l1.cont(epsTVA) - a1.cont(epsTVA) - epsq * tS * p1 + TT1;
388 sum2 = l2.cont(epsTVA) - a2.cont(epsTVA) - epsq * tS * p2 + TT2;
391 amp.vertex(i, 0, sum1);
392 amp.vertex(i, 1, sum2);
409 EvtId pId = getParentId(), mId = getDaug(0), l1Id = getDaug(1), l2Id = getDaug(2);
411 EvtScalarParticle* scalar_part;
412 EvtParticle* root_part;
414 scalar_part =
new EvtScalarParticle;
417 scalar_part->noLifeTime();
421 p_init.set(EvtPDL::getMass(pId), 0.0, 0.0, 0.0);
422 scalar_part->init(pId, p_init);
423 root_part = (EvtParticle*)scalar_part;
424 root_part->setDiagonalSpinDensity();
432 amp.init(pId, 3, listdaug);
434 root_part->makeDaughters(3, listdaug);
435 EvtParticle* daughter, *lep, *trino;
436 daughter = root_part->getDaug(0);
437 lep = root_part->getDaug(1);
438 trino = root_part->getDaug(2);
441 daughter->noLifeTime();
448 rho.setDiag(root_part->getSpinStates());
450 EvtVector4R p4meson, p4lepton, p4nu, p4w;
451 double mass[3], m = root_part->mass(), maxfoundprob = 0.0;
453 for (
int massiter = 0; massiter < 3; massiter++) {
454 mass[0] = EvtPDL::getMeanMass(mId);
455 mass[1] = EvtPDL::getMeanMass(l1Id);
456 mass[2] = EvtPDL::getMeanMass(l2Id);
458 mass[0] = EvtPDL::getMinMass(mId);
461 mass[0] = EvtPDL::getMaxMass(mId);
462 if ((mass[0] + mass[1] + mass[2]) > m)
463 mass[0] = m - mass[1] - mass[2] - 0.00001;
466 double q2min = mass[1] * mass[1], q2max = (m - mass[0]) * (m - mass[0]);
468 for (
int imax = 40, i = 0; i < imax; i++) {
469 double q2 = q2min + ((i + 0.5) * (q2max - q2min)) / imax;
470 double erho = (m * m + mass[0] * mass[0] - q2) / (2.0 * m);
471 double prho = sqrt(erho * erho - mass[0] * mass[0]);
472 p4meson.set(erho, 0.0, 0.0, -1.0 * prho);
473 p4w.set(m - erho, 0.0, 0.0, prho);
476 double elepton = (q2 + mass[1] * mass[1]) / (2.0 * sqrt(q2));
477 double plepton = sqrt(elepton * elepton - mass[1] * mass[1]);
480 for (
int j = 0; j < 3; j++) {
481 double costl = 0.99 * (j - 1.0);
485 p4lepton.set(elepton, 0.0, plepton * sqrt(1.0 - costl * costl),
487 p4nu.set(plepton, 0.0,
488 -1.0 * plepton * sqrt(1.0 - costl * costl),
489 -1.0 * plepton * costl);
491 EvtVector4R boost((m - erho), 0.0, 0.0, 1.0 * prho);
492 p4lepton = boostTo(p4lepton, boost);
493 p4nu = boostTo(p4nu, boost);
497 daughter->init(mId, p4meson);
498 lep->init(l1Id, p4lepton);
499 trino->init(l2Id, p4nu);
507 probctl[j] = rho.normalizedProb(amp.getSpinDensity());
513 double a = probctl[1];
514 double b = 0.5 * (probctl[2] - probctl[0]);
515 double c = 0.5 * (probctl[2] + probctl[0]) - probctl[1];
517 double prob = probctl[0];
518 if (probctl[1] > prob)
520 if (probctl[2] > prob)
523 if (fabs(c) > 1e-20) {
524 double ctlx = -0.5 * b / c;
525 if (fabs(ctlx) < 1.0) {
526 double probtmp = a + b * ctlx + c * ctlx * ctlx;
532 if (prob > maxfoundprob) {
536 if (EvtPDL::getWidth(mId) <= 0.0) {
541 root_part->deleteTree();
Implementation of with new physics contributions and the BGL hadronic form factor parameterization.
EvtComplex _cT
C_T – tensor current.
EvtDecayBase * clone() override
The function which makes a copy of the model.
EvtComplex _Cvl
Strength of the left handed part of the vector hadronic current.
void decay(EvtParticle *p) override
The method to calculate a decay amplitude.
EvtComplex _Cvr
Strength of the Right handed part of the vector hadronic current.
EvtComplex _Csr
(g_S + g_P) strength of pseudoscalar current with constraint _Csl = -_Csr
std::string getName() override
The function which returns the name of the model.
void CalcAmp(EvtParticle *, EvtAmp &)
The method to evaluate the decay amplitude.
void init() override
Initialization method.
EvtComplex _Csl
(g_S - g_P) strength of pseudoscalar current
void initProbMax() override
The method to evaluate the maximum amplitude.
double CalcMaxProb()
The method to evaluate the maximum decay amplitude.
#define B2_EVTGEN_REGISTER_MODEL(classname)
Class to register B2_EVTGEN_REGISTER_MODEL.
double sqrt(double a)
sqrt for double