BmnRoot 26.10.0-18-g4e3414f9
Software framework of the BM@N experiment
Loading...
Searching...
No Matches
BmnTOF1Detector.h
Go to the documentation of this file.
1/*
2 * To change this license header, choose License Headers in Project Properties.
3 * To change this template file, choose Tools | Templates
4 * and open the template in the editor.
5 */
6
7/*
8 * File: BmnTOF1Detector.h
9 * Author: mikhail
10 *
11 * Created on March 13, 2017, 4:52 PM
12 */
13
14#ifndef BMNTOF1DETECTOR_H
15#define BMNTOF1DETECTOR_H 1
16
17#include "BmnEnums.h"
18#include "BmnEventHeader.h"
19#include "BmnTOF1Conteiner.h"
20#include "BmnTOF1Point.h"
21#include "BmnTof1Digit.h"
22#include "BmnTof1GeoUtils.h"
23#include "BmnTof701Digit.h"
24#include "BmnTofHit.h"
25#include "BmnTrigDigit.h"
26#include "TClonesArray.h"
27#include "TDirectory.h"
28#include "TF1.h"
29#include "TFile.h"
30#include "TGraphErrors.h"
31#include "TH1I.h"
32#include "TH2I.h"
33#include "TList.h"
34#include "TString.h"
35#include "TSystem.h"
36#include "TTree.h"
37#include "TVector3.h"
38
39#include <RtypesCore.h>
40#include <TGeoManager.h>
41#include <TKey.h>
42#include <cstdio>
43#include <cstdlib>
44#include <deque>
45#include <fstream>
46#include <iostream>
47#include <list>
48#include <map>
49#include <stdio.h>
50#include <stdlib.h>
51#include <vector>
52
53using namespace std;
54
56{
57 private:
58 static const Int_t fHalfMaxInt = kMaxInt * 0.5 - 1;
59 static const Int_t fNStrMax = 48;
60 DetectorId fTofId;
66
67 std::vector<std::vector<std::vector<Double_t>>> vHitsL;
68 std::vector<std::vector<std::vector<Double_t>>> vHitsR;
69 // std::vector<std::vector<std::vector<Double_t>>> vHits;
70
82
85
93
95
98
100
101 void FillHist();
104 void AddHit(Int_t Str, TClonesArray* TofHit);
105 void AddConteiner(Int_t Str, TClonesArray* TofHit);
106 Int_t FormIndex(Int_t IndL, Int_t IndR);
107
108 public:
110
112 Int_t tofId,
113 Int_t NPlane,
114 Int_t FillHistLevel,
115 Int_t Verbose); // FillHistLevel=0-don"t fill, FillHistLevel=1-fill statistic, FillHistLevel>1-fill all
116
117 virtual ~BmnTOF1Detector() {};
118
119 void Clear();
120 Bool_t SetDigitNew(BmnTof1Digit* TofDigit, Int_t ind = -1);
121 void KillStrip(Int_t NumberOfStrip);
122 void KillSide(Int_t NumberOfSide);
124 {
125 fStripLength = l;
126 fMaxDelta = (fStripLength * 0.5 + 3.0) * fSignalVelosity;
127 };
128 Int_t FindHitsNew(BmnTrigDigit* T0, TClonesArray* TofHit, TClonesArray* TofCont, int printnaw);
131
132 Bool_t SetCorrLR(TString NameFile);
133 Bool_t SetCorrSlewing(TString NameFile);
135 Bool_t SetGeoFile(TString NameFile);
136 Bool_t SetGeo(BmnTof1GeoUtils* pGeoUtils);
138 Bool_t GetXYZTime(Int_t Str, TVector3* XYZ, Double_t* ToF);
139 Bool_t GetLRTime(Int_t Str, Double_t* LMinusRTime);
144 Bool_t SaveHistToFile(TString NameFile);
146
148
150};
151
152#endif
bool Bool_t
int Int_t
constexpr Int_t kMaxInt
short Short_t
double Double_t
#define ClassDef(name, id)
Short_t fIndexL[fNStrMax]
Double_t fSignalVelosity
Double_t fCorrTimeShift[fNStrMax]
Int_t fDigitR[fNStrMax]
TH2S * hdT_vs_WidthT0[fNStrMax+1]
Double_t fTof[fNStrMax]
Int_t FormIndex(Int_t IndL, Int_t IndR)
Bool_t GetXYZTime(Int_t Str, TVector3 *XYZ, Double_t *ToF)
static const Int_t fHalfMaxInt
virtual ~BmnTOF1Detector()
void SetStripLength(Double_t l)
Double_t fTimeLtemp[fNStrMax]
Double_t fWidthL[fNStrMax]
Bool_t SetGeoFile(TString NameFile)
TVector3 fCentrStrip[fNStrMax]
Bool_t SetCorrLR(TString NameFile)
Bool_t fKilled[fNStrMax]
Double_t fTimeR[fNStrMax]
void KillSide(Int_t NumberOfSide)
TVector3 fStripAngle[fNStrMax]
Double_t GetWidth(Int_t Str)
std::vector< std::vector< std::vector< Double_t > > > vHitsL
Short_t fIndexR[fNStrMax]
Int_t fDigitL[fNStrMax]
Int_t FindHitsNew(BmnTrigDigit *T0, TClonesArray *TofHit, TClonesArray *TofCont, int printnaw)
Bool_t GetLRTime(Int_t Str, Double_t *LMinusRTime)
BmnTrigDigit * fT0
Double_t fTimeL[fNStrMax]
TH1I * hdT[fNStrMax+1]
TF1 * funT0[fNStrMax]
Bool_t SetCorrTimeShift(TString NameFile)
static const Int_t fNStrMax
Double_t GetWidthR(Int_t Str)
TF1 * funRPC[fNStrMax]
Double_t fWidthRtemp[fNStrMax]
Double_t fWidthR[fNStrMax]
void KillStrip(Int_t NumberOfStrip)
Double_t fWidth[fNStrMax]
TH2S * hdT_vs_WidthDet[fNStrMax+1]
Bool_t SetDigitNew(BmnTof1Digit *TofDigit, Int_t ind=-1)
Double_t GetTime(Int_t Str)
Bool_t fFlagHit[fNStrMax]
Double_t fTime[fNStrMax]
Double_t fSignalVelosityStr[fNStrMax]
Double_t GetWidthL(Int_t Str)
Int_t fHit[fNStrMax]
TVector3 fCrossPoint[fNStrMax]
Bool_t SetGeo(BmnTof1GeoUtils *pGeoUtils)
Bool_t GetCrossPoint(Int_t NStrip, Double_t tL, Double_t tR)
Short_t fIndexRtemp[fNStrMax]
Double_t fCorrLR[fNStrMax]
Bool_t SaveHistToFile(TFile *fileout)
Double_t CalculateDt(Int_t Str)
void AddConteiner(Int_t Str, TClonesArray *TofHit)
Bool_t SetSpeedOfSignal(TString NameFile)
Double_t fTimeRtemp[fNStrMax]
Double_t fCommonTimeShift
TList * GetList(Int_t n)
std::vector< std::vector< std::vector< Double_t > > > vHitsR
void AddHit(Int_t Str, TClonesArray *TofHit)
Bool_t SetCorrSlewing(TString NameFile)
Double_t fWidthLtemp[fNStrMax]
Short_t fIndexLtemp[fNStrMax]
Bool_t SaveHistToFile(TString NameFile)
TGraphErrors * gSlew[fNStrMax]
*brief user defined string literal for JSON values *sa std::size_t n
Definition json.hpp:20362
Definition json.hpp:4446