evtgen is hosted by Hepforge, IPPP Durham
EvtGen  2.0.0
Monte Carlo generator of particle decays, in particular the weak decays of heavy flavour particles such as B mesons.
EvtPartProp.hh
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 #ifndef EVTPARTPROP_HH
22 #define EVTPARTPROP_HH
23 
25 #include "EvtGenBase/EvtId.hh"
27 
28 #include <memory>
29 #include <string>
30 
31 class EvtPartProp {
32  public:
33  EvtPartProp();
34  EvtPartProp( const EvtPartProp& x );
35 
36  double getMass() { return _lineShape->getMass(); }
37  double getMassMin() { return _lineShape->getMassMin(); }
38  double getMassMax() { return _lineShape->getMassMax(); }
39  double getMaxRange() { return _lineShape->getMaxRange(); }
40  double getWidth() { return _lineShape->getWidth(); }
41 
42  double getRandMass( EvtId* parId, int nDaug, EvtId* dauId, EvtId* othDauId,
43  double maxMass, double* dauMasses )
44  {
45  return _lineShape->getRandMass( parId, nDaug, dauId, othDauId, maxMass,
46  dauMasses );
47  }
48  double getMassProb( double mass, double massPar, int nDaug, double* massDau )
49  {
50  return _lineShape->getMassProb( mass, massPar, nDaug, massDau );
51  }
52 
53  double getctau() { return _ctau; }
54  void setctau( double tau ) { _ctau = tau; }
55 
56  int getChg3() { return _chg3; }
57  void setChg3( int c3 ) { _chg3 = c3; }
58 
60  void setSpinType( EvtSpinType::spintype stype ) { _spintype = stype; }
61 
62  const std::string& getName() { return _name; }
63  void setName( std::string pname );
64 
65  EvtId getId() { return _id; }
66  void setId( EvtId id ) { _id = id; }
67 
69  void setIdChgConj( EvtId idchgconj ) { _idchgconj = idchgconj; }
70 
71  int getStdHep() { return _stdhep; }
72  void setStdHep( int stdhep ) { _stdhep = stdhep; }
73 
74  int getLundKC() { return _lundkc; }
75  void setLundKC( int lundkc ) { _lundkc = lundkc; }
76 
78  void initLineShape( double mass, double width, double maxRange );
79  // void initLineShape(double mass, double width, double maxRange, double mDaug1, double mDaug2, int l);
80 
81  // setLineShape takes ownership of l
82  void setLineShape( EvtAbsLineShape* l ) { _lineShape.reset( l ); }
83  double rollMass() { return _lineShape->rollMass(); }
84 
85  EvtPartProp& operator=( const EvtPartProp& x );
86 
87  void reSetMass( double mass );
88  void reSetWidth( double width );
89 
90  void reSetMassMin( double mass );
91  void reSetMassMax( double mass );
92  void reSetBlatt( double blatt );
93  void reSetBlattBirth( double blatt );
94  void includeBirthFactor( bool yesno );
95  void includeDecayFactor( bool yesno );
96  void newLineShape( std::string type );
97  void setPWForDecay( int spin, EvtId d1, EvtId d2 );
98  void setPWForBirthL( int spin, EvtId par, EvtId othD );
99 
100  private:
101  std::unique_ptr<EvtAbsLineShape> _lineShape;
102 
103  double _ctau;
107  int _chg3;
108  int _stdhep;
109  int _lundkc;
110  std::string _name;
111 };
112 
113 #endif
void setStdHep(int stdhep)
Definition: EvtPartProp.hh:72
EvtSpinType::spintype _spintype
Definition: EvtPartProp.hh:106
int getChg3()
Definition: EvtPartProp.hh:56
double getMassMin()
Definition: EvtPartProp.hh:37
std::string _name
Definition: EvtPartProp.hh:110
double rollMass()
Definition: EvtPartProp.hh:83
double getctau()
Definition: EvtPartProp.hh:53
void setPWForDecay(int spin, EvtId d1, EvtId d2)
void setChg3(int c3)
Definition: EvtPartProp.hh:57
void includeDecayFactor(bool yesno)
void setctau(double tau)
Definition: EvtPartProp.hh:54
EvtId _idchgconj
Definition: EvtPartProp.hh:105
double getMass()
Definition: EvtPartProp.hh:36
double _ctau
Definition: EvtPartProp.hh:103
void setIdChgConj(EvtId idchgconj)
Definition: EvtPartProp.hh:69
void setPWForBirthL(int spin, EvtId par, EvtId othD)
void setSpinType(EvtSpinType::spintype stype)
Definition: EvtPartProp.hh:60
EvtId getId()
Definition: EvtPartProp.hh:65
Definition: EvtId.hh:27
void reSetMassMax(double mass)
void setName(std::string pname)
Definition: EvtPartProp.cpp:57
EvtId getIdChgConj()
Definition: EvtPartProp.hh:68
EvtPartProp & operator=(const EvtPartProp &x)
Definition: EvtPartProp.cpp:62
void reSetMassMin(double mass)
std::unique_ptr< EvtAbsLineShape > _lineShape
Definition: EvtPartProp.hh:101
EvtAbsLineShape * getLineShape()
Definition: EvtPartProp.hh:77
EvtSpinType::spintype getSpinType()
Definition: EvtPartProp.hh:59
void reSetBlattBirth(double blatt)
double getMaxRange()
Definition: EvtPartProp.hh:39
void reSetMass(double mass)
void setLineShape(EvtAbsLineShape *l)
Definition: EvtPartProp.hh:82
double getRandMass(EvtId *parId, int nDaug, EvtId *dauId, EvtId *othDauId, double maxMass, double *dauMasses)
Definition: EvtPartProp.hh:42
void includeBirthFactor(bool yesno)
double getMassMax()
Definition: EvtPartProp.hh:38
double getMassProb(double mass, double massPar, int nDaug, double *massDau)
Definition: EvtPartProp.hh:48
int getLundKC()
Definition: EvtPartProp.hh:74
void reSetBlatt(double blatt)
void setLundKC(int lundkc)
Definition: EvtPartProp.hh:75
void newLineShape(std::string type)
Definition: EvtPartProp.cpp:80
int getStdHep()
Definition: EvtPartProp.hh:71
void initLineShape(double mass, double width, double maxRange)
Definition: EvtPartProp.cpp:73
void setId(EvtId id)
Definition: EvtPartProp.hh:66
const std::string & getName()
Definition: EvtPartProp.hh:62
double getWidth()
Definition: EvtPartProp.hh:40
void reSetWidth(double width)