CGEM BOSS 6.6.5.f
BESIII Offline Software System
Loading...
Searching...
No Matches
EvtFlatLineShape.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: EvtLineShape.cc
12//
13// Description: Store particle properties for one particle.
14//
15// Modification history:
16//
17// Lange March 10, 2001 Module created
18// Dvoretskii June 03, 2002 Reimplemented rollMass()
19//
20//------------------------------------------------------------------------
22
30#include "EvtGenBase/EvtPDL.hh"
32
34
35}
36
38}
39
40EvtFlatLineShape::EvtFlatLineShape(double mass, double width, double maxRange, EvtSpinType::spintype sp) {
41
42 _mass=mass;
43 _width=width;
44 _spin=sp;
45 _maxRange=maxRange;
46
47 double maxdelta = width;
48
49 _massMax=mass+maxdelta;
50 _massMin=mass-maxdelta;
51
52 if ( _massMin< 0. ) _massMin=0.;
53
54}
55
57 _mass=x._mass;
58 _width=x._width;
59 _spin=x._spin;
60 _massMax=x._massMax;
61 _massMin=x._massMin;
62 _maxRange=x._maxRange;
63
64}
65
67 _mass=x._mass;
68 _massMax=x._massMax;
69 _massMin=x._massMin;
70 _width=x._width;
71 _maxRange=x._maxRange;
72 _spin=x._spin;
73 return *this;
74
75}
76
78
79 return new EvtFlatLineShape(*this);
80}
81
82
83double EvtFlatLineShape::getMassProb(double mass, double massPar,int nDaug, double *massDau) {
84
85
86 double dTotMass=0.;
87
88 int i;
89 for (i=0; i<nDaug; i++) {
90 dTotMass+=massDau[i];
91 }
92 if ( (mass<dTotMass) ) return 0.;
93
94 if ( massPar>0.0000000001 ) {
95 if ( mass > massPar) return 0.;
96 }
97
98 return 1.;
99}
100
101double EvtFlatLineShape::getRandMass(EvtId *parId,int nDaug, EvtId *dauId, EvtId *othDaugId, double massMax, double *dauMasses) {
102
104}
105
106
107
108
double mass
Double_t x[10]
EvtSpinType::spintype _spin
double getRandMass(EvtId *parId, int nDaug, EvtId *dauId, EvtId *othDaugId, double maxMass, double *dauMasses)
EvtFlatLineShape & operator=(const EvtFlatLineShape &x)
EvtAbsLineShape * clone()
double getMassProb(double mass, double massPar, int nDaug, double *massDau)
Definition: EvtId.hh:27
static double Flat()
Definition: EvtRandom.cc:73