]> git.uio.no Git - u/mrichter/AliRoot.git/blob - PHOS/AliPHOSPIDv0.h
Detector name is hard-coded in ctor (B.Polichtchouk)
[u/mrichter/AliRoot.git] / PHOS / AliPHOSPIDv0.h
1 #ifndef ALIPHOSPIDV0_H
2 #define ALIPHOSPIDV0_H
3 /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4  * See cxx source for full Copyright notice                               */
5
6 /* $Id$ */
7
8 /* History of cvs commits:
9  *
10  * $Log$
11  * Revision 1.10  2005/05/28 14:19:04  schutz
12  * Compilation warnings fixed by T.P.
13  *
14  */
15
16 //_________________________________________________________________________
17 // Implementation version v0 of the PHOS particle identifier 
18 // Identification is based on information from PPSD and EMC
19 // Oh yeah                 
20 //*-- Author: Yves Schutz (SUBATECH)
21
22 // --- ROOT system ---
23 class TFormula ;
24 class TVector3 ;
25
26 // --- Standard library ---
27
28 // --- AliRoot header files ---
29 class AliPHOSEmcRecPoint ;
30 class AliPHOSRecPoint ;
31
32 #include "AliPHOSPID.h"
33
34 class  AliPHOSPIDv0 : public AliPHOSPID {
35
36 public:
37
38   AliPHOSPIDv0() ;          // ctor            
39   AliPHOSPIDv0(const char* evFolderName, const char * tsBranch = "Default");
40   virtual ~AliPHOSPIDv0() ; // dtor, empty, memory leak in fFormula member
41
42   //Compiler generated should be ok, because destructor is empty.
43   AliPHOSPIDv0(const AliPHOSPIDv0 & rhs);
44   AliPHOSPIDv0 & operator = (const AliPHOSPIDv0 & rhs);
45
46   virtual void Exec(Option_t * option);
47   //  virtual char * GetRecParticlesBranch()const {return (char*) fRecParticlesTitle.Data() ;}      
48   //  virtual char * GetTrackSegmentsBranch()const{return (char*) fTrackSegmentsTitle.Data(); }
49   virtual Int_t GetRecParticlesInRun() const  {return fRecParticlesInRun ;}  
50
51   virtual void PlotDispersionCuts()const ;
52   virtual void Print(const Option_t * = "")const ; 
53   virtual void SetIdentificationMethod(const char * option = "CPV DISP" ){fIDOptions = option ;} 
54   virtual void SetShowerProfileCut(const char * formula = "0.35*0.35 - (x-1.386)*(x-1.386) - 1.707*1.707*(y-1.008)*(y-1.008)") ;
55   virtual void SetDispersionCut(Float_t cut){fDispersion = cut ; } 
56   virtual void SetCpvtoEmcDistanceCut(Float_t cut )      {fCpvEmcDistance = cut ;}
57   virtual void SetTimeGate(Float_t gate)                 {fTimeGate = gate ;}
58   //  virtual void SetTrackSegmentsBranch(const char* title) { fTrackSegmentsTitle = title;}
59   //  virtual void SetRecParticlesBranch (const char* title) { fRecParticlesTitle = title;} 
60   virtual const char * Version() const { return "pid-v0" ; }  
61                      
62  private:
63   
64   virtual void Init() ;
65   void     MakeRecParticles(void ) ;
66   Float_t  GetDistance(AliPHOSEmcRecPoint * emc, AliPHOSRecPoint * cpv, Option_t * Axis)const ; // Relative Distance CPV-EMC
67   TVector3 GetMomentumDirection(AliPHOSEmcRecPoint * emc, AliPHOSRecPoint * cpv)const ;
68   void     PrintRecParticles(Option_t * option) ;
69   virtual void WriteRecParticles(); 
70
71  private:
72
73   TString                fTrackSegmentsTitle; // branch name with track segments
74   TString                fRecPointsTitle ;    // branch name with rec points
75   TString                fRecParticlesTitle ; // branch name with rec particles
76   TString                fIDOptions ;         // PID option
77   Int_t                  fNEvent ;            // current event number
78
79   AliPHOSClusterizer   * fClusterizer ;       // !
80   AliPHOSTrackSegmentMaker * fTSMaker ;       // !
81
82   TFormula             * fFormula ;           // formula to define cut on the shower elips axis
83   Float_t                fDispersion ;        // dispersion cut
84   Float_t                fCpvEmcDistance ;    // Max EMC-CPV distance
85   Float_t                fTimeGate ;          // Time of the latest EmcRecPoint accepted as EM
86   Int_t                  fRecParticlesInRun ; //! Total number of recparticles in one run
87
88   ClassDef( AliPHOSPIDv0,1)  // Particle identifier implementation version 1
89
90 };
91
92 #endif // AliPHOSPIDV0_H