BOSS
8.0.0
BESIII Offline Software System
Loading...
Searching...
No Matches
EvtPhsp.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: EvtPhsp.cc
12
//
13
// Description: Routine to decay a particle according th phase space
14
//
15
// Modification history:
16
//
17
// RYD January 8, 1997 Module created
18
//
19
//------------------------------------------------------------------------
20
//
21
#include "
EvtPhsp.hh
"
22
#include "
../EvtGenBase/EvtGenKine.hh
"
23
#include "
../EvtGenBase/EvtGlobalSet.hh
"
24
#include "
../EvtGenBase/EvtPDL.hh
"
25
#include "
../EvtGenBase/EvtParticle.hh
"
26
#include "
../EvtGenBase/EvtPatches.hh
"
27
#include "
../EvtGenBase/EvtReport.hh
"
28
#include <stdlib.h>
29
#include <string>
30
31
EvtPhsp::~EvtPhsp
() {}
32
33
void
EvtPhsp::getName
( std::string& model_name ) { model_name =
"PHSP"
; }
34
35
EvtDecayBase
*
EvtPhsp::clone
() {
return
new
EvtPhsp
; }
36
37
void
EvtPhsp::init
() {
38
39
// check that there are 0 arguments
40
checkNArg
( 0 );
41
}
42
43
void
EvtPhsp::initProbMax
() {
noProbMax
(); }
44
45
void
EvtPhsp::decay
(
EvtParticle
* p ) {
46
47
// unneeded - lange - may13-02
48
// if ( p->getNDaug() != 0 ) {
49
// Will end up here because maxrate multiplies by 1.2
50
// report(DEBUG,"EvtGen") << "In EvtPhsp: has "
51
// <<" daugthers should not be here!"<<endl;
52
// return;
53
//}
54
EvtFilter:
55
double
weight
= p->
initializePhaseSpace
(
getNDaug
(),
getDaugs
() );
56
// std::cout<<"weight= "<<weight<<std::endl;
57
if
( !
EvtGlobalSet::iVV
.size() )
return
;
58
59
for
(
int
i = 0; i <
EvtGlobalSet::iVV
.size(); i++ )
60
{
61
EvtVector4R
psum( 0, 0, 0, 0 );
62
for
(
int
j = 0; j <
EvtGlobalSet::iVV
[i].size(); j++ )
63
{
64
int
idx =
EvtGlobalSet::iVV
[i][j];
65
psum += p->
getDaug
( idx )->
getP4
();
66
// debugging
67
// std::cout<<idx<<std::endl;
68
}
69
double
xmass
= psum.
mass
();
70
// std::cout<<xmass<<" "<<EvtGlobalSet::dVV[i][0]<<" "<<EvtGlobalSet::dVV[i][1]<<std::endl;
71
if
(
xmass
<
EvtGlobalSet::dVV
[i][0] ||
xmass
>
EvtGlobalSet::dVV
[i][1] )
goto
EvtFilter;
72
}
73
74
return
;
75
}
EvtGenKine.hh
EvtGlobalSet.hh
EvtPDL.hh
EvtParticle.hh
EvtPatches.hh
EvtPhsp.hh
EvtReport.hh
xmass
const double xmass[5]
Definition
Gam4pikp.cxx:35
weight
*********Class see also m_nmax DOUBLE PRECISION m_MasPhot DOUBLE PRECISION m_phsu DOUBLE PRECISION m_Xenph DOUBLE PRECISION m_r2 DOUBLE PRECISION m_WtMass INTEGER m_nmax INTEGER m_Nevgen INTEGER m_IsFSR INTEGER m_MarTot *COMMON c_KarFin $ !Output file $ !Event serial number $ !alpha QED at Thomson limit $ !minimum energy at CMS for remooval $ !infrared dimensionless $ !dummy photon IR regulator $ !crude photon multiplicity enhancement factor *EVENT $ !MC crude volume of PhhSpace *Sfactors $ !YFS formfactor IR part only $ !YFS formfactor non IR finite part $ !mass weight
Definition
KarFin.h:34
EvtDecayBase::EvtDecayBase
EvtDecayBase()
Definition
EvtDecayBase.cc:205
EvtDecayBase::noProbMax
void noProbMax()
Definition
EvtDecayBase.cc:267
EvtDecayBase::getNDaug
int getNDaug()
Definition
EvtDecayBase.hh:67
EvtDecayBase::getDaugs
EvtId * getDaugs()
Definition
EvtDecayBase.hh:68
EvtDecayBase::checkNArg
void checkNArg(int a1, int a2=-1, int a3=-1, int a4=-1)
Definition
EvtDecayBase.cc:449
EvtGlobalSet::dVV
static std::vector< std::vector< double > > dVV
Definition
EvtGlobalSet.hh:20
EvtGlobalSet::iVV
static std::vector< std::vector< int > > iVV
Definition
EvtGlobalSet.hh:21
EvtParticle
Definition
EvtParticle.hh:42
EvtParticle::getP4
const EvtVector4R & getP4() const
Definition
EvtParticle.cc:108
EvtParticle::getDaug
EvtParticle * getDaug(int i)
Definition
EvtParticle.cc:80
EvtParticle::initializePhaseSpace
double initializePhaseSpace(int numdaughter, EvtId *daughters, double poleSize=-1., int whichTwo1=0, int whichTwo2=1)
Definition
EvtParticle.cc:1042
EvtPhsp::EvtPhsp
EvtPhsp()
Definition
EvtPhsp.hh:33
EvtPhsp::getName
void getName(std::string &name)
Definition
EvtPhsp.cc:33
EvtPhsp::clone
EvtDecayBase * clone()
Definition
EvtPhsp.cc:35
EvtPhsp::initProbMax
void initProbMax()
Definition
EvtPhsp.cc:43
EvtPhsp::~EvtPhsp
virtual ~EvtPhsp()
Definition
EvtPhsp.cc:31
EvtPhsp::decay
void decay(EvtParticle *p)
Definition
EvtPhsp.cc:45
EvtPhsp::init
void init()
Definition
EvtPhsp.cc:37
EvtVector4R
Definition
EvtVector4R.hh:29
EvtVector4R::mass
double mass() const
Definition
EvtVector4R.cc:40
8.0.0
BOSS_Gen
BesEvtGen
src
EvtGen
EvtGenModels
EvtPhsp.cc
Generated by
1.16.1