]> git.uio.no Git - u/mrichter/AliRoot.git/commitdiff
updating apd and fee parameters
authorjklay <jklay@f7af4fe6-9843-0410-8265-dc069ae4e863>
Mon, 14 Apr 2008 19:59:30 +0000 (19:59 +0000)
committerjklay <jklay@f7af4fe6-9843-0410-8265-dc069ae4e863>
Mon, 14 Apr 2008 19:59:30 +0000 (19:59 +0000)
EMCAL/AliEMCALDigitizer.cxx
EMCAL/AliEMCALRawUtils.cxx
EMCAL/AliEMCALRawUtils.h
EMCAL/AliEMCALSDigitizer.cxx

index dfe5ea132878911c5a4827cc8cc0abc906f7d53e..ff290568d5697085b83b1868a240debebe9ee687 100644 (file)
@@ -241,7 +241,6 @@ void AliEMCALDigitizer::Digitize(Int_t event)
   // after that adds contributions from SDigits. This design 
   // helps to avoid scanning over the list of digits to add 
   // contribution of any new SDigit.
-  static int isTrd1Geom = -1; // -1 - mean undefined 
   static int nEMC=0; //max number of digits possible
 
   AliRunLoader *rl = AliRunLoader::GetRunLoader();
@@ -266,16 +265,9 @@ void AliEMCALDigitizer::Digitize(Int_t event)
   else 
     AliFatal("Could not get AliRun from runLoader");
 
-  if(isTrd1Geom < 0) { 
-    AliDebug(1, Form(" get Geometry %s : %s ", geom->GetName(),geom->GetTitle()));
-    TString ng(geom->GetName());
-    isTrd1Geom = 0;
-    if(ng.Contains("SHISH") &&  ng.Contains("TRD1")) isTrd1Geom = 1;
-
-    if(isTrd1Geom == 0) nEMC = geom->GetNPhi()*geom->GetNZ();
-    else                nEMC = geom->GetNCells();
-    AliDebug(1,Form("nEMC %i (number cells in EMCAL) | %s | isTrd1Geom %i\n", nEMC, geom->GetName(), isTrd1Geom));
-  }
+  nEMC = geom->GetNCells();
+  AliDebug(1,Form("nEMC %i (number cells in EMCAL) | %s \n", nEMC, geom->GetName()));
+  
   Int_t absID ;
 
   digits->Expand(nEMC) ;
@@ -617,9 +609,10 @@ void AliEMCALDigitizer::InitParameters()
 { 
   // Parameter initialization for digitizer
   // Tune parameters - 24-nov-04; Apr 29, 2007
+  // New parameters JLK 14-Apr-2008
 
-  fMeanPhotonElectron = 3300;  // electrons per GeV 
-  fPinNoise           = 0.010; // pin noise in GEV from analysis test beam data 
+  fMeanPhotonElectron = 4400;  // electrons per GeV 
+  fPinNoise           = 0.037; // pin noise in GEV from analysis test beam data 
   if (fPinNoise == 0. ) 
     Warning("InitParameters", "No noise added\n") ; 
   fDigitThreshold     = fPinNoise * 3; // 3 * sigma
@@ -691,6 +684,7 @@ void AliEMCALDigitizer::MixWith(TString alirunFileName, TString eventFolderName)
     fInput++ ;
 }  
 
+//__________________________________________________________________
 void AliEMCALDigitizer::Print1(Option_t * option)
 { // 19-nov-04 - just for convinience
   Print(); 
@@ -837,12 +831,14 @@ void AliEMCALDigitizer::WriteDigits()
 
 }
 
+//__________________________________________________________________
 void AliEMCALDigitizer::Browse(TBrowser* b)
 {
   if(fHists) b->Add(fHists);
   TTask::Browse(b);
 }
 
+//__________________________________________________________________
 TList *AliEMCALDigitizer::BookControlHists(int var)
 { 
   // 22-nov-04
@@ -866,6 +862,7 @@ TList *AliEMCALDigitizer::BookControlHists(int var)
   return fHists;
 }
 
+//__________________________________________________________________
 void AliEMCALDigitizer::SaveHists(const char* name, Bool_t kSingleKey, const char* opt)
 {
   AliEMCALHistoUtilities::SaveListOfHists(fHists, name, kSingleKey, opt); 
index de2633d2ba15f808d4942e4f076571a04408c86a..3e19eb56e941d8bd3e47af36da0f57312f33d267 100644 (file)
@@ -80,6 +80,8 @@ Double_t AliEMCALRawUtils::fgTimeTrigger = 1.5E-6 ;   // 15 time bins ~ 1.5 muse
 // some digitization constants
 Int_t    AliEMCALRawUtils::fgThreshold = 1;
 Int_t    AliEMCALRawUtils::fgDDLPerSuperModule = 2;  // 2 ddls per SuperModule
+Int_t    AliEMCALRawUtils::fgPedestalValue = 32;      // pedestal value for digits2raw
+Double_t AliEMCALRawUtils::fgFEENoise = 3.;            // 3 ADC channels of noise (sampled)
 
 AliEMCALRawUtils::AliEMCALRawUtils()
   : fHighLowGainFactor(0.), fOrder(0), fTau(0.), fNoiseThreshold(0),
@@ -523,7 +525,6 @@ const Double_t dtime, const Double_t damp, Int_t * adcH, Int_t * adcL) const
   // for a start time dtime and an amplitude damp given by digit, 
   // calculates the raw sampled response AliEMCAL::RawResponseFunction
 
-  const Int_t pedVal = 32;
   Bool_t lowGain = kFALSE ; 
 
   // A:   par[0]   // Amplitude = peak value
@@ -537,11 +538,17 @@ const Double_t dtime, const Double_t damp, Int_t * adcH, Int_t * adcL) const
   signalF.SetParameter(1, dtime + fgTimeTrigger) ; 
   signalF.SetParameter(2, fTau) ; 
   signalF.SetParameter(3, fOrder);
-  signalF.SetParameter(4, pedVal);
+  signalF.SetParameter(4, fgPedestalValue);
 
   for (Int_t iTime = 0; iTime < GetRawFormatTimeBins(); iTime++) {
     Double_t time = iTime * GetRawFormatTimeBinWidth() ;
     Double_t signal = signalF.Eval(time) ;     
+
+    //According to Terry Awes, 13-Apr-2008
+    //add gaussian noise in quadrature to each sample
+    //Double_t noise = gRandom->Gaus(0.,fgFEENoise);
+    //signal = sqrt(signal*signal + noise*noise);
+
     adcH[iTime] =  static_cast<Int_t>(signal + 0.5) ;
     if ( adcH[iTime] > fgkRawSignalOverflow ){  // larger than 10 bits 
       adcH[iTime] = fgkRawSignalOverflow ;
index cdca0d0d5b79f6fb1efadc72ab8a8e963808d57d..156c0a22eef03d43a7b77aa5a16177a6c0bd21a9 100644 (file)
@@ -96,13 +96,15 @@ class AliEMCALRawUtils : public TObject {
   static Double_t fgTimeBinWidth;       // maximum sampled time of the raw RO signal                             
   static Int_t fgThreshold;             // threshold
   static Int_t fgDDLPerSuperModule;     // number of DDL per SuperModule
+  static Int_t fgPedestalValue;         // pedestal value for Digits2Raw
+  static Double_t fgFEENoise;           // electronics noise in ADC units
 
   AliEMCALGeometry* fGeom;         //geometry
   AliAltroMapping*  fMapping[2];   //only two for now
 
   TString fOption;                      //! option passed from Reconstructor
 
-  ClassDef(AliEMCALRawUtils,2)          // utilities for raw signal fitting
+  ClassDef(AliEMCALRawUtils,3)          // utilities for raw signal fitting
 };
 
 #endif
index 476610b447e30ede56ceb81cad2140837f74cc31..c7b0c17f94f44be7daa97c5d6bb7bf9beef388e1 100644 (file)
@@ -446,12 +446,14 @@ void AliEMCALSDigitizer::Unload() const
   rl->UnloadSDigits() ; 
 }
 
+//____________________________________________________________________________ 
 void AliEMCALSDigitizer::Browse(TBrowser* b)
 {
   if(fHists) b->Add(fHists);
   TTask::Browse(b);
 }
 
+//____________________________________________________________________________ 
 TList *AliEMCALSDigitizer::BookControlHists(int var)
 { 
   //book histograms for monitoring sdigitization
@@ -474,6 +476,7 @@ TList *AliEMCALSDigitizer::BookControlHists(int var)
   return fHists;
 }
 
+//____________________________________________________________________________ 
 void AliEMCALSDigitizer::SaveHists(const char* name, Bool_t kSingleKey, const char* opt)
 {
   AliEMCALHistoUtilities::SaveListOfHists(fHists, name, kSingleKey, opt);