5 #ifndef _FOURMOMENTUM_HPP_ 6 #define _FOURMOMENTUM_HPP_ 16 #include <boost/property_tree/ptree.hpp> 36 throw std::runtime_error(
37 "FourMomentum::Fourmomentum() | Size of vector not equal 4!");
38 return std::array<double, 4>{{P4_[0], P4_[1], P4_[2], P4_[3]}};
41 double px()
const {
return P4[0]; }
42 double py()
const {
return P4[1]; }
43 double pz()
const {
return P4[2]; }
44 double e()
const {
return P4[3]; }
53 std::transform(
P4.begin(),
P4.end(), pB.
P4.begin(),
P4.begin(),
61 stream <<
"(" << p4.
px() <<
"," << p4.
py() <<
"," << p4.
e() <<
")";
77 std::array<double, 4>
P4;
ComPWA four momentum class.
double threeMomentumSquared() const
double invariantMass() const
friend std::ostream & operator<<(std::ostream &stream, const FourMomentum &p4)
std::array< double, 4 > P4
bool operator==(const FourMomentum &pB) const
FourMomentum(std::vector< double > P4_)
FourMomentum(double Px, double Py, double Pz, double E)
FourMomentum(std::array< double, 4 > P4_)
double invariantMassSquared() const
void operator+=(const FourMomentum &pB)
FourMomentum operator+(const FourMomentum &pB) const