Jpp
|
Auxiliary data structure to store high-voltage versus gain data and interpolate the nominal high-voltage. More...
#include <JHVGainGraph.hh>
Public Member Functions | |
JHVGainGraph (const char *name="HVGainGraph", const bool logScale=false, const double base=10.0) | |
Constructor. More... | |
JHVGainGraph (const TMultiGraph &object, const bool logScale, const double base=10.0) | |
Copy constructor. More... | |
void | AddPoint (Double_t HV, Double_t gain, Double_t gainError) |
Add point to diagram. More... | |
void | SetPoint (Int_t i, Double_t HV, Double_t gain, Double_t gainError) |
Set point with index i. More... | |
const bool | checkHV (const double HV) const |
Checks whether high-voltage is within range. More... | |
const bool | checkHV (const double HV1, const double HV2) const |
Checks whether two high-voltage values are different. More... | |
const bool | checkGain (const double gain) const |
Checks if gain is within range. More... | |
const bool | areIncreasing (const Int_t i, const Int_t j) |
Checks whether the gains of two points are strictly increasing as function of their absolute high-voltage. More... | |
const bool | areValid (const Int_t i, const Int_t j) |
Checks whether two points are valid for inter-/extrapolation. More... | |
bool | interpolate (const double gainTarget) |
Inter-/Extrapolate the high-voltage value corresponding to the target gain value. More... | |
double | getTargetHV (const double gainTarget) |
Get high-voltage corresponding to given target gain value. More... | |
double | getTargetHVError (const double gainTarget) |
Get error estimate on high-voltage corresponding to given target gain value. More... | |
void | setLogLog () |
Set log-log scale. More... | |
void | unsetLogLog () |
Unset log-log scale. More... | |
void | setLogBase (const double base) |
Set logarithmic base for log-log scaling. More... | |
TGraphErrors * | getData () |
Get graph with the input data for the interpolation. More... | |
TGraphErrors * | getResult () |
Get graph with the interpolation result. More... | |
JHVGainGraph * | Clone (const char *newname="") const |
Clone this object. More... | |
Static Public Member Functions | |
static void | setMinHVDistance (const double minDist) |
Set minimal separation distance for high-voltage. More... | |
static void | setHVRange (const JRange< double > range) |
Set valid gain range. More... | |
static void | setGainRange (const JRange< double > range) |
Set valid gain range. More... | |
Private Attributes | |
bool | loglog |
Log-log scale toggle. More... | |
double | base |
Base for logarithmic scaling. More... | |
Static Private Attributes | |
static double | dHVmin = 2 * 3.14 |
Minimal high-voltage difference between two points [V]. More... | |
static JRange< double > | hvRange = JRange<double>(-1500, -80) |
Allowed high-voltage range [V]. More... | |
static JRange< double > | gainRange |
Allowed gain range. More... | |
Auxiliary data structure to store high-voltage versus gain data and interpolate the nominal high-voltage.
Definition at line 35 of file JHVGainGraph.hh.
|
inline |
Constructor.
name | name |
logScale | set logarithmic scaling |
base | base for logarithmic scaling |
Definition at line 45 of file JHVGainGraph.hh.
|
inline |
Copy constructor.
object | TMultiGraph object |
logScale | set logarithmic scale |
base | base for logarithmic scaling |
Definition at line 72 of file JHVGainGraph.hh.
|
inline |
Add point to diagram.
HV | high-voltage [V] |
gain | gain value |
gainError | error on gain value |
Definition at line 102 of file JHVGainGraph.hh.
|
inline |
Set point with index i.
i | index of point |
HV | high-voltage [V] |
gain | gain value |
gainError | error on gain value |
Definition at line 129 of file JHVGainGraph.hh.
|
inline |
Checks whether high-voltage is within range.
HV | high-voltage [V] |
Definition at line 152 of file JHVGainGraph.hh.
|
inline |
Checks whether two high-voltage values are different.
HV1 | first high-voltage [V] |
HV2 | second high-voltage [V] |
Definition at line 166 of file JHVGainGraph.hh.
|
inline |
Checks if gain is within range.
gain | gain value |
Definition at line 178 of file JHVGainGraph.hh.
|
inline |
Checks whether the gains of two points are strictly increasing as function of their absolute high-voltage.
i | index of first point |
j | index of second point |
Definition at line 193 of file JHVGainGraph.hh.
|
inline |
Checks whether two points are valid for inter-/extrapolation.
i | index of first point |
j | index of second point |
Definition at line 225 of file JHVGainGraph.hh.
|
inline |
Inter-/Extrapolate the high-voltage value corresponding to the target gain value.
gainTarget | target gain value for inter-/extrapolation |
Definition at line 265 of file JHVGainGraph.hh.
|
inline |
Get high-voltage corresponding to given target gain value.
gainTarget | target gain value for inter-/extrapolation |
Definition at line 356 of file JHVGainGraph.hh.
|
inline |
Get error estimate on high-voltage corresponding to given target gain value.
gainTarget | target gain value for inter-/extrapolation |
Definition at line 382 of file JHVGainGraph.hh.
|
inline |
Set log-log scale.
Definition at line 404 of file JHVGainGraph.hh.
|
inline |
Unset log-log scale.
Definition at line 436 of file JHVGainGraph.hh.
|
inline |
Set logarithmic base for log-log scaling.
base | logarithmic base for scaling |
Definition at line 470 of file JHVGainGraph.hh.
|
inline |
Get graph with the input data for the interpolation.
Definition at line 504 of file JHVGainGraph.hh.
|
inline |
Get graph with the interpolation result.
Definition at line 534 of file JHVGainGraph.hh.
|
inline |
Clone this object.
newname | new name |
Definition at line 564 of file JHVGainGraph.hh.
|
inlinestatic |
Set minimal separation distance for high-voltage.
minDist | minimal separation distance for high-voltage |
Definition at line 579 of file JHVGainGraph.hh.
|
inlinestatic |
Set valid gain range.
range | valid high-voltage range [V] |
Definition at line 590 of file JHVGainGraph.hh.
|
inlinestatic |
Set valid gain range.
range | valid gain range |
Definition at line 601 of file JHVGainGraph.hh.
|
private |
Log-log scale toggle.
Definition at line 609 of file JHVGainGraph.hh.
|
private |
Base for logarithmic scaling.
Definition at line 610 of file JHVGainGraph.hh.
|
staticprivate |
Minimal high-voltage difference between two points [V].
Default values.
Definition at line 612 of file JHVGainGraph.hh.
Allowed high-voltage range [V].
Definition at line 613 of file JHVGainGraph.hh.
|
staticprivate |
Allowed gain range.
Definition at line 614 of file JHVGainGraph.hh.