new AliRICHcluster added
authorkir <kir@f7af4fe6-9843-0410-8265-dc069ae4e863>
Tue, 28 Oct 2003 10:46:08 +0000 (10:46 +0000)
committerkir <kir@f7af4fe6-9843-0410-8265-dc069ae4e863>
Tue, 28 Oct 2003 10:46:08 +0000 (10:46 +0000)
RICH/AliRICH.cxx
RICH/AliRICH.h
RICH/AliRICHParam.h
RICH/RICHLinkDef.h
RICH/menu.C

index 55d4cfc..dd0198b 100644 (file)
@@ -32,18 +32,25 @@ ClassImp(AliRICHhit)
 //__________________________________________________________________________________________________
 void AliRICHhit::Print(Option_t*)const
 {
-  Info("","chamber=%2i, PID=%9i, TID=%6i, eloss=%9.3f eV",fChamber,fPid,fTrack,fEloss*1e9);
-}//void AliRICHdigit::Print(Option_t *option)const
+  Info("","chamber=%2i, PID=%9i, TID=%6i, eloss=%8.3f eV",fChamber,fPid,fTrack,fEloss*1e9);
+}
 //__________________________________________________________________________________________________
 ClassImp(AliRICHdigit)
 //__________________________________________________________________________________________________
 void AliRICHdigit::Print(Option_t*)const
 {
-  Info("","ID=%6i, chamber=%2i, PadX=%3i, PadY=%3i, Qdc=%4i, TID1=%5i, TID2=%5i, TID3=%5i",
+  Info("","ID=%6i, chamber=%2i, PadX=%3i, PadY=%3i, Q=%6.2f, TID1=%5i, TID2=%5i, TID3=%5i",
          Id(),fChamber,fPadX,fPadY,fQdc,fTracks[0],fTracks[1],fTracks[2]);
-}//void AliRICHdigit::Print(Option_t *option)const
+}
+//__________________________________________________________________________________________________
+ClassImp(AliRICHcluster)
+//__________________________________________________________________________________________________
+void AliRICHcluster::Print(Option_t*)const
+{
+  Info("","chamber=%2i,size=%3i,dim=%5i,x=%6.3f,y=%6.3f,Q=%4i,status=%i",
+            fChamber,fSize,fDimXY,fX,fY,fQdc,fStatus);
+}
 //__________________________________________________________________________________________________
-
 ClassImp(AliRICH)    
 //__________________________________________________________________________________________________
 // RICH manager class   
@@ -84,8 +91,8 @@ AliRICH::AliRICH(const char *name, const char *title)
   
   fCerenkovs=  0;     CreateCerenkovsOld();  gAlice->GetMCApp()->AddHitList(fCerenkovs);
   fSpecials=   0;     CreateSpecialsOld();   
-  fDchambers=  0;   //CreateDigitsOld();
-  fRawClusters=0;   //CreateRawClustersOld();
+  fDchambers=  0;  
+  fRawClusters=0;  
   
   fCkovNumber=fFreonProd=0;  
   if(GetDebug())Info("named ctor","Stop.");
@@ -122,17 +129,25 @@ void AliRICH::Hits2SDigits()
     if(!GetLoader()->TreeS()) GetLoader()->MakeTree("S");  
     MakeBranch("S");
     
-    ResetSdigits();  ResetSpecialsOld();  
+    ResetHits();  ResetSDigits();  
     for(Int_t iPrimN=0;iPrimN<GetLoader()->TreeH()->GetEntries();iPrimN++){//prims loop
       GetLoader()->TreeH()->GetEntry(iPrimN);
-      for(Int_t i=0;i<Specials()->GetEntries();i++){//specials loop          
-        Int_t padx= ((AliRICHSDigit*)Specials()->At(i))->PadX();
-        Int_t pady= ((AliRICHSDigit*)Specials()->At(i))->PadY();
-        Int_t qdc=  ((AliRICHSDigit*)Specials()->At(i))->QPad();
-        Int_t hitN= ((AliRICHSDigit*)Specials()->At(i))->HitNumber()-1;//!!! important -1
-        Int_t chamber=((AliRICHhit*)Hits()->At(hitN))->C();
-        Int_t track=((AliRICHhit*)Hits()->At(hitN))->GetTrack();
-        AddSdigit(chamber,padx+Param()->NpadsX()/2,pady+Param()->NpadsY()/2,qdc,track);
+      for(Int_t iHitN=0;iHitN<Hits()->GetEntries();iHitN++){//hits loop          
+        AliRICHhit *pHit=(AliRICHhit*)Hits()->At(iHitN);        
+        
+        TVector3 globX3(pHit->X(),pHit->Y(),pHit->Z());        
+        TVector3 locX3=C(pHit->C())->Glob2Loc(globX3);
+        
+        Int_t sector;
+        Int_t iTotQdc=Param()->Loc2TotQdc(locX3,pHit->Eloss(),pHit->Pid(),sector);
+        
+        Int_t iPadXmin,iPadXmax,iPadYmin,iPadYmax;
+        AliRICHParam::Loc2Area(locX3,iPadXmin,iPadYmin,iPadXmax,iPadYmax);
+        for(Int_t iPadY=iPadYmin;iPadY<=iPadYmax;iPadY++)
+          for(Int_t iPadX=iPadXmin;iPadX<=iPadXmax;iPadX++){
+            Double_t padQdc=iTotQdc*Param()->Loc2PadFrac(locX3,iPadX,iPadY);
+            if(padQdc>0.1) AddSDigit(pHit->C(),iPadX,iPadY,padQdc,pHit->GetTrack());
+          }            
       }//specials loop
     }//prims loop
     GetLoader()->TreeS()->Fill();
@@ -140,7 +155,7 @@ void AliRICH::Hits2SDigits()
     if(GetDebug()) Info("Hit2SDigits","Event %i processed.",iEventN);
   }//events loop  
   GetLoader()->UnloadHits();   GetLoader()->UnloadSDigits();  
-  ResetHits();                 ResetSdigits();
+  ResetHits();                 ResetSDigits();
   if(GetDebug()) Info("Hit2SDigits","Stop.");
 }//void AliRICH::Hits2SDigits()
 //__________________________________________________________________________________________________
@@ -154,38 +169,40 @@ void AliRICH::SDigits2Digits()
     gAlice->GetRunLoader()->GetEvent(iEventN);
     
     if(!GetLoader()->TreeD()) GetLoader()->MakeTree("D");  MakeBranch("D"); //create TreeD with RICH branches 
-    ResetSdigits();ResetDigitsOld();//reset lists of sdigits and digits
+    ResetSDigits();ResetDigitsOld();//reset lists of sdigits and digits
     GetLoader()->TreeS()->GetEntry(0);  
-    Sdigits()->Sort();
+    SDigits()->Sort();
   
-    Int_t kBad=-101;
-    
-    Int_t tr[3],q[3],dig[5]; for(Int_t i=0;i<3;i++) tr[i]=q[i]=kBad;    for(Int_t i=0;i<5;i++) dig[i]=kBad;        
-    Int_t chamber=kBad,id=kBad,iNdigitsPerPad=kBad;//how many sdigits for a given pad
+    Int_t chamber,x,y,tr[3],id;
+    chamber=x=y=tr[0]=tr[1]=tr[2]=id=kBad;
+    Double_t q=kBad;
+    Int_t iNdigitsPerPad=kBad;//how many sdigits for a given pad
         
-    for(Int_t i=0;i<Sdigits()->GetEntries();i++){//sdigits loop (sorted)
-      AliRICHdigit *pSdig=(AliRICHdigit*)Sdigits()->At(i);
+    for(Int_t i=0;i<SDigits()->GetEntries();i++){//sdigits loop (sorted)
+      AliRICHdigit *pSdig=(AliRICHdigit*)SDigits()->At(i);
       if(pSdig->Id()==id){//still the same pad
         iNdigitsPerPad++;
-        dig[2]+=pSdig->Qdc();//sum up qdc
+        q+=pSdig->Q();
         if(iNdigitsPerPad<=3)
           tr[iNdigitsPerPad-1]=pSdig->T(0);
         else
           Info("","More then 3 sdigits for the given pad");
       }else{//new pad, add the pevious one
-        if(id!=kBad) AddDigitOld(chamber,tr,q,dig);
-        chamber=pSdig->C();dig[0]=pSdig->X();dig[1]=pSdig->Y();dig[2]=pSdig->Qdc();tr[0]=pSdig->T(0);id=pSdig->Id();
+        if(id!=kBad) AddDigit(chamber,x,y,(Int_t)q,tr[0],tr[1],tr[2]);//ch-xpad-ypad-qdc-tr1-2-3
+        chamber=pSdig->C();x=pSdig->X();y=pSdig->Y();q=pSdig->Q();tr[0]=pSdig->T(0);id=pSdig->Id();
         iNdigitsPerPad=1;tr[1]=tr[2]=kBad;
       }
     }//sdigits loop (sorted)
-    if(Sdigits()->GetEntries()) AddDigitOld(chamber,tr,q,dig);//add the last digit
+  
+    if(SDigits()->GetEntries())AddDigit(chamber,x,y,(Int_t)q,tr[0],tr[1],tr[2]);//add the last digit
+        
         
     GetLoader()->TreeD()->Fill();  
     GetLoader()->WriteDigits("OVERWRITE");
     if(GetDebug()) Info("SDigits2Digits","Event %i processed.",iEventN);
   }//events loop
   GetLoader()->UnloadSDigits();  GetLoader()->UnloadDigits();  
-  ResetSdigits();                ResetDigitsOld();
+  ResetSDigits();                ResetDigitsOld();
   if(GetDebug()) Info("SDigits2Digits","Stop.");
 }//void AliRICH::SDigits2Digits()
 //__________________________________________________________________________________________________
@@ -625,7 +642,7 @@ void AliRICH::MakeBranch(Option_t* option)
   AliDetector::MakeBranch(option);//this is after cH because we need to guarantee that fHits array is created
       
   if(cS&&fLoader->TreeS()){//S  
-    CreateSdigits();   MakeBranchInTree(fLoader->TreeS(),"RICH",&fSdigits,kBufferSize,0) ;
+    CreateSDigits();   MakeBranchInTree(fLoader->TreeS(),"RICH",&fSdigits,kBufferSize,0) ;
   }//S
    
   if(cD&&fLoader->TreeD()){//D
@@ -661,7 +678,7 @@ void AliRICH::SetTreeAddress()
 
   if(fLoader->TreeS()){//S
     if(GetDebug())Info("SetTreeAddress","tree S is requested.");
-    branch=fLoader->TreeS()->GetBranch(GetName());        if(branch){CreateSdigits();   branch->SetAddress(&fSdigits);}
+    branch=fLoader->TreeS()->GetBranch(GetName());        if(branch){CreateSDigits();   branch->SetAddress(&fSdigits);}
   }//S
     
   if(fLoader->TreeD()){//D    
index 120d8eb..372e11f 100644 (file)
@@ -160,29 +160,29 @@ AliRICHCerenkov::AliRICHCerenkov(Int_t shunt, Int_t track, Int_t *vol, Float_t *
 class AliRICHdigit :public AliDigit
 {
 public:
-           AliRICHdigit() {fPadX=fPadY=fChamber=fQdc=fTracks[0]=fTracks[1]=fTracks[2]=kBad;}
-  inline   AliRICHdigit(Int_t iC,Int_t iX,Int_t iY,Int_t iQdc,Int_t iT1,Int_t iT2,Int_t iT3);
+           AliRICHdigit() {fPadX=fPadY=fChamber=fTracks[0]=fTracks[1]=fTracks[2]=kBad;fQdc=kBad;}
+  inline   AliRICHdigit(Int_t iC,Int_t iX,Int_t iY,Double_t iQdc,Int_t iT1,Int_t iT2,Int_t iT3);
   virtual ~AliRICHdigit() {;}  
-  inline   Int_t Compare(const TObject *pObj) const;//virtual
-           Bool_t IsSortable()                                 const{return kTRUE;}//virtual
-           Int_t C()                                           const{return fChamber;}
-           Int_t X()                                           const{return fPadX;}
-           Int_t Y()                                           const{return fPadY;}
-           Int_t Id()                                          const{return fChamber*1000000+fPadX*1000+fPadY;}
-           Int_t Qdc()                                         const{return fQdc;}
-           Int_t T(Int_t i)                                    const{return fTracks[i];}
-           void  Print(Option_t *option)const;      //virtual
+  inline   Int_t    Compare(const TObject *pObj) const;                               //virtual
+           Bool_t   IsSortable()                                  const{return kTRUE;}//virtual
+           Int_t    C()                                           const{return fChamber;}
+           Int_t    X()                                           const{return fPadX;}
+           Int_t    Y()                                           const{return fPadY;}
+           Int_t    Id()                                          const{return fChamber*1000000+fPadX*1000+fPadY;}
+           Double_t Q()                                           const{return fQdc;}
+           Int_t    T(Int_t i)                                    const{return fTracks[i];}
+           void  Print(Option_t *option)const;                                       //virtual
 protected:
-  Int_t fChamber;  //module number 
-  Int_t fPadX;     //pad number along X
-  Int_t fPadY;     //pad number along Y
-  Int_t fQdc;      //ADC value
+  Int_t    fChamber;  //module number 
+  Int_t    fPadX;     //pad number along X
+  Int_t    fPadY;     //pad number along Y
+  Double_t fQdc;      //QDC value, fractions are permitted for summable procedure
   ClassDef(AliRICHdigit,1) //RICH digit class       
 };//class AliRICHdigit
 //__________________________________________________________________________________________________
-AliRICHdigit::AliRICHdigit(Int_t iC,Int_t iX,Int_t iY,Int_t iQdc,Int_t iT0,Int_t iT1,Int_t iT2)
+AliRICHdigit::AliRICHdigit(Int_t iC,Int_t iX,Int_t iY,Double_t q,Int_t iT0,Int_t iT1,Int_t iT2)
 {
-  fChamber=iC;fPadX=iX;fPadY=iY;fQdc=iQdc;
+  fChamber=iC;fPadX=iX;fPadY=iY;fQdc=q;
   fTracks[0]=iT0;fTracks[1]=iT1;fTracks[2]=iT2;
 }
 //__________________________________________________________________________________________________
@@ -195,6 +195,42 @@ Int_t AliRICHdigit::Compare(const TObject *pObj)const
   else
     return -1;
 } 
+//__________________AliRICHcluster__________________________________________________________________
+//__________________________________________________________________________________________________
+//__________________________________________________________________________________________________
+class AliRICHcluster :public TObject
+{
+public:
+ enum ClusterStatus {kOK,kEdge,kShape,kSize};
+
+           AliRICHcluster()                                       {fStatus=fSize=fDimXY=fChamber=fQdc=kBad;fX=fY=kBad;fDigits=0;}
+  virtual ~AliRICHcluster() {delete fDigits;}  
+           Int_t    Size()                                        const{return fSize;}
+           Int_t    DimXY()                                       const{return fDimXY;}
+           Int_t    Chamber()                                     const{return fChamber/10;}
+           Int_t    Sector()                                      const{return fChamber-(fChamber/10)*10;} 
+           Int_t    Q()                                           const{return fQdc;}
+           Double_t X()                                           const{return fX;}
+           Double_t Y()                                           const{return fY;}
+           Int_t    Status()                                      const{return fStatus;}
+           void  Print(Option_t *option)const;                                       //virtual
+   inline  void  AddDigit(AliRICHdigit *pDig);
+protected:
+  Int_t         fSize;        //how many digits belong to this cluster    
+  Int_t         fDimXY;       //100*xdim+ydim box containing the cluster
+  Int_t         fQdc;         //QDC value
+  Int_t         fChamber;     //10*module number+sector number 
+  Double_t      fX;           //local x postion 
+  Double_t      fY;           //local y postion  
+  Int_t         fStatus;      //flag to mark the quality of the cluster   
+  TObjArray    *fDigits;      //! list of digits forming this cluster
+  ClassDef(AliRICHcluster,1)  //RICH digit class       
+};//class AliRICHcluster
+//__________________________________________________________________________________________________
+void AliRICHcluster::AddDigit(AliRICHdigit *pDig)
+{  
+  fSize++; fQdc+=(Int_t)pDig->Q(); fDigits->Add(pDig);
+}
 //__________________AliRICH_________________________________________________________________________
 //__________________________________________________________________________________________________
 //__________________________________________________________________________________________________
@@ -216,19 +252,19 @@ public:
           void    Digits2Reco();                                                                                  //virtual
   
   inline  void    CreateHits();    
-  inline  void    CreateSdigits();  
+  inline  void    CreateSDigits();  
   inline  void    CreateDigits();  
   inline  void    CreateClusters();  
   inline  void    AddHit(Int_t track, Int_t *vol, Float_t *hits);                                                 //virtual
-  inline  void    AddSdigit(Int_t iC,Int_t iX,Int_t iY,Int_t iAdc,Int_t iT0,Int_t iT1=kBad,Int_t iT2=kBad);
-  inline  void    AddDigit (Int_t iC,Int_t iX,Int_t iY,Int_t iAdc,Int_t iT0,Int_t iT1=kBad,Int_t iT2=kBad);     
-          void    AddCluster()                                                                                {;}     
+  inline  void    AddSDigit(Int_t iC,Int_t iX,Int_t iY,Double_t q,Int_t iT0,Int_t iT1=kBad,Int_t iT2=kBad);
+  inline  void    AddDigit (Int_t iC,Int_t iX,Int_t iY,Int_t iQ,Int_t iT0,Int_t iT1=kBad,Int_t iT2=kBad);     
+  inline  void    AddCluster(AliRICHcluster clus);
           void    ResetHits()     {AliDetector::ResetHits();fNcerenkovs=0;if(fCerenkovs)fCerenkovs->Clear();fNspecials=0;if(fSpecials)fSpecials->Clear();}  //virtual
-          void    ResetSdigits()  {fNsdigits=0;  if(fSdigits)  fSdigits ->Clear();}                                 
+          void    ResetSDigits()  {fNsdigits=0;  if(fSdigits)  fSdigits ->Clear();}                                 
           void    ResetDigits()   {if(fDigitsNew)for(int i=0;i<kNCH;i++){fDigitsNew->At(i)->Clear();fNdigitsNew[i]=0;}}
           void    ResetClusters() {if(fClusters) for(int i=0;i<kNCH;i++){fClusters ->At(i)->Clear();fNclusters[i]=0;}}
                   //Hits provided by AliDetector
-  TClonesArray*   Sdigits()             const{return fSdigits;}
+  TClonesArray*   SDigits()             const{return fSdigits;}
   TClonesArray*   Digits(Int_t iC)      const{if(fDigitsNew) return (TClonesArray *)fDigitsNew->At(iC-1);else return 0;}
   TClonesArray*   Clusters(Int_t iC)    const{if(fClusters)  return (TClonesArray *)fClusters->At(iC-1);else return 0;}
           
@@ -310,10 +346,10 @@ void AliRICH::AddHit(Int_t track, Int_t *vol, Float_t *hits)
   new(tmp[fNhits++])AliRICHhit(fIshunt,track,vol,hits);
 }
 //__________________________________________________________________________________________________
-void AliRICH::AddSdigit(Int_t iC,Int_t iX,Int_t iY,Int_t iAdc,Int_t iT0,Int_t iT1,Int_t iT2)
+void AliRICH::AddSDigit(Int_t iC,Int_t iX,Int_t iY,Double_t q,Int_t iT0,Int_t iT1,Int_t iT2)
 {//Adds the current Sdigit to the RICH list of Sdigits   
   TClonesArray &tmp=*fSdigits;
-  new(tmp[fNsdigits++])AliRICHdigit(iC,iX,iY,iAdc,iT0,iT1,iT2);
+  new(tmp[fNsdigits++])AliRICHdigit(iC,iX,iY,q,iT0,iT1,iT2);
 } 
 //__________________________________________________________________________________________________
 void AliRICH::AddDigit(Int_t iC,Int_t iX,Int_t iY,Int_t iAdc,Int_t iT0,Int_t iT1,Int_t iT2)
@@ -322,6 +358,12 @@ void AliRICH::AddDigit(Int_t iC,Int_t iX,Int_t iY,Int_t iAdc,Int_t iT0,Int_t iT1
   new(tmp[fNdigitsNew[iC-1]++]) AliRICHdigit(iC,iX,iY,iAdc,iT0,iT1,iT2);
 }
 //__________________________________________________________________________________________________
+void AliRICH::AddCluster(AliRICHcluster clus)
+{//Adds the current cluster to the corresponding RICH list of clusters (individual list per chamber)
+  TClonesArray &tmp=*((TClonesArray*)fClusters->At(clus.Chamber()-1));
+  new(tmp[fNclusters[clus.Chamber()-1]++]) AliRICHcluster(clus);
+}
+//__________________________________________________________________________________________________
 void AliRICH::CreateHits()
 {
   if(fHits) return;
@@ -329,10 +371,10 @@ void AliRICH::CreateHits()
   fHits=new TClonesArray("AliRICHhit",10000);   fNhits=0;
 }
 //__________________________________________________________________________________________________
-void AliRICH::CreateSdigits()
+void AliRICH::CreateSDigits()
 {
   if(fSdigits) return;
-  if(GetDebug())Info("CreateSdigits","creating sdigits container.");
+  if(GetDebug())Info("CreateSDigits","creating sdigits container.");
   fSdigits=new TClonesArray("AliRICHdigit",10000); fNsdigits=0;
 }
 //__________________________________________________________________________________________________
index 4138bec..e560305 100644 (file)
@@ -99,9 +99,9 @@ Int_t AliRICHParam::Loc2Sec(Double_t &x,Double_t &y)
   else if(x>=x5&&x<=x6)    {sector=3;x-=SectorSizeX()/2+DeadZone();}
   else                     {return kBad;} //in dead zone
 
-  if     (y>=-PcSizeY()/2   &&y<=-DeadZone()/2)  {y+=PcSizeY()/2;  return -sector;}
+  if     (y>=-PcSizeY()/2   &&y<=-DeadZone()/2)  {y+=PcSizeY()/2;  return sector;}
   else if(y> -DeadZone()/2  &&y<  DeadZone()/2)  {return kBad;} //in dead zone
-  else if(y>= DeadZone()/2  &&y<= PcSizeY()/2)   {y-=DeadZone()/2; return  sector;}
+  else if(y>= DeadZone()/2  &&y<= PcSizeY()/2)   {y-=DeadZone()/2; return sector+3;}
   else                                           {return kBad;}
 }//Loc2Sec(Double_t x, Double_t y)
 //__________________________________________________________________________________________________
@@ -113,8 +113,8 @@ Int_t AliRICHParam::Pad2Sec(Int_t &padx, Int_t &pady)
   else if(padx> NpadsXsec()*2&&padx<=NpadsX())         {sector=3;padx-=NpadsXsec()*2;}
   else                                                 {return kBad;}
 
-  if     (pady>=1         &&pady<= NpadsYsec())     {return -sector;}
-  else if(pady>NpadsYsec()&&pady<= NpadsY())        {pady-=NpadsYsec();return sector;} 
+  if     (pady>=1         &&pady<= NpadsYsec())     {return sector;}
+  else if(pady>NpadsYsec()&&pady<= NpadsY())        {pady-=NpadsYsec();return sector+3;} 
   else                                              {return kBad;}
 }//Pad2Sec()
 //__________________________________________________________________________________________________
@@ -128,8 +128,8 @@ Int_t AliRICHParam::Loc2Pad(Double_t x, Double_t y, Int_t &padx, Int_t &pady)
   
   padx=Int_t(x/PadSizeX())+1; 
   if(padx>NpadsXsec())            padx= NpadsXsec();
-  if(sector==2||sector==-2)       padx+=NpadsXsec();
-  else if(sector==3||sector==-3)  padx+=NpadsXsec()*2;
+  if(sector==2||sector==5)       padx+=NpadsXsec();
+  else if(sector==3||sector==6)  padx+=NpadsXsec()*2;
   
   pady=Int_t(y/PadSizeY())+1;
   if(pady>NpadsYsec())            padx= NpadsYsec();
@@ -141,15 +141,14 @@ Int_t AliRICHParam::Loc2Pad(Double_t x, Double_t y, Int_t &padx, Int_t &pady)
 void AliRICHParam::Pad2Loc(Int_t padx,Int_t pady,Double_t &x,Double_t &y)
 {
   Int_t sector=Pad2Sec(padx,pady);  
-  if(sector>0)
+  if(sector>3)
     y=0.5*DeadZone()+pady*PadSizeY()-0.5*PadSizeY();
   else{
-    sector=-sector;
     y=-0.5*PcSizeY()+pady*PadSizeY()-0.5*PadSizeY();
   }
-  if(sector==1)
+  if(sector==1||sector==4)
     x=-0.5*PcSizeX()+padx*PadSizeX()-0.5*PadSizeX();
-  else if(sector==2)
+  else if(sector==2||sector==5)
     x=-0.5*SectorSizeX()+padx*PadSizeX()-0.5*PadSizeX();
   else
     x= 0.5*SectorSizeX()+DeadZone()+padx*PadSizeX()-0.5*PadSizeX();
index 6143cd7..bd890a6 100644 (file)
@@ -9,6 +9,7 @@
 #pragma link C++ class  AliRICHhit+;
 #pragma link C++ class  AliRICHCerenkov+;
 #pragma link C++ class  AliRICHdigit+;
+#pragma link C++ class  AliRICHcluster+;
 #pragma link C++ class  AliRICHv3+;
 #pragma link C++ class  AliRICHDigit+;
 #pragma link C++ class  AliRICHSDigit+;
index 202dd21..2d0e67c 100644 (file)
@@ -1,11 +1,27 @@
 void ss()
 {
-  rl->LoadSDigits();
+  if(rl->LoadSDigits()) return;
   rl->TreeS()->GetEntry(0);
   r->SDigits()->Print();
+  Info("sd","totally %i",r->SDigits()->GetEntries());
   rl->UnloadSDigits();
 }
 
+void sd()
+{
+  if(rl->LoadDigits()) return;
+  rl->TreeD()->GetEntry(0);
+  for(int i=1;i<=7;i++) r->Digits(i)->Print();
+  rl->UnloadDigits();
+}
+
+void sc()
+{
+  if(rl->LoadRecPoints()) return;
+  rl->TreeR()->GetEntry(0);
+  for(int i=1;i<=7;i++) r->Clusters(i)->Print();
+  rl->UnloadRecPoints();
+}
 
 Double_t r2d = TMath::RadToDeg();
 Double_t d2r = TMath::DegToRad();