1 // HelicityMatrixElements.cc is a part of the PYTHIA event generator.
2 // Copyright (C) 2013 Philip Ilten, Torbjorn Sjostrand.
3 // PYTHIA is licenced under the GNU GPL version 2, see COPYING for details.
4 // Please respect the MCnet Guidelines, see GUIDELINES for details.
6 // Function definitions (not found in the header) for physics classes
9 #include "HelicityMatrixElements.h"
13 //==========================================================================
15 // The HelicityMatrixElements class.
17 //--------------------------------------------------------------------------
19 // Initialize the helicity matrix element.
21 void HelicityMatrixElement::initPointers(ParticleData* particleDataPtrIn,
22 Couplings* couplingsPtrIn) {
24 particleDataPtr = particleDataPtrIn;
25 couplingsPtr = couplingsPtrIn;
26 for(int i = 0; i <= 5; i++)
27 gamma.push_back(GammaMatrix(i));
31 //--------------------------------------------------------------------------
33 // Initialize the channel for the helicity matrix element.
35 HelicityMatrixElement* HelicityMatrixElement::initChannel(
36 vector<HelicityParticle>& p) {
40 for(int i = 0; i < static_cast<int>(p.size()); i++) {
41 pID.push_back(p[i].id());
42 pM.push_back(p[i].m());
49 //--------------------------------------------------------------------------
51 // Calculate a particle's decay matrix.
53 void HelicityMatrixElement::calculateD(vector<HelicityParticle>& p) {
55 // Reset the D matrix to zero.
56 for (int i = 0; i < p[0].spinStates(); i++) {
57 for (int j = 0; j < p[0].spinStates(); j++) {
62 // Initialize the wave functions.
65 // Create the helicity vectors.
66 vector<int> h1(p.size(),0);
67 vector<int> h2(p.size(),0);
69 // Call the recursive sub-method.
70 calculateD(p, h1, h2, 0);
72 // Normalize the decay matrix.
73 p[0].normalize(p[0].D);
77 //--------------------------------------------------------------------------
79 // Recursive sub-method for calculating a particle's decay matrix.
81 void HelicityMatrixElement::calculateD(vector<HelicityParticle>& p,
82 vector<int>& h1, vector<int>& h2, unsigned int i) {
85 for (h1[i] = 0; h1[i] < p[i].spinStates(); h1[i]++) {
86 for (h2[i] = 0; h2[i] < p[i].spinStates(); h2[i]++) {
87 calculateD(p, h1, h2, i+1);
92 p[0].D[h1[0]][h2[0]] += calculateME(h1) * conj(calculateME(h2)) *
93 calculateProductD(p, h1, h2);
98 //--------------------------------------------------------------------------
100 // Calculate a particle's helicity density matrix.
102 void HelicityMatrixElement::calculateRho(unsigned int idx,
103 vector<HelicityParticle>& p) {
105 // Reset the rho matrix to zero.
106 for (int i = 0; i < p[idx].spinStates(); i++) {
107 for (int j = 0; j < p[idx].spinStates(); j++) {
108 p[idx].rho[i][j] = 0;
112 // Initialize the wave functions.
115 // Create the helicity vectors.
116 vector<int> h1(p.size(),0);
117 vector<int> h2(p.size(),0);
119 // Call the recursive sub-method.
120 calculateRho(idx, p, h1, h2, 0);
122 // Normalize the density matrix.
123 p[idx].normalize(p[idx].rho);
127 //--------------------------------------------------------------------------
129 // Recursive sub-method for calculating a particle's helicity density matrix.
131 void HelicityMatrixElement::calculateRho(unsigned int idx,
132 vector<HelicityParticle>& p, vector<int>& h1, vector<int>& h2,
136 for (h1[i] = 0; h1[i] < p[i].spinStates(); h1[i]++) {
137 for (h2[i] = 0; h2[i] < p[i].spinStates(); h2[i]++) {
138 calculateRho(idx, p, h1, h2, i+1);
143 // Calculate rho from a hard process.
144 if (p[1].direction < 0)
145 p[idx].rho[h1[idx]][h2[idx]] += p[0].rho[h1[0]][h2[0]] *
146 p[1].rho[h1[1]][h2[1]] * calculateME(h1)*conj(calculateME(h2)) *
147 calculateProductD(idx, 2, p, h1, h2);
148 // Calculate rho from a decay.
150 p[idx].rho[h1[idx]][h2[idx]] += p[0].rho[h1[0]][h2[0]] *
151 calculateME(h1)*conj(calculateME(h2)) *
152 calculateProductD(idx, 1, p, h1, h2);
158 //--------------------------------------------------------------------------
160 // Calculate a decay's weight.
162 double HelicityMatrixElement::decayWeight(vector<HelicityParticle>& p) {
164 complex weight = complex(0,0);
166 // Initialize the wave functions.
169 // Create the helicity vectors.
170 vector<int> h1(p.size(),0);
171 vector<int> h2(p.size(),0);
173 // Call the recursive sub-method.
174 decayWeight(p, h1, h2, weight, 0);
180 //--------------------------------------------------------------------------
182 // Recursive sub-method for calculating a decay's weight.
184 void HelicityMatrixElement::decayWeight(vector<HelicityParticle>& p,
185 vector<int>& h1, vector<int>& h2, complex& weight, unsigned int i) {
188 for (h1[i] = 0; h1[i] < p[i].spinStates(); h1[i]++) {
189 for (h2[i] = 0; h2[i] < p[i].spinStates(); h2[i]++) {
190 decayWeight(p, h1, h2, weight, i+1);
195 weight += p[0].rho[h1[0]][h2[0]] * calculateME(h1) *
196 conj(calculateME(h2)) * calculateProductD(p, h1, h2);
201 //--------------------------------------------------------------------------
203 // Calculate the product of the decay matrices (hard process).
205 complex HelicityMatrixElement::calculateProductD(unsigned int idx,
206 unsigned int start, vector<HelicityParticle>& p,
207 vector<int>& h1, vector<int>& h2) {
210 for (unsigned int i = start; i < p.size(); i++) {
212 answer *= p[i].D[h1[i]][h2[i]];
219 //--------------------------------------------------------------------------
221 // Calculate the product of the decay matrices (decay process).
223 complex HelicityMatrixElement::calculateProductD(
224 vector<HelicityParticle>& p, vector<int>& h1, vector<int>& h2) {
227 for (unsigned int i = 1; i < p.size(); i++) {
228 answer *= p[i].D[h1[i]][h2[i]];
234 //--------------------------------------------------------------------------
236 // Initialize a fermion line.
238 void HelicityMatrixElement::setFermionLine(int position,
239 HelicityParticle& p0, HelicityParticle& p1) {
241 vector< Wave4 > u0, u1;
243 // First particle is incoming and particle, or outgoing and anti-particle.
244 if (p0.id()*p0.direction < 0) {
245 pMap[position] = position; pMap[position+1] = position+1;
246 for (int h = 0; h < p0.spinStates(); h++) u0.push_back(p0.wave(h));
247 for (int h = 0; h < p1.spinStates(); h++) u1.push_back(p1.waveBar(h));
249 // First particle is outgoing and particle, or incoming and anti-particle.
251 pMap[position] = position+1; pMap[position+1] = position;
252 for (int h = 0; h < p0.spinStates(); h++) u1.push_back(p0.waveBar(h));
253 for (int h = 0; h < p1.spinStates(); h++) u0.push_back(p1.wave(h));
255 u.push_back(u0); u.push_back(u1);
259 //--------------------------------------------------------------------------
261 // Return a fixed width Breit-Wigner.
263 complex HelicityMatrixElement::breitWigner(double s, double M, double G) {
265 return (-M*M + complex(0, 1) * M * G) / (s - M*M + complex(0, 1) * M * G);
269 //--------------------------------------------------------------------------
271 // Return an s-wave BreitWigner.
273 complex HelicityMatrixElement::sBreitWigner(double m0, double m1, double s,
274 double M, double G) {
276 double gs = sqrtpos((s - pow2(m0+m1)) * (s - pow2(m0-m1))) / (2*sqrtpos(s));
277 double gM = sqrtpos((M*M - pow2(m0+m1)) * (M*M - pow2(m0-m1))) / (2*M);
278 return M*M / (M*M - s - complex(0,1)*G*M*M/sqrtpos(s)*(gs/gM));
282 //--------------------------------------------------------------------------
284 // Return a p-wave BreitWigner.
286 complex HelicityMatrixElement::pBreitWigner(double m0, double m1, double s,
287 double M, double G) {
289 double gs = sqrtpos((s - pow2(m0+m1)) * (s - pow2(m0-m1))) / (2*sqrtpos(s));
290 double gM = sqrtpos((M*M - pow2(m0+m1)) * (M*M - pow2(m0-m1))) / (2*M);
291 return M*M / (M*M - s - complex(0,1)*G*M*M/sqrtpos(s)*pow3(gs/gM));
295 //--------------------------------------------------------------------------
297 // Return a d-wave BreitWigner.
299 complex HelicityMatrixElement::dBreitWigner(double m0, double m1, double s,
300 double M, double G) {
302 double gs = sqrtpos((s - pow2(m0+m1)) * (s - pow2(m0-m1))) / (2*sqrtpos(s));
303 double gM = sqrtpos((M*M - pow2(m0+m1)) * (M*M - pow2(m0-m1))) / (2*M);
304 return M*M / (M*M - s - complex(0,1)*G*M*M/sqrtpos(s)*pow5(gs/gM));
308 //==========================================================================
310 // Helicity matrix element for two fermions -> W -> two fermions. This matrix
311 // element handles s-channel hard processes in addition to t-channel, assuming
312 // the first two particles are a fermion line and the second two particles
313 // are a fermion line. This matrix element is not scaled with respect to W
314 // propagator energy as currently this matrix element is used only for
315 // calculating helicity density matrices.
317 //--------------------------------------------------------------------------
319 // Initialize spinors for the helicity matrix element.
321 void HMETwoFermions2W2TwoFermions::initWaves(vector<HelicityParticle>& p) {
325 setFermionLine(0,p[0],p[1]);
326 setFermionLine(2,p[2],p[3]);
330 //--------------------------------------------------------------------------
332 // Return element for the helicity matrix element.
334 complex HMETwoFermions2W2TwoFermions::calculateME(vector<int> h) {
337 for (int mu = 0; mu <= 3; mu++) {
338 answer += (u[1][h[pMap[1]]] * gamma[mu] * (1 - gamma[5])
339 * u[0][h[pMap[0]]]) * gamma[4](mu,mu) * (u[3][h[pMap[3]]]
340 * gamma[mu] * (1 - gamma[5]) * u[2][h[pMap[2]]]);
346 //==========================================================================
348 // Helicity matrix element for two fermions -> photon -> two fermions. This
349 // matrix element can be combined with the Z matrix element to provide full
350 // interference effects.
352 // p0Q: charge of the incoming fermion line
353 // p2Q: charge of the outgoing fermion line
354 // s: center of mass energy
356 //--------------------------------------------------------------------------
358 // Initialize wave functions for the helicity matrix element.
360 void HMETwoFermions2Gamma2TwoFermions::initWaves(
361 vector<HelicityParticle>& p) {
365 setFermionLine(0, p[0], p[1]);
366 setFermionLine(2, p[2], p[3]);
367 s = max( 1., pow2(p[4].m()));
368 p0Q = p[0].charge(); p2Q = p[2].charge();
372 //--------------------------------------------------------------------------
374 // Return element for the helicity matrix element.
377 complex HMETwoFermions2Gamma2TwoFermions::calculateME(vector<int> h) {
380 for (int mu = 0; mu <= 3; mu++) {
381 answer += (u[1][h[pMap[1]]] * gamma[mu] * u[0][h[pMap[0]]])
382 * gamma[4](mu,mu) * (u[3][h[pMap[3]]] * gamma[mu] * u[2][h[pMap[2]]]);
384 return p0Q*p2Q * answer / s;
388 //==========================================================================
390 // Helicity matrix element for two fermions -> Z -> two fermions. This matrix
391 // element can be combined with the photon matrix element to provide full
392 // interference effects.
394 // Note that there is a double contraction in the Z matrix element, which can
395 // be very time consuming. If the two incoming fermions are oriented along
396 // the z-axis, their helicities must be opposite for a non-zero matrix element
397 // term. Consequently, this check is made to help speed up the matrix element.
399 // sin2W: sine of the Weinberg angle
400 // cos2W: cosine of the Weinberg angle
401 // zM: on-shell mass of the Z
402 // zG: on-shell width of the Z
403 // p0CA: axial coupling of particle 0 to the Z
404 // p2CA: axial coupling of particle 2 to the Z
405 // p0CV: vector coupling of particle 0 to the Z
406 // p2CV: vector coupling of particle 2 to the Z
407 // zaxis: true if the incoming fermions are oriented along the z-axis
409 //--------------------------------------------------------------------------
411 // Initialize the constant for the helicity matrix element.
413 void HMETwoFermions2Z2TwoFermions::initConstants() {
415 // Set the Weinberg angle.
416 sin2W = couplingsPtr->sin2thetaW();
417 cos2W = couplingsPtr->cos2thetaW();
418 // Set the on-shell Z mass and width.
419 zG = particleDataPtr->mWidth(23);
420 zM = particleDataPtr->m0(23);
421 // Set the vector and axial couplings to the fermions.
422 p0CA = couplingsPtr->af(abs(pID[0]));
423 p2CA = couplingsPtr->af(abs(pID[2]));
424 p0CV = couplingsPtr->vf(abs(pID[0]));
425 p2CV = couplingsPtr->vf(abs(pID[2]));
429 //--------------------------------------------------------------------------
431 // Initialize wave functions for the helicity matrix element.
433 void HMETwoFermions2Z2TwoFermions::initWaves(vector<HelicityParticle>& p) {
438 setFermionLine(0, p[0], p[1]);
439 setFermionLine(2, p[2], p[3]);
440 u4.push_back(Wave4(p[2].p() + p[3].p()));
442 // Center of mass energy.
443 s = max( 1., pow2(p[4].m()));
444 // Check if incoming fermions are oriented along z-axis.
445 zaxis = (p[0].pAbs() == fabs(p[0].pz())) &&
446 (p[1].pAbs() == fabs(p[1].pz()));
450 //--------------------------------------------------------------------------
452 // Return element for helicity matrix element.
454 complex HMETwoFermions2Z2TwoFermions::calculateME(vector<int> h) {
457 // Return zero if correct helicity conditions.
458 if (h[0] == h[1] && zaxis) return answer;
459 for (int mu = 0; mu <= 3; mu++) {
460 for (int nu = 0; nu <= 3; nu++) {
462 (u[1][h[pMap[1]]] * gamma[mu] * (p0CV - p0CA * gamma[5]) *
464 (gamma[4](mu,nu) - gamma[4](mu,mu)*u[4][0](mu) *
465 gamma[4](nu,nu) * u[4][0](nu) / (zM*zM)) *
466 (u[3][h[pMap[3]]] * gamma[nu] * (p2CV - p2CA * gamma[5]) *
470 return answer / (16 * pow2(sin2W * cos2W) *
471 (s - zM*zM + complex(0, s*zG/zM)));
475 //==========================================================================
477 // Helicity matrix element for two fermions -> photon/Z -> two fermions. Full
478 // interference is obtained by combining the photon and Z helicity matrix
481 // In general the initPointers and initChannel methods should not be
484 //--------------------------------------------------------------------------
486 // Initialize the matrix element.
488 void HMETwoFermions2GammaZ2TwoFermions::initPointers(
489 ParticleData* particleDataPtrIn, Couplings* couplingsPtrIn) {
491 zHME.initPointers(particleDataPtrIn, couplingsPtrIn);
492 gHME.initPointers(particleDataPtrIn, couplingsPtrIn);
496 //--------------------------------------------------------------------------
498 // Initialize the channel for the helicity matrix element.
500 HelicityMatrixElement* HMETwoFermions2GammaZ2TwoFermions::initChannel(
501 vector<HelicityParticle>& p) {
509 //--------------------------------------------------------------------------
511 // Initialize wave functions for the helicity matrix element.
513 void HMETwoFermions2GammaZ2TwoFermions::initWaves(
514 vector<HelicityParticle>& p) {
521 //--------------------------------------------------------------------------
523 // Return element for the helicity matrix element.
525 complex HMETwoFermions2GammaZ2TwoFermions::calculateME(vector<int> h) {
527 return zHME.calculateME(h) + gHME.calculateME(h);
531 //==========================================================================
533 // Helicity matrix element for Z -> two fermions.
535 // Helicity matrix element for Z -> two fermions. This matrix element is used
536 // when the production of the Z is from an unknown process.
538 // p2CA: axial coupling of particle 2 to the Z
539 // p2CV: vector coupling of particle 2 to the Z
541 //--------------------------------------------------------------------------
543 // Initialize the constant for the helicity matrix element.
545 void HMEZ2TwoFermions::initConstants() {
547 // Set the vector and axial couplings to the fermions.
548 p2CA = couplingsPtr->af(abs(pID[2]));
549 p2CV = couplingsPtr->vf(abs(pID[2]));
553 //--------------------------------------------------------------------------
555 // Initialize wave functions for the helicity matrix element.
557 void HMEZ2TwoFermions::initWaves(vector<HelicityParticle>& p) {
561 // Initialize Z wave function.
564 for (int h = 0; h < p[pMap[1]].spinStates(); h++)
565 u1.push_back(p[pMap[1]].wave(h));
567 // Initialize fermion wave functions.
568 setFermionLine(2, p[2], p[3]);
572 //--------------------------------------------------------------------------
574 // Return element for helicity matrix element.
576 complex HMEZ2TwoFermions::calculateME(vector<int> h) {
579 for (int mu = 0; mu <= 3; mu++) {
581 u[0][h[pMap[1]]](mu) * (u[2][h[pMap[3]]] * gamma[mu]
582 * (p2CV - p2CA * gamma[5]) * u[1][h[pMap[2]]]);
587 //==========================================================================
589 // Helicity matrix element for the decay of a CP even Higgs to two fermions.
590 // All SM and MSSM Higgses couple to fermions with a vertex factor of
591 // (pfCV - pfCA * gamma[5]) where pf indicates the type of fermion line. For
592 // simplicity for the SM and MSSM CP even Higgses pfCV is set to one, and
593 // pfCA to zero, as this matrix element is used only for calculating helicity
596 // p2CA: in the SM and MSSM this coupling is zero
597 // p2CV: in the SM and MSSM this coupling is given by:
598 // i * g_w * m_f / (2 * m_W)
600 // * -sin(alpha) / sin(beta) for H^0 u-type
601 // * -cos(alpha) / cos(beta) for H^0 d-type
602 // * -cos(alpha) / sin(beta) for h^0 u-type
603 // * sin(alpha) / cos(beta) for h^0 d-type
605 //--------------------------------------------------------------------------
607 // Initialize wave functions for the helicity matrix element.
609 void HMEHiggsEven2TwoFermions::initWaves(vector<HelicityParticle>& p) {
614 setFermionLine(2, p[2], p[3]);
618 //--------------------------------------------------------------------------
620 // Return element for the helicity matrix element.
622 complex HMEHiggsEven2TwoFermions::calculateME(vector<int> h) {
624 return (u[1][h[pMap[3]]] * (p2CV - p2CA * gamma[5]) * u[0][h[pMap[2]]]);
628 //==========================================================================
630 // Helicity matrix element for the decay of a CP odd Higgs to two fermions.
631 // See HMEHiggsEven2TwoFermions for more details. For the MSSM CP odd Higgs
632 // pfCA is set to one and pfCV is set to zero.
634 // p2CA: in the MSSM this coupling is given by:
635 // -g_w * m_f / (2 * m_W)
636 // * cot(beta) for A^0 u-type
637 // * tan(beta) for A^0 d-type
638 // p2CV: in the MSSM this coupling is zero
640 //--------------------------------------------------------------------------
642 // Initialize wave functions for the helicity matrix element.
644 void HMEHiggsOdd2TwoFermions::initWaves(vector<HelicityParticle>& p) {
649 setFermionLine(2, p[2], p[3]);
653 //--------------------------------------------------------------------------
655 // Return element for the helicity matrix element.
657 complex HMEHiggsOdd2TwoFermions::calculateME(vector<int> h) {
659 return (u[1][h[pMap[3]]] * (p2CV - p2CA * gamma[5]) * u[0][h[pMap[2]]]);
663 //==========================================================================
665 // Helicity matrix element for the decay of a charged Higgs to two fermions.
666 // See HMEHiggsEven2TwoFermions for more details. For the MSSM charged Higgs
667 // pfCA is set to +/- one given an H^+/- and pfCV is set to one.
669 // p2CA: in the MSSM this coupling is given by:
670 // i * g / (sqrt(8.) * m_W) * (m_d * tan(beta) + m_u * cot(beta))
671 // p2CV: in the MSSM this coupling is given by:
672 // +/- i * g / (sqrt(8.) * m_W) * (m_d * tan(beta) - m_u * cot(beta))
674 //--------------------------------------------------------------------------
676 // Initialize wave functions for the helicity matrix element.
678 void HMEHiggsCharged2TwoFermions::initWaves(vector<HelicityParticle>& p) {
683 if (pID[3] == 15 || pID[3] == -16) p2CA = 1;
685 setFermionLine(2, p[2], p[3]);
689 //--------------------------------------------------------------------------
691 // Return element for the helicity matrix element.
693 complex HMEHiggsCharged2TwoFermions::calculateME(vector<int> h) {
695 return (u[1][h[pMap[3]]] * (p2CV - p2CA * gamma[5]) * u[0][h[pMap[2]]]);
699 //==========================================================================
701 // Helicity matrix element which provides an unpolarized helicity
702 // density matrix. This matrix element is used for unkown hard processes.
704 // Note that calculateRho is redefined for this special case, but that in
705 // general calculateRho should not be redefined.
707 //--------------------------------------------------------------------------
709 // Calculate a particle's helicity density matrix.
711 void HMEUnpolarized::calculateRho(unsigned int idx,
712 vector<HelicityParticle>& p) {
714 for (int i = 0; i < p[idx].spinStates(); i++ ) {
715 for (int j = 1; j < p[idx].spinStates(); j++) {
716 if ((i == j) && static_cast<double>(p[idx].spinStates()) != 0.) {
717 p[idx].rho[i][j] = 1.0 /
718 static_cast<double>(p[idx].spinStates());
720 else p[idx].rho[i][j] = 0;
726 //==========================================================================
728 // Base class for all tau decay matrix elements. This class derives from
729 // the HelicityMatrixElement class and redefines some of the virtual functions.
731 // One new method, initHadronicCurrent is defined which initializes the
732 // hadronic current in the initWaves method. For each tau decay matrix element
733 // the hadronic current method must be redefined accordingly, but initWaves
734 // should not be redefined.
736 //--------------------------------------------------------------------------
738 // Initialize wave functions for the helicity matrix element.
739 void HMETauDecay::initWaves(vector<HelicityParticle>& p) {
742 pMap.resize(p.size());
743 setFermionLine(0, p[0], p[1]);
744 initHadronicCurrent(p);
748 //--------------------------------------------------------------------------
750 // Return element for the helicity matrix element.
751 complex HMETauDecay::calculateME(vector<int> h) {
754 for (int mu = 0; mu <= 3; mu++) {
756 (u[1][h[pMap[1]]] * gamma[mu] * (1 - gamma[5]) * u[0][h[pMap[0]]])
757 * gamma[4](mu,mu) * u[2][0](mu);
763 //--------------------------------------------------------------------------
765 // Return the maximum decay weight for the helicity matrix element.
767 double HMETauDecay::decayWeightMax(vector<HelicityParticle>& p) {
769 // Determine the maximum on-diagonal element of rho.
770 double on = real(p[0].rho[0][0]) > real(p[0].rho[1][1]) ?
771 real(p[0].rho[0][0]) : real(p[0].rho[1][1]);
772 // Determine the maximum off-diagonal element of rho.
773 double off = fabs(real(p[0].rho[0][1])) + fabs(imag(p[0].rho[0][1]));
774 return DECAYWEIGHTMAX * (on + off);
778 //--------------------------------------------------------------------------
780 // Calculate complex resonance weights given a phase and amplitude vector.
782 void HMETauDecay::calculateResonanceWeights(vector<double>& phase,
783 vector<double>& amplitude, vector<complex>& weight) {
785 for (unsigned int i = 0; i < phase.size(); i++)
786 weight.push_back(amplitude[i] * (cos(phase[i]) +
787 complex(0,1) * sin(phase[i])));
791 //==========================================================================
793 // Tau decay matrix element for tau decay into a single scalar meson.
795 // The maximum decay weight for this matrix element can be found analytically
796 // to be 4 * m_tau^2 * (m_tau^2 - m_meson^2). However, because m_tau >> m_meson
797 // for the relevant tau decay channels, this expression is approximated by
800 //--------------------------------------------------------------------------
802 // Initialize constants for the helicity matrix element.
804 void HMETau2Meson::initConstants() {
806 DECAYWEIGHTMAX = 4*pow4(pM[0]);
810 //--------------------------------------------------------------------------
812 // Initialize the hadronic current for the helicity matrix element.
814 void HMETau2Meson::initHadronicCurrent(vector<HelicityParticle>& p) {
818 u2.push_back(Wave4(p[2].p()));
823 //==========================================================================
825 // Tau decay matrix element for tau decay into two leptons. Because there is
826 // no hadronic current, but rather a leptonic current, the calculateME and
827 // initWaves methods must be redefined.
829 //--------------------------------------------------------------------------
831 // Initialize constants for the helicity matrix element.
833 void HMETau2TwoLeptons::initConstants() {
835 DECAYWEIGHTMAX = 16*pow4(pM[0]);
839 //--------------------------------------------------------------------------
841 // Initialize spinors for the helicity matrix element.
843 void HMETau2TwoLeptons::initWaves(vector<HelicityParticle>& p) {
847 setFermionLine(0,p[0],p[1]);
848 setFermionLine(2,p[2],p[3]);
852 //--------------------------------------------------------------------------
854 // Return element for the helicity matrix element.
856 complex HMETau2TwoLeptons::calculateME(vector<int> h) {
859 for (int mu = 0; mu <= 3; mu++) {
860 answer += (u[1][h[pMap[1]]] * gamma[mu] * (1 - gamma[5])
861 * u[0][h[pMap[0]]]) * gamma[4](mu,mu) * (u[3][h[pMap[3]]]
862 * gamma[mu] * (1 - gamma[5]) * u[2][h[pMap[2]]]);
868 //==========================================================================
870 // Tau decay matrix element for tau decay into two mesons through an
871 // intermediate vector meson. This matrix element is used for pi^0 + pi^-
872 // decays (rho resonances), K^0 + K^- decays (rho resonances), and eta + K^-
873 // decays (K^* resonances). Note that for the rho resonances the pi^0 + pi^-
874 // running width dominates while for the K^* resonances the pi^- + K^0 running
877 // vecM: on-shell masses for the vector resonances
878 // vecG: on-shell widths for the vector resonances
879 // vecP: phases used to calculate vector resonance weights
880 // vecA: amplitudes used to calculate vector resonance weights
881 // vecW: vector resonance weights
883 //--------------------------------------------------------------------------
885 // Initialize constants for the helicity matrix element.
887 void HMETau2TwoMesonsViaVector::initConstants() {
889 // Clear the vectors from previous decays.
890 vecM.clear(); vecG.clear(); vecP.clear(); vecA.clear(); vecW.clear();
892 // Decay through K^* resonances (eta + K^- decay).
893 if (abs(pID[2]) == 221) {
895 pM[2] = particleDataPtr->m0(211); pM[3] = particleDataPtr->m0(311);
896 vecM.push_back(0.8921); vecM.push_back(1.700);
897 vecG.push_back(0.0513); vecG.push_back(0.235);
898 vecP.push_back(0); vecP.push_back(M_PI);
899 vecA.push_back(1); vecA.push_back(0.038);
902 // Decay through rho resonances (pi^0 + pi^- and K^0 + K^- decays).
904 if (abs(pID[2]) == 111) DECAYWEIGHTMAX = 800;
905 else if (abs(pID[2]) == 311) DECAYWEIGHTMAX = 6;
906 pM[2] = particleDataPtr->m0(111); pM[3] = particleDataPtr->m0(211);
907 vecM.push_back(0.7746); vecM.push_back(1.4080); vecM.push_back(1.700);
908 vecG.push_back(0.1490); vecG.push_back(0.5020); vecG.push_back(0.235);
909 vecP.push_back(0); vecP.push_back(M_PI); vecP.push_back(0);
910 vecA.push_back(1.0); vecA.push_back(0.167); vecA.push_back(0.050);
912 calculateResonanceWeights(vecP, vecA, vecW);
916 //--------------------------------------------------------------------------
918 // Initialize the hadronic current for the helicity matrix element.
920 void HMETau2TwoMesonsViaVector::initHadronicCurrent(
921 vector<HelicityParticle>& p) {
924 Wave4 u3(p[3].p() - p[2].p());
925 Wave4 u4(p[2].p() + p[3].p());
926 double s1 = m2(u3, u4);
929 for (unsigned int i = 0; i < vecW.size(); i++)
930 sumBW += vecW[i] * pBreitWigner(pM[2], pM[3], s2, vecM[i], vecG[i]);
931 u2.push_back((u3 - s1 / s2 * u4) * sumBW);
936 //==========================================================================
938 // Tau decay matrix element for tau decay into two mesons through both
939 // intermediate vector and scalar mesons.
941 // scaC: scalar coupling constant
942 // scaM: on-shell masses for the scalar resonances
943 // scaG: on-shell widths for the scalar resonances
944 // scaP: phases used to calculate scalar resonance weights
945 // scaA: amplitudes used to calculate scalar resonance weights
946 // scaW: scalar resonance weights
947 // vecC: scalar coupling constant
948 // vecM: on-shell masses for the vector resonances
949 // vecG: on-shell widths for the vector resonances
950 // vecP: phases used to calculate vector resonance weights
951 // vecA: amplitudes used to calculate vector resonance weights
952 // vecW: vector resonance weights
954 //--------------------------------------------------------------------------
956 // Initialize constants for the helicity matrix element.
958 void HMETau2TwoMesonsViaVectorScalar::initConstants() {
960 DECAYWEIGHTMAX = 5400;
961 // Clear the vectors from previous decays.
962 scaM.clear(); scaG.clear(); scaP.clear(); scaA.clear(); scaW.clear();
963 vecM.clear(); vecG.clear(); vecP.clear(); vecA.clear(); vecW.clear();
964 // Scalar resonance parameters.
966 scaM.push_back(0.878);
967 scaG.push_back(0.499);
970 calculateResonanceWeights(scaP, scaA, scaW);
971 // Vector resonance parameters.
973 vecM.push_back(0.89547); vecM.push_back(1.414);
974 vecG.push_back(0.04619); vecG.push_back(0.232);
975 vecP.push_back(0); vecP.push_back(1.4399);
976 vecA.push_back(1); vecA.push_back(0.075);
977 calculateResonanceWeights(vecP, vecA, vecW);
981 //--------------------------------------------------------------------------
983 // Initialize the hadronic current for the helicity matrix element.
985 void HMETau2TwoMesonsViaVectorScalar::initHadronicCurrent(
986 vector<HelicityParticle>& p) {
989 Wave4 u3(p[3].p() - p[2].p());
990 Wave4 u4(p[2].p() + p[3].p());
991 double s1 = m2(u3,u4);
993 complex scaSumBW = 0; complex scaSumW = 0;
994 complex vecSumBW = 0; complex vecSumW = 0; complex vecSumBWM = 0;
995 for (unsigned int i = 0; i < scaW.size(); i++) {
996 scaSumBW += scaW[i] * sBreitWigner(pM[2], pM[3], s2, scaM[i], scaG[i]);
999 for (unsigned int i = 0; i < vecW.size(); i++) {
1000 vecSumBW += vecW[i] * pBreitWigner(pM[2], pM[3], s2, vecM[i], vecG[i]);
1001 vecSumBWM += vecW[i] * pBreitWigner(pM[2], pM[3], s2, vecM[i], vecG[i]) /
1005 u2.push_back(vecC * (vecSumBW * u3 - s1 * vecSumBWM * u4) / vecSumW +
1006 scaC * u4 * scaSumBW / scaSumW);
1011 //==========================================================================
1013 // Tau decay matrix element for tau decay into three mesons. This matrix
1014 // element provides a base class for all implemented three meson decays.
1016 // mode: three meson decay mode of the tau
1017 // initMode(): initialize the decay mode
1018 // initResonances(): initialize the resonance constants
1019 // s1, s2, s3, s4: center-of-mass energies
1020 // q, q2, q3, q4: summed and individual hadronic momentum four-vectors
1021 // a1BW: stored value of a1BreitWigner for speed
1022 // a1PhaseSpace(s): phase space factor for the a1
1023 // a1BreitWigner(s): Breit-Wigner for the a1
1024 // T(m0, m1, s, M, G, W): sum weighted p-wave Breit-Wigners
1025 // T(s, M, G, W): sum weighted fixed width Breit-Wigners
1026 // F1(), F2(), F3(), F4(): sub-current form factors
1028 //--------------------------------------------------------------------------
1030 // Initialize constants for the helicity matrix element.
1032 void HMETau2ThreeMesons::initConstants() {
1039 //--------------------------------------------------------------------------
1041 // Initialize the hadronic current for the helicity matrix element.
1043 void HMETau2ThreeMesons::initHadronicCurrent(vector<HelicityParticle>& p) {
1047 // Initialize the momenta.
1050 // Calculate the center of mass energies.
1056 // Calculate the form factors.
1057 a1BW = a1BreitWigner(s1);
1063 // Calculate the hadronic current.
1064 Wave4 u3 = (f3 - f2) * q2 + (f1 - f3) * q3 + (f2 - f1) * q4;
1065 u3 = u3 - (u3 * gamma[4] * q / s1) * q;
1066 if (f4 != complex(0, 0))
1067 u3 = u3 + complex(0, 1) * f4 * epsilon(q2, q3, q4);
1073 //--------------------------------------------------------------------------
1075 // Initialize the tau decay mode.
1077 void HMETau2ThreeMesons::initMode() {
1079 if (abs(pID[2]) == 111 && abs(pID[3]) == 111 && abs(pID[4]) == 211)
1081 else if (abs(pID[2]) == 211 && abs(pID[3]) == 211 && abs(pID[4]) == 211)
1083 else if (abs(pID[2]) == 111 && abs(pID[3]) == 211 && abs(pID[4]) == 311)
1085 else if (abs(pID[2]) == 211 && abs(pID[3]) == 211 && abs(pID[4]) == 321)
1087 else if (abs(pID[2]) == 111 && abs(pID[3]) == 211 && abs(pID[4]) == 221)
1089 else if (abs(pID[2]) == 211 && abs(pID[3]) == 321 && abs(pID[4]) == 321)
1091 else if (abs(pID[2]) == 111 && abs(pID[3]) == 311 && abs(pID[4]) == 321)
1093 else if (abs(pID[2]) == 130 && abs(pID[3]) == 211 && abs(pID[4]) == 310)
1095 else if (abs(pID[2]) == 111 && abs(pID[3]) == 111 && abs(pID[4]) == 321)
1097 else if (abs(pID[2]) == 130 && abs(pID[3]) == 130 && abs(pID[4]) == 211)
1099 else if (abs(pID[2]) == 211 && abs(pID[3]) == 310 && abs(pID[4]) == 310)
1101 else if (abs(pID[2]) == 211 && abs(pID[3]) == 311 && abs(pID[4]) == 311)
1107 //--------------------------------------------------------------------------
1109 // Initialize the momenta for the helicity matrix element.
1111 void HMETau2ThreeMesons::initMomenta(vector<HelicityParticle>& p) {
1113 q = Wave4(p[2].p() + p[3].p() + p[4].p());
1114 // pi-, pi-, pi+ decay and pi0, pi0, pi- decay.
1115 if (mode == PimPimPip || mode == Pi0Pi0Pim) {
1116 q2 = Wave4(p[2].p()); q3 = Wave4(p[3].p()); q4 = Wave4(p[4].p());
1117 // K-, pi-, K+ decay.
1118 } else if (mode == PimKmKp) {
1119 q2 = Wave4(p[3].p()); q3 = Wave4(p[2].p()); q4 = Wave4(p[4].p());
1120 // K0, pi-, Kbar0 decay.
1121 } else if (mode == PimK0bK0) {
1122 q2 = Wave4(p[3].p()); q3 = Wave4(p[2].p()); q4 = Wave4(p[4].p());
1123 // K_S0, pi-, K_S0 decay.
1124 } else if (mode == PimKsKs) {
1125 q2 = Wave4(p[3].p()); q3 = Wave4(p[2].p()); q4 = Wave4(p[4].p());
1126 // K_L0, pi-, K_L0 decay.
1127 } else if (mode == KlKlPim) {
1128 q2 = Wave4(p[2].p()); q3 = Wave4(p[4].p()); q4 = Wave4(p[3].p());
1129 // K_S0, pi-, K_L0 decay.
1130 } else if (mode == KlPimKs) {
1131 q2 = Wave4(p[4].p()); q3 = Wave4(p[3].p()); q4 = Wave4(p[2].p());
1132 } // K-, pi0, K0 decay.
1133 else if (mode == Pi0K0Km) {
1134 q2 = Wave4(p[4].p()); q3 = Wave4(p[2].p()); q4 = Wave4(p[3].p());
1135 } // pi0, pi0, K- decay.
1136 else if (mode == Pi0Pi0Km) {
1137 q2 = Wave4(p[2].p()); q3 = Wave4(p[3].p()); q4 = Wave4(p[4].p());
1138 } // K-, pi-, pi+ decay.
1139 else if (mode == PimPipKm) {
1140 q2 = Wave4(p[4].p()); q3 = Wave4(p[2].p()); q4 = Wave4(p[3].p());
1141 } // pi-, Kbar0, pi0 decay.
1142 else if (mode == Pi0PimK0b) {
1143 q2 = Wave4(p[3].p()); q3 = Wave4(p[4].p()); q4 = Wave4(p[2].p());
1144 } // pi-, pi0, eta decay.
1145 else if (mode == Pi0PimEta) {
1146 q2 = Wave4(p[3].p()); q3 = Wave4(p[2].p()); q4 = Wave4(p[4].p());
1151 //--------------------------------------------------------------------------
1153 // Return the phase space factor for the a1. Implements equation 3.16 of Z.
1154 // Phys. C48 (1990) 445-452.
1156 double HMETau2ThreeMesons::a1PhaseSpace(double s) {
1158 double piM = 0.13957; // Mass of the charged pion.
1159 double rhoM = 0.773; // Mass of the rho.
1160 if (s < pow2(3 * piM))
1162 else if (s < pow2(rhoM + piM)) {
1163 double sum = (s - 9 * piM * piM);
1164 return 4.1 * sum * sum * sum * (1 - 3.3 * sum + 5.8 * sum * sum);
1167 return s * (1.623 + 10.38 / s - 9.32 / (s * s) + 0.65 / (s * s * s));
1171 //--------------------------------------------------------------------------
1173 // Return the Breit-Wigner for the a1. Implements equation 3.18
1174 // of Z. Phys. C48 (1990) 445-452.
1176 complex HMETau2ThreeMesons::a1BreitWigner(double s) {
1178 double a1M = 1.251; // Mass of the a1.
1179 double a1G = 0.475; // Width of the a1.
1180 return a1M * a1M / (a1M * a1M - s - complex(0,1) * a1M * a1G
1181 * a1PhaseSpace(s) / a1PhaseSpace(a1M * a1M));
1185 //--------------------------------------------------------------------------
1187 // Return summed weighted running p Breit-Wigner resonances.
1189 complex HMETau2ThreeMesons::T(double m0, double m1, double s,
1190 vector<double> &M, vector<double> &G, vector<double> &W) {
1194 for (unsigned int i = 0; i < M.size(); i++) {
1195 num += W[i] * pBreitWigner(m0, m1, s, M[i], G[i]);
1202 //--------------------------------------------------------------------------
1204 // Return summed weighted fixed width Breit-Wigner resonances.
1206 complex HMETau2ThreeMesons::T(double s, vector<double> &M,
1207 vector<double> &G, vector<double> &W) {
1211 for (unsigned int i = 0; i < M.size(); i++) {
1212 num += W[i] * breitWigner(s, M[i], G[i]);
1219 //==========================================================================
1221 // Tau decay matrix element for tau decay into three pions. This matrix element
1222 // is taken from the Herwig++ implementation based on the CLEO fits.
1224 // rhoM: on-shell masses for the rho resonances
1225 // rhoG: on-shell widths for the rho resonances
1226 // rhoPp: p-wave phase for the rho coupling to the a1
1227 // rhoAp: p-wave amplitude for the rho coupling to the a1
1228 // rhoPd: d-wave phase for the rho coupling to the a1
1229 // rhoAd: d-wave amplitude for the rho coupling to the a1
1230 // f0M: f0 on-shell mass
1231 // f0G: f0 on-shell width
1232 // f0P: phase for the coupling of the f0 to the a1
1233 // f0A: amplitude for the coupling of the f0 to the a1
1234 // f2M: f2 on-shell mass
1235 // f2G: f2 on-shell width
1236 // f2P: phase for the coupling of the f2 to the a1
1237 // f2P: amplitude for the coupling of the f2 to the a1
1238 // sigM: sigma on-shell mass
1239 // sigG: sigma on-shell width
1240 // sigP: phase for the coupling of the sigma to the a1
1241 // sigA: amplitude for the coupling of the sigma to the a1
1243 //--------------------------------------------------------------------------
1245 // Initialize resonance constants for the helicity matrix element.
1247 void HMETau2ThreePions::initResonances() {
1249 // Three charged pion decay.
1250 if (mode == PimPimPip) DECAYWEIGHTMAX = 6000;
1252 // Two neutral and one charged pion decay.
1253 else DECAYWEIGHTMAX = 3000;
1255 // Clear the vectors from previous decays.
1256 rhoM.clear(); rhoG.clear();
1257 rhoPp.clear(); rhoAp.clear(); rhoWp.clear();
1258 rhoPd.clear(); rhoAd.clear(); rhoWd.clear();
1261 rhoM.push_back(.7743); rhoM.push_back(1.370); rhoM.push_back(1.720);
1262 rhoG.push_back(.1491); rhoG.push_back(.386); rhoG.push_back(.250);
1263 rhoPp.push_back(0); rhoPp.push_back(3.11018); rhoPp.push_back(0);
1264 rhoAp.push_back(1); rhoAp.push_back(0.12); rhoAp.push_back(0);
1265 rhoPd.push_back(-0.471239); rhoPd.push_back(1.66504); rhoPd.push_back(0);
1266 rhoAd.push_back(3.7e-07); rhoAd.push_back(8.7e-07); rhoAd.push_back(0);
1268 // Scalar and tensor parameters.
1269 f0M = 1.186; f2M = 1.275; sigM = 0.860;
1270 f0G = 0.350; f2G = 0.185; sigG = 0.880;
1271 f0P = -1.69646; f2P = 1.75929; sigP = 0.722566;
1272 f0A = 0.77; f2A = 7.1e-07; sigA = 2.1;
1274 // Calculate the weights from the phases and amplitudes.
1275 calculateResonanceWeights(rhoPp, rhoAp, rhoWp);
1276 calculateResonanceWeights(rhoPd, rhoAd, rhoWd);
1277 f0W = f0A * (cos(f0P) + complex(0,1) * sin(f0P));
1278 f2W = f2A * (cos(f2P) + complex(0,1) * sin(f2P));
1279 sigW = sigA * (cos(sigP) + complex(0,1) * sin(sigP));
1283 //--------------------------------------------------------------------------
1285 // Return the first form factor.
1287 complex HMETau2ThreePions::F1() {
1289 complex answer(0,0);
1291 // Three charged pion decay.
1292 if (mode == PimPimPip) {
1293 for (unsigned int i = 0; i < rhoM.size(); i++) {
1294 answer += - rhoWp[i] * pBreitWigner(pM[3], pM[4], s2, rhoM[i], rhoG[i])
1295 - rhoWd[i] / 3.0 * pBreitWigner(pM[2], pM[4], s3, rhoM[i], rhoG[i])
1298 answer += -2.0 / 3.0 * (sigW * sBreitWigner(pM[2], pM[4], s3, sigM, sigG)
1299 + f0W * sBreitWigner(pM[2], pM[4], s3, f0M, f0G));
1300 answer += f2W * (0.5 * (s4 - s3)
1301 * dBreitWigner(pM[3], pM[4], s2, f2M, f2G)
1302 - 1.0 / (18 * s3) * (4 * pow2(pM[2]) - s3)
1303 * (s1 + s3 - pow2(pM[2]))
1304 * dBreitWigner(pM[2], pM[4], s3, f2M, f2G));
1307 // Two neutral and one charged pion decay.
1309 for (unsigned int i = 0; i < rhoM.size(); i++) {
1310 answer += rhoWp[i] * pBreitWigner(pM[3], pM[4], s2, rhoM[i], rhoG[i])
1311 - rhoWd[i] / 3.0 * pBreitWigner(pM[2], pM[4], s3, rhoM[i], rhoG[i])
1312 * (s4 - s2 - pow2(pM[4]) + pow2(pM[2]));
1314 answer += 2.0 / 3.0 * (sigW * sBreitWigner(pM[2], pM[3], s4, sigM, sigG)
1315 + f0W * sBreitWigner(pM[2], pM[3], s4, f0M, f0G));
1316 answer += f2W / (18 * s4) * (s1 - pow2(pM[4]) + s4)
1317 * (4 * pow2(pM[2]) - s4) * dBreitWigner(pM[2], pM[3], s4, f2M, f2G);
1319 return a1BW * answer;
1323 //--------------------------------------------------------------------------
1325 // Return the second form factor.
1327 complex HMETau2ThreePions::F2() {
1329 complex answer(0,0);
1331 // Three charged pion decay.
1332 if (mode == PimPimPip) {
1333 for (unsigned int i = 0; i < rhoM.size(); i++) {
1334 answer += -rhoWp[i] * pBreitWigner(pM[2], pM[4], s3, rhoM[i], rhoG[i])
1335 - rhoWd[i] / 3.0 * pBreitWigner(pM[3], pM[4], s2, rhoM[i], rhoG[i])
1338 answer += -2.0 / 3.0 * (sigW * sBreitWigner(pM[3], pM[4], s2, sigM, sigG)
1339 + f0W * sBreitWigner(pM[3], pM[4], s2, f0M, f0G));
1340 answer += f2W * (0.5 * (s4 - s2)
1341 * dBreitWigner(pM[2], pM[4], s3, f2M, f2G)
1342 - 1.0 / (18 * s2) * (4 * pow2(pM[2]) - s2) * (s1 + s2 - pow2(pM[2]))
1343 * dBreitWigner(pM[3], pM[4], s2, f2M, f2G));
1346 // Two neutral and one charged pion decay.
1348 for (unsigned int i = 0; i < rhoM.size(); i++) {
1349 answer += -rhoWp[i] / 3.0 *
1350 pBreitWigner(pM[2], pM[4], s3, rhoM[i], rhoG[i]) -
1351 rhoWd[i] * pBreitWigner(pM[3], pM[4], s2, rhoM[i], rhoG[i]) *
1352 (s4 - s3 - pow2(pM[4]) + pow2(pM[3]));
1354 answer += 2.0 / 3.0 * (sigW * sBreitWigner(pM[2], pM[3], s4, sigM, sigG)
1355 + f0W * sBreitWigner(pM[2], pM[3], s4, f0M, f0G));
1356 answer += f2W / (18 * s4) * (s1 - pow2(pM[4]) + s4) *
1357 (4 * pow2(pM[2]) - s4) * dBreitWigner(pM[2], pM[3], s4, f2M, f2G);
1359 return -a1BW * answer;
1363 //--------------------------------------------------------------------------
1365 // Return the third form factor.
1367 complex HMETau2ThreePions::F3() {
1369 complex answer(0,0);
1371 // Three charged pion decay.
1372 if (mode == PimPimPip) {
1373 for (unsigned int i = 0; i < rhoM.size(); i++) {
1374 answer += -rhoWd[i] * (1.0 / 3.0 * (s3 - s4) *
1375 pBreitWigner(pM[3], pM[4], s2, rhoM[i], rhoG[i])
1376 - 1.0 / 3.0 * (s2 - s4) *
1377 pBreitWigner(pM[2], pM[4], s3, rhoM[i],
1380 answer += -2.0 / 3.0 * (sigW * sBreitWigner(pM[3], pM[4], s2, sigM, sigG)
1381 + f0W * sBreitWigner(pM[3], pM[4], s2, f0M, f0G));
1382 answer += 2.0 / 3.0 * (sigW * sBreitWigner(pM[2], pM[4], s3, sigM, sigG)
1383 + f0W * sBreitWigner(pM[2], pM[4], s3, f0M, f0G));
1384 answer += f2W * (-1.0 / (18 * s2) * (4 * pow2(pM[2]) - s2) *
1385 (s1 + s2 - pow2(pM[2])) *
1386 dBreitWigner(pM[3], pM[4], s2, f2M, f2G) +
1387 1.0 / (18 * s3) * (4 * pow2(pM[2]) - s3) *
1388 (s1 + s3 - pow2(pM[2])) *
1389 dBreitWigner(pM[2], pM[4], s3, f2M, f2G));
1392 // Two neutral and one charged pion decay.
1394 for (unsigned int i = 0; i < rhoM.size(); i++) {
1395 answer += rhoWd[i] * (-1.0 / 3.0 *
1396 (s4 - s3 - pow2(pM[4]) + pow2(pM[3])) *
1397 pBreitWigner(pM[3], pM[4], s2, rhoM[i], rhoG[i]) +
1398 1.0 / 3.0 * (s4 - s2 - pow2(pM[4]) + pow2(pM[2]))
1399 * pBreitWigner(pM[2], pM[4], s3, rhoM[i],
1402 answer += -f2W / 2.0 * (s2 - s3) *
1403 dBreitWigner(pM[2], pM[3], s4, f2M, f2G);
1405 return a1BW * answer;
1409 //--------------------------------------------------------------------------
1411 // Return the running width for the a1 (multiplied by a factor of a1M).
1413 double HMETau2ThreePions::a1PhaseSpace(double s) {
1415 double picM = 0.1753; // (m_pi^- + m_pi^- + m_pi^+)^2
1416 double pinM = 0.1676; // (m_pi^0 + m_pi^0 + m_pi^-)^2
1417 double kM = 0.496; // K mass.
1418 double ksM = 0.894; // K^* mass.
1419 double picG = 0; // Width contribution from three charged pions.
1420 double pinG = 0; // Width contribution from two neutral one charged.
1421 double kG = 0; // Width contributions from s-wave K K^*.
1422 double piW = pow2(0.2384)/1.0252088; // Overall weight factor.
1423 double kW = pow2(4.7621); // K K^* width weight factor.
1425 // Three charged pion width contribution.
1429 picG = 5.80900 * pow3(s - picM) * (1.0 - 3.00980 * (s - picM) +
1430 4.5792 * pow2(s - picM));
1432 picG = -13.91400 + 27.67900 * s - 13.39300 * pow2(s) + 3.19240 * pow3(s)
1433 - 0.10487 * pow4(s);
1435 // Two neutral and one charged pion width contribution.
1439 pinG = 6.28450 * pow3(s - pinM) * (1.0 - 2.95950 * (s - pinM) +
1440 4.33550 * pow2(s - pinM));
1442 pinG = -15.41100 + 32.08800 * s - 17.66600 * pow2(s) + 4.93550 * pow3(s)
1443 - 0.37498 * pow4(s);
1445 // K and K^* width contribution.
1446 if (s > pow2(ksM + kM))
1447 kG = 0.5 * sqrt((s - pow2(ksM + kM)) * (s - pow2(ksM - kM))) / s;
1448 return piW*(picG + pinG + kW*kG);
1452 //--------------------------------------------------------------------------
1454 // Return the Breit-Wigner for the a1.
1456 complex HMETau2ThreePions::a1BreitWigner(double s) {
1458 double a1M = 1.331; // Mass of the a1.
1459 return a1M*a1M/(a1M*a1M - s - complex(0,1)*a1PhaseSpace(s));
1463 //==========================================================================
1465 // Tau decay matrix element for tau decay into three mesons with kaons.
1466 // The form factors are taken from hep-ph/9503474.
1468 // rhoMa(v): on-shell masses for the axial (vector) rho resonances
1469 // rhoGa(v): widths for the axial (vector) rho resonances
1470 // rhoWa(v): weights for the axial (vector) rho resonances
1471 // kstarXa(v): on-shell masses, widths, and weights for the K* resonances
1472 // k1Xa(b): on-shell masses, width, and weight for the K1 resonances,
1473 // the a constants are for K1 -> K* pi, K* -> K pi
1474 // the b constants are for K1 -> rho K, rho -> pi pi
1475 // omegaX: on-shell masses, width, and weights for the omega reosnances
1477 // piM: charged pion mass
1478 // piW: pion coupling, f_W
1480 //--------------------------------------------------------------------------
1482 // Initialize resonance constants for the helicity matrix element.
1484 void HMETau2ThreeMesonsWithKaons::initResonances() {
1486 // K-, pi-, K+ decay.
1487 if (mode == PimKmKp) DECAYWEIGHTMAX = 130;
1488 // K0, pi-, Kbar0 decay.
1489 else if (mode == PimK0bK0) DECAYWEIGHTMAX = 115;
1490 // K_S0, pi-, K_S0 and K_L0, pi-, K_L0 decay.
1491 else if (mode == PimKsKs || mode == KlKlPim) DECAYWEIGHTMAX = 230;
1492 // K_S0, pi-, K_L0 decay.
1493 else if (mode == KlPimKs) DECAYWEIGHTMAX = 230;
1494 // K-, pi0, K0 decay.
1495 else if (mode == Pi0K0Km) DECAYWEIGHTMAX = 125;
1496 // pi0, pi0, K- decay.
1497 else if (mode == Pi0Pi0Km) DECAYWEIGHTMAX = 2.5e4;
1498 // K-, pi-, pi+ decay.
1499 else if (mode == PimPipKm) DECAYWEIGHTMAX = 1.8e4;
1500 // pi-, Kbar0, pi0 decay.
1501 else if (mode == Pi0PimK0b) DECAYWEIGHTMAX = 3.9e4;
1503 // Clear the vectors from previous decays.
1504 rhoMa.clear(); rhoGa.clear(); rhoWa.clear();
1505 rhoMv.clear(); rhoGv.clear(); rhoWv.clear();
1506 kstarMa.clear(); kstarGa.clear(); kstarWa.clear();
1507 kstarMv.clear(); kstarGv.clear(); kstarWv.clear();
1508 k1Ma.clear(); k1Ga.clear(); k1Wa.clear();
1509 k1Mb.clear(); k1Gb.clear(); k1Wb.clear();
1510 omegaM.clear(); omegaG.clear(); omegaW.clear();
1513 rhoMa.push_back(0.773); rhoGa.push_back(0.145); rhoWa.push_back(1);
1514 rhoMa.push_back(1.370); rhoGa.push_back(0.510); rhoWa.push_back(-0.145);
1515 rhoMv.push_back(0.773); rhoGv.push_back(0.145); rhoWv.push_back(1);
1516 rhoMv.push_back(1.500); rhoGv.push_back(0.220); rhoWv.push_back(-6.5 / 26.0);
1517 rhoMv.push_back(1.750); rhoGv.push_back(0.120); rhoWv.push_back(-1.0 / 26.0);
1519 // Kstar parameters.
1520 kstarMa.push_back(0.892); kstarGa.push_back(0.050);
1521 kstarMa.push_back(1.412); kstarGa.push_back(0.227);
1522 kstarWa.push_back(1);
1523 kstarWa.push_back(-0.135);
1524 kstarMv.push_back(0.892); kstarGv.push_back(0.050);
1525 kstarMv.push_back(1.412); kstarGv.push_back(0.227);
1526 kstarMv.push_back(1.714); kstarGv.push_back(0.323);
1527 kstarWv.push_back(1);
1528 kstarWv.push_back(-6.5 / 26.0);
1529 kstarWv.push_back(-1.0 / 26.0);
1532 k1Ma.push_back(1.270); k1Ga.push_back(0.090); k1Wa.push_back(0.33);
1533 k1Ma.push_back(1.402); k1Ga.push_back(0.174); k1Wa.push_back(1);
1534 k1Mb.push_back(1.270); k1Gb.push_back(0.090); k1Wb.push_back(1);
1536 // Omega and phi parameters.
1537 omegaM.push_back(0.782); omegaG.push_back(0.00843); omegaW.push_back(1);
1538 omegaM.push_back(1.020); omegaG.push_back(0.00443); omegaW.push_back(0.05);
1540 // Kaon and pion parameters
1541 kM = 0.49765; piM = 0.13957; piW = 0.0942;
1545 //--------------------------------------------------------------------------
1547 // Return the first form factor.
1549 complex HMETau2ThreeMesonsWithKaons::F1() {
1552 // K-, pi-, K+ decay.
1553 if (mode == PimKmKp)
1554 answer = a1BW * T(piM, kM, s2, kstarMa, kstarGa, kstarWa) / 2.0;
1555 // K0, pi-, Kbar0 decay.
1556 else if (mode == PimK0bK0)
1557 answer = a1BW * T(piM, kM, s2, kstarMa, kstarGa, kstarWa) / 2.0;
1558 // K_S0, pi-, K_S0 decay and K_L0, pi-, K_L0 decay.
1559 else if (mode == PimKsKs || mode == KlKlPim)
1560 answer = -a1BW * (T(piM, kM, s2, kstarMa, kstarGa, kstarWa)
1561 + T(piM, kM, s4, kstarMa, kstarGa, kstarWa)) / 2.0;
1562 // K_S0, pi-, K_L0 decay.
1563 else if (mode == KlPimKs)
1564 answer = a1BW * (T(piM, kM, s2, kstarMa, kstarGa, kstarWa)
1565 - T(piM, kM, s4, kstarMa, kstarGa, kstarWa)) / 2.0;
1566 // K-, pi0, K0 decay.
1567 else if (mode == Pi0K0Km)
1568 answer = a1BW * (T(piM, kM, s2, kstarMa, kstarGa, kstarWa)
1569 - T(piM, kM, s4, kstarMa, kstarGa, kstarWa)) / 2.0;
1570 // pi0, pi0, K- decay.
1571 else if (mode == Pi0Pi0Km)
1572 answer = T(s1, k1Ma, k1Ga, k1Wa)
1573 * T(piM, kM, s2, kstarMa, kstarGa, kstarWa);
1574 // K-, pi-, pi+ decay.
1575 else if (mode == PimPipKm)
1576 answer = T(s1, k1Mb, k1Gb, k1Wb)
1577 * T(piM, piM, s2, rhoMa, rhoGa, rhoWa);
1578 // pi-, Kbar0, pi0 decay.
1579 else if (mode == Pi0PimK0b)
1580 answer = T(s1, k1Ma, k1Ga, k1Wa)
1581 * (T(piM, kM, s2, kstarMa, kstarGa, kstarWa)
1582 - T(piM, kM, s4, kstarMa, kstarGa, kstarWa));
1583 return -1.0 / 3.0 * answer;
1586 //--------------------------------------------------------------------------
1588 // Return the second form factor.
1590 complex HMETau2ThreeMesonsWithKaons::F2() {
1593 // K-, pi-, K+ decay.
1594 if (mode == PimKmKp)
1595 answer = a1BW * T(piM, piM, s3, rhoMa, rhoGa, rhoWa) / 2.0;
1596 // K0, pi-, Kbar0 decay.
1597 else if (mode == PimK0bK0)
1598 answer = a1BW * T(piM, piM, s3, rhoMa, rhoGa, rhoWa) / 2.0;
1599 // K_S0, pi-, K_S0 decay and K_L0, pi-, K_L0 decay.
1600 else if (mode == PimKsKs || mode == KlKlPim)
1601 answer = a1BW * T(piM, kM, s4, kstarMa, kstarGa, kstarWa) / 2.0;
1602 // K_S0, pi-, K_L0 decay.
1603 else if (mode == KlPimKs)
1604 answer = a1BW * (2.0 * T(piM, piM, s3, rhoMa, rhoGa, rhoWa)
1605 + T(piM, kM, s4, kstarMa, kstarGa, kstarWa)) / 2.0;
1606 // K-, pi0, K0 decay.
1607 else if (mode == Pi0K0Km)
1608 answer = a1BW * (2.0 * T(piM, piM, s3, rhoMa, rhoGa, rhoWa)
1609 + T(piM, kM, s4, kstarMa, kstarGa, kstarWa)) / 2.0;
1610 // pi0, pi0, K- decay.
1611 else if (mode == Pi0Pi0Km)
1612 answer = T(s1, k1Ma, k1Ga, k1Wa)
1613 * T(piM, kM, s3, kstarMa, kstarGa, kstarWa);
1614 // K-, pi-, pi+ decay.
1615 else if (mode == PimPipKm)
1616 answer = T(s1, k1Ma, k1Ga, k1Wa)
1617 * T(piM, kM, s3, kstarMa, kstarGa, kstarWa);
1618 // pi-, Kbar0, pi0 decay.
1619 else if (mode == Pi0PimK0b)
1620 answer = 2.0 * T(s1, k1Mb, k1Gb, k1Wb)
1621 * T(piM, piM, s3, rhoMa, rhoGa, rhoWa)
1622 + T(s1, k1Ma, k1Ga, k1Wa) * T(piM, kM, s4, kstarMa, kstarGa, kstarWa);
1623 return 1.0 / 3.0 * answer;
1627 //--------------------------------------------------------------------------
1629 // Return the fourth form factor.
1631 complex HMETau2ThreeMesonsWithKaons::F4() {
1634 // K-, pi-, K+ decay.
1635 if (mode == PimKmKp)
1636 answer = (sqrt(2.) - 1) * T(piM, piM, s1, rhoMv, rhoGv, rhoWv)
1637 * (sqrt(2.) * T(s3, omegaM, omegaG, omegaW)
1638 + T(piM, kM, s2, kstarMa, kstarGa, kstarWa));
1639 // K0, pi-, Kbar0 decay.
1640 else if (mode == PimK0bK0)
1641 answer = -(sqrt(2.) - 1) * T(piM, piM, s1, rhoMv, rhoGv, rhoWv)
1642 * (sqrt(2.) * T(s3, omegaM, omegaG, omegaW)
1643 + T(piM, kM, s2, kstarMa, kstarGa, kstarWa));
1644 // K_S0, pi-, K_S0 decay and K_L0, pi-, K_L0 decay.
1645 else if (mode == PimKsKs || mode == KlKlPim)
1646 answer = (sqrt(2.) - 1) * T(piM, piM, s1, rhoMv, rhoGv, rhoWv)
1647 * (T(piM, kM, s2, kstarMa, kstarGa, kstarWa)
1648 - T(piM, kM, s4, kstarMa, kstarGa, kstarWa));
1649 // K_S0, pi-, K_L0 decay.
1650 else if (mode == KlPimKs)
1651 answer = -(sqrt(2.) - 1) * T(piM, piM, s1, rhoMv, rhoGv, rhoWv)
1652 * (2 * sqrt(2.) * T(s3, omegaM, omegaG, omegaW)
1653 + T(piM, kM, s2, kstarMa, kstarGa, kstarWa)
1654 + T(piM, kM, s4, kstarMa, kstarGa, kstarWa));
1655 // K-, pi0, K0 decay.
1656 else if (mode == Pi0K0Km)
1657 answer = -(sqrt(2.) - 1) * T(piM, piM, s1, rhoMv, rhoGv, rhoWv)
1658 * (T(piM, kM, s4, kstarMa, kstarGa, kstarWa)
1659 - T(piM, kM, s2, kstarMa, kstarGa, kstarWa));
1660 // pi0, pi0, K- decay.
1661 else if (mode == Pi0Pi0Km)
1662 answer = T(piM, kM, s1, kstarMv, kstarGv, kstarWv)
1663 * (T(piM, kM, s2, kstarMa, kstarGa, kstarWa)
1664 - T(piM, kM, s3, kstarMa, kstarGa, kstarWa));
1665 // K-, pi-, pi+ decay.
1666 else if (mode == PimPipKm)
1667 answer = -T(piM, kM, s1, kstarMv, kstarGv, kstarWv)
1668 * (T(piM, piM, s2, rhoMa, rhoGa, rhoWa)
1669 + T(piM, kM, s3, kstarMa, kstarGa, kstarWa));
1670 // pi-, Kbar0, pi0 decay.
1671 else if (mode == Pi0PimK0b)
1672 answer = T(piM, kM, s1, kstarMv, kstarGv, kstarWv)
1673 * (2.0 * T(piM, piM, s3, rhoMa, rhoGa, rhoWa)
1674 + T(piM, kM, s2, kstarMa, kstarGa, kstarWa)
1675 + T(piM, kM, s4, kstarMa, kstarGa, kstarWa));
1676 return 1.0 / (8.0 * M_PI * M_PI * piW * piW) * answer;
1680 //==========================================================================
1682 // Tau decay matrix element for tau decay into three mesons. The form
1683 // factors are taken from Comp. Phys. Com. 76 (1993) 361-380.
1685 // rhoMa(v): on-shell masses for the axial (vector) rho resonances
1686 // rhoGa(v): widths for the axial (vector) rho resonances
1687 // rhoWa(v): weights for the axial (vector) rho resonances
1688 // kstarX: on-shell masses, widths, and weights for the K* resonances
1689 // k1X: on-shell masses, width, and weight for the K1 resonances
1691 // piM: charged pion mass
1692 // piW: pion coupling, f_W
1694 //--------------------------------------------------------------------------
1696 // Initialize resonances for the helicity matrix element.
1698 void HMETau2ThreeMesonsGeneric::initResonances() {
1700 // pi-, pi-, pi+ decay and pi0, pi0, pi- decay.
1701 if (mode == PimPimPip || mode == Pi0Pi0Pim) DECAYWEIGHTMAX = 1.3e4;
1702 // K-, pi-, K+ decay.
1703 else if (mode == PimKmKp) DECAYWEIGHTMAX = 330;
1704 // K0, pi-, Kbar0 decay.
1705 else if (mode == PimK0bK0) DECAYWEIGHTMAX = 300;
1706 // K-, pi0, K0 decay.
1707 else if (mode == Pi0K0Km) DECAYWEIGHTMAX = 40;
1708 // pi0, pi0, K- decay.
1709 else if (mode == Pi0Pi0Km) DECAYWEIGHTMAX = 9.4e4;
1710 // K-, pi-, pi+ decay.
1711 else if (mode == PimPipKm) DECAYWEIGHTMAX = 9.0e3;
1712 // pi-, Kbar0, pi0 decay.
1713 else if (mode == Pi0PimK0b) DECAYWEIGHTMAX = 1.2e4;
1714 // pi-, pi0, eta decay.
1715 else if (mode == Pi0PimEta) DECAYWEIGHTMAX = 360;
1717 // Clear the vectors from previous decays.
1718 rhoMa.clear(); rhoGa.clear(); rhoWa.clear();
1719 rhoMv.clear(); rhoGv.clear(); rhoWv.clear();
1720 kstarM.clear(); kstarG.clear(); kstarW.clear();
1721 k1M.clear(); k1G.clear(); k1W.clear();
1724 rhoMa.push_back(0.773); rhoGa.push_back(0.145); rhoWa.push_back(1);
1725 rhoMa.push_back(1.370); rhoGa.push_back(0.510); rhoWa.push_back(-0.145);
1726 rhoMv.push_back(0.773); rhoGv.push_back(0.145); rhoWv.push_back(-26);
1727 rhoMv.push_back(1.5); rhoGv.push_back(0.220); rhoWv.push_back(6.5);
1728 rhoMv.push_back(1.75); rhoGv.push_back(0.120); rhoWv.push_back(1);
1731 kstarM.push_back(0.892); kstarG.push_back(0.0513); kstarW.push_back(1);
1732 k1M.push_back(1.402); k1G.push_back(0.174); k1W.push_back(1);
1734 // Kaon and pion parameters
1735 kM = 0.49765; piM = 0.13957; piW = 0.0942;
1739 //--------------------------------------------------------------------------
1741 // Return the first form factor.
1743 complex HMETau2ThreeMesonsGeneric::F1() {
1746 // pi-, pi-, pi+ decay and pi0, pi0, pi- decay.
1747 if (mode == PimPimPip || mode == Pi0Pi0Pim)
1748 answer = a1BW * T(piM, piM, s2, rhoMa, rhoGa, rhoWa);
1749 // K-, pi-, K+ decay.
1750 else if (mode == PimKmKp)
1751 answer = -a1BW * T(piM, kM, s2, kstarM, kstarG, kstarW) / 3.0;
1752 // K0, pi-, Kbar0 decay.
1753 else if (mode == PimK0bK0)
1754 answer = -a1BW * T(piM, kM, s2, kstarM, kstarG, kstarW) / 3.0;
1755 // K-, pi0, K0 decay.
1756 else if (mode == Pi0K0Km)
1758 // pi0, pi0, K- decay.
1759 else if (mode == Pi0Pi0Km)
1760 answer = T(s1, k1M, k1G, k1W) * T(piM, kM, s2, kstarM, kstarG, kstarW);
1761 // K-, pi-, pi+ decay.
1762 else if (mode == PimPipKm)
1763 answer = -T(s1, k1M, k1G, k1W) * T(piM, piM, s2, rhoMa, rhoGa, rhoWa)
1765 // pi-, Kbar0, pi0 decay.
1766 else if (mode == Pi0PimK0b)
1768 // pi-, pi0, eta decay.
1769 else if (mode == Pi0PimEta)
1775 //--------------------------------------------------------------------------
1777 // Return the second form factor.
1779 complex HMETau2ThreeMesonsGeneric::F2() {
1782 // pi-, pi-, pi+ decay and pi0, pi0, pi- decay.
1783 if (mode == PimPimPip || mode == Pi0Pi0Pim)
1784 answer = -a1BW * T(piM, piM, s3, rhoMa, rhoGa, rhoWa);
1785 // K-, pi-, K+ decay.
1786 else if (mode == PimKmKp)
1787 answer = a1BW * T(piM, piM, s3, rhoMa, rhoGa, rhoWa) / 3.0;
1788 // K0, pi-, Kbar0 decay.
1789 else if (mode == PimK0bK0)
1790 answer = a1BW * T(piM, piM, s3, rhoMa, rhoGa, rhoWa) / 3.0;
1791 // K-, pi0, K0 decay.
1792 else if (mode == Pi0K0Km)
1793 answer = a1BW * T(piM, piM, s3, rhoMa, rhoGa, rhoWa);
1794 // pi0, pi0, K- decay.
1795 else if (mode == Pi0Pi0Km)
1796 answer = -T(s1, k1M, k1G, k1W) * T(piM, kM, s3, kstarM, kstarG, kstarW);
1797 // K-, pi-, pi+ decay.
1798 else if (mode == PimPipKm)
1799 answer = T(s1, k1M, k1G, k1W)
1800 * T(piM, kM, s3, kstarM, kstarG, kstarW) / 3.0;
1801 // pi-, Kbar0, pi0 decay.
1802 else if (mode == Pi0PimK0b)
1803 answer = T(s1, k1M, k1G, k1W) * T(piM, piM, s3, rhoMa, rhoGa, rhoWa);
1804 // pi-, pi0, eta decay.
1805 else if (mode == Pi0PimEta)
1811 //--------------------------------------------------------------------------
1813 // Return the fourth form factor.
1815 complex HMETau2ThreeMesonsGeneric::F4() {
1818 // pi-, pi-, pi+ decay and pi0, pi0, pi- decay.
1819 if (mode == PimPimPip || mode == Pi0Pi0Pim)
1821 // K-, pi-, K+ decay.
1822 else if (mode == PimKmKp)
1823 answer = T(piM, piM, s1, rhoMv, rhoGv, rhoWv)
1824 * (T(piM, piM, s3, rhoMa, rhoGa, rhoWa)
1825 - 0.2 * T(piM, kM, s2, kstarM, kstarG, kstarW)) * (1.25);
1826 // K0, pi-, Kbar0 decay.
1827 else if (mode == PimK0bK0)
1828 answer = -T(piM, piM, s1, rhoMv, rhoGv, rhoWv)
1829 * (T(piM, piM, s3, rhoMa, rhoGa, rhoWa)
1830 - 0.2 * T(piM, kM, s2, kstarM, kstarG, kstarW)) * (1.25);
1831 // K-, pi0, K0 decay.
1832 else if (mode == Pi0K0Km)
1834 // pi0, pi0, K- decay.
1835 else if (mode == Pi0Pi0Km)
1837 // K-, pi-, pi+ decay.
1838 else if (mode == PimPipKm)
1839 answer = -T(piM, kM, s1, kstarM, kstarG, kstarW)
1840 * (T(piM, piM, s2, rhoMa, rhoGa, rhoWa)
1841 - 0.2 * T(piM, kM, s3, kstarM, kstarG, kstarW)) * (1.25);
1842 // pi-, Kbar0, pi0 decay.
1843 else if (mode == Pi0PimK0b)
1844 answer = 2.0 * T(piM, kM, s1, kstarM, kstarG, kstarW)
1845 * (T(piM, piM, s3, rhoMa, rhoGa, rhoWa)
1846 - 0.2 * T(piM, kM, s2, kstarM, kstarG, kstarW)) * (1.25);
1847 // pi-, pi0, eta decay.
1848 else if (mode == Pi0PimEta)
1849 answer = T(piM, piM, s1, rhoMv, rhoGv, rhoWv)
1850 * T(piM, piM, s4, rhoMa, rhoGa, rhoWa);
1851 return 1.0 / (4.0 * M_PI * M_PI * piW * piW) * answer;
1855 //==========================================================================
1857 // Tau decay matrix element for tau decay into two pions with a photons taken
1858 // from Comp. Phys. Com. 76 (1993) 361-380. Because a photon is in the final
1859 // state the matrix element is reimplented to handle the two spin states.
1861 // F(s, M, G, W): form factor for resonance
1862 // rhoM: on-shell mass of the rho resonances
1863 // rhoG: width of the rho resonances
1864 // rhoW: weight of the rho resonances
1865 // omegaX: on-shell mass, width, and weight of the omega resonances
1866 // piM: charged pion mass
1868 //--------------------------------------------------------------------------
1870 // Initialize constants for the helicity matrix element.
1872 void HMETau2TwoPionsGamma::initConstants() {
1874 DECAYWEIGHTMAX = 4e4;
1876 // Clear the vectors from previous decays.
1877 rhoM.clear(); rhoG.clear(); rhoW.clear();
1878 omegaM.clear(); omegaG.clear(); omegaW.clear();
1881 rhoM.push_back(0.773); rhoG.push_back(0.145); rhoW.push_back(1);
1882 rhoM.push_back(1.7); rhoG.push_back(0.26); rhoW.push_back(-0.1);
1883 omegaM.push_back(0.782); omegaG.push_back(0.0085); omegaW.push_back(1);
1888 //--------------------------------------------------------------------------
1890 // Initialize wave functions for the helicity matrix element.
1891 void HMETau2TwoPionsGamma::initWaves(vector<HelicityParticle>& p) {
1893 // Calculate the hadronic current.
1895 pMap.resize(p.size());
1896 setFermionLine(0, p[0], p[1]);
1898 // Calculate the hadronic current.
1900 Wave4 q(p[2].p() + p[3].p() + p[4].p());
1901 Wave4 q2(p[2].p()), q3(p[3].p()), q4(p[4].p());
1903 double s2 = m2(q3 + q2);
1904 complex f = F(s1, rhoM, rhoG, rhoW) * F(0, rhoM, rhoG, rhoW)
1905 * F(s2, omegaM, omegaG, omegaW);
1906 double q4q2 = m2(q4, q2);
1907 double q4q3 = m2(q4, q3);
1908 double q3q2 = m2(q3, q2);
1909 for (int h = 0; h < 2; h++) {
1910 Wave4 e = p[2].wave(h);
1911 complex q4e = q4*gamma[4]*e;
1912 complex q3e = q3*gamma[4]*e;
1913 u2.push_back(f * (e * (piM*piM*q4q2 - q3q2*(q4q3 - q4q2))
1914 - q3 * (q3e*q4q2 - q4e*q3q2)
1915 + q2 * (q3e*q4q3 - q4e*(piM*piM + q3q2))));
1921 //--------------------------------------------------------------------------
1923 // Return element for the helicity matrix element.
1924 complex HMETau2TwoPionsGamma::calculateME(vector<int> h) {
1926 complex answer(0,0);
1927 for (int mu = 0; mu <= 3; mu++) {
1929 (u[1][h[pMap[1]]] * gamma[mu] * (1 - gamma[5]) * u[0][h[pMap[0]]])
1930 * gamma[4](mu,mu) * u[2][h[2]](mu);
1936 //--------------------------------------------------------------------------
1938 // Return the form factor.
1939 complex HMETau2TwoPionsGamma::F(double s, vector<double> M, vector<double> G,
1942 complex answer(0, 0);
1943 for (unsigned int i = 0; i < M.size(); i++)
1944 answer += W[i] / (M[i]*M[i] - s - complex(0, 1) * M[i] * G[i]);
1949 //==========================================================================
1951 // Tau decay matrix element for tau decay into pions using the Novosibirsk
1952 // model of Comp. Phys. Com. 174 (2006) 818-835.
1954 // G(i,s): G-factor for index 1, 2, or 3
1955 // tX(q,q1,q2,q3,q4): combined resonance current
1956 // a1D(s): a1 Breit-Wigner denominator
1957 // rhoD(s): rho Breit-Wigner denominator
1958 // sigD(s): sigma Breit-Wigner denominator
1959 // omeD(s): omega Breit-Wigner denominator
1960 // a1FormFactor(s): form factor for the a1 resonance
1961 // rhoFormFactor1(2)(s): form factor for the rho resonance
1962 // omeFormFactor(s): form factor for the omega resonance
1963 // sigM: on-shell mass of the sigma resonance
1964 // sigG: width of the sigma resonance
1965 // sigA: amplitude of the sigma resonance
1966 // sigP: phase of the sigma resonance
1967 // sigW: weight of the sigma resonance (from amplitude and weight)
1968 // omeX: mass, width, amplitude, phase, and weight of the omega resonance
1969 // a1X: mass and width of the a1 resonance
1970 // rhoX: mass and width of the rho resonance
1971 // picM: charge pion mass
1972 // pinM: neutral pion mass
1973 // lambda2: a1 form factor cut-off
1975 //--------------------------------------------------------------------------
1977 // Initialize constants for the helicity matrix element.
1979 void HMETau2FourPions::initConstants() {
1981 if (abs(pID[3]) == 111) DECAYWEIGHTMAX = 5e8;
1982 else DECAYWEIGHTMAX = 5e9;
1983 pinM = particleDataPtr->m0(111);
1984 picM = particleDataPtr->m0(211);
1985 sigM = 0.8; omeM = 0.782; a1M = 1.23; rhoM = 0.7761;
1986 sigG = 0.8; omeG = 0.00841; a1G = 0.45; rhoG = 0.1445;
1987 sigP = 0.43585; omeP = 0.0;
1988 sigA = 1.39987; omeA = 1.0;
1989 sigW = sigA*(cos(sigP)+complex(0,1)*sin(sigP));
1990 omeW = omeA*(cos(omeP)+complex(0,1)*sin(omeP));
1995 //--------------------------------------------------------------------------
1997 // Initialize the hadronic current for the helicity matrix element.
1999 void HMETau2FourPions::initHadronicCurrent(vector<HelicityParticle>& p) {
2003 // Create pion momenta.
2004 Wave4 q(p[2].p() + p[3].p() + p[4].p()+ p[5].p());
2005 Wave4 q2(p[2].p()), q3(p[3].p()), q4(p[4].p()), q5(p[5].p());
2007 // Calculate the four pion system energy.
2010 // Create the hadronic current for the 3 neutral pion channel.
2011 if (abs(pID[3]) == 111)
2012 u2.push_back(G(1,s)*(t1(q,q3,q4,q5,q2) + t1(q,q3,q2,q5,q4) +
2013 t1(q,q4,q3,q5,q2) + t1(q,q4,q2,q5,q3) +
2014 t1(q,q2,q3,q5,q4) + t1(q,q2,q4,q5,q3) +
2015 t2(q,q3,q5,q4,q2) + t2(q,q4,q5,q3,q2) +
2016 t2(q,q2,q5,q4,q3) - t2(q,q5,q3,q4,q2) -
2017 t2(q,q5,q4,q3,q2) - t2(q,q5,q2,q4,q3)));
2019 // Create the hadronic current for the 3 charged pion channel.
2020 else if (abs(pID[3]) == 211)
2021 u2.push_back(G(2,s)*(t1(q,q3,q5,q4,q2) + t1(q,q4,q5,q3,q2) +
2022 t1(q,q3,q4,q5,q2) + t1(q,q4,q3,q5,q2) +
2023 t1(q,q2,q4,q3,q5) + t1(q,q2,q3,q4,q5) +
2024 t2(q,q2,q4,q3,q5) + t2(q,q2,q3,q4,q5) -
2025 t2(q,q3,q2,q4,q5) - t2(q,q4,q2,q3,q5)) +
2026 G(3,s)*(t3(q,q3,q5,q4,q2) + t3(q,q4,q5,q3,q2) -
2027 t3(q,q3,q4,q5,q2) - t3(q,q4,q3,q5,q2) -
2028 t3(q,q3,q2,q4,q5) - t3(q,q4,q2,q3,q5)));
2033 //--------------------------------------------------------------------------
2035 // Return the first t-vector.
2037 Wave4 HMETau2FourPions::t1(Wave4 &q, Wave4 &q1, Wave4 &q2,
2038 Wave4 &q3, Wave4 &q4) {
2040 Wave4 a1Q(q2 + q3 + q4);
2041 Wave4 rhoQ(q3 + q4);
2042 double a1S = m2(a1Q);
2043 double rhoS = m2(rhoQ);
2045 // Needed to match Herwig++.
2046 double gM = sqrtpos(rhoM*rhoM - 4*picM*picM) * (rhoM*rhoM - 4*picM*picM)
2048 double dm = (rhoFormFactor1(0) - rhoFormFactor1(rhoM*rhoM) +
2049 rhoM*rhoM * rhoFormFactor2(rhoM*rhoM)) / gM;
2050 return - a1FormFactor(a1S) / (a1D(a1S) * rhoD(rhoS)) * pow2(a1M) *
2051 (rhoM*rhoM + rhoM*rhoG*dm) *
2052 (m2(q,a1Q) * (m2(q3,a1Q) * q4 - m2(q4,a1Q) * q3) +
2053 (m2(q,q4) * m2(q1,q3) - m2(q,q3) * m2(q1,q4)) * a1Q);
2057 //--------------------------------------------------------------------------
2059 // Return the second t-vector.
2061 Wave4 HMETau2FourPions::t2(Wave4 &q, Wave4 &/*q1*/, Wave4 &q2,
2062 Wave4 &q3, Wave4 &q4) {
2064 Wave4 a1Q(q2 + q3 + q4);
2065 Wave4 sigQ(q3 + q4);
2066 double a1S = m2(a1Q);
2067 double sigS = m2(sigQ);
2068 return sigW * a1FormFactor(a1S) / (a1D(a1S) * sigD(sigS)) *
2069 pow2(a1M) * pow2(sigM) * (m2(q,a1Q) * a1S * q2 - m2(q,q2) * a1S * a1Q);
2073 //--------------------------------------------------------------------------
2075 // Return the third t-vector.
2077 Wave4 HMETau2FourPions::t3(Wave4 &q, Wave4 &q1, Wave4 &q2,
2078 Wave4 &q3, Wave4 &q4) {
2079 Wave4 omeQ(q2 + q3 + q4);
2080 Wave4 rhoQ(q3 + q4);
2081 double omeS = m2(omeQ);
2082 double rhoS = m2(rhoQ);
2084 // Needed to match Herwig++.
2085 double gM = sqrtpos(rhoM*rhoM - 4*picM*picM) * (rhoM*rhoM - 4*picM*picM)
2087 double dm = (rhoFormFactor1(0) - rhoFormFactor1(rhoM*rhoM) +
2088 rhoM*rhoM * rhoFormFactor2(rhoM*rhoM)) / gM;
2089 return omeW * omeFormFactor(omeS) / (omeD(omeS) * rhoD(rhoS)) *
2090 pow2(omeM) * (rhoM*rhoM + rhoM*rhoG*dm) *
2091 ((m2(q,q3) * m2(q1,q4) - m2(q,q4) * m2(q1,q3)) * q2 +
2092 (m2(q,q4) * m2(q1,q2) - m2(q,q2) * m2(q1,q4)) * q3 +
2093 (m2(q,q2) * m2(q1,q3) - m2(q,q3) * m2(q1,q2)) * q4);
2097 //--------------------------------------------------------------------------
2099 // Return the D function for the a1(1260).
2101 complex HMETau2FourPions::a1D(double s) {
2103 // rG is defined as the running width.
2106 // The rho and pion cut off thresholds defined in the fit.
2107 double piM = 0.16960;
2108 double rM = 0.83425;
2110 // Fit of width below three pion mass threshold.
2114 // Fit of width below pion and rho mass threshold.
2116 rG = 0.003052*pow3(s - piM)*(1.0 + 151.088*(s - piM) +
2117 174.495*pow2(s - piM));
2119 // Fit of width above pion and rho mass threshold.
2121 rG = 2.60817 - 2.47790*s + 0.66539*pow2(s) - 0.0678183*pow3(s) +
2122 1.66577*(s-1.23701)/s;
2123 return s - a1M*a1M + complex(0,1) * sqrtpos(s) * rG;
2127 //--------------------------------------------------------------------------
2129 // Return the D function for the rho(770).
2131 complex HMETau2FourPions::rhoD(double s) {
2133 double gQ = sqrtpos(s - 4*picM*picM) * (s - 4*picM*picM) / sqrtpos(s);
2134 double gM = sqrtpos(rhoM*rhoM - 4*picM*picM) * (rhoM*rhoM - 4*picM*picM)
2136 double dm = (rhoFormFactor1(s) - rhoFormFactor1(rhoM*rhoM) -
2137 (s - rhoM*rhoM) * rhoFormFactor2(rhoM*rhoM)) / gM;
2139 // Ensure complex part is zero below available channel.
2140 if (s < 4*picM*picM) gQ = 0;
2141 return s - rhoM*rhoM - rhoM*rhoG*dm + complex(0,1)*rhoM*rhoG*(gQ/gM);
2145 //--------------------------------------------------------------------------
2147 // Return the D function for the sigma(800) (just s-wave running width).
2149 complex HMETau2FourPions::sigD(double s) {
2151 // Sigma decay to two neutral pions for three neutral pion channel.
2152 double piM = abs(pID[3]) == 111 ? pinM : picM;
2153 double gQ = sqrtpos(1.0 - 4*piM*piM/s);
2154 double gM = sqrtpos(1.0 - 4*piM*piM/(sigM*sigM));
2155 return s - sigM*sigM + complex(0,1)*sigM*sigG*gQ/gM;
2159 //--------------------------------------------------------------------------
2161 // Return the D function for the omega(782).
2163 complex HMETau2FourPions::omeD(double s) {
2166 double q = sqrtpos(s);
2167 double x = q - omeM;
2169 // Fit of width given in TAUOLA.
2171 g = 1 + 17.560*x + 141.110*pow2(x) + 894.884*pow3(x) + 4977.35*pow4(x) +
2172 7610.66*pow5(x) - 42524.4*pow6(x);
2174 g = -1333.26 + 4860*q - 6000.81*pow2(q) + 2504.97*pow3(q);
2176 return s - omeM*omeM + complex(0,1)*omeM*omeG*g;
2180 //--------------------------------------------------------------------------
2182 // Return the form factor for the a1.
2184 double HMETau2FourPions::a1FormFactor(double s) {
2186 return pow2((1.0 + a1M*a1M/lambda2) / (1.0 + s/lambda2));
2190 //--------------------------------------------------------------------------
2192 // Return the form factor for the rho(770) (equivalent to h(s) in TAUOLA).
2194 double HMETau2FourPions::rhoFormFactor1(double s) {
2197 if (s > 4*picM*picM) {
2198 f = sqrtpos(1 - 4*picM*picM/s);
2199 f = f * log((1 + f) / (1 - f)) * (s - 4*picM*picM) / M_PI;
2201 else if (s < 0.0000001)
2202 f = -8 * picM*picM / M_PI;
2209 //--------------------------------------------------------------------------
2211 // Return the form factor for the rho(770) (equivalent to h(s) derivative).
2213 double HMETau2FourPions::rhoFormFactor2(double s) {
2216 if (s > 4*picM*picM) {
2217 f = sqrtpos(1 - 4*picM*picM/s);
2218 f = f / (M_PI * s) * (s*f + (2*picM*picM + s)*log((1 + f) / (1 - f)));
2226 //--------------------------------------------------------------------------
2228 // Return the form factor for the omega(782).
2230 double HMETau2FourPions::omeFormFactor(double /*s*/) {
2236 //--------------------------------------------------------------------------
2238 // Return the G-functions given in TAUOLA using a piece-wise fit.
2240 double HMETau2FourPions::G(int i, double s) {
2242 // Break points for the fits.
2243 double s0(0), s1(0), s2(0), s3(0), s4(0), s5(0);
2245 // Parameters for the fits.
2246 double a1(0), b1(0);
2247 double a2(0), b2(0), c2(0), d2(0), e2(0);
2248 double a3(0), b3(0), c3(0), d3(0), e3(0);
2249 double a4(0), b4(0);
2250 double a5(0), b5(0);
2252 // Three neutral pion parameters.
2254 s0 = 0.614403; s1 = 0.656264; s2 = 1.57896;
2255 s3 = 3.08198; s4 = 3.12825; s5 = 3.17488;
2256 a1 = -23383.7; b1 = 38059.2;
2257 a2 = 230.368; b2 = -4.39368; c2 = 687.002;
2258 d2 = -732.581; e2 = 207.087;
2259 a3 = 1633.92; b3 = -2596.21; c3 = 1703.08;
2260 d3 = -501.407; e3 = 54.5919;
2261 a4 = -2982.44; b4 = 986.009;
2262 a5 = 6948.99; b5 = -2188.74;
2265 // Three charged pion parameters.
2267 s0 = 0.614403; s1 = 0.635161; s2 = 2.30794;
2268 s3 = 3.08198; s4 = 3.12825; s5 = 3.17488;
2269 a1 = -54171.5; b1 = 88169.3;
2270 a2 = 454.638; b2 = -3.07152; c2 = -48.7086;
2271 d2 = 81.9702; e2 = -24.0564;
2272 a3 = -162.421; b3 = 308.977; c3 = -27.7887;
2273 d3 = -48.5957; e3 = 10.6168;
2274 a4 = -2650.29; b4 = 879.776;
2275 a5 = 6936.99; b5 = -2184.97;
2278 // Omega mediated three charged pion parameters.
2280 s0 = 0.81364; s1 = 0.861709; s2 = 1.92621;
2281 s3 = 3.08198; s4 = 3.12825; s5 = 3.17488;
2282 a1 = -84888.9; b1 = 104332;
2283 a2 = 2698.15; b2 = -3.08302; c2 = 1936.11;
2284 d2 = -1254.59; e2 = 201.291;
2285 a3 = 7171.65; b3 = -6387.9; c3 = 3056.27;
2286 d3 = -888.63; e3 = 108.632;
2287 a4 = -5607.48; b4 = 1917.27;
2288 a5 = 26573; b5 = -8369.76;
2291 // Return the appropriate fit.
2297 return a2*pow(s,b2) + c2*pow2(s) + d2*pow3(s) + e2*pow4(s);
2299 return a3 + b3*s + c3*pow2(s) + d3*pow3(s) + e3*pow4(s);
2309 //==========================================================================
2311 // Tau decay matrix element for tau decay into five pions using the model given
2312 // in hep-ph/0602162v1.
2314 // Ja(q,q1,q2,q3,q4,q5): current through rho and omega resonances
2315 // Jb(q,q1,q2,q3,q4,q5): current through a1 and sigma resonances
2316 // breitWigner(s,M,G): s-wave Breit-Wigner assuming massless products
2317 // a1M: on-shell mass of the a1 resonance
2318 // a1G: width of the a1 resonance
2319 // rhoX: mass and width of the rho resonance
2320 // omegaX: mass, width, and weight of the omega resonance
2321 // sigmaX: mass, width, and weight of the sigma resonance
2323 //--------------------------------------------------------------------------
2325 // Initialize constants for the helicity matrix element.
2327 void HMETau2FivePions::initConstants() {
2329 // pi-, pi-, pi+, pi+, pi- decay.
2330 if (abs(pID[2]) == 211 && abs(pID[3]) == 211 && abs(pID[4]) == 211 &&
2331 abs(pID[5]) == 211 && abs(pID[6]) == 211)
2332 DECAYWEIGHTMAX = 4e4;
2333 // pi+, pi-, pi0, pi-, pi0 decay.
2334 else if (abs(pID[2]) == 111 && abs(pID[3]) == 111 && abs(pID[4]) == 211 &&
2335 abs(pID[5]) == 211 && abs(pID[6]) == 211)
2336 DECAYWEIGHTMAX = 1e7;
2337 // pi0, pi0, pi-, pi0, pi0 decay.
2338 else if (abs(pID[2]) == 111 && abs(pID[3]) == 111 && abs(pID[4]) == 111 &&
2339 abs(pID[5]) == 111 && abs(pID[6]) == 211)
2340 DECAYWEIGHTMAX = 1e5;
2343 a1M = 1.260; a1G = 0.400;
2344 rhoM = 0.776; rhoG = 0.150;
2345 omegaM = 0.782; omegaG = 0.0085; omegaW = 11.5;
2346 sigmaM = 0.800; sigmaG = 0.600; sigmaW = 1;
2350 //--------------------------------------------------------------------------
2352 // Initialize the hadronic current for the helicity matrix element.
2354 void HMETau2FivePions::initHadronicCurrent(vector<HelicityParticle>& p) {
2358 Wave4 q(p[2].p() + p[3].p() + p[4].p() + p[5].p() + p[6].p());
2359 Wave4 q2(p[2].p()), q3(p[3].p()), q4(p[4].p()), q5(p[5].p()), q6(p[6].p());
2360 // pi-, pi-, pi+, pi+, pi- decay.
2361 if (abs(pID[2]) == 211 && abs(pID[3]) == 211 && abs(pID[4]) == 211 &&
2362 abs(pID[5]) == 211 && abs(pID[6]) == 211)
2363 u2.push_back(Jb(q, q2, q3, q5, q6, q4) + Jb(q, q4, q3, q5, q6, q2)
2364 + Jb(q, q2, q4, q5, q6, q3) + Jb(q, q2, q3, q6, q5, q4)
2365 + Jb(q, q4, q3, q6, q5, q2) + Jb(q, q2, q4, q6, q5, q3));
2366 // pi+, pi-, pi0, pi-, pi0 decay.
2367 else if (abs(pID[2]) == 111 && abs(pID[3]) == 111 && abs(pID[4]) == 211 &&
2368 abs(pID[5]) == 211 && abs(pID[6]) == 211)
2369 u2.push_back(Ja(q, q6, q4, q2, q5, q3) + Ja(q, q6, q5, q2, q4, q3)
2370 + Ja(q, q6, q4, q3, q5, q2) + Ja(q, q6, q5, q3, q4, q2)
2371 + Jb(q, q4, q5, q6, q2, q3) + Jb(q, q2, q3, q4, q6, q5)
2372 + Jb(q, q2, q3, q5, q6, q4));
2373 // pi0, pi0, pi-, pi0, pi0 decay.
2374 else if (abs(pID[2]) == 111 && abs(pID[3]) == 111 && abs(pID[4]) == 111 &&
2375 abs(pID[5]) == 111 && abs(pID[6]) == 211)
2376 u2.push_back(Jb(q, q2, q3, q6, q4, q5) + Jb(q, q5, q3, q6, q4, q2)
2377 + Jb(q, q3, q4, q6, q2, q5) + Jb(q, q2, q4, q6, q3, q5)
2378 + Jb(q, q2, q5, q6, q4, q3) + Jb(q, q4, q5, q6, q2, q3));
2384 //--------------------------------------------------------------------------
2386 // Return the omega-rho hadronic current.
2388 Wave4 HMETau2FivePions::Ja(Wave4 &q, Wave4 &q1, Wave4 &q2,
2389 Wave4 &q3, Wave4 &q4, Wave4 &q5) {
2391 Wave4 j = epsilon(q1, q2, q3);
2392 return omegaW * (breitWigner(m2(q), a1M, a1G)
2393 * breitWigner(m2(q1 + q2 + q3), omegaM, omegaG)
2394 * breitWigner(m2(q4 + q5), rhoM, rhoG)
2395 * epsilon(q4 - q5, j, q)
2396 * (breitWigner(m2(q2 + q3), rhoM, rhoG)
2397 + breitWigner(m2(q1 + q3), rhoM, rhoG)
2398 + breitWigner(m2(q1 + q2), rhoM, rhoG)));
2402 //--------------------------------------------------------------------------
2404 // Return the a1-sigma hadronic current.
2406 Wave4 HMETau2FivePions::Jb(Wave4 &q, Wave4 &q1, Wave4 &q2,
2407 Wave4 &q3, Wave4 &q4, Wave4 &q5) {
2410 Wave4 a1Q = q1 + q2 + q3;
2411 double a1S = m2(a1Q);
2412 Wave4 j = (m2(q2, q1 - q3) / a1S * a1Q - q1 + q3)
2413 * breitWigner(m2(q1 + q3), rhoM, rhoG)
2414 + (m2(q1, q2 - q3) / a1S * a1Q - q2 + q3)
2415 * breitWigner(m2(q2 + q3), rhoM, rhoG);
2416 j = (j * gamma[4] * q / s) * q - j;
2417 return sigmaW * (breitWigner(s, a1M, a1G) * breitWigner(a1S, a1M, a1G)
2418 * breitWigner(m2(q4 + q5), sigmaM, sigmaG) * j);
2422 complex HMETau2FivePions::breitWigner(double s, double M, double G) {
2424 return M * M / (M * M - s - complex(0, 1) * M * G);
2428 //==========================================================================
2430 } // end namespace Pythia8