Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2024-04-06 12:04:47

0001 #ifndef MuonReco_MuonSimInfo_h
0002 #define MuonReco_MuonSimInfo_h
0003 
0004 #include "DataFormats/Math/interface/Point3D.h"
0005 #include "DataFormats/Math/interface/LorentzVector.h"
0006 
0007 namespace reco {
0008   /*
0009 
0010 
0011  CLASSIFICATION: For each RECO Muon, match to SIM particle, and then:
0012   - If the SIM is not a Muon, label as Punchthrough (1) except if it is an electron or positron (11)
0013   - If the SIM is a Muon, then look at it's provenance.
0014      A) the SIM muon is also a GEN muon, whose parent is NOT A HADRON AND NOT A TAU
0015         -> classify as "primary" (4).
0016      B) the SIM muon is also a GEN muon, whose parent is HEAVY FLAVOURED HADRON OR A TAU
0017         -> classify as "heavy flavour" (3)
0018      C) classify as "light flavour/decay" (2)
0019 
0020   In any case, if the TP is not preferentially matched back to the same RECO muon,
0021   label as Ghost (flip the classification)
0022 
0023 
0024  FLAVOUR:
0025   - for non-muons: 0
0026   - for primary muons: 13
0027   - for non primary muons: flavour of the mother: std::abs(pdgId) of heaviest quark, or 15 for tau
0028 
0029 */
0030 
0031   enum MuonSimType {
0032     Unknown = 999,
0033     NotMatched = 0,
0034     MatchedPunchthrough = 1,
0035     MatchedElectron = 11,
0036     MatchedPrimaryMuon = 4,
0037     MatchedMuonFromHeavyFlavour = 3,
0038     MatchedMuonFromLightFlavour = 2,
0039     GhostPunchthrough = -1,
0040     GhostElectron = -11,
0041     GhostPrimaryMuon = -4,
0042     GhostMuonFromHeavyFlavour = -3,
0043     GhostMuonFromLightFlavour = -2
0044   };
0045 
0046   enum ExtendedMuonSimType {
0047     ExtUnknown = 999,
0048     ExtNotMatched = 0,
0049     ExtMatchedPunchthrough = 1,
0050     ExtMatchedElectron = 11,
0051     MatchedMuonFromGaugeOrHiggsBoson = 10,
0052     MatchedMuonFromTau = 9,
0053     MatchedMuonFromB = 8,
0054     MatchedMuonFromBtoC = 7,
0055     MatchedMuonFromC = 6,
0056     MatchedMuonFromOtherLight = 5,
0057     MatchedMuonFromPiKppMuX = 4,
0058     MatchedMuonFromPiKNotppMuX = 3,
0059     MatchedMuonFromNonPrimaryParticle = 2,
0060     ExtGhostPunchthrough = -1,
0061     ExtGhostElectron = -11,
0062     GhostMuonFromGaugeOrHiggsBoson = -10,
0063     GhostMuonFromTau = -9,
0064     GhostMuonFromB = -8,
0065     GhostMuonFromBtoC = -7,
0066     GhostMuonFromC = -6,
0067     GhostMuonFromOtherLight = -5,
0068     GhostMuonFromPiKppMuX = -4,
0069     GhostMuonFromPiKNotppMuX = -3,
0070     GhostMuonFromNonPrimaryParticle = -2
0071 
0072   };
0073 
0074   class MuonSimInfo {
0075   public:
0076     MuonSimInfo();
0077     typedef math::XYZPointD Point;                   ///< point in the space
0078     typedef math::XYZTLorentzVectorD LorentzVector;  ///< Lorentz vector
0079     MuonSimType primaryClass;
0080     ExtendedMuonSimType extendedClass;
0081     int flavour;
0082     int pdgId;          // pdg ID of matching tracking particle
0083     int g4processType;  // Geant process producing the particle
0084     int motherPdgId;
0085     int motherFlavour;
0086     int motherStatus;  // Status of the first gen particle
0087     int grandMotherPdgId;
0088     int grandMotherFlavour;
0089     int heaviestMotherFlavour;
0090     int tpId;
0091     int tpEvent;
0092     int tpBX;  // bunch crossing
0093     int charge;
0094     LorentzVector p4;
0095     Point vertex;
0096     Point motherVertex;
0097     float tpAssoQuality;
0098   };
0099 }  // namespace reco
0100 
0101 #endif