CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
InvariantMass.h
Go to the documentation of this file.
1 #ifndef CommonTools_Utils_InvariantMass_h
2 #define CommonTools_Utils_InvariantMass_h
4 
5 template<typename T1, typename T2 = T1>
6 struct InvariantMass {
7  double operator()( const T1 & t1, const T2 & t2 ) const {
8  return ( t1.momentum() + t2.momentum() ).mass();
9  }
10 };
11 
12 #endif
auto const T2 &decltype(t1.eta()) t2
Definition: deltaR.h:16
double operator()(const T1 &t1, const T2 &t2) const
Definition: InvariantMass.h:7