Conversion photons to photoelectrons moved to AliSTARTv1
authoralla <alla@f7af4fe6-9843-0410-8265-dc069ae4e863>
Thu, 9 Nov 2006 13:31:43 +0000 (13:31 +0000)
committeralla <alla@f7af4fe6-9843-0410-8265-dc069ae4e863>
Thu, 9 Nov 2006 13:31:43 +0000 (13:31 +0000)
START/AliSTARTDigitizer.cxx
START/readRec.C

index 768b5ac..faf4084 100644 (file)
@@ -135,7 +135,7 @@ void AliSTARTDigitizer::Exec(Option_t* /*option*/)
   Float_t gain[24],timeDelayCFD[24], timeDelayLED[24];
   Int_t threshold =50; //photoelectrons
   Float_t zdetA, zdetC;
-   Int_t sumMultCoeff = 25;
+   Int_t sumMultCoeff = 100;
   TObjArray slewingLED;
   TObjArray slewingRec;
   AliSTARTParameters* param = AliSTARTParameters::Instance();
@@ -219,10 +219,11 @@ void AliSTARTDigitizer::Exec(Option_t* /*option*/)
          }
          pmt=startHit->Pmt();
          Int_t numpmt=pmt-1;
-                 Double_t e=startHit->Etot();
+         Double_t e=startHit->Etot();
          volume = startHit->Volume();
          
-         if(e>0 && RegisterPhotoE(numpmt,e)) {
+         //      if(e>0 && RegisterPhotoE(numpmt,e)) {
+         if(e>0 ) {
            countE[numpmt]++;
            besttime[numpmt] = startHit->Time();
            if(besttime[numpmt]<time[numpmt])
index 362301c..c756724 100644 (file)
@@ -39,11 +39,19 @@ void readRec()
   TH1F *hRealVertex = new TH1F("hRealVertex","Real Vertex",100,-15,15);
   
   TH1F *hVertex = new TH1F("hVertex","Z position of vertex",   100,-15,15);
+  TH1F *hAmp = new TH1F("hAmp"," amplitude",   100, 10,1000);
+  TH1F *hTime = new TH1F("hTime"," time",   100,12000.,20000);
+
+  TArrayI *amp = new TArrayI(24);  
+  TArrayI *time = new TArrayI(24);  
+
   AliSTARTRecPoint *fRec   ; // digits
   fRec = new AliSTARTRecPoint();
 
  // Event ------------------------- LOOP  
   for (Int_t ievent=0; ievent<iNevents; ievent++){
+    // for (Int_t ievent=0; ievent<990; ievent++){
     rl->GetEvent(ievent);
 
     AliHeader *header = gAlice->GetHeader();
@@ -71,10 +79,17 @@ void readRec()
     hBestTimeC->Fill(0.001 * besttimeright);
     hBestTimeA->Fill(0.001 * besttimeleft );
     Float_t vertex= fRec->GetVertex();
+    if(vertex<99){
     cout<<ievent<<" "<<mean<<" real vertex "<< zRealVertex<<" vertex "<<vertex<<
       " a "<< besttimeleft<<" c "<< besttimeright<<endl;
-    hAcc->Fill(zRealVertex-vertex/2.);
-    hVertex->Fill(vertex/2.);
+    hAcc->Fill(zRealVertex-vertex);
+    hVertex->Fill(vertex);
+     for (Int_t i=0; i<24; i++){ 
+      hAmp->Fill(fRec->GetAmp(i));
+      hTime->Fill(fRec->GetTime(i));
+      //  cout<<"time "<<fRec->GetTime(i)<<" amp "<<fRec->GetAmp(i)<<endl;
+    } 
+    }
   }
   Hfile = new TFile("FigRec.root","RECREATE","Histograms for START 
 digits");
@@ -89,7 +104,9 @@ digits");
   hVertex->Write();
   hRealVertex->Write();
   hAcc->Write();  
- hMean->Write();
+  hMean->Write();
+  hAmp->Write();
+  hTime->Write();
 } // end of macro