PandaRoot
PndSdsCalcStrip.h
Go to the documentation of this file.
1 //
2 // C++ Interface: PndSdsCalcStrip
3 //
4 // Description:
5 //
6 //
7 // Authors: HG Zaunick <hg.zaunick@physik.tu-dresden.de>, (C) 2007
8 // R Kliemt (Tu Dresden,Uni Bonn)
9 //
10 // Copyright: See COPYING file that comes with this distribution
11 //
12 //
13 #ifndef PNDSDSCALCSTRIP_H
14 #define PNDSDSCALCSTRIP_H
15 
16 #include "PndSdsStrip.h"
17 //#include "FairGeoVector.h"
18 #include "PndSdsStripDigiPar.h"
19 
20 #include <TVector2.h>
21 
22 #include <iostream>
23 #include <vector>
24 
25 #include "PndDetectorList.h"
26 
28 
34  public:
40 
53  PndSdsCalcStrip(Double_t pitch, Double_t orient, Int_t nrStrips, Int_t nrFeChannels, const TVector2 &firstStripAnchor, Double_t threshold, Double_t noise, Double_t csigma);
54 
56 
68  std::vector<PndSdsStrip> GetStrips(Double_t inx, Double_t iny, Double_t inz, Double_t outx, Double_t outy, Double_t outz, Double_t eLoss);
69 
70  // Calculate without diffusion
71  std::vector<PndSdsStrip> GetStripsNoDif(Double_t nuIn, Double_t nuOut, Double_t Q);
72 
73  // Calculate with diffusion
74  std::vector<PndSdsStrip> GetStripsDif(Double_t nuIn, Double_t nuOut, Double_t Q);
75  Double_t CalcFk(Double_t strip, Double_t x, Double_t sig);
76 
77  // for debugging; call one of the GetStrips* but returns the number of strips and int arrays to their channel/charge
78  Int_t GetStripsAlternative(Double_t nuIn, Double_t nuOut, Double_t Q, Int_t mode, std::vector<Int_t> &indice, std::vector<Double_t> &charges);
79 
85  Int_t CalcFEfromStrip(Int_t stripNr) const;
86 
92  Int_t CalcChannelfromStrip(Int_t stripNr) const;
93 
101  void CalcFeChToStrip(Int_t fe, Int_t channel, Int_t &strip, enum SensorSide &side) const;
102  void CalcStripPointOnLine(const Double_t strip, TVector2 &point) const;
103 
107  const TVector2 GetStripDirection() const { return fStripDir; }
108 
109  void SetVerboseLevel(Int_t level) { fVerboseLevel = level; }
110  // std::ostream& operator<<(std::ostream& out); // not implemented
111  Double_t GetThreshold() const { return fThreshold; }
112  Double_t GetNoise() const { return fNoise; }
113 
114  void Print() const;
115 
116  private:
117  Double_t fPitch;
118  Double_t fOrient;
119  Int_t fNrStrips;
120  Int_t fNrFeChannels;
121  TVector2 fAnchor;
122  Double_t fThreshold;
123  Double_t fNoise;
124  Double_t fCSigma;
125  TVector2 fStripDir;
126  TVector2 fOrthoDir;
127  Int_t fVerboseLevel;
128 
135  Double_t CalcStripFromPoint(Double_t x, Double_t y);
136 
137  Double_t ChargeFromEloss(Double_t eloss) const { return eloss / (3.61e-9); }
138  void InjectStripCharge(std::vector<PndSdsStrip> &array, Int_t istrip, Double_t charge);
139  Double_t SmearCharge(Double_t charge);
140 };
141 
142 #endif /* PNDSDSCALCSTRIP_H */
void CalcStripPointOnLine(const Double_t strip, TVector2 &point) const
Int_t CalcFEfromStrip(Int_t stripNr) const
void CalcFeChToStrip(Int_t fe, Int_t channel, Int_t &strip, enum SensorSide &side) const
Class for calculating strip indices from wafer hits.
Int_t GetStripsAlternative(Double_t nuIn, Double_t nuOut, Double_t Q, Int_t mode, std::vector< Int_t > &indice, std::vector< Double_t > &charges)
std::vector< PndSdsStrip > GetStrips(Double_t inx, Double_t iny, Double_t inz, Double_t outx, Double_t outy, Double_t outz, Double_t eLoss)
Digitization Parameter Class for MVD-Strip part.
SensorSide
Double_t CalcFk(Double_t strip, Double_t x, Double_t sig)
std::vector< PndSdsStrip > GetStripsDif(Double_t nuIn, Double_t nuOut, Double_t Q)
std::vector< PndSdsStrip > GetStripsNoDif(Double_t nuIn, Double_t nuOut, Double_t Q)
Double_t GetNoise() const
void Print() const
const TVector2 GetStripDirection() const
Double_t GetThreshold() const
void SetVerboseLevel(Int_t level)
Int_t CalcChannelfromStrip(Int_t stripNr) const