GRSISort
Created by P.C. Bender
Developement Team: P.C. Bender, R. Dunlop, V. Bildstein
An extension of the ROOT analysis Framework
TCalibrateDescant Class Reference

This class implements a GUI to fit and calibrate DESCANT.

Definition at line 66 of file TCalibrateDescant.h.

Public Types

enum  EParameter {
  kAmplitude = 0, kPosition = 3, kSigma = 6, kDSigma = 9,
  kPeakAmp = 12, kPeakPos = 15, kPeakSigma = 18, kNoiseAmp = 21,
  kNoisePos = 24, kNoiseSigma = 27, kThreshold = 30, kThresholdSigma = 33,
  kBgConst = 36, kBgAmp = 39, kBgDecayConst = 42, kCutoff = 45
}
 
enum  ESourceType {
  ESourceType::k22NaLow, ESourceType::k22NaHigh, ESourceType::k24NaLow, ESourceType::k24NaHigh,
  ESourceType::k60Co, ESourceType::k137Cs, ESourceType::k152Eu121, ESourceType::k152Eu344,
  ESourceType::k152Eu1408, ESourceType::k241AmEdge, ESourceType::k241Am
}
 

Public Member Functions

 TCalibrateDescant (TH2 *hist, const ESourceType &source=ESourceType::k137Cs)
 
void CalibrationCanvasZoomed ()
 
void Fit ()
 
void FitCanvasZoomed ()
 
void Next ()
 
void Previous ()
 
Bool_t ProcessMessage (Long_t msg, Long_t parameter1, Long_t parameter2) override
 
void ResetFit ()
 
void Save ()
 
void Status (Int_t px, Int_t py, Int_t pz, TObject *selected)
 
void UpdateInitialFunction ()
 
void UpdateInitialParameters ()
 

Private Member Functions

void AddCalibrationPoint (double value, double uncertainty)
 
void BuildInterface ()
 
void CreateGraphicMembers ()
 
void InitializeParameters ()
 
void MakeConnections ()
 
void UpdateInterface ()
 

Private Attributes

TParameterInputfAmplitude {nullptr}
 
TF1 * fBg {nullptr}
 
TParameterInputfBgAmp {nullptr}
 
TParameterInputfBgConst {nullptr}
 
TParameterInputfBgDecayConst {nullptr}
 
TGHorizontalFrame * fBottomButtonFrame {nullptr}
 
TRootEmbeddedCanvas * fCalibrationCanvas {nullptr}
 
std::vector< TGraphErrors * > fCalibrations
 
int fCurrentProjection {0}
 
TParameterInputfCutoff {nullptr}
 
TParameterInputfDSigma {nullptr}
 
TF1 * fEdge {nullptr}
 
TF1 * fFit {nullptr}
 
TGTextButton * fFitButton {nullptr}
 
TRootEmbeddedCanvas * fFitCanvas {nullptr}
 
TF1 * fInitial {nullptr}
 
TGVerticalFrame * fLeftFrame {nullptr}
 
TH2 * fMatrix {nullptr}
 
TGTextButton * fNextButton {nullptr}
 
TF1 * fNoise {nullptr}
 
TParameterInputfNoiseAmp {nullptr}
 
TParameterInputfNoisePos {nullptr}
 
TParameterInputfNoiseSigma {nullptr}
 
TF1 * fPeak {nullptr}
 
TParameterInputfPeakAmp {nullptr}
 
TParameterInputfPeakPos {nullptr}
 
TParameterInputfPeakSigma {nullptr}
 
TParameterInputfPosition {nullptr}
 
TGTextButton * fPreviousButton {nullptr}
 
std::vector< TH1D * > fProjections
 
TGTextButton * fResetFitButton {nullptr}
 
TGVerticalFrame * fRightFrame {nullptr}
 
TGTextButton * fSaveButton {nullptr}
 
TParameterInputfSigma {nullptr}
 
ESourceType fSource {ESourceType::k137Cs}
 
TGStatusBar * fStatusBar {nullptr}
 
TParameterInputfThreshold {nullptr}
 
TParameterInputfThresholdSigma {nullptr}
 
TGHorizontalFrame * fTopButtonFrame {nullptr}
 
TGTextButton * fUpdateInitialButton {nullptr}
 

#include <TCalibrateDescant.h>

+ Inheritance diagram for TCalibrateDescant:
+ Collaboration diagram for TCalibrateDescant:

Member Enumeration Documentation

◆ EParameter

Enumerator
kAmplitude 
kPosition 
kSigma 
kDSigma 
kPeakAmp 
kPeakPos 
kPeakSigma 
kNoiseAmp 
kNoisePos 
kNoiseSigma 
kThreshold 
kThresholdSigma 
kBgConst 
kBgAmp 
kBgDecayConst 
kCutoff 

Definition at line 69 of file TCalibrateDescant.h.

◆ ESourceType

Enumerator
k22NaLow 
k22NaHigh 
k24NaLow 
k24NaHigh 
k60Co 
k137Cs 
k152Eu121 
k152Eu344 
k152Eu1408 
k241AmEdge 
k241Am 

Definition at line 68 of file TCalibrateDescant.h.

Constructor & Destructor Documentation

◆ TCalibrateDescant()

TCalibrateDescant::TCalibrateDescant ( TH2 *  hist,
const ESourceType source = ESourceType::k137Cs 
)

Member Function Documentation

◆ AddCalibrationPoint()

void TCalibrateDescant::AddCalibrationPoint ( double  value,
double  uncertainty 
)
private

Definition at line 743 of file TCalibrateDescant.cxx.

References fCalibrations, fCurrentProjection, fSource, SourceEnergy(), and SourceEnergyUncertainty().

Referenced by Fit().

◆ BuildInterface()

◆ CalibrationCanvasZoomed()

void TCalibrateDescant::CalibrationCanvasZoomed ( )

Definition at line 780 of file TCalibrateDescant.cxx.

◆ CreateGraphicMembers()

void TCalibrateDescant::CreateGraphicMembers ( )
private

Definition at line 386 of file TCalibrateDescant.cxx.

References fBg, fCalibrations, fEdge, fFit, fInitial, fMatrix, fNoise, fPeak, fProjections, and FullEdge().

Referenced by TCalibrateDescant().

◆ Fit()

◆ FitCanvasZoomed()

void TCalibrateDescant::FitCanvasZoomed ( )

Definition at line 760 of file TCalibrateDescant.cxx.

References fBg, fEdge, fFit, fFitCanvas, fInitial, fNoise, and fPeak.

◆ InitializeParameters()

void TCalibrateDescant::InitializeParameters ( )
private

◆ MakeConnections()

◆ Next()

void TCalibrateDescant::Next ( )

Definition at line 575 of file TCalibrateDescant.cxx.

References fCurrentProjection, fProjections, and UpdateInterface().

◆ Previous()

void TCalibrateDescant::Previous ( )

Definition at line 568 of file TCalibrateDescant.cxx.

References fCurrentProjection, and UpdateInterface().

◆ ProcessMessage()

Bool_t TCalibrateDescant::ProcessMessage ( Long_t  msg,
Long_t  parameter1,
Long_t  parameter2 
)
override

This functions deals with changes in the text fields of the TGNumberEntry as those don't seem to emit signals?

Definition at line 362 of file TCalibrateDescant.cxx.

References UpdateInitialFunction().

◆ ResetFit()

void TCalibrateDescant::ResetFit ( )

Definition at line 728 of file TCalibrateDescant.cxx.

References fFit, fFitCanvas, and fInitial.

◆ Save()

void TCalibrateDescant::Save ( )

Definition at line 738 of file TCalibrateDescant.cxx.

◆ Status()

void TCalibrateDescant::Status ( Int_t  px,
Int_t  py,
Int_t  pz,
TObject *  selected 
)

Definition at line 786 of file TCalibrateDescant.cxx.

References fStatusBar.

◆ UpdateInitialFunction()

◆ UpdateInitialParameters()

void TCalibrateDescant::UpdateInitialParameters ( )

◆ UpdateInterface()

void TCalibrateDescant::UpdateInterface ( )
private

Member Data Documentation

◆ fAmplitude

TParameterInput* TCalibrateDescant::fAmplitude {nullptr}
private

◆ fBg

TF1* TCalibrateDescant::fBg {nullptr}
private

Definition at line 103 of file TCalibrateDescant.h.

Referenced by CreateGraphicMembers(), Fit(), and FitCanvasZoomed().

◆ fBgAmp

TParameterInput* TCalibrateDescant::fBgAmp {nullptr}
private

◆ fBgConst

TParameterInput* TCalibrateDescant::fBgConst {nullptr}
private

◆ fBgDecayConst

TParameterInput* TCalibrateDescant::fBgDecayConst {nullptr}
private

◆ fBottomButtonFrame

TGHorizontalFrame* TCalibrateDescant::fBottomButtonFrame {nullptr}
private

Definition at line 132 of file TCalibrateDescant.h.

Referenced by BuildInterface().

◆ fCalibrationCanvas

TRootEmbeddedCanvas* TCalibrateDescant::fCalibrationCanvas {nullptr}
private

Definition at line 111 of file TCalibrateDescant.h.

Referenced by BuildInterface(), Fit(), MakeConnections(), and UpdateInterface().

◆ fCalibrations

std::vector<TGraphErrors*> TCalibrateDescant::fCalibrations
private

Definition at line 97 of file TCalibrateDescant.h.

Referenced by AddCalibrationPoint(), CreateGraphicMembers(), and UpdateInterface().

◆ fCurrentProjection

int TCalibrateDescant::fCurrentProjection {0}
private

◆ fCutoff

TParameterInput* TCalibrateDescant::fCutoff {nullptr}
private

◆ fDSigma

TParameterInput* TCalibrateDescant::fDSigma {nullptr}
private

◆ fEdge

TF1* TCalibrateDescant::fEdge {nullptr}
private

Definition at line 100 of file TCalibrateDescant.h.

Referenced by CreateGraphicMembers(), Fit(), and FitCanvasZoomed().

◆ fFit

TF1* TCalibrateDescant::fFit {nullptr}
private

◆ fFitButton

TGTextButton* TCalibrateDescant::fFitButton {nullptr}
private

Definition at line 135 of file TCalibrateDescant.h.

Referenced by BuildInterface(), and MakeConnections().

◆ fFitCanvas

TRootEmbeddedCanvas* TCalibrateDescant::fFitCanvas {nullptr}
private

◆ fInitial

TF1* TCalibrateDescant::fInitial {nullptr}
private

◆ fLeftFrame

TGVerticalFrame* TCalibrateDescant::fLeftFrame {nullptr}
private

Definition at line 107 of file TCalibrateDescant.h.

Referenced by BuildInterface().

◆ fMatrix

TH2* TCalibrateDescant::fMatrix {nullptr}
private

Definition at line 94 of file TCalibrateDescant.h.

Referenced by CreateGraphicMembers().

◆ fNextButton

TGTextButton* TCalibrateDescant::fNextButton {nullptr}
private

Definition at line 136 of file TCalibrateDescant.h.

Referenced by BuildInterface(), and MakeConnections().

◆ fNoise

TF1* TCalibrateDescant::fNoise {nullptr}
private

Definition at line 102 of file TCalibrateDescant.h.

Referenced by CreateGraphicMembers(), Fit(), and FitCanvasZoomed().

◆ fNoiseAmp

TParameterInput* TCalibrateDescant::fNoiseAmp {nullptr}
private

◆ fNoisePos

TParameterInput* TCalibrateDescant::fNoisePos {nullptr}
private

◆ fNoiseSigma

TParameterInput* TCalibrateDescant::fNoiseSigma {nullptr}
private

◆ fPeak

TF1* TCalibrateDescant::fPeak {nullptr}
private

Definition at line 101 of file TCalibrateDescant.h.

Referenced by CreateGraphicMembers(), Fit(), and FitCanvasZoomed().

◆ fPeakAmp

TParameterInput* TCalibrateDescant::fPeakAmp {nullptr}
private

◆ fPeakPos

TParameterInput* TCalibrateDescant::fPeakPos {nullptr}
private

◆ fPeakSigma

TParameterInput* TCalibrateDescant::fPeakSigma {nullptr}
private

◆ fPosition

TParameterInput* TCalibrateDescant::fPosition {nullptr}
private

◆ fPreviousButton

TGTextButton* TCalibrateDescant::fPreviousButton {nullptr}
private

Definition at line 134 of file TCalibrateDescant.h.

Referenced by BuildInterface(), and MakeConnections().

◆ fProjections

std::vector<TH1D*> TCalibrateDescant::fProjections
private

◆ fResetFitButton

TGTextButton* TCalibrateDescant::fResetFitButton {nullptr}
private

Definition at line 137 of file TCalibrateDescant.h.

Referenced by BuildInterface(), and MakeConnections().

◆ fRightFrame

TGVerticalFrame* TCalibrateDescant::fRightFrame {nullptr}
private

Definition at line 108 of file TCalibrateDescant.h.

Referenced by BuildInterface().

◆ fSaveButton

TGTextButton* TCalibrateDescant::fSaveButton {nullptr}
private

Definition at line 139 of file TCalibrateDescant.h.

Referenced by BuildInterface(), and MakeConnections().

◆ fSigma

TParameterInput* TCalibrateDescant::fSigma {nullptr}
private

◆ fSource

ESourceType TCalibrateDescant::fSource {ESourceType::k137Cs}
private

Definition at line 105 of file TCalibrateDescant.h.

Referenced by AddCalibrationPoint().

◆ fStatusBar

TGStatusBar* TCalibrateDescant::fStatusBar {nullptr}
private

Definition at line 112 of file TCalibrateDescant.h.

Referenced by BuildInterface(), and Status().

◆ fThreshold

TParameterInput* TCalibrateDescant::fThreshold {nullptr}
private

◆ fThresholdSigma

TParameterInput* TCalibrateDescant::fThresholdSigma {nullptr}
private

◆ fTopButtonFrame

TGHorizontalFrame* TCalibrateDescant::fTopButtonFrame {nullptr}
private

Definition at line 131 of file TCalibrateDescant.h.

Referenced by BuildInterface().

◆ fUpdateInitialButton

TGTextButton* TCalibrateDescant::fUpdateInitialButton {nullptr}
private

Definition at line 138 of file TCalibrateDescant.h.

Referenced by BuildInterface(), and MakeConnections().