ATLAS Offline Software
ALFA_MDGap.h
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2022 CERN for the benefit of the ATLAS collaboration
3 */
4 
5 #ifndef ALFA_MDGap_H
6 #define ALFA_MDGap_H
7 
8 #include <iostream>
9 #include <string>
10 #include <vector>
11 #include <map>
12 
14 
15 #include "GaudiKernel/StatusCode.h"
16 
17 #include "Rtypes.h"
18 #include "TMath.h"
19 #include "TH1.h"
20 #include "TH2.h"
21 
24 
25 #define MAXTRACKNUM 10
26 
27 class ALFA_MDGap : public AthMessaging
28 {
29  public:
30  ALFA_MDGap();
31  ~ALFA_MDGap();
32 
33  private:
34  Int_t m_iRPot;
35  Int_t m_iUVCut;
36  Float_t m_fOverlapCut;
37 
38  //slope, offset and Z-pos for MD fibers [2*10][64]
41 
42  //number of hits in the layer
44 
48 
51  Float_t m_fOvU[MAXTRACKNUM];
52  Float_t m_fOvV[MAXTRACKNUM];
53 
54  private:
55  std::map<Int_t, FIBERS> m_MapLayers;
56 
57  public:
58  StatusCode Initialize(Int_t iRPot, Float_t faMD[RPOTSCNT][ALFALAYERSCNT*ALFAPLATESCNT][ALFAFIBERSCNT], Float_t fbMD[RPOTSCNT][ALFALAYERSCNT*ALFAPLATESCNT][ALFAFIBERSCNT], Int_t iUVCut, Float_t fOverlapCut);
59  StatusCode Execute(const std::list<MDHIT> &ListMDHits);
60  StatusCode Finalize(Float_t (&fRecXPos)[MAXTRACKNUM], Float_t (&fRecYPos)[MAXTRACKNUM]);
61 
62  void GetData(Int_t (&iNumU)[MAXTRACKNUM], Int_t (&iNumV)[MAXTRACKNUM], Float_t (&fOvU)[MAXTRACKNUM], Float_t (&fOvV)[MAXTRACKNUM], Int_t (&iFibSel)[ALFALAYERSCNT*ALFAPLATESCNT]);
63 
64  private:
65  void Proj_Store(Int_t iFiberSide, Int_t (&iOver)[72000], Float_t fbRef, Int_t iSideFlag);
66  void Find_Proj(const Int_t iOver[72000], Float_t fbRef, Float_t &fb, Float_t &fOv, Int_t &fNum) const;
67  void Finding_Fib(Int_t iFiberSide, Float_t fbRef, Float_t fbRec, Int_t (&iFSel)[ALFAPLATESCNT], Int_t iSideFlag);
68  void Reco_Track(std::vector<Float_t> &b_p, std::vector<Float_t> &b_n,
69  std::vector<Float_t> &Ov_p, std::vector<Float_t> &Ov_n,
70  std::vector<int> &Num_p, std::vector<int> &Num_n,
71  Int_t (&FSel_n)[ALFAPLATESCNT], Int_t (&FSel_p)[ALFAPLATESCNT],
72  Int_t (&Gaps)[2][2], std::vector<Int_t> &GapsID, Bool_t (&FGaps_p)[ALFAPLATESCNT], Bool_t (&FGaps_n)[ALFAPLATESCNT],
73  Int_t (&Gap_Fib_p)[ALFAPLATESCNT][2], Int_t (&Gap_Fib_n)[ALFAPLATESCNT][2]);
74  Int_t Silent_Gap(Int_t (&Over)[72000], Float_t b_ref, Float_t b_rec, const Int_t FSel[ALFAPLATESCNT], Bool_t (&FGap)[ALFAPLATESCNT], Int_t (&Gap_Fib)[ALFAPLATESCNT][2], Float_t OverLap, Int_t iSideFlag);
75  Int_t Active_Gap(Int_t iFiberSide, Int_t (&Over)[72000], Float_t b_ref, Float_t b_rec, const Int_t FSel[ALFAPLATESCNT], Float_t OverLap, Int_t iSideFlag);
76 
77 };
78 #endif // ALFA_MDGap_H
MAXTRACKNUM
#define MAXTRACKNUM
Definition: ALFA_MDGap.h:25
ALFA_MDGap::m_fOvU
Float_t m_fOvU[MAXTRACKNUM]
Definition: ALFA_MDGap.h:51
ALFA_MDGap::m_fOverlapCut
Float_t m_fOverlapCut
Definition: ALFA_MDGap.h:36
ALFA_MDGap::Silent_Gap
Int_t Silent_Gap(Int_t(&Over)[72000], Float_t b_ref, Float_t b_rec, const Int_t FSel[ALFAPLATESCNT], Bool_t(&FGap)[ALFAPLATESCNT], Int_t(&Gap_Fib)[ALFAPLATESCNT][2], Float_t OverLap, Int_t iSideFlag)
Definition: ALFA_MDGap.cxx:537
ALFAFIBERSCNT
#define ALFAFIBERSCNT
Definition: ALFA_constants.h:10
ALFA_MDGap::m_fRecYPos
Float_t m_fRecYPos[MAXTRACKNUM]
Definition: ALFA_MDGap.h:50
RPOTSCNT
#define RPOTSCNT
Definition: ALFA_CLinkAlg.h:26
ALFA_MDGap::Proj_Store
void Proj_Store(Int_t iFiberSide, Int_t(&iOver)[72000], Float_t fbRef, Int_t iSideFlag)
Definition: ALFA_MDGap.cxx:158
ALFA_MDGap::Execute
StatusCode Execute(const std::list< MDHIT > &ListMDHits)
Definition: ALFA_MDGap.cxx:64
ALFA_MDGap::Active_Gap
Int_t Active_Gap(Int_t iFiberSide, Int_t(&Over)[72000], Float_t b_ref, Float_t b_rec, const Int_t FSel[ALFAPLATESCNT], Float_t OverLap, Int_t iSideFlag)
Definition: ALFA_MDGap.cxx:597
ALFA_MDGap::Reco_Track
void Reco_Track(std::vector< Float_t > &b_p, std::vector< Float_t > &b_n, std::vector< Float_t > &Ov_p, std::vector< Float_t > &Ov_n, std::vector< int > &Num_p, std::vector< int > &Num_n, Int_t(&FSel_n)[ALFAPLATESCNT], Int_t(&FSel_p)[ALFAPLATESCNT], Int_t(&Gaps)[2][2], std::vector< Int_t > &GapsID, Bool_t(&FGaps_p)[ALFAPLATESCNT], Bool_t(&FGaps_n)[ALFAPLATESCNT], Int_t(&Gap_Fib_p)[ALFAPLATESCNT][2], Int_t(&Gap_Fib_n)[ALFAPLATESCNT][2])
Definition: ALFA_MDGap.cxx:327
ALFA_MDGap
Definition: ALFA_MDGap.h:28
ALFA_MDGap::m_fOvV
Float_t m_fOvV[MAXTRACKNUM]
Definition: ALFA_MDGap.h:52
ALFA_MDGap::Finalize
StatusCode Finalize(Float_t(&fRecXPos)[MAXTRACKNUM], Float_t(&fRecYPos)[MAXTRACKNUM])
Definition: ALFA_MDGap.cxx:144
ALFA_constants.h
ALFA_MDGap::m_MapLayers
std::map< Int_t, FIBERS > m_MapLayers
Definition: ALFA_MDGap.h:55
ALFA_MDGap::GetData
void GetData(Int_t(&iNumU)[MAXTRACKNUM], Int_t(&iNumV)[MAXTRACKNUM], Float_t(&fOvU)[MAXTRACKNUM], Float_t(&fOvV)[MAXTRACKNUM], Int_t(&iFibSel)[ALFALAYERSCNT *ALFAPLATESCNT])
Definition: ALFA_MDGap.cxx:520
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
ALFA_MDGap::m_iRPot
Int_t m_iRPot
Definition: ALFA_MDGap.h:34
AthMessaging
Class to provide easy MsgStream access and capabilities.
Definition: AthMessaging.h:55
ALFA_MDGap::m_faMD
Float_t m_faMD[RPOTSCNT][ALFALAYERSCNT *ALFAPLATESCNT][ALFAFIBERSCNT]
Definition: ALFA_MDGap.h:39
ALFA_MDGap::m_iFibSel
Int_t m_iFibSel[ALFALAYERSCNT *ALFAPLATESCNT]
Definition: ALFA_MDGap.h:47
ALFA_MDGap::Finding_Fib
void Finding_Fib(Int_t iFiberSide, Float_t fbRef, Float_t fbRec, Int_t(&iFSel)[ALFAPLATESCNT], Int_t iSideFlag)
Definition: ALFA_MDGap.cxx:263
ALFALAYERSCNT
#define ALFALAYERSCNT
Definition: ALFA_constants.h:8
ALFA_MDGap::m_iNumHitsLayer
Int_t m_iNumHitsLayer[ALFALAYERSCNT *ALFAPLATESCNT]
Definition: ALFA_MDGap.h:43
ALFA_MDGap::m_iUVCut
Int_t m_iUVCut
Definition: ALFA_MDGap.h:35
ALFA_MDGap::m_iNV
Int_t m_iNV[MAXTRACKNUM]
Definition: ALFA_MDGap.h:46
ALFA_MDGap::m_iNU
Int_t m_iNU[MAXTRACKNUM]
Definition: ALFA_MDGap.h:45
ALFA_UserObjects.h
AthMessaging.h
ALFA_MDGap::m_fbMD
Float_t m_fbMD[RPOTSCNT][ALFALAYERSCNT *ALFAPLATESCNT][ALFAFIBERSCNT]
Definition: ALFA_MDGap.h:40
ALFA_MDGap::m_fRecXPos
Float_t m_fRecXPos[MAXTRACKNUM]
Definition: ALFA_MDGap.h:49
ALFA_MDGap::ALFA_MDGap
ALFA_MDGap()
Definition: ALFA_MDGap.cxx:7
ALFA_MDGap::~ALFA_MDGap
~ALFA_MDGap()
Definition: ALFA_MDGap.cxx:26
ALFA_MDGap::Find_Proj
void Find_Proj(const Int_t iOver[72000], Float_t fbRef, Float_t &fb, Float_t &fOv, Int_t &fNum) const
Definition: ALFA_MDGap.cxx:199
ALFA_MDGap::Initialize
StatusCode Initialize(Int_t iRPot, Float_t faMD[RPOTSCNT][ALFALAYERSCNT *ALFAPLATESCNT][ALFAFIBERSCNT], Float_t fbMD[RPOTSCNT][ALFALAYERSCNT *ALFAPLATESCNT][ALFAFIBERSCNT], Int_t iUVCut, Float_t fOverlapCut)
Definition: ALFA_MDGap.cxx:30
ALFAPLATESCNT
#define ALFAPLATESCNT
Definition: ALFA_constants.h:9