]> git.uio.no Git - u/mrichter/AliRoot.git/commitdiff
(1) Client code adapted to new method signatures in AliMUONSegmentation (see comments...
authormorsch <morsch@f7af4fe6-9843-0410-8265-dc069ae4e863>
Wed, 28 Jun 2000 15:16:35 +0000 (15:16 +0000)
committermorsch <morsch@f7af4fe6-9843-0410-8265-dc069ae4e863>
Wed, 28 Jun 2000 15:16:35 +0000 (15:16 +0000)
to allow development of slat-muon chamber simulation and reconstruction code in the MUON
framework. The changes should have no side effects (mostly dummy arguments).
(2) Hit disintegration uses 3-dim hit coordinates to allow simulation
of chambers with overlapping modules (MakePadHits, Disintegration).

MUON/AliMUON.cxx
MUON/AliMUON.h
MUON/AliMUONChamber.cxx
MUON/AliMUONChamber.h
MUON/AliMUONChamberTrigger.cxx
MUON/AliMUONChamberTrigger.h
MUON/AliMUONClusterFinderVS.cxx
MUON/AliMUONClusterInput.cxx
MUON/AliMUONDisplay.cxx
MUON/AliMUONTriggerCircuit.cxx
MUON/AliMUONv1.cxx

index 04a6585d5c9ab11c69ad035d549c2b6af7c3eab0..fdcefc7cf4cc440e58e11825170c4d4967580ebf 100644 (file)
  **************************************************************************/
 /*
 $Log$
+Revision 1.23  2000/06/28 12:19:17  morsch
+More consequent seperation of global input data services (AliMUONClusterInput singleton) and the
+cluster and hit reconstruction algorithms in AliMUONClusterFinderVS.
+AliMUONClusterFinderVS becomes the base class for clustering and hit reconstruction.
+It requires two cathode planes. Small modifications in the code will make it usable for
+one cathode plane and, hence, more general (for test beam data).
+AliMUONClusterFinder is now obsolete.
+
 Revision 1.22  2000/06/28 08:06:10  morsch
 Avoid global variables in AliMUONClusterFinderVS by seperating the input data for the fit from the
 algorithmic part of the class. Input data resides inside the AliMUONClusterInput singleton.
@@ -807,7 +815,7 @@ void   AliMUON::SetNsec(Int_t id, Int_t nsec)
 
 
 
-void AliMUON::MakePadHits(Float_t xhit,Float_t yhit,
+void AliMUON::MakePadHits(Float_t xhit,Float_t yhit, Float_t zhit,
                          Float_t eloss, Float_t tof,  Int_t idvol)
 {
 //
@@ -827,7 +835,7 @@ void AliMUON::MakePadHits(Float_t xhit,Float_t yhit,
 //
 //
     ((AliMUONChamber*) (*fChambers)[idvol])
-       ->DisIntegration(eloss, tof, xhit, yhit, nnew, newclust);
+       ->DisIntegration(eloss, tof, xhit, yhit, zhit, nnew, newclust);
     Int_t ic=0;
     
 //
@@ -996,9 +1004,9 @@ void AliMUON::Digitise(Int_t nev,Int_t bgrEvent,Option_t *option,Option_t *opt,T
                    
                    if (cathode != (icat+1)) continue;
                    // fill the info array
-                   Float_t thex, they;
+                   Float_t thex, they, thez;
                    segmentation=iChamber->SegmentationModel(cathode);
-                   segmentation->GetPadCxy(ipx,ipy,thex,they);
+                   segmentation->GetPadCxy(ipx,ipy,thex,they,thez);
 //                 Float_t rpad=TMath::Sqrt(thex*thex+they*they);
 //                 if (rpad < rmin || iqpad ==0 || rpad > rmax) continue;
 
@@ -1114,9 +1122,9 @@ void AliMUON::Digitise(Int_t nev,Int_t bgrEvent,Option_t *option,Option_t *opt,T
                        Int_t iqpad    = Int_t(mPad->fQpad);// charge per pad
 
                        if (cathode != (icat+1)) continue;
-                       Float_t thex, they;
+                       Float_t thex, they, thez;
                        segmentation=iChamber->SegmentationModel(cathode);
-                       segmentation->GetPadCxy(ipx,ipy,thex,they);
+                       segmentation->GetPadCxy(ipx,ipy,thex,they,thez);
                        Float_t rpad=TMath::Sqrt(thex*thex+they*they);
                        if (rpad < rmin || iqpad ==0 || rpad > rmax) continue;
                        new((*pAddress)[countadr++]) TVector(2);
index 7b742fc842cfbad53c809c0f91a0f74483f5b30d..965ee54706282c5ba893a96304687e28d18051ef 100644 (file)
@@ -89,7 +89,7 @@ class AliMUON : public  AliDetector {
     virtual void   SetMaxDestepAlu(Float_t p1);
     virtual void   SetMuonAcc(Bool_t acc=0, Float_t angmin=2, Float_t angmax=9);
 // Response Simulation
-    virtual void   MakePadHits(Float_t xhit,Float_t yhit,
+    virtual void   MakePadHits(Float_t xhit,Float_t yhit, Float_t zhit,
                               Float_t eloss, Float_t tof, Int_t id);
 // get Trigger answer
     void   Trigger(Int_t nev);
index 29b3a4734f8ff45927a017a15300970499faa355..45a4027e3de9f9ef7b772e151079842ea15d0793 100644 (file)
@@ -14,6 +14,9 @@
  **************************************************************************/
 /*
 $Log$
+Revision 1.2  2000/06/15 07:58:48  morsch
+Code from MUON-dev joined
+
 Revision 1.1.2.5  2000/06/09 21:27:01  morsch
 Most coding rule violations corrected.
 
@@ -96,7 +99,7 @@ void    AliMUONChamber::SigGenInit(Float_t x, Float_t y, Float_t z)
 }
 
 void AliMUONChamber::DisIntegration(Float_t eloss, Float_t tof, 
-                                   Float_t xhit, Float_t yhit,
+                                   Float_t xhit, Float_t yhit, Float_t zhit,
                                    Int_t& nnew,Float_t newclust[6][500]) 
 {
 //    
@@ -120,7 +123,7 @@ void AliMUONChamber::DisIntegration(Float_t eloss, Float_t tof,
        qcheck=0;
        AliMUONSegmentation * segmentation=
            (AliMUONSegmentation *) (*fSegmentation)[i-1];
-       for (segmentation->FirstPad(xhit, yhit, dx, dy); 
+       for (segmentation->FirstPad(xhit, yhit, zhit, dx, dy); 
             segmentation->MorePads(); 
             segmentation->NextPad()) 
        {
index b5c3b8e7c2ed8a5792c64bc301d156da5ca9b8ff..d8af746abe2a0e583c3d4dba7dcbc69edd078052 100644 (file)
@@ -99,7 +99,7 @@ public TObject
 //  
 // Cluster formation method (charge disintegration)
   virtual void   DisIntegration(Float_t eloss, Float_t tof,
-                               Float_t xhit, Float_t yhit,
+                               Float_t xhit, Float_t yhit, Float_t zhit,
                                Int_t& x, Float_t newclust[6][500]);
 // Initialize geometry related parameters  
   virtual void    InitGeo(Float_t z);
index 0ae5613b7edf6b53f582544136c6a51d1cafb0bf..f9a4333749dc8b7743fe08645716a070bca80b54 100644 (file)
@@ -15,6 +15,9 @@
 
 /*
 $Log$
+Revision 1.2  2000/06/15 07:58:48  morsch
+Code from MUON-dev joined
+
 Revision 1.1.2.3  2000/06/09 21:27:35  morsch
 Most coding rule violations corrected.
 
@@ -44,7 +47,7 @@ AliMUONChamberTrigger::AliMUONChamberTrigger() : AliMUONChamber()
 
 //-------------------------------------------
 void AliMUONChamberTrigger::DisIntegration(Float_t eloss, Float_t tof, 
-                                          Float_t xhit, Float_t yhit, 
+                                          Float_t xhit, Float_t yhit, Float_t zhit, 
                                           Int_t& nnew,
                                           Float_t newclust[6][500]) 
 {
@@ -70,7 +73,7 @@ void AliMUONChamberTrigger::DisIntegration(Float_t eloss, Float_t tof,
 // Find the module & strip Id. which has fired
     Int_t ix,iy;
     
-    segmentation->GetPadIxy(xhit,yhit,ix,iy);
+    segmentation->GetPadIxy(xhit,yhit,0,ix,iy);
     segmentation->SetPad(ix,iy);
 
 // treatment of GEANT hits w/o corresponding strip (due to the fact that
@@ -87,7 +90,7 @@ void AliMUONChamberTrigger::DisIntegration(Float_t eloss, Float_t tof,
       newclust[5][nnew]=(Float_t) i;              // counter
       nnew++;
       // set hits
-      segmentation->SetHit(xhit,yhit);
+      segmentation->SetHit(xhit,yhit,zhit);
       // get the list of nearest neighbours
       Int_t nList, xList[2], yList[2];
       segmentation->Neighbours(ix,iy,&nList,xList,yList);
@@ -95,8 +98,8 @@ void AliMUONChamberTrigger::DisIntegration(Float_t eloss, Float_t tof,
       for (Int_t j=0; j<nList; j++){
        
        // neighbour real coordinates (just for checks here)
-       Float_t x,y;
-       segmentation->GetPadCxy(xList[j],yList[j],x,y);
+       Float_t x,y,z;
+       segmentation->GetPadCxy(xList[j],yList[j],x,y,z);
        // set pad (fx fy & fix fiy are the current pad coord. & Id.)
        segmentation->SetPad(xList[j],yList[j]);
        // get the chamber (i.e. current strip) response
index 1664ca1240e587cb110c0e5857c404645639dcba..c5be7202509a2d51ede5770a5a5d79a96aab5b4a 100644 (file)
@@ -19,9 +19,9 @@ public AliMUONChamber {
     AliMUONChamberTrigger();
     virtual ~AliMUONChamberTrigger(){}
 // Cluster formation method (charge disintegration)
-
-  virtual void   DisIntegration(Float_t eloss, Float_t tof, Float_t xhit, Float_t yhit,
-                               Int_t& nnew, Float_t newclust[6][500]);
+    
+    virtual void   DisIntegration(Float_t eloss, Float_t tof, Float_t xhit, Float_t yhit, Float_t zhit,
+                                       Int_t& nnew, Float_t newclust[6][500]);
 
   ClassDef(AliMUONChamberTrigger,1) // Muon trigger chamber class
       };
index 250b9155bd2cf3ac85452a68c89f19149757194d..424137f50dfefd86c7c14a71945699c34afc37dd 100644 (file)
  **************************************************************************/
 /*
 $Log$
+Revision 1.6  2000/06/28 12:19:18  morsch
+More consequent seperation of global input data services (AliMUONClusterInput singleton) and the
+cluster and hit reconstruction algorithms in AliMUONClusterFinderVS.
+AliMUONClusterFinderVS becomes the base class for clustering and hit reconstruction.
+It requires two cathode planes. Small modifications in the code will make it usable for
+one cathode plane and, hence, more general (for test beam data).
+AliMUONClusterFinder is now obsolete.
+
 Revision 1.5  2000/06/28 08:06:10  morsch
 Avoid global variables in AliMUONClusterFinderVS by seperating the input data for the fit from the
 algorithmic part of the class. Input data resides inside the AliMUONClusterInput singleton.
@@ -115,7 +123,7 @@ void AliMUONClusterFinderVS::SplitByLocalMaxima(AliMUONRawCluster *c)
 //  dump digit information into arrays
 //
 
-    Float_t qtot;
+    Float_t qtot, zdum;
     
     for (cath=0; cath<2; cath++) {
        qtot=0;
@@ -130,7 +138,7 @@ void AliMUONClusterFinderVS::SplitByLocalMaxima(AliMUONRawCluster *c)
            fQ[i][cath] = fDig[i][cath]->fSignal;
            // pad centre coordinates
            fInput->Segmentation(cath)->
-               GetPadCxy(fIx[i][cath], fIy[i][cath], fX[i][cath], fY[i][cath]);
+               GetPadCxy(fIx[i][cath], fIy[i][cath], fX[i][cath], fY[i][cath], zdum);
        } // loop over cluster digits
     }  // loop over cathodes
 
@@ -887,7 +895,7 @@ void AliMUONClusterFinderVS::FindLocalMaxima(AliMUONRawCluster* c)
 // get neighbours for that digit and assume that it is local maximum       
            isLocal[i][cath]=kTRUE;
 // compare signal to that on the two neighbours on the left and on the right
-           fInput->Segmentation(cath)->GetPadIxy(fX[i][cath],fY[i][cath]+dpy,ix,iy);
+           fInput->Segmentation(cath)->GetPadIxy(fX[i][cath],fY[i][cath]+dpy,0,ix,iy);
 // iNN counts the number of neighbours with signal, it should be 1 or 2
            Int_t iNN=0;
            if (fHitMap[cath]->TestHit(ix, iy)!=kEmpty) {
@@ -895,7 +903,7 @@ void AliMUONClusterFinderVS::FindLocalMaxima(AliMUONRawCluster* c)
                digt=(AliMUONDigit*) fHitMap[cath]->GetHit(ix,iy);
                if (digt->fSignal > fQ[i][cath]) isLocal[i][cath]=kFALSE;
            }
-           fInput->Segmentation(cath)->GetPadIxy(fX[i][cath],fY[i][cath]-dpy,ix,iy);
+           fInput->Segmentation(cath)->GetPadIxy(fX[i][cath],fY[i][cath]-dpy,0,ix,iy);
            if (fHitMap[cath]->TestHit(ix, iy)!=kEmpty) {
                iNN++;
                digt=(AliMUONDigit*) fHitMap[cath]->GetHit(ix,iy);
@@ -940,7 +948,7 @@ void AliMUONClusterFinderVS::FindLocalMaxima(AliMUONRawCluster* c)
 // get neighbours for that digit and assume that it is local maximum       
            isLocal[i][cath]=kTRUE;
 // compare signal to that on the two neighbours on the left and on the right
-           fInput->Segmentation(cath)->GetPadIxy(fX[i][cath]+dpx,fY[i][cath],ix,iy);
+           fInput->Segmentation(cath)->GetPadIxy(fX[i][cath]+dpx,fY[i][cath],0,ix,iy);
 // iNN counts the number of neighbours with signal, it should be 1 or 2
            Int_t iNN=0;
            if (fHitMap[cath]->TestHit(ix, iy)!=kEmpty) {
@@ -948,7 +956,7 @@ void AliMUONClusterFinderVS::FindLocalMaxima(AliMUONRawCluster* c)
                digt=(AliMUONDigit*) fHitMap[cath]->GetHit(ix,iy);
                if (digt->fSignal > fQ[i][cath]) isLocal[i][cath]=kFALSE;
            }
-           fInput->Segmentation(cath)->GetPadIxy(fX[i][cath]-dpx,fY[i][cath],ix,iy);
+           fInput->Segmentation(cath)->GetPadIxy(fX[i][cath]-dpx,fY[i][cath],0,ix,iy);
            if (fHitMap[cath]->TestHit(ix, iy)!=kEmpty) {
                iNN++;
                digt=(AliMUONDigit*) fHitMap[cath]->GetHit(ix,iy);
@@ -980,7 +988,7 @@ void  AliMUONClusterFinderVS::FillCluster(AliMUONRawCluster* c, Int_t flag, Int_
 //  Completes cluster information starting from list of digits
 //
     AliMUONDigit* dig;
-    Float_t x, y;
+    Float_t x, y, z;
     Int_t  ix, iy;
     
     if (cath==1) {
@@ -1023,7 +1031,7 @@ void  AliMUONClusterFinderVS::FillCluster(AliMUONRawCluster* c, Int_t flag, Int_
        }
 //
        if (flag) {
-           fInput->Segmentation(cath)->GetPadCxy(ix, iy, x, y);
+           fInput->Segmentation(cath)->GetPadCxy(ix, iy, x, y, z);
            c->fX[cath] += q*x;
            c->fY[cath] += q*y;
            c->fQ[cath] += q;
@@ -1041,8 +1049,8 @@ void  AliMUONClusterFinderVS::FillCluster(AliMUONRawCluster* c, Int_t flag, Int_
 //
        x=c->fX[cath];   
        y=c->fY[cath];
-       fInput->Segmentation(cath)->GetPadIxy(x, y, ix, iy);
-       fInput->Segmentation(cath)->GetPadCxy(ix, iy, x, y);
+       fInput->Segmentation(cath)->GetPadIxy(x, y, 0, ix, iy);
+       fInput->Segmentation(cath)->GetPadCxy(ix, iy, x, y, z);
        Int_t isec=fInput->Segmentation(cath)->Sector(ix,iy);
        TF1* cogCorr = fInput->Segmentation(cath)->CorrFunc(isec-1);
        
@@ -1066,14 +1074,14 @@ void  AliMUONClusterFinderVS::FillCluster(AliMUONRawCluster* c, Int_t cath)
        dr0 = 10000;
     }
     
-    Float_t xpad, ypad;
+    Float_t xpad, ypad, zpad;
     Float_t dx, dy, dr;
 
     for (Int_t i=0; i<c->fMultiplicity[cath]; i++)
     {
        dig = fInput->Digit(cath,c->fIndexMap[i][cath]);
        fInput->Segmentation(cath)->
-       GetPadCxy(dig->fPadX,dig->fPadY,xpad,ypad);
+       GetPadCxy(dig->fPadX,dig->fPadY,xpad,ypad, zpad);
        fprintf(stderr,"x %f y %f cx %f cy %f\n",xpad,ypad,c->fX[0],c->fY[0]);
        dx = xpad - c->fX[0];
        dy = ypad - c->fY[0];
@@ -1155,8 +1163,8 @@ void  AliMUONClusterFinderVS::FindCluster(Int_t i, Int_t j, Int_t cath, AliMUONR
     }
 
 // Prepare center of gravity calculation
-    Float_t x, y;
-    fInput->Segmentation(cath)->GetPadCxy(i, j, x, y);
+    Float_t x, y, z;
+    fInput->Segmentation(cath)->GetPadCxy(i, j, x, y, z);
            
     c.fX[cath] += q*x;
     c.fY[cath] += q*y;
@@ -1188,7 +1196,7 @@ void  AliMUONClusterFinderVS::FindCluster(Int_t i, Int_t j, Int_t cath, AliMUONR
        xc=xmin+.001;
        while (xc < xmax) {
            xc+=fInput->Segmentation(iop)->Dpx(isec);
-           fInput->Segmentation(iop)->GetPadIxy(xc,y,ix,iy);
+           fInput->Segmentation(iop)->GetPadIxy(xc,y,0,ix,iy);
            if (ix>=(fInput->Segmentation(iop)->Npx()) || (iy>=fInput->Segmentation(iop)->Npy())) continue;
            if (fHitMap[iop]->TestHit(ix,iy)==kUnused) FindCluster(ix, iy, iop, c);
        }
@@ -1199,7 +1207,7 @@ void  AliMUONClusterFinderVS::FindCluster(Int_t i, Int_t j, Int_t cath, AliMUONR
        yc=ymin+.001;
        while (yc < ymax) {
            yc+=fInput->Segmentation(iop)->Dpy(isec);
-           fInput->Segmentation(iop)->GetPadIxy(x,yc,ix,iy);
+           fInput->Segmentation(iop)->GetPadIxy(x,yc,0,ix,iy);
            if (ix>=(fInput->Segmentation(iop)->Npx()) || (iy>=fInput->Segmentation(iop)->Npy())) continue;
            if (fHitMap[iop]->TestHit(ix,iy)==kUnused) FindCluster(ix, iy, iop, c);
        }
@@ -1322,7 +1330,7 @@ Float_t AliMUONClusterFinderVS::SingleMathiesonFit(AliMUONRawCluster *c, Int_t c
 // lower and upper limits
     static Double_t lower[2], upper[2];
     Int_t ix,iy;
-    fInput->Segmentation(cath)->GetPadIxy(c->fX[cath], c->fY[cath], ix, iy);
+    fInput->Segmentation(cath)->GetPadIxy(c->fX[cath], c->fY[cath], 0, ix, iy);
     Int_t isec=fInput->Segmentation(cath)->Sector(ix, iy);
     lower[0]=vstart[0]-fInput->Segmentation(cath)->Dpx(isec)/2;
     lower[1]=vstart[1]-fInput->Segmentation(cath)->Dpy(isec)/2;
@@ -1381,10 +1389,10 @@ Float_t AliMUONClusterFinderVS::CombiSingleMathiesonFit(AliMUONRawCluster *c)
 // lower and upper limits
     static Double_t lower[2], upper[2];
     Int_t ix,iy,isec;
-    fInput->Segmentation(0)->GetPadIxy(fXInit[0], fYInit[0], ix, iy);
+    fInput->Segmentation(0)->GetPadIxy(fXInit[0], fYInit[0], 0, ix, iy);
     isec=fInput->Segmentation(0)->Sector(ix, iy);
     Float_t dpy=fInput->Segmentation(0)->Dpy(isec)/2;
-    fInput->Segmentation(1)->GetPadIxy(fXInit[0], fYInit[0], ix, iy);
+    fInput->Segmentation(1)->GetPadIxy(fXInit[0], fYInit[0], 0, ix, iy);
     isec=fInput->Segmentation(1)->Sector(ix, iy);
     Float_t dpx=fInput->Segmentation(1)->Dpx(isec)/2;
 
@@ -1524,11 +1532,11 @@ Float_t AliMUONClusterFinderVS::CombiDoubleMathiesonFit(AliMUONRawCluster *c)
     Int_t ix,iy,isec;
     Float_t dpx, dpy;
     
-    fInput->Segmentation(1)->GetPadIxy(fXInit[0], fYInit[0], ix, iy);
+    fInput->Segmentation(1)->GetPadIxy(fXInit[0], fYInit[0], 0, ix, iy);
     isec=fInput->Segmentation(1)->Sector(ix, iy);
     dpx=fInput->Segmentation(1)->Dpx(isec);
 
-    fInput->Segmentation(0)->GetPadIxy(fXInit[0], fYInit[0], ix, iy);
+    fInput->Segmentation(0)->GetPadIxy(fXInit[0], fYInit[0], 0, ix, iy);
     isec=fInput->Segmentation(0)->Sector(ix, iy);
     dpy=fInput->Segmentation(0)->Dpy(isec);
 
@@ -1538,10 +1546,10 @@ Float_t AliMUONClusterFinderVS::CombiDoubleMathiesonFit(AliMUONRawCluster *c)
     upper[1]=vstart[1]+dpy;
 
 
-    fInput->Segmentation(1)->GetPadIxy(fXInit[1], fYInit[1], ix, iy);
+    fInput->Segmentation(1)->GetPadIxy(fXInit[1], fYInit[1], 0, ix, iy);
     isec=fInput->Segmentation(1)->Sector(ix, iy);
     dpx=fInput->Segmentation(1)->Dpx(isec);
-    fInput->Segmentation(0)->GetPadIxy(fXInit[1], fYInit[1], ix, iy);
+    fInput->Segmentation(0)->GetPadIxy(fXInit[1], fYInit[1], 0, ix, iy);
     isec=fInput->Segmentation(0)->Sector(ix, iy);
     dpy=fInput->Segmentation(0)->Dpy(isec);
 
@@ -1623,7 +1631,7 @@ void AliMUONClusterFinderVS::Split(AliMUONRawCluster* c)
            } else {
                cnew.fQ[cath]=Int_t(clusterInput.TotalCharge(cath)*(1-fQrFit[cath]));
            }
-           fInput->Segmentation(cath)->SetHit(fXFit[j],fYFit[j]);
+           fInput->Segmentation(cath)->SetHit(fXFit[j],fYFit[j],0);
            for (i=0; i<fMul[cath]; i++) {
                cnew.fIndexMap[cnew.fMultiplicity[cath]][cath]=
                    c->fIndexMap[i][cath];
index acddd6d843a1f21a02f953325ca05c7107f86239..71f82e0041bf96f9e09d3c44dd11d4f6fc8339b5 100644 (file)
 
 /*
 $Log$
+Revision 1.2  2000/06/28 12:19:18  morsch
+More consequent seperation of global input data services (AliMUONClusterInput singleton) and the
+cluster and hit reconstruction algorithms in AliMUONClusterFinderVS.
+AliMUONClusterFinderVS becomes the base class for clustering and hit reconstruction.
+It requires two cathode planes. Small modifications in the code will make it usable for
+one cathode plane and, hence, more general (for test beam data).
+AliMUONClusterFinder is now obsolete.
+
 Revision 1.1  2000/06/28 08:06:10  morsch
 Avoid global variables in AliMUONClusterFinderVS by seperating the input data for the fit from the
 algorithmic part of the class. Input data resides inside the AliMUONClusterInput singleton.
@@ -130,7 +138,7 @@ Float_t AliMUONClusterInput::DiscrChargeS1(Int_t i,Double_t *par)
 
    fSegmentation[0]->SetPad(fix[i][0], fiy[i][0]);
 //  First Cluster
-   fSegmentation[0]->SetHit(par[0],par[1]);
+   fSegmentation[0]->SetHit(par[0],par[1],0);
    Float_t q1=fResponse->IntXY(fSegmentation[0]);
     
    Float_t value = fQtot[0]*q1;
@@ -144,7 +152,7 @@ Float_t AliMUONClusterInput::DiscrChargeCombiS1(Int_t i,Double_t *par, Int_t cat
 
    fSegmentation[cath]->SetPad(fix[i][cath], fiy[i][cath]);
 //  First Cluster
-   fSegmentation[cath]->SetHit(par[0],par[1]);
+   fSegmentation[cath]->SetHit(par[0],par[1],0);
    Float_t q1=fResponse->IntXY(fSegmentation[cath]);
     
    Float_t value = fQtot[cath]*q1;
@@ -163,11 +171,11 @@ Float_t AliMUONClusterInput::DiscrChargeS2(Int_t i,Double_t *par)
 
    fSegmentation[0]->SetPad(fix[i][0], fiy[i][0]);
 //  First Cluster
-   fSegmentation[0]->SetHit(par[0],par[1]);
+   fSegmentation[0]->SetHit(par[0],par[1],0);
    Float_t q1=fResponse->IntXY(fSegmentation[0]);
     
 //  Second Cluster
-   fSegmentation[0]->SetHit(par[2],par[3]);
+   fSegmentation[0]->SetHit(par[2],par[3],0);
    Float_t q2=fResponse->IntXY(fSegmentation[0]);
     
    Float_t value = fQtot[0]*(par[4]*q1+(1.-par[4])*q2);
@@ -185,11 +193,11 @@ Float_t AliMUONClusterInput::DiscrChargeCombiS2(Int_t i,Double_t *par, Int_t cat
 
    fSegmentation[cath]->SetPad(fix[i][cath], fiy[i][cath]);
 //  First Cluster
-   fSegmentation[cath]->SetHit(par[0],par[1]);
+   fSegmentation[cath]->SetHit(par[0],par[1],0);
    Float_t q1=fResponse->IntXY(fSegmentation[cath]);
     
 //  Second Cluster
-   fSegmentation[cath]->SetHit(par[2],par[3]);
+   fSegmentation[cath]->SetHit(par[2],par[3],0);
    Float_t q2=fResponse->IntXY(fSegmentation[cath]);
    Float_t value;
    if (cath==0) {
index 421029394dc1b632c30b44ae1187feb7def083f0..54ec9c53352cfbb82cec8e7320513561f011ea38 100644 (file)
@@ -15,6 +15,9 @@
 
 /*
 $Log$
+Revision 1.4  2000/06/27 09:46:57  morsch
+kMAXZOOM global constant now in AliMUONConstants
+
 Revision 1.3  2000/06/26 14:02:38  morsch
 Add class AliMUONConstants with MUON specific constants using static memeber data and access methods.
 
@@ -568,13 +571,13 @@ void AliMUONDisplay::DrawSegmentation()
        for (Int_t j=0; j<seg->Npy(); j++) {
            Float_t y0;
            y0=j*seg->Dpy()-seg->Dpy()/2.;
-           for (seg->FirstPad(0.,y0,300,0.); 
+           for (seg->FirstPad(0.,y0,0,300,0.); 
                 seg->MorePads();
                 seg->NextPad())
            {
                if (seg->ISector()==0) continue;
-               Float_t x,y;
-               seg->GetPadCxy(seg->Ix(), seg->Iy(), x, y);
+               Float_t x,y,z;
+               seg->GetPadCxy(seg->Ix(), seg->Iy(), x, y, z);
                Float_t dpx=seg->Dpx(seg->ISector())/2;
                Float_t dpy=seg->Dpy(seg->ISector())/2;
                marker=new TMarker3DBox(x,y,zpos,dpx,dpy,0,0,0);
@@ -589,14 +592,14 @@ void AliMUONDisplay::DrawSegmentation()
            Float_t x0=j*seg->Dpx();
            Float_t y0=TMath::Sqrt(r*r-x0*x0);
            
-           for (seg->FirstPad(x0,0,0,y0); 
+           for (seg->FirstPad(x0,0,0,0,y0); 
                 seg->MorePads();
                 seg->NextPad())
            {
                if (seg->ISector()==0) continue;
                
-               Float_t x,y;
-               seg->GetPadCxy(seg->Ix(), seg->Iy(), x, y);
+               Float_t x,y,z;
+               seg->GetPadCxy(seg->Ix(), seg->Iy(), x, y, z);
                Float_t dpx=seg->Dpx(seg->ISector())/2;
                Float_t dpy=seg->Dpy(seg->ISector())/2;
                marker=new TMarker3DBox(x,y,zpos,dpx,dpy,0,0,0);
@@ -934,8 +937,8 @@ void AliMUONDisplay::LoadDigits(Int_t chamber, Int_t cathode)
        }
 
        // get the center of the pad - add on x and y half of pad size
-       Float_t xpad, ypad;
-       segmentation->GetPadCxy(mdig->fPadX, mdig->fPadY,xpad, ypad);
+       Float_t xpad, ypad, zpad;
+       segmentation->GetPadCxy(mdig->fPadX, mdig->fPadY,xpad, ypad, zpad);
        
         Int_t isec=segmentation->Sector(mdig->fPadX, mdig->fPadY);
         Float_t dpx=segmentation->Dpx(isec)/2;
@@ -962,7 +965,7 @@ void AliMUONDisplay::LoadDigits(Int_t chamber, Int_t cathode)
         points->SetPoint(0,xpad,ypad,zpos);    
        for (Int_t imark=0;imark<nPara; imark++)
        {
-           segmentation->GetPadCxy(mdig->fPadX + imark*offset, mdig->fPadY,xpad, ypad);
+           segmentation->GetPadCxy(mdig->fPadX + imark*offset, mdig->fPadY,xpad, ypad, zpad);
            marker=new TMarker3DBox(xpad,ypad,zpos,dpx,dpy,0,0,0);
            marker->SetLineColor(2);
            marker->SetFillStyle(1001);
index dc267f828a1eed40d95dcb4b11a30580eb5211af..8a2706d3b054c86d7e1668a6604e9d7bc077ec26 100644 (file)
@@ -14,6 +14,9 @@
  **************************************************************************/
 /*
 $Log$
+Revision 1.3  2000/06/26 10:04:49  pcrochet
+problem with HP compiler solved (PH), static variables removed : now defined in AliMUONTriggerConstants
+
 */
 
 #include "AliRun.h"
@@ -275,7 +278,7 @@ void AliMUONTriggerCircuit::LoadYPos(){
 
   Int_t chamber, cathode;
   Int_t code, idModule, idStrip, idSector;
-  Float_t x, y, width;
+  Float_t x, y, z, width;
   Int_t istrip;
 
   AliMUON *pMUON  = (AliMUON*)gAlice->GetModule("MUON");  
@@ -294,7 +297,7 @@ void AliMUONTriggerCircuit::LoadYPos(){
     idStrip=TMath::Abs(code-idModule*100); // corresp. strip number in module
     idSector=segmentation->Sector(idModule,idStrip); // corresponding sector
     width=segmentation->Dpy(idSector);      // corresponding strip width
-    segmentation->GetPadCxy(idModule,idStrip,x,y); // get strip real position
+    segmentation->GetPadCxy(idModule,idStrip,x,y,z); // get strip real position
     
     fYpos11[2*istrip]=y;
     if (istrip!=15) fYpos11[2*istrip+1]=y+width/2.;
@@ -312,7 +315,7 @@ void AliMUONTriggerCircuit::LoadYPos(){
     idStrip=TMath::Abs(code-idModule*100); // corresp. strip number in module
     idSector=segmentation->Sector(idModule,idStrip); // corresponding sector
     width=segmentation->Dpy(idSector);      // corresponding strip width
-    segmentation->GetPadCxy(idModule,idStrip,x,y); // get strip real position
+    segmentation->GetPadCxy(idModule,idStrip,x,y,z); // get strip real position
     
 // using idModule!=0 prevents to fill garbage in case of circuits 
 // in the first and last rows 
@@ -330,7 +333,7 @@ void AliMUONTriggerCircuit::LoadXPos(){
 // taking into account whether or nor not part(s) of the circuit
 // (middle, up or down) has(have) 16 strips
   
-  Float_t x, y;
+  Float_t x, y, z;
   Int_t istrip;  
 
   Int_t chamber=11;
@@ -350,14 +353,14 @@ void AliMUONTriggerCircuit::LoadXPos(){
 // first case : up middle and down parts have all 8 or 16 strip 
   if ((nStrY==16)||(nStrY==8&&fx2m==0&&fx2ud==0)) { 
     for (istrip=0; istrip<nStrY; istrip++) {
-      segmentation->GetPadCxy(idModule,istrip,x,y); 
+      segmentation->GetPadCxy(idModule,istrip,x,y,z); 
       fXpos11[istrip]=x;
     }
 // second case : mixing 8 and 16 strips within same circuit      
   } else {
     for (istrip=0; istrip<nStrY; istrip++) {
       if (nStrY!=8) { cout << " bug in LoadXpos " << "\n";}
-      segmentation->GetPadCxy(idModule,istrip,x,y); 
+      segmentation->GetPadCxy(idModule,istrip,x,y,z); 
       fXpos11[2*istrip]=x-width/4.;
       fXpos11[2*istrip+1]=fXpos11[2*istrip]+width/2.;
     }
index 66069a8f3f790b577385c2cb08e33d784d8d08f1..b382dc46a5c4d1f9d6aac15cab26244bcdf173ae 100644 (file)
@@ -15,6 +15,9 @@
 
 /*
 $Log$
+Revision 1.4  2000/06/26 14:02:38  morsch
+Add class AliMUONConstants with MUON specific constants using static memeber data and access methods.
+
 Revision 1.3  2000/06/22 14:10:05  morsch
 HP scope problems corrected (PH)
 
@@ -1609,20 +1612,27 @@ void AliMUONv1::StepManager()
       eloss   += destep;
       tlength += step;
       
-      Float_t x0,y0;
+      Float_t x0,y0,z0;
+      Float_t localPos[3];
+      Float_t globalPos[3] = {pos[0], pos[1], pos[2]};
+      
       
+      gMC->Gmtod(globalPos,localPos,1); 
+
       if(idvol<10) {
 // tracking chambers
          x0 = 0.5*(xhit+pos[0]);
          y0 = 0.5*(yhit+pos[1]);
+         z0 = localPos[2];
       } else {
 // trigger chambers
          x0=xhit;
          y0=yhit;
+         z0=0.;
       }
       
       
-      if (eloss >0)  MakePadHits(x0,y0,eloss,tof,idvol);
+      if (eloss >0)  MakePadHits(x0,y0,z0,eloss,tof,idvol);
       
          
       hits[6]=tlength;
@@ -1645,9 +1655,15 @@ void AliMUONv1::StepManager()
   {
       ((AliMUONChamber*) (*fChambers)[idvol])
          ->SigGenInit(pos[0], pos[1], pos[2]);
+      
+      Float_t localPos[3];
+      Float_t globalPos[3] = {pos[0], pos[1], pos[2]};
+      gMC->Gmtod(globalPos,localPos,1); 
+
+
 //      printf("\n-> MakePadHits, reason special %d",ipart);
       if (eloss > 0 && idvol < 10)
-         MakePadHits(0.5*(xhit+pos[0]),0.5*(yhit+pos[1]),eloss,tof,idvol);
+         MakePadHits(0.5*(xhit+pos[0]),0.5*(yhit+pos[1]),localPos[2],eloss,tof,idvol);
       xhit     = pos[0];
       yhit     = pos[1]; 
       eloss    = destep;