coding violations
authorcblume <cblume@f7af4fe6-9843-0410-8265-dc069ae4e863>
Thu, 29 Nov 2007 18:58:29 +0000 (18:58 +0000)
committercblume <cblume@f7af4fe6-9843-0410-8265-dc069ae4e863>
Thu, 29 Nov 2007 18:58:29 +0000 (18:58 +0000)
TRD/AliTRDCalibPadStatus.cxx
TRD/AliTRDCalibPadStatus.h
TRD/AliTRDCalibraMode.cxx
TRD/AliTRDCalibraVdriftLinearFit.cxx
TRD/AliTRDCalibraVdriftLinearFit.h
TRD/AliTRDCalibraVector.cxx
TRD/AliTRDCalibraVector.h
TRD/AliTRDcalibDB.h

index e6414e4db1a8c0f0b3434c9941589c20ad6f1bd1..abb50c8bdab453434793ef2315fda18ea9a9f711 100644 (file)
 
 /* $Id$ */
 
-/*
- example: fill pedestal with Gaussian noise
- AliTRDCalibPadStatus ped;
- ped.TestEvent(numberofevent);
- // Method without histo
- //////////////////////////
- ped.Analyse();
- //Create the histo of the AliTRDCalROC
- TH2F * histo2dm = ped.GetCalRocMean(0,kFALSE)->MakeHisto2D();
- histo2dm->Scale(10.0);
- TH1F * histo1dm = ped.GetCalRocMean(0,kFALSE)->MakeHisto1D();
- histo1dm->Scale(10.0);
- TH2F * histo2ds = ped.GetCalRocSquares(0,kFALSE)->MakeHisto2D();
- histo2ds->Scale(10.0);
- TH1F * histo1ds = ped.GetCalRocSquares(0,kFALSE)->MakeHisto1D();
- histo1ds->Scale(10.0)
- //Draw output;
- TCanvas* c1 = new TCanvas;
- c1->Divide(2,2);
- c1->cd(1);
- histo2dm->Draw("colz");
- c1->cd(2);
- histo1dm->Draw();
- c1->cd(3);
- histo2ds->Draw("colz");
- c1->cd(4);
- histo1ds->Draw();
-// Method with histo
-/////////////////////////
-ped.AnalyseHisto();
-//Take the histo
-TH1F * histo = ped.GetHisto(31);
-histo->SetEntries(1);
-histo->Draw();
-
-*/
+////////////////////////////////////////////////////////////////////////////
+//                                                                        //
+// Example: fill pedestal with Gaussian noise                             //
+//                                                                        //
+//  AliTRDCalibPadStatus ped;                                             //
+//  ped.TestEvent(numberofevent);                                         //
+//                                                                        //
+//  // Method without histo                                               //
+//  ped.Analyse();                                                        //
+//                                                                        //
+//  // Create the histo of the AliTRDCalROC                               //
+//  TH2F * histo2dm = ped.GetCalRocMean(0,kFALSE)->MakeHisto2D();         //
+//  histo2dm->Scale(10.0);                                                //
+//  TH1F * histo1dm = ped.GetCalRocMean(0,kFALSE)->MakeHisto1D();         //
+//  histo1dm->Scale(10.0);                                                //
+//  TH2F * histo2ds = ped.GetCalRocSquares(0,kFALSE)->MakeHisto2D();      //
+//  histo2ds->Scale(10.0);                                                //
+//  TH1F * histo1ds = ped.GetCalRocSquares(0,kFALSE)->MakeHisto1D();      //
+//  histo1ds->Scale(10.0)                                                 //
+//                                                                        //
+//  // Draw output                                                        //
+//  TCanvas* c1 = new TCanvas;                                            //
+//  c1->Divide(2,2);                                                      //
+//  c1->cd(1);                                                            //
+//  histo2dm->Draw("colz");                                               //
+//  c1->cd(2);                                                            //
+//  histo1dm->Draw();                                                     //
+//  c1->cd(3);                                                            //
+//  histo2ds->Draw("colz");                                               //
+//  c1->cd(4);                                                            //
+//  histo1ds->Draw();                                                     //
+//                                                                        //
+//  // Method with histo                                                  //
+//  ped.AnalyseHisto();                                                   //
+//                                                                        //
+//  // Take the histo                                                     //
+//  TH1F *histo = ped.GetHisto(31);                                       //
+//  histo->SetEntries(1);                                                 //
+//  histo->Draw();                                                        //
+//                                                                        //
+////////////////////////////////////////////////////////////////////////////
 
 //Root includes
 #include <TObjArray.h>
@@ -330,7 +335,7 @@ Int_t AliTRDCalibPadStatus::ProcessEvent(
                                          Bool_t /*nocheck*/
            
 #endif 
-                                         )
+                                         ) const
 {
   //
   //  process date event
@@ -492,7 +497,7 @@ void AliTRDCalibPadStatus::AnalyseHisto() /*FOLD00*/
     TVectorD param(3);
     TMatrixD dummy(3,3);
 
-    Float_t *array_hP=0;
+    Float_t *arrayHP=0;
 
 
     for (Int_t idet=0; idet<540; idet++){
@@ -504,12 +509,12 @@ void AliTRDCalibPadStatus::AnalyseHisto() /*FOLD00*/
        AliTRDCalROC *rocMean     = GetCalRocMean(idet,kTRUE);
        AliTRDCalROC *rocRMS      = GetCalRocRMS(idet,kTRUE);
 
-       array_hP = hP->GetArray();
+       arrayHP = hP->GetArray();
         Int_t nChannels = rocMean->GetNchannels();
 
        for (Int_t iChannel=0; iChannel<nChannels; iChannel++){
             Int_t offset = (nbinsAdc+2)*(iChannel+1)+1;
-           Double_t ret = AliMathBase::FitGaus(array_hP+offset,nbinsAdc,fAdcMin,fAdcMax,&param,&dummy);
+           Double_t ret = AliMathBase::FitGaus(arrayHP+offset,nbinsAdc,fAdcMin,fAdcMax,&param,&dummy);
             // if the fitting failed set noise and pedestal to 0
            if ((ret==-4) || (ret==-1) || (ret==-2)) {
                param[1]=0.0;
@@ -532,7 +537,7 @@ void AliTRDCalibPadStatus::AnalyseHisto() /*FOLD00*/
 
        for (Int_t iChannel=shift; iChannel<total; iChannel++){
             Int_t offset = (nbinsAdc+2)*(iChannel+1)+1;
-           Double_t ret = AliMathBase::FitGaus(array_hP+offset,nbinsAdc,fAdcMin,fAdcMax,&param,&dummy);
+           Double_t ret = AliMathBase::FitGaus(arrayHP+offset,nbinsAdc,fAdcMin,fAdcMax,&param,&dummy);
             // if the fitting failed set noise and pedestal to 0
            if ((ret==-4) || (ret==-1) || (ret==-2)) {
                param[1]=0.0;
@@ -650,7 +655,7 @@ AliTRDCalPad* AliTRDCalibPadStatus::CreateCalPad()
 }
 
 //_______________________________________________________________________________________
-AliTRDCalDet* AliTRDCalibPadStatus::CreateCalDet()
+AliTRDCalDet* AliTRDCalibPadStatus::CreateCalDet() const
 {
   //
   // Create Det Noise correction factor
index 1a146adaedceab37e8bbb3281671020227e26e2f..f75e4526c04ac5f047c7b22d2ecc8786921bfd74 100644 (file)
@@ -37,7 +37,7 @@ public:
 
   Int_t ProcessEvent(AliTRDRawStreamV2 *rawStream, Bool_t nocheck = kFALSE);
   Int_t ProcessEvent(AliRawReader    *rawReader, Bool_t nocheck = kFALSE);
-  Int_t ProcessEvent(eventHeaderStruct   *event, Bool_t nocheck = kFALSE);
+  Int_t ProcessEvent(eventHeaderStruct   *event, Bool_t nocheck = kFALSE) const;
 
   Int_t UpdateHisto(const Int_t idet, const Int_t iRow, const Int_t iCol,
                    const Int_t signal, const Int_t crowMax, const Int_t ccold, const Int_t icMcm);
@@ -45,7 +45,7 @@ public:
   void AnalyseHisto();
   AliTRDCalPadStatus *CreateCalPadStatus();
   AliTRDCalPad *CreateCalPad();
-  AliTRDCalDet *CreateCalDet();
+  AliTRDCalDet *CreateCalDet() const;
 
   void SetCalRocMean(AliTRDCalROC *mean, Int_t det);
   void SetCalRocRMS(AliTRDCalROC *rms, Int_t det);  
index 0c95899fb1533b67b8512a9e1558ab002f6bf689..baac34bd12c88c4c61753e0aff3be58af6cb4bee 100644 (file)
 // AliTRDCalibraMode                                                             
 //                                                                             
 // This class is for the modes of the TRD calibration.        
-// The user has to choose with the functions SetNz and SetNrphi the precision of the calibration. 
+// The user has to choose with the functions SetNz and SetNrphi
+// the precision of the calibration. 
+// Author:
+//   R. Bailhache (R.Bailhache@gsi.de)
+//                            
 //Begin_Html
 /*
 <br>
@@ -48,9 +52,6 @@
 //End_Html 
 //
 //                            
-// Author:
-//   R. Bailhache (R.Bailhache@gsi.de)
-//                            
 //////////////////////////////////////////////////////////////////////////////////////
 
 #include "AliLog.h"
index 07809aa228324541b37e004d4dd2048b71c16d07..aa3a386ad3eba289559e756861064fc9b5571a7f 100644 (file)
 
 /* $Id$ */
 
+////////////////////////////////////////////////////////////////////////////
+//                                                                        //
+// AliTRDCalibraVdriftLinearFit                                           //
+//                                                                        //
+// Does the Vdrift an ExB calibration by applying a linear fit            //
+//                                                                        //
+// Author:                                                                //
+//   R. Bailhache (R.Bailhache@gsi.de)                                    //
+//                                                                        //
+////////////////////////////////////////////////////////////////////////////
+
 //Root includes
 #include <TObjArray.h>
 #include <TH2F.h>
index a25d9883934fc00b72466d07a14606abd9ce5aed..4045fe235cace5258d9eaaf6dea6611914834b68 100644 (file)
@@ -20,7 +20,7 @@ class TTreeSRedirector;
 
 class AliTRDCalibraVdriftLinearFit : public TObject {
 
-public:
+ public:
 
   AliTRDCalibraVdriftLinearFit();
   AliTRDCalibraVdriftLinearFit(const AliTRDCalibraVdriftLinearFit &ped);
@@ -32,15 +32,15 @@ public:
   void            Update(Int_t detector, Float_t tnp, Float_t pars1);
   void            FillPEArray();
   void            Add(AliTRDCalibraVdriftLinearFit *ped);
-  TH2F            *GetLinearFitterHisto(Int_t detector, Bool_t force=kFALSE);
+  TH2F           *GetLinearFitterHisto(Int_t detector, Bool_t force=kFALSE);
   Bool_t          GetParam(Int_t detector, TVectorD *param);
   Bool_t          GetError(Int_t detector, TVectorD *error);
 
-  TObjArray       *GetPArray()                   { return &fLinearFitterPArray;       };
-  TObjArray       *GetEArray()                   { return &fLinearFitterEArray;       };
-  TObjArray       GetHistoArray()                { return fLinearFitterHistoArray;    };
+  TObjArray      *GetPArray()                    { return &fLinearFitterPArray;       };
+  TObjArray      *GetEArray()                    { return &fLinearFitterEArray;       };
+  TObjArray       GetHistoArray() const          { return fLinearFitterHistoArray;    };
 
-private:
+ private:
    
   Int_t           fVersion;                 // Version of the object
 
@@ -48,8 +48,6 @@ private:
   TObjArray       fLinearFitterPArray;      // Array of result parameters from linear fitters for the detectors
   TObjArray       fLinearFitterEArray;      // Array of result errors from linear fitters for the detectors
 
-public:
-
   ClassDef(AliTRDCalibraVdriftLinearFit,1)  // Online Vdrift calibration
 
 };
index 97b459fa7180b3b5963e6538c18705f4095789bb..716712c0826ddda9e574be82c09f9d528d35e2b0 100644 (file)
 
 /* $Id$ */
 
-/////////////////////////////////////////////////////////////////////////////////
-//                                                                             
-// AliTRDCalibraVector                                                             
-//                                                                             
-// This class is for the vector methode of the TRD calibration.        
-//                            
-// Author:
-//   R. Bailhache (R.Bailhache@gsi.de)
-//                            
-//////////////////////////////////////////////////////////////////////////////////////
+////////////////////////////////////////////////////////////////////////////
+//                                                                        //   
+// AliTRDCalibraVector                                                    //       
+//                                                                        //   
+// This class is for the vector method of the TRD calibration.            //
+//                                                                        //
+// Author:                                                                //
+//   R. Bailhache (R.Bailhache@gsi.de)                                    //
+//                                                                        //
+////////////////////////////////////////////////////////////////////////////
 
 #include <TGraphErrors.h>
 #include <TH1F.h>
@@ -576,7 +576,8 @@ TH1F *AliTRDCalibraVector::ConvertVectorCHHisto(Int_t det, Int_t group
 
 } 
 //_____________________________________________________________________
-AliTRDarrayI* AliTRDCalibraVector::GetPHEntries(Int_t det, Bool_t force) /*FOLD00*/
+AliTRDarrayI* AliTRDCalibraVector::GetPHEntries(Int_t det
+                                              , Bool_t force) /*FOLD00*/
 {
     //
     // return pointer to Carge ROC Calibration
@@ -586,7 +587,8 @@ AliTRDarrayI* AliTRDCalibraVector::GetPHEntries(Int_t det, Bool_t force) /*FOLD0
     return GetEntriesPH(det, arr, force);
 }
 //_____________________________________________________________________
-AliTRDarrayI* AliTRDCalibraVector::GetPRFEntries(Int_t det, Bool_t force) /*FOLD00*/
+AliTRDarrayI* AliTRDCalibraVector::GetPRFEntries(Int_t det
+                                               , Bool_t force) /*FOLD00*/
 {
     //
     // return pointer to Carge ROC Calibration
@@ -596,7 +598,8 @@ AliTRDarrayI* AliTRDCalibraVector::GetPRFEntries(Int_t det, Bool_t force) /*FOLD
     return GetEntriesPRF(det, arr, force);
 }
 //_____________________________________________________________________
-AliTRDarrayI* AliTRDCalibraVector::GetCHEntries(Int_t det, Bool_t force) /*FOLD00*/
+AliTRDarrayI* AliTRDCalibraVector::GetCHEntries(Int_t det
+                                              , Bool_t force) /*FOLD00*/
 {
     //
     // return pointer to Carge ROC Calibration
@@ -606,7 +609,8 @@ AliTRDarrayI* AliTRDCalibraVector::GetCHEntries(Int_t det, Bool_t force) /*FOLD0
     return GetEntriesCH(det, arr, force);
 }
 //_____________________________________________________________________
-AliTRDarrayF* AliTRDCalibraVector::GetPHMean(Int_t det, Bool_t force) /*FOLD00*/
+AliTRDarrayF* AliTRDCalibraVector::GetPHMean(Int_t det
+                                           , Bool_t force) /*FOLD00*/
 {
     //
     // return pointer to Carge ROC Calibration
@@ -616,7 +620,8 @@ AliTRDarrayF* AliTRDCalibraVector::GetPHMean(Int_t det, Bool_t force) /*FOLD00*/
     return GetMeanSquaresPH(det, arr, force);
 }
 //_____________________________________________________________________
-AliTRDarrayF* AliTRDCalibraVector::GetPHSquares(Int_t det, Bool_t force) /*FOLD00*/
+AliTRDarrayF* AliTRDCalibraVector::GetPHSquares(Int_t det
+                                              , Bool_t force) /*FOLD00*/
 {
     //
     // return pointer to Carge ROC Calibration
@@ -626,7 +631,8 @@ AliTRDarrayF* AliTRDCalibraVector::GetPHSquares(Int_t det, Bool_t force) /*FOLD0
     return GetMeanSquaresPH(det, arr, force);
 }
 //_____________________________________________________________________
-AliTRDarrayF* AliTRDCalibraVector::GetPRFMean(Int_t det, Bool_t force) /*FOLD00*/
+AliTRDarrayF* AliTRDCalibraVector::GetPRFMean(Int_t det
+                                            , Bool_t force) /*FOLD00*/
 {
     //
     // return pointer to Carge ROC Calibration
@@ -636,7 +642,8 @@ AliTRDarrayF* AliTRDCalibraVector::GetPRFMean(Int_t det, Bool_t force) /*FOLD00*
     return GetMeanSquaresPRF(det, arr, force);
 }
 //_____________________________________________________________________
-AliTRDarrayF* AliTRDCalibraVector::GetPRFSquares(Int_t det, Bool_t force) /*FOLD00*/
+AliTRDarrayF* AliTRDCalibraVector::GetPRFSquares(Int_t det
+                                               , Bool_t force) /*FOLD00*/
 {
     //
     // return pointer to Carge ROC Calibration
@@ -646,7 +653,9 @@ AliTRDarrayF* AliTRDCalibraVector::GetPRFSquares(Int_t det, Bool_t force) /*FOLD
     return GetMeanSquaresPRF(det, arr, force);
 }
 //_____________________________________________________________________
-AliTRDarrayI* AliTRDCalibraVector::GetEntriesCH(Int_t det, TObjArray* arr, Bool_t force) /*FOLD00*/
+AliTRDarrayI* AliTRDCalibraVector::GetEntriesCH(Int_t det
+                                              , TObjArray* arr
+                                              , Bool_t force) /*FOLD00*/
 {
     //
     // return pointer to AliTRDarrayI Entries
@@ -670,7 +679,9 @@ AliTRDarrayI* AliTRDCalibraVector::GetEntriesCH(Int_t det, TObjArray* arr, Bool_
     return croc;
 }
 //_____________________________________________________________________
-AliTRDarrayI* AliTRDCalibraVector::GetEntriesPRF(Int_t det, TObjArray* arr, Bool_t force) /*FOLD00*/
+AliTRDarrayI* AliTRDCalibraVector::GetEntriesPRF(Int_t det
+                                               , TObjArray* arr
+                                               , Bool_t force) /*FOLD00*/
 {
     //
     // return pointer to AliTRDarrayI Entries
@@ -695,7 +706,9 @@ AliTRDarrayI* AliTRDCalibraVector::GetEntriesPRF(Int_t det, TObjArray* arr, Bool
 
 }
 //_____________________________________________________________________
-AliTRDarrayI* AliTRDCalibraVector::GetEntriesPH(Int_t det, TObjArray* arr, Bool_t force) /*FOLD00*/
+AliTRDarrayI* AliTRDCalibraVector::GetEntriesPH(Int_t det
+                                              , TObjArray* arr
+                                              , Bool_t force) /*FOLD00*/
 {
     //
     // return pointer to AliTRDarrayI Entries
@@ -720,7 +733,9 @@ AliTRDarrayI* AliTRDCalibraVector::GetEntriesPH(Int_t det, TObjArray* arr, Bool_
 
 }
 //_____________________________________________________________________
-AliTRDarrayF* AliTRDCalibraVector::GetMeanSquaresPH(Int_t det, TObjArray* arr, Bool_t force) /*FOLD00*/
+AliTRDarrayF* AliTRDCalibraVector::GetMeanSquaresPH(Int_t det
+                                                  , TObjArray* arr
+                                                  , Bool_t force) /*FOLD00*/
 {
     //
     // return pointer to AliTRDarrayF Mean or Squares
@@ -744,7 +759,9 @@ AliTRDarrayF* AliTRDCalibraVector::GetMeanSquaresPH(Int_t det, TObjArray* arr, B
     return croc;
 }
 //_____________________________________________________________________
-AliTRDarrayF* AliTRDCalibraVector::GetMeanSquaresPRF(Int_t det, TObjArray* arr, Bool_t force) /*FOLD00*/
+AliTRDarrayF* AliTRDCalibraVector::GetMeanSquaresPRF(Int_t det
+                                                   , TObjArray* arr
+                                                   , Bool_t force) /*FOLD00*/
 {
     //
     // return pointer to AliTRDarrayF Mean or Squares
index 48174a5c5a226d524b72595d889b35be98f80518..43459e67b32c0e7aa5c4385621d20c88e28feb16 100644 (file)
@@ -64,8 +64,8 @@ class AliTRDCalibraVector : public TObject {
   Short_t        GetNumberBinPRF()const                        { return fNumberBinPRF;                          }
   Int_t          GetTimeMax()const                             { return fTimeMax;                               } 
   Float_t        GetPRFRange()const                            { return fPRFRange;                              } 
-  Short_t        GetDetCha0(Int_t i)                           { return fDetCha0[i];                            }
-  Short_t        GetDetCha2(Int_t i)                           { return fDetCha2[i];                            }
+  Short_t        GetDetCha0(Int_t i) const                     { return fDetCha0[i];                            }
+  Short_t        GetDetCha2(Int_t i) const                     { return fDetCha2[i];                            }
   const char*    GetNamePH()                                   { return fVectorPHEntries.GetName();             }
   const char*    GetNamePRF()                                  { return fVectorPRFEntries.GetName();            }
   const char*    GetNameCH()                                   { return fVectorCHEntries.GetName();             }
index d91e82a2a28024ad611fa411ef0c533dffc7b288..2aa94ccd5257e4014e5e54d326434908b66a7438 100644 (file)
@@ -33,7 +33,7 @@ class AliTRDcalibDB : public TObject {
   static void                Terminate();
 
   void                       SetRun(Long64_t run);
-  Long64_t                   GetRun() { return fRun; }
+  Long64_t                   GetRun() const { return fRun; }
 
   Float_t                    GetVdrift(Int_t det, Int_t col, Int_t row);
   Float_t                    GetVdriftAverage(Int_t det);