Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2024-04-06 12:29:19

0001 #ifndef InvariantMassFromVertex_H
0002 #define InvariantMassFromVertex_H
0003 
0004 // #include "RecoVertex/KinematicFitPrimitives/interface/RefCountedKinematicTree.h"
0005 // #include "RecoVertex/KinematicFitPrimitives/interface/KinematicVertexFactory.h"
0006 // #include "RecoVertex/KinematicFitPrimitives/interface/VirtualKinematicParticleFactory.h"
0007 #include "RecoVertex/VertexPrimitives/interface/CachingVertex.h"
0008 // #include "RecoVertex/KinematicFitPrimitives/interface/KinematicRefittedTrackState.h"
0009 // #include "RecoVertex/KinematicFitPrimitives/interface/Matrices.h"
0010 #include "DataFormats/GeometryCommonDetAlgo/interface/Measurement1D.h"
0011 #include "DataFormats/Math/interface/LorentzVector.h"
0012 #include "Math/Vector4D.h"
0013 #include "DataFormats/CLHEP/interface/AlgebraicObjects.h"
0014 
0015 /**
0016  * Class building  a resulting output
0017  * tree out of the information provided
0018  * by KinematicParticleVertexFitter.
0019  */
0020 class InvariantMassFromVertex {
0021 public:
0022   typedef ROOT::Math::PxPyPzMVector LorentzVector;
0023 
0024   Measurement1D invariantMass(const CachingVertex<5>& vertex, const std::vector<double>& masses) const;
0025 
0026   Measurement1D invariantMass(const CachingVertex<5>& vertex, const double mass) const;
0027 
0028   /**
0029    * four-momentum Lorentz vector
0030    */
0031   LorentzVector p4(const CachingVertex<5>& vertex, const std::vector<double>& masses) const;
0032 
0033   /**
0034    * four-momentum Lorentz vector
0035    */
0036   LorentzVector p4(const CachingVertex<5>& vertex, const double mass) const;
0037 
0038   GlobalVector momentum(const CachingVertex<5>& vertex) const;
0039 
0040 private:
0041   typedef ReferenceCountingPointer<VertexTrack<5> > RefCountedVertexTrack;
0042   typedef ReferenceCountingPointer<LinearizedTrackState<5> > RefCountedLinearizedTrackState;
0043   typedef ReferenceCountingPointer<RefittedTrackState<5> > RefCountedRefittedTrackState;
0044 
0045   double uncertainty(const LorentzVector& p4, const CachingVertex<5>& vertex, const std::vector<double>& masses) const;
0046 };
0047 
0048 #endif