ViewVC Help
View File | Revision Log | Show Annotations | Root Listing
root/cvsroot/UserCode/MitAna/DataTree/interface/Muon.h
(Generate patch)

Comparing UserCode/MitAna/DataTree/interface/Muon.h (file contents):
Revision 1.18 by loizides, Thu Nov 27 16:15:06 2008 UTC vs.
Revision 1.21 by bendavid, Wed Dec 3 16:58:17 2008 UTC

# Line 18 | Line 18
18   namespace mithep {
19    class Muon : public ChargedParticle {
20      public:
21 <      Muon() {}
21 >      Muon();
22        ~Muon() {}
23  
24        enum EClassType {
# Line 56 | Line 56 | namespace mithep {
56        Int_t          NChambers()           const { return fNTraversedChambers;       }
57        Int_t          NSegments()           const { return fStationMask.NBitsSet();   }
58        Bool_t         StationBit(Int_t bit) const { return fStationMask.TestBit(bit); }
59 <      Double_t       GetDX(Int_t iStation)             const;
60 <      Double_t       GetDY(Int_t iStation)             const;
61 <      Double_t       GetPullX(Int_t iStation)          const;
62 <      Double_t       GetPullY(Int_t iStation)          const;
63 <      Double_t       GetTrackDist(Int_t iStation)      const;
64 <      Double_t       GetTrackDistErr(Int_t iStation)   const;
65 <      Int_t          GetNSegments(Int_t iStation)      const;
66 <      Bool_t         Has(EClassType type)              const;
67 <      EClassType     Is()                              const;
68 <      Int_t          LastHit()                         const;
59 >      Double_t       GetDX(Int_t iStation)           const;
60 >      Double_t       GetDY(Int_t iStation)           const;
61 >      Double_t       GetPullX(Int_t iStation)        const;
62 >      Double_t       GetPullY(Int_t iStation)        const;
63 >      Double_t       GetTrackDist(Int_t iStation)    const;
64 >      Double_t       GetTrackDistErr(Int_t iStation) const;
65 >      Int_t          GetNSegments(Int_t iStation)    const;
66 >      Bool_t         HasGlobalTrk()                  const { return fGlobalTrackRef.IsValid(); }
67 >      Bool_t         HasStandaloneTrk()              const { return fStandaloneTrackRef.IsValid(); }
68 >      Bool_t         HasTrackerTrk()                 const { return fTrackerTrackRef.IsValid(); }
69 >      Bool_t         Has(EClassType type)            const;
70 >      EClassType     Is()                            const;
71 >      Int_t          LastHit()                       const;
72        Int_t          LastStation(Double_t iMaxD, Double_t iMaxP)               const;
73        Int_t          LastStation(Int_t iMax=8)                                 const;
74        Bool_t         PromptTight(EClassType type)                              const;
# Line 73 | Line 76 | namespace mithep {
76                                     Double_t iDXMin = 3., Double_t iPXMin = 3.,Int_t iN = 2) const;
77        Bool_t         TMOneStation(Double_t iDYMin = 3., Double_t iPYMin = 3.,
78                                    Double_t iDXMin = 3., Double_t iPXMin = 3.,Int_t iN = 1)  const;
79 <      void           SetGlobalTrk(Track* t)                { fGlobalTrackRef = t;            }
80 <      void           SetStandaloneTrk(Track* t)            { fStandaloneTrackRef = t;        }
81 <      void           SetTrackerTrk(Track* t)               { fTrackerTrackRef = t;           }
79 >      void           SetGlobalTrk(const Track *t)          { fGlobalTrackRef = const_cast<Track*>(t); }
80 >      void           SetStandaloneTrk(const Track *t)      { fStandaloneTrackRef = const_cast<Track*>(t); }
81 >      void           SetTrackerTrk(const Track *t)         { fTrackerTrackRef = const_cast<Track*>(t); }
82        void           SetIsoR03SumPt(Double_t isoR03SumPt)  { fIsoR03SumPt = isoR03SumPt;     }
83        void           SetIsoR03EmEt(Double_t isoR03EmEt)    { fIsoR03EmEt = isoR03EmEt;       }
84        void           SetIsoR03HadEt(Double_t isoR03HadEt)  { fIsoR03HadEt = isoR03HadEt;     }
# Line 152 | Line 155 | inline const mithep::Track *mithep::Muon
155    else if (StandaloneTrk())
156      return StandaloneTrk();
157  
158 +  Error("BestTrk", "No track reference found, returning NULL pointer.");
159    return 0;
160   }
161  
# Line 380 | Line 384 | inline Bool_t mithep::Muon::TMOneStation
384      return kFALSE; //second last one
385  
386    Bool_t pGoodX  = kFALSE;
387 +  Bool_t pBadY   = kFALSE;
388    for (Int_t i0 = 0; i0 < 8; ++i0) {
389      if ((TMath::Abs(GetDX(i0))    < iDXMin  ||
390           TMath::Abs(GetPullX(i0)) < iPXMin))
# Line 388 | Line 393 | inline Bool_t mithep::Muon::TMOneStation
393          (TMath::Abs(GetDY(i0))    < iDYMin  ||
394           TMath::Abs(GetPullY(i0)) < iPYMin))  
395        return kTRUE;
391  Bool_t pBadY   = kFALSE;
396      if (TMath::Abs(GetDY(i0)) < 999999)
397        pBadY = kTRUE;
398      if (i0 == 3 && pGoodX && !pBadY)            

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines