From: agheata Date: Mon, 23 Jul 2012 13:12:45 +0000 (+0000) Subject: addition to #96201: forgot to add the new files X-Git-Url: http://git.uio.no/git/?a=commitdiff_plain;h=3bf10ad95874abd7c226905bd2ca49dfd4f3a009;p=u%2Fmrichter%2FAliRoot.git addition to #96201: forgot to add the new files --- diff --git a/STEER/AOD/AliAODHMPIDrings.cxx b/STEER/AOD/AliAODHMPIDrings.cxx new file mode 100644 index 00000000000..f80af836a9b --- /dev/null +++ b/STEER/AOD/AliAODHMPIDrings.cxx @@ -0,0 +1,164 @@ +/************************************************************************** + * Copyright(c) 1998-2007, ALICE Experiment at CERN, All rights reserved. * + * * + * Author: The ALICE Off-line Project. * + * Contributors are mentioned in the code where appropriate. * + * * + * Permission to use, copy, modify and distribute this software and its * + * documentation strictly for non-commercial purposes is hereby granted * + * without fee, provided that the above copyright notice appears in all * + * copies and that both the copyright notice and this permission notice * + * appear in the supporting documentation. The authors make no claims * + * about the suitability of this software for any purpose. It is * + * provided "as is" without express or implied warranty. * + **************************************************************************/ + + + +// +// Class to handle the AOD tracks with good HMPID data +// Author: Levente Molnar +// levente.molnar@cern.ch , March 2012 +// + +#include "AliAODHMPIDrings.h" + +ClassImp(AliAODHMPIDrings) + +//________________________________________________________________________________________________________________________________________________________ + +AliAODHMPIDrings::AliAODHMPIDrings() + :TObject(), + fHmpidAODtrkId(0), + fHmpidAODqn(0), + fHmpidAODcluIdx(0), + fHmpidAODtrkTheta(0), + fHmpidAODtrkPhi(0), + fHmpidAODsignal(0), + fHmpidAODocc(0), + fHmpidAODchi2(0), + fHmpidAODtrkX(0), + fHmpidAODtrkY(0), + fHmpidAODmipX(0), + fHmpidAODmipY(0) + +{ + //default ctor + for(Int_t isp = 0 ; isp +//___AliRoot includes +#include "AliPID.h" + + +class AliAODHMPIDrings : public TObject { + + public: + + AliAODHMPIDrings(); + AliAODHMPIDrings( + Int_t trkId, + Int_t qn, + Int_t cluIdx, + Double32_t trkTheta, + Double32_t trkPhi, + Double32_t signal, + Double32_t occ, + Double32_t chi2, + Double32_t trkX, + Double32_t trkY, + Double32_t mipX, + Double32_t mipY, + Double32_t *pid, + Double32_t *p ); // + + + AliAODHMPIDrings(const AliAODHMPIDrings& hmpidAOD);// + AliAODHMPIDrings &operator=(const AliAODHMPIDrings& hmpidAOD);// + virtual ~AliAODHMPIDrings() {}; + + //___ Getters + Double32_t GetHmpTrkID() { return fHmpidAODtrkId; } + + Double32_t GetHmpMipCharge() { return fHmpidAODqn%1000000; } + Double32_t GetHmpNumOfPhotonClusters() { return fHmpidAODqn/1000000;} + + Int_t GetHmpChamber() { return fHmpidAODcluIdx/1000000; } + + Double32_t GetHmpTrackTheta() { return fHmpidAODtrkTheta;} + Double32_t GetHmpTrackPhi() { return fHmpidAODtrkPhi;} + + Double32_t GetHmpSignal() { return fHmpidAODsignal;} + Double32_t GetHmpOccupancy() { return fHmpidAODocc;} + + Double32_t GetHmpChi2() { return fHmpidAODchi2;} + + Double32_t GetHmpTrackX() { return fHmpidAODtrkX;} + Double32_t GetHmpTrackY() { return fHmpidAODtrkY;} + + Double32_t GetHmpMipX() { return fHmpidAODmipX;} + Double32_t GetHmpMipY() { return fHmpidAODmipY;} + + Double32_t GetHmpDX() { return fHmpidAODmipX - fHmpidAODtrkX;} + Double32_t GetHmpDY() { return fHmpidAODmipY - fHmpidAODtrkY;} + Double32_t GetHmpDist() { return TMath::Sqrt((fHmpidAODmipX - fHmpidAODtrkX)*(fHmpidAODmipX - fHmpidAODtrkX) + (fHmpidAODmipY - fHmpidAODtrkY)*(fHmpidAODmipY - fHmpidAODtrkY));} + + + void GetHmpPidProbs(Double32_t *pid); //defined in cxx + void GetHmpMom(Double32_t *mom); //defined in cxx + + //___ Setters + + void SetHmpMipCharge(Int_t q) { fHmpidAODqn = q; } + void SetHmpCluIdx(Int_t ch,Int_t idx) { fHmpidAODcluIdx=ch*1000000+idx;} + + void SetHmpNumOfPhotonClusters(Int_t nph) { fHmpidAODqn = 1000000 * nph;} + + void SetHmpTrackTheta(Double32_t trkTheta) { fHmpidAODtrkTheta = trkTheta;} + void SetHmpTrackPhi(Double32_t trkPhi) { fHmpidAODtrkPhi = trkPhi;} + + void SetHmpSignal(Double32_t thetaC) { fHmpidAODsignal = thetaC;} + void SetHmpOccupancy(Double32_t occ) { fHmpidAODocc = occ;} + + void SetHmpChi2(Double32_t chi2) { fHmpidAODchi2 = chi2;} + + void SetHmpTrackX(Double32_t trkX) { fHmpidAODtrkX = trkX;} + void SetHmpTrackY(Double32_t trkY) { fHmpidAODtrkY = trkY;} + + void SetHmpMipX(Double32_t mipX) { fHmpidAODmipX = mipX;} + void SetHmpMipY(Double32_t mipY) { fHmpidAODmipY = mipY;} + + void SetHmpPidProbs(Double32_t *pid); + void SetHmpMom(Double32_t *mom); + + + // blablabla + + + + protected: + + Int_t fHmpidAODtrkId; // Unique track id as in ESD + Int_t fHmpidAODqn; // 1000000*number of photon clusters + QDC + Int_t fHmpidAODcluIdx; // 1000000*chamber id + cluster idx of the assigned MIP cluster + + Double32_t fHmpidAODtrkTheta; // [-2*pi,2*pi,16] theta of the track extrapolated to the HMPID, LORS + Double32_t fHmpidAODtrkPhi; // [-2*pi,2*pi,16] theta of the track extrapolated to the HMPID, LORS + Double32_t fHmpidAODsignal; // [0,0.9,8] HMPID signal (Theta ckov, rad) + Double32_t fHmpidAODocc; // [0,0,,8] chamber occupancy where the track passed through: number of pads + Double32_t fHmpidAODchi2; // [0.,0.,8] chi2 in the HMPID + Double32_t fHmpidAODtrkX; // [0.,0.,8] x of the track impact, LORS + Double32_t fHmpidAODtrkY; // [0.,0.,8] y of the track impact, LORS + Double32_t fHmpidAODmipX; // [0.,0.,8] x of the MIP in LORS + Double32_t fHmpidAODmipY; // [0.,0.,8] y of the MIP in LORS + Double32_t fHmpidAODpid[AliPID::kSPECIES]; // [0.,0.,8] "detector response probabilities" (for the PID) + Double32_t fHMPIDmom[3]; // [0.,0.,8] track momentum at the HMPID ring reconstruction + + ClassDef(AliAODHMPIDrings,1) + +}; +#endif