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.
EvtFourBodyPhsp.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 EVTFOURBODYPHSP_HH
22 #define EVTFOURBODYPHSP_HH
23 
24 #include <vector>
25 #include <array>
26 #include <utility>
27 
29 
30 class EvtParticle;
31 
32 class EvtFourBodyPhsp : public EvtDecayProb {
33  public:
34  enum Shape
35  {
36  rectangle = 1,
37  trapezoid = 2,
38  pentagon = 3,
40  };
41 
42  std::string getName() override;
43  EvtDecayBase* clone() override;
44 
45  void init() override;
46  void initProbMax() override;
47 
48  void decay( EvtParticle* parent ) override;
49 
50  private:
51  std::array<double, 4> phspFactor( const double mM, const double m12,
52  const double m34,
53  std::array<double, 4>& daughters ) const;
54  Shape determineBoundaryShape( const double m12Min, const double m12Max,
55  const double m34Max,
56  const double mMother ) const;
57 
58  std::pair<double, double> generatePairMasses(
59  const double m12Min, const double m12Max, const double m34Min,
60  const double m34Max, const double mMother,
61  const EvtFourBodyPhsp::Shape shape ) const;
62  std::pair<double, double> generateRectangle( const double m12Min,
63  const double m12Max,
64  const double m34Min,
65  const double m34Max ) const;
66  std::pair<double, double> generateTrapezoid( const double m12Min,
67  const double m12Max,
68  const double m34Min,
69  const double mMother ) const;
70 
71  std::array<double, 4> m_daughterMasses{ -1, -1, -1, -1 };
72 
73  double m_m12Min;
74  double m_m12Max;
75  double m_m34Min;
76  double m_m34Max;
77 
78  double m_trapNorm;
79  double m_trapCoeff1;
80  double m_trapCoeff2;
81 
84 
86 
87  bool m_stableMother{true};
88  bool m_stableDaughters{true};
89  bool m_fixedBoundary{true};
90 };
91 
92 #endif
void initProbMax() override
Shape determineBoundaryShape(const double m12Min, const double m12Max, const double m34Max, const double mMother) const
void decay(EvtParticle *parent) override
std::pair< double, double > generatePairMasses(const double m12Min, const double m12Max, const double m34Min, const double m34Max, const double mMother, const EvtFourBodyPhsp::Shape shape) const
void init() override
std::array< double, 4 > phspFactor(const double mM, const double m12, const double m34, std::array< double, 4 > &daughters) const
std::array< double, 4 > m_daughterMasses
EvtDecayBase * clone() override
std::pair< double, double > generateTrapezoid(const double m12Min, const double m12Max, const double m34Min, const double mMother) const
std::string getName() override
std::pair< double, double > generateRectangle(const double m12Min, const double m12Max, const double m34Min, const double m34Max) const