/*
$Log$
+Revision 1.3 2000/10/22 16:56:32 morsch
+- Store chamber number as slat id.
+
+Revision 1.2 2000/10/18 11:42:06 morsch
+- AliMUONRawCluster contains z-position.
+- Some clean-up of useless print statements during initialisations.
+
+Revision 1.1 2000/10/06 08:59:03 morsch
+Segmentation classes for bending and non bending plane slat modules (A. de Falco, A. Morsch)
+
*/
/////////////////////////////////////////////////////
for (Int_t i=fNsec-1; i > 0; i--) {
if (x >= fCx[i-1]) {
isec=i;
+ if (fCx[isec] == fCx[isec-1] && isec > 1) isec--;
break;
}
}
//
// Find sector isec
Int_t isec=AliMUONSegmentationSlatModule::Sector(ix,iy);
- if (isec == -1) printf("\n PadC %d %d %d \n ", isec, ix, iy);
+ if (isec == -1) printf("\n PadC %d %d %d %d \n ", isec, fId, ix, iy);
//
if (isec>0) {
x = fCx[isec-1]+(ix-fNpxS[isec-1])*(*fDpxD)[isec];
Float_t x02=x0a + dx;
Float_t y01=yhit - dy;
Float_t y02=yhit + dy;
-
if (x01 < 0) x01 = 0;
if (y01 < 0) y01 = 0;
+
+ if (x02 >= fCx[fNsec-1]) x02 = fCx[fNsec-1];
+ if (y02 >= fDyPCB) y02 = fDyPCB;
+
Int_t isec=-1;
for (Int_t i=fNsec-1; i > 0; i--) {
if (x02 >= fCx[i-1]) {
isec=i;
+ if (fCx[isec] == fCx[isec-1] && isec > 1) isec--;
break;
}
}
- if (x02 >= fCx[fNsec-1]) x02 = fCx[fNsec-1];
- if (y02 >= fDyPCB) y02 = fDyPCB;
//
// find the pads over which the charge distributes
GetPadI(x01,y01,fIxmin,fIymin);
GetPadI(x02,y02,fIxmax,fIymax);
+
if (fIxmax > fNpx) fIxmax=fNpx;
if (fIymax > fNpyS[isec]) fIymax = fNpyS[isec];
fXmin=x01;
// printf("\n \n First Pad: %d %d %f %f %d %d %d %f" ,
// fIxmin, fIxmax, fXmin, fXmax, fNpx, fId, isec, Dpy(isec));
// printf("\n \n First Pad: %d %d %f %f %d %d %d %f",
-// fIymin, fIymax, fYmin, fYmax, fNpy, fId, isec, Dpy(isec));
+// fIymin, fIymax, fYmin, fYmax, fNpyS[isec], fId, isec, Dpy(isec));
}
void AliMUONSegmentationSlatModule::NextPad()
void AliMUONSegmentationSlatModule::Init(Int_t chamber)
{
- printf("\n Initialise segmentation SlatModule \n");
+ printf("\n Initialise Segmentation SlatModule \n");
//
// Fill the arrays fCx (x-contour) and fNpxS (ix-contour) for each sector
// These arrays help in converting from real to pad co-ordinates and
if (fNsec > 1) {
for (Int_t i=fNsec-2; i>=0; i--){
(*fDpxD)[i]=(*fDpxD)[fNsec-1]/(*fNDiv)[i];
- printf("\n test ---dx %d %f \n",i,(*fDpxD)[i]);
}
}
//
// maximum number of pad rows
fNpy=nPyPCB;
fNpx=fNpxS[3];
+//
+ fId = chamber;
+
}