EvtGen 2.2.0
Monte Carlo generator of particle decays, in particular the weak decays of heavy flavour particles such as B mesons.
Loading...
Searching...
No Matches
EvtSVSCPLH.cpp
Go to the documentation of this file.
1
2/***********************************************************************
3* Copyright 1998-2020 CERN for the benefit of the EvtGen authors *
4* *
5* This file is part of EvtGen. *
6* *
7* EvtGen is free software: you can redistribute it and/or modify *
8* it under the terms of the GNU General Public License as published by *
9* the Free Software Foundation, either version 3 of the License, or *
10* (at your option) any later version. *
11* *
12* EvtGen is distributed in the hope that it will be useful, *
13* but WITHOUT ANY WARRANTY; without even the implied warranty of *
14* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
15* GNU General Public License for more details. *
16* *
17* You should have received a copy of the GNU General Public License *
18* along with EvtGen. If not, see <https://www.gnu.org/licenses/>. *
19***********************************************************************/
20
22
26#include "EvtGenBase/EvtId.hh"
27#include "EvtGenBase/EvtPDL.hh"
31
32#include <stdlib.h>
33#include <string>
34using std::endl;
35
36std::string EvtSVSCPLH::getName() const
37{
38 return "SVS_CPLH";
39}
40
42{
43 return new EvtSVSCPLH;
44}
45
47{
48 // check that there are 8 arguments
49 checkNArg( 8 );
50 checkNDaug( 2 );
51
53
56
57 static const double ctau = EvtPDL::getctau( EvtPDL::getId( "B0" ) );
58
59 // hbar/s
60 m_dm = getArg( 0 );
61 m_dgamma = EvtConst::c * getArg( 1 ) / ctau;
62
63 m_qop = getArg( 2 ) * exp( EvtComplex( 0.0, getArg( 3 ) ) );
64
65 m_poq = 1.0 / m_qop;
66
67 m_Af = getArg( 4 ) * exp( EvtComplex( 0.0, getArg( 5 ) ) );
68 m_Abarf = getArg( 6 ) * exp( EvtComplex( 0.0, getArg( 7 ) ) );
69
70 if ( verbose() ) {
71 EvtGenReport( EVTGEN_INFO, "EvtGen" )
72 << ":EvtSVSCPLH:dm=" << m_dm << endl;
73 EvtGenReport( EVTGEN_INFO, "EvtGen" )
74 << ":EvtSVSCPLH:dGamma=" << m_dgamma << endl;
75 EvtGenReport( EVTGEN_INFO, "EvtGen" )
76 << ":EvtSVSCPLH:q/p=" << m_qop << endl;
77 EvtGenReport( EVTGEN_INFO, "EvtGen" )
78 << ":EvtSVSCPLH:Af=" << m_Af << endl;
79 EvtGenReport( EVTGEN_INFO, "EvtGen" )
80 << ":EvtSVSCPLH:Abarf=" << m_Abarf << endl;
81 }
82}
83
85{
86 //This is probably not quite right, but it should do as a start...
87 //Anders
88
89 setProbMax( 4.0 * ( getArg( 4 ) * getArg( 4 ) + getArg( 6 ) * getArg( 6 ) ) );
90}
91
93{
95
96 static const EvtId B0 = EvtPDL::getId( "B0" );
97 static const EvtId B0B = EvtPDL::getId( "anti-B0" );
98
99 double t;
100 EvtId other_b;
101
102 EvtCPUtil::getInstance()->OtherB( p, t, other_b, 0.5 );
103
104 //convert time from mm to seconds
105 t /= EvtConst::c;
106
107 //sign convention is dm=Mheavy-Mlight
108 // dGamma=Gammalight-Gammaheavy
109 //such that in the standard model both of these are positive.
110 EvtComplex gp =
111 0.5 * ( exp( EvtComplex( 0.25 * t * m_dgamma, -0.5 * t * m_dm ) ) +
112 exp( EvtComplex( -0.25 * t * m_dgamma, 0.5 * t * m_dm ) ) );
113 EvtComplex gm =
114 0.5 * ( exp( EvtComplex( 0.25 * t * m_dgamma, -0.5 * t * m_dm ) ) -
115 exp( EvtComplex( -0.25 * t * m_dgamma, 0.5 * t * m_dm ) ) );
116
117 EvtComplex amp;
118
119 if ( other_b == B0B ) {
120 amp = gp * m_Af + m_qop * gm * m_Abarf;
121 } else if ( other_b == B0 ) {
122 amp = gp * m_Abarf + m_poq * gm * m_Af;
123 } else {
124 EvtGenReport( EVTGEN_ERROR, "EvtGen" )
125 << "other_b was not B0 or B0B!" << endl;
126 ::abort();
127 }
128
129 EvtVector4R p4_parent = p->getP4Restframe();
130 ;
131
132 double norm = p->getDaug( 0 )->mass() /
133 ( p->getDaug( 0 )->getP4().d3mag() * p4_parent.mass() );
134
135 EvtParticle* v = p->getDaug( 0 );
136
137 vertex( 0, amp * norm * ( p4_parent * ( v->epsParent( 0 ) ) ) );
138 vertex( 1, amp * norm * ( p4_parent * ( v->epsParent( 1 ) ) ) );
139 vertex( 2, amp * norm * ( p4_parent * ( v->epsParent( 2 ) ) ) );
140
141 return;
142}
EvtComplex exp(const EvtComplex &c)
std::ostream & EvtGenReport(EvtGenSeverity severity, const char *facility=nullptr)
Definition EvtReport.cpp:32
@ EVTGEN_INFO
Definition EvtReport.hh:52
@ EVTGEN_ERROR
Definition EvtReport.hh:49
static EvtCPUtil * getInstance()
Definition EvtCPUtil.cpp:42
void OtherB(EvtParticle *p, double &t, EvtId &otherb)
static const double c
Definition EvtConst.hh:30
void vertex(const EvtComplex &amp)
void checkSpinDaughter(int d1, EvtSpinType::spintype sp)
EvtDecayBase()=default
int getNDaug() const
void checkSpinParent(EvtSpinType::spintype sp)
double getArg(unsigned int j)
void setProbMax(double prbmx)
bool verbose() const
void checkNDaug(int d1, int d2=-1)
void checkNArg(int a1, int a2=-1, int a3=-1, int a4=-1)
const EvtId * getDaugs() const
Definition EvtId.hh:27
static double getctau(EvtId i)
Definition EvtPDL.cpp:351
static EvtId getId(const std::string &name)
Definition EvtPDL.cpp:283
virtual EvtVector4C epsParent(int i) const
double initializePhaseSpace(size_t numdaughter, const EvtId *daughters, bool forceResetMasses=false, double poleSize=-1., int whichTwo1=0, int whichTwo2=1)
EvtVector4R getP4Restframe() const
EvtParticle * getDaug(const int i)
double mass() const
double m_dm
Definition EvtSVSCPLH.hh:47
void decay(EvtParticle *p) override
void init() override
void initProbMax() override
EvtDecayBase * clone() const override
std::string getName() const override
double m_dgamma
Definition EvtSVSCPLH.hh:48
EvtComplex m_poq
Definition EvtSVSCPLH.hh:45
EvtComplex m_Af
Definition EvtSVSCPLH.hh:44
EvtComplex m_Abarf
Definition EvtSVSCPLH.hh:44
EvtComplex m_qop
Definition EvtSVSCPLH.hh:45
double mass() const