]> git.uio.no Git - u/mrichter/AliRoot.git/blame - PWG4/JCORRAN/AliJPhoton.h
update to run TPC+ITS analysis
[u/mrichter/AliRoot.git] / PWG4 / JCORRAN / AliJPhoton.h
CommitLineData
2f4cac02 1// $Id: AliJPhoton.h,v 1.1 2008/05/02 20:28:14 djkim Exp $
2
3////////////////////////////////////////////////////
4/*!
5 \file AliJPhoton.h
6 \author J. Rak, D.J.Kim, R.Diaz (University of Jyvaskyla)
7 \email: djkim@jyu.fi
8 \version $Revision: 1.1 $
9 \date $Date: 2008/05/02 11:56:39 $
10*/
11////////////////////////////////////////////////////
12
13#ifndef ALIJPHOTON_H
14#define ALIJPHOTON_H
15
16#ifndef ROOT_TObject
17#include <TObject.h>
18#endif
19
20#include <iostream>
21#include <fstream>
22#include <stdlib.h>
23#include <stdio.h>
24#include "TMath.h"
25
26#include "JConst.h"
27#include "AliPhJBaseTrack.h"
28#include "AliPhJPhoton.h"
29
30//class AliPhJBaseTrack;
31//class TObject;
32
33
34class AliJPhoton : public AliPhJPhoton {
35
36public:
37
38 enum AliJCaloType {
39 kUndef = -1,
40 kPHOSCalo,
41 kEMCALCalo
42 };
43
44 enum AliJCaloPID{
45 kElectronAli = 0,
46 kMuonAli = 1,
47 kPionAli = 2,
48 kKaonAli = 3,
49 kProtonAli = 4,
50 kPhotonAli = 5,
51 kPi0Ali = 6,
52 kNeutronAli = 7,
53 kKaon0Ali = 8,
54 kEleConAli = 9,
55 kUnknownAli = 10
56 };
57
58
59 AliJPhoton(); // default constructor
60 AliJPhoton(const AliJPhoton& a);
61 ~AliJPhoton(){;} //destructor
62
63 Bool_t InPHOS() const {return fCaloType==kPHOSCalo ? kTRUE:kFALSE ;}
64 Bool_t InEMCAL() const {return fCaloType==kEMCALCalo ? kTRUE:kFALSE ;}
65 // getters
66 void GetPID(Double_t *pid) const {
67 for(Int_t i=0; i<kUnknownAli+1; ++i) pid[i]=fCaloPID[i];
68 }
69 Double_t GetDistToBadChannel() const {return fDistToBadChannel;}
70 Double_t GetDispersion() const {return fDispersion;}
71 Double_t GetM20() const {return fM20;}
72 Double_t GetM02() const {return fM02;}
73 Double_t GetEmcCpvDist() const {return fEmcCpvDist;}
74 Double_t GetNCells() const { return fNCells;}
75 UShort_t *GetCellsAbsId() const {return fCellsAbsId;}
76 Int_t GetCellAbsId(Int_t i) const {
77 if (fCellsAbsId && i >=0 && i < fNCells ) return fCellsAbsId[i];
78 else return -1;}
79 Double32_t *GetCellsAmplitudeFraction() const {return fCellsAmpFraction;}
80 Double_t GetCellAmplitudeFraction(Int_t i) const {
81 if (fCellsAmpFraction && i >=0 && i < fNCells ) return fCellsAmpFraction[i];
82 else return -1;}
83 particleType GetParticleType();
84
85
86 //setters
87 void SetCaloType(AliJCaloType calo) {fCaloType = calo;}
88 void SetDistToBadChannel(Double_t dist) {fDistToBadChannel = dist;}
89 void SetDispersion(Double_t disp) {fDispersion = disp;}
90 void SetM20(Double_t m20) {fM20 = m20;}
91 void SetM02(Double_t m02) {fM02 = m02;}
92 void SetEmcCpvDist(Double_t dist) {fEmcCpvDist = dist;}
93 void SetPID(const Double_t *pid);
94 void SetNCells(Int_t n) { fNCells = n;}
95 void SetCellsAbsId(const UShort_t *array);
96 void SetCellsAmplitudeFraction(const Double32_t *array) ;
97
98 Int_t GetMCid() const { return fMCid; }
99 void SetMCid(Int_t id) { fMCid = id; }
100 Int_t GetSuperModuleID() const { return fSuperModuleId; }
101 void SetSuperModuleID(Int_t id) { fSuperModuleId = id; }
102
103
104 AliJPhoton& operator=(const AliJPhoton& photon);
105
106private:
107
108 AliJCaloType fCaloType; // PHOS or EMCAL photon
109 Double_t fCaloPID[kUnknownAli+1]; // [0.,1.,8] pointer to PID object
110 Double_t fDistToBadChannel; // Distance to nearest bad channel
111 Double_t fDispersion; // cluster dispersion, for shape analysis
112 Double_t fM20; // 2-nd moment along the main eigen axis
113 Double_t fM02; // 2-nd moment along the second eigen axis
114 Double_t fEmcCpvDist; // the distance from PHOS EMC rec.point to the closest CPV rec.point
115
116 Int_t fNCells ; //number of cells
117 Int_t fSuperModuleId ; //super module id
118 UShort_t *fCellsAbsId; //[fNCells] array of cell absId numbers
119 Double32_t *fCellsAmpFraction; //[fNCells][0.,1.,16] array with cell amplitudes fraction.
120
121 Int_t fMCid; // track label, points back to MC track
122
123
124
125 ClassDef(AliJPhoton,1)
126
127};
128
129#endif
130