#include "TPad.h"
#include "TGraph.h"
#include "TPaveText.h"
#include "TClonesArray.h"
#include "TMath.h"
#include "TGeoMatrix.h"
#include "TGeoManager.h"
#include "TGeoPhysicalNode.h"
#include "TRandom.h"
#include <Riostream.h>
class AliGenerator;
class AliEMCAL;
#include "AliLog.h"
#include "AliGeomManager.h"
#include "AliEMCALGeometry.h"
#include "AliEMCALHit.h"
#include "AliEMCALDigit.h"
#include "AliEMCALRecPoint.h"
#include "AliCaloCalibPedestal.h"
#include "AliEMCALGeoParams.h"
ClassImp(AliEMCALRecPoint)
AliEMCALRecPoint::AliEMCALRecPoint()
: AliCluster(), fGeomPtr(0),
fAmp(0), fIndexInList(-1),
fGlobPos(0,0,0),fLocPos(0,0,0),
fMaxDigit(100), fMulDigit(0), fMaxTrack(200),
fMulTrack(0), fDigitsList(0), fTracksList(0),
fClusterType(-1), fCoreEnergy(0), fDispersion(0),
fEnergyList(0), fAbsIdList(0),
fTime(0.), fNExMax(0), fCoreRadius(10),
fDETracksList(0), fMulParent(0), fMaxParent(0),
fParentsList(0), fDEParentsList(0), fSuperModuleNumber(0),
fDigitIndMax(-1), fDistToBadTower(-1), fSharedCluster(kFALSE)
{
fGeomPtr = AliEMCALGeometry::GetInstance();
fLambda[0] = 0;
fLambda[1] = 0;
}
AliEMCALRecPoint::AliEMCALRecPoint(const char *)
: AliCluster(), fGeomPtr(0),
fAmp(0), fIndexInList(-1),
fGlobPos(0,0,0), fLocPos(0,0,0),
fMaxDigit(100), fMulDigit(0), fMaxTrack(1000), fMulTrack(0),
fDigitsList(new Int_t[fMaxDigit]), fTracksList(new Int_t[fMaxTrack]),
fClusterType(-1), fCoreEnergy(0), fDispersion(0),
fEnergyList(new Float_t[fMaxDigit]),
fAbsIdList(new Int_t[fMaxDigit]), fTime(-1.), fNExMax(0), fCoreRadius(10),
fDETracksList(new Float_t[fMaxTrack]), fMulParent(0), fMaxParent(1000),
fParentsList(new Int_t[fMaxParent]), fDEParentsList(new Float_t[fMaxParent]),
fSuperModuleNumber(0), fDigitIndMax(-1), fDistToBadTower(-1),fSharedCluster(kFALSE)
{
for (Int_t i = 0; i < fMaxTrack; i++)
fDETracksList[i] = 0;
for (Int_t i = 0; i < fMaxParent; i++) {
fParentsList[i] = -1;
fDEParentsList[i] = 0;
}
fGeomPtr = AliEMCALGeometry::GetInstance();
fLambda[0] = 0;
fLambda[1] = 0;
}
AliEMCALRecPoint::AliEMCALRecPoint(const AliEMCALRecPoint & rp)
: AliCluster(rp), fGeomPtr(rp.fGeomPtr),
fAmp(rp.fAmp), fIndexInList(rp.fIndexInList),
fGlobPos(rp.fGlobPos),fLocPos(rp.fLocPos),
fMaxDigit(rp.fMaxDigit), fMulDigit(rp.fMulDigit),
fMaxTrack(rp.fMaxTrack), fMulTrack(rp.fMaxTrack),
fDigitsList(new Int_t[rp.fMaxDigit]), fTracksList(new Int_t[rp.fMaxTrack]),
fClusterType(rp.fClusterType), fCoreEnergy(rp.fCoreEnergy),
fDispersion(rp.fDispersion),
fEnergyList(new Float_t[rp.fMaxDigit]),
fAbsIdList(new Int_t[rp.fMaxDigit]), fTime(rp.fTime), fNExMax(rp.fNExMax),fCoreRadius(rp.fCoreRadius),
fDETracksList(new Float_t[rp.fMaxTrack]), fMulParent(rp.fMulParent),
fMaxParent(rp.fMaxParent), fParentsList(new Int_t[rp.fMaxParent]),
fDEParentsList(new Float_t[rp.fMaxParent]),
fSuperModuleNumber(rp.fSuperModuleNumber), fDigitIndMax(rp.fDigitIndMax),
fDistToBadTower(rp.fDistToBadTower), fSharedCluster(rp.fSharedCluster)
{
fLambda[0] = rp.fLambda[0];
fLambda[1] = rp.fLambda[1];
for(Int_t i = 0; i < rp.fMulDigit; i++) {
fEnergyList[i] = rp.fEnergyList[i];
fAbsIdList[i] = rp.fAbsIdList[i];
}
for(Int_t i = 0; i < rp.fMulTrack; i++) fDETracksList[i] = rp.fDETracksList[i];
for(Int_t i = 0; i < rp.fMulParent; i++) {
fParentsList[i] = rp.fParentsList[i];
fDEParentsList[i] = rp.fDEParentsList[i];
}
}
AliEMCALRecPoint::~AliEMCALRecPoint()
{
if ( fEnergyList )
delete[] fEnergyList ;
if ( fAbsIdList )
delete[] fAbsIdList ;
if ( fDETracksList)
delete[] fDETracksList;
if ( fParentsList)
delete[] fParentsList;
if ( fDEParentsList)
delete[] fDEParentsList;
delete [] fDigitsList ;
delete [] fTracksList ;
}
AliEMCALRecPoint& AliEMCALRecPoint::operator= (const AliEMCALRecPoint &rp)
{
if(&rp == this) return *this;
fGeomPtr = rp.fGeomPtr;
fAmp = rp.fAmp;
fIndexInList = rp.fIndexInList;
fGlobPos = rp.fGlobPos;
fLocPos = rp.fLocPos;
fMaxDigit = rp.fMaxDigit;
fMulDigit = rp.fMulDigit;
fMaxTrack = rp.fMaxTrack;
fMulTrack = rp.fMulTrack;
if(fDigitsList) delete [] fDigitsList;
fDigitsList = new Int_t[rp.fMaxDigit];
if(fTracksList) delete [] fTracksList;
fTracksList = new Int_t[rp.fMaxTrack];
for(Int_t i = 0; i<fMaxDigit; i++) fDigitsList[i] = rp.fDigitsList[i];
for(Int_t i = 0; i<fMaxTrack; i++) fTracksList[i] = rp.fTracksList[i];
fClusterType = rp.fClusterType;
fCoreEnergy = rp.fCoreEnergy;
fDispersion = rp.fDispersion;
if(fEnergyList) delete [] fEnergyList;
fEnergyList = new Float_t[rp.fMaxDigit];
if(fAbsIdList) delete [] fAbsIdList;
fAbsIdList = new Int_t[rp.fMaxDigit];
for(Int_t i = 0; i<fMaxDigit; i++) {
fEnergyList[i] = rp.fEnergyList[i];
fAbsIdList[i] = rp.fAbsIdList[i];
}
fTime = rp.fTime;
fNExMax = rp.fNExMax;
fCoreRadius = rp.fCoreRadius;
if(fDETracksList) delete [] fDETracksList;
fDETracksList = new Float_t[rp.fMaxTrack];
for(Int_t i = 0; i < fMaxTrack; i++) fDETracksList[i] = rp.fDETracksList[i];
fMulParent = rp.fMulParent;
fMaxParent = rp.fMaxParent;
if(fParentsList) delete [] fParentsList;
fParentsList = new Int_t[rp.fMaxParent];
if(fDEParentsList) delete [] fDEParentsList;
fDEParentsList = new Float_t[rp.fMaxParent];
for(Int_t i = 0; i < fMaxParent; i++) {
fParentsList[i] = rp.fParentsList[i];
fDEParentsList[i] = rp.fDEParentsList[i];
}
fSuperModuleNumber = rp.fSuperModuleNumber;
fDigitIndMax = rp.fDigitIndMax;
fLambda[0] = rp.fLambda[0];
fLambda[1] = rp.fLambda[1];
fDistToBadTower = rp.fDistToBadTower;
fSharedCluster = rp.fSharedCluster;
return *this;
}
void AliEMCALRecPoint::AddDigit(AliEMCALDigit & digit, const Float_t energy, const Bool_t shared)
{
if(fEnergyList == 0)
fEnergyList = new Float_t[fMaxDigit];
if(fAbsIdList == 0) {
fAbsIdList = new Int_t [fMaxDigit];
}
if ( fMulDigit >= fMaxDigit ) {
fMaxDigit*=2 ;
Int_t * tempo = new Int_t [fMaxDigit];
Float_t * tempoE = new Float_t[fMaxDigit];
Int_t * tempoId = new Int_t [fMaxDigit];
Int_t index ;
for ( index = 0 ; index < fMulDigit ; index++ ){
tempo [index] = fDigitsList[index] ;
tempoE [index] = fEnergyList[index] ;
tempoId[index] = fAbsIdList [index] ;
}
delete [] fDigitsList ;
delete [] fEnergyList ;
delete [] fAbsIdList ;
fDigitsList = tempo;
fEnergyList = tempoE;
fAbsIdList = tempoId;
}
fDigitsList[fMulDigit] = digit.GetIndexInList() ;
fEnergyList[fMulDigit] = energy ;
fAbsIdList [fMulDigit] = digit.GetId();
fMulDigit++ ;
fAmp += energy ;
if(shared) fSharedCluster = kTRUE;
}
Bool_t AliEMCALRecPoint::AreNeighbours(AliEMCALDigit * digit1, AliEMCALDigit * digit2 ) const
{
Bool_t areNeighbours = kFALSE ;
Int_t nSupMod=0, nModule=0, nIphi=0, nIeta=0;
Int_t nSupMod1=0, nModule1=0, nIphi1=0, nIeta1=0;
Int_t relid1[2] , relid2[2] ;
Int_t rowdiff=0, coldiff=0;
areNeighbours = kFALSE ;
fGeomPtr->GetCellIndex(digit1->GetId(), nSupMod,nModule,nIphi,nIeta);
fGeomPtr->GetCellPhiEtaIndexInSModule(nSupMod,nModule,nIphi,nIeta, relid1[0],relid1[1]);
fGeomPtr->GetCellIndex(digit2->GetId(), nSupMod1,nModule1,nIphi1,nIeta1);
fGeomPtr->GetCellPhiEtaIndexInSModule(nSupMod1,nModule1,nIphi1,nIeta1, relid2[0],relid2[1]);
if(fSharedCluster){
if(nSupMod1%2) relid2[1]+=AliEMCALGeoParams::fgkEMCALCols;
else relid1[1]+=AliEMCALGeoParams::fgkEMCALCols;
}
rowdiff = TMath::Abs( relid1[0] - relid2[0] ) ;
coldiff = TMath::Abs( relid1[1] - relid2[1] ) ;
if ((coldiff + rowdiff == 1 ))
areNeighbours = kTRUE ;
return areNeighbours;
}
Int_t AliEMCALRecPoint::Compare(const TObject * obj) const
{
Float_t delta = 1 ;
Int_t rv = 2 ;
AliEMCALRecPoint * clu = (AliEMCALRecPoint *)obj ;
TVector3 locpos1;
GetLocalPosition(locpos1);
TVector3 locpos2;
clu->GetLocalPosition(locpos2);
Int_t rowdif = (Int_t)(TMath::Ceil(locpos1.X()/delta)-TMath::Ceil(locpos2.X()/delta)) ;
if (rowdif> 0)
rv = 1 ;
else if(rowdif < 0)
rv = -1 ;
else if(locpos1.Y()>locpos2.Y())
rv = -1 ;
else
rv = 1 ;
return rv ;
}
void AliEMCALRecPoint::Draw(Option_t *option)
{
AppendPad(option);
}
void AliEMCALRecPoint::EvalAll(Float_t logWeight,TClonesArray * digits, const Bool_t justClusters)
{
fDigitIndMax = GetMaximalEnergyIndex();
fSuperModuleNumber = fGeomPtr->GetSuperModuleNumber(GetAbsIdMaxDigit());
EvalGlobalPosition(logWeight, digits) ;
EvalLocalPosition(logWeight, digits) ;
EvalElipsAxis(logWeight, digits) ;
EvalDispersion(logWeight, digits) ;
EvalTime(digits) ;
EvalPrimaries(digits) ;
EvalParents(digits);
if(!justClusters){
EvalLocal2TrackingCSTransform();
}
}
void AliEMCALRecPoint::EvalDispersion(Float_t logWeight, TClonesArray * digits)
{
Double_t d = 0., wtot = 0., w = 0.;
Int_t iDigit=0, nstat=0;
AliEMCALDigit * digit=0;
Double_t etai, phii, etaMean=0.0, phiMean=0.0;
int nSupMod=0, nModule=0, nIphi=0, nIeta=0;
int iphi=0, ieta=0;
for(iDigit=0; iDigit < fMulDigit; iDigit++) {
digit = (AliEMCALDigit *) digits->At(fDigitsList[iDigit]) ;
if (fAmp>0 && fEnergyList[iDigit]>0) {
fGeomPtr->GetCellIndex(digit->GetId(), nSupMod,nModule,nIphi,nIeta);
fGeomPtr->GetCellPhiEtaIndexInSModule(nSupMod,nModule,nIphi,nIeta, iphi,ieta);
if(fSharedCluster && nSupMod%2) ieta+=AliEMCALGeoParams::fgkEMCALCols;
etai=(Double_t)ieta;
phii=(Double_t)iphi;
w = TMath::Max(0.,logWeight+TMath::Log(fEnergyList[iDigit]/fAmp ) ) ;
if(w>0.0) {
phiMean += phii*w;
etaMean += etai*w;
wtot += w;
}
}
}
if (wtot>0) {
phiMean /= wtot ;
etaMean /= wtot ;
} else AliError(Form("Wrong weight %f\n", wtot));
for(iDigit=0; iDigit < fMulDigit; iDigit++) {
digit = (AliEMCALDigit *) digits->At(fDigitsList[iDigit]) ;
if (fAmp>0 && fEnergyList[iDigit]>0) {
fGeomPtr->GetCellIndex(digit->GetId(), nSupMod,nModule,nIphi,nIeta);
fGeomPtr->GetCellPhiEtaIndexInSModule(nSupMod,nModule,nIphi,nIeta, iphi,ieta);
if(fSharedCluster && nSupMod%2) ieta+=AliEMCALGeoParams::fgkEMCALCols;
etai=(Double_t)ieta;
phii=(Double_t)iphi;
w = TMath::Max(0.,logWeight+TMath::Log(fEnergyList[iDigit]/fAmp ) ) ;
if(w>0.0) {
nstat++;
d += w*((etai-etaMean)*(etai-etaMean)+(phii-phiMean)*(phii-phiMean));
}
}
}
if ( wtot > 0 && nstat>1) d /= wtot ;
else d = 0. ;
fDispersion = TMath::Sqrt(d) ;
}
void AliEMCALRecPoint::EvalDistanceToBadChannels(AliCaloCalibPedestal* caloped)
{
if(!caloped->GetDeadTowerCount()) return;
TH2D* hMap = caloped->GetDeadMap(fSuperModuleNumber);
Int_t dRrow, dReta;
Float_t minDist = 10000.;
Float_t dist = 0.;
Int_t nSupMod, nModule;
Int_t nIphi, nIeta;
Int_t iphi, ieta;
fDigitIndMax = GetMaximalEnergyIndex();
fGeomPtr->GetCellIndex(fAbsIdList[fDigitIndMax], nSupMod,nModule,nIphi,nIeta);
fGeomPtr->GetCellPhiEtaIndexInSModule(nSupMod,nModule,nIphi,nIeta, iphi,ieta);
for(Int_t irow = 0; irow < AliEMCALGeoParams::fgkEMCALRows; irow++){
for(Int_t icol = 0; icol < AliEMCALGeoParams::fgkEMCALCols; icol++){
if(hMap->GetBinContent(icol,irow)==AliCaloCalibPedestal::kAlive) continue;
dRrow=TMath::Abs(irow-iphi);
dReta=TMath::Abs(icol-ieta);
dist=TMath::Sqrt(dRrow*dRrow+dReta*dReta);
if(dist < minDist) minDist = dist;
}
}
if (fSharedCluster) {
TH2D* hMap2 = 0;
Int_t nSupMod2 = -1;
if(fSuperModuleNumber%2) nSupMod2 = fSuperModuleNumber-1;
else nSupMod2 = fSuperModuleNumber+1;
hMap2 = caloped->GetDeadMap(nSupMod2);
for(Int_t irow = 0; irow < AliEMCALGeoParams::fgkEMCALRows; irow++){
for(Int_t icol = 0; icol < AliEMCALGeoParams::fgkEMCALCols; icol++){
if(hMap2->GetBinContent(icol,irow)==AliCaloCalibPedestal::kAlive) continue;
dRrow=TMath::Abs(irow-iphi);
if(fSuperModuleNumber%2) {
dReta=TMath::Abs(icol-(AliEMCALGeoParams::fgkEMCALCols+ieta));
}
else {
dReta=TMath::Abs(AliEMCALGeoParams::fgkEMCALCols+icol-ieta);
}
dist=TMath::Sqrt(dRrow*dRrow+dReta*dReta);
if(dist < minDist) minDist = dist;
}
}
}
fDistToBadTower = minDist;
}
void AliEMCALRecPoint::EvalLocalPosition(Float_t logWeight, TClonesArray * digits)
{
AliEMCALDigit * digit=0;
Int_t i=0, nstat=0;
Double_t dist = TmaxInCm(Double_t(fAmp));
Double_t clXYZ[3]={0.,0.,0.}, clRmsXYZ[3]={0.,0.,0.}, xyzi[3], wtot=0., w=0.;
for(Int_t iDigit=0; iDigit<fMulDigit; iDigit++) {
digit = dynamic_cast<AliEMCALDigit *>(digits->At(fDigitsList[iDigit])) ;
if(!digit) {
AliError("No Digit!!");
continue;
}
fGeomPtr->RelPosCellInSModule(digit->GetId(), dist, xyzi[0], xyzi[1], xyzi[2]);
if(fSharedCluster && fSuperModuleNumber != fGeomPtr->GetSuperModuleNumber(digit->GetId())) xyzi[1]*=-1;
if(logWeight > 0.0) w = TMath::Max( 0., logWeight + TMath::Log( fEnergyList[iDigit] / fAmp ));
else w = fEnergyList[iDigit];
if(w>0.0) {
wtot += w ;
nstat++;
for(i=0; i<3; i++ ) {
clXYZ[i] += (w*xyzi[i]);
clRmsXYZ[i] += (w*xyzi[i]*xyzi[i]);
}
}
}
if ( wtot > 0 ) {
for(i=0; i<3; i++ ) {
clXYZ[i] /= wtot;
if(nstat>1) {
clRmsXYZ[i] /= (wtot*wtot);
clRmsXYZ[i] = clRmsXYZ[i] - clXYZ[i]*clXYZ[i];
if(clRmsXYZ[i] > 0.0) {
clRmsXYZ[i] = TMath::Sqrt(clRmsXYZ[i]);
} else clRmsXYZ[i] = 0;
} else clRmsXYZ[i] = 0;
}
} else {
for(i=0; i<3; i++ ) {
clXYZ[i] = clRmsXYZ[i] = -1.;
}
}
fLocPos.SetX(clXYZ[0]);
fLocPos.SetY(clXYZ[1]);
fLocPos.SetZ(clXYZ[2]);
if (gDebug==2)
printf("EvalLocalPosition Cluster: Local (x,y,z) = (%f,%f,%f) \n", fLocPos.X(), fLocPos.Y(), fLocPos.Z()) ;
}
void AliEMCALRecPoint::EvalGlobalPosition(Float_t logWeight, TClonesArray * digits)
{
AliEMCALDigit * digit=0;
Int_t i=0, nstat=0;
Double_t dist = TmaxInCm(Double_t(fAmp));
Double_t clXYZ[3]={0.,0.,0.}, clRmsXYZ[3]={0.,0.,0.}, lxyzi[3], xyzi[3], wtot=0., w=0.;
for(Int_t iDigit=0; iDigit<fMulDigit; iDigit++) {
digit = dynamic_cast<AliEMCALDigit *>(digits->At(fDigitsList[iDigit])) ;
if(!digit) {
AliError("No Digit!!");
continue;
}
fGeomPtr->RelPosCellInSModule(digit->GetId(), dist, lxyzi[0], lxyzi[1], lxyzi[2]);
fGeomPtr->GetGlobal(lxyzi,xyzi, fGeomPtr->GetSuperModuleNumber(digit->GetId()));
if(logWeight > 0.0) w = TMath::Max( 0., logWeight + TMath::Log( fEnergyList[iDigit] / fAmp ));
else w = fEnergyList[iDigit];
if(w>0.0) {
wtot += w ;
nstat++;
for(i=0; i<3; i++ ) {
clXYZ[i] += (w*xyzi[i]);
clRmsXYZ[i] += (w*xyzi[i]*xyzi[i]);
}
}
}
if ( wtot > 0 ) {
for(i=0; i<3; i++ ) {
clXYZ[i] /= wtot;
if(nstat>1) {
clRmsXYZ[i] /= (wtot*wtot);
clRmsXYZ[i] = clRmsXYZ[i] - clXYZ[i]*clXYZ[i];
if(clRmsXYZ[i] > 0.0) {
clRmsXYZ[i] = TMath::Sqrt(clRmsXYZ[i]);
} else clRmsXYZ[i] = 0;
} else clRmsXYZ[i] = 0;
}
} else {
for(i=0; i<3; i++ ) {
clXYZ[i] = clRmsXYZ[i] = -1.;
}
}
fGlobPos.SetX(clXYZ[0]);
fGlobPos.SetY(clXYZ[1]);
fGlobPos.SetZ(clXYZ[2]);
if (gDebug==2)
printf("EvalGlobalPosition Cluster: (x ,y ,z) = (%f,%f,%f), eta %f,phi %f\n",
fGlobPos.X(), fGlobPos.Y(), fGlobPos.Z(),fGlobPos.Eta(),fGlobPos.Phi()*TMath::RadToDeg()) ;
}
void AliEMCALRecPoint::EvalLocalPositionFit(Double_t deff, Double_t logWeight,
Double_t phiSlope, TClonesArray * digits)
{
Double_t ycorr=0;
AliEMCALDigit *digit=0;
Int_t i=0, nstat=0;
Double_t clXYZ[3]={0.,0.,0.}, clRmsXYZ[3]={0.,0.,0.}, xyzi[3], wtot=0., w=0.;
Double_t dist = TmaxInCm(Double_t(fAmp));
for(Int_t iDigit=0; iDigit<digits->GetEntries(); iDigit++) {
digit = dynamic_cast<AliEMCALDigit *>(digits->At(fDigitsList[iDigit])) ;
if(digit){
dist = deff;
fGeomPtr->RelPosCellInSModule(digit->GetId(), dist, xyzi[0], xyzi[1], xyzi[2]);
if(logWeight > 0.0) w = TMath::Max( 0., logWeight + TMath::Log( fEnergyList[iDigit] / fAmp ));
else w = fEnergyList[iDigit];
if(w>0.0) {
wtot += w ;
nstat++;
for(i=0; i<3; i++ ) {
clXYZ[i] += (w*xyzi[i]);
clRmsXYZ[i] += (w*xyzi[i]*xyzi[i]);
}
}
}else AliError("Digit null");
}
if ( wtot > 0 ) {
for(i=0; i<3; i++ ) {
clXYZ[i] /= wtot;
if(nstat>1) {
clRmsXYZ[i] /= (wtot*wtot);
clRmsXYZ[i] = clRmsXYZ[i] - clXYZ[i]*clXYZ[i];
if(clRmsXYZ[i] > 0.0) {
clRmsXYZ[i] = TMath::Sqrt(clRmsXYZ[i]);
} else clRmsXYZ[i] = 0;
} else clRmsXYZ[i] = 0;
}
} else {
for(i=0; i<3; i++ ) {
clXYZ[i] = clRmsXYZ[i] = -1.;
}
}
if(phiSlope != 0.0 && logWeight > 0.0 && wtot) {
ycorr = clXYZ[1] * (1. + phiSlope);
clXYZ[1] = ycorr;
}
fLocPos.SetX(clXYZ[0]);
fLocPos.SetY(clXYZ[1]);
fLocPos.SetZ(clXYZ[2]);
}
Bool_t AliEMCALRecPoint::EvalLocalPosition2(TClonesArray * digits, TArrayD &ed)
{
return AliEMCALRecPoint::EvalLocalPositionFromDigits(digits, ed, fLocPos);
}
Bool_t AliEMCALRecPoint::EvalLocalPositionFromDigits(TClonesArray *digits, TArrayD &ed, TVector3 &locPos)
{
Double_t deff=0, w0=0, esum=0;
Int_t iDigit=0;
if(ed.GetSize() && (digits->GetEntries()!=ed.GetSize())) return kFALSE;
esum = 0.0;
for(iDigit=0; iDigit<ed.GetSize(); iDigit++) esum += ed[iDigit];
GetDeffW0(esum, deff, w0);
return EvalLocalPositionFromDigits(esum, deff, w0, digits, ed, locPos);
}
Bool_t AliEMCALRecPoint::EvalLocalPositionFromDigits(const Double_t esum, const Double_t deff, const Double_t w0, TClonesArray *digits, TArrayD &ed, TVector3 &locPos)
{
AliEMCALDigit *digit=0;
Int_t i=0, nstat=0;
Double_t clXYZ[3]={0.,0.,0.}, xyzi[3], wtot=0., w=0.;
AliEMCALGeometry* geo = AliEMCALGeometry::GetInstance();
for(Int_t iDigit=0; iDigit<digits->GetEntries(); iDigit++) {
digit = dynamic_cast<AliEMCALDigit *>(digits->At(iDigit));
if(digit){
geo->RelPosCellInSModule(digit->GetId(), deff, xyzi[0], xyzi[1], xyzi[2]);
if(w0 > 0.0) w = TMath::Max( 0., w0 + TMath::Log(ed[iDigit] / esum));
else w = ed[iDigit];
if(w>0.0) {
wtot += w ;
nstat++;
for(i=0; i<3; i++ ) {
clXYZ[i] += (w*xyzi[i]);
}
}
}else AliError("Digit null");
}
if (wtot > 0) {
for(i=0; i<3; i++ ) {
clXYZ[i] /= wtot;
}
locPos.SetX(clXYZ[0]);
locPos.SetY(clXYZ[1]);
locPos.SetZ(clXYZ[2]);
return kTRUE;
} else {
return kFALSE;
}
}
void AliEMCALRecPoint::GetDeffW0(const Double_t esum , Double_t &deff, Double_t &w0)
{
Double_t e=0.0;
const Double_t kdp0=9.25147, kdp1=1.16700;
const Double_t kwp0=4.83713, kwp1=-2.77970e-01, kwp2 = 4.41116;
e = esum<0.5?0.5:esum;
e = e>100.?100.:e;
deff = kdp0 + kdp1*TMath::Log(e);
w0 = kwp0 / (1. + TMath::Exp(kwp1*(e+kwp2)));
}
void AliEMCALRecPoint::EvalCoreEnergy(Float_t logWeight, TClonesArray * digits)
{
AliEMCALDigit * digit = 0 ;
Int_t iDigit=0;
if (!fLocPos.Mag()) {
EvalLocalPosition(logWeight, digits);
}
Double_t phiPoint = fLocPos.Phi(), etaPoint = fLocPos.Eta();
Double_t eta, phi, distance;
for(iDigit=0; iDigit < fMulDigit; iDigit++) {
digit = (AliEMCALDigit *) ( digits->At(fDigitsList[iDigit]) ) ;
eta = phi = 0.0;
fGeomPtr->EtaPhiFromIndex(digit->GetId(),eta, phi) ;
phi = phi * TMath::DegToRad();
distance = TMath::Sqrt((eta-etaPoint)*(eta-etaPoint)+(phi-phiPoint)*(phi-phiPoint));
if(distance < fCoreRadius)
fCoreEnergy += fEnergyList[iDigit] ;
}
}
void AliEMCALRecPoint::EvalElipsAxis(Float_t logWeight,TClonesArray * digits)
{
TString gn(fGeomPtr->GetName());
Double_t wtot = 0.;
Double_t x = 0.;
Double_t z = 0.;
Double_t dxx = 0.;
Double_t dzz = 0.;
Double_t dxz = 0.;
AliEMCALDigit * digit = 0;
Double_t etai =0, phii=0, w=0;
int nSupMod=0, nModule=0, nIphi=0, nIeta=0;
int iphi=0, ieta=0;
for(Int_t iDigit=0; iDigit<fMulDigit; iDigit++) {
digit = (AliEMCALDigit *) digits->At(fDigitsList[iDigit]) ;
etai = phii = 0.;
nSupMod = nModule = nIphi = nIeta = iphi = ieta = 0;
fGeomPtr->GetCellIndex(digit->GetId(), nSupMod,nModule,nIphi,nIeta);
fGeomPtr->GetCellPhiEtaIndexInSModule(nSupMod,nModule,nIphi,nIeta, iphi,ieta);
if(fSharedCluster && nSupMod%2) ieta+=AliEMCALGeoParams::fgkEMCALCols;
etai=(Double_t)ieta;
phii=(Double_t)iphi;
w = TMath::Max(0.,logWeight+TMath::Log(fEnergyList[iDigit]/fAmp ) ) ;
dxx += w * etai * etai ;
x += w * etai ;
dzz += w * phii * phii ;
z += w * phii ;
dxz += w * etai * phii ;
wtot += w ;
}
if ( wtot > 0 ) {
dxx /= wtot ;
x /= wtot ;
dxx -= x * x ;
dzz /= wtot ;
z /= wtot ;
dzz -= z * z ;
dxz /= wtot ;
dxz -= x * z ;
fLambda[0] = 0.5 * (dxx + dzz) + TMath::Sqrt( 0.25 * (dxx - dzz) * (dxx - dzz) + dxz * dxz ) ;
if(fLambda[0] > 0)
fLambda[0] = TMath::Sqrt(fLambda[0]) ;
else
fLambda[0] = 0;
fLambda[1] = 0.5 * (dxx + dzz) - TMath::Sqrt( 0.25 * (dxx - dzz) * (dxx - dzz) + dxz * dxz ) ;
if(fLambda[1] > 0)
fLambda[1] = TMath::Sqrt(fLambda[1]) ;
else
fLambda[1]= 0. ;
} else {
fLambda[0]= 0. ;
fLambda[1]= 0. ;
}
}
void AliEMCALRecPoint::EvalPrimaries(TClonesArray * digits)
{
AliEMCALDigit * digit =0;
Int_t * primArray = new Int_t[fMaxTrack] ;
memset(primArray,-1,sizeof(Int_t)*fMaxTrack);
Float_t * dEPrimArray = new Float_t[fMaxTrack] ;
memset(dEPrimArray,-1,sizeof(Int_t)*fMaxTrack);
Int_t index ;
for ( index = 0 ; index < GetDigitsMultiplicity() ; index++ ) {
digit = dynamic_cast<AliEMCALDigit *>(digits->At( fDigitsList[index] )) ;
if(!digit) {
AliError("No Digit!!");
continue;
}
Int_t nprimaries = digit->GetNprimary() ;
if ( nprimaries == 0 ) continue ;
Int_t jndex ;
for ( jndex = 0 ; jndex < nprimaries ; jndex++ ) {
if ( fMulTrack > fMaxTrack ) {
fMulTrack = fMaxTrack ;
Error("EvalPrimaries", "increase fMaxTrack ") ;
break ;
}
Int_t newPrimary = digit->GetPrimary(jndex+1);
Float_t dEPrimary = digit->GetDEPrimary(jndex+1);
Int_t kndex ;
Bool_t already = kFALSE ;
for ( kndex = 0 ; kndex < fMulTrack ; kndex++ ) {
if ( newPrimary == primArray[kndex] ){
already = kTRUE ;
dEPrimArray[kndex] += dEPrimary;
break ;
}
}
if ( !already && (fMulTrack < fMaxTrack)) {
primArray[fMulTrack] = newPrimary ;
dEPrimArray[fMulTrack] = dEPrimary ;
fMulTrack++ ;
}
}
}
Int_t *sortIdx = new Int_t[fMulTrack];
TMath::Sort(fMulTrack,dEPrimArray,sortIdx);
for(index = 0; index < fMulTrack; index++) {
fTracksList[index] = primArray[sortIdx[index]] ;
fDETracksList[index] = dEPrimArray[sortIdx[index]] ;
}
delete [] sortIdx;
delete [] primArray ;
delete [] dEPrimArray ;
}
void AliEMCALRecPoint::EvalParents(TClonesArray * digits)
{
AliEMCALDigit * digit=0 ;
Int_t * parentArray = new Int_t[fMaxTrack] ;
memset(parentArray,-1,sizeof(Int_t)*fMaxTrack);
Float_t * dEParentArray = new Float_t[fMaxTrack] ;
memset(dEParentArray,-1,sizeof(Int_t)*fMaxTrack);
Int_t index ;
for ( index = 0 ; index < GetDigitsMultiplicity() ; index++ ) {
if (fDigitsList[index] >= digits->GetEntries() || fDigitsList[index] < 0)
AliError(Form("Trying to get invalid digit %d (idx in WriteRecPoint %d)",fDigitsList[index],index));
digit = dynamic_cast<AliEMCALDigit *>(digits->At( fDigitsList[index] )) ;
if(!digit) {
AliError("No Digit!!");
continue;
}
Int_t nparents = digit->GetNiparent() ;
if ( nparents == 0 ) continue ;
Int_t jndex ;
for ( jndex = 0 ; jndex < nparents ; jndex++ ) {
if ( fMulParent > fMaxParent ) {
fMulTrack = - 1 ;
Error("EvalParents", "increase fMaxParent") ;
break ;
}
Int_t newParent = digit->GetIparent(jndex+1) ;
Float_t newdEParent = digit->GetDEParent(jndex+1) ;
Int_t kndex ;
Bool_t already = kFALSE ;
for ( kndex = 0 ; kndex < fMulParent ; kndex++ ) {
if ( newParent == parentArray[kndex] ){
dEParentArray[kndex] += newdEParent;
already = kTRUE ;
break ;
}
}
if ( !already && (fMulParent < fMaxParent)) {
parentArray[fMulParent] = newParent ;
dEParentArray[fMulParent] = newdEParent ;
fMulParent++ ;
}
}
}
if (fMulParent>0) {
Int_t *sortIdx = new Int_t[fMulParent];
TMath::Sort(fMulParent,dEParentArray,sortIdx);
for(index = 0; index < fMulParent; index++) {
fParentsList[index] = parentArray[sortIdx[index]] ;
fDEParentsList[index] = dEParentArray[sortIdx[index]] ;
}
delete [] sortIdx;
}
delete [] parentArray;
delete [] dEParentArray;
}
void AliEMCALRecPoint::GetLocalPosition(TVector3 & lpos) const
{
lpos = fLocPos;
}
void AliEMCALRecPoint::GetGlobalPosition(TVector3 & gpos) const
{
gpos = fGlobPos;
}
void AliEMCALRecPoint::EvalLocal2TrackingCSTransform()
{
SetVolumeId(AliGeomManager::LayerToVolUID(AliGeomManager::kEMCAL,GetSuperModuleNumber()));
const TGeoHMatrix* tr2loc = GetTracking2LocalMatrix();
if(!tr2loc) AliFatal(Form("No Tracking2LocalMatrix found."));
Double_t lxyz[3] = {fLocPos.X(),fLocPos.Y(),fLocPos.Z()};
Double_t txyz[3] = {0,0,0};
tr2loc->MasterToLocal(lxyz,txyz);
SetX(txyz[0]); SetY(txyz[1]); SetZ(txyz[2]);
if(AliLog::GetGlobalDebugLevel()>0) {
TVector3 gpos;
fGeomPtr->GetGlobal(fLocPos, gpos, GetSuperModuleNumber());
Float_t gxyz[3];
GetGlobalXYZ(gxyz);
AliInfo(Form("lCS-->(%.3f,%.3f,%.3f), tCS-->(%.3f,%.3f,%.3f), gCS-->(%.3f,%.3f,%.3f), gCScalc-\
->(%.3f,%.3f,%.3f), supermodule %d",
fLocPos.X(),fLocPos.Y(),fLocPos.Z(),
GetX(),GetY(),GetZ(),
gpos.X(),gpos.Y(),gpos.Z(),
gxyz[0],gxyz[1],gxyz[2],GetSuperModuleNumber()));
}
}
Float_t AliEMCALRecPoint::GetMaximalEnergy(void) const
{
Float_t menergy = 0. ;
Int_t iDigit;
for(iDigit=0; iDigit<fMulDigit; iDigit++) {
if(fEnergyList[iDigit] > menergy)
menergy = fEnergyList[iDigit] ;
}
return menergy ;
}
Int_t AliEMCALRecPoint::GetMaximalEnergyIndex(void) const
{
Float_t menergy = 0. ;
Int_t mid = 0 ;
Int_t iDigit;
for(iDigit=0; iDigit<fMulDigit; iDigit++) {
if(fEnergyList[iDigit] > menergy){
menergy = fEnergyList[iDigit] ;
mid = iDigit ;
}
}
return mid ;
}
Int_t AliEMCALRecPoint::GetMultiplicityAtLevel(Float_t H) const
{
Int_t multipl = 0 ;
Int_t iDigit ;
for(iDigit=0; iDigit<fMulDigit; iDigit++) {
if(fEnergyList[iDigit] > H * fAmp)
multipl++ ;
}
return multipl ;
}
Int_t AliEMCALRecPoint::GetNumberOfLocalMax(AliEMCALDigit ** maxAt, Float_t * maxAtEnergy,
Float_t locMaxCut,TClonesArray * digits) const
{
AliEMCALDigit * digit = 0;
AliEMCALDigit * digitN = 0;
Int_t iDigitN = 0 ;
Int_t iDigit = 0 ;
for(iDigit = 0; iDigit < fMulDigit; iDigit++)
maxAt[iDigit] = (AliEMCALDigit*) digits->At(fDigitsList[iDigit]) ;
for(iDigit = 0 ; iDigit < fMulDigit; iDigit++) {
if(maxAt[iDigit]) {
digit = maxAt[iDigit] ;
for(iDigitN = 0; iDigitN < fMulDigit; iDigitN++) {
if(iDigitN == iDigit) continue;
digitN = (AliEMCALDigit *) digits->At(fDigitsList[iDigitN]) ;
if ( AreNeighbours(digit, digitN) ) {
if (fEnergyList[iDigit] > fEnergyList[iDigitN] ) {
maxAt[iDigitN] = 0 ;
if(fEnergyList[iDigit] < fEnergyList[iDigitN] + locMaxCut)
maxAt[iDigit] = 0 ;
} else {
maxAt[iDigit] = 0 ;
if(fEnergyList[iDigit] > fEnergyList[iDigitN] - locMaxCut)
maxAt[iDigitN] = 0 ;
}
}
}
}
}
iDigitN = 0 ;
for(iDigit = 0; iDigit < fMulDigit; iDigit++) {
if(maxAt[iDigit] ){
maxAt[iDigitN] = maxAt[iDigit] ;
maxAtEnergy[iDigitN] = fEnergyList[iDigit] ;
iDigitN++ ;
}
}
return iDigitN ;
}
Int_t AliEMCALRecPoint::GetPrimaryIndex() const
{
if (fMulTrack)
return fTracksList[0];
return -12345;
}
void AliEMCALRecPoint::EvalTime(TClonesArray * digits){
Float_t maxE = 0;
Int_t maxAt = 0;
for(Int_t idig=0; idig < fMulDigit; idig++){
if(fEnergyList[idig] > maxE){
maxE = fEnergyList[idig] ;
maxAt = idig;
}
}
fTime = ((AliEMCALDigit*) digits->At(fDigitsList[maxAt]))->GetTime() ;
}
void AliEMCALRecPoint::Paint(Option_t *)
{
TVector3 pos(0.,0.,0.) ;
GetLocalPosition(pos) ;
Coord_t x = pos.X() ;
Coord_t y = pos.Z() ;
Color_t markercolor = 1 ;
Size_t markersize = 1.;
Style_t markerstyle = 5 ;
if (!gPad->IsBatch()) {
gVirtualX->SetMarkerColor(markercolor) ;
gVirtualX->SetMarkerSize (markersize) ;
gVirtualX->SetMarkerStyle(markerstyle) ;
}
gPad->SetAttMarkerPS(markercolor,markerstyle,markersize) ;
gPad->PaintPolyMarker(1,&x,&y,"") ;
}
Double_t AliEMCALRecPoint::TmaxInCm(const Double_t e , const Int_t key)
{
const Double_t ca = 4.82;
Double_t tmax = 0.;
Double_t x0 = 1.31;
if(!((fGeomPtr->GetEMCGeometry()->GetGeoName()).Contains("V1"))) x0 = 1.28;
if(e>0.1) {
tmax = TMath::Log(e) + ca;
if (key==0) tmax += 0.5;
else tmax -= 0.5;
tmax *= x0;
}
return tmax;
}
Float_t AliEMCALRecPoint::EtaToTheta(Float_t arg) const
{
return (2.*TMath::ATan(TMath::Exp(-arg)));
}
Float_t AliEMCALRecPoint::ThetaToEta(Float_t arg) const
{
return (-1 * TMath::Log(TMath::Tan(0.5 * arg)));
}
void AliEMCALRecPoint::Print(Option_t *opt) const
{
if(strlen(opt)==0) return;
TString message ;
message = "AliEMCALRecPoint:\n" ;
message += " digits # = " ;
AliInfo(message.Data()) ;
Int_t iDigit;
for(iDigit=0; iDigit<fMulDigit; iDigit++)
printf(" %d ", fDigitsList[iDigit] ) ;
printf("\n");
AliInfo(" Energies = ") ;
for(iDigit=0; iDigit<fMulDigit; iDigit++)
printf(" %f ", fEnergyList[iDigit] ) ;
printf("\n");
AliInfo("\n Abs Ids = ") ;
for(iDigit=0; iDigit<fMulDigit; iDigit++)
printf(" %i ", fAbsIdList[iDigit] ) ;
printf("\n");
AliInfo(" Primaries ") ;
for(iDigit = 0;iDigit < fMulTrack; iDigit++)
printf(" %d ", fTracksList[iDigit]) ;
printf("\n Local x %6.2f y %7.2f z %7.1f \n", fLocPos[0], fLocPos[1], fLocPos[2]);
message = " ClusterType = %d" ;
message += " Multiplicity = %d" ;
message += " Cluster Energy = %f" ;
message += " Core energy = %f" ;
message += " Core radius = %f" ;
message += " Number of primaries %d" ;
message += " Stored at position %d" ;
AliInfo(Form(message.Data(), fClusterType, fMulDigit, fAmp, fCoreEnergy, fCoreRadius, fMulTrack, GetIndexInList()) ) ;
}
Double_t AliEMCALRecPoint::GetPointEnergy() const
{
Double_t e=0.0;
for(int ic=0; ic<GetMultiplicity(); ic++) e += double(fEnergyList[ic]);
return e;
}
AliEMCALRecPoint.cxx:1000 AliEMCALRecPoint.cxx:1001 AliEMCALRecPoint.cxx:1002 AliEMCALRecPoint.cxx:1003 AliEMCALRecPoint.cxx:1004 AliEMCALRecPoint.cxx:1005 AliEMCALRecPoint.cxx:1006 AliEMCALRecPoint.cxx:1007 AliEMCALRecPoint.cxx:1008 AliEMCALRecPoint.cxx:1009 AliEMCALRecPoint.cxx:1010 AliEMCALRecPoint.cxx:1011 AliEMCALRecPoint.cxx:1012 AliEMCALRecPoint.cxx:1013 AliEMCALRecPoint.cxx:1014 AliEMCALRecPoint.cxx:1015 AliEMCALRecPoint.cxx:1016 AliEMCALRecPoint.cxx:1017 AliEMCALRecPoint.cxx:1018 AliEMCALRecPoint.cxx:1019 AliEMCALRecPoint.cxx:1020 AliEMCALRecPoint.cxx:1021 AliEMCALRecPoint.cxx:1022 AliEMCALRecPoint.cxx:1023 AliEMCALRecPoint.cxx:1024 AliEMCALRecPoint.cxx:1025 AliEMCALRecPoint.cxx:1026 AliEMCALRecPoint.cxx:1027 AliEMCALRecPoint.cxx:1028 AliEMCALRecPoint.cxx:1029 AliEMCALRecPoint.cxx:1030 AliEMCALRecPoint.cxx:1031 AliEMCALRecPoint.cxx:1032 AliEMCALRecPoint.cxx:1033 AliEMCALRecPoint.cxx:1034 AliEMCALRecPoint.cxx:1035 AliEMCALRecPoint.cxx:1036 AliEMCALRecPoint.cxx:1037 AliEMCALRecPoint.cxx:1038 AliEMCALRecPoint.cxx:1039 AliEMCALRecPoint.cxx:1040 AliEMCALRecPoint.cxx:1041 AliEMCALRecPoint.cxx:1042 AliEMCALRecPoint.cxx:1043 AliEMCALRecPoint.cxx:1044 AliEMCALRecPoint.cxx:1045 AliEMCALRecPoint.cxx:1046 AliEMCALRecPoint.cxx:1047 AliEMCALRecPoint.cxx:1048 AliEMCALRecPoint.cxx:1049 AliEMCALRecPoint.cxx:1050 AliEMCALRecPoint.cxx:1051 AliEMCALRecPoint.cxx:1052 AliEMCALRecPoint.cxx:1053 AliEMCALRecPoint.cxx:1054 AliEMCALRecPoint.cxx:1055 AliEMCALRecPoint.cxx:1056 AliEMCALRecPoint.cxx:1057 AliEMCALRecPoint.cxx:1058 AliEMCALRecPoint.cxx:1059 AliEMCALRecPoint.cxx:1060 AliEMCALRecPoint.cxx:1061 AliEMCALRecPoint.cxx:1062 AliEMCALRecPoint.cxx:1063 AliEMCALRecPoint.cxx:1064 AliEMCALRecPoint.cxx:1065 AliEMCALRecPoint.cxx:1066 AliEMCALRecPoint.cxx:1067 AliEMCALRecPoint.cxx:1068 AliEMCALRecPoint.cxx:1069 AliEMCALRecPoint.cxx:1070 AliEMCALRecPoint.cxx:1071 AliEMCALRecPoint.cxx:1072 AliEMCALRecPoint.cxx:1073 AliEMCALRecPoint.cxx:1074 AliEMCALRecPoint.cxx:1075 AliEMCALRecPoint.cxx:1076 AliEMCALRecPoint.cxx:1077 AliEMCALRecPoint.cxx:1078 AliEMCALRecPoint.cxx:1079 AliEMCALRecPoint.cxx:1080 AliEMCALRecPoint.cxx:1081 AliEMCALRecPoint.cxx:1082 AliEMCALRecPoint.cxx:1083 AliEMCALRecPoint.cxx:1084 AliEMCALRecPoint.cxx:1085 AliEMCALRecPoint.cxx:1086 AliEMCALRecPoint.cxx:1087 AliEMCALRecPoint.cxx:1088 AliEMCALRecPoint.cxx:1089 AliEMCALRecPoint.cxx:1090 AliEMCALRecPoint.cxx:1091 AliEMCALRecPoint.cxx:1092 AliEMCALRecPoint.cxx:1093 AliEMCALRecPoint.cxx:1094 AliEMCALRecPoint.cxx:1095 AliEMCALRecPoint.cxx:1096 AliEMCALRecPoint.cxx:1097 AliEMCALRecPoint.cxx:1098 AliEMCALRecPoint.cxx:1099 AliEMCALRecPoint.cxx:1100 AliEMCALRecPoint.cxx:1101 AliEMCALRecPoint.cxx:1102 AliEMCALRecPoint.cxx:1103 AliEMCALRecPoint.cxx:1104 AliEMCALRecPoint.cxx:1105 AliEMCALRecPoint.cxx:1106 AliEMCALRecPoint.cxx:1107 AliEMCALRecPoint.cxx:1108 AliEMCALRecPoint.cxx:1109 AliEMCALRecPoint.cxx:1110 AliEMCALRecPoint.cxx:1111 AliEMCALRecPoint.cxx:1112 AliEMCALRecPoint.cxx:1113 AliEMCALRecPoint.cxx:1114 AliEMCALRecPoint.cxx:1115 AliEMCALRecPoint.cxx:1116 AliEMCALRecPoint.cxx:1117 AliEMCALRecPoint.cxx:1118 AliEMCALRecPoint.cxx:1119 AliEMCALRecPoint.cxx:1120 AliEMCALRecPoint.cxx:1121 AliEMCALRecPoint.cxx:1122 AliEMCALRecPoint.cxx:1123 AliEMCALRecPoint.cxx:1124 AliEMCALRecPoint.cxx:1125 AliEMCALRecPoint.cxx:1126 AliEMCALRecPoint.cxx:1127 AliEMCALRecPoint.cxx:1128 AliEMCALRecPoint.cxx:1129 AliEMCALRecPoint.cxx:1130 AliEMCALRecPoint.cxx:1131 AliEMCALRecPoint.cxx:1132 AliEMCALRecPoint.cxx:1133 AliEMCALRecPoint.cxx:1134 AliEMCALRecPoint.cxx:1135 AliEMCALRecPoint.cxx:1136 AliEMCALRecPoint.cxx:1137 AliEMCALRecPoint.cxx:1138 AliEMCALRecPoint.cxx:1139 AliEMCALRecPoint.cxx:1140 AliEMCALRecPoint.cxx:1141 AliEMCALRecPoint.cxx:1142 AliEMCALRecPoint.cxx:1143 AliEMCALRecPoint.cxx:1144 AliEMCALRecPoint.cxx:1145 AliEMCALRecPoint.cxx:1146 AliEMCALRecPoint.cxx:1147 AliEMCALRecPoint.cxx:1148 AliEMCALRecPoint.cxx:1149 AliEMCALRecPoint.cxx:1150 AliEMCALRecPoint.cxx:1151 AliEMCALRecPoint.cxx:1152 AliEMCALRecPoint.cxx:1153 AliEMCALRecPoint.cxx:1154 AliEMCALRecPoint.cxx:1155 AliEMCALRecPoint.cxx:1156 AliEMCALRecPoint.cxx:1157 AliEMCALRecPoint.cxx:1158 AliEMCALRecPoint.cxx:1159 AliEMCALRecPoint.cxx:1160 AliEMCALRecPoint.cxx:1161 AliEMCALRecPoint.cxx:1162 AliEMCALRecPoint.cxx:1163 AliEMCALRecPoint.cxx:1164 AliEMCALRecPoint.cxx:1165 AliEMCALRecPoint.cxx:1166 AliEMCALRecPoint.cxx:1167 AliEMCALRecPoint.cxx:1168 AliEMCALRecPoint.cxx:1169 AliEMCALRecPoint.cxx:1170 AliEMCALRecPoint.cxx:1171 AliEMCALRecPoint.cxx:1172 AliEMCALRecPoint.cxx:1173 AliEMCALRecPoint.cxx:1174 AliEMCALRecPoint.cxx:1175 AliEMCALRecPoint.cxx:1176 AliEMCALRecPoint.cxx:1177 AliEMCALRecPoint.cxx:1178 AliEMCALRecPoint.cxx:1179 AliEMCALRecPoint.cxx:1180 AliEMCALRecPoint.cxx:1181 AliEMCALRecPoint.cxx:1182 AliEMCALRecPoint.cxx:1183 AliEMCALRecPoint.cxx:1184 AliEMCALRecPoint.cxx:1185 AliEMCALRecPoint.cxx:1186 AliEMCALRecPoint.cxx:1187 AliEMCALRecPoint.cxx:1188 AliEMCALRecPoint.cxx:1189 AliEMCALRecPoint.cxx:1190 AliEMCALRecPoint.cxx:1191 AliEMCALRecPoint.cxx:1192 AliEMCALRecPoint.cxx:1193 AliEMCALRecPoint.cxx:1194 AliEMCALRecPoint.cxx:1195 AliEMCALRecPoint.cxx:1196 AliEMCALRecPoint.cxx:1197 AliEMCALRecPoint.cxx:1198 AliEMCALRecPoint.cxx:1199 AliEMCALRecPoint.cxx:1200 AliEMCALRecPoint.cxx:1201 AliEMCALRecPoint.cxx:1202 AliEMCALRecPoint.cxx:1203 AliEMCALRecPoint.cxx:1204 AliEMCALRecPoint.cxx:1205 AliEMCALRecPoint.cxx:1206 AliEMCALRecPoint.cxx:1207 AliEMCALRecPoint.cxx:1208 AliEMCALRecPoint.cxx:1209 AliEMCALRecPoint.cxx:1210 AliEMCALRecPoint.cxx:1211 AliEMCALRecPoint.cxx:1212 AliEMCALRecPoint.cxx:1213 AliEMCALRecPoint.cxx:1214 AliEMCALRecPoint.cxx:1215 AliEMCALRecPoint.cxx:1216 AliEMCALRecPoint.cxx:1217 AliEMCALRecPoint.cxx:1218 AliEMCALRecPoint.cxx:1219 AliEMCALRecPoint.cxx:1220 AliEMCALRecPoint.cxx:1221 AliEMCALRecPoint.cxx:1222 AliEMCALRecPoint.cxx:1223 AliEMCALRecPoint.cxx:1224 AliEMCALRecPoint.cxx:1225 AliEMCALRecPoint.cxx:1226 AliEMCALRecPoint.cxx:1227 AliEMCALRecPoint.cxx:1228 AliEMCALRecPoint.cxx:1229 AliEMCALRecPoint.cxx:1230 AliEMCALRecPoint.cxx:1231 AliEMCALRecPoint.cxx:1232 AliEMCALRecPoint.cxx:1233 AliEMCALRecPoint.cxx:1234 AliEMCALRecPoint.cxx:1235 AliEMCALRecPoint.cxx:1236 AliEMCALRecPoint.cxx:1237 AliEMCALRecPoint.cxx:1238 AliEMCALRecPoint.cxx:1239 AliEMCALRecPoint.cxx:1240 AliEMCALRecPoint.cxx:1241 AliEMCALRecPoint.cxx:1242 AliEMCALRecPoint.cxx:1243 AliEMCALRecPoint.cxx:1244 AliEMCALRecPoint.cxx:1245 AliEMCALRecPoint.cxx:1246 AliEMCALRecPoint.cxx:1247 AliEMCALRecPoint.cxx:1248 AliEMCALRecPoint.cxx:1249 AliEMCALRecPoint.cxx:1250 AliEMCALRecPoint.cxx:1251 AliEMCALRecPoint.cxx:1252 AliEMCALRecPoint.cxx:1253 AliEMCALRecPoint.cxx:1254 AliEMCALRecPoint.cxx:1255 AliEMCALRecPoint.cxx:1256 AliEMCALRecPoint.cxx:1257 AliEMCALRecPoint.cxx:1258 AliEMCALRecPoint.cxx:1259 AliEMCALRecPoint.cxx:1260 AliEMCALRecPoint.cxx:1261 AliEMCALRecPoint.cxx:1262 AliEMCALRecPoint.cxx:1263 AliEMCALRecPoint.cxx:1264 AliEMCALRecPoint.cxx:1265 AliEMCALRecPoint.cxx:1266 AliEMCALRecPoint.cxx:1267 AliEMCALRecPoint.cxx:1268 AliEMCALRecPoint.cxx:1269 AliEMCALRecPoint.cxx:1270 AliEMCALRecPoint.cxx:1271 AliEMCALRecPoint.cxx:1272 AliEMCALRecPoint.cxx:1273 AliEMCALRecPoint.cxx:1274 AliEMCALRecPoint.cxx:1275 AliEMCALRecPoint.cxx:1276 AliEMCALRecPoint.cxx:1277 AliEMCALRecPoint.cxx:1278 AliEMCALRecPoint.cxx:1279 AliEMCALRecPoint.cxx:1280 AliEMCALRecPoint.cxx:1281 AliEMCALRecPoint.cxx:1282 AliEMCALRecPoint.cxx:1283 AliEMCALRecPoint.cxx:1284 AliEMCALRecPoint.cxx:1285 AliEMCALRecPoint.cxx:1286 AliEMCALRecPoint.cxx:1287 AliEMCALRecPoint.cxx:1288 AliEMCALRecPoint.cxx:1289 AliEMCALRecPoint.cxx:1290 AliEMCALRecPoint.cxx:1291 AliEMCALRecPoint.cxx:1292 AliEMCALRecPoint.cxx:1293 AliEMCALRecPoint.cxx:1294 AliEMCALRecPoint.cxx:1295 AliEMCALRecPoint.cxx:1296 AliEMCALRecPoint.cxx:1297 AliEMCALRecPoint.cxx:1298 AliEMCALRecPoint.cxx:1299 AliEMCALRecPoint.cxx:1300 AliEMCALRecPoint.cxx:1301 AliEMCALRecPoint.cxx:1302 AliEMCALRecPoint.cxx:1303 AliEMCALRecPoint.cxx:1304 AliEMCALRecPoint.cxx:1305 AliEMCALRecPoint.cxx:1306 AliEMCALRecPoint.cxx:1307 AliEMCALRecPoint.cxx:1308 AliEMCALRecPoint.cxx:1309 AliEMCALRecPoint.cxx:1310 AliEMCALRecPoint.cxx:1311 AliEMCALRecPoint.cxx:1312 AliEMCALRecPoint.cxx:1313 AliEMCALRecPoint.cxx:1314 AliEMCALRecPoint.cxx:1315 AliEMCALRecPoint.cxx:1316 AliEMCALRecPoint.cxx:1317 AliEMCALRecPoint.cxx:1318 AliEMCALRecPoint.cxx:1319 AliEMCALRecPoint.cxx:1320 AliEMCALRecPoint.cxx:1321 AliEMCALRecPoint.cxx:1322 AliEMCALRecPoint.cxx:1323 AliEMCALRecPoint.cxx:1324 AliEMCALRecPoint.cxx:1325 AliEMCALRecPoint.cxx:1326 AliEMCALRecPoint.cxx:1327 AliEMCALRecPoint.cxx:1328 AliEMCALRecPoint.cxx:1329 AliEMCALRecPoint.cxx:1330 AliEMCALRecPoint.cxx:1331 AliEMCALRecPoint.cxx:1332 AliEMCALRecPoint.cxx:1333 AliEMCALRecPoint.cxx:1334 AliEMCALRecPoint.cxx:1335 AliEMCALRecPoint.cxx:1336 AliEMCALRecPoint.cxx:1337 AliEMCALRecPoint.cxx:1338 AliEMCALRecPoint.cxx:1339 AliEMCALRecPoint.cxx:1340 AliEMCALRecPoint.cxx:1341 AliEMCALRecPoint.cxx:1342 AliEMCALRecPoint.cxx:1343 AliEMCALRecPoint.cxx:1344 AliEMCALRecPoint.cxx:1345 AliEMCALRecPoint.cxx:1346 AliEMCALRecPoint.cxx:1347 AliEMCALRecPoint.cxx:1348 AliEMCALRecPoint.cxx:1349 AliEMCALRecPoint.cxx:1350 AliEMCALRecPoint.cxx:1351 AliEMCALRecPoint.cxx:1352 AliEMCALRecPoint.cxx:1353 AliEMCALRecPoint.cxx:1354 AliEMCALRecPoint.cxx:1355 AliEMCALRecPoint.cxx:1356 AliEMCALRecPoint.cxx:1357 AliEMCALRecPoint.cxx:1358 AliEMCALRecPoint.cxx:1359 AliEMCALRecPoint.cxx:1360 AliEMCALRecPoint.cxx:1361 AliEMCALRecPoint.cxx:1362 AliEMCALRecPoint.cxx:1363 AliEMCALRecPoint.cxx:1364 AliEMCALRecPoint.cxx:1365 AliEMCALRecPoint.cxx:1366 AliEMCALRecPoint.cxx:1367 AliEMCALRecPoint.cxx:1368 AliEMCALRecPoint.cxx:1369 AliEMCALRecPoint.cxx:1370 AliEMCALRecPoint.cxx:1371 AliEMCALRecPoint.cxx:1372 AliEMCALRecPoint.cxx:1373 AliEMCALRecPoint.cxx:1374 AliEMCALRecPoint.cxx:1375 AliEMCALRecPoint.cxx:1376 AliEMCALRecPoint.cxx:1377 AliEMCALRecPoint.cxx:1378 AliEMCALRecPoint.cxx:1379 AliEMCALRecPoint.cxx:1380 AliEMCALRecPoint.cxx:1381 AliEMCALRecPoint.cxx:1382 AliEMCALRecPoint.cxx:1383 AliEMCALRecPoint.cxx:1384 AliEMCALRecPoint.cxx:1385 AliEMCALRecPoint.cxx:1386 AliEMCALRecPoint.cxx:1387 AliEMCALRecPoint.cxx:1388 AliEMCALRecPoint.cxx:1389 AliEMCALRecPoint.cxx:1390 AliEMCALRecPoint.cxx:1391 AliEMCALRecPoint.cxx:1392 AliEMCALRecPoint.cxx:1393 AliEMCALRecPoint.cxx:1394 AliEMCALRecPoint.cxx:1395 AliEMCALRecPoint.cxx:1396 AliEMCALRecPoint.cxx:1397 AliEMCALRecPoint.cxx:1398 AliEMCALRecPoint.cxx:1399 AliEMCALRecPoint.cxx:1400 AliEMCALRecPoint.cxx:1401 AliEMCALRecPoint.cxx:1402 AliEMCALRecPoint.cxx:1403 AliEMCALRecPoint.cxx:1404 AliEMCALRecPoint.cxx:1405 AliEMCALRecPoint.cxx:1406 AliEMCALRecPoint.cxx:1407