fNTmpHits = 0 ;
fTmpHits = 0 ;
- // Create an empty array of CPVModule to satisfy
+ // Create an empty array of AliPHOSCPVModule to satisfy
// AliPHOSv1::Streamer when reading root file
- if ( NULL==(fCPVModules=new TClonesArray("CPVModule",0)) ) {
+ if ( NULL==(fCPVModules=new TClonesArray("AliPHOSCPVModule",0)) ) {
Error("AliPHOSv1","Can not create array of CPV modules");
exit(1);
}
// Create array of CPV modules for the IHEP's version of CPV
if ( strcmp(fGeom->GetName(),"IHEP") == 0 ) {
- // Create array of CPVmodule of the size of PHOS modules number
+ // Create array of AliPHOSCPVmodule of the size of PHOS modules number
- if ( NULL==(fCPVModules=new TClonesArray("CPVModule",fGeom->GetNModules())) ) {
+ if ( NULL==(fCPVModules=new TClonesArray("AliPHOSCPVModule",fGeom->GetNModules())) ) {
Error("AliPHOSv1","Can not create array of CPV modules");
exit(1);
}
TClonesArray &lcpvmodule = *fCPVModules;
- for (Int_t i=0; i<fGeom->GetNModules(); i++) new(lcpvmodule[i]) CPVModule();
+ for (Int_t i=0; i<fGeom->GetNModules(); i++) new(lcpvmodule[i]) AliPHOSCPVModule();
}
else {
- // Create an empty array of CPVModule to satisfy
+ // Create an empty array of AliPHOSCPVModule to satisfy
// AliPHOSv1::Streamer when writing root file
- fCPVModules=new TClonesArray("CPVModule",0);
+ fCPVModules=new TClonesArray("AliPHOSCPVModule",0);
}
}
AliDetector::ResetHits();
if ( strcmp(fGeom->GetName(),"IHEP") == 0 ) {
- for (Int_t i=0; i<fGeom->GetNModules(); i++) ((CPVModule*)(*fCPVModules)[i]) -> Clear();
+ for (Int_t i=0; i<fGeom->GetNModules(); i++) ((AliPHOSCPVModule*)(*fCPVModules)[i]) -> Clear();
}
}
//____________________________________________________________________________
// 1. find pad response and
- TClonesArray *cpvDigits = new TClonesArray("CPVDigit",0); // array of digits for current hit
+ TClonesArray *cpvDigits = new TClonesArray("AliPHOSCPVDigit",0); // array of digits for current hit
CPVDigitize(pmom,xyd,ModuleNumber,cpvDigits);
Float_t xmean = 0;
ndigits = cpvDigits->GetEntriesFast();
for (Int_t idigit=0; idigit<ndigits-1; idigit++) {
- CPVDigit *cpvDigit1 = (CPVDigit*) cpvDigits->UncheckedAt(idigit);
+ AliPHOSCPVDigit *cpvDigit1 = (AliPHOSCPVDigit*) cpvDigits->UncheckedAt(idigit);
Float_t x1 = cpvDigit1->GetXpad() ;
Float_t z1 = cpvDigit1->GetYpad() ;
for (Int_t jdigit=idigit+1; jdigit<ndigits; jdigit++) {
- CPVDigit *cpvDigit2 = (CPVDigit*) cpvDigits->UncheckedAt(jdigit);
+ AliPHOSCPVDigit *cpvDigit2 = (AliPHOSCPVDigit*) cpvDigits->UncheckedAt(jdigit);
Float_t x2 = cpvDigit2->GetXpad() ;
Float_t z2 = cpvDigit2->GetYpad() ;
if (x1==x2 && z1==z2) {
ndigits = cpvDigits->GetEntriesFast();
for (Int_t idigit=0; idigit<ndigits; idigit++) {
- CPVDigit *cpvDigit = (CPVDigit*) cpvDigits->UncheckedAt(idigit);
+ AliPHOSCPVDigit *cpvDigit = (AliPHOSCPVDigit*) cpvDigits->UncheckedAt(idigit);
relid[0] = ModuleNumber + 1 ; // CPV (or PHOS) module number
relid[1] =-1 ; // means CPV
relid[2] = cpvDigit->GetXpad() ; // column number of a pad
// axis X goes across the beam in the module plane
// axis Y is a normal to the module plane showing from the IP
+// cout << __PRETTY_FUNCTION__ << ": YVK : Start digitization\n";
+
Float_t hitX = zxhit[0];
Float_t hitZ =-zxhit[1];
Float_t pX = p.Px();
Float_t pNorm = p.Py();
Float_t E = dEdx;
+// cout << "CPVDigitize: YVK : "<<hitX<<" "<<hitZ<<" | "<<pX<<" "<<pZ<<" "<<pNorm<<endl;
+
Float_t dZY = pZ/pNorm * fGeom->GetCPVGasThickness();
Float_t dXY = pX/pNorm * fGeom->GetCPVGasThickness();
gRandom->Rannor(rnor1,rnor2);
Float_t zhit2 = zhit1 + dZY;
Float_t xhit2 = xhit1 + dXY;
+// cout << "CPVDigitize: YVK : "<<xhit1<<" "<<xhit2<<" | "<<zhit1<<" "<<zhit2<<" | "
+// << (Int_t)(xhit1/fGeom->GetPadSizePhi())<<" "<<(Int_t)(zhit1/fGeom->GetPadSizeZ())<<" "<<endl;
+
Int_t iwht1 = (Int_t) (xhit1 / celWr); // wire (x) coordinate "in"
Int_t iwht2 = (Int_t) (xhit2 / celWr); // wire (x) coordinate "out"
TClonesArray &ldigits = *(TClonesArray *)cpvDigits;
for (Int_t iter=0; iter<nIter; iter++) {
+// cout << "CPVDigitize: YVK : iter="<<iter<<endl;
Float_t zhit = zxe[0][iter];
Float_t xhit = zxe[1][iter];
if (qpad<0) continue;
// Fill the array with pad response ID and amplitude
- new(ldigits[cpvDigits->GetEntriesFast()]) CPVDigit(kxg,kzg,qpad);
+ new(ldigits[cpvDigits->GetEntriesFast()]) AliPHOSCPVDigit(kxg,kzg,qpad);
// printf("(%2d,%2d,%5.3f) ",kxg,kzg,qpad);
}
// cout << endl;
// --- ROOT system ---
#include "TClonesArray.h"
-#include "TH1.h"
// --- AliRoot header files ---
#include "AliPHOSv0.h"
#include "AliPHOSReconstructioner.h"
#include "AliPHOSTrackSegmentMaker.h"
#include "AliPHOSPID.h"
-#include "AliPHOSCPV.h"
+#include "AliPHOSCPVModule.h"
+#include "AliPHOSCPVHit.h"
+#include "AliPHOSCPVDigit.h"
class AliPHOSv1 : public AliPHOSv0 {
// IHEP's CPV specific functions
- CPVModule &GetCPVModule(int n) { return *(CPVModule*)fCPVModules->operator[](n); }
+ AliPHOSCPVModule &GetCPVModule(int n) { return *(AliPHOSCPVModule*)fCPVModules->operator[](n); }
void CPVDigitize (TLorentzVector p, Float_t *xy, Int_t moduleNumber, TClonesArray *digits) ;
Float_t CPVPadResponseFunction(Float_t qhit, Float_t zg, Float_t xg) ;
Double_t CPVCumulPadResponse(Double_t x, Double_t y) ;
PACKAGE = PHOS
+MYLIBDIR = ~/lib/tgt_$(ALICE_TARGET)
+
# C++ sources
SRCS = AliPHOS.cxx AliPHOSv0.cxx AliPHOSv1.cxx AliPHOSv2.cxx \
AliPHOSv3.cxx AliPHOSv4.cxx \
AliPHOSHit.cxx \
AliPHOSGeometry.cxx \
- AliEMCAGeometry.cxx \
- AliCPVGeometry.cxx AliCPVBaseGeometry.cxx AliPPSDGeometry.cxx \
- AliPHOSCPV.cxx \
+ AliPHOSEMCAGeometry.cxx \
+ AliPHOSCPVGeometry.cxx AliPHOSCPVBaseGeometry.cxx AliPHOSPPSDGeometry.cxx \
+ AliPHOSCPVModule.cxx AliPHOSCPVDigit.cxx AliPHOSCPVHit.cxx \
AliPHOSDigit.cxx \
- AliPHOSRecPoint.cxx AliPHOSEmcRecPoint.cxx AliPHOSPpsdRecPoint.cxx \
+ AliPHOSRecPoint.cxx AliPHOSEmcRecPoint.cxx \
+ AliPHOSPpsdRecPoint.cxx AliPHOSCpvRecPoint.cxx \
AliPHOSClusterizer.cxx AliPHOSClusterizerv1.cxx AliPHOSLink.cxx \
AliPHOSReconstructioner.cxx AliPHOSTrackSegment.cxx \
AliPHOSTrackSegmentMaker.cxx AliPHOSTrackSegmentMakerv1.cxx \
AliPHOSRecParticle.cxx AliPHOSPID.cxx AliPHOSPIDv1.cxx \
AliPHOSAnalyze.cxx AliPHOSFastRecParticle.cxx \
- AliPHOSIndexToObject.cxx \
+ AliPHOSIndexToObject.cxx
# C++ Headers
##### COMMANDS #####
-SLIBRARY = $(LIBDIR)/libPHOS.$(SL)
+SLIBRARY = $(MYLIBDIR)/libPHOS.$(SL)
default: $(SLIBRARY)
-$(LIBDIR)/libPHOS.$(SL): $(OBJS) $(FOBJS)
+$(MYLIBDIR)/libPHOS.$(SL): $(OBJS) $(FOBJS)
$(DICT): $(HDRS)
#pragma link C++ class AliPHOS ;
#pragma link C++ class AliPHOSClusterizer ;
#pragma link C++ class AliPHOSClusterizerv1 ;
+#pragma link C++ class AliPHOSCpvRecPoint ;
#pragma link C++ class AliPHOSDigit ;
#pragma link C++ class AliPHOSEmcRecPoint ;
#pragma link C++ class AliPHOSFastRecParticle ;
#pragma link C++ class AliPHOSPID ;
#pragma link C++ class AliPHOSPIDv1 ;
#pragma link C++ class AliPHOSAnalyze ;
-#pragma link C++ class AliEMCAGeometry ;
-#pragma link C++ class AliCPVBaseGeometry ;
-#pragma link C++ class AliCPVGeometry ;
-#pragma link C++ class AliPPSDGeometry ;
-#pragma link C++ class CPVModule ;
-#pragma link C++ class CPVHit ;
-#pragma link C++ class CPVDigit ;
+#pragma link C++ class AliPHOSEMCAGeometry ;
+#pragma link C++ class AliPHOSCPVBaseGeometry ;
+#pragma link C++ class AliPHOSCPVGeometry ;
+#pragma link C++ class AliPHOSPPSDGeometry ;
+#pragma link C++ class AliPHOSCPVModule ;
+#pragma link C++ class AliPHOSCPVHit ;
+#pragma link C++ class AliPHOSCPVDigit ;
#endif