EvtGen
2.2.0
Monte Carlo generator of particle decays, in particular the weak decays of heavy flavour particles such as B mesons.
Toggle main menu visibility
Loading...
Searching...
No Matches
src
EvtGenModels
EvtCBTo3piMPP.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/EvtCBTo3piMPP.hh
"
22
23
#include "
EvtGenBase/EvtGenKine.hh
"
24
#include "
EvtGenBase/EvtId.hh
"
25
#include "
EvtGenBase/EvtPDL.hh
"
26
#include "
EvtGenBase/EvtParticle.hh
"
27
#include "
EvtGenBase/EvtReport.hh
"
28
29
#include <stdlib.h>
30
#include <string>
31
32
std::string
EvtCBTo3piMPP::getName
()
const
33
{
34
return
"CB3PI-MPP"
;
35
}
36
37
EvtCBTo3piMPP
*
EvtCBTo3piMPP::clone
()
const
38
{
39
return
new
EvtCBTo3piMPP
;
40
}
41
42
void
EvtCBTo3piMPP::init
()
43
{
44
// check that there are 1 argument
45
checkNArg
( 1 );
46
checkNDaug
( 3 );
47
48
checkSpinParent
(
EvtSpinType::SCALAR
);
49
50
checkSpinDaughter
( 0,
EvtSpinType::SCALAR
);
51
checkSpinDaughter
( 1,
EvtSpinType::SCALAR
);
52
checkSpinDaughter
( 2,
EvtSpinType::SCALAR
);
53
54
EvtVector4R
p4[3];
55
double
alpha =
getArg
( 0 );
56
57
int
iset( 10000 );
58
double
realA, imgA, realbarA, imgbarA;
59
60
m_generator
.Evt3piMPP( alpha, iset, p4[0], p4[1], p4[2], realA, imgA,
61
realbarA, imgbarA );
62
}
63
64
void
EvtCBTo3piMPP::initProbMax
()
65
{
66
setProbMax
( 1.5 );
67
}
68
69
void
EvtCBTo3piMPP::decay
(
EvtParticle
* p )
70
{
71
//added by Lange Jan4,2000
72
static
const
EvtId
BM =
EvtPDL::getId
(
"B-"
);
73
static
const
EvtId
BP =
EvtPDL::getId
(
"B+"
);
74
75
EvtParticle
*pi1, *pi2, *pi3;
76
77
p->
makeDaughters
(
getNDaug
(),
getDaugs
() );
78
pi1 = p->
getDaug
( 0 );
79
pi2 = p->
getDaug
( 1 );
80
pi3 = p->
getDaug
( 2 );
81
82
EvtVector4R
p4[3];
83
double
alpha =
getArg
( 0 );
84
85
int
iset( 0 );
86
double
realA, imgA, realbarA, imgbarA;
87
88
m_generator
.Evt3piMPP( alpha, iset, p4[0], p4[1], p4[2], realA, imgA,
89
realbarA, imgbarA );
90
91
pi1->
init
(
getDaug
( 0 ), p4[0] );
92
pi2->
init
(
getDaug
( 1 ), p4[1] );
93
pi3->
init
(
getDaug
( 2 ), p4[2] );
94
95
EvtComplex
A( realA, imgA );
96
EvtComplex
Abar( realbarA, imgbarA );
97
98
//amp is filled just to make sure the compiler will
99
//do its job!! but one has to define amp differently
100
// if one wants the B+ or the B- to decay to 3pi!
101
//
102
103
EvtComplex
amp;
104
if
( p->
getId
() == BP ) {
105
amp = A;
106
}
107
if
( p->
getId
() == BM ) {
108
amp = Abar;
109
}
110
111
vertex
( amp );
112
113
return
;
114
}
EvtCBTo3piMPP.hh
EvtGenKine.hh
EvtId.hh
EvtPDL.hh
EvtParticle.hh
EvtReport.hh
EvtCBTo3piMPP
Definition
EvtCBTo3piMPP.hh:31
EvtCBTo3piMPP::m_generator
EvtBTo3hCP m_generator
Definition
EvtCBTo3piMPP.hh:42
EvtCBTo3piMPP::initProbMax
void initProbMax() override
Definition
EvtCBTo3piMPP.cpp:64
EvtCBTo3piMPP::getName
std::string getName() const override
Definition
EvtCBTo3piMPP.cpp:32
EvtCBTo3piMPP::init
void init() override
Definition
EvtCBTo3piMPP.cpp:42
EvtCBTo3piMPP::decay
void decay(EvtParticle *p) override
Definition
EvtCBTo3piMPP.cpp:69
EvtCBTo3piMPP::clone
EvtCBTo3piMPP * clone() const override
Definition
EvtCBTo3piMPP.cpp:37
EvtComplex
Definition
EvtComplex.hh:29
EvtDecayAmp::vertex
void vertex(const EvtComplex &)
Definition
EvtDecayAmp.hh:37
EvtDecayBase::checkSpinDaughter
void checkSpinDaughter(int d1, EvtSpinType::spintype sp)
Definition
EvtDecayBase.cpp:547
EvtDecayBase::getNDaug
int getNDaug() const
Definition
EvtDecayBase.hh:64
EvtDecayBase::checkSpinParent
void checkSpinParent(EvtSpinType::spintype sp)
Definition
EvtDecayBase.cpp:534
EvtDecayBase::getArg
double getArg(unsigned int j)
Definition
EvtDecayBase.cpp:578
EvtDecayBase::setProbMax
void setProbMax(double prbmx)
Definition
EvtDecayBase.cpp:295
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::checkNArg
void checkNArg(int a1, int a2=-1, int a3=-1, int a4=-1)
Definition
EvtDecayBase.cpp:492
EvtDecayBase::getDaugs
const EvtId * getDaugs() const
Definition
EvtDecayBase.hh:65
EvtId
Definition
EvtId.hh:27
EvtPDL::getId
static EvtId getId(const std::string &name)
Definition
EvtPDL.cpp:283
EvtParticle
Definition
EvtParticle.hh:45
EvtParticle::init
virtual void init(EvtId part_n, const EvtVector4R &p4)=0
EvtParticle::getId
EvtId getId() const
Definition
EvtParticle.cpp:124
EvtParticle::getDaug
EvtParticle * getDaug(const int i)
Definition
EvtParticle.hh:173
EvtParticle::makeDaughters
void makeDaughters(size_t ndaug, const EvtId *id)
Definition
EvtParticle.cpp:1235
EvtSpinType::SCALAR
@ SCALAR
Definition
EvtSpinType.hh:30
EvtVector4R
Definition
EvtVector4R.hh:29
Generated by
1.17.0