HYDRA_development_version
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
hrich700digitizer.h
Go to the documentation of this file.
1 #ifndef HRICH700DIGITIZER_H
2 #define HRICH700DIGITIZER_H
3 
4 #include "hlocation.h"
5 #include "hreconstructor.h"
6 #include "hcategory.h"
7 #include "hiterator.h"
8 #include "hgeantrich.h"
9 #include "hrich700pmt.h"
10 
11 #include <map>
12 #include <vector>
13 using namespace std;
14 
15 class HGeantKine;
16 class HRich700DigiPar;
17 
19 
20 private:
21 
22  HCategory* fCatKine; //!
23  HCategory* fCatRichPhoton; //!
24  HCategory* fCatRichDirect; //!
25  HCategory* fCatRichCal; //!
27 
29 
30  // if true: we store trackIds only for the converted photons
31  // This can influence efficiency
32  // Must be set to true when ideal ring finder is used
34 
35  //------------------------------------------------------
36  // delta electron handling
37  Bool_t fUseDeltaElectrons; //! switch for use/not use delta electron time smearing
38  Bool_t fUseDeltaMomSelection; //! switch for use/not use momentum below momMaxDeltaElecCut for primary electrons to identify delta electrons
39  Int_t fIonID; //! beam ion (au ==109)
40  Float_t fMomMaxDeltaElecCut; //! delta electron smearing : primary electrons below this mom are considdered to be delta electrons [MeV/c]
41  Float_t fMomMinDeltaCut[6]; //! min mom cut per sector (account for different mirror materials) [MeV/c]
42  Float_t fProbDeltaAccepted; //! 0 - 1 probability to accept a delta electron (yield adjustment)
43  map<HGeantKine*,Float_t> fmDeltaTrackProb; //! map delta electron candidates to prob
44  map<HGeantKine*,Float_t>::iterator fitDelta;//! map delta electron candidates to prob
45  //------------------------------------------------------
46 
48 
49  void processEvent();
50 
51  void setProbabilityForDeltaElectrons();
52 
53  Bool_t workOnDeltaElectrons(HGeantKine* primary, Int_t sector);
54 
55  void processRichPhoton(HGeantRichPhoton* photon);
56 
57  void processRichDirect(HGeantRichDirect* direct);
58 
59  void addRichCal(Int_t sector, Int_t col, Int_t row, Int_t trackId);
60 
61  void addAllTrackIds();
62 
63  void addTrackId(Int_t sector, Int_t col, Int_t row, Int_t trackId);
64 
65  void addCrossTalkHit(Int_t sector, Int_t col, Int_t row, Int_t trackId);
66 
67  void addNoiseHits();
68 
69 public:
70  HRich700Digitizer(const Text_t* name ="Rich700Digitizer", const Text_t* title= "Rich700Digitizer");
71 
73 
74  Bool_t init();
75  Bool_t reinit();
76  Int_t execute();
77  Bool_t finalize();
78  static HRich700Digitizer* getDigitizer() { return fDigitizer;}
79 
80  void setStoreOnlyConvertedPhotonTrackIds(Bool_t s){fStoreOnlyConvertedPhotonTrackIds = s;}
81 
82  //----------- using delta electrons -----------------
83  void setDeltaElectronUse(Bool_t use, Bool_t useDeltaMomSel=kFALSE, Int_t ionId=109,Float_t momCut=20.,Float_t probDelta=2.){ fProbDeltaAccepted = probDelta; fUseDeltaElectrons = use;fUseDeltaMomSelection = useDeltaMomSel; fIonID=ionId; fMomMaxDeltaElecCut = momCut; }
84  Bool_t getDeltaElectronUse() { return fUseDeltaElectrons;}
85  void setDeltaElectronMinMomCut(Float_t s0=2.,Float_t s1=2.,Float_t s2=4.,Float_t s3=2.,Float_t s4=2.,Float_t s5=4.) { fMomMinDeltaCut[0]=s0; fMomMinDeltaCut[1]=s1; fMomMinDeltaCut[2]=s2; fMomMinDeltaCut[3]=s3; fMomMinDeltaCut[4]=s4; fMomMinDeltaCut[5]=s5; }
86 
87  ClassDef(HRich700Digitizer, 0)
88 
89 };
90 
91 #endif // HRICH700DIGITIZER_H
void setDeltaElectronMinMomCut(Float_t s0=2., Float_t s1=2., Float_t s2=4., Float_t s3=2., Float_t s4=2., Float_t s5=4.)
HCategory * fCatRichCal
Bool_t getDeltaElectronUse()
static HRich700Digitizer * getDigitizer()
Bool_t fStoreOnlyConvertedPhotonTrackIds
map< HGeantKine *, Float_t >::iterator fitDelta
map delta electron candidates to prob
HRich700DigiPar * fDigiPar
void setDeltaElectronUse(Bool_t use, Bool_t useDeltaMomSel=kFALSE, Int_t ionId=109, Float_t momCut=20., Float_t probDelta=2.)
Int_t fIonID
switch for use/not use momentum below momMaxDeltaElecCut for primary electrons to identify delta elec...
static HRich700Digitizer * fDigitizer
HCategory * fCatRichPhoton
HRich700Pmt fPmt
map delta electron candidates to prob
HCategory * fCatRichDirect
void setStoreOnlyConvertedPhotonTrackIds(Bool_t s)
Bool_t fUseDeltaMomSelection
switch for use/not use delta electron time smearing
map< HGeantKine *, Float_t > fmDeltaTrackProb
0 - 1 probability to accept a delta electron (yield adjustment)
Float_t fMomMaxDeltaElecCut
beam ion (au ==109)
Float_t fProbDeltaAccepted
min mom cut per sector (account for different mirror materials) [MeV/c]