a Code for the Combination of Indirect and Direct Constraints on High Energy Physics Models Logo
ModelParameter.h
Go to the documentation of this file.
1/*
2 * Copyright (C) 2012 HEPfit Collaboration
3 *
4 *
5 * For the licensing terms see doc/COPYING.
6 */
7
8#ifndef MODELPARAMETER_H
9#define MODELPARAMETER_H
10
11#include <string>
12#include <iostream>
13#include <boost/tokenizer.hpp>
14
29public:
30
38 ModelParameter(std::string name_in, double ave_in, double errg_in, double errf_in);
39
44
49 boost::tokenizer<boost::char_separator<char> >::iterator & ParseModelParameter(boost::tokenizer<boost::char_separator<char> >::iterator & beg);
50
54 virtual ~ModelParameter();
55
60 bool IsCorrelated() const
61 {
62 return(!cgp_name.empty());
63 }
64
69 std::string getname() const
70 {
71 return name;
72 }
73
78 double getave() const
79 {
80 return ave;
81 }
82
87 double geterrf() const
88 {
89 return errf;
90 }
91
96 double geterrg() const
97 {
98 return errg;
99 }
100
105 double getmin() const
106 {
107 return min;
108 }
109
114 double getmax() const
115 {
116 return max;
117 }
118
123 bool IsFixed() const
124 {
125 return isFixed;
126 }
127
132 std::string getCgp_name() const
133 {
134 return cgp_name;
135 }
136
140 void setCgp_name(std::string cgp_name)
141 {
142 this->cgp_name = cgp_name;
143 }
144
151 friend std::ostream& operator<<(std::ostream& output, const ModelParameter& m);
152
153private:
154 std::string name;
155 double ave;
156 double errg;
157 double errf;
158 double min;
159 double max;
160 bool isFixed;
161 std::string cgp_name;
162};
163
164#endif /* MODELPARAMETER_H */
165
A class for model parameters.
boost::tokenizer< boost::char_separator< char > >::iterator & ParseModelParameter(boost::tokenizer< boost::char_separator< char > >::iterator &beg)
Parser for model parameters.
bool isFixed
A boolean flag that is true if the parameter is fixed.
void setCgp_name(std::string cgp_name)
A set method to set the name of the set of correlated parameter.
std::string getname() const
A get method to get the name of each parameter.
double errg
The Gaussian error of the model parameter.
double ave
The average value of the model parameter.
std::string getCgp_name() const
A get method to get the name of the set of correlated parameter.
bool IsFixed() const
A method to check if the parameter is fixed.
double geterrg() const
A get method to get the gaussian error.
std::string cgp_name
ModelParameter()
Constructor.
std::string name
The name of the model parameter.
bool IsCorrelated() const
A method to check if the parameters are correlated or not.
double max
The maximum value of the model parameter.
double min
The minimum value of the model parameter.
double geterrf() const
A get method to get the flat error.
double getmin() const
A get method to get the minimum value.
friend std::ostream & operator<<(std::ostream &output, const ModelParameter &m)
Befriending of the std::ostream operator << to generate an output stream for printing the model param...
double getmax() const
A get method to get the maximum value.
double getave() const
A get method to get the average.
virtual ~ModelParameter()
The default destructor.
double errf
The flat error of the model parameter.