]>
Commit | Line | Data |
---|---|---|
621688e4 | 1 | #ifndef ALIUNICOREVENTALICEESD_H |
2 | #define ALIUNICOREVENTALICEESD_H | |
3 | ||
4 | /* Copyright(c) 1998-2048, ALICE Experiment at CERN, All rights reserved. * | |
5 | * See cxx source for full Copyright notice */ | |
6 | /* $Id$ */ | |
7 | ||
8 | // Author: Dariusz Miskowiec <mailto:d.miskowiec@gsi.de> 2008 | |
9 | ||
10 | #include <cmath> | |
11 | #include "TVector2.h" | |
12 | #include "AliESDEvent.h" | |
61e4657c | 13 | //#include "AliPhysicsSelection.h" |
76d78859 | 14 | #include "AliExternalTrackParam.h" |
621688e4 | 15 | #include "AliUnicorEvent.h" |
16 | ||
61e4657c | 17 | //class AliPhysicsSelection; |
28eee19b | 18 | class TGraph; |
b226c9db | 19 | |
621688e4 | 20 | //============================================================================= |
21 | class AliUnicorEventAliceESD : public AliUnicorEvent { | |
22 | ||
23 | public: | |
24 | AliUnicorEventAliceESD(AliESDEvent *esd=0); | |
28eee19b | 25 | //AliUnicorEventAliceESD(const AliUnicorEventAliceESD &ev): AliUnicorEvent(ev), fViper(ev.fViper), fESD(ev.fESD), fPhysicsSelection(ev.fPhysicsSelection){} |
a645633a | 26 | AliUnicorEventAliceESD(const AliUnicorEventAliceESD &ev): AliUnicorEvent(ev), fViper(ev.fViper), fESD(ev.fESD) {} |
621688e4 | 27 | virtual ~AliUnicorEventAliceESD(); |
e99fb5c9 | 28 | AliUnicorEventAliceESD &operator=(const AliUnicorEventAliceESD &source) { |
29 | if(&source == this) return *this; | |
30 | AliUnicorEvent::operator=(source); | |
31 | fViper=source.fViper; fESD=source.fESD; return *this;} | |
621688e4 | 32 | Double_t Etamin() const {return -0.75;} |
33 | Double_t Etamax() const {return 0.75;} | |
34 | void AttachTree(TTree *tr) {fESD->ReadFromTree(tr);} | |
35 | Bool_t Good() const; | |
28eee19b | 36 | // Double_t Centrality() const {return 0.9999*exp(-NGoodParticles()/1000.0);} // 7 for pp 900 GeV, 12 for pp 7 TeV, 1000 PbPb |
37 | Double_t Centrality() const; | |
621688e4 | 38 | void RP(Double_t &qx, Double_t &qy) const {AliUnicorEvent::RP(qx,qy,2);} |
39 | Double_t RPphi() const {Double_t qx,qy; RP(qx,qy); return atan2(qy,qx);} | |
28eee19b | 40 | Double_t Zver() const {return fESD->GetPrimaryVertex()->GetZv()/12.0;} |
621688e4 | 41 | Int_t NParticles() const {return fESD->GetNumberOfTracks();} |
42 | ||
43 | Bool_t ParticleGood(Int_t i, Int_t pidi=0) const; | |
76d78859 | 44 | Double_t ParticleP(Int_t i) const {return GetTrackParam(i)->P();} |
45 | Double_t ParticleTheta(Int_t i) const {return GetTrackParam(i)->Theta();} | |
46 | Double_t ParticlePhi(Int_t i) const {return TVector2::Phi_mpi_pi(GetTrackParam(i)->Phi());} | |
040da09c | 47 | Double_t ParticleDedx(Int_t i) const {return fESD->GetTrack(i)->GetTPCsignal()/50.0;} |
28eee19b | 48 | Bool_t PairGood(double p0, double the0, double phi0, double z0, |
49 | double p1, double the1, double phi1, double z1) const; | |
c6fc7f72 | 50 | void SetESD(AliESDEvent * const esd) {fESD = esd;} |
621688e4 | 51 | AliESDEvent *GetESD() const {return fESD;} |
76d78859 | 52 | //const AliExternalTrackParam *GetTrackParam(Int_t i) const {return fESD->GetTrack(i);} |
61e4657c | 53 | //const AliExternalTrackParam *GetTrackParam(Int_t i) const {return fESD->GetTrack(i)->GetConstrainedParam();} |
b226c9db | 54 | //const AliExternalTrackParam *GetTrackParam(Int_t i) const {return fESD->GetTrack(i)->GetInnerParam();} // not at vtx! |
61e4657c | 55 | const AliExternalTrackParam *GetTrackParam(Int_t i) const {return fESD->GetTrack(i)->GetTPCInnerParam();} |
621688e4 | 56 | |
57 | protected: | |
28eee19b | 58 | TGraph *fViper; // V0 centrality percentile |
b226c9db | 59 | AliESDEvent *fESD; //! pointer to the actual source of data |
61e4657c | 60 | // AliPhysicsSelection *fPhysicsSelection; //! interaction event filter |
621688e4 | 61 | |
62 | ClassDef(AliUnicorEventAliceESD,0) | |
63 | }; | |
64 | #endif | |
65 | //============================================================================= |