3 ////////////////////////////////////////////////
4 // Manager and hits classes for set:PMD //
5 ////////////////////////////////////////////////
7 #include "AliDetector.h"
11 class AliPMD : public AliDetector {
14 Float_t fPar[4]; // pmdin, pmdout, thgas, thcell
15 Float_t fIn[5]; // thmin, thmax, zdist, thlow, thhigh
16 Float_t fGeo[3]; // wafer, edge, numqu
17 Float_t fPadSize[4]; // size of the pads
18 Int_t fNumPads[4]; // number of the pads
21 AliPMD(const char *name, const char *title);
23 virtual void AddHit(Int_t, Int_t*, Float_t*);
24 virtual void BuildGeometry();
25 virtual void CreateGeometry() {}
26 virtual void CreateMaterials() {}
27 Int_t DistancetoPrimitive(Int_t, Int_t);
28 virtual Int_t IsVersion() const =0;
29 virtual void SetPAR(Float_t, Float_t, Float_t, Float_t);
30 virtual void SetIN(Float_t, Float_t, Float_t, Float_t, Float_t);
31 virtual void SetGEO(Float_t, Float_t, Float_t);
32 virtual void SetPadSize(Float_t, Float_t, Float_t, Float_t);
33 virtual void StepManager();
35 ClassDef(AliPMD,1) // Base Class for Photon Multiplicity Detector
40 //___________________________________________
42 class AliPMDhit : public AliHit {
44 Int_t fVolume[5]; //array of volumes
45 Float_t fEnergy; //Total energy deposited in eV
48 AliPMDhit(Int_t shunt, Int_t track, Int_t *vol, Float_t *hits);
49 AliPMDhit(AliPMDhit* oldhit) {*this=*oldhit;}
50 virtual ~AliPMDhit() {}
51 inline virtual Int_t GetVolume(Int_t i) {return fVolume[i];}
52 inline virtual Float_t GetEnergy() {return fEnergy;}
53 inline int operator == (AliPMDhit &cell) {
55 if(fTrack!=cell.GetTrack()) return 0;
56 for (i=0; i<4; i++) if(fVolume[i]!=cell.GetVolume(i)) return 0;
59 inline virtual AliPMDhit& operator + (AliPMDhit &cell) {
60 fEnergy+=cell.GetEnergy();
63 virtual void Print(Option_t *) {
64 printf("PMD Cell %d %d %d %d\n Primary %d - Energy %f\n",
65 fVolume[0],fVolume[1],fVolume[2],fVolume[3],fTrack,fEnergy);
69 ClassDef(AliPMDhit,1) //Hits object for set:PMD