MINT2
Eff4piSymmetric.h
Go to the documentation of this file.
1 #ifndef MINT_EFF_FOUR_PI_SYMMETRIC_HH
2 #define MINT_EFF_FOUR_PI_SYMMETRIC_HH
3 
4 #include "Mint/IDalitzEvent.h"
6 
8 
9 #include "Mint/FitParameter.h"
11 #include "Mint/counted_ptr.h"
12 
13 #include "Mint/symMultiPolyTerm.h"
14 
15 #include <vector>
16 #include <iostream>
17 
18 class Eff4piSymmetric : virtual public MINT::IReturnRealForEvent<IDalitzEvent>
19 {
20  public:
23  const symPolyTerm& _t1;
24  const symPolyTerm& _t2;
25  std::string _prefix;
27 
28  bool makeFitParameter(double initVal, double guessError);
29 
30  public:
31  std::string name() const;
33  , const symPolyTerm& p2
34  , const std::string& prefix
35  , double initValue
36  , double guessError
37  , MINT::MinuitParameterSet* pset=0);
38 
39  double getVal(const std::vector<double* >& t1_coords
40  , const std::vector<double* >& t2_coords
41  ) const;
42  void print(std::ostream& os = std::cout) const;
43 
45  };
46 
47  protected:
48  int _order;
49 
52 
53  // can swap all three s terms amongst themselves.
54  // can swap the two t-terms (that's the bit
55  // that assumes charge symmetry)
56  mutable double _t01, _s12, _s23, _s34, _t40;
59 
60  mutable std::vector<double* > _tijVec, _sijVec;
61 
62  std::vector<symMultiPolyTerm> _tTerms, _sTerms;
63  std::vector< MINT::counted_ptr< ProdWithFitParameter > > _allTerms;
64 
65  bool init();
66  bool makeTerms();
67  bool makeSijTijVectors();
69 
70  virtual double getValFromSavedCoordinates() const;
71 
72 
73  public:
74 
75  Eff4piSymmetric(int order
76  , const DalitzEventPattern& pat
77  , MINT::MinuitParameterSet* pset=0);
78  virtual double getVal( double t01, double s12, double s23
79  , double s34, double t40) const;
80  virtual double getVal(const IDalitzEvent& evt) const;
81  virtual double getVal(const IDalitzEvent* evt) const{
82  // for backwards compatibility only, deprecated.
83  if(0 == evt) return 0;
84  return getVal(*evt);
85  }
86 
87  virtual double RealVal(IDalitzEvent& evt);
88 
89  void print(std::ostream& os = std::cout) const;
90  void printCentreAndTypicalVal(std::ostream& os = std::cout) const;
91  void fixZerothTherm();
92 
93  virtual ~Eff4piSymmetric(){}
94 
95 };
96 
97 std::ostream& operator<<(std::ostream& os
99 
100 std::ostream& operator<<(std::ostream& os
101  , const Eff4piSymmetric& e4pi);
102 
103 
104 #endif
105 //
virtual double getVal(double t01, double s12, double s23, double s34, double t40) const
MINT::counted_ptr< MINT::FitParameter > fp()
std::vector< double * > _sijVec
virtual double RealVal(IDalitzEvent &evt)
ProdWithFitParameter(const symPolyTerm &p1, const symPolyTerm &p2, const std::string &prefix, double initValue, double guessError, MINT::MinuitParameterSet *pset=0)
double getVal(const std::vector< double * > &t1_coords, const std::vector< double * > &t2_coords) const
std::vector< double * > _tijVec
virtual double getVal(const IDalitzEvent *evt) const
std::vector< symMultiPolyTerm > _sTerms
std::vector< MINT::counted_ptr< ProdWithFitParameter > > _allTerms
DalitzEventPattern _pat
MINT::MinuitParameterSet * _pset
std::ostream & operator<<(std::ostream &os, const Eff4piSymmetric::ProdWithFitParameter &pwfp)
std::vector< symMultiPolyTerm > _tTerms
void print(std::ostream &os=std::cout) const
virtual double getValFromSavedCoordinates() const
void print(std::ostream &os=std::cout) const
Eff4piSymmetric(int order, const DalitzEventPattern &pat, MINT::MinuitParameterSet *pset=0)
virtual ~Eff4piSymmetric()
bool makeFitParameter(double initVal, double guessError)
MINT::MinuitParameterSet * _pset
bool setCentreAndTypicalVal()
void printCentreAndTypicalVal(std::ostream &os=std::cout) const
MINT::counted_ptr< MINT::FitParameter > _fp