CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
VectorUtil.h
Go to the documentation of this file.
1 #ifndef GeometryVector_Geom_Util_h
2 #define GeometryVector_Geom_Util_h
3 
4 
5 
8 #include <cmath>
9 
10 
11 namespace Geom {
12  using reco::deltaPhi;
13  using reco::deltaR2;
14  using reco::deltaR;
15 
16 
17 
23  inline bool phiLess(float phi1, float phi2) {
24  return deltaPhi(phi1,phi2)<0;
25  }
26  inline bool phiLess(double phi1, double phi2) {
27  return deltaPhi(phi1,phi2)<0;
28  }
29  template <class Vector1, class Vector2>
30  bool phiLess(const Vector1 & v1, const Vector2 & v2) {
31  return deltaPhi(v1.phi(),v2.phi())<0.;
32  }
33 
34 
35 }
36 
37 #endif
double deltaR(const T1 &t1, const T2 &t2)
Definition: deltaR.h:48
double deltaR2(const T1 &t1, const T2 &t2)
Definition: deltaR.h:36
bool phiLess(float phi1, float phi2)
Definition: VectorUtil.h:23
double deltaPhi(double phi1, double phi2)
Definition: deltaPhi.h:12