]> git.uio.no Git - u/mrichter/AliRoot.git/blame - STEER/AliAODJet.cxx
removed definition
[u/mrichter/AliRoot.git] / STEER / AliAODJet.cxx
CommitLineData
df9db588 1/**************************************************************************
2 * Copyright(c) 1998-2007, ALICE Experiment at CERN, All rights reserved. *
3 * *
4 * Author: The ALICE Off-line Project. *
5 * Contributors are mentioned in the code where appropriate. *
6 * *
7 * Permission to use, copy, modify and distribute this software and its *
8 * documentation strictly for non-commercial purposes is hereby granted *
9 * without fee, provided that the above copyright notice appears in all *
10 * copies and that both the copyright notice and this permission notice *
11 * appear in the supporting documentation. The authors make no claims *
12 * about the suitability of this software for any purpose. It is *
13 * provided "as is" without express or implied warranty. *
14 **************************************************************************/
15
16/* $Id$ */
17
18//-------------------------------------------------------------------------
87102d3c 19// AOD class for jets
20// Author: Andreas Morsch, CERN
df9db588 21//-------------------------------------------------------------------------
22
87102d3c 23#include <TLorentzVector.h>
df9db588 24#include "AliAODJet.h"
25
26ClassImp(AliAODJet)
27
28
29//______________________________________________________________________________
a1708071 30AliAODJet::AliAODJet() :
ff7c57dd 31 AliVParticle(),
2e7293a2 32 fMomentum(0),
33 fRefTracks(new TRefArray())
df9db588 34{
35 // constructor
a1708071 36 fBackgEnergy[0] = 0.;
37 fBackgEnergy[1] = 0.;
38 fEffectiveArea[0] = 0.;
39 fEffectiveArea[1] = 0.;
df9db588 40}
41
87102d3c 42AliAODJet::AliAODJet(Double_t px, Double_t py, Double_t pz, Double_t e):
ff7c57dd 43 AliVParticle(),
2e7293a2 44 fMomentum(0),
45 fRefTracks(new TRefArray())
87102d3c 46{
47 // constructor
87102d3c 48 fBackgEnergy[0] = 0.;
49 fBackgEnergy[1] = 0.;
50 fEffectiveArea[0] = 0.;
51 fEffectiveArea[1] = 0.;
9333290e 52 fMomentum = new TLorentzVector(px, py, pz, e);
87102d3c 53}
54
a1708071 55AliAODJet::AliAODJet(TLorentzVector & p):
ff7c57dd 56 AliVParticle(),
2e7293a2 57 fMomentum(0),
58 fRefTracks(new TRefArray())
87102d3c 59{
60 // constructor
87102d3c 61 fBackgEnergy[0] = 0.;
62 fBackgEnergy[1] = 0.;
63 fEffectiveArea[0] = 0.;
64 fEffectiveArea[1] = 0.;
9333290e 65 fMomentum = new TLorentzVector(p);
87102d3c 66}
67
68
df9db588 69//______________________________________________________________________________
70AliAODJet::~AliAODJet()
71{
72 // destructor
87102d3c 73 delete fMomentum;
2e7293a2 74 delete fRefTracks;
df9db588 75}
76
77//______________________________________________________________________________
78AliAODJet::AliAODJet(const AliAODJet& jet) :
ff7c57dd 79 AliVParticle(jet),
87102d3c 80 fMomentum(0)
df9db588 81{
82 // Copy constructor
2e7293a2 83 fBackgEnergy[0] = jet.fBackgEnergy[0];
d3ad3ee1 84 fBackgEnergy[1] = jet.fBackgEnergy[1];
2e7293a2 85 fEffectiveArea[0] = jet.fEffectiveArea[0];
86 fEffectiveArea[1] = jet.fEffectiveArea[1];
9333290e 87
88 fMomentum = new TLorentzVector(*jet.fMomentum);
89 fRefTracks = new TRefArray(*jet.fRefTracks);
df9db588 90}
91
92//______________________________________________________________________________
93AliAODJet& AliAODJet::operator=(const AliAODJet& jet)
94{
95 // Assignment operator
96 if(this!=&jet) {
9333290e 97
98 fBackgEnergy[0] = jet.fBackgEnergy[0];
99 fBackgEnergy[1] = jet.fBackgEnergy[1];
100 fEffectiveArea[0] = jet.fEffectiveArea[0];
101 fEffectiveArea[1] = jet.fEffectiveArea[1];
102
103 delete fMomentum;
104 fMomentum = new TLorentzVector(*jet.fMomentum);
105 delete fRefTracks;
106 fRefTracks = new TRefArray(*jet.fRefTracks);
df9db588 107 }
108
109 return *this;
110}
111
87102d3c 112void AliAODJet::Print(Option_t* /*option*/) const
113{
114 // Print information of all data members
115 printf("Jet 4-vector:\n");
116 printf(" E = %13.3f\n", E() );
117 printf(" Px = %13.3f\n", Px());
118 printf(" Py = %13.3f\n", Py());
119 printf(" Pz = %13.3f\n", Pz());
120 printf("Background Energy:\n");
121 printf("Charged: %13.3f\n", ChargedBgEnergy());
122 printf("Neutral: %13.3f\n", NeutralBgEnergy());
123 printf("Total: %13.3f\n", TotalBgEnergy());
124 printf("Effective Area: \n");
125 printf("Charged: %13.3f\n", EffectiveAreaCharged());
126 printf("Neutral: %13.3f\n", EffectiveAreaNeutral());
127}