1 #ifndef ALITOFT0MAKERANA_H
2 #define ALITOFT0MAKERANA_H
3 /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4 * See cxx source for full Copyright notice */
6 /* $Id: AliRsnTOFT0maker.h,v 1.8 2010/01/19 16:32:20 noferini Exp $ */
8 ///////////////////////////////////////////////
10 // Manager class for time zero evaluation //
11 // with TOF informations //
13 ///////////////////////////////////////////////
18 #include "AliESDEvent.h"
22 class AliTOFcalibHisto;
25 class AliRsnTOFT0maker : public TObject {
39 case kPass2: out = "pass 2"; break;
40 case kPass4: out = "pass 4"; break;
41 case kLHC09d10: out = "LHC09d10"; break;
42 default: out = "none specific"; break;
49 virtual ~AliRsnTOFT0maker() ; // dtor
50 AliRsnTOFT0maker(const AliRsnTOFT0maker & t);
51 AliRsnTOFT0maker & operator=(const AliRsnTOFT0maker & t);
53 void SetESDdata(Bool_t val = kTRUE) {fESDswitch = val;};
55 // return (fCalculated[0]=event time -- fCalculated[1]=sigma event time in ps -- fCalculated[2]=mean event time for each fill -- fCalculated[3]=number of tracks at the TOF level) if you can subtruct the event time; return NULL if there is no event time
56 Double_t *RemakePID(AliESDEvent *esd, Double_t t0time = 0., Double_t t0sigma = 1000.); // t0time and t0sigma in ps
58 void SetTimeResolution(Double_t timeresolution) {fTimeResolution = timeresolution;}; // TOF timeresolution in [s] e.g. for 120 ps -> 1.2e-10
59 Double_t GetTimeResolution() const {return fTimeResolution;}
61 void LoadChannelMap(char *filename = "$ALICE_ROOT/TOF/enableMap.104892.root"); //load the enable channel map
62 void ApplyMask(AliESDEvent *esd);
64 void SetNoTOFT0(Bool_t status = kTRUE) {fNoTOFT0 = status;}; // disable the TOF T0 info
65 void SetMaskOffChannel(Bool_t status = kTRUE) {fKmask = status;}; // swith for the map off channel
68 void TakeTimeRawCorrection(AliESDEvent * const esd);
69 void RemakeTOFpid(AliESDEvent *esd, Float_t timezero);
70 Double_t GetT0Fill(Int_t nrun) const ;
72 AliTOFcalibHisto *fCalib; // TOF calibration object pointer
74 Bool_t fESDswitch; // if you want take the ESD time instead of the raw + time slewing correction
76 Double_t fCalculated[4]; // contains the parameters with the event time
77 Double_t fTimeResolution; // global time resolution used to calculate T0
79 Float_t fT0sigma; // T0 resolution
81 TH1F *fHmapChannel; // histo with the channel map
85 ClassDef(AliRsnTOFT0maker, 1); // Calculate the time zero using TOF detector */
89 #endif // ALITOFT0MAKERANA_H