]>
Commit | Line | Data |
---|---|---|
762e8424 | 1 | #ifndef ALIJETMODELBASETASK_H |
2 | #define ALIJETMODELBASETASK_H | |
3 | ||
4 | // $Id$ | |
5 | ||
6 | class TClonesArray; | |
7 | class AliEMCALGeometry; | |
8 | class AliVCluster; | |
9 | class AliPicoTrack; | |
e44e8726 | 10 | class TF1; |
762e8424 | 11 | |
12 | #include "AliAnalysisTaskSE.h" | |
13 | ||
14 | class AliJetModelBaseTask : public AliAnalysisTaskSE { | |
15 | public: | |
16 | AliJetModelBaseTask(); | |
17 | AliJetModelBaseTask(const char *name); | |
18 | virtual ~AliJetModelBaseTask(); | |
19 | ||
20 | virtual void Init(); | |
21 | virtual void UserExec(Option_t* /*option*/); | |
22 | virtual void Terminate(const Option_t* /*option*/) {;} | |
23 | ||
24 | void SetClusName(const char *n) { fCaloName = n; } | |
25 | void SetTracksName(const char *n) { fTracksName = n; } | |
26 | void SetEtaRange(Float_t min, Float_t max) { fEtaMin = min; fEtaMax = max; } | |
27 | void SetPhiRange(Float_t min, Float_t max) { fPhiMin = min; fPhiMax = max; } | |
28 | void SetPtRange(Float_t min, Float_t max) { fPtMin = min; fPtMax = max; } | |
29 | void SetCopyArray(Bool_t copy) { fCopyArray = copy; } | |
30 | void SetNClusters(Int_t n) { fNClusters = n; } | |
31 | void SetNTracks(Int_t n) { fNTracks = n; } | |
32 | void SetGeometryName(const char *n) { fGeomName = n; } | |
33 | void SetSuffix(const char *s) { fSuffix = s; } | |
e44e8726 | 34 | void SetPtSpectrum(TF1 *f) { fPtSpectrum = f; } |
762e8424 | 35 | |
36 | protected: | |
37 | ||
38f684a8 | 38 | virtual void Run(); // do jet model action |
39 | void GetRandomCell(Double_t &eta, Double_t &phi, Int_t &absId); // generate a random cell in the calorimeter | |
40 | Double_t GetRandomEta(); // generate a random eta value in the given range | |
41 | Double_t GetRandomPhi(); // generate a random phi value in the given range | |
42 | Double_t GetRandomPt(); // generate a random pt value in the given range | |
43 | AliVCluster *AddCluster(Double_t e = -1, Double_t eta = -999, Double_t phi = -1); // add a cluster; if values are -1 generate random parameters | |
44 | AliVCluster *AddCluster(Double_t e, Int_t absId); // add a cluster with given energy and position | |
45 | AliPicoTrack *AddTrack(Double_t pt = -1, Double_t eta = -999, Double_t phi = -1); // add a track; if values are -1 generate random parameters | |
e44e8726 | 46 | void CopyClusters(); |
47 | void CopyTracks(); | |
762e8424 | 48 | |
49 | TString fGeomName; // EMCal geometry name | |
50 | TString fTracksName; // name of track collection | |
51 | TString fOutTracksName; // name of output track collection | |
52 | TString fCaloName; // name of calo cluster collection | |
53 | TString fOutCaloName; // name of output cluster collection | |
54 | TString fSuffix; // suffix to add in the name of new collections | |
55 | Float_t fEtaMin; // eta minimum value | |
56 | Float_t fEtaMax; // eta maximum value | |
57 | Float_t fPhiMin; // phi minimum value | |
58 | Float_t fPhiMax; // phi maximum value | |
59 | Float_t fPtMin; // pt minimum value | |
60 | Float_t fPtMax; // pt maximum value | |
61 | Bool_t fCopyArray; // whether or not the array will be copied to a new one before modelling | |
62 | Int_t fNClusters; // how many clusters are being processed | |
63 | Int_t fNTracks; // how many tracks are being processed | |
e44e8726 | 64 | TF1 *fPtSpectrum; // pt spectrum parametrization to extract random pt values |
762e8424 | 65 | AliEMCALGeometry *fGeom; //!pointer to EMCal geometry |
66 | TClonesArray *fClusters; //!cluster collection | |
67 | TClonesArray *fOutClusters; //!output cluster collection | |
68 | TClonesArray *fTracks; //!track collection | |
69 | TClonesArray *fOutTracks; //!output track collection | |
70 | ||
71 | private: | |
72 | AliJetModelBaseTask(const AliJetModelBaseTask&); // not implemented | |
73 | AliJetModelBaseTask &operator=(const AliJetModelBaseTask&); // not implemented | |
74 | ||
e44e8726 | 75 | ClassDef(AliJetModelBaseTask, 2) // Jet modelling task |
762e8424 | 76 | }; |
77 | #endif |