]> git.uio.no Git - u/mrichter/AliRoot.git/commitdiff
Minor changes on class names.
authormorsch <morsch@f7af4fe6-9843-0410-8265-dc069ae4e863>
Wed, 19 Apr 2000 13:19:56 +0000 (13:19 +0000)
committermorsch <morsch@f7af4fe6-9843-0410-8265-dc069ae4e863>
Wed, 19 Apr 2000 13:19:56 +0000 (13:19 +0000)
RICH/AliRICHHitMap.cxx
RICH/AliRICHHitMap.h
RICH/AliRICHPoints.cxx [new file with mode: 0644]
RICH/AliRICHSegResCkv.cxx
RICH/AliRICHSegResV0.h

index 7cdb7d96d436657f66d1e5b4cc62f52443cf45e8..3cc9537c6eb41e089dc093b6d5c324c4a552ff8c 100644 (file)
  **************************************************************************/
 
 /*
-$Log$
+  $Log$
 */
 
+
 #include "AliRICHHitMap.h"
 
 ClassImp(AliRICHHitMap)
 ClassImp(AliRICHHitMapA1)
 
-    //const char* dummy=0;
-
 
-AliRICHHitMapA1::AliRICHHitMapA1(AliRICHsegmentation *seg, TObjArray *dig)
+AliRICHHitMapA1::AliRICHHitMapA1(AliRICHSegmentation *seg, TObjArray *dig)
 {
     fSegmentation = seg;
     fNpx  = fSegmentation->Npx();
@@ -45,7 +44,7 @@ AliRICHHitMapA1::~AliRICHHitMapA1()
     if (fHitMap) delete[] fHitMap;
 }
 
-void AliRICHHitMapA1::Clear(Option_t *)
+void AliRICHHitMapA1::Clear()
 {
     memset(fHitMap,0,sizeof(int)*fMaxIndex);
 }
@@ -65,12 +64,12 @@ Int_t AliRICHHitMapA1::CheckedIndex(Int_t ix, Int_t iy)
 void  AliRICHHitMapA1::FillHits()
 {
     Int_t ndigits = fDigits->GetEntriesFast();
-    printf("\n Filling hits into HitMap\n");
-    printf("FindRawClusters -- ndigits %d \n",ndigits);
+    //printf("\n Filling hits into HitMap\n");
+    //printf("FindRawClusters -- ndigits %d \n",ndigits);
     if (!ndigits) return;
-    AliRICHdigit *dig;
+    AliRICHDigit *dig;
     for (Int_t ndig=0; ndig<fNdigits; ndig++) {
-       dig = (AliRICHdigit*)fDigits->UncheckedAt(ndig);
+       dig = (AliRICHDigit*)fDigits->UncheckedAt(ndig);
        SetHit(dig->fPadX,dig->fPadY,ndig);
     }
 }
index 2cedb98c35bdb10124ca7e0a99a809e6ec02626a..bbe5ba66a5495dc15fa898fc32de38033cee15fd 100644 (file)
@@ -1,10 +1,13 @@
 #ifndef AliRICHHitMap_H
 #define AliRICHHitMap_H
+
+
 /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
  * See cxx source for full Copyright notice                               */
 
 /* $Id$ */
 
+
 #include "AliRICH.h"
 #include "TArrayI.h"
 typedef enum {empty, used, unused} Flag_t;
@@ -14,7 +17,7 @@ class AliRICHHitMap :
 public TObject {
  public:
     virtual  void  FillHits()                                      =0;
-    virtual  void  Clear(Option_t* =0)                             =0;
+    virtual  void  Clear()                                         =0;
     virtual  void  SetHit(Int_t ix, Int_t iy, Int_t idigit)        =0;
     virtual  void  DeleteHit(Int_t ix, Int_t iy)                   =0;
     virtual Int_t  GetHitIndex(Int_t ix, Int_t iy)                 =0;
@@ -29,7 +32,7 @@ class AliRICHHitMapA1 :
 public AliRICHHitMap 
 {
  private:
-    AliRICHsegmentation *fSegmentation;
+    AliRICHSegmentation *fSegmentation;
     Int_t fNpx;
     Int_t fNpy;
     TObjArray *fDigits;
@@ -38,10 +41,10 @@ public AliRICHHitMap
     Int_t fMaxIndex;
     
  public:
-    AliRICHHitMapA1(AliRICHsegmentation *seg, TObjArray *dig);
+    AliRICHHitMapA1(AliRICHSegmentation *seg, TObjArray *dig);
     virtual ~AliRICHHitMapA1();
     virtual  void  FillHits();
-    virtual  void  Clear(Option_t* =0);    
+    virtual  void  Clear();    
     virtual  void  SetHit(Int_t ix, Int_t iy, Int_t idigit);
     virtual  void  DeleteHit(Int_t ix, Int_t iy);
     virtual Int_t  GetHitIndex(Int_t ix, Int_t iy);
diff --git a/RICH/AliRICHPoints.cxx b/RICH/AliRICHPoints.cxx
new file mode 100644 (file)
index 0000000..de61de7
--- /dev/null
@@ -0,0 +1,318 @@
+/**************************************************************************
+ * Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
+ *                                                                        *
+ * Author: The ALICE Off-line Project.                                    *
+ * Contributors are mentioned in the code where appropriate.              *
+ *                                                                        *
+ * Permission to use, copy, modify and distribute this software and its   *
+ * documentation strictly for non-commercial purposes is hereby granted   *
+ * without fee, provided that the above copyright notice appears in all   *
+ * copies and that both the copyright notice and this permission notice   *
+ * appear in the supporting documentation. The authors make no claims     *
+ * about the suitability of this software for any purpose. It is          *
+ * provided "as is" without express or implied warranty.                  *
+ **************************************************************************/
+
+/*
+  $Log$
+*/
+
+
+///////////////////////////////////////////////////////////////////////////////
+//                                                                           //
+//  This class contains the points for the ALICE event display               //
+//                                                                           //
+//Begin_Html
+/*
+<img src="gif/AliRICHPointsClass.gif">
+*/
+//End_Html
+//                                                                           //
+//                                                                           //
+///////////////////////////////////////////////////////////////////////////////
+#include "AliRICHDisplay.h"
+#include "AliRICHPoints.h"
+#include "AliRun.h"
+#include "TPad.h"
+#include "TView.h"
+#include "TMath.h"
+
+const Int_t MAX_Nipx=400, MAX_Nipy=800;
+ClassImp(AliRICHPoints)
+
+//_____________________________________________________________________________
+AliRICHPoints::AliRICHPoints()
+{
+  //
+  // Default constructor
+  //
+  fHitIndex = 0;
+  fTrackIndex = 0;
+  fDigitIndex = 0;
+  fMarker[0] = fMarker[1] = fMarker[2]=0;
+}
+
+//_____________________________________________________________________________
+AliRICHPoints::AliRICHPoints(Int_t npoints)
+  :AliPoints(npoints)
+{
+  //
+  // Standard constructor
+  //
+  fHitIndex = 0;
+  fTrackIndex = 0;
+  fDigitIndex = 0;
+  fMarker[0] = fMarker[1] = fMarker[2]=0;
+}
+        
+//_____________________________________________________________________________
+AliRICHPoints::~AliRICHPoints()
+{
+  //
+  // Default destructor
+  //
+  fHitIndex = 0;
+  fTrackIndex = 0;
+  fDigitIndex = 0;
+}
+
+//_____________________________________________________________________________
+void AliRICHPoints::DumpHit()
+{
+  //
+  //   Dump hit corresponding to this point
+  //
+  AliRICHHit *hit = GetHit();
+  if (hit) hit->Dump();
+}
+
+//_____________________________________________________________________________
+void AliRICHPoints::DumpDigit()
+{
+  //
+  //   Dump digit corresponding to this point
+  //
+  AliRICHDigit *digit = GetDigit();
+  if (digit) digit->Dump();
+}
+
+//_____________________________________________________________________________
+void AliRICHPoints::InspectHit()
+{
+  //
+  //   Inspect hit corresponding to this point
+  //
+  AliRICHHit *hit = GetHit();
+  if (hit) hit->Inspect();
+}
+
+//_____________________________________________________________________________
+void AliRICHPoints::InspectDigit()
+{
+  //
+  //   Inspect digit corresponding to this point
+  //
+  AliRICHDigit *digit = GetDigit();
+  if (digit) digit->Inspect();
+}
+
+//_____________________________________________________________________________
+Int_t AliRICHPoints::GetTrackIndex()
+{
+  //
+  //   Dump digit corresponding to this point
+  //
+  printf("GetTrackIndex - fTrackIndex %d \n",fTrackIndex);
+  this->Inspect();
+  return fTrackIndex;
+}
+
+//_____________________________________________________________________________
+AliRICHHit *AliRICHPoints::GetHit() const
+{
+  //
+  //   Returns pointer to hit index in AliRun::fParticles
+  //
+  AliRICH *RICH  = (AliRICH*)gAlice->GetDetector("RICH");
+  gAlice->TreeH()->GetEvent(fTrackIndex);
+  TClonesArray *RICHhits  = RICH->Hits();
+  Int_t nhits = RICHhits->GetEntriesFast();
+  if (fHitIndex < 0 || fHitIndex >= nhits) return 0;
+  return (AliRICHHit*)RICHhits->UncheckedAt(fHitIndex);
+}
+
+//_____________________________________________________________________________
+AliRICHDigit *AliRICHPoints::GetDigit() const
+{
+  //
+  //   Returns pointer to digit index in AliRun::fParticles
+  //
+
+  AliRICHDisplay *display=(AliRICHDisplay*)gAlice->Display();
+  Int_t chamber=display->GetChamber();
+  Int_t cathode=display->GetCathode();
+   
+  AliRICH *RICH  = (AliRICH*)gAlice->GetDetector("RICH");
+  TClonesArray *RICHdigits  = RICH->DigitsAddress(chamber-1);
+  gAlice->TreeD()->GetEvent(cathode);
+  Int_t ndigits = RICHdigits->GetEntriesFast();
+  if (fDigitIndex < 0 || fDigitIndex >= ndigits) return 0;
+  return (AliRICHDigit*)RICHdigits->UncheckedAt(fDigitIndex);
+}
+//_____________________________________________________________________________
+struct Bin {
+   const AliRICHDigit *dig;
+   int idx;
+   Bin() {dig=0; idx=-1;}
+};
+
+struct PreCluster : public AliRICHRawCluster {
+   const AliRICHDigit* summit;
+   int idx;
+   int cut;
+   int npeaks;
+   PreCluster() : AliRICHRawCluster() {cut=npeaks=0;}
+};
+//_____________________________________________________________________________
+
+static void FindCluster(AliRICHChamber *iChamber, AliRICHSegmentation *segmentation, int i, int j, Bin bins[MAX_Nipx][MAX_Nipy], PreCluster &c) 
+
+{
+
+  //
+  // Find clusters
+  //
+
+  printf("I'm in FindCluster \n"); 
+
+  Bin& b=bins[i][j];
+  Int_t q=b.dig->fSignal;
+
+  printf("FindCluster - i j q %d %d %d\n",i,j,q);
+  
+  if (q<0) { 
+    q=-q;
+    c.cut=1;
+  } 
+  if (b.idx >= 0 && b.idx != c.idx) {
+    c.idx=b.idx;
+    c.npeaks++;
+  }
+  
+  if (q > TMath::Abs(c.summit->fSignal)) c.summit=b.dig;
+
+  Int_t npx  = segmentation->Npx();
+  Int_t npy  = segmentation->Npy();
+  Float_t x,y;
+  segmentation->GetPadCxy(i-npx, j-npy, x,y);
+  printf("FindCluster - x  y %f %f \n",x,y);
+
+
+  c.fX += q*x;
+  c.fY += q*y;
+  c.fQ += q;
+  
+  b.dig = 0;  b.idx = c.idx;
+  
+  if (bins[i-1][j].dig) FindCluster(iChamber,segmentation,i-1,j,bins,c);
+  if (bins[i][j-1].dig) FindCluster(iChamber,segmentation,i,j-1,bins,c);
+  if (bins[i+1][j].dig) FindCluster(iChamber,segmentation,i+1,j,bins,c);
+  if (bins[i][j+1].dig) FindCluster(iChamber,segmentation,i,j+1,bins,c);
+
+}
+
+//_____________________________________________________________________________
+
+void AliRICHPoints::GetCenterOfGravity()
+{
+  //
+  // simple RICH cluster finder from digits -- finds neighbours and 
+  // calculates center of gravity for the cluster
+  //
+  const Int_t MAX_nipx=400, MAX_nipy=800;
+  printf("\n Hallo world");
+  AliRICHDisplay *display=(AliRICHDisplay*)gAlice->Display();
+  Int_t chamber=display->GetChamber();
+  Int_t cathode=display->GetCathode();
+   
+  AliRICH *RICH  = (AliRICH*)gAlice->GetDetector("RICH");
+  AliRICHChamber *iChamber;
+  AliRICHSegmentation *segmentation;
+  iChamber =&(RICH->Chamber(chamber-1));
+  segmentation=iChamber->GetSegmentationModel(cathode);
+  Int_t npx  = segmentation->Npx();
+  Int_t npy  = segmentation->Npy();
+  Float_t zpos=iChamber->ZPosition();
+  
+  TClonesArray *RICHdigits  = RICH->DigitsAddress(chamber-1);
+  gAlice->TreeD()->GetEvent(cathode);
+  Int_t ndigits = RICHdigits->GetEntriesFast();
+  if (fDigitIndex < 0 || fDigitIndex >= ndigits) return;
+
+  AliRICHDigit  *dig;
+  dig=(AliRICHDigit*)RICHdigits->UncheckedAt(fDigitIndex);
+  Int_t ipx=dig->fPadX;
+  Int_t ipy=dig->fPadY;
+  Bin bins[MAX_nipx][MAX_nipy]; 
+  bins[ipx+npx][ipy+npy].dig=dig;
+    
+  int ndig;
+  int ncls=0;
+  for (ndig=0; ndig<ndigits; ndig++) {
+      dig = (AliRICHDigit*)RICHdigits->UncheckedAt(ndig);
+      int i=dig->fPadX, j=dig->fPadY;
+      bins[i+npx][j+npy].dig=dig;
+  }
+
+  PreCluster c; c.summit=bins[ipx+npx][ipy+npy].dig; c.idx=ncls;
+  FindCluster(iChamber,segmentation,ipx+npx, ipy+npy, bins, c);
+  if (c.npeaks>1) {
+      printf("GetCenterOfGravity -- more than one peak");
+  }
+  c.fX /= c.fQ;
+  c.fY /= c.fQ;
+  printf("GetCenterOfGravity - c.fX c.fY c.fQ %f %f %d \n",c.fX,c.fY,c.fQ);
+  
+  c.fTracks[0]=c.summit->fTracks[0];
+  c.fTracks[1]=c.summit->fTracks[1];
+  c.fTracks[2]=c.summit->fTracks[2];
+  ncls++;
+  AliRICHPoints *points = 0;
+  points = new AliRICHPoints(1);
+  points->SetMarkerColor(kYellow);
+  points->SetMarkerStyle(5);
+  points->SetMarkerSize(1.);
+  points->SetPoint(0,c.fX,c.fY,zpos);
+  points->Draw();
+  
+  printf("GetCenterOfGravity -- ncls %d \n",ncls);
+
+}
+
+//_____________________________________________________________________________
+const Text_t *AliRICHPoints::GetName() const
+{
+  //
+  // Return name of the Geant3 particle corresponding to this point
+  //
+  TParticle *particle = GetParticle();
+  if (!particle) return "Particle";
+  return particle->GetName();
+}
+
+//_____________________________________________________________________________
+Text_t *AliRICHPoints::GetObjectInfo(Int_t, Int_t)
+{
+  //
+  //   Redefines TObject::GetObjectInfo.
+  //   Displays the info (particle,etc
+  //   corresponding to cursor position px,py
+  //
+  static char info[64];
+  sprintf(info,"%s %d",GetName(),fIndex);
+  return info;
+}
+
+
+
index 06a18239b3250e29da5f9db24c764a4c081540ed..4c3819028de4a8be8bc5db611cbece78c7d38709 100644 (file)
  **************************************************************************/
 
 /*
-$Log$
+  $Log$
 */
 
+
 #include "AliRICHSegResCkv.h"
 #include "TMath.h"
 #include "TRandom.h"
 
 
 //___________________________________________
-ClassImp(AliRICHresponseCkv)
+ClassImp(AliRICHResponseCkv)
 //___________________________________________  
-Float_t AliRICHresponseCkv::IntPH(Float_t)
+Float_t AliRICHResponseCkv::IntPH(Float_t)
 {
     
-    Float_t charge = -fChslope*TMath::Log(gRandom->Rndm());
+    Float_t charge = -fChargeSlope*TMath::Log(gRandom->Rndm());
+    return charge;
+}
+
+Float_t AliRICHResponseCkv::IntPH()
+{
+    Float_t charge = -fChargeSlope*TMath::Log(gRandom->Rndm());
     return charge;
 }
 
index 7e3a3c54693da660403ddff28095a01bcfe4fce6..d0c4e6f7cadeda9c0e3e4ea63b81d52805d3143b 100644 (file)
 #ifndef RICHSegResV0_H
 #define RICHSegResV0_H
+
+
 /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
  * See cxx source for full Copyright notice                               */
 
 /* $Id$ */
 
+
 #include "AliRICH.h"
 #include "AliRICHv0.h"
+#include "AliRICHSegRes.h"
 
-class AliRICHsegmentationV0 :
-public AliRICHsegmentation {
+class AliRICHSegmentationV0 :
+public AliRICHSegmentation {
  public:
-    AliRICHsegmentationV0(){}
-    virtual ~AliRICHsegmentationV0(){}
+    AliRICHSegmentationV0(){}
+    virtual ~AliRICHSegmentationV0(){}
     //    
     // Set Chamber Segmentation Parameters
-    virtual  void    SetPADSIZ(Float_t p1, Float_t p2);
+    //
+    // Pad size Dx*Dy 
+    virtual  void    SetPadSize(Float_t p1, Float_t p2);
+    // Anod Pitch
     virtual  void    SetDAnod(Float_t D) {fWireD = D;};
+        
     //
-    // Transform from pad (wire) to real coordinates and vice versa  
+    // Transform from pad (wire) to real coordinates and vice versa
+    //
+    // Anod wire coordinate closest to xhit
     virtual Float_t GetAnod(Float_t xhit);
+    // Transform from pad to real coordinates
     virtual void    GetPadIxy(Float_t x ,Float_t y ,Int_t   &ix,Int_t   &iy);
+    // Transform from real to pad coordinates
     virtual void    GetPadCxy(Int_t   ix,Int_t   iy,Float_t &x ,Float_t &y );
     //
     // Initialisation
-    virtual void Init(AliRICHchamber*);
+    virtual void Init(AliRICHChamber*);
     //
     // Get member data
+    //
+    // Pad size in x
     virtual Float_t Dpx(){return fDpx;}
+    //
+    // Pad size in y
     virtual Float_t Dpy(){return fDpy;}
+    // Pad size in x by Sector
+    virtual Float_t Dpx(Int_t) {return fDpx;}
+    // Pad size in y by Sector
+    virtual Float_t Dpy(Int_t) {return fDpy;}
+    // Max number of Pads in x
     virtual Int_t   Npx(){return fNpx;}
+    // Max number of Pads in y
     virtual Int_t   Npy(){return fNpy;}
+    
+
+    // set pad position
+    virtual void     SetPad(Int_t, Int_t);
+    // set hit position
+    virtual void     SetHit(Float_t, Float_t);
     //
     // Iterate over pads
+    // Initialiser
     virtual void  FirstPad(Float_t xhit, Float_t yhit, Float_t dx, Float_t dy);
+    // Stepper
     virtual void  NextPad();
+    // Condition
     virtual Int_t MorePads();
+    //
+    // Distance between 1 pad and a position
+    virtual Float_t Distance2AndOffset(Int_t iX, Int_t iY, Float_t X, Float_t Y, Int_t *
+                                      dummy);
+    // Number of pads read in parallel and offset to add to x 
+    // (specific to LYON, but mandatory for display)
+    virtual void GetNParallelAndOffset(Int_t iX, Int_t iY,
+                                      Int_t *Nparallel, Int_t *Offset) {*Nparallel=1;*Offset=0;}
     // Get next neighbours 
     virtual void Neighbours
        (Int_t iX, Int_t iY, Int_t* Nlist, Int_t Xlist[10], Int_t Ylist[10]);
-    // Provisory RecCluster coordinates reconstructor
-    virtual void FitXY(AliRICHRecCluster* Cluster,TClonesArray* RICHdigits);
     //
     // Current Pad during Integration
+    // x-coordinate
     virtual Int_t  Ix(){return fix;}
-    virtual Int_t  Iy(){return fiy;}    
+    // y-coordinate
+    virtual Int_t  Iy(){return fiy;}
+    // current sector
     virtual Int_t  ISector(){return 1;}
+    // calculate sector from x-y coordinates
+    virtual Int_t  Sector(Float_t x, Float_t y){return 1;}
     //
     // Signal Generation Condition during Stepping
     virtual Int_t SigGenCond(Float_t x, Float_t y, Float_t z);
+    // Initialise signal gneration at coord (x,y,z)
     virtual void  SigGenInit(Float_t x, Float_t y, Float_t z);
+    // Current integration limits
     virtual void IntegrationLimits
        (Float_t& x1, Float_t& x2, Float_t& y1, Float_t& y2);
-    //
-    // Identification
-    virtual char* YourName(){return fName;}
-    ClassDef(AliRICHsegmentationV0,1)
+    // Test points for auto calibration
+    virtual void GiveTestPoints(Int_t &n, Float_t *x, Float_t *y);
+    // Debugging utilities
+    virtual void Draw();
+    // Function for systematic corrections
+    virtual void SetCorrFunc(Int_t dum, TF1* func) {fCorr=func;}
+    
+    virtual TF1* CorrFunc(Int_t) {return fCorr;} 
+    ClassDef(AliRICHSegmentationV0,1)
        protected:
     //
     // Implementation of the segmentation data
@@ -64,50 +113,71 @@ public AliRICHsegmentation {
     //
     //  geometry
     //
-    Float_t    fDpx;           // x pad width per sector  
-    Float_t    fDpy;           // y pad base width
-    Int_t      fNpx;
-    Int_t      fNpy;           // Number of pads in y
-    Float_t    fWireD;         // wire pitch
+    Float_t    fDpx;             // x pad width per sector  
+    Float_t    fDpy;             // y pad base width
+    Int_t      fNpx;             // Number of pads in x
+    Int_t      fNpy;             // Number of pads in y
+    Int_t      fSector;          // Current padplane
+    Float_t    fWireD;           // wire pitch
     
+
+        
     // Chamber region consideres during disintegration (lower left and upper right corner)
     //
-    Int_t fixmin;
-    Int_t fixmax;
-    Int_t fiymin;
-    Int_t fiymax;
+    Int_t fixmin; // lower left  x
+    Int_t fixmax; // lower left  y
+    Int_t fiymin; // upper right x
+    Int_t fiymax; // upper right y 
     //
     // Current pad during integration (cursor for disintegration)
-    Int_t fix;
-    Int_t fiy;
-    Float_t fx;
-    Float_t fy;
+    Int_t fix;  // pad coord. x 
+    Int_t fiy;  // pad coord. y 
+    Float_t fx; // x
+    Float_t fy; // y
     //
     // Current pad and wire during tracking (cursor at hit centre)
-    Int_t fixt;
-    Int_t fiyt;
-    Int_t fiwt;
-    Float_t fxt;
-    Float_t fyt;
-    //
-    char    *fName;       //! Version Identifier
+    Float_t fxhit;
+    Float_t fyhit;
+    // Reference point to define signal generation condition
+    Int_t fixt;     // pad coord. x
+    Int_t fiyt;     // pad coord. y
+    Int_t fiwt;     // wire number
+    Float_t fxt;    // x
+    Float_t fyt;    // y
+    TF1*    fCorr;  // correction function
 };
 
-class AliRICHresponseV0 : //Mathieson response
-public AliRICHresponse {
+class AliRICHResponseV0 : //Mathieson response
+public AliRICHResponse {
  public:
-    AliRICHresponseV0(){}
-    virtual ~AliRICHresponseV0(){}
-    
-    
-    
+    AliRICHResponseV0(){}
+    virtual ~AliRICHResponseV0(){}
     //
     // Configuration methods
     // 
-    virtual void   SetRSIGM(Float_t p1) {fNsigma=p1;} 
-    virtual void   SetMUCHSP(Float_t p1) {fChslope=p1;}
-    virtual void   SetMUSIGM(Float_t p1, Float_t p2) {fChwX=p1; fChwY=p2;}
-    virtual void   SetMAXADC(Float_t p1) {fadc_satm=p1;}
+    // Number of sigmas over which cluster didintegration is performed
+    virtual void    SetSigmaIntegration(Float_t p1) {fSigmaIntegration=p1;}
+    virtual Float_t SigmaIntegration() {return fSigmaIntegration;}    
+    // charge slope in ADC/e
+    virtual void    SetChargeSlope(Float_t p1) {fChargeSlope=p1;}
+    virtual Float_t ChargeSlope()      {return fChargeSlope;}
+    // sigma of the charge spread function
+    virtual void    SetChargeSpread(Float_t p1, Float_t p2)
+       {fChargeSpreadX=p1; fChargeSpreadY=p2;}
+    virtual Float_t ChargeSpreadX()    {return fChargeSpreadX;}    
+    virtual Float_t ChargeSpreadY()    {return fChargeSpreadY;}        
+    // Adc-count saturation value
+    virtual void    SetMaxAdc(Float_t p1) {fMaxAdc=p1;}
+    virtual Float_t MaxAdc()           {return fMaxAdc;}
+    // anode cathode Pitch
+    virtual Float_t Pitch()            {return fPitch;}
+    virtual void    SetPitch(Float_t p1) {fPitch=p1;};
+    // alpha feedback
+    virtual void    SetAlphaFeedback(Float_t alpha) {fAlphaFeedback=alpha;}
+    virtual Float_t AlphaFeedback()  {return fAlphaFeedback;}
+    // ionisation enrgy
+    virtual void    SetEIonisation(Float_t e) {fEIonisation=e;}
+    virtual Float_t EIonisation() {return fEIonisation;}                            
     // Mathieson parameters
     virtual void   SetSqrtKx3(Float_t p1) {fSqrtKx3=p1;};
     virtual void   SetKx2(Float_t p1) {fKx2=p1;};
@@ -115,34 +185,22 @@ public AliRICHresponse {
     virtual void   SetSqrtKy3(Float_t p1) {fSqrtKy3=p1;};
     virtual void   SetKy2(Float_t p1) {fKy2=p1;};
     virtual void   SetKy4(Float_t p1) {fKy4=p1;};
-    virtual void   SetPitch(Float_t p1) {fPitch=p1;};
-    
-    //
-    // Get member data
-    virtual Float_t Chslope() {return fChslope;}
-    virtual Float_t ChwX() {return fChwX;}    
-    virtual Float_t ChwY() {return fChwY;}        
-    virtual Float_t Nsigma() {return fNsigma;}    
-    virtual Float_t adc_satm() {return fadc_satm;}
     //  
     // Chamber response methods
     // Pulse height from scored quantity (eloss)
-    virtual Float_t IntPH(Float_t eloss=0);
-    virtual Int_t FeedBackPhotons(Float_t *source, Float_t qtot);
-    
+    virtual Float_t IntPH(Float_t eloss);
+    virtual Float_t IntPH();
     // Charge disintegration
-    virtual Float_t IntXY(AliRICHsegmentation * segmentation);
-    // Identification
-    //
-    virtual char* YourName() {return fName;}
-    
-    ClassDef(AliRICHresponseV0,1)
+    virtual Float_t IntXY(AliRICHSegmentation * segmentation);
+    virtual Int_t   FeedBackPhotons(Float_t *source, Float_t qtot);
        protected:
-    Float_t fChslope;         // Slope of the charge distribution
-    Float_t fChwX;            // Width of the charge distribution in x
-    Float_t fChwY;            // Width of the charge distribution in y
-    Float_t fNsigma;          // Number of sigma's used for charge distribution
-    Float_t fadc_satm;        // Maximum ADC channel
+    Float_t fChargeSlope;              // Slope of the charge distribution
+    Float_t fChargeSpreadX;            // Width of the charge distribution in x
+    Float_t fChargeSpreadY;            // Width of the charge distribution in y
+    Float_t fSigmaIntegration;         // Number of sigma's used for charge distribution
+    Float_t fAlphaFeedback;            // Feedback photons coefficient
+    Float_t fEIonisation;              // Mean ionisation energy
+    Float_t fMaxAdc;                   // Maximum ADC channel
     Float_t fSqrtKx3;         // Mathieson parameters for x
     Float_t fKx2;
     Float_t fKx4;
@@ -150,7 +208,68 @@ public AliRICHresponse {
     Float_t fKy2;
     Float_t fKy4;
     Float_t fPitch;           //anode-cathode pitch
-    char    *fName;           //! Version Identifier
+    ClassDef(AliRICHResponseV0,1)
+};
+
+class AliRICHGeometryV0 : //Chamber geometry
+public AliRICHGeometry {
+ public:
+    // Radiator Thickness
+    virtual void   SetGapThickness(Float_t thickness)  {fGapThickness=thickness;} 
+    // Proximity Gap Thickness
+    virtual void   SetProximityGapThickness(Float_t thickness)       {fProximityGapThickness=thickness;}
+    // Quartz Length
+    virtual void   SetQuartzLength(Float_t length)          {fQuartzLength=length;}
+    // Quartz Width
+    virtual void   SetQuartzWidth(Float_t width)            {fQuartzWidth=width;}
+    // Quartz Thickness
+    virtual void   SetQuartzThickness(Float_t thickness)    {fQuartzThickness=thickness;}
+    // Freon Length
+    virtual void   SetOuterFreonLength(Float_t length)          {fOuterFreonLength=length;}
+    // Freon Width
+    virtual void   SetOuterFreonWidth(Float_t width)            {fOuterFreonWidth=width;}
+    // Freon Length
+    virtual void   SetInnerFreonLength(Float_t length)          {fInnerFreonLength=length;}
+    // Freon Width
+    virtual void   SetInnerFreonWidth(Float_t width)            {fInnerFreonWidth=width;}
+    // Freon Thickness
+    virtual void   SetFreonThickness(Float_t thickness)    {fFreonThickness=thickness;}
+
+    // Radiator thickness
+    virtual Float_t  GetGapThickness(){return fGapThickness;}
+    // Proximity Gap thickness
+    virtual Float_t  GetProximityGapThickness(){return fProximityGapThickness;}
+    // Quartz Length
+    virtual Float_t  GetQuartzLength(){return fQuartzLength;}
+    // Quartz Width
+    virtual Float_t  GetQuartzWidth(){return fQuartzWidth;}
+    // Quartz Thickness
+    virtual Float_t  GetQuartzThickness(){return fQuartzThickness;}
+    // Freon Length
+    virtual Float_t  GetOuterFreonLength(){return fOuterFreonLength;}
+    // Freon Width
+    virtual Float_t  GetOuterFreonWidth(){return fOuterFreonWidth;}
+    // Freon Length
+    virtual Float_t  GetInnerFreonLength(){return fInnerFreonLength;}
+    // Freon Width
+    virtual Float_t  GetInnerFreonWidth(){return fInnerFreonWidth;}
+    // Freon Thickness
+    virtual Float_t  GetFreonThickness(){return fFreonThickness;}
+
+    //Self-explainable:
+
+    Float_t fGapThickness;
+    Float_t fProximityGapThickness;
+    Float_t fQuartzLength;
+    Float_t fQuartzWidth;
+    Float_t fQuartzThickness;
+    Float_t fOuterFreonLength;
+    Float_t fOuterFreonWidth;
+    Float_t fInnerFreonLength;
+    Float_t fInnerFreonWidth;
+    Float_t fFreonThickness;
+
+    ClassDef(AliRICHGeometryV0,1)
 };
 
 #endif