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