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
EvtPVVCPLH.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
33
34#include <stdlib.h>
35#include <string>
36
37std::string EvtPVVCPLH::getName() const
38{
39 return "PVV_CPLH";
40}
41
43{
44 return new EvtPVVCPLH;
45}
46
48{
49 // check that there are 8 arguments (deltaMs no argument anymore)
50 checkNArg( 8 );
51 checkNDaug( 2 );
52
54
57}
58
60{
61 //This is probably not quite right, but it should do as a start...
62 //Anders
63
64 setProbMax( 2 * ( getArg( 2 ) * getArg( 2 ) + getArg( 4 ) * getArg( 4 ) +
65 getArg( 6 ) * getArg( 6 ) ) );
66}
67
69{
70 //added by Lange Jan4,2000
71 static const EvtId BS0 = EvtPDL::getId( "B_s0" );
72 static const EvtId BSB = EvtPDL::getId( "anti-B_s0" );
73
74 //This is only to get tag-ID
75 //Mixing is not relevant
76 //Lifetime is made correctly later
77 //Tristan
78 EvtId other_b;
79 double t;
80
81 // To generate integrated CP asymmetry, EvtGen uses the "flipping".
82 // CP-asymmetry in this channel very small, since:
83 // deltaMs large ..and..
84 // CPV-phase small
85 EvtCPUtil::getInstance()->OtherB( p, t, other_b );
86
87 //Here we're gonna generate and set the "envelope" lifetime
88 //So we take the longest living component (for positive deltaGamma: tauH)
89 //The double exponent will be taken care of later, by the amplitudes
90 //Tristan
91
92 static const double Gamma = EvtConst::c / ( EvtPDL::getctau( BS0 ) );
93 static const double deltaGamma = EvtCPUtil::getInstance()->getDeltaGamma(
94 BS0 );
95 static const double ctauLong = EvtConst::c /
96 ( Gamma - fabs( deltaGamma ) / 2 );
97 // if dG>0: tauLong=tauH(CP-odd) is then largest
98
99 //This overrules the lifetimes made in OtherB
100 t = -log( EvtRandom::Flat() ) *
101 ( ctauLong ); //ctauLong has same dimensions as t
102 if ( isBsMixed( p ) ) {
103 p->getParent()->setLifetime( t );
104 } else {
105 p->setLifetime( t );
106 }
107
108 //These should be filled with the transversity amplitudes at t=0 //Tristan
109 EvtComplex G0P, G1P, G1M;
110 G1P = EvtComplex( getArg( 2 ) * cos( getArg( 3 ) ),
111 getArg( 2 ) * sin( getArg( 3 ) ) );
112 G0P = EvtComplex( getArg( 4 ) * cos( getArg( 5 ) ),
113 getArg( 4 ) * sin( getArg( 5 ) ) );
114 G1M = EvtComplex( getArg( 6 ) * cos( getArg( 7 ) ),
115 getArg( 6 ) * sin( getArg( 7 ) ) );
116
117 EvtComplex lambda_km =
118 EvtComplex( cos( 2 * getArg( 0 ) ),
119 sin( 2 * getArg( 0 ) ) ); //was een min in oude versie
120
121 //deltaMs is no argument anymore
122 //Tristan
123
124 static const double deltaMs = EvtCPUtil::getInstance()->getDeltaM( BS0 );
125
126 EvtComplex cG0P, cG1P, cG1M;
127
128 double mt = exp( -std::max( 0., deltaGamma ) * t / ( 2 * EvtConst::c ) );
129 double pt = exp( +std::min( 0., deltaGamma ) * t / ( 2 * EvtConst::c ) );
130
131 EvtComplex gplus =
132 ( mt * EvtComplex( cos( deltaMs * t / ( 2 * EvtConst::c ) ),
133 sin( deltaMs * t / ( 2 * EvtConst::c ) ) ) +
134 pt * EvtComplex( cos( deltaMs * t / ( 2 * EvtConst::c ) ),
135 sin( -deltaMs * t / ( 2 * EvtConst::c ) ) ) ) /
136 2;
137 EvtComplex gminus =
138 ( mt * EvtComplex( cos( deltaMs * t / ( 2 * EvtConst::c ) ),
139 sin( deltaMs * t / ( 2 * EvtConst::c ) ) ) -
140 pt * EvtComplex( cos( deltaMs * t / ( 2 * EvtConst::c ) ),
141 sin( -deltaMs * t / ( 2 * EvtConst::c ) ) ) ) /
142 2;
143 ;
144
145 if ( other_b == BSB ) {
146 //These are the right equations for the transversity formalism
147 //cGOP is de 0-component, CP-even, so lives shorter: mainly lifetime tauL
148 //cG1P is the //-component, also CP-even, also mainly smaller exponent
149 //cG1M is the transverse component, CP-odd, so has mainly longer lifetime tauH
150 //Tristan
151 cG0P = G0P * ( gplus + lambda_km * gminus );
152 cG1P = G1P * ( gplus + lambda_km * gminus );
153 cG1M = G1M * ( gplus - lambda_km * gminus );
154 } else if ( other_b == BS0 ) {
155 //The equations for BsBar
156 //Note the minus-sign difference
157 //Tristan
158 cG0P = G0P * ( gplus + ( 1.0 / lambda_km ) * gminus );
159 cG1P = G1P * ( gplus + ( 1.0 / lambda_km ) * gminus );
160 cG1M = -G1M * ( gplus - ( 1.0 / lambda_km ) * gminus );
161
162 } else {
163 EvtGenReport( EVTGEN_ERROR, "EvtGen" )
164 << "other_b was not BSB or BS0!" << std::endl;
165 ::abort();
166 }
167
168 EvtComplex A0, AP, AM;
169 //Converting the transversity amplitudes
170 //to helicity amplitudes
171 //(to plug them into SVVHelAmp)
172 A0 = cG0P;
173 AP = ( cG1P + cG1M ) / sqrt( 2.0 );
174 AM = ( cG1P - cG1M ) / sqrt( 2.0 );
175
176 EvtSVVHelAmp::SVVHel( p, m_amp2, getDaug( 0 ), getDaug( 1 ), AP, A0, AM );
177
178 return;
179}
180
182{
183 if ( !( p->getParent() ) )
184 return false;
185
186 static const EvtId BS0 = EvtPDL::getId( "B_s0" );
187 static const EvtId BSB = EvtPDL::getId( "anti-B_s0" );
188
189 if ( ( p->getId() != BS0 ) && ( p->getId() != BSB ) )
190 return false;
191
192 if ( ( p->getParent()->getId() == BS0 ) || ( p->getParent()->getId() == BSB ) )
193 return true;
194
195 return false;
196}
EvtComplex exp(const EvtComplex &c)
std::ostream & EvtGenReport(EvtGenSeverity severity, const char *facility=nullptr)
Definition EvtReport.cpp:32
@ EVTGEN_ERROR
Definition EvtReport.hh:49
static EvtCPUtil * getInstance()
Definition EvtCPUtil.cpp:42
double getDeltaM(const EvtId id)
double getDeltaGamma(const EvtId id)
void OtherB(EvtParticle *p, double &t, EvtId &otherb)
static const double c
Definition EvtConst.hh:30
EvtAmp m_amp2
void checkSpinDaughter(int d1, EvtSpinType::spintype sp)
EvtDecayBase()=default
void checkSpinParent(EvtSpinType::spintype sp)
double getArg(unsigned int j)
void setProbMax(double prbmx)
EvtId getDaug(int i) const
void checkNDaug(int d1, int d2=-1)
void checkNArg(int a1, int a2=-1, int a3=-1, int a4=-1)
Definition EvtId.hh:27
static double getctau(EvtId i)
Definition EvtPDL.cpp:351
static EvtId getId(const std::string &name)
Definition EvtPDL.cpp:283
void initProbMax() override
EvtDecayBase * clone() const override
std::string getName() const override
bool isBsMixed(EvtParticle *p)
void decay(EvtParticle *p) override
void init() override
EvtId getId() const
void setLifetime(double tau)
EvtParticle * getParent() const
static double Flat()
Definition EvtRandom.cpp:95
static void SVVHel(EvtParticle *parent, EvtAmp &amp, EvtId n_v1, EvtId n_v2, const EvtComplex &hp, const EvtComplex &h0, const EvtComplex &hm)