ViewVC Help
View File | Revision Log | Show Annotations | Root Listing
root/cvsroot/UserCode/MitPhysics/Utils/src/MuonTools.cc
(Generate patch)

Comparing UserCode/MitPhysics/Utils/src/MuonTools.cc (file contents):
Revision 1.5 by loizides, Thu Nov 27 16:28:58 2008 UTC vs.
Revision 1.9 by loizides, Tue Apr 7 15:37:10 2009 UTC

# Line 91 | Line 91 | void MuonTools::DeleteHistos()
91   Double_t MuonTools::GetCaloCompatability(const Muon *iMuon,
92                                           Bool_t iEMSpecial, Bool_t iCorrectedHCAL) const
93   {
94 <  // todo
94 >  // Get calo compatibility value for given muon based on calorimeter templates.
95 >  // If iEMSpecial is true, then a use different arrangement of ECAL for compatibility.
96  
97    Double_t lEta = iMuon->Eta();
98    Double_t aEta = TMath::Abs(lEta);
# Line 144 | Line 145 | Double_t MuonTools::GetCaloCompatability
145  
146    if (aEta < 1.1) {
147      if(iCorrectedHCAL)    
148 <      lHad *= TMath::Sin(2*TMath::ATan(TMath::Exp(lEta))); //todo ask!
148 >      lHad *= TMath::Sin(2*TMath::ATan(TMath::Exp(lEta)));
149      lTPionHad  = fpion_had_etaB;
150      lTMuonHad  = fmuon_had_etaB;
151    }
# Line 276 | Line 277 | Bool_t MuonTools::IsGood(const mithep::M
277        return iMuon->PromptTight(Muon::kAny);
278        break;
279      case kTMOneStationLoose:
280 <      return iMuon->TMOneStation(99999,999999);
280 >      return iMuon->TMOneStation(999999,999999);
281        break;
282      case kTMOneStationTight:
283        return iMuon->TMOneStation();
# Line 298 | Line 299 | Bool_t MuonTools::IsGood(const mithep::M
299        break;
300    }
301  
302 <  Double_t lVal = 1.2*GetSegmentCompatability(iMuon);
303 <  if (lVal/1.2 == 0.5)
302 >  Double_t lVal = GetSegmentCompatability(iMuon);
303 >  if (lVal == 0.5) // exclude this border case
304      return kFALSE;
305  
306 +  lVal *= 1.2;
307    lVal += 0.8*GetCaloCompatability(iMuon,kTRUE,kTRUE);
308    if (lVal > tm2dcut)
309      return kTRUE;
310 +
311    return kFALSE;
312   }
313  
314   //--------------------------------------------------------------------------------------------------
315   Double_t MuonTools::GetSegmentCompatability(const mithep::Muon *iMuon) const
316   {
317 <  // todo phil
317 >  // Get segment compatability for given muon based on likelihood of well defined
318 >  // track through chambers.
319  
320    Int_t lNStationsCrossed = 0;
321    Int_t lNStationsSegment = 0;
# Line 332 | Line 336 | Double_t MuonTools::GetSegmentCompatabil
336      } else
337        lStCrossed[i0]  = 0;
338  
339 <    if(iMuon->GetDX(i0) < 999999.) { //Use iMuon->GetSegmentX--> CHECK
339 >    if(iMuon->GetDX(i0) < 999999.) {
340        lNStationsSegment++;
341        lStSegmentmatch[i0] = 1;
342      } else

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines