LCOV - code coverage report
Current view: top level - STEER/ESD - AliESDcascade.h (source / functions) Hit Total Coverage
Test: coverage.info Lines: 1 30 3.3 %
Date: 2016-06-14 17:26:59 Functions: 2 32 6.2 %

          Line data    Source code
       1             : #ifndef ALIESDCASCADE_H
       2             : #define ALIESDCASCADE_H
       3             : 
       4             : /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
       5             :  * See cxx source for full Copyright notice                               */
       6             : 
       7             : /* $Id$ */
       8             : 
       9             : //-------------------------------------------------------------------------
      10             : //                        ESD Cascade Vertex Class
      11             : //               Implementation of the cascade vertex class
      12             : //    Origin: Christian Kuhn, IReS, Strasbourg, christian.kuhn@ires.in2p3.fr
      13             : //     Modified by: Antonin Maire,IPHC, Antonin.Maire@ires.in2p3.fr
      14             : //            and  Boris Hippolyte,IPHC, hippolyt@in2p3.fr 
      15             : //-------------------------------------------------------------------------
      16             : 
      17             : #include <TPDGCode.h>
      18             : #include "AliESDv0.h"
      19             : 
      20             : class AliLog;
      21             : class AliExternalTrackParam;
      22             : 
      23             : class AliESDcascade : public AliESDv0 {
      24             : 
      25             : public:
      26             :   AliESDcascade();
      27             :   AliESDcascade(const AliESDcascade& cas);
      28             :   AliESDcascade(const AliESDv0 &v0,
      29             :                 const AliExternalTrackParam &t, Int_t i);
      30             :   ~AliESDcascade();
      31             :   AliESDcascade& operator=(const AliESDcascade& cas);
      32             :   virtual void Copy(TObject &obj) const;
      33             : 
      34             : // Start with AliVParticle functions
      35           0 :   virtual Double_t Px() const { return fNmom[0]+fPmom[0]+fBachMom[0]; }
      36           0 :   virtual Double_t Py() const { return fNmom[1]+fPmom[1]+fBachMom[1]; }
      37           0 :   virtual Double_t Pz() const { return fNmom[2]+fPmom[2]+fBachMom[2]; }
      38           0 :   virtual Double_t Pt() const { return TMath::Sqrt(Px()*Px()+Py()*Py()); }
      39             :   virtual Double_t P()  const { 
      40           0 :      return TMath::Sqrt(Px()*Px()+Py()*Py()+Pz()*Pz()); 
      41             :   }
      42           0 :   virtual Bool_t   PxPyPz(Double_t p[3]) const { p[0] = Px(); p[1] = Py(); p[2] = Pz(); return kTRUE; }
      43           0 :   virtual Double_t Xv() const { return fPosXi[0]; }
      44           0 :   virtual Double_t Yv() const { return fPosXi[1]; }
      45           0 :   virtual Double_t Zv() const { return fPosXi[2]; }
      46           0 :   virtual Bool_t   XvYvZv(Double_t x[3]) const { x[0] = Xv(); x[1] = Yv(); x[2] = Zv(); return kTRUE; }
      47           0 :   virtual Double_t OneOverPt() const { return (Pt() != 0.) ? 1./Pt() : -999.; }
      48           0 :   virtual Double_t Phi() const {return TMath::Pi()+TMath::ATan2(-Py(),-Px()); }
      49           0 :   virtual Double_t Theta() const {return 0.5*TMath::Pi()-TMath::ATan(Pz()/(Pt()+1.e-13)); }
      50             :   virtual Double_t E() const; // default is Xis but can be changed via ChangeMassHypothesis (defined in the .cxx)
      51           0 :   virtual Double_t M() const { return GetEffMassXi(); }
      52           0 :   virtual Double_t Eta() const { return 0.5*TMath::Log((P()+Pz())/(P()-Pz()+1.e-13)); }
      53             :   virtual Double_t Y() const;
      54           0 :   virtual Short_t  Charge() const { return (GetPdgCodeXi()>0) ? -1 : 1; } // due to PDG sign convention !
      55           0 :   virtual Int_t    GetLabel() const { return -1; }  // temporary
      56           0 :   virtual const Double_t *PID() const { return 0; } // return PID object ? (to be discussed!)
      57             : 
      58             :   // Then extend the AliVParticle functions
      59             :   Double_t E(Int_t pdg) const;
      60             :   Double_t Y(Int_t pdg) const;
      61             : 
      62             :   // Now the functions for analysis consistency
      63             :   Double_t RapXi() const;
      64             :   Double_t RapOmega() const;
      65             :   Double_t AlphaXi() const;
      66             :   Double_t PtArmXi() const;
      67             : 
      68             :   // Eventually the older functions
      69             :   Double_t ChangeMassHypothesis(Double_t &v0q, Int_t code=kXiMinus); 
      70             : 
      71           0 :   Int_t    GetPdgCodeXi() const {return fPdgCodeXi;}
      72           0 :   Double_t GetEffMassXi() const {return fEffMassXi;}
      73           0 :   Double_t GetChi2Xi()  const {return fChi2Xi;}
      74             :   void     GetPxPyPz(Double_t &px, Double_t &py, Double_t &pz) const;
      75             :   void     GetXYZcascade(Double_t &x, Double_t &y, Double_t &z) const;
      76             :   Double_t GetDcascade(Double_t x0, Double_t y0, Double_t z0) const;
      77             : 
      78             :   void     GetBPxPyPz(Double_t &px, Double_t &py, Double_t &pz) const {
      79           0 :      px=fBachMom[0]; py=fBachMom[1]; pz=fBachMom[2];
      80           0 :   }
      81             : 
      82           0 :   Int_t    GetBindex() const {return fBachIdx;}
      83           0 :   void     SetIndex(Int_t i) {fBachIdx=i;}        //for the consistency with V0
      84           0 :   Int_t    GetIndex() const {return GetBindex();} //for the consistency with V0
      85             :   void     SetDcaXiDaughters(Double_t rDcaXiDaughters=0.);
      86           0 :   Double_t GetDcaXiDaughters() const {return fDcaXiDaughters;}
      87             :   Double_t GetCascadeCosineOfPointingAngle(Double_t refPointX, Double_t refPointY, Double_t refPointZ) const;
      88             : 
      89             :   void GetPosCovXi(Double_t cov[6]) const;
      90             : 
      91             : protected: 
      92             : 
      93             :   Double32_t fEffMassXi;      // reconstructed cascade effective mass
      94             :   Double32_t fChi2Xi;         // chi2 value
      95             :   Double32_t fDcaXiDaughters; // dca between Xi's daughters
      96             :   Double32_t fPosXi[3];       // cascade vertex position (global)
      97             :   Double32_t fPosCovXi[6];    // covariance matrix of the vertex position
      98             :   Double32_t fBachMom[3];     // bachelor momentum (global)
      99             :   Double32_t fBachMomCov[6];  // covariance matrix of the bachelor momentum.
     100             :   Int_t      fPdgCodeXi;      // reconstructed cascade type (PDG code)
     101             :   Int_t      fBachIdx;        // label of the bachelor track
     102             : 
     103             : 
     104             : private:
     105             : 
     106             : 
     107         180 :   ClassDef(AliESDcascade,5) // reconstructed cascade vertex
     108             : };
     109             : 
     110             : inline
     111             : void AliESDcascade::SetDcaXiDaughters(Double_t rDcaXiDaughters){
     112           0 :   fDcaXiDaughters=rDcaXiDaughters;
     113           0 : }
     114             : 
     115             : #endif

Generated by: LCOV version 1.11