Protection for charge > 4095 ADC (LM)
[u/mrichter/AliRoot.git] / STEER / AliAODJet.h
CommitLineData
df9db588 1#ifndef AliAODJet_H
2#define AliAODJet_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//-------------------------------------------------------------------------
87102d3c 9// AOD jet class
10// Author: Andreas Morsch, CERN
df9db588 11//-------------------------------------------------------------------------
12
87102d3c 13#include <TLorentzVector.h>
ff7c57dd 14#include "AliVParticle.h"
2e7293a2 15#include <TArrayI.h>
df9db588 16#include "AliAODVertex.h"
17
87102d3c 18
ff7c57dd 19class AliAODJet : public AliVParticle {
df9db588 20
21 public:
87102d3c 22 AliAODJet();
23 AliAODJet(Double_t px, Double_t py, Double_t pz, Double_t e);
a1708071 24 AliAODJet(TLorentzVector & p);
87102d3c 25 virtual ~AliAODJet();
26 AliAODJet(const AliAODJet& jet);
27 AliAODJet& operator=(const AliAODJet& jet);
ff7c57dd 28// AliVParticle methods
87102d3c 29 virtual Double_t Px() const { return fMomentum->Px(); }
30 virtual Double_t Py() const { return fMomentum->Py(); }
31 virtual Double_t Pz() const { return fMomentum->Pz(); }
32 virtual Double_t Pt() const { return fMomentum->Pt(); }
33 virtual Double_t P() const { return fMomentum->P(); }
34 virtual Double_t OneOverPt() const { return 1. / fMomentum->Pt(); }
35 virtual Double_t Phi() const { return fMomentum->Phi(); }
36 virtual Double_t Theta() const { return fMomentum->Theta(); }
37 virtual Double_t E() const { return fMomentum->E(); }
38 virtual Double_t M() const { return fMomentum->M(); }
39 virtual Double_t Eta() const { return fMomentum->Eta(); }
40 virtual Double_t Y() const { return fMomentum->Rapidity();}
41//
2e7293a2 42 virtual void AddTrack(TObject *tr) {fRefTracks->Add(tr);}
43 TObject* GetTrack(Int_t i) {return fRefTracks->At(i);}
87102d3c 44 virtual void SetBgEnergy(Double_t bgEnCh, Double_t bgEnNe)
45 {fBackgEnergy[0] = bgEnCh; fBackgEnergy[1] = bgEnNe;}
46 virtual void SetEffArea(Double_t effACh, Double_t effANe)
47 {fEffectiveArea[0] = effACh; fEffectiveArea[1] = effANe;}
48
2e7293a2 49 virtual TRefArray* GetRefTracks() const { return fRefTracks;}
50 virtual Double_t ChargedBgEnergy() const { return fBackgEnergy[0];}
51 virtual Double_t NeutralBgEnergy() const { return fBackgEnergy[1];}
52 virtual Double_t TotalBgEnergy() const { return (fBackgEnergy[0] + fBackgEnergy[1]);}
87102d3c 53
2e7293a2 54 virtual Double_t EffectiveAreaCharged() const { return fEffectiveArea[0];}
55 virtual Double_t EffectiveAreaNeutral() const { return fEffectiveArea[1];}
87102d3c 56
57 virtual void Print(Option_t* /*option*/) const;
58
59// Dummy
60 virtual Short_t Charge() const { return 0;}
61 virtual const Double_t* PID() const { return NULL;}
62//
63
64
65 private:
9333290e 66 Double32_t fBackgEnergy[2]; // Subtracted background energy
67 Double32_t fEffectiveArea[2]; // Effective jet area used for background subtraction
68
87102d3c 69 TLorentzVector* fMomentum; // Jet 4-momentum vector
2e7293a2 70 TRefArray* fRefTracks; // array of references to the tracks belonging to the jet
9333290e 71
72 ClassDef(AliAODJet,3);
df9db588 73};
74
75#endif