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
src
EvtGenModels
EvtBLLNuL.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
21
#include "
EvtGenModels/EvtBLLNuL.hh
"
22
23
#include "
EvtGenBase/EvtIdSet.hh
"
24
#include "
EvtGenBase/EvtPDL.hh
"
25
#include "
EvtGenBase/EvtParticle.hh
"
26
#include "
EvtGenBase/EvtReport.hh
"
27
#include "
EvtGenBase/EvtSpinType.hh
"
28
29
EvtBLLNuL::EvtBLLNuL
() :
m_calcAmp
()
30
{
31
}
32
33
std::string
EvtBLLNuL::getName
()
const
34
{
35
// The model name
36
return
"BLLNUL"
;
37
}
38
39
EvtDecayBase
*
EvtBLLNuL::clone
()
const
40
{
41
return
new
EvtBLLNuL
();
42
}
43
44
void
EvtBLLNuL::init
()
45
{
46
// check that there are 4 daughters
47
checkNDaug
( 4 );
48
49
// We expect that the parent to be a scalar (B meson) and
50
// the daughters to be ell+ (k1), ell- (k2), neutrino (k3)
51
// and the last lepton ell- (k4)
52
53
// Check spin types
54
checkSpinParent
(
EvtSpinType::SCALAR
);
55
56
checkSpinDaughter
( 0,
EvtSpinType::DIRAC
);
// ell+(k_1)
57
checkSpinDaughter
( 1,
EvtSpinType::DIRAC
);
// ell-(k_2)
58
checkSpinDaughter
( 2,
EvtSpinType::NEUTRINO
);
// neu (k_3)
59
checkSpinDaughter
( 3,
EvtSpinType::DIRAC
);
// ell-(k_4)
60
61
// Check that we have a charged B parent
62
static
const
EvtIdSet
BMesons{
"B-"
,
"B+"
};
63
if
( !BMesons.
contains
(
getParentId
() ) ) {
64
EvtGenReport
(
EVTGEN_ERROR
,
"EvtBLLNuL"
)
65
<<
"Expecting the parent to be a charged B. Found PDG = "
66
<<
EvtPDL::getStdHep
(
getParentId
() ) << std::endl;
67
::abort();
68
}
69
70
// Make sure the first two leptons are charged conjugates of each other
71
int
id1 =
EvtPDL::getStdHep
(
getDaug
( 0 ) );
72
int
id2 =
EvtPDL::getStdHep
(
getDaug
( 1 ) );
73
if
( id1 != -id2 ) {
74
EvtGenReport
(
EVTGEN_ERROR
,
"EvtBLLNuL"
)
75
<<
"Expecting the first 2 leptons, with PDG codes "
<< id1 <<
" and "
76
<< id2 <<
", to be charged conjugates of each other"
<< std::endl;
77
::abort();
78
}
79
80
// Check that the last lepton has the same charge as the B parent
81
int
q3 =
EvtPDL::chg3
(
getDaug
( 3 ) ) / 3;
82
int
qB =
EvtPDL::chg3
(
getParentId
() ) / 3;
83
if
( q3 != qB ) {
84
EvtGenReport
(
EVTGEN_ERROR
,
"EvtBLLNuL"
)
85
<<
"The 3rd lepton charge "
<< q3 <<
" does not match the B charge "
86
<< qB << std::endl;
87
::abort();
88
}
89
90
// Also check that the 2nd lepton has the same charge as the 3rd one
91
int
q2 =
EvtPDL::chg3
(
getDaug
( 1 ) ) / 3;
92
if
( q2 != q3 ) {
93
EvtGenReport
(
EVTGEN_ERROR
,
"EvtBLLNuL"
)
94
<<
"The 2nd lepton charge "
<< q2
95
<<
" does not match the 3rd lepton charge "
<< q3 << std::endl;
96
::abort();
97
}
98
99
// Identify if the decay has 3 charged leptons with the same flavour.
100
// If so, then we need to include amplitude terms where the 2nd and 3rd
101
// same-sign leptons are interchanged: k2 <-> k4
102
bool
symmetry(
false
);
103
int
id3 =
EvtPDL::getStdHep
(
getDaug
( 3 ) );
104
105
if
(
abs
( id1 ) ==
abs
( id2 ) &&
abs
( id1 ) ==
abs
( id3 ) ) {
106
symmetry =
true
;
107
}
108
109
// Specify the qSq minimum cut-off as 4*(muon mass)^2 = 0.044655 and the
110
// kSq minimum cut off as 4*(electron mass)^2 = 1.044e-6
111
double
muMass =
EvtPDL::getMeanMass
(
EvtPDL::getId
(
"mu+"
) );
112
double
eMass =
EvtPDL::getMeanMass
(
EvtPDL::getId
(
"e+"
) );
113
double
qSqMin = 4.0 * muMass * muMass;
114
double
kSqMin = 4.0 * eMass * eMass;
115
116
// Optionally set these cut-offs using two decay file parameters. We may
117
// have a 3rd parameter (max prob), so check for at least 2 parameters
118
if
(
getNArg
() >= 2 ) {
119
qSqMin =
getArg
( 0 );
120
kSqMin =
getArg
( 1 );
121
}
122
123
// Define the amplitude qSq and kSq cut-offs, also
124
// specifying if the decay mode has flavour symmetry
125
m_calcAmp
.setParameters( qSqMin, kSqMin, symmetry );
126
}
127
128
void
EvtBLLNuL::initProbMax
()
129
{
130
// Set the maximum probability of the decay
131
double
maxProb( 3.2 );
132
133
// Optional 3rd decay file parameter, e.g. if qSq and/or kSq min have changed.
134
// Note that both qSq and kSq parameters must still be specified in the decay
135
// file to ensure that the maximum probability value is the 3rd parameter!
136
if
(
getNArg
() == 3 ) {
137
maxProb =
getArg
( 2 );
138
}
139
140
setProbMax
( maxProb );
141
}
142
143
void
EvtBLLNuL::decay
(
EvtParticle
* p )
144
{
145
p->
initializePhaseSpace
(
getNDaug
(),
getDaugs
() );
146
147
m_calcAmp
.CalcAmp( p,
m_amp2
);
148
}
EvtBLLNuL.hh
abs
double abs(const EvtComplex &c)
Definition
EvtComplex.hh:203
EvtIdSet.hh
EvtPDL.hh
EvtParticle.hh
EvtReport.hh
EvtGenReport
std::ostream & EvtGenReport(EvtGenSeverity severity, const char *facility=nullptr)
Definition
EvtReport.cpp:32
EVTGEN_ERROR
@ EVTGEN_ERROR
Definition
EvtReport.hh:49
EvtSpinType.hh
EvtBLLNuL::init
virtual void init() override
Definition
EvtBLLNuL.cpp:44
EvtBLLNuL::EvtBLLNuL
EvtBLLNuL()
Definition
EvtBLLNuL.cpp:29
EvtBLLNuL::initProbMax
virtual void initProbMax() override
Definition
EvtBLLNuL.cpp:128
EvtBLLNuL::decay
virtual void decay(EvtParticle *p) override
Definition
EvtBLLNuL.cpp:143
EvtBLLNuL::m_calcAmp
EvtBLLNuLAmp m_calcAmp
Definition
EvtBLLNuL.hh:49
EvtBLLNuL::getName
virtual std::string getName() const override
Definition
EvtBLLNuL.cpp:33
EvtBLLNuL::clone
virtual EvtDecayBase * clone() const override
Definition
EvtBLLNuL.cpp:39
EvtDecayAmp::m_amp2
EvtAmp m_amp2
Definition
EvtDecayAmp.hh:73
EvtDecayBase::checkSpinDaughter
void checkSpinDaughter(int d1, EvtSpinType::spintype sp)
Definition
EvtDecayBase.cpp:547
EvtDecayBase::EvtDecayBase
EvtDecayBase()=default
EvtDecayBase::getNDaug
int getNDaug() const
Definition
EvtDecayBase.hh:64
EvtDecayBase::checkSpinParent
void checkSpinParent(EvtSpinType::spintype sp)
Definition
EvtDecayBase.cpp:534
EvtDecayBase::getNArg
int getNArg() const
Definition
EvtDecayBase.hh:67
EvtDecayBase::getArg
double getArg(unsigned int j)
Definition
EvtDecayBase.cpp:578
EvtDecayBase::setProbMax
void setProbMax(double prbmx)
Definition
EvtDecayBase.cpp:295
EvtDecayBase::getParentId
EvtId getParentId() const
Definition
EvtDecayBase.hh:60
EvtDecayBase::getDaug
EvtId getDaug(int i) const
Definition
EvtDecayBase.hh:66
EvtDecayBase::checkNDaug
void checkNDaug(int d1, int d2=-1)
Definition
EvtDecayBase.cpp:516
EvtDecayBase::getDaugs
const EvtId * getDaugs() const
Definition
EvtDecayBase.hh:65
EvtIdSet
Definition
EvtIdSet.hh:30
EvtIdSet::contains
bool contains(const EvtId &id) const
Definition
EvtIdSet.cpp:46
EvtPDL::getStdHep
static int getStdHep(EvtId id)
Definition
EvtPDL.cpp:356
EvtPDL::chg3
static int chg3(EvtId i)
Definition
EvtPDL.cpp:366
EvtPDL::getMeanMass
static double getMeanMass(EvtId i)
Definition
EvtPDL.cpp:306
EvtPDL::getId
static EvtId getId(const std::string &name)
Definition
EvtPDL.cpp:283
EvtParticle
Definition
EvtParticle.hh:45
EvtParticle::initializePhaseSpace
double initializePhaseSpace(size_t numdaughter, const EvtId *daughters, bool forceResetMasses=false, double poleSize=-1., int whichTwo1=0, int whichTwo2=1)
Definition
EvtParticle.cpp:1100
EvtSpinType::NEUTRINO
@ NEUTRINO
Definition
EvtSpinType.hh:35
EvtSpinType::SCALAR
@ SCALAR
Definition
EvtSpinType.hh:30
EvtSpinType::DIRAC
@ DIRAC
Definition
EvtSpinType.hh:33
Generated by
1.16.1