1 #ifndef DataFormats_Math_deltaPhi_h 2 #define DataFormats_Math_deltaPhi_h 19 constexpr
T o2pi = 1. / (2. *
M_PI);
22 T n = std::round(
x * o2pi);
28 constexpr
double deltaPhi(
float phi1,
double phi2) {
return deltaPhi(static_cast<double>(phi1), phi2); }
30 constexpr
double deltaPhi(
double phi1,
float phi2) {
return deltaPhi(phi1, static_cast<double>(phi2)); }
34 template <
typename T1,
typename T2>
48 template <
typename T1,
typename T2 = T1>
66 template <
class valType>
69 constexpr valType oneOverTwoPi = 1. / (2. *
M_PI);
70 constexpr valType
epsilon = 1.e-13;
constexpr double deltaPhi(double phi1, double phi2)
constexpr auto operator()(const T1 &t1, const T2 &t2) -> decltype(reco::deltaPhi(t1, t2)) const
constexpr T reduceRange(T x)
Abs< T >::type abs(const T &t)
constexpr valType make0To2pi(valType angle)
T angle(T x1, T y1, T z1, T x2, T y2, T z2)