CbmRoot
Loading...
Searching...
No Matches
CbmRichAlignment.h
Go to the documentation of this file.
1/* Copyright (C) 2016 Justus-Liebig-Universitaet Giessen, Giessen
2 SPDX-License-Identifier: GPL-3.0-only
3 Authors: Jordan Bendarouach [committer] */
4
5#ifndef CBMRICHALIGNMENT_H
6#define CBMRICHALIGNMENT_H
7
8
9#include "CbmHistManager.h"
12#include "FairTask.h"
13
14#include <vector>
15
16using namespace std;
17
18class TClonesArray;
19class TH1D;
20class TH2D;
21
22
23class CbmRichAlignment : public FairTask {
24 private:
25 static const int kMAX_NOF_HITS = 100; // Maximum number of hits in ring
26
27 public:
28 /*
29 * Constructor.
30 */
32
33 /*
34 * Destructor.
35 */
36 virtual ~CbmRichAlignment();
37
41 virtual InitStatus Init();
42
46 virtual void Exec(Option_t* option);
47
51 virtual void Finish();
52
53 /*
54 * Histogram initialization for alignment method.
55 */
56 void InitHistAlignment();
57
58 /*
59 * Calculate the distances between C and C', the Cherenkov distances and angles (Theta_Ch vs Phi_Ch) for each photon hit in a given event and draw the corresponding
60 * distributions.
61 */
63
64 /*
65 * Get x and y positions on the PMT plane from the extrapolated track.
66 */
67 void GetTrackPosition(Double_t& x, Double_t& y);
68
69 /*
70 * Draw histograms for alignment method.
71 */
72 void DrawHistAlignment();
73
74 /*
75 *
76 */
77 void DrawFit(vector<Double_t>& outputFit, Int_t thresh);
78
79 /*
80 * Draw histograms from root file.
81 */
82 void DrawHistFromFile(TString fileName);
83
84 /*
85 * Set output directory for images.
86 */
87 void SetOutputDir(TString dir) { fOutputDir = dir; }
88
89 /*
90 * Set run title. It is also a part of the file name of image files.
91 */
92 void SetRunTitle(TString title) { fRunTitle = title; }
93
94 /*
95 * Set axis rotation title. It is also a part of the file name of image files.
96 */
97 void SetAxisRotTitle(TString title) { fAxisRotTitle = title; }
98
99 /*
100 * Set to TRUE if you want to draw histograms.
101 */
102 void SetDrawAlignment(Bool_t b) { fDrawAlignment = b; }
103
104 /*
105 *
106 */
107 void SetNumbAxis(TString n) { fNumbAxis = n; }
108
109 /*
110 *
111 */
112 void SetTileName(TString a) { fTile = a; }
113
114
115 private:
116 TClonesArray* fRichHits; // Array of RICH hits
117 TClonesArray* fRichRings; // Array of found RICH rings
118 TClonesArray* fRichProjections;
119 TClonesArray* fRichPoints;
120 TClonesArray* fMCTracks;
121 TClonesArray* fRichRingMatches;
122 TClonesArray* fRichMirrorPoints;
123 // TClonesArray* fRichRefPlanePoints;
124 // TClonesArray* fRichMCPoints;
125 // TClonesArray* fGlobalTracks;
127
128 UInt_t fEventNum; // Event counter
129 TString fNumbAxis; // Misalignment applied on the geometry.
130 TString fTile;
131 Bool_t fDrawAlignment; // If TRUE, draws the alignment and fitting plots.
132 vector<Float_t> fPhi;
133
134 TString fOutputDir; // Output directory to store figures.
135 TString fRunTitle; // Title of the run.
136 TString fAxisRotTitle; // Rotation around which axis.
137
140
143
145};
146
147#endif
Histogram manager.
Here the ring is fitted with the COP algorithm from A. Ayriyan/G. Ososkov.
Here the ring is fitted with Taubin algorithm from A. Ayriyan, G. Ososkov, N. Chernov.
Histogram manager.
void SetOutputDir(TString dir)
TClonesArray * fMCTracks
CbmRichRingFitterCOP * fCopFit
CbmRichAlignment(const CbmRichAlignment &)
void SetDrawAlignment(Bool_t b)
void GetTrackPosition(Double_t &x, Double_t &y)
void DrawHistFromFile(TString fileName)
virtual void Finish()
Inherited from FairTask.
CbmHistManager * fHM
CbmRichAlignment operator=(const CbmRichAlignment &)
void DrawFit(vector< Double_t > &outputFit, Int_t thresh)
ClassDef(CbmRichAlignment, 1)
TClonesArray * fRichHits
void SetTileName(TString a)
vector< Float_t > fPhi
TClonesArray * fRichRings
TClonesArray * fRichPoints
void SetAxisRotTitle(TString title)
TClonesArray * fRichMirrorPoints
virtual void Exec(Option_t *option)
Inherited from FairTask.
TClonesArray * fRichProjections
static const int kMAX_NOF_HITS
CbmRichRingFitterEllipseTau * fTauFit
void SetRunTitle(TString title)
void SetNumbAxis(TString n)
TClonesArray * fRichRingMatches
virtual InitStatus Init()
Inherited from FairTask.
Here the ring is fitted with the COP algorithm from A. Ayriyan/G. Ososkov.
Here the ring is fitted with Taubin algorithm from A. Ayriyan, G. Ososkov, N. Chernov.
Hash for CbmL1LinkKey.