Extending the functionality of the physics selection. Instead of providing a yes...
[u/mrichter/AliRoot.git] / STEER / AliAODHeader.h
CommitLineData
df9db588 1#ifndef AliAODHeader_H
2#define AliAODHeader_H
3/* Copyright(c) 1998-2007, ALICE Experiment at CERN, All rights reserved. *
4 * See cxx source for full Copyright notice */
5
6/* $Id$ */
7
8//-------------------------------------------------------------------------
9ae2e5e6 9// AOD event header class
df9db588 10// Author: Markus Oldenburg, CERN
11//-------------------------------------------------------------------------
12
9ae2e5e6 13#include "AliVHeader.h"
df9db588 14#include "AliAODVertex.h"
15
1aa76f71 16class TGeoHMatrix;
27346f69 17class TString;
1aa76f71 18
9ae2e5e6 19class AliAODHeader : public AliVHeader {
df9db588 20
21 public :
31fd97b2 22 AliAODHeader();
df9db588 23
abfce367 24 AliAODHeader(Int_t nRun, UShort_t nBunchX, UInt_t nOrbit, UInt_t nPeriod, const Char_t *title="");
31fd97b2 25 AliAODHeader(Int_t nRun,
26 UShort_t nBunchX,
27 UInt_t nOrbit,
89cf15db 28 UInt_t nPeriod,
31fd97b2 29 Int_t refMult,
30 Int_t refMultPos,
31 Int_t refMultNeg,
32 Double_t magField,
6b6f8d32 33 Double_t muonMagFieldScale,
34 Double_t cent,
35 Double_t n1Energy,
36 Double_t p1Energy,
37 Double_t n2Energy,
38 Double_t p2Energy,
a85132e7 39 Double_t *emEnergy,
31fd97b2 40 ULong64_t fTriggerMask,
41 UChar_t fTriggerCluster,
42 UInt_t fEventType,
fa8b0e56 43 const Char_t *title="",
44 Int_t nMuons=0,
45 Int_t nDimuons=0);
31fd97b2 46
df9db588 47 virtual ~AliAODHeader();
48 AliAODHeader(const AliAODHeader& evt);
49 AliAODHeader& operator=(const AliAODHeader& evt);
6b6f8d32 50
df9db588 51 Int_t GetRunNumber() const { return fRunNumber; }
31fd97b2 52 UShort_t GetBunchCrossNumber() const { return fBunchCrossNumber; }
53 UInt_t GetOrbitNumber() const { return fOrbitNumber; }
89cf15db 54 UInt_t GetPeriodNumber() const { return fPeriodNumber; }
df9db588 55 ULong64_t GetTriggerMask() const { return fTriggerMask; }
56 UChar_t GetTriggerCluster() const { return fTriggerCluster; }
27346f69 57 TString GetFiredTriggerClasses()const { return fFiredTriggers;}
df9db588 58 UInt_t GetEventType() const { return fEventType; }
59 Double_t GetMagneticField() const { return fMagneticField; }
6b6f8d32 60 Double_t GetMuonMagFieldScale() const { return fMuonMagFieldScale; }
61
df9db588 62 Double_t GetCentrality() const { return fCentrality; }
6b6f8d32 63 Double_t GetZDCN1Energy() const { return fZDCN1Energy; }
64 Double_t GetZDCP1Energy() const { return fZDCP1Energy; }
65 Double_t GetZDCN2Energy() const { return fZDCN2Energy; }
66 Double_t GetZDCP2Energy() const { return fZDCP2Energy; }
a85132e7 67 Double_t GetZDCEMEnergy(Int_t i) const { return fZDCEMEnergy[i]; }
df9db588 68 Int_t GetRefMultiplicity() const { return fRefMult; }
69 Int_t GetRefMultiplicityPos() const { return fRefMultPos; }
70 Int_t GetRefMultiplicityNeg() const { return fRefMultNeg; }
fa8b0e56 71 Int_t GetNumberOfMuons() const { return fNMuons; }
72 Int_t GetNumberOfDimuons() const { return fNDimuons; }
ff254193 73
74 Double_t GetQTheta(UInt_t i) const;
75 UInt_t GetNQTheta() const { return (UInt_t)fNQTheta; }
613fc341 76
77 Double_t GetDiamondX() const {return fDiamondXY[0];}
78 Double_t GetDiamondY() const {return fDiamondXY[1];}
49fc2e2c 79 Double_t GetDiamondZ() const {return fDiamondZ;}
613fc341 80 Double_t GetSigma2DiamondX() const {return fDiamondCovXY[0];}
81 Double_t GetSigma2DiamondY() const {return fDiamondCovXY[2];}
49fc2e2c 82 Double_t GetSigma2DiamondZ() const {return fDiamondSig2Z;}
613fc341 83 void GetDiamondCovXY(Float_t cov[3]) const {
84 for(Int_t i=0;i<3;i++) cov[i]=fDiamondCovXY[i]; return;
85 }
6b6f8d32 86
df9db588 87 void SetRunNumber(Int_t nRun) { fRunNumber = nRun; }
31fd97b2 88 void SetBunchCrossNumber(UShort_t nBx) { fBunchCrossNumber = nBx; }
9ae2e5e6 89 void SetOrbitNumber(UInt_t nOr) { fOrbitNumber = nOr; }
90 void SetPeriodNumber(UInt_t nPer) { fPeriodNumber = nPer; }
df9db588 91 void SetTriggerMask(ULong64_t trigMsk) { fTriggerMask = trigMsk; }
27346f69 92 void SetFiredTriggerClasses(TString trig) { fFiredTriggers = trig;}
df9db588 93 void SetTriggerCluster(UChar_t trigClus) { fTriggerCluster = trigClus; }
94 void SetEventType(UInt_t evttype) { fEventType = evttype; }
95 void SetMagneticField(Double_t magFld) { fMagneticField = magFld; }
6b6f8d32 96 void SetMuonMagFieldScale(Double_t magFldScl){ fMuonMagFieldScale = magFldScl; }
97
df9db588 98 void SetCentrality(Double_t cent) { fCentrality = cent; }
6b6f8d32 99 void SetZDCN1Energy(Double_t n1Energy) { fZDCN1Energy = n1Energy; }
100 void SetZDCP1Energy(Double_t p1Energy) { fZDCP1Energy = p1Energy; }
101 void SetZDCN2Energy(Double_t n2Energy) { fZDCN2Energy = n2Energy; }
102 void SetZDCP2Energy(Double_t p2Energy) { fZDCP2Energy = p2Energy; }
a85132e7 103 void SetZDCEMEnergy(Double_t emEnergy1, Double_t emEnergy2)
104 { fZDCEMEnergy[0] = emEnergy1; fZDCEMEnergy[1] = emEnergy2;}
df9db588 105 void SetRefMultiplicity(Int_t refMult) { fRefMult = refMult; }
106 void SetRefMultiplicityPos(Int_t refMultPos) { fRefMultPos = refMultPos; }
107 void SetRefMultiplicityNeg(Int_t refMultNeg) { fRefMultNeg = refMultNeg; }
fa8b0e56 108 void SetNumberOfMuons(Int_t nMuons) { fNMuons = nMuons; }
109 void SetNumberOfDimuons(Int_t nDimuons) { fNDimuons = nDimuons; }
6b6f8d32 110
ff254193 111 void SetQTheta(Double_t *QTheta, UInt_t size = 5);
112 void RemoveQTheta();
113
613fc341 114 void SetDiamond(Float_t xy[2],Float_t cov[3]) {
115 for(Int_t i=0;i<3;i++) {if(i<2) fDiamondXY[i]=xy[i]; fDiamondCovXY[i]=cov[i];}
116 }
49fc2e2c 117 void SetDiamondZ(Float_t z, Float_t sig2z){
118 fDiamondZ=z; fDiamondSig2Z=sig2z;
119 }
613fc341 120
df9db588 121 void Print(Option_t* option = "") const;
1aa76f71 122
123 void SetPHOSMatrix(TGeoHMatrix*matrix, Int_t i) {
124 if ((i >= 0) && (i < kNPHOSMatrix)) fPHOSMatrix[i] = matrix;
125 }
126 const TGeoHMatrix* GetPHOSMatrix(Int_t i) const {
127 return ((i >= 0) && (i < kNPHOSMatrix)) ? fPHOSMatrix[i] : NULL;
128 }
6b6f8d32 129
1aa76f71 130 void SetEMCALMatrix(TGeoHMatrix*matrix, Int_t i) {
131 if ((i >= 0) && (i < kNEMCALMatrix)) fEMCALMatrix[i] = matrix;
132 }
133 const TGeoHMatrix* GetEMCALMatrix(Int_t i) const {
134 return ((i >= 0) && (i < kNEMCALMatrix)) ? fEMCALMatrix[i] : NULL;
135 }
136
0c6c629b 137 UInt_t GetOfflineTrigger() { return fOfflineTrigger; }
138 void SetOfflineTrigger(UInt_t trigger) { fOfflineTrigger = trigger; }
139
1aa76f71 140 enum {kNPHOSMatrix = 5};
141 enum {kNEMCALMatrix = 12};
6b6f8d32 142
df9db588 143 private :
6b6f8d32 144
145 Double32_t fMagneticField; // Solenoid Magnetic Field in kG
146 Double32_t fMuonMagFieldScale; // magnetic field scale of muon arm magnet
147 Double32_t fCentrality; // Centrality
148 Double32_t fZDCN1Energy; // reconstructed energy in the neutron1 ZDC
149 Double32_t fZDCP1Energy; // reconstructed energy in the proton1 ZDC
150 Double32_t fZDCN2Energy; // reconstructed energy in the neutron2 ZDC
151 Double32_t fZDCP2Energy; // reconstructed energy in the proton2 ZDC
a85132e7 152 Double32_t fZDCEMEnergy[2]; // reconstructed energy in the electromagnetic ZDCs
ff254193 153 Int_t fNQTheta; // number of QTheta elements
154 Double32_t *fQTheta; // [fNQTheta] values to store Lee-Yang-Zeros
6b6f8d32 155 ULong64_t fTriggerMask; // Trigger Type (mask)
27346f69 156 TString fFiredTriggers; // String with fired triggers
6b6f8d32 157 Int_t fRunNumber; // Run Number
158 Int_t fRefMult; // reference multiplicity
159 Int_t fRefMultPos; // reference multiplicity of positive particles
160 Int_t fRefMultNeg; // reference multiplicity of negative particles
fa8b0e56 161 Int_t fNMuons; // number of muons in the forward spectrometer
162 Int_t fNDimuons; // number of dimuons in the forward spectrometer
9333290e 163 UInt_t fEventType; // Type of Event
164 UInt_t fOrbitNumber; // Orbit Number
165 UInt_t fPeriodNumber; // Period Number
166 UShort_t fBunchCrossNumber; // BunchCrossingNumber
6b6f8d32 167 UChar_t fTriggerCluster; // Trigger cluster (mask)
613fc341 168 Double32_t fDiamondXY[2]; // Interaction diamond (x,y) in RUN
169 Double32_t fDiamondCovXY[3]; // Interaction diamond covariance (x,y) in RUN
49fc2e2c 170 Double32_t fDiamondZ; // Interaction diamond (z) in RUN
171 Double32_t fDiamondSig2Z; // Interaction diamond sigma^2 (z) in RUN
1aa76f71 172 TGeoHMatrix* fPHOSMatrix[kNPHOSMatrix]; //PHOS module position and orientation matrices
173 TGeoHMatrix* fEMCALMatrix[kNEMCALMatrix]; //EMCAL supermodule position and orientation matrices
0c6c629b 174 UInt_t fOfflineTrigger; // fired offline triggers for this event
1aa76f71 175
0c6c629b 176 ClassDef(AliAODHeader,12);
df9db588 177};
178
179#endif