21 #ifndef yap_FourVector_h
22 #define yap_FourVector_h
31 #include <type_traits>
59 using Vector<T, 4>::operator=;
69 {
return ThreeVector<T>({V[1], V[2], V[3]}); }
74 {
return (V[0] != 0) ? (T(1) / V[0]) *
vect(V) : ThreeVector<T>({0, 0, 0}); }
87 std::vector<FourVector<T> > result;
88 result.reserve(V.size());
100 template <
typename T>
103 std::vector<FourVector<T> > result;
104 result.reserve(V.size());
111 template <
typename T>
116 template <
typename T>
119 std::vector<FourVector<T> > result;
120 result.reserve(V.size());
122 result.push_back(R * v);
130 template <
typename T>
const CoordinateSystem< T, 3 > helicityFrame(const FourVector< T > &V, const CoordinateSystem< T, 3 > &C)
Definition: FourVector.h:131
Four-Vector handling.
Definition: FourVector.h:41
constexpr ThreeVector< T > vect(const FourVector< T > &V) noexcept
Definition: FourVector.h:68
constexpr FourVector(const Vector< T, 4 > &V)
Vector<T, 4> constructor.
Definition: FourVector.h:48
const DataIterator operator-(const DataIterator &lhs, DataIterator::difference_type n)
subraction operator
Definition: DataPartition.h:139
VectorIterator< T, N > end()
access to end
Definition: Vector.h:208
constexpr T operator*(const Vector< T, 4 > &B) const override
Definition: FourVector.h:62
const CoordinateSystem< T, N > operator*(const SquareMatrix< T, N > &M, const CoordinateSystem< T, N > &C)
Definition: CoordinateSystem.h:62
constexpr FourVector(const T &E, const ThreeVector< T > &P) noexcept
Definition: FourVector.h:53
T & front()
access to front
Definition: Vector.h:192
constexpr FourVector(const std::array< T, 4 > &l) noexcept
intializer_list constructor
Definition: FourVector.h:45
VectorIterator< T, N > begin()
access to begin
Definition: Vector.h:200
constexpr ThreeVector< T > boost(const FourVector< T > &V)
Definition: FourVector.h:73
N-dimensional column vector.
Definition: Vector.h:168