MINT2
DalitzPhaseSpaceBox.h
Go to the documentation of this file.
1 #ifndef DALITZ_PHASESPACE_BOX_HH
2 #define DALITZ_PHASESPACE_BOX_HH
3 // author: Jonas Rademacker (Jonas.Rademacker@bristol.ac.uk)
4 // status: Mon 9 Feb 2009 19:17:58 GMT
7 #include "Mint/DalitzEventList.h"
8 
9 #include "Mint/IGenFct.h"
10 
11 #include "Mint/counted_ptr.h"
12 
13 #include "TRandom.h"
14 
15 #include <vector>
16 #include <string>
17 #include <iostream>
18 
20  std::string _name;
22  TRandom* _rnd;
23  double _height;
24  double _weight;
26 
27  double doPhaseSpaceIntegral();
29  public:
30  double& height(){ return _height;}
31  const double& height() const{ return _height;}
32 
33  void setWeight(double w){_weight = w;} // every event gets the same.
34  double weight() const{return _weight;}
35  double& weight(){return _weight;}
36 
37  DalitzPhaseSpaceBox(TRandom* rnd = gRandom);
39  , TRandom* rnd = gRandom
40  );
43 
44  const DalitzEventPattern& pattern()const{return _pat;}
45  void setPattern(const DalitzEventPattern& pat);
46 
47  void setName(const std::string& name){ _name = name;}
48  const std::string& name() const{return _name;}
49 
50  double volume() const;
51 
52  double genValue() const;
53  double genValue(const DalitzEvent& evt) const;
54 
55  bool insideArea(const DalitzEvent& evt) const;
56 
59 
60  bool setRnd(TRandom* rnd=gRandom);
61 
62  double phaseSpaceIntegral() const;
63  double phaseSpaceIntegral(); // re-evaluates if necessary
64 
65  bool checkIntegration() const;
66 
67  void print(std::ostream& os = std::cout) const;
68 
69 };
70 
71 std::ostream& operator<<(std::ostream& os, const DalitzPhaseSpaceBox& box);
72 
73 
74 #endif
75 //
void setPattern(const DalitzEventPattern &pat)
MINT::counted_ptr< DalitzEvent > tryNewEvent()
void setWeight(double w)
DalitzEventPattern _pat
MINT::counted_ptr< DalitzEvent > tryEventForOwner()
bool insideArea(const DalitzEvent &evt) const
const double & height() const
MINT::counted_ptr< DalitzEvent > makeEventForOwner()
DalitzPhaseSpaceBox(TRandom *rnd=gRandom)
const std::string & name() const
void print(std::ostream &os=std::cout) const
std::ostream & operator<<(std::ostream &os, const DalitzPhaseSpaceBox &box)
void setName(const std::string &name)
double phaseSpaceIntegral() const
bool setRnd(TRandom *rnd=gRandom)
const DalitzEventPattern & pattern() const