R3BROOT
R3B analysis software
Loading...
Searching...
No Matches
R3BNeulandMapped2Cal.h
Go to the documentation of this file.
1/******************************************************************************
2 * Copyright (C) 2019 GSI Helmholtzzentrum für Schwerionenforschung GmbH *
3 * Copyright (C) 2019-2025 Members of R3B Collaboration *
4 * *
5 * This software is distributed under the terms of the *
6 * GNU General Public Licence (GPL) version 3, *
7 * copied verbatim in the file "LICENSE". *
8 * *
9 * In applying this license GSI does not waive the privileges and immunities *
10 * granted to it by virtue of its status as an Intergovernmental Organization *
11 * or submit itself to any jurisdiction. *
12 ******************************************************************************/
13
14#ifndef R3BNEULANDMAPPED2CAL_H
15#define R3BNEULANDMAPPED2CAL_H
16
17#include "FairTask.h"
18#include "TH2F.h"
19
20class TClonesArray;
21class R3BTCalModulePar;
22class R3BTCalPar;
23class R3BEventHeader;
25
35class R3BNeulandMapped2Cal : public FairTask
36{
37
38 public:
44
51 R3BNeulandMapped2Cal(const char* name, Int_t iVerbose = 1);
52
57 virtual ~R3BNeulandMapped2Cal();
58
65 virtual InitStatus Init();
66
71 virtual void SetParContainers();
72
77 virtual InitStatus ReInit();
78
84 virtual void Exec(Option_t* option);
85
91 virtual void FinishEvent();
92
97 virtual void FinishTask();
98
103 inline void SetTrigger(Int_t trigger) { fTrigger = trigger; }
104
110 inline void SetNofModules(Int_t nPlanes, Int_t nBars)
111 {
112 fNofPlanes = nPlanes;
113 fNofBarsPerPlane = nBars;
114 fNofPMTs = nPlanes * nBars * 2;
115 }
116
121 inline void SetPulserMode(Bool_t mode = kTRUE) { fPulserMode = mode; }
122
127 inline void EnableWalk(Bool_t walk = kTRUE) { fWalkEnabled = walk; }
128
129 inline void SetNhitmin(Int_t nhitmin = 1) { fNhitmin = nhitmin; }
130
131 private:
132 void SetParameter();
133
134 Int_t fNEvents;
135 Bool_t fPulserMode;
136 Bool_t fWalkEnabled;
137
138 TClonesArray* fMapped;
139 TClonesArray* fMappedTrigger;
140 TClonesArray* fCal;
141 Int_t fNPmt;
142
143 R3BNeulandMappingPar* fMapPar;
144
145 R3BTCalPar* fTcalPar;
146 UInt_t fNofTcalPars;
147
148 R3BEventHeader* header;
149 Int_t fTrigger;
150
151 Int_t fNofPlanes;
152 Int_t fNofBarsPerPlane;
153 Int_t fNofPMTs;
154
155 Double_t fClockFreq;
156
157 void MakeCal();
158
159 Double_t WalkCorrection(Double_t);
160
161 TH2F* htcal1;
162 TH2F* htcal2;
163 TH2F* htcal3;
164 TH2F* htcal4;
165
166 Int_t fNhitmin;
167
168 public:
169 ClassDef(R3BNeulandMapped2Cal, 1)
170};
171
172#endif
Double_t walk(Double_t x)
An analysis task to apply TCAL calibration for NeuLAND.
virtual InitStatus ReInit()
Method for re-initialization of parameter containers in case the Run ID has changed.
virtual void FinishTask()
Method for finish of the task execution.
virtual void SetParContainers()
Method for initialization of the parameter containers.
virtual void FinishEvent()
A method for finish of processing of an event.
void SetNofModules(Int_t nPlanes, Int_t nBars)
Method for setting the number of NeuLAND modules.
void EnableWalk(Bool_t walk=kTRUE)
Method to enable / disable walk corrections.
void SetPulserMode(Bool_t mode=kTRUE)
Method to set running mode for pulser data analysis.
void SetNhitmin(Int_t nhitmin=1)
R3BNeulandMapped2Cal()
Default constructor.
virtual InitStatus Init()
Method for task initialization.
virtual ~R3BNeulandMapped2Cal()
Destructor.
virtual void Exec(Option_t *option)
Method for event loop implementation.
void SetTrigger(Int_t trigger)
Method for setting the trigger value.
constexpr Int_t nPlanes