Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2021-02-14 12:54:10

0001 #ifndef MuonReco_MuonTime_h
0002 #define MuonReco_MuonTime_h
0003 
0004 namespace reco {
0005   struct MuonTime {
0006     enum Direction { OutsideIn = -1, Undefined = 0, InsideOut = 1 };
0007 
0008     /// number of muon stations used
0009     int nDof;
0010 
0011     /// time of arrival at the IP for the Beta=1 hypothesis
0012     ///  a) particle is moving from inside out
0013     float timeAtIpInOut;
0014     float timeAtIpInOutErr;
0015     ///  b) particle is moving from outside in
0016     float timeAtIpOutIn;
0017     float timeAtIpOutInErr;
0018 
0019     /// direction estimation based on time dispersion
0020     Direction direction() const {
0021       if (nDof < 2)
0022         return Undefined;
0023       if (timeAtIpInOutErr > timeAtIpOutInErr)
0024         return OutsideIn;
0025       return InsideOut;
0026     }
0027 
0028     MuonTime() : nDof(0), timeAtIpInOut(0), timeAtIpInOutErr(0), timeAtIpOutIn(0), timeAtIpOutInErr(0) {}
0029   };
0030 }  // namespace reco
0031 #endif