ATLAS Offline Software
Loading...
Searching...
No Matches
ADCMTHistos.h
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2026 CERN for the benefit of the ATLAS collaboration
3*/
4
5// ADCMTHistos.h
6// Header file for class ADCMTHistos
8// (c) ATLAS Detector software
10//
12
13#ifndef ADCMTHistos_H
14#define ADCMTHistos_H
15
16// c - c++
17#include <iostream>
18#include <memory>
19
20// root
21#include "TH1.h"
22#include "TF1.h"
23class TDirectory;
24
25// this
26#include "T0MTSettings.h"
27
28namespace MuonCalib {
29
42 public:
43 //---------------------------constructor----------------------------------------
45 inline ADCMTHistos() : m_adc(NULL), m_id(-1), m_adc_ok(false), m_settings(nullptr) {}
51 inline ADCMTHistos(int id, const T0MTSettings *settings, const char *hname = NULL) :
52 m_adc(NULL), m_id(-1), m_adc_ok(false), m_settings(nullptr) {
53 Initialize(id, settings, hname);
54 }
55 //---------------------------public member functions----------------------------
61 void Initialize(int id, const T0MTSettings *settings, const char *hname = NULL);
62
64 inline TH1F *GetADCSpec() { return m_adc; }
65
70 void FillA(double a);
71
75 inline int Id() const { return m_id; }
76
78 bool FitAdc();
79
81 inline TF1 *GetAdcFunction() const { return m_adc->GetFunction("adc_fun"); }
82 inline bool AdcOk() const { return m_adc_ok; }
83
84 private:
85 //---------------------------private data members-------------------------------
87 TH1F *m_adc;
89 int m_id;
91 std::unique_ptr<TF1> m_adc_fit;
96 };
97
98} // namespace MuonCalib
99
100#endif
static Double_t a
bool m_adc_ok
is true if the adc-fit is ok;
Definition ADCMTHistos.h:93
void Initialize(int id, const T0MTSettings *settings, const char *hname=NULL)
Initialize class.
std::unique_ptr< TF1 > m_adc_fit
function which is fitted to the adc-spectrum
Definition ADCMTHistos.h:91
TF1 * GetAdcFunction() const
returnd function fitted to adc-spectrum
Definition ADCMTHistos.h:81
void FillA(double a)
fill adc value
TH1F * GetADCSpec()
get adc spectrum
Definition ADCMTHistos.h:64
TH1F * m_adc
pulse height spectrum
Definition ADCMTHistos.h:87
ADCMTHistos(int id, const T0MTSettings *settings, const char *hname=NULL)
Initializing constructor.
Definition ADCMTHistos.h:51
const T0MTSettings * m_settings
Pointer to settings class.
Definition ADCMTHistos.h:95
int Id() const
return tube id
Definition ADCMTHistos.h:75
ADCMTHistos()
Default Constructor.
Definition ADCMTHistos.h:45
Settings for the T0 calibration (histogram booking and fitting parameters) Parameters for pattern rec...
CscCalcPed - algorithm that finds the Cathode Strip Chamber pedestals from an RDO.