#include <TGo4FitLinearTrans.h>
Inheritance diagram for TGo4FitLinearTrans:
Public Member Functions | |
TGo4FitLinearTrans () | |
TGo4FitLinearTrans (const char *iName, const char *iTitle, Int_t iAxis=0) | |
virtual | ~TGo4FitLinearTrans () |
Int_t | GetAxis () |
void | SetAxis (Int_t iAxis) |
Double_t | GetCoefK () |
void | SetCoefK (Double_t k) |
Double_t | GetCoefB () |
void | SetCoefB (Double_t b) |
void | SetCoef (Double_t iCoefK, Double_t iCoefB) |
void | SetCoefByRange (Int_t nbins, Double_t y1, Double_t y2) |
void | SetCoefByPoints (Double_t n1, Double_t y1, Double_t n2, Double_t y2) |
virtual void | Transformation (Double_t *scales, Int_t naxis) |
virtual void | Print (Option_t *option) const |
Default print method. | |
Protected Attributes | |
Int_t | fiAxis |
Double_t | fdCoefK |
Double_t | fdCoefB |
It has two coefficients to transfrom axis values like:
scale[naxis] = CoefK * scale[naxis] + CoefB
After linear transformation object is constructed, the coefficients can be defined by three ways:
SetCalibration() - just setting these coefficients;
SetCalibrationByRange() - coefficients defines from range and number of points in this range;
SetCalibrationByPoints() - coefficients calculates from coordinates of two points, where first coordinate is channel number and second - axis value.
Definition at line 36 of file TGo4FitLinearTrans.h.
TGo4FitLinearTrans::TGo4FitLinearTrans | ( | ) |
Definition at line 20 of file TGo4FitLinearTrans.cxx.
TGo4FitLinearTrans::TGo4FitLinearTrans | ( | const char * | iName, | |
const char * | iTitle, | |||
Int_t | iAxis = 0 | |||
) |
Definition at line 23 of file TGo4FitLinearTrans.cxx.
References TGo4FitParsList::AddPar(), and TGo4FitParameter::SetFixed().
TGo4FitLinearTrans::~TGo4FitLinearTrans | ( | ) | [virtual] |
Definition at line 34 of file TGo4FitLinearTrans.cxx.
Int_t TGo4FitLinearTrans::GetAxis | ( | ) | [inline] |
Definition at line 42 of file TGo4FitLinearTrans.h.
References fiAxis.
Referenced by Transformation().
void TGo4FitLinearTrans::SetAxis | ( | Int_t | iAxis | ) | [inline] |
Double_t TGo4FitLinearTrans::GetCoefK | ( | ) | [inline] |
Definition at line 44 of file TGo4FitLinearTrans.h.
References TGo4FitParsList::GetPar(), and TGo4FitParameter::GetValue().
Referenced by Transformation().
void TGo4FitLinearTrans::SetCoefK | ( | Double_t | k | ) | [inline] |
Definition at line 45 of file TGo4FitLinearTrans.h.
References TGo4FitParsList::GetPar(), and TGo4FitParameter::SetValue().
Double_t TGo4FitLinearTrans::GetCoefB | ( | ) | [inline] |
Definition at line 46 of file TGo4FitLinearTrans.h.
References TGo4FitParsList::GetPar(), and TGo4FitParameter::GetValue().
Referenced by Transformation().
void TGo4FitLinearTrans::SetCoefB | ( | Double_t | b | ) | [inline] |
Definition at line 47 of file TGo4FitLinearTrans.h.
References TGo4FitParsList::GetPar(), and TGo4FitParameter::SetValue().
void TGo4FitLinearTrans::SetCoef | ( | Double_t | iCoefK, | |
Double_t | iCoefB | |||
) | [inline] |
Definition at line 49 of file TGo4FitLinearTrans.h.
References TGo4FitParsList::GetPar(), and TGo4FitParameter::SetValue().
Referenced by SetCoefByPoints(), and SetCoefByRange().
void TGo4FitLinearTrans::SetCoefByRange | ( | Int_t | nbins, | |
Double_t | y1, | |||
Double_t | y2 | |||
) |
void TGo4FitLinearTrans::SetCoefByPoints | ( | Double_t | n1, | |
Double_t | y1, | |||
Double_t | n2, | |||
Double_t | y2 | |||
) |
void TGo4FitLinearTrans::Transformation | ( | Double_t * | scales, | |
Int_t | naxis | |||
) | [virtual] |
Implements TGo4FitAxisTrans.
Definition at line 48 of file TGo4FitLinearTrans.cxx.
References GetAxis(), GetCoefB(), and GetCoefK().
void TGo4FitLinearTrans::Print | ( | Option_t * | option | ) | const [virtual] |
Default print method.
Call print method for every parameter object in list.
Reimplemented from TGo4FitParsList.
Definition at line 53 of file TGo4FitLinearTrans.cxx.
References fiAxis, and TGo4FitParsList::Print().
Int_t TGo4FitLinearTrans::fiAxis [protected] |
Definition at line 59 of file TGo4FitLinearTrans.h.
Double_t TGo4FitLinearTrans::fdCoefK [protected] |
Double_t TGo4FitLinearTrans::fdCoefB [protected] |
Definition at line 61 of file TGo4FitLinearTrans.h.