RestFrames
v1.0.1
RestFrames HEP Event Analysis Software Library
|
Go to the documentation of this file.
33 namespace RestFrames {
40 const std::string& stitle)
53 ResonanceGenFrame::~ResonanceGenFrame() {}
56 return ResonanceGenFrame::m_Empty;
64 m_Log <<
"Unable to set mass to negative value ";
65 m_Log << val <<
". Setting to zero." << LogEnd;
79 m_Log <<
"Unable to set width to negative value ";
80 m_Log << val <<
". Setting to zero." << LogEnd;
82 SetVariableMassMCMC(
false);
85 SetVariableMassMCMC(
true);
94 SetVariableMassMCMC(
true);
98 m_Log <<
"Unable to set variable mass. ";
99 m_Log <<
"Resonance width is set to zero. " << LogEnd;
103 SetVariableMassMCMC(
false);
120 double den = mass*mass-m_PoleMass*m_PoleMass;
122 den += m_PoleMass*m_PoleMass*m_Width*m_Width;
131 prob,
double max)
const {
134 for(
int i = 0; i < N; i++)
137 if(((max < min) && (max > 0)) || m_Width <= 0.){
146 double M2 = m_PoleMass*m_PoleMass;
147 double MW = m_PoleMass*m_Width;
148 double Imin = atan((min*min-M2)/MW);
151 Imax = TMath::Pi()/2.;
153 Imax = atan((max*max-M2)/MW);
155 mass = sqrt(M2 + MW*tan(Imin+
GetRandom()*(Imax-Imin)));
157 double den = mass*mass-m_PoleMass*m_PoleMass;
159 den += m_PoleMass*m_PoleMass*m_Width*m_Width;
static ResonanceGenFrame & Empty()
Returns empty ResonanceGenFrame.
ResonanceGenFrame()
Empty constructor.
int GetNChildren() const
Returns the number of child frames inheriting from this one.
virtual void SetWidth(double w)
Sets width of current frame.
double GetRandom() const
Returns random value.
virtual void SetMass(double mass)
Sets mass of current frame.
virtual double GetPoleMass() const
Returns pole mass of current frame.
virtual GeneratorFrame & GetChildFrame(int i=0) const
Returns the frame of the i th child.
virtual double GetProbMCMC(double mass=-1.) const
Evaluates probability of the state is in right now or the probablility of a state it could go in.
virtual void SetVariableMass(bool varymass=true)
Determines who sets mass of current frame.
virtual double GetWidth() const
Returns width of current frame.
virtual double GetProbMCMC(double mass=-1.) const
Evaluates probability of the state is in right now or the probablility of a state it could go in.
virtual double GetMass() const
Get the mass of this frame.
virtual void GenerateMassMCMC(double &mass, double &prob, double max=-1.) const
Generates mass for Markov Chain MonteCarlo event generation.