CMS 3D CMS Logo

TrackingParticleIP.h
Go to the documentation of this file.
1 #ifndef SimTracker_TrackAssociation_TrackingParticleIP
2 #define SimTracker_TrackAssociation_TrackingParticleIP
3 
4 // This file is in this package only because ParametersDefinerForTP is
5 
6 #include <cmath>
7 
8 namespace TrackingParticleIP {
9  // As in TrackBase::dxy(Point) and dz(Point)
10  template <typename T_Vertex, typename T_Momentum, typename T_Point>
11  inline auto dxy(const T_Vertex& vertex, const T_Momentum& momentum, const T_Point& point) {
12  return -(vertex.x()-point.x())*std::sin(momentum.phi()) + (vertex.y()-point.y())*std::cos(momentum.phi());
13 
14  }
15 
16  template <typename T_Vertex, typename T_Momentum, typename T_Point>
17  inline auto dz(const T_Vertex& vertex, const T_Momentum& momentum, const T_Point& point) {
18  return vertex.z()-point.z() - ( (vertex.x()-point.x())*momentum.x() +
19  (vertex.y()-point.y())*momentum.y() ) * momentum.z()/momentum.perp2();
20  }
21 }
22 
23 #endif
Sin< T >::type sin(const T &t)
Definition: Sin.h:22
auto dz(const T_Vertex &vertex, const T_Momentum &momentum, const T_Point &point)
Cos< T >::type cos(const T &t)
Definition: Cos.h:22
auto dxy(const T_Vertex &vertex, const T_Momentum &momentum, const T_Point &point)
*vegas h *****************************************************used in the default bin number in original ***version of VEGAS is ***a higher bin number might help to derive a more precise ***grade subtle point
Definition: invegas.h:5