laura is hosted by Hepforge, IPPP Durham
Laura++  v2r2p1
A maximum likelihood fitting package for performing Dalitz-plot analysis.
LauFormulaPar.hh
Go to the documentation of this file.
1 
2 // Copyright University of Warwick 2013 - 2014.
3 // Distributed under the Boost Software License, Version 1.0.
4 // (See accompanying file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
5 
6 // Authors:
7 // Thomas Latham
8 // John Back
9 // Paul Harrison
10 
23 #ifndef LAU_FORMULAPAR
24 #define LAU_FORMULAPAR
25 
26 #include <map>
27 #include <vector>
28 
29 #include "TString.h"
30 #include "TFormula.h"
31 #include "LauAbsRValue.hh"
32 #include "LauParameter.hh"
33 
34 
35 class LauFormulaPar : public LauAbsRValue {
36 
37  public:
39 
44  LauFormulaPar(const TString& forName, const TString& formula, const std::vector<LauParameter*>& params);
45 
46  // Destructor
47  virtual ~LauFormulaPar();
48 
50 
53  Double_t value() const;
54 
56 
59  inline const TString& name() const {return name_;}
60 
62 
65  std::vector<LauParameter*> getPars() {return paramVec_;}
66 
68 
71  inline Bool_t isLValue() const {return kFALSE;}
72 
74 
77  Bool_t fixed() const;
78 
80 
83  inline Bool_t gaussConstraint() const {return gaussConstraint_;}
84 
86 
89  inline Double_t constraintMean() const {return constraintMean_;}
90 
92 
95  inline Double_t constraintWidth() const {return constraintWidth_;}
96 
98 
102  void addGaussianConstraint(Double_t newGaussMean, Double_t newGaussWidth);
103 
106 
107 
108  protected:
109 
110  private:
112  TString name_;
113 
115  mutable TFormula formula_;
116 
118  std::vector<LauParameter*> paramVec_;
119 
121  Double_t* dummy_;
123  Double_t* paramArray_;
124 
128  Double_t constraintMean_;
131 
132  ClassDef(LauFormulaPar, 0)
133 
134 };
135 
136 #endif
Double_t constraintMean() const
The mean of the Gaussian constraint.
Class for defining combinations of fit parameter objects.
virtual ~LauFormulaPar()
const TString & name() const
The parameter name.
std::vector< LauParameter * > paramVec_
Vector of LauParameters in the formula.
LauFormulaPar(const TString &forName, const TString &formula, const std::vector< LauParameter * > &params)
Constructor.
Bool_t fixed() const
Boolean to say if the LauFormulaPar is fixed.
Bool_t gaussConstraint() const
Check whether a Gaussian constraints is applied.
TString name_
The parameter name.
TFormula formula_
The formula.
void addGaussianConstraint(Double_t newGaussMean, Double_t newGaussWidth)
Add a Gaussian constraint (or modify an existing one)
Double_t * dummy_
Array.
File containing declaration of LauAbsRValue class.
File containing declaration of LauParameter class.
Double_t constraintMean_
Mean value of the Gaussian constraint.
Double_t * paramArray_
Array.
std::vector< LauParameter * > getPars()
Get the LauParameters used in LauFormulaPar.
Double_t constraintWidth_
Width of the Gaussian constraint.
Bool_t gaussConstraint_
Choice to use Gaussian constraint.
Bool_t isLValue() const
Boolean to say it is not an L value.
void removeGaussianConstraint()
Remove the Gaussian constraint.
Double_t constraintWidth() const
The width of the Gaussian constraint.
Pure abstract base class for defining a parameter containing an R value.
Definition: LauAbsRValue.hh:29
Double_t value() const
Return the value of the LauFormalaPar.