From: mhorner Date: Fri, 25 Jun 2004 17:33:25 +0000 (+0000) Subject: Implemented 30ns time cut X-Git-Url: http://git.uio.no/git/?p=u%2Fmrichter%2FAliRoot.git;a=commitdiff_plain;h=9b3585065e4203ebcaa72786c94120a911657b45 Implemented 30ns time cut --- diff --git a/EMCAL/AliEMCALv1.cxx b/EMCAL/AliEMCALv1.cxx index 241705531b3..739cd6e5af4 100644 --- a/EMCAL/AliEMCALv1.cxx +++ b/EMCAL/AliEMCALv1.cxx @@ -61,6 +61,7 @@ AliEMCALv1::AliEMCALv1(const char *name, const char *title): fNhits = 0; fIshunt = 2; // All hits are associated with particles entering the calorimeter + fTimeCut = 30e-09; } //______________________________________________________________________ @@ -125,7 +126,7 @@ void AliEMCALv1::StepManager(void){ if(gMC->CurrentVolID(copy) == gMC->VolId("XPHI") ) { // We are in a Scintillator Layer Float_t depositedEnergy ; - if( (depositedEnergy = gMC->Edep()) > 0.){// Track is inside a scintillator and deposits some energy + if( ((depositedEnergy = gMC->Edep()) > 0.) && (gMC->TrackTime() < fTimeCut)){// Track is inside a scintillator and deposits some energy if (fCurPrimary==-1) fCurPrimary=gAlice->GetMCApp()->GetPrimary(tracknumber); diff --git a/EMCAL/AliEMCALv1.h b/EMCAL/AliEMCALv1.h index bd34611f253..18d28f19374 100644 --- a/EMCAL/AliEMCALv1.h +++ b/EMCAL/AliEMCALv1.h @@ -39,6 +39,8 @@ public: virtual void RemapTrackHitIDs(Int_t *map); virtual void FinishPrimary(); virtual const TString Version(void)const {return TString("v0");} + virtual void SetTimeCut(Float_t tc){ fTimeCut = tc;} + virtual Float_t GetTimeCut(){return fTimeCut;} // assignement operator requested by coding convention but not needed AliEMCALv1 & operator = (const AliEMCALv0 & /*rvalue*/){ Fatal("operator =", "not implemented") ; @@ -49,8 +51,9 @@ private: Int_t fCurPrimary; Int_t fCurParent; Int_t fCurTrack; + Float_t fTimeCut; // Cut to remove the background from the ALICE system - ClassDef(AliEMCALv1,7)//Implementation of EMCAL manager class to produce hits in a Central Calorimeter + ClassDef(AliEMCALv1,8)//Implementation of EMCAL manager class to produce hits in a Central Calorimeter };