FairRoot/PandaRoot
Public Member Functions | Private Member Functions | Private Attributes | List of all members
PndDrcRecoLookupMapS Class Reference

#include <PndDrcRecoLookupMapS.h>

Inheritance diagram for PndDrcRecoLookupMapS:

Public Member Functions

 PndDrcRecoLookupMapS ()
 
 PndDrcRecoLookupMapS (Int_t verbose)
 
virtual ~PndDrcRecoLookupMapS ()
 
virtual InitStatus Init ()
 
virtual void Exec (Option_t *option)
 
virtual void Finish ()
 
void SetHistoWidth (double wid=0.01)
 
void SetNSigma (double nsig=3.)
 
void SetMagneticField (double mag=0.)
 
void SetOutputFile (TString outName="PndDrcRecoLookupMapS_output.root")
 

Private Member Functions

void ProcessPhotonHit ()
 
void ProcessPhotonMC ()
 
void WriteToFile ()
 
void CreateHisto ()
 
void DrawHisto ()
 
void ProcessBarHit ()
 
virtual void SetParContainers ()
 
Double_t InBarCoordSyst (TVector3, TVector3 *, TVector3 *, TVector3 *, TVector3 *)
 
Int_t NumberOfBounces (TVector3, TVector3, Int_t)
 
Double_t FindOutPoint (Double_t, Double_t, Double_t, Double_t *, Bool_t)
 
Double_t CherenkovPhi (TVector3, TVector3, Double_t *, Double_t *)
 
Double_t RecoAmbigTime (TVector3, TVector3, Double_t *, Bool_t)
 
void DrawBarBox (TVector3, TVector3, TVector3, TVector3)
 
void SetDefaultParameters ()
 

Private Attributes

Double_t fpi
 
Double_t fR
 
Double_t fzup
 
Double_t fzdown
 
Double_t fHThick
 
Double_t fBboxNum
 
Double_t fBarNum
 
Double_t fPipehAngle
 
Double_t fBarBoxGap
 
Double_t fLSide
 
Double_t fBarWidth
 
Double_t fDphi
 
TTree * mapstree
 
Float_t fxx
 
Float_t fyy
 
Float_t fchdiff
 
PndDrcDigiParfDigiPar
 
Int_t fDetectorID
 
TClonesArray * fBarPointArray
 
TClonesArray * fPDPointArray
 
TClonesArray * fHitArray
 
TClonesArray * fPDHitArray
 
TClonesArray * fMCArray
 
TClonesArray * fDigiArray
 
TClonesArray * fDrcLutInfoArray
 
TList * fHistoList
 
PndGeoDrcfGeo
 Basic geometry data of barrel DRC. More...
 
PndGeoHandlingfGeoH
 
Int_t fVerbose
 
Int_t nevents
 
TString fOutputName
 
Double_t fWidth
 
Double_t fPixelSize
 
Double_t fHAngleInBDeg
 
Double_t fCHrecoMin
 
Double_t fCHrecoMax
 
Double_t fNSigma
 
Double_t fB
 
TVector3 fnX1
 
TVector3 fnY1
 
Double_t flambdah
 
Double_t fpixID
 
Double_t fxbar
 
Double_t fybar
 
Double_t fxPHit
 
Double_t fyPHit
 
Double_t fzPHit
 
Double_t ftime
 
Double_t ftime0
 
Double_t fPhiRot
 
TVector3 fPMo
 
TVector3 fPMoB
 
TVector3 fPphoInit
 
TVector3 fkBar
 
Double_t fWeight
 
Int_t fBarId
 
Bool_t print
 
Int_t NHitPix
 
Int_t NPixPar
 
Int_t NAmb
 
Double_t fkxBar
 
Double_t fkyBar
 
Double_t fkzBar
 
Double_t fPxMoBar
 
Double_t fPyMoBar
 
Double_t fPzMoBar
 
Double_t fxnew
 
Double_t fynew
 
Double_t CHexp
 
Double_t CHreal
 
TVector3 fPphoB
 
TVector3 fStartVertex
 
TVector3 fPphoPD
 
Double_t fPath
 
Double_t fPhiMap
 
Double_t fThetaMap
 
TVector3 fBBver1
 
TVector3 fBBver2
 
TVector3 fBBver3
 
TVector3 fBBver4
 

Detailed Description

PndDrcRecoLookupMapS.h

Class for Analysising DRC Cherenkov Photons with lookup tables for CHerenkov photons directions

Definition at line 49 of file PndDrcRecoLookupMapS.h.

Constructor & Destructor Documentation

PndDrcRecoLookupMapS::PndDrcRecoLookupMapS ( )

Default constructor

Definition at line 55 of file PndDrcRecoLookupMapS.cxx.

References fDigiPar, fGeo, and fGeoH.

56 :FairTask("PndDrcRecoLookupMapS")
57 {
58  fGeo = new PndGeoDrc();
59  fGeoH=NULL;
60  fDigiPar = NULL;
61 }
PndGeoDrc * fGeo
Basic geometry data of barrel DRC.
PndDrcRecoLookupMapS::PndDrcRecoLookupMapS ( Int_t  verbose)

Constructor with verbosity

Definition at line 64 of file PndDrcRecoLookupMapS.cxx.

References fDigiPar, fGeo, fGeoH, fVerbose, and verbose.

65  :FairTask("PndDrcRecoLookupMapS")
66 {
67  fVerbose = verbose;
68  fGeo = new PndGeoDrc();
69  fGeoH=NULL;
70  fDigiPar = NULL;
71 }
#define verbose
PndGeoDrc * fGeo
Basic geometry data of barrel DRC.
PndDrcRecoLookupMapS::~PndDrcRecoLookupMapS ( )
virtual

Destructor

Definition at line 73 of file PndDrcRecoLookupMapS.cxx.

References fGeo, fGeoH, and fHistoList.

74 {
75  if (fGeo) delete fGeo;
76  if (fGeoH) delete fGeoH;
77  fHistoList->Delete();
78  delete fHistoList;
79 }
PndGeoDrc * fGeo
Basic geometry data of barrel DRC.

Member Function Documentation

Double_t PndDrcRecoLookupMapS::CherenkovPhi ( TVector3  ,
TVector3  ,
Double_t ,
Double_t  
)
private
void PndDrcRecoLookupMapS::CreateHisto ( )
private

Definition at line 690 of file PndDrcRecoLookupMapS.cxx.

Referenced by Init().

690 {}
void PndDrcRecoLookupMapS::DrawBarBox ( TVector3  v1,
TVector3  v2,
TVector3  v3,
TVector3  v4 
)
private

Definition at line 633 of file PndDrcRecoLookupMapS.cxx.

References Double_t.

633  {
634  Double_t xx[5];
635  Double_t yy[5];
636  xx[0] = v1.X(); xx[1] = v2.X(); xx[2] = v3.X(); xx[3] = v4.X(); xx[4] = v1.X();
637  yy[0] = v1.Y(); yy[1] = v2.Y(); yy[2] = v3.Y(); yy[3] = v4.Y(); yy[4] = v1.Y();
638  TPolyLine *p6 =new TPolyLine(5,xx,yy);
639  p6->SetLineWidth(2);
640  p6->Draw("same");
641 }
Double_t
TVector3 v1
Definition: bump_analys.C:40
TVector3 v2
Definition: bump_analys.C:40
void PndDrcRecoLookupMapS::DrawHisto ( )
private

Definition at line 704 of file PndDrcRecoLookupMapS.cxx.

Referenced by Finish().

704 {}
void PndDrcRecoLookupMapS::Exec ( Option_t *  option)
virtual

Executed task

Definition at line 196 of file PndDrcRecoLookupMapS.cxx.

References fDetectorID, fGeoH, fVerbose, nevents, ProcessPhotonHit(), and PndGeoHandling::SetVerbose().

197 {
198  //if ( ! fChPhoArray ) Fatal("Exec", "No fChPhoArray");
199  //fChPhoArray->Clear();
201 
202  nevents++;
203  fDetectorID = 0;
204 
205  cout<<"EVENT # "<<nevents<<endl;
206  // fNHits = 0;
207  //ProcessBarHit();
209  //ProcessPhotonMC();
210 }
void SetVerbose(Int_t v)
Double_t PndDrcRecoLookupMapS::FindOutPoint ( Double_t  x0,
Double_t  xEn,
Double_t  a,
Double_t NN,
Bool_t  printt 
)
private

Definition at line 599 of file PndDrcRecoLookupMapS.cxx.

References a, Double_t, m, and n.

Referenced by NumberOfBounces().

599  {
600  Double_t m=99.;
601  Double_t n=TMath::Floor(x0/a);
602  m = n;
603  if(printt){std::cout<<"n = "<<n<<", NN = "<<*NN<<", x0 = "<<x0<<", a = "<<a<<std::endl;}
604  Double_t x1 = x0 - n*a;
605  if(x0 < 0.){x1 = x0 - (n+1)*a;}
606  if(printt){std::cout<<"xy = "<< x1<<std::endl;}
607  Double_t xK = 0.;
608  if((m/2. - TMath::Floor(m/2.)) == 0.) { // 4etnoe
609  //if(print){std::cout<<"odd==0"<<std::endl;}
610  if(x0 >= 0. && x1 + xEn <= a){xK = x1 + xEn;}
611  if(x0 >= 0. && x1 + xEn > a){xK = 2*a - x1 - xEn; n = 1. + n;}
612  if(x0 < 0. && x1 + xEn >= 0.){xK = a - (x1 + xEn); n = -1. -n;}
613  if(x0 < 0. && x1 + xEn < 0.) {xK = a + x1 + xEn; n = -n;}
614  if(printt){std::cout<<"xK = "<< xK<<", n = "<<n<<std::endl;}
615 
616  }
617 
618  if((m/2. - TMath::Floor(m/2.)) != 0.) { // ne4etnoe
619  //if(print){std::cout<<"even!=0"<<std::endl;}
620  if(x0 >= 0. && x1 + xEn <= a){xK = a - (x1 + xEn);}
621  if(x0 >= 0. && x1 + xEn > a){xK = x1 + xEn - a; n = 1. + n;}
622  if(x0 < 0. && x1 + xEn >= 0.){xK = x1 + xEn; n = -1. -n;}
623  if(x0 < 0. && x1 + xEn < 0.) {xK = - (x1 + xEn); n = -n;}
624  if(printt){std::cout<<"xK = "<< xK<<", n = "<<n<<std::endl;}
625 
626  }
627 
628  *NN = n;
629  return xK;
630 }
Double_t x0
Definition: checkhelixhit.C:70
__m128 m
Definition: P4_F32vec4.h:28
int n
Int_t a
Definition: anaLmdDigi.C:126
Double_t
void PndDrcRecoLookupMapS::Finish ( )
virtual

Finish task

Definition at line 696 of file PndDrcRecoLookupMapS.cxx.

References DrawHisto(), and WriteToFile().

697 {
698  cout << "-I- PndDrcRecoLookupMapS: Finish" << endl;
699  WriteToFile();
700  DrawHisto();
701 }
Double_t PndDrcRecoLookupMapS::InBarCoordSyst ( TVector3  start,
TVector3 *  v1,
TVector3 *  v2,
TVector3 *  v3,
TVector3 *  v4 
)
private

Definition at line 523 of file PndDrcRecoLookupMapS.cxx.

References Double_t, fDphi, fHThick, fLSide, fpi, fPipehAngle, and fR.

Referenced by ProcessPhotonHit().

523  {
524  Double_t startPhi = start.Phi()/fpi*180.; // [degrees]
525  //cout<<"-I- InBarCoordinateSystem: start phi = "<<start.Phi()/fpi*180.<<endl;
526  if(startPhi < 0.){startPhi = 360. + startPhi;}
527  //if(startPhi > 360.){startPhi = startPhi - 360.;}
528  //cout<<"-I- InBarCoordinateSystem: start phi = "<<startPhi<<endl;
529  //Double_t dphi = 2.*(180. - 2*fPipehAngle)/ fBboxNum; //[degrees]
530  //cout<<"-I- InBarCoordinateSystem: dphi = "<<dphi<<endl;
531  Double_t PhiRot = 0.; //[degrees]
532  if(startPhi >= 0. && startPhi < 90.){
533  PhiRot = TMath::Floor(startPhi/fDphi) *fDphi + fDphi/2.;
534  }
535  if(startPhi >= 90. && startPhi < 270.){
536  PhiRot = 90. + fPipehAngle + TMath::Floor((startPhi-90.-fPipehAngle)/fDphi) *fDphi + fDphi/2.;
537  }
538  if(startPhi >= 270. && startPhi < 360.){
539  PhiRot = 270. + fPipehAngle + TMath::Floor((startPhi-270.-fPipehAngle)/fDphi) *fDphi + fDphi/2.;
540  }
541  //cout<<"-I- InBarCoordinateSystem: PhiRot = "<<PhiRot<<endl;
542 
543  TVector3 ver1, ver2, ver3, ver4;
544  ver1.SetXYZ(fR-(fHThick), fLSide/2. ,0.);
545  ver2.SetXYZ(fR+(fHThick), fLSide/2. ,0.);
546  ver3.SetXYZ(fR+(fHThick), -fLSide/2. ,0.);
547  ver4.SetXYZ(fR-(fHThick), -fLSide/2. ,0.);
548 
549  ver1.RotateZ(PhiRot/180.*fpi);
550  ver2.RotateZ(PhiRot/180.*fpi);
551  ver3.RotateZ(PhiRot/180.*fpi);
552  ver4.RotateZ(PhiRot/180.*fpi);
553 
554  *v1 = ver1;
555  *v2 = ver2;
556  *v3 = ver3;
557  *v4 = ver4;
558 
559  return PhiRot/180.*fpi;
560 }
Double_t
TVector3 v1
Definition: bump_analys.C:40
TVector3 v2
Definition: bump_analys.C:40
InitStatus PndDrcRecoLookupMapS::Init ( )
virtual

Definition at line 82 of file PndDrcRecoLookupMapS.cxx.

References PndGeoDrc::barBoxZDown(), PndGeoDrc::barBoxZUp(), PndGeoDrc::barHalfThick(), PndGeoDrc::barNum(), PndGeoDrc::BarWidth(), PndGeoDrc::BBoxGap(), PndGeoDrc::BBoxNum(), CreateHisto(), fBarBoxGap, fBarNum, fBarPointArray, fBarWidth, fBboxNum, fDigiArray, fDphi, fDrcLutInfoArray, fGeo, fHThick, fLSide, fMCArray, fnX1, fnY1, fPDHitArray, fPDPointArray, fpi, fPipehAngle, fR, fzdown, fzup, PndGeoDrc::Lside(), nevents, Pi, PndGeoDrc::PipehAngle(), and PndGeoDrc::radius().

83 {
84  cout << " ---------- INITIALIZATION ------------" << endl;
85  nevents = 0;
86  // Get RootManager
87  FairRootManager* ioman = FairRootManager::Instance();
88  if ( ! ioman ) {
89  cout << "-E- PndDrcRecoLookupMapS::Init: "
90  << "RootManager not instantiated!" << endl;
91  return kFATAL;
92  }
93 
94  // Get input array
95  fMCArray = (TClonesArray*) ioman->GetObject("MCTrack");
96  if ( ! fMCArray ) {
97  cout << "-W- PndDrcRecoLookupMapS::Init: "
98  << "No MCTrack array!" << endl;
99  return kERROR;
100  }
101  // Get input array
102  fBarPointArray = (TClonesArray*) ioman->GetObject("DrcBarPoint");
103  if ( ! fBarPointArray ) {
104  cout << "-W- PndDrcRecoLookupMapS::Init: "
105  << "No DrcBarPoint array!" << endl;
106  return kERROR;
107  }
108  // Get Photon point array
109  fPDPointArray = (TClonesArray*) ioman->GetObject("DrcPDPoint");
110  if ( ! fPDPointArray ) {
111  cout << "-W- PndDrcRecoLookupMapS::Init: "
112  << "No DrcPDPoint array!" << endl;
113  return kERROR;
114  }
115 /* // Get input array
116  fHitArray = (TClonesArray*) ioman->GetObject("DrcHit");
117  if ( ! fHitArray ) {
118  cout << "-W- PndDrcRecoLookupMapS::Init: "
119  << "No DrcHit array!" << endl;
120  return kERROR;
121  }
122 */
123 
124  // Get digi array
125  fDigiArray = (TClonesArray*) ioman->GetObject("DrcDigi");
126  if ( ! fDigiArray ) {
127  cout << "-W- PndDrcRecoLookupMapS::Init: " << "No DrcDigi array!" << endl;
128  return kERROR;
129  }
130 
131  // Get input array
132  fPDHitArray = (TClonesArray*) ioman->GetObject("DrcPDHit");
133  if ( ! fPDHitArray ) {
134  cout << "-W- PndDrcRecoLookupMapS::Init: "
135  << "No DrcPDHit array!" << endl;
136  return kERROR;
137  }
138 
139  // Create and register output array
140  // fChPhoArray = new TClonesArray("PndChPho");
141  // ioman->Register("ChPho","Drc",fChPhoArray, kTRUE);
142  fDrcLutInfoArray = new TClonesArray("PndDrcLutInfo");
143  ioman->Register("DrcLutInfo","Drc",fDrcLutInfoArray, kTRUE);
144 
145  // Get parameters:
146  fpi = TMath::Pi();
147 
148  fR = fGeo->radius();
149  fzup = fGeo->barBoxZUp();
150  fzdown = fGeo->barBoxZDown();
152  fBboxNum = fGeo->BBoxNum();
153  fBarNum = fGeo->barNum();
155  fBarBoxGap = fGeo->BBoxGap();
156  //fLength = (180. - 2.*fPipehAngle - fBarBoxGap/fR*(fBboxNum/2. - 1.)/fpi*180.)/(fBboxNum/2.) * fR/ 180.*fpi;
157  fDphi = 2.*(180. - 2*fPipehAngle)/ fBboxNum; //[degrees]
158  fLSide = fGeo->Lside();//(180. - 2.*fPipehAngle - fBarBoxGap/fR*(fBboxNum/2. - 1.)/fpi*180.)/(fBboxNum/2.) * fR/ 180.*fpi;
159  fBarWidth = fGeo->BarWidth();//fLSide/fBarNum;
160 
161  // vectors of bar surfaces:
162  fnX1.SetXYZ(-1., 0.,0.);
163  fnY1.SetXYZ( 0., 1.,0.);
164 
165  cout << "-I- PndDrcRecoLookupMapS: Intialization successfull" << endl;
166  CreateHisto();
167  return kSUCCESS;
168 
169 }
Double_t BBoxNum()
Definition: PndGeoDrc.h:136
TClonesArray * fDrcLutInfoArray
Double_t Lside()
Definition: PndGeoDrc.h:184
Double_t BarWidth()
Definition: PndGeoDrc.h:100
Double_t BBoxGap()
Definition: PndGeoDrc.h:130
Double_t barBoxZDown()
Definition: PndGeoDrc.h:104
Double_t PipehAngle()
Definition: PndGeoDrc.h:139
Double_t barBoxZUp()
Definition: PndGeoDrc.h:108
Double_t barHalfThick()
Definition: PndGeoDrc.h:96
Double_t Pi
Double_t barNum()
Definition: PndGeoDrc.h:124
Double_t radius()
Definition: PndGeoDrc.h:92
PndGeoDrc * fGeo
Basic geometry data of barrel DRC.
Int_t PndDrcRecoLookupMapS::NumberOfBounces ( TVector3  start,
TVector3  dir,
Int_t  barId 
)
private

Definition at line 563 of file PndDrcRecoLookupMapS.cxx.

References CAMath::Cos(), Double_t, fabs(), fBarWidth, fGeoH, fHThick, FindOutPoint(), fzdown, fzup, PndGeoHandling::MasterToLocalShortId(), CAMath::Sin(), and CAMath::Tan().

Referenced by ProcessPhotonHit().

563  {
564  // start - photon production point in global coord system
565  // dir - photon direction in bar coord system
566 
567  //cout<<"-I- NumberOfBounces: dir"<<endl;
568  //dir.Print();
569  //cout<<"-I- NumberOfBounces: start"<<endl;
570  //start.Print();
571 
572  // Find coordinates of X0, Y0:
573  Double_t Z0, X0, Y0;
574  if(dir.Theta() < 3.1415/2.){
575  Z0 = -(fabs(fzup) + 2.*fzdown - start.Z());
576  }
577  if(dir.Theta() >= 3.1415/2.){
578  Z0 = -(start.Z() - fzup);
579  }
580  X0 = Z0*TMath::Tan(dir.Theta())*TMath::Cos(dir.Phi());
581  Y0 = Z0*TMath::Tan(dir.Theta())*TMath::Sin(dir.Phi());
582  //cout<<"-I- NumberOfBounces: tan th = "<<TMath::Tan(dir.Theta())<<", sin ph = "<<TMath::Sin(dir.Phi())<<", cos ph = "<<TMath::Cos(dir.Phi())<<endl;
583  //cout<<"-I- NumberOfBounces: X0 = "<<X0<<", Y0 = "<<Y0<<", Z0 = "<<Z0<<endl;
584 
585  // Find the start position of the photon with respect to the middle of the bar:
586  TVector3 startLocal = fGeoH->MasterToLocalShortId(start, barId); // point
587  //cout<<"-I- NumberOfBounces: Xen = "<<startLocal.X() + fBarWidth/2.<<", Yen = "<<startLocal.Y() + fHThick<<endl;
588 
589  // Find the number of bounces in each direction
590  Double_t N1, N2;
591  FindOutPoint(X0, startLocal.X() + fBarWidth/2., fBarWidth, &N1, 0);
592  FindOutPoint(Y0, startLocal.Y() + fHThick, 2.*fHThick, &N2, 0);
593  //cout<<"-I- NumberOfBounces: N1 = "<<N1<<", N2 = "<<N2<<endl;
594 
595  return (Int_t)N1+N2;
596 }
static T Sin(const T &x)
Definition: PndCAMath.h:42
float Tan(float x)
Definition: PndCAMath.h:165
static T Cos(const T &x)
Definition: PndCAMath.h:43
Double_t
friend F32vec4 fabs(const F32vec4 &a)
Definition: P4_F32vec4.h:47
TVector3 MasterToLocalShortId(const TVector3 &master, const Int_t &shortId)
Double_t FindOutPoint(Double_t, Double_t, Double_t, Double_t *, Bool_t)
void PndDrcRecoLookupMapS::ProcessBarHit ( )
private

Definition at line 223 of file PndDrcRecoLookupMapS.cxx.

References fBarPointArray, fHitArray, fMCArray, PndDrcHit::GetRefIndex(), hit, pt(), and tr.

224 {
225  PndDrcBarPoint* pt=NULL;
226  PndDrcHit* hit=NULL;
227  PndMCTrack* tr = NULL;
228 
229  for(Int_t j=0; j<fHitArray->GetEntriesFast(); j++) {
230  hit = (PndDrcHit*)fHitArray->At(j);
231  Int_t mcRef= hit->GetRefIndex();
232  pt= (PndDrcBarPoint*)fBarPointArray->At(mcRef);
233 
234  Int_t chtrID= pt->GetTrackID();
235  tr = (PndMCTrack*)fMCArray->At(chtrID);
236 
237  cout<<"nother track px = "<<pt->GetPx()<<", py = "<<pt->GetPy()<<endl;
238 
239  }
240 }
TString pt(TString pts, TString exts="px py pz")
Definition: invexp.C:133
virtual Int_t GetRefIndex()
Definition: PndDrcHit.h:44
PndSdsMCPoint * hit
Definition: anasim.C:70
void PndDrcRecoLookupMapS::ProcessPhotonHit ( )
private

Definition at line 243 of file PndDrcRecoLookupMapS.cxx.

References acos(), PndDrcLutInfo::AddAngle(), PndDrcLutInfo::AddChDiff(), PndDrcLutInfo::AddHitTime(), PndDrcLutInfo::AddLambda(), PndDrcLutInfo::AddNOfBounces(), PndDrcLutInfo::AddPath(), PndDrcLutInfo::AddTime(), PndDrcLutInfo::AddTruePath(), CHexp, CHreal, Double_t, fabs(), fB, fBarId, fBarPointArray, fBBver1, fBBver2, fBBver3, fBBver4, fDigiPar, fDrcLutInfoArray, fGeo, fGeoH, fHAngleInBDeg, fkBar, fkxBar, fkyBar, fkzBar, flambdah, fMCArray, fnX1, fnY1, fPath, fPDHitArray, fPDPointArray, fPhiMap, fPhiRot, fpi, fpixID, fPMo, fPMoB, fPphoB, fPphoInit, fPphoPD, fR, fStartVertex, fThetaMap, ftime, ftime0, fVerbose, fxPHit, fyPHit, fzPHit, PndDrcPDPoint::GetBarPointID(), PndMCTrack::GetMomentum(), PndMCTrack::GetMotherID(), PndDrcDigiPar::GetNAmbiguities(), PndDrcDigiPar::GetNHitPixels(), PndDrcDigiPar::GetNPixelParam(), PndDrcDigiPar::GetParamsForPixel(), PndMCTrack::GetPdgCode(), PndDrcPDHit::GetRefIndex(), PndMCTrack::GetStartTime(), PndMCTrack::GetStartVertex(), PndDrcPDHit::GetTime(), i, InBarCoordSyst(), PndGeoHandling::MasterToLocalShortId(), NAmb, NHitPix, CAMath::Nint(), NPixPar, PndGeoDrc::nQuartz(), NumberOfBounces(), par, Pi, RecoAmbigTime(), PndDrcLutInfo::SetCherenkovMC(), PndDrcLutInfo::SetCherenkovReal(), PndDrcLutInfo::SetChPartDir(), PndDrcLutInfo::SetChPartDirInBar(), PndDrcLutInfo::SetChPartDirInBar2(), PndDrcLutInfo::SetChPartPdg(), sqrt(), and tr.

Referenced by Exec().

244 {
245  //Int_t nofChPho = 0;
246  fDrcLutInfoArray->Clear();
247  PndDrcLutInfo lutinfo;
248 
249  PndDrcPDPoint* Ppt=NULL;
250  PndDrcPDHit* pdhit=NULL;
251  PndMCTrack* tr = NULL;
252  PndMCTrack* trMr;
253 
254  if (fVerbose > 0) {
255  cout <<"PndDrcRecoLookupMapS: Number of Detected Photon MCPDPoints : "<<fPDPointArray->GetEntries()<<endl;
256  cout <<"PndDrcRecoLookupMapS: Number of Detected Photon PDHits : "<<fPDHitArray->GetEntries()<<endl;
257  }
258 
259  // Loop over PndDrcPDHits
260  for(Int_t k=0; k<fPDHitArray->GetEntriesFast(); k++) {
261 
262  pdhit = (PndDrcPDHit*)fPDHitArray->At(k);
263 
264  Int_t mcPDRef= pdhit->GetRefIndex();
265 
266  if(mcPDRef < 0)continue;
267  Ppt = (PndDrcPDPoint*)fPDPointArray->At(mcPDRef);
268 
269  if(Ppt->GetBarPointID() < 0) continue;
270  PndDrcBarPoint *fBarPoint= (PndDrcBarPoint*)fBarPointArray->At(Ppt->GetBarPointID());
271  fBarId = fBarPoint->GetDetectorID();
272  if(fBarId < 0)continue;
273  //cout<<"bar name - "<<fGeoH->GetPath(fBarId)<<endl;
274 
275  Int_t trID= Ppt->GetTrackID();
276  tr = (PndMCTrack*)fMCArray->At(trID);
277 
278  Int_t trMID=tr->GetMotherID();
279 
280  //if(trMID > -1){
281  trMr = (PndMCTrack*)fMCArray->At(trMID);
282  Int_t trMpdg=trMr->GetPdgCode();
283 
284  if(trMr->GetMotherID()==-1){ // charged track is a primary
285 
286  lutinfo.SetChPartPdg(trMpdg);
287 
288  // expected cherenkov angle
289  Double_t Mrmass;
290  Int_t MoSign;
291  if(fabs(trMpdg) == 11){Mrmass = 0.000511; MoSign = 1;}
292  if(fabs(trMpdg) == 13){Mrmass = 0.105658; MoSign = 1;}
293  if(fabs(trMpdg) == 211){Mrmass = 0.139570; MoSign = -1;}
294  if(fabs(trMpdg) == 321){Mrmass = 0.49368; MoSign = -1;}
295  if(fabs(trMpdg) == 2212){Mrmass = 0.938; MoSign = -1;}
296  if(fabs(trMpdg) == 50000050){Mrmass = 0.0; MoSign = -1;}
297  Double_t Mrmom = trMr->GetMomentum().Mag();
298  CHexp = acos(sqrt(pow(Mrmom,2) + pow(Mrmass,2))/Mrmom/fGeo->nQuartz());
299  lutinfo.SetCherenkovMC(CHexp);
300  //cout<<"+++++++++++++++++++++++++++"<<endl;
301  //cout<<"CH expected = "<<CHexp<<endl;
302 
303  fxPHit= pdhit->GetX();
304  fyPHit= pdhit->GetY();
305  fzPHit= pdhit->GetZ();
306  ftime = pdhit->GetTime();
307  //ftime = Ppt->GetTime();
308 
309  //get the pixel id
310  fpixID = pdhit->GetDetectorID();
311  if(fpixID<0)continue;
312 
313  //cout<<"hit id "<<fpixID<<", x = "<<pdhit->GetX()<<", y = "<<pdhit->GetY()<<", time = "<<ftime<<endl;
314 
315  Double_t xPPoi= Ppt->GetX();
316  Double_t yPPoi= Ppt->GetY();
317 
318  lutinfo.AddTruePath(Ppt->GetLength());
319 
320  // momentum of a photon on the PD Plane
321  fPphoPD.SetXYZ(Ppt->GetPx(), Ppt->GetPy(), Ppt->GetPz());
322 
323  {
324  // mother momentum/direction
325  fPMo.SetXYZ(trMr->GetMomentum().X(), trMr->GetMomentum().Y(), trMr->GetMomentum().Z());
326  //fPMo.Print();
327  lutinfo.SetChPartDir(fPMo);
328  //cout<<"mother phi = "<<fPMo.Phi()/3.1415*180.<<endl;
329  if(fB > 0.){
330  Double_t PtMo = sqrt(pow(trMr->GetMomentum().X(),2)+pow(trMr->GetMomentum().Y(),2));
331  Double_t Rratio = fR*fR/2./pow((PtMo/0.29979/fB)*100.,2);
332  Double_t phi_extra = fPMo.Phi() + MoSign * trMpdg/fabs(trMpdg) * acos(1. - Rratio);
333  fHAngleInBDeg = 0.5 * MoSign * trMpdg/fabs(trMpdg) * (acos(1. - Rratio) /TMath::Pi())*180.;
334  //cout<<"B = "<<fB<<", R = "<<fR<<", trMpdg = "<<trMpdg<<", half angle in B = "<<fHAngleInBDeg<<endl;
335  fPMo.SetPhi(phi_extra);
336  }
337  lutinfo.SetChPartDirInBar2(fPMo);
338  }
339 
340  {
341  //mother momentum/direction from the bar point
342  fBarPoint->Momentum(fPMo);
343  lutinfo.SetChPartDirInBar(fPMo);
344  }
345 
346  //cout<<"Mother vector (global cs) : "<<endl;
347  TVector3 motherMom = fPMo.Unit();
348  //motherMom.Print();
349 
350  // initial momentum of the photon
351  fPphoInit = tr->GetMomentum();
352  //cout<<"Initial momentum of the photon :"<<endl;
353  //fPphoInit.Print();
354 
355  // real = generated cherenkov angle
356  CHreal = fPphoInit.Angle(fPMo);
357  lutinfo.SetCherenkovReal(CHreal);
358  //cout<<"CH real (generated) = "<<CHreal<<endl;
359 
360  Double_t etot = sqrt(pow(fPphoPD.X(),2) + pow(fPphoPD.Y(),2) +pow(fPphoPD.Z(),2));
361  flambdah=197.0*2.0*TMath::Pi()/(etot*1.0E9);//wavelength of photon in nm
362  lutinfo.AddLambda(flambdah);
363 
364  // production point of the photon
366 
367  //cout<<"start: phi = "<<fStartVertex.Phi()<<endl;
368  //fStartVertex.Print();
369  ftime0 = tr->GetStartTime()/1.0E9;
370  lutinfo.AddHitTime(ftime-ftime0);
371 
372  //cout<<"fstart time = "<<ftime0<<endl;
373  //$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$
374  // proceed only if photon was born in the bar for which the LUT is used!!!
375  //if(fStartVertex.Phi() >0./180.*fpi && fStartVertex.Phi() < 6./180.*fpi){
376  if(fPphoInit.Z() > 0. || fPphoInit.Z() < 0.){ // reflected photons
377 
378  // Transformation of the photon initial direction to the local bar coodr system:
379  // to get to the bar coord system.
381 
382  // Photon initial momentum in the bar coord. syst.
383  fPphoB = (fGeoH->MasterToLocalShortId(fPphoInit, fBarId) - fGeoH->MasterToLocalShortId((0.,0.,0.),fBarId)).Unit(); // vector
384  //fPphoB.Print();
385 
386  // mother momentum in the bar' (and bar) coord syst:
387  fPMoB = (fGeoH->MasterToLocalShortId(fPMo, fBarId) - fGeoH->MasterToLocalShortId((0.,0.,0.),fBarId)).Unit(); // vector
388  //PMBar.Print();
389 
390  // to find Cherenkov Phi (NOT THETA!!!):
391  TVector3 kB;
392  kB.SetXYZ(fkxBar, fkyBar, fkzBar);
393 
394  // use lookups to get the kXbar and kYbar of photons:
396  //cout<<"N pixels = "<<NHitPix<<endl;
398  //cout<<"N amb = "<<NAmb<<endl;
400  Double_t par[NPixPar];
401 
402  if (fDigiPar->GetParamsForPixel(fpixID, par) == kFALSE) {
403  cout<<"NO SUCH HIT IN LUT!!!"<<endl;
404  continue;
405  }
406 
407  //cout<<"LOOKUP!!!!"<<endl;
408  //cout<<"N Hit Pix = "<<NHitPix<<endl;
409  //cout<<"N Amb = "<<NAmb<<endl;
410  //cout<<"NPixPar = "<<NPixPar<<endl;
411 /* cout<<"par 0 = "<<par[0]<<endl; // kx
412  cout<<"par 1 = "<<par[1]<<endl; // ky
413  cout<<"par 2 = "<<par[2]<<endl; // kxB
414  cout<<"par 3 = "<<par[3]<<endl; // kyB
415  cout<<"par 4 = "<<par[4]<<endl; // kxU1
416  cout<<"par 5 = "<<par[5]<<endl; // kyU1
417  cout<<"par 6 = "<<par[6]<<endl; // kxU2
418  cout<<"par 7 = "<<par[7]<<endl; // kyU2
419  cout<<"par 8 = "<<par[8]<<endl; // kxU3
420  cout<<"par 9 = "<<par[9]<<endl; // kyU3
421  cout<<"par 10 = "<<par[10]<<endl; // kxBU1
422  cout<<"par 11 = "<<par[11]<<endl; // kyBU1
423  cout<<"par 12 = "<<par[12]<<endl; // kxBU2
424  cout<<"par 13 = "<<par[13]<<endl; // kyBU2
425  cout<<"par 14 = "<<par[14]<<endl; // kxBU3
426  cout<<"par 15 = "<<par[15]<<endl; // kyBU3
427  cout<<"par 16 = "<<par[16]<<endl; // kxUB
428  cout<<"par 17 = "<<par[17]<<endl; // kyUB
429  cout<<"par 18= "<<par[18]<<endl; // kxUU
430  cout<<"par 19= "<<par[19]<<endl; // kyUU
431  cout<<"par 20= "<<par[20]<<endl; // kxUUU
432  cout<<"par 21= "<<par[21]<<endl; // kyUUU
433  cout<<"par 22= "<<par[22]<<endl; // kxBUU
434  cout<<"par 23= "<<par[23]<<endl; // kyBUU
435  cout<<"par 24= "<<par[24]<<endl; // kxBUB
436  cout<<"par 25= "<<par[25]<<endl; // kyBUB
437  cout<<"par 26= "<<par[26]<<endl; // kxUBU
438  cout<<"par 27= "<<par[27]<<endl; // kyUBU
439 */
440  // fill in NPixPar/2 * 1 ambiguities:
441  Double_t kX, kY, kZ;
442  std::vector<TVector3> ambig;
443  std::vector<Double_t> CHreco;
444  std::vector<Double_t> Tamb;
445  std::vector<Double_t> Path;
446 
447  // length of the vector should be the same as NumAmb*8 !!!!!
448  Int_t NumAmb = NAmb; //=14
449  TVectorD CHdiff(8*NumAmb);
450  TVectorD Adiff(8*NumAmb); // vector to store angle diff btw real and reco photons
451 
452  for(Int_t i=0; i<NumAmb; i++){
453  // in bar' coordinate system
454  kX = par[i*2]; // kXD
455  kY = par[i*2 + 1]; // kYD
456  kZ = -sqrt(1. - pow(kX,2.) - pow(kY,2.));
457  //cout<<"mom: x = "<<fPMoB.X()<<", y = "<<fPMoB.Y()<<", z = "<<fPMoB.Z()<<endl;
458  fkBar.SetXYZ(kX, kY, kZ);
459  //cout<<"photon from LUT in bar' coordinate system: "<<endl;
460  //fkBar.Print();
461 
462  for(Int_t jamb=0; jamb <8; jamb++){
463  if(jamb == 1){fkBar.SetXYZ(-kX, kY, kZ);}
464  if(jamb == 2){fkBar.SetXYZ(kX, -kY, kZ);}
465  if(jamb == 3){fkBar.SetXYZ(kX, kY, -kZ);}
466  if(jamb == 4){fkBar.SetXYZ(-kX, -kY, kZ);}
467  if(jamb == 5){fkBar.SetXYZ(kX, -kY, -kZ);}
468  if(jamb == 6){fkBar.SetXYZ(-kX, kY, -kZ);}
469  if(jamb == 7){fkBar.SetXYZ(-kX, -kY, -kZ);}
470 
471  // check if there is such enrty in the LUT and if the ambiguity fulfills the total internal reflection requitrement
472  if((kX != 0. && kY != 0.) && ((fkBar.Cross(fnX1)).Mag() > 1.00028/fGeo->nQuartz() ||
473  (fkBar.Cross(fnY1)).Mag() > 1.00028/fGeo->nQuartz())){
474  ambig.push_back(fkBar);
475  CHreco.push_back(fkBar.Angle(fPMoB));
476  CHdiff(8*i+jamb) = fabs(CHreco[8*i+jamb] - CHexp);
477  Tamb.push_back(RecoAmbigTime(fkBar, fStartVertex, &fPath, 0));
478  Path.push_back(fPath);
479  Adiff(8*i+jamb) = fkBar.Angle(fPphoB);
480  //cout<<"reco ch angle = "<<fkBar.Angle(fPMoB)<<endl;
481  //cout<<"number of bounces = "<<NumberOfBounces(fStartVertex, fPphoB, fBarId)<<endl;
482  //cout<<"CHdiff = "<<CHdiff(8*i+jamb)<<", CHreco"<<8*i+jamb<<" = "<<CHreco[8*i+jamb]<<endl;
483 
484  //fill only with credible information:
485  lutinfo.AddAngle(fkBar.Angle(fPMoB));
486  lutinfo.AddTime(RecoAmbigTime(fkBar, fStartVertex, &fPath, 0));
487  lutinfo.AddPath(fPath);
488  lutinfo.AddChDiff(CHreco[8*i+jamb] - CHexp);
489  //cout<<"fkBar = "<<endl;
490  //fkBar.Print();
491  lutinfo.AddNOfBounces(NumberOfBounces(fStartVertex, fkBar/*fPphoB*/, fBarId));
492 
493  //fkBarXHist->Fill(kX, fPphoB.X());
494  //fkBarYHist->Fill(kY, fPphoB.Y());
495  }else{
496  ambig.push_back((0.,0.,0.));
497  CHreco.push_back(-999.);
498  CHdiff(8*i+jamb) = -999.;
499  Tamb.push_back(-999.);
500  Path.push_back(-999.);
501  Adiff(8*i+jamb) = -999.;
502  }
503  }// for
504  }
505 
506  fPhiMap = TMath::Nint(fPMo.Phi()/fpi*180.);
507  fThetaMap = TMath::Nint(fPMo.Theta()/fpi*180.);
508  //cout<<"phi = "<<fPMo.Phi()/fpi*180.<<", phi map = "<<fPhiMap<<", theta map = "<<fThetaMap<<endl;
509 
510  if(fB > 0.){
511  // fMapHist->Fill(fThetaMap,fPhiMap-fHAngleInBDeg); // assuming that R = 50 cm
512  }
513  if(fB == 0.){
514  // fMapHist->Fill(fThetaMap,fPhiMap);
515  }
516  } // if start vertex lies within the right bar!
517  }// photon from primary particle
518 
519  }// photon hits
520  new ((*fDrcLutInfoArray)[fDrcLutInfoArray->GetEntriesFast()]) PndDrcLutInfo(lutinfo);
521 }
void SetChPartDirInBar2(TVector3 val)
friend F32vec4 acos(const F32vec4 &a)
Definition: P4_F32vec4.h:113
void AddChDiff(Double_t val)
void AddHitTime(Double_t val)
Double_t RecoAmbigTime(TVector3, TVector3, Double_t *, Bool_t)
Int_t GetNPixelParam()
Definition: PndDrcDigiPar.h:45
Double_t InBarCoordSyst(TVector3, TVector3 *, TVector3 *, TVector3 *, TVector3 *)
Int_t i
Definition: run_full.C:25
friend F32vec4 sqrt(const F32vec4 &a)
Definition: P4_F32vec4.h:29
TClonesArray * fDrcLutInfoArray
Bool_t GetParamsForPixel(Int_t, Double_t *)
Int_t GetPdgCode() const
Definition: PndMCTrack.h:73
Double_t par[3]
TVector3 GetMomentum() const
Definition: PndMCTrack.h:78
void SetChPartPdg(Int_t val)
Int_t NumberOfBounces(TVector3, TVector3, Int_t)
void SetChPartDirInBar(TVector3 val)
virtual Double_t GetTime()
Definition: PndDrcPDHit.h:55
void SetCherenkovReal(Double_t val)
Int_t GetBarPointID() const
Definition: PndDrcPDPoint.h:56
virtual Int_t GetRefIndex()
Definition: PndDrcPDHit.h:57
void AddLambda(Double_t val)
void AddAngle(Double_t val)
void SetChPartDir(TVector3 val)
Double_t
Double_t nQuartz()
Definition: PndGeoDrc.h:70
void AddTime(Double_t val)
void AddNOfBounces(Double_t val)
void AddTruePath(Double_t val)
friend F32vec4 fabs(const F32vec4 &a)
Definition: P4_F32vec4.h:47
void SetCherenkovMC(Double_t val)
TVector3 MasterToLocalShortId(const TVector3 &master, const Int_t &shortId)
Int_t GetNAmbiguities()
Definition: PndDrcDigiPar.h:44
Int_t GetNHitPixels()
Definition: PndDrcDigiPar.h:43
void AddPath(Double_t val)
TVector3 GetStartVertex() const
Definition: PndMCTrack.h:76
Int_t GetMotherID() const
Definition: PndMCTrack.h:74
Double_t Pi
int Nint(float x)
Definition: PndCAMath.h:117
Double_t GetStartTime() const
Definition: PndMCTrack.h:77
PndGeoDrc * fGeo
Basic geometry data of barrel DRC.
void PndDrcRecoLookupMapS::ProcessPhotonMC ( )
private

Definition at line 213 of file PndDrcRecoLookupMapS.cxx.

References fMCArray, and fVerbose.

214 {
215  if (fVerbose > 0) {
216  cout <<"PndDrcRecoLookupMapS: Number of Detected MC Tracks : "<<fMCArray->GetEntries()<<endl;
217  PndMCTrack* ptr = NULL;
218  PndMCTrack* trMr=NULL;
219 
220  }
221 }
Double_t PndDrcRecoLookupMapS::RecoAmbigTime ( TVector3  kb,
TVector3  start,
Double_t l,
Bool_t  printout 
)
private

Definition at line 644 of file PndDrcRecoLookupMapS.cxx.

References PndGeoDrc::barBoxZDown(), PndGeoDrc::barBoxZUp(), cos(), Double_t, PndGeoDrc::EVlen(), fabs(), fGeo, fpi, L1, PndGeoDrc::nEV(), PndGeoDrc::nQuartz(), and sin().

Referenced by ProcessPhotonHit().

644  { // [ns]
645 
646  // group velocities for oil and quartz for Noil and Nquartz assuming that mean lambda = 410 nm:
647  //Double_t nOil = fGeo->nEV();
648  Double_t u_oil = 19.8;//30./nOil;
649  //Double_t u_quartz = 30./1.46907; // for lambda = 410 nm
650  //Double_t u_quartz = 30./1.47012; // for lambda = 400 nm
651  //Double_t u_quartz = 30./1.46838; // for lambda = 417 nm
652  //Double_t u_quartz = 30./1.47125; // for lambda = 390 nm
653  //Double_t u_quartz = 30./1.47248; // for lambda = 380 nm
654  Double_t u_quartz = 20.;//30./fNquartz;//1.47805; // for lambda = 400 nm
655 
656  // kb - photon momentum at the production point, first calculate path in QUARTZ BAR:
657  // assume that there are only DIRECT photons!!!
658 
659  // path in quartz:
660  Double_t Z0 = 0.;
661  Double_t kz = 0.;
662  if(kb.Z() < 0.){Z0 = start.Z() - fGeo->barBoxZUp(); kz = kb.Z();}
663  if(kb.Z() >= 0.){Z0 = 2.*fGeo->barBoxZDown() - fGeo->barBoxZUp() - start.Z(); kz = -kb.Z();}
664 
665  if(printout){
666  cout<<"-I- Reco ambig Time: Zstart = "<<start.Z()<<", Z0 = "<<Z0<<endl;
667  }
668 
669  Double_t L0 = Z0/fabs(cos(kb.Theta()));
670  kb.SetZ(kz);
671  Double_t thetaOil = asin(fGeo->nQuartz()/fGeo->nEV()*sin(kb.Theta()));
672  if(printout){
673  cout<<"RECO ambig TIME: thetas are: quartz = "<<kb.Theta()/fpi*180.<<", oil = "<<thetaOil/fpi*180.<<endl;
674  }
675  kb.SetTheta(thetaOil);
676  Double_t Z1 = fGeo->EVlen();
677  Double_t L1 = Z1/fabs(cos(kb.Theta())); // path in oil
678 
679  if(printout){
680  cout<<"-I- Reco ambig Time: Zev = "<<fGeo->EVlen()<<endl;
681  cout<<"-I- Reco ambig Time: L0 = "<<L0<<", L1 = "<<L1<<endl;
682  cout<<"-I- Reco ambig Time: time is "<< L0/u_quartz + L1/u_oil <<endl; // 19.5 cm/ns - average (lambda) group speed
683  }
684 
685  *l = L0 + L1;
686 
687  return L0/u_quartz + L1/u_oil; //[ns]
688 }
Double_t nEV()
Definition: PndGeoDrc.h:76
friend F32vec4 cos(const F32vec4 &a)
Definition: P4_F32vec4.h:112
friend F32vec4 sin(const F32vec4 &a)
Definition: P4_F32vec4.h:111
Double_t EVlen()
Definition: PndGeoDrc.h:127
Double_t barBoxZDown()
Definition: PndGeoDrc.h:104
Double_t barBoxZUp()
Definition: PndGeoDrc.h:108
Double_t
Double_t nQuartz()
Definition: PndGeoDrc.h:70
friend F32vec4 fabs(const F32vec4 &a)
Definition: P4_F32vec4.h:47
Int_t L1[1]
Definition: Pnd_Hc_ee7G.C:50
PndGeoDrc * fGeo
Basic geometry data of barrel DRC.
void PndDrcRecoLookupMapS::SetDefaultParameters ( )
private

Set the parameters to the default values.

void PndDrcRecoLookupMapS::SetHistoWidth ( double  wid = 0.01)
inline

Definition at line 70 of file PndDrcRecoLookupMapS.h.

References fWidth.

70 {fWidth = wid;} // 0.01
void PndDrcRecoLookupMapS::SetMagneticField ( double  mag = 0.)
inline

Definition at line 72 of file PndDrcRecoLookupMapS.h.

References fB.

72 {fB = mag;} // [Tesla]
void PndDrcRecoLookupMapS::SetNSigma ( double  nsig = 3.)
inline

Definition at line 71 of file PndDrcRecoLookupMapS.h.

References fNSigma, and nsig.

71 {fNSigma = nsig;}
int nsig
Definition: toy_core.C:46
void PndDrcRecoLookupMapS::SetOutputFile ( TString  outName = "PndDrcRecoLookupMapS_output.root")
inline

Definition at line 73 of file PndDrcRecoLookupMapS.h.

References fOutputName.

73 {fOutputName = outName;}
void PndDrcRecoLookupMapS::SetParContainers ( )
privatevirtual

Definition at line 172 of file PndDrcRecoLookupMapS.cxx.

References fDigiPar, fGeoH, fVerbose, PndDrcDigiPar::GetNAmbiguities(), PndGeoHandling::Instance(), run, and PndGeoHandling::SetParContainers().

172  {
173 
174  // Get run and runtime database
175  FairRunAna* run = FairRunAna::Instance();
176  if ( ! run ) Fatal("SetParContainers", "No analysis run");
177 
178  FairRuntimeDb* db = run->GetRuntimeDb();
179  if ( ! db ) Fatal("SetParContainers", "No runtime database");
180 
181  // Get DIRC digitisation parameter container
182  fDigiPar = (PndDrcDigiPar*)(db->getContainer("DIRCLookupTable"));
183  cout << "-I- PndDrcRecoLookupMapS::SetParContainers(). read parameters" << endl;
184  cout<<"read them!"<<endl;
185  //cout << "-I- PndDrcRecoLookupMapS: Number of hit pixels "<< fDigiPar->GetNHitPixels()<< endl;
186  cout << "-I- PndDrcRecoLookupMapS: Number of hit pixels "<< fDigiPar->GetNAmbiguities()<< endl;
187 
188  if ( fGeoH == NULL ) fGeoH = PndGeoHandling::Instance();
190  if(fVerbose>1) Info("SetParContainers","done.");
191  return;
192 }
Int_t run
Definition: autocutx.C:47
virtual void SetParContainers()
static PndGeoHandling * Instance()
Int_t GetNAmbiguities()
Definition: PndDrcDigiPar.h:44
Digitization Parameter Class for DIRC barrel part.
Definition: PndDrcDigiPar.h:29
void PndDrcRecoLookupMapS::WriteToFile ( )
private

Definition at line 693 of file PndDrcRecoLookupMapS.cxx.

Referenced by Finish().

693 {}

Member Data Documentation

Double_t PndDrcRecoLookupMapS::CHexp
private

Definition at line 180 of file PndDrcRecoLookupMapS.h.

Referenced by ProcessPhotonHit().

Double_t PndDrcRecoLookupMapS::CHreal
private

Definition at line 181 of file PndDrcRecoLookupMapS.h.

Referenced by ProcessPhotonHit().

Double_t PndDrcRecoLookupMapS::fB
private

Definition at line 148 of file PndDrcRecoLookupMapS.h.

Referenced by ProcessPhotonHit(), and SetMagneticField().

Double_t PndDrcRecoLookupMapS::fBarBoxGap
private

Definition at line 96 of file PndDrcRecoLookupMapS.h.

Referenced by Init().

Int_t PndDrcRecoLookupMapS::fBarId
private

Definition at line 168 of file PndDrcRecoLookupMapS.h.

Referenced by ProcessPhotonHit().

Double_t PndDrcRecoLookupMapS::fBarNum
private

Definition at line 94 of file PndDrcRecoLookupMapS.h.

Referenced by Init().

TClonesArray* PndDrcRecoLookupMapS::fBarPointArray
private

Definition at line 117 of file PndDrcRecoLookupMapS.h.

Referenced by Init(), ProcessBarHit(), and ProcessPhotonHit().

Double_t PndDrcRecoLookupMapS::fBarWidth
private

Definition at line 98 of file PndDrcRecoLookupMapS.h.

Referenced by Init(), and NumberOfBounces().

Double_t PndDrcRecoLookupMapS::fBboxNum
private

Definition at line 93 of file PndDrcRecoLookupMapS.h.

Referenced by Init().

TVector3 PndDrcRecoLookupMapS::fBBver1
private

Definition at line 190 of file PndDrcRecoLookupMapS.h.

Referenced by ProcessPhotonHit().

TVector3 PndDrcRecoLookupMapS::fBBver2
private

Definition at line 191 of file PndDrcRecoLookupMapS.h.

Referenced by ProcessPhotonHit().

TVector3 PndDrcRecoLookupMapS::fBBver3
private

Definition at line 192 of file PndDrcRecoLookupMapS.h.

Referenced by ProcessPhotonHit().

TVector3 PndDrcRecoLookupMapS::fBBver4
private

Definition at line 193 of file PndDrcRecoLookupMapS.h.

Referenced by ProcessPhotonHit().

Float_t PndDrcRecoLookupMapS::fchdiff
private

Definition at line 103 of file PndDrcRecoLookupMapS.h.

Double_t PndDrcRecoLookupMapS::fCHrecoMax
private

Definition at line 146 of file PndDrcRecoLookupMapS.h.

Double_t PndDrcRecoLookupMapS::fCHrecoMin
private

Definition at line 145 of file PndDrcRecoLookupMapS.h.

Int_t PndDrcRecoLookupMapS::fDetectorID
private

Definition at line 115 of file PndDrcRecoLookupMapS.h.

Referenced by Exec().

TClonesArray* PndDrcRecoLookupMapS::fDigiArray
private

Definition at line 122 of file PndDrcRecoLookupMapS.h.

Referenced by Init().

PndDrcDigiPar* PndDrcRecoLookupMapS::fDigiPar
private
Double_t PndDrcRecoLookupMapS::fDphi
private

Definition at line 99 of file PndDrcRecoLookupMapS.h.

Referenced by InBarCoordSyst(), and Init().

TClonesArray* PndDrcRecoLookupMapS::fDrcLutInfoArray
private

Definition at line 125 of file PndDrcRecoLookupMapS.h.

Referenced by Init(), and ProcessPhotonHit().

PndGeoDrc* PndDrcRecoLookupMapS::fGeo
private

Basic geometry data of barrel DRC.

Definition at line 129 of file PndDrcRecoLookupMapS.h.

Referenced by Init(), PndDrcRecoLookupMapS(), ProcessPhotonHit(), RecoAmbigTime(), and ~PndDrcRecoLookupMapS().

PndGeoHandling* PndDrcRecoLookupMapS::fGeoH
private
Double_t PndDrcRecoLookupMapS::fHAngleInBDeg
private

Definition at line 143 of file PndDrcRecoLookupMapS.h.

Referenced by ProcessPhotonHit().

TList* PndDrcRecoLookupMapS::fHistoList
private

Definition at line 127 of file PndDrcRecoLookupMapS.h.

Referenced by ~PndDrcRecoLookupMapS().

TClonesArray* PndDrcRecoLookupMapS::fHitArray
private

Definition at line 119 of file PndDrcRecoLookupMapS.h.

Referenced by ProcessBarHit().

Double_t PndDrcRecoLookupMapS::fHThick
private

Definition at line 92 of file PndDrcRecoLookupMapS.h.

Referenced by InBarCoordSyst(), Init(), and NumberOfBounces().

TVector3 PndDrcRecoLookupMapS::fkBar
private

Definition at line 166 of file PndDrcRecoLookupMapS.h.

Referenced by ProcessPhotonHit().

Double_t PndDrcRecoLookupMapS::fkxBar
private

Definition at line 177 of file PndDrcRecoLookupMapS.h.

Referenced by ProcessPhotonHit().

Double_t PndDrcRecoLookupMapS::fkyBar
private

Definition at line 177 of file PndDrcRecoLookupMapS.h.

Referenced by ProcessPhotonHit().

Double_t PndDrcRecoLookupMapS::fkzBar
private

Definition at line 177 of file PndDrcRecoLookupMapS.h.

Referenced by ProcessPhotonHit().

Double_t PndDrcRecoLookupMapS::flambdah
private

Definition at line 153 of file PndDrcRecoLookupMapS.h.

Referenced by ProcessPhotonHit().

Double_t PndDrcRecoLookupMapS::fLSide
private

Definition at line 97 of file PndDrcRecoLookupMapS.h.

Referenced by InBarCoordSyst(), and Init().

TClonesArray* PndDrcRecoLookupMapS::fMCArray
private

Definition at line 121 of file PndDrcRecoLookupMapS.h.

Referenced by Init(), ProcessBarHit(), ProcessPhotonHit(), and ProcessPhotonMC().

Double_t PndDrcRecoLookupMapS::fNSigma
private

Definition at line 147 of file PndDrcRecoLookupMapS.h.

Referenced by SetNSigma().

TVector3 PndDrcRecoLookupMapS::fnX1
private

Definition at line 150 of file PndDrcRecoLookupMapS.h.

Referenced by Init(), and ProcessPhotonHit().

TVector3 PndDrcRecoLookupMapS::fnY1
private

Definition at line 151 of file PndDrcRecoLookupMapS.h.

Referenced by Init(), and ProcessPhotonHit().

TString PndDrcRecoLookupMapS::fOutputName
private

Definition at line 140 of file PndDrcRecoLookupMapS.h.

Referenced by SetOutputFile().

Double_t PndDrcRecoLookupMapS::fPath
private

Definition at line 185 of file PndDrcRecoLookupMapS.h.

Referenced by ProcessPhotonHit().

TClonesArray* PndDrcRecoLookupMapS::fPDHitArray
private

Definition at line 120 of file PndDrcRecoLookupMapS.h.

Referenced by Init(), and ProcessPhotonHit().

TClonesArray* PndDrcRecoLookupMapS::fPDPointArray
private

Definition at line 118 of file PndDrcRecoLookupMapS.h.

Referenced by Init(), and ProcessPhotonHit().

Double_t PndDrcRecoLookupMapS::fPhiMap
private

Definition at line 186 of file PndDrcRecoLookupMapS.h.

Referenced by ProcessPhotonHit().

Double_t PndDrcRecoLookupMapS::fPhiRot
private

Definition at line 162 of file PndDrcRecoLookupMapS.h.

Referenced by ProcessPhotonHit().

Double_t PndDrcRecoLookupMapS::fpi
private

Definition at line 88 of file PndDrcRecoLookupMapS.h.

Referenced by InBarCoordSyst(), Init(), ProcessPhotonHit(), and RecoAmbigTime().

Double_t PndDrcRecoLookupMapS::fPipehAngle
private

Definition at line 95 of file PndDrcRecoLookupMapS.h.

Referenced by InBarCoordSyst(), and Init().

Double_t PndDrcRecoLookupMapS::fPixelSize
private

Definition at line 142 of file PndDrcRecoLookupMapS.h.

Double_t PndDrcRecoLookupMapS::fpixID
private

Definition at line 154 of file PndDrcRecoLookupMapS.h.

Referenced by ProcessPhotonHit().

TVector3 PndDrcRecoLookupMapS::fPMo
private

Definition at line 163 of file PndDrcRecoLookupMapS.h.

Referenced by ProcessPhotonHit().

TVector3 PndDrcRecoLookupMapS::fPMoB
private

Definition at line 164 of file PndDrcRecoLookupMapS.h.

Referenced by ProcessPhotonHit().

TVector3 PndDrcRecoLookupMapS::fPphoB
private

Definition at line 182 of file PndDrcRecoLookupMapS.h.

Referenced by ProcessPhotonHit().

TVector3 PndDrcRecoLookupMapS::fPphoInit
private

Definition at line 165 of file PndDrcRecoLookupMapS.h.

Referenced by ProcessPhotonHit().

TVector3 PndDrcRecoLookupMapS::fPphoPD
private

Definition at line 184 of file PndDrcRecoLookupMapS.h.

Referenced by ProcessPhotonHit().

Double_t PndDrcRecoLookupMapS::fPxMoBar
private

Definition at line 178 of file PndDrcRecoLookupMapS.h.

Double_t PndDrcRecoLookupMapS::fPyMoBar
private

Definition at line 178 of file PndDrcRecoLookupMapS.h.

Double_t PndDrcRecoLookupMapS::fPzMoBar
private

Definition at line 178 of file PndDrcRecoLookupMapS.h.

Double_t PndDrcRecoLookupMapS::fR
private

Definition at line 89 of file PndDrcRecoLookupMapS.h.

Referenced by InBarCoordSyst(), Init(), and ProcessPhotonHit().

TVector3 PndDrcRecoLookupMapS::fStartVertex
private

Definition at line 183 of file PndDrcRecoLookupMapS.h.

Referenced by ProcessPhotonHit().

Double_t PndDrcRecoLookupMapS::fThetaMap
private

Definition at line 187 of file PndDrcRecoLookupMapS.h.

Referenced by ProcessPhotonHit().

Double_t PndDrcRecoLookupMapS::ftime
private

Definition at line 160 of file PndDrcRecoLookupMapS.h.

Referenced by ProcessPhotonHit().

Double_t PndDrcRecoLookupMapS::ftime0
private

Definition at line 161 of file PndDrcRecoLookupMapS.h.

Referenced by ProcessPhotonHit().

Int_t PndDrcRecoLookupMapS::fVerbose
private

Verbosity level

Definition at line 136 of file PndDrcRecoLookupMapS.h.

Referenced by Exec(), PndDrcRecoLookupMapS(), ProcessPhotonHit(), ProcessPhotonMC(), and SetParContainers().

Double_t PndDrcRecoLookupMapS::fWeight
private

Definition at line 167 of file PndDrcRecoLookupMapS.h.

Double_t PndDrcRecoLookupMapS::fWidth
private

Definition at line 141 of file PndDrcRecoLookupMapS.h.

Referenced by SetHistoWidth().

Double_t PndDrcRecoLookupMapS::fxbar
private

Definition at line 155 of file PndDrcRecoLookupMapS.h.

Double_t PndDrcRecoLookupMapS::fxnew
private

Definition at line 179 of file PndDrcRecoLookupMapS.h.

Double_t PndDrcRecoLookupMapS::fxPHit
private

Definition at line 157 of file PndDrcRecoLookupMapS.h.

Referenced by ProcessPhotonHit().

Float_t PndDrcRecoLookupMapS::fxx
private

Definition at line 103 of file PndDrcRecoLookupMapS.h.

Double_t PndDrcRecoLookupMapS::fybar
private

Definition at line 156 of file PndDrcRecoLookupMapS.h.

Double_t PndDrcRecoLookupMapS::fynew
private

Definition at line 179 of file PndDrcRecoLookupMapS.h.

Double_t PndDrcRecoLookupMapS::fyPHit
private

Definition at line 158 of file PndDrcRecoLookupMapS.h.

Referenced by ProcessPhotonHit().

Float_t PndDrcRecoLookupMapS::fyy
private

Definition at line 103 of file PndDrcRecoLookupMapS.h.

Double_t PndDrcRecoLookupMapS::fzdown
private

Definition at line 91 of file PndDrcRecoLookupMapS.h.

Referenced by Init(), and NumberOfBounces().

Double_t PndDrcRecoLookupMapS::fzPHit
private

Definition at line 159 of file PndDrcRecoLookupMapS.h.

Referenced by ProcessPhotonHit().

Double_t PndDrcRecoLookupMapS::fzup
private

Definition at line 90 of file PndDrcRecoLookupMapS.h.

Referenced by Init(), and NumberOfBounces().

TTree* PndDrcRecoLookupMapS::mapstree
private

Definition at line 102 of file PndDrcRecoLookupMapS.h.

Int_t PndDrcRecoLookupMapS::NAmb
private

Definition at line 175 of file PndDrcRecoLookupMapS.h.

Referenced by ProcessPhotonHit().

Int_t PndDrcRecoLookupMapS::nevents
private

Definition at line 138 of file PndDrcRecoLookupMapS.h.

Referenced by Exec(), and Init().

Int_t PndDrcRecoLookupMapS::NHitPix
private

Definition at line 173 of file PndDrcRecoLookupMapS.h.

Referenced by ProcessPhotonHit().

Int_t PndDrcRecoLookupMapS::NPixPar
private

Definition at line 174 of file PndDrcRecoLookupMapS.h.

Referenced by ProcessPhotonHit().

Bool_t PndDrcRecoLookupMapS::print
private

Definition at line 170 of file PndDrcRecoLookupMapS.h.


The documentation for this class was generated from the following files: