1 /**************************************************************************
2 * Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4 * Author: The ALICE Off-line Project. *
5 * Contributors are mentioned in the code where appropriate. *
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 **************************************************************************/
18 ////////////////////////////////////////////////
19 // RecPoints classes for set ZDC //
20 // This class reconstructs the space //
21 // points from digits //
22 // for the ZDC calorimeter //
23 ////////////////////////////////////////////////
26 #include "AliZDCReco.h"
31 //_____________________________________________________________________________
32 AliZDCReco::AliZDCReco() :
52 // Default constructor
54 for(Int_t i=0; i<10; i++){
55 fZN1EnTow[i] = fZP1EnTow[i] = fZN2EnTow[i] = fZP2EnTow[i] = 0.;
57 fZN1Energy[i] = fZP1Energy[i] = fZN2Energy[i] = fZP2Energy[i] = 0.;
58 fZEM1signal[i] = fZEM2signal[i] = 0.;
59 fPMRef1[i] = fPMRef2[i] = 0.;
65 //_____________________________________________________________________________
66 AliZDCReco::AliZDCReco(Float_t* ezn1, Float_t* ezp1, Float_t* ezn2, Float_t* ezp2,
67 Float_t* ezn1tow, Float_t* ezp1tow,
68 Float_t* ezn2tow, Float_t* ezp2tow,
69 Float_t* ezem1, Float_t* ezem2,
70 Float_t* ref1, Float_t* ref2,
72 Int_t detspnLeft, Int_t detsppLeft, Int_t detspnRight, Int_t detsppRight,
73 Int_t trspnLeft, Int_t trsppLeft, Int_t trspLeft,
74 Int_t trspnRight, Int_t trsppRight, Int_t trspRight,
75 Int_t partLeft, Int_t partRight, Float_t b) :
79 fNDetSpecNLeft(detspnLeft),
80 fNDetSpecPLeft(detsppLeft),
81 fNDetSpecNRight(detspnRight),
82 fNDetSpecPRight(detsppRight),
83 fNTrueSpecNLeft(trspnLeft),
84 fNTrueSpecPLeft(trsppLeft),
85 fNTrueSpecLeft(trspLeft),
86 fNTrueSpecNRight(trspnRight),
87 fNTrueSpecPRight(trsppRight),
88 fNTrueSpecRight(trspRight),
90 fNPartRight(partRight),
97 for(Int_t j=0; j<10; j++){
98 fZN1EnTow[j] = ezn1tow[j];
99 fZP1EnTow[j] = ezp1tow[j];
100 fZN2EnTow[j] = ezn2tow[j];
101 fZP2EnTow[j] = ezp2tow[j];
103 fZN1Energy[j] = ezn1[j];
104 fZP1Energy[j] = ezp1[j];
105 fZN2Energy[j] = ezn2[j];
106 fZP2Energy[j] = ezp2[j];
107 fZEM1signal[j] = ezem1[j];
108 fZEM2signal[j] = ezem2[j];
109 fPMRef1[j] = ref1[j];
110 fPMRef2[j] = ref2[j];
116 //______________________________________________________________________________
117 AliZDCReco::AliZDCReco(const AliZDCReco &oldreco) :
119 fNDetSpecNLeft(oldreco.GetNDetSpecNLeft()),
120 fNDetSpecPLeft(oldreco.GetNDetSpecPLeft()),
121 fNDetSpecNRight(oldreco.GetNDetSpecNRight()),
122 fNDetSpecPRight(oldreco.GetNDetSpecPRight()),
123 fNTrueSpecNLeft(oldreco.GetNTrueSpecNLeft()),
124 fNTrueSpecPLeft(oldreco.GetNTrueSpecPLeft()),
125 fNTrueSpecLeft(oldreco.GetNTrueSpecLeft()),
126 fNTrueSpecNRight(oldreco.GetNTrueSpecNRight()),
127 fNTrueSpecPRight(oldreco.GetNTrueSpecPRight()),
128 fNTrueSpecRight(oldreco.GetNTrueSpecRight()),
129 fNPartLeft(oldreco.GetNPartLeft()),
130 fNPartRight(oldreco.GetNPartRight()),
131 fImpPar(oldreco.GetImpPar())
135 fZN1Energy[0] = oldreco.GetZN1HREnergy();
136 fZP1Energy[0] = oldreco.GetZP1HREnergy();
137 fZN2Energy[0] = oldreco.GetZN2HREnergy();
138 fZP2Energy[0] = oldreco.GetZP2HREnergy();
140 fZN1Energy[1] = oldreco.GetZN1LREnergy();
141 fZP1Energy[1] = oldreco.GetZP1LREnergy();
142 fZN2Energy[1] = oldreco.GetZN2LREnergy();
143 fZP2Energy[1] = oldreco.GetZP2LREnergy();
145 for(Int_t i=0; i<5; i++){
146 fZN1EnTow[i] = oldreco.GetZN1HREnTow(i);
147 fZP1EnTow[i] = oldreco.GetZP1HREnTow(i);
148 fZN2EnTow[i] = oldreco.GetZN2HREnTow(i);
149 fZP2EnTow[i] = oldreco.GetZP2HREnTow(i);
150 fZN1EnTow[i+5] = oldreco.GetZN1LREnTow(i);
151 fZP1EnTow[i+5] = oldreco.GetZP1LREnTow(i);
152 fZN2EnTow[i+5] = oldreco.GetZN2LREnTow(i);
153 fZP2EnTow[i+5] = oldreco.GetZP2LREnTow(i);
155 fZEM1signal[0] = oldreco.GetZEM1HRsignal();
156 fZEM1signal[1] = oldreco.GetZEM1LRsignal();
157 fZEM2signal[0] = oldreco.GetZEM2HRsignal();
158 fZEM2signal[1] = oldreco.GetZEM2LRsignal();
159 fPMRef1[0] = oldreco.GetPMRef1HRsignal();
160 fPMRef1[1] = oldreco.GetPMRef1LRsignal();
161 fPMRef2[0] = oldreco.GetPMRef2HRsignal();
162 fPMRef2[1] = oldreco.GetPMRef2LRsignal();
165 //______________________________________________________________________________
166 void AliZDCReco::Print(Option_t *) const {
168 // Printing Reconstruction Parameters
170 printf(" \t --- Reconstruction -> EZN1 = %f TeV, EZP1 = %f TeV, EZEM1 = %f GeV , EZEM2 = %f GeV \n "
171 "EZN2 = %f TeV, EZP2 = %f TeV \n"
172 " \t NDetSpecNLeft = %d, NDetSpecPLeft = %d, NspecnLeft = %d,"
173 " NspecpLeft = %d, NpartLeft = %d"
174 " \t NDetSpecNRight = %d, NDetSpecPRight = %d, NspecnRight = %d,"
175 " NspecpRight = %d, NpartRight = %d"
177 fZN1Energy[0],fZP1Energy[0],fZEM1signal[0],fZEM2signal[0],
178 fZN2Energy[0], fZP2Energy[0],
179 fNDetSpecNLeft,fNDetSpecPLeft,fNTrueSpecNLeft,fNTrueSpecPLeft,fNPartLeft,
180 fNDetSpecNRight,fNDetSpecPRight,fNTrueSpecNRight,fNTrueSpecPRight,fNPartRight,