]> git.uio.no Git - u/mrichter/AliRoot.git/blob - STEER/AliAODJet.cxx
Fixed class version number
[u/mrichter/AliRoot.git] / STEER / AliAODJet.cxx
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 //-------------------------------------------------------------------------
19 //     AOD class for jets
20 //     Author: Andreas Morsch, CERN
21 //-------------------------------------------------------------------------
22
23 #include <TLorentzVector.h>
24 #include "AliAODJet.h"
25
26 ClassImp(AliAODJet)
27
28
29 //______________________________________________________________________________
30 AliAODJet::AliAODJet() :
31     AliVirtualParticle(),
32     fMomentum(0)
33 {
34   // constructor
35     fBackgEnergy[0]   = 0.;     
36     fBackgEnergy[1]   = 0.;
37     fEffectiveArea[0] = 0.;   
38     fEffectiveArea[1] = 0.;   
39 }
40
41 AliAODJet::AliAODJet(Double_t px, Double_t py, Double_t pz, Double_t e):
42     AliVirtualParticle(),
43     fMomentum(0)
44 {
45   // constructor
46     fMomentum = new TLorentzVector(px, py, pz, e);
47     fBackgEnergy[0]   = 0.;     
48     fBackgEnergy[1]   = 0.;
49     fEffectiveArea[0] = 0.;   
50     fEffectiveArea[1] = 0.;   
51 }
52
53 AliAODJet::AliAODJet(TLorentzVector & p):
54     AliVirtualParticle(),
55     fMomentum(0)
56 {
57   // constructor
58     fMomentum = new TLorentzVector(p);
59     fBackgEnergy[0]   = 0.;     
60     fBackgEnergy[1]   = 0.;
61     fEffectiveArea[0] = 0.;   
62     fEffectiveArea[1] = 0.;   
63 }
64
65
66 //______________________________________________________________________________
67 AliAODJet::~AliAODJet() 
68 {
69   // destructor
70     delete fMomentum;
71 }
72
73 //______________________________________________________________________________
74 AliAODJet::AliAODJet(const AliAODJet& jet) :
75     AliVirtualParticle(jet),
76     fMomentum(0)
77 {
78   // Copy constructor
79     fMomentum = new TLorentzVector(*jet.fMomentum);
80     
81 }
82
83 //______________________________________________________________________________
84 AliAODJet& AliAODJet::operator=(const AliAODJet& jet)
85 {
86   // Assignment operator
87   if(this!=&jet) {
88   }
89
90   return *this;
91 }
92
93 void AliAODJet::Print(Option_t* /*option*/) const 
94 {
95   // Print information of all data members
96   printf("Jet 4-vector:\n");
97   printf("     E  = %13.3f\n", E() );
98   printf("     Px = %13.3f\n", Px());
99   printf("     Py = %13.3f\n", Py());
100   printf("     Pz = %13.3f\n", Pz());
101   printf("Background Energy:\n");
102   printf("Charged:  %13.3f\n", ChargedBgEnergy());
103   printf("Neutral:  %13.3f\n", NeutralBgEnergy());
104   printf("Total:    %13.3f\n", TotalBgEnergy());
105   printf("Effective Area: \n");
106   printf("Charged:  %13.3f\n", EffectiveAreaCharged());
107   printf("Neutral:  %13.3f\n", EffectiveAreaNeutral());
108 }