-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathParameterLimit.h
38 lines (30 loc) · 991 Bytes
/
ParameterLimit.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
#ifndef PARAMETERLIMIT_H
#define PARAMETERLIMIT_H
#include "CalibData.h"
class Parameters;
//! \brief Data class to limit a parameter
class ParameterLimit : public Event
{
public:
ParameterLimit(unsigned short int index, Parameters* parameters, double min, double max, double error = 1.0)
: Event(1.0,0.0), index_(index), min_(min), max_(max),
error2_(error*error), par_(parameters)
{
}
double chi2() const;
double chi2_fast(double* temp_derivative1, double* temp_derivative2,
double * temp_derivative3, double * temp_derivative4,
const double* epsilon) const;
Measurement *mess() const { return 0;}
double truth() const { return 0;}
double parametrizedMess() const { return 0;}
void setParameters(Parameters* param);
DataType type() const { return ParLimit;}
double chi2_plots() const { return chi2();}
void updateError() {}
private:
unsigned short int index_;
double min_, max_, error2_;
Parameters* par_;
};
#endif