BOSS
8.0.0
BESIII Offline Software System
Loading...
Searching...
No Matches
EvtSVSNONCPEIGEN.cc
Go to the documentation of this file.
1
//--------------------------------------------------------------------------
2
//
3
// Environment:
4
// This software is part of the EvtGen package developed jointly
5
// for the BaBar and CLEO collaborations. If you use all or part
6
// of it, please give an appropriate acknowledgement.
7
//
8
// Copyright Information: See EvtGen/COPYRIGHT
9
// Copyright (C) 1998 Caltech, UCSB
10
//
11
// Module: EvtSVSNONCPEIGEN.cc
12
//
13
// Description: Routine to decay scalar -> vectors scalar
14
// and has CP violation.
15
//
16
// Modification history:
17
//
18
// RYD April 26, 1997 Module created
19
//
20
//------------------------------------------------------------------------
21
//
22
#include "
EvtSVSNONCPEIGEN.hh
"
23
#include "
../EvtGenBase/EvtCPUtil.hh
"
24
#include "
../EvtGenBase/EvtConst.hh
"
25
#include "
../EvtGenBase/EvtGenKine.hh
"
26
#include "
../EvtGenBase/EvtPDL.hh
"
27
#include "
../EvtGenBase/EvtParticle.hh
"
28
#include "
../EvtGenBase/EvtPatches.hh
"
29
#include "
../EvtGenBase/EvtRandom.hh
"
30
#include "
../EvtGenBase/EvtReport.hh
"
31
#include "
../EvtGenBase/EvtVector4C.hh
"
32
#include <stdlib.h>
33
#include <string>
34
35
EvtSVSNONCPEIGEN::~EvtSVSNONCPEIGEN
() {}
36
37
void
EvtSVSNONCPEIGEN::getName
( std::string& model_name ) { model_name =
"SVS_NONCPEIGEN"
; }
38
39
EvtDecayBase
*
EvtSVSNONCPEIGEN::clone
() {
return
new
EvtSVSNONCPEIGEN
; }
40
41
void
EvtSVSNONCPEIGEN::init
() {
42
43
// check that there are 11 arguments
44
checkNArg
( 11, 7 );
45
checkNDaug
( 2 );
46
47
checkSpinDaughter
( 0,
EvtSpinType::VECTOR
);
48
checkSpinDaughter
( 1,
EvtSpinType::SCALAR
);
49
50
_dm =
getArg
( 1 );
51
_phickm = 2 *
getArg
( 0 ) +
getArg
( 2 );
52
53
_A_f =
EvtComplex
(
getArg
( 3 ) *
cos
(
getArg
( 4 ) ),
getArg
( 3 ) *
sin
(
getArg
( 4 ) ) );
54
_Abar_f =
EvtComplex
(
getArg
( 5 ) *
cos
(
getArg
( 6 ) ),
getArg
( 5 ) *
sin
(
getArg
( 6 ) ) );
55
56
_A_fbar = _Abar_f;
57
_Abar_fbar = _A_f;
58
59
if
(
getNArg
() == 11 )
60
{
61
_A_fbar =
EvtComplex
(
getArg
( 7 ) *
cos
(
getArg
( 8 ) ),
getArg
( 7 ) *
sin
(
getArg
( 8 ) ) );
62
_Abar_fbar =
63
EvtComplex
(
getArg
( 9 ) *
cos
(
getArg
( 10 ) ),
getArg
( 9 ) *
sin
(
getArg
( 10 ) ) );
64
}
65
}
66
67
void
EvtSVSNONCPEIGEN::initProbMax
() {
68
double
theProbMax =
abs
( _A_f ) *
abs
( _A_f ) +
abs
( _Abar_f ) *
abs
( _Abar_f ) +
69
abs
( _A_fbar ) *
abs
( _A_fbar ) +
abs
( _Abar_fbar ) *
abs
( _Abar_fbar );
70
71
setProbMax
( theProbMax );
72
}
73
74
void
EvtSVSNONCPEIGEN::decay
(
EvtParticle
* p ) {
75
76
// added by Lange Jan4,2000
77
static
EvtId
B0 =
EvtPDL::getId
(
"B0"
);
78
static
EvtId
B0B =
EvtPDL::getId
(
"anti-B0"
);
79
80
double
t
;
81
EvtId
other_b;
82
EvtId
daugs[2];
83
84
// MB: flip selects the final of the decay
85
int
flip = ( ( p->
getId
() == B0 ) ? 0 : 1 );
86
daugs[0] =
getDaug
( 0 );
87
daugs[1] =
getDaug
( 1 );
88
p->
initializePhaseSpace
( 2, daugs );
89
90
EvtCPUtil::OtherB
( p,
t
, other_b, 0.5 );
91
92
EvtComplex
amp;
93
double
dmt2 = ( _dm *
t
) / ( 2 *
EvtConst::c
);
94
EvtComplex
ePlusIPhi(
cos
( _phickm ),
sin
( _phickm ) );
95
EvtComplex
eMinusIPhi(
cos
( -_phickm ), -
sin
( _phickm ) );
96
97
// flip == 0 : D-rho+
98
// flip == 1 : D+rho-
99
100
if
( !flip )
101
{
102
if
( other_b == B0B )
103
{
104
// At t=0 we have a B0
105
amp =
cos
( dmt2 ) * _A_f + eMinusIPhi *
EvtComplex
( 0.0,
sin
( dmt2 ) ) * _Abar_f;
106
}
107
if
( other_b == B0 )
108
{
109
// At t=0 we have a B0bar
110
amp = ePlusIPhi *
EvtComplex
( 0.0,
sin
( dmt2 ) ) * _A_f +
cos
( dmt2 ) * _Abar_f;
111
}
112
}
113
else
114
{
115
if
( other_b == B0B )
116
{
117
// At t=0 we have a B0
118
amp =
cos
( dmt2 ) * _A_fbar + eMinusIPhi *
EvtComplex
( 0.0,
sin
( dmt2 ) ) * _Abar_fbar;
119
}
120
if
( other_b == B0 )
121
{
122
// At t=0 we have a B0bar
123
amp = ePlusIPhi *
EvtComplex
( 0.0,
sin
( dmt2 ) ) * _A_fbar +
cos
( dmt2 ) * _Abar_fbar;
124
}
125
}
126
127
EvtParticle
*
v
;
128
v
= p->
getDaug
( 0 );
129
130
EvtVector4R
momv = p->
getDaug
( 0 )->
getP4
();
131
EvtVector4R
moms = p->
getDaug
( 1 )->
getP4
();
132
EvtVector4R
p4_parent = momv + moms;
133
134
double
norm = momv.
mass
() / ( momv.
d3mag
() * p->
mass
() );
135
136
vertex
( 0, amp * norm * p4_parent * (
v
->epsParent( 0 ) ) );
137
vertex
( 1, amp * norm * p4_parent * (
v
->epsParent( 1 ) ) );
138
vertex
( 2, amp * norm * p4_parent * (
v
->epsParent( 2 ) ) );
139
140
return
;
141
}
abs
#define abs(x)
Definition
Eepipi/src/ee2eepp/basesv5.1/f2c.h:155
EvtCPUtil.hh
EvtConst.hh
EvtGenKine.hh
EvtPDL.hh
EvtParticle.hh
EvtPatches.hh
EvtRandom.hh
EvtReport.hh
EvtSVSNONCPEIGEN.hh
EvtVector4C.hh
sin
double sin(const BesAngle a)
Definition
InstallArea/x86_64-el9-gcc13-dbg/include/MdcGeom/BesAngle.h:185
cos
double cos(const BesAngle a)
Definition
InstallArea/x86_64-el9-gcc13-dbg/include/MdcGeom/BesAngle.h:187
v
**********Class see also m_nmax DOUBLE PRECISION m_amel DOUBLE PRECISION m_x2 DOUBLE PRECISION m_alfinv DOUBLE PRECISION m_Xenph INTEGER m_KeyWtm INTEGER m_idyfs DOUBLE PRECISION m_zini DOUBLE PRECISION m_q2 DOUBLE PRECISION m_Wt_KF DOUBLE PRECISION m_WtCut INTEGER m_KFfin *COMMON c_KarLud $ !Input CMS energy[GeV] $ !CMS energy after beam spread beam strahlung[GeV] $ !Beam energy spread[GeV] $ !z boost due to beam spread $ !electron beam mass *ff pair spectrum $ !minimum v
Definition
KarLud.h:35
EvtCPUtil::OtherB
static void OtherB(EvtParticle *p, double &t, EvtId &otherb)
Definition
EvtCPUtil.cc:225
EvtComplex
Definition
EvtComplex.hh:28
EvtConst::c
static const double c
Definition
EvtConst.hh:31
EvtDecayAmp::vertex
void vertex(const EvtComplex &)
Definition
EvtDecayAmp.hh:36
EvtDecayBase::checkSpinDaughter
void checkSpinDaughter(int d1, EvtSpinType::spintype sp)
Definition
EvtDecayBase.cc:492
EvtDecayBase::getArg
double getArg(int j)
Definition
EvtDecayBase.cc:520
EvtDecayBase::EvtDecayBase
EvtDecayBase()
Definition
EvtDecayBase.cc:205
EvtDecayBase::setProbMax
void setProbMax(double prbmx)
Definition
EvtDecayBase.cc:261
EvtDecayBase::getNArg
int getNArg()
Definition
EvtDecayBase.hh:70
EvtDecayBase::checkNDaug
void checkNDaug(int d1, int d2=-1)
Definition
EvtDecayBase.cc:465
EvtDecayBase::checkNArg
void checkNArg(int a1, int a2=-1, int a3=-1, int a4=-1)
Definition
EvtDecayBase.cc:449
EvtDecayBase::getDaug
EvtId getDaug(int i)
Definition
EvtDecayBase.hh:69
EvtId
Definition
EvtId.hh:27
EvtPDL::getId
static EvtId getId(const std::string &name)
Definition
EvtPDL.cc:272
EvtParticle
Definition
EvtParticle.hh:42
EvtParticle::getId
EvtId getId() const
Definition
EvtParticle.cc:100
EvtParticle::getP4
const EvtVector4R & getP4() const
Definition
EvtParticle.cc:108
EvtParticle::getDaug
EvtParticle * getDaug(int i)
Definition
EvtParticle.cc:80
EvtParticle::mass
double mass() const
Definition
EvtParticle.cc:114
EvtParticle::initializePhaseSpace
double initializePhaseSpace(int numdaughter, EvtId *daughters, double poleSize=-1., int whichTwo1=0, int whichTwo2=1)
Definition
EvtParticle.cc:1042
EvtSVSNONCPEIGEN::clone
EvtDecayBase * clone()
Definition
EvtSVSNONCPEIGEN.cc:39
EvtSVSNONCPEIGEN::~EvtSVSNONCPEIGEN
virtual ~EvtSVSNONCPEIGEN()
Definition
EvtSVSNONCPEIGEN.cc:35
EvtSVSNONCPEIGEN::init
void init()
Definition
EvtSVSNONCPEIGEN.cc:41
EvtSVSNONCPEIGEN::decay
void decay(EvtParticle *p)
Definition
EvtSVSNONCPEIGEN.cc:74
EvtSVSNONCPEIGEN::getName
void getName(std::string &name)
Definition
EvtSVSNONCPEIGEN.cc:37
EvtSVSNONCPEIGEN::EvtSVSNONCPEIGEN
EvtSVSNONCPEIGEN()
Definition
EvtSVSNONCPEIGEN.hh:31
EvtSVSNONCPEIGEN::initProbMax
void initProbMax()
Definition
EvtSVSNONCPEIGEN.cc:67
EvtSpinType::SCALAR
@ SCALAR
Definition
EvtSpinType.hh:31
EvtSpinType::VECTOR
@ VECTOR
Definition
EvtSpinType.hh:32
EvtVector4R
Definition
EvtVector4R.hh:29
EvtVector4R::mass
double mass() const
Definition
EvtVector4R.cc:40
EvtVector4R::d3mag
double d3mag() const
Definition
EvtVector4R.cc:168
t
int t()
Definition
t.c:1
8.0.0
BOSS_Gen
BesEvtGen
src
EvtGen
EvtGenModels
EvtSVSNONCPEIGEN.cc
Generated by
1.16.1