Definition at line 15 of file TGainMatch.h.
Public Member Functions | |
TGainMatch () | |
TGainMatch (const char *name, const char *title) | |
TGainMatch (const TGainMatch ©) | |
~TGainMatch () override=default | |
Bool_t | Align (TH1 *test, TH1 *hist, Int_t low_range=100, Int_t high_range=600) |
void | CalculateGain (Double_t cent1, Double_t cent2, Double_t eng1, Double_t eng2) |
void | Clear (Option_t *opt="") override |
Bool_t | CoarseMatch (TH1 *hist, Int_t chanNum=9999, Double_t energy1=1173.228, Double_t energy2=1332.492) |
void | Copy (TObject &obj) const override |
Bool_t | FineMatch (TH1 *energyHist, TH1 *testhist, TH1 *chargeHist, Double_t energy1, Double_t energy2, Int_t low_range=100, Int_t high_range=600, Int_t channelNum=9999) |
Bool_t | FineMatchFast (TH1 *hist1, TPeak *peak1, TH1 *hist2, TPeak *peak2, Int_t channelNum=9999) |
Bool_t | FineMatchFast (TH1 *hist, TPeak *peak1, TPeak *peak2, Int_t channelNum=9999) |
Bool_t | FineMatchFast (TH1 *hist, Double_t energy1, Double_t energy2, Int_t channelNum=9999) |
Bool_t | FineMatchFast (TH1 *hist1, Double_t energy1, TH1 *hist2, Double_t energy2, Int_t channelNum=9999) |
TChannel * | GetChannel () const |
Double_t | GetCoarseRange () const |
virtual TF1 * | GetFitFunction () const |
TH1 * | GetHist () const |
TNucleus * | GetNucleus () const override |
virtual Double_t | GetParameter (size_t parameter) const |
virtual std::vector< Double_t > | GetParameters () const |
Bool_t | IsGroupable () const override |
void | Print (Option_t *opt="") const override |
Bool_t | SetChannel (const TChannel *chan) |
Bool_t | SetChannel (UInt_t chanNum) |
void | SetCoarseRange (Double_t coarseRange) |
virtual void | SetFitFunction (const TF1 *func) |
void | SetHist (TH1 *) override |
void | SetNucleus (TNucleus *, Option_t *="") override |
virtual void | WriteToAllChannels (const std::string &mnemonic="") |
void | WriteToChannel () const override |
Static Public Member Functions | |
static Bool_t | AlignAll (TCalManager *cm, TH1 *hist, TH2 *mat, Int_t low_range=100, Int_t high_range=600) |
static Bool_t | CoarseMatchAll (TCalManager *cm, TH2 *mat, Double_t energy1=1173.228, Double_t energy2=1332.492) |
static Bool_t | FineMatchAll (TCalManager *cm, TH2 *charge_mat, TH2 *eng_mat, Int_t testchan, Double_t energy1, Double_t energy2, Int_t low_range=100, Int_t high_range=600) |
static Bool_t | FineMatchFastAll (TCalManager *cm, TH2 *mat, Double_t energy1, Double_t energy2) |
static Bool_t | FineMatchFastAll (TCalManager *cm, TH2 *mat1, Double_t energy1, TH2 *mat2, Double_t energy2) |
static Bool_t | FineMatchFastAll (TCalManager *cm, TH2 *mat1, TPeak *peak1, TH2 *mat2, TPeak *peak2) |
static Bool_t | FineMatchFastAll (TCalManager *cm, TH2 *mat, TPeak *peak1, TPeak *peak2) |
static Double_t | GetDefaultCoarseRange () |
static void | SetDefaultCoarseRange (Double_t coarseRange) |
Protected Member Functions | |
void | InitTCal () |
Private Member Functions | |
Double_t | HistCompare (Double_t *x, Double_t *par) |
Private Attributes | |
Double_t | fAlignCoeffs [2] {0.} |
Bool_t | fAligned {false} |
Bool_t | fCoarseMatch {false} |
Double_t | fCoarseRange |
Double_t | fGainCoeffs [2] {0.} |
TH1 * | fHist {nullptr} |
Static Private Attributes | |
static Double_t | gDefaultCoarseRange = 40. |
#include <TGainMatch.h>
|
inline |
Definition at line 17 of file TGainMatch.h.
Referenced by AlignAll(), CoarseMatchAll(), FineMatchAll(), and FineMatchFastAll().
|
inline |
Definition at line 18 of file TGainMatch.h.
References Clear().
|
overridedefault |
TGainMatch::TGainMatch | ( | const TGainMatch & | copy | ) |
Definition at line 18 of file TGainMatch.cxx.
References Copy(), fCoarseRange, and fHist.
Bool_t TGainMatch::Align | ( | TH1 * | test, |
TH1 * | hist, | ||
Int_t | low_range = 100 , |
||
Int_t | high_range = 600 |
||
) |
Definition at line 511 of file TGainMatch.cxx.
References fAlignCoeffs, fAligned, fHist, hist, and HistCompare().
Referenced by FineMatch().
|
static |
Definition at line 576 of file TGainMatch.cxx.
References TCalManager::AddToManager(), hist, mat, and TGainMatch().
void TGainMatch::CalculateGain | ( | Double_t | cent1, |
Double_t | cent2, | ||
Double_t | eng1, | ||
Double_t | eng2 | ||
) |
Definition at line 32 of file TGainMatch.cxx.
References fGainCoeffs, and TCal::SetFitFunction().
|
override |
Definition at line 500 of file TGainMatch.cxx.
References TCal::Clear(), fAlignCoeffs, fAligned, fCoarseMatch, and fGainCoeffs.
Referenced by TGainMatch().
Bool_t TGainMatch::CoarseMatch | ( | TH1 * | hist, |
Int_t | chanNum = 9999 , |
||
Double_t | energy1 = 1173.228 , |
||
Double_t | energy2 = 1332.492 |
||
) |
Definition at line 54 of file TGainMatch.cxx.
References fCoarseMatch, fCoarseRange, fGainCoeffs, fHist, TPeak::Fit(), TChannel::GetChannelByNumber(), hist, s, TCal::SetChannel(), and TCal::SetFitFunction().
|
static |
Definition at line 362 of file TGainMatch.cxx.
References TCalManager::AddToManager(), mat, and TGainMatch().
|
override |
Definition at line 25 of file TGainMatch.cxx.
References TCal::Copy(), fCoarseMatch, and fCoarseRange.
Referenced by TGainMatch().
Bool_t TGainMatch::FineMatch | ( | TH1 * | energyHist, |
TH1 * | testhist, | ||
TH1 * | chargeHist, | ||
Double_t | energy1, | ||
Double_t | energy2, | ||
Int_t | low_range = 100 , |
||
Int_t | high_range = 600 , |
||
Int_t | channelNum = 9999 |
||
) |
Definition at line 687 of file TGainMatch.cxx.
References Align(), fAlignCoeffs, fCoarseMatch, fGainCoeffs, TChannel::GetChannelByNumber(), TChannel::GetENGCoeff(), TCal::GetFitFunction(), TCal::GetParameter(), s, TCal::SetChannel(), and TCal::SetFitFunction().
|
static |
Definition at line 625 of file TGainMatch.cxx.
References TCalManager::AddToManager(), and TGainMatch().
Bool_t TGainMatch::FineMatchFast | ( | TH1 * | hist1, |
TPeak * | peak1, | ||
TH1 * | hist2, | ||
TPeak * | peak2, | ||
Int_t | channelNum = 9999 |
||
) |
Definition at line 152 of file TGainMatch.cxx.
References fCoarseMatch, fGainCoeffs, TPeak::Fit(), TPeak::GetCentroid(), TChannel::GetChannelByNumber(), TChannel::GetENGCoeff(), TCal::GetFitFunction(), TCal::GetParameter(), s, TCal::SetChannel(), and TCal::SetFitFunction().
Referenced by FineMatchFast().
Bool_t TGainMatch::FineMatchFast | ( | TH1 * | hist, |
TPeak * | peak1, | ||
TPeak * | peak2, | ||
Int_t | channelNum = 9999 |
||
) |
Definition at line 293 of file TGainMatch.cxx.
References FineMatchFast(), and hist.
Bool_t TGainMatch::FineMatchFast | ( | TH1 * | hist, |
Double_t | energy1, | ||
Double_t | energy2, | ||
Int_t | channelNum = 9999 |
||
) |
Definition at line 301 of file TGainMatch.cxx.
References FineMatchFast(), and hist.
Bool_t TGainMatch::FineMatchFast | ( | TH1 * | hist1, |
Double_t | energy1, | ||
TH1 * | hist2, | ||
Double_t | energy2, | ||
Int_t | channelNum = 9999 |
||
) |
Definition at line 308 of file TGainMatch.cxx.
References FineMatchFast().
|
static |
|
static |
Definition at line 409 of file TGainMatch.cxx.
References FineMatchFastAll().
|
static |
Definition at line 429 of file TGainMatch.cxx.
References TCalManager::AddToManager(), and TGainMatch().
|
static |
Definition at line 495 of file TGainMatch.cxx.
References FineMatchFastAll(), and mat.
|
inherited |
Gets the channel being pointed to by the TCal. Returns 0 if no channel is set.
Definition at line 130 of file TCal.cxx.
References TCal::fChan.
Referenced by TCalManager::AddToManager(), TTimeCal::Print(), TCFDCal::Print(), TCal::Print(), TTimeCal::ReadFromChannel(), TCFDCal::ReadFromChannel(), TCal::WriteToAllChannels(), TCFDCal::WriteToChannel(), TTimeCal::WriteToChannel(), TEnergyCal::WriteToChannel(), and WriteToChannel().
|
inline |
Definition at line 71 of file TGainMatch.h.
References fCoarseRange.
|
inlinestatic |
Definition at line 77 of file TGainMatch.h.
References gDefaultCoarseRange.
|
inlinevirtualinherited |
Definition at line 58 of file TCal.h.
References TCal::fFitFunc.
Referenced by FineMatch(), FineMatchFast(), TCal::GetParameter(), TCal::GetParameters(), and main().
|
inline |
Definition at line 64 of file TGainMatch.h.
|
inlineoverridevirtual |
Reimplemented from TCal.
Definition at line 57 of file TGainMatch.h.
|
virtualinherited |
Returns the parameter at the index parameter
Reimplemented in TEnergyCal, TCFDCal, and TTimeCal.
Definition at line 108 of file TCal.cxx.
References TCal::GetFitFunction().
Referenced by FineMatch(), FineMatchFast(), TCal::GetParameters(), and WriteToChannel().
|
virtualinherited |
Returns all of the parameters in the current TCal.
Reimplemented in TEnergyCal, TCFDCal, and TTimeCal.
Definition at line 90 of file TCal.cxx.
References TCal::GetFitFunction(), and TCal::GetParameter().
|
private |
|
protectedinherited |
Initiallizes the TCal.
Definition at line 179 of file TCal.cxx.
References TCal::Clear(), TCal::fChan, TCal::fFitFunc, TCal::fHist, and TCal::fNuc.
Referenced by TCal::TCal().
|
inlineoverridevirtual |
Implements TCal.
Definition at line 53 of file TGainMatch.h.
|
override |
Definition at line 340 of file TGainMatch.cxx.
References fAlignCoeffs, fAligned, fCoarseMatch, fGainCoeffs, and TCal::Print().
|
inherited |
Sets the channel being calibrated
Definition at line 60 of file TCal.cxx.
References TCal::fChan.
Referenced by TCalManager::AddToManager(), CoarseMatch(), FineMatch(), FineMatchFast(), main(), TCal::SetChannel(), and TCal::WriteToAllChannels().
|
inherited |
Sets the channel for the calibration to the channel number channum. Returns 0 if the channel does not exist
Definition at line 118 of file TCal.cxx.
References TChannel::GetChannelByNumber(), and TCal::SetChannel().
|
inline |
Definition at line 70 of file TGainMatch.h.
References fCoarseRange.
|
inlinestatic |
Definition at line 72 of file TGainMatch.h.
References gDefaultCoarseRange.
|
inlinevirtualinherited |
Definition at line 59 of file TCal.h.
References TCal::fFitFunc.
Referenced by CalculateGain(), CoarseMatch(), FineMatch(), FineMatchFast(), and main().
|
inlineoverridevirtual |
Reimplemented from TCal.
Definition at line 63 of file TGainMatch.h.
|
inlineoverridevirtual |
Reimplemented from TCal.
Definition at line 56 of file TGainMatch.h.
|
virtualinherited |
Writes this calibration to all channels in the current TChannel Map
Definition at line 72 of file TCal.cxx.
References TCal::GetChannel(), TChannel::GetChannelMap(), TCal::SetChannel(), and TCal::WriteToChannel().
|
overridevirtual |
Reimplemented from TCal.
Definition at line 326 of file TGainMatch.cxx.
References TChannel::AddENGCoefficient(), TChannel::DestroyENGCal(), TCal::GetChannel(), TChannel::GetNumber(), and TCal::GetParameter().
Referenced by main().
|
private |
Definition at line 83 of file TGainMatch.h.
Referenced by Align(), Clear(), FineMatch(), and Print().
|
private |
Definition at line 81 of file TGainMatch.h.
|
private |
Definition at line 80 of file TGainMatch.h.
Referenced by Clear(), CoarseMatch(), Copy(), FineMatch(), FineMatchFast(), and Print().
|
private |
Definition at line 85 of file TGainMatch.h.
Referenced by CoarseMatch(), Copy(), GetCoarseRange(), SetCoarseRange(), and TGainMatch().
|
private |
Definition at line 84 of file TGainMatch.h.
Referenced by CalculateGain(), Clear(), CoarseMatch(), FineMatch(), FineMatchFast(), and Print().
|
private |
Definition at line 82 of file TGainMatch.h.
Referenced by Align(), CoarseMatch(), HistCompare(), and TGainMatch().
|
staticprivate |
Definition at line 88 of file TGainMatch.h.
Referenced by GetDefaultCoarseRange(), and SetDefaultCoarseRange().