10 #ifndef SRC_INCLUDE_ENERGYMOMENTUMTENSOR_H_    11 #define SRC_INCLUDE_ENERGYMOMENTUMTENSOR_H_    41     for (
size_t i = 0; i < 10; i++) {
    54   static std::int8_t 
tmn_index(std::int8_t mu, std::int8_t nu) {
    56     constexpr std::array<std::int8_t, 16> indices = {0, 1, 2, 3,
    61     if (mu < 4 && nu < 4 && mu >= 0 && nu >= 0) {
    62       return indices[mu + 4 * nu];
    64       throw std::invalid_argument(
"Invalid indices: " + std::to_string(mu) +
    65                                   ", " + std::to_string(nu));
   156   for (
size_t i = 0; i < 10; i++) {
   170   for (
size_t i = 0; i < 10; i++) {
   183   for (
size_t i = 0; i < 10; i++) {
   200   for (
size_t i = 0; i < 10; i++) {
   213 #endif  // SRC_INCLUDE_ENERGYMOMENTUMTENSOR_H_ const_iterator begin() const 
Const overload of the above. 
 
std::array< double, 10 > tmn_type
The energy-momentum tensor is symmetric and has 10 independent components. 
 
The ThreeVector class represents a physical three-vector  with the components . 
 
EnergyMomentumTensor operator/(EnergyMomentumTensor a, const double b)
Direct division operator. 
 
tmn_type::const_iterator const_iterator
Constant iterator over the components. 
 
static std::int8_t tmn_index(std::int8_t mu, std::int8_t nu)
Access the index of component . 
 
void add_particle_for_derivatives(const ParticleData &, double, ThreeVector)
Dummy function need for update_general_lattice. 
 
EnergyMomentumTensor operator+(EnergyMomentumTensor a, const EnergyMomentumTensor &b)
Direct addition operator. 
 
EnergyMomentumTensor()
Default constructor (nulls all components) 
 
EnergyMomentumTensor operator-=(const EnergyMomentumTensor &Tmn0)
Subtraction of  of tensor. 
 
EnergyMomentumTensor operator-(EnergyMomentumTensor a, const EnergyMomentumTensor &b)
Direct subtraction operator. 
 
EnergyMomentumTensor(const tmn_type &Tmn)
Copy constructor. 
 
iterator begin()
Returns an iterator starting at the (0,0) component. 
 
EnergyMomentumTensor boosted(const FourVector &u) const 
Boost to a given 4-velocity. 
 
iterator end()
Returns an iterator pointing after the (3,3)th component. 
 
tmn_type::iterator iterator
Iterator over the components. 
 
EnergyMomentumTensor operator+=(const EnergyMomentumTensor &Tmn0)
Addition of  to tensor. 
 
EnergyMomentumTensor operator/=(double a)
Division of the tensor by scalar . 
 
const_iterator cbegin() const 
 
FourVector landau_frame_4velocity() const 
Find the Landau frame 4-velocity from energy-momentum tensor. 
 
EnergyMomentumTensor operator*(EnergyMomentumTensor a, const double b)
Direct multiplication operator. 
 
The EnergyMomentumTensor class represents a symmetric positive semi-definite energy-momentum tensor ...
 
void add_particle(const FourVector &mom)
Given momentum of the particle adds  to the energy momentum tensor. 
 
const_iterator cend() const 
 
tmn_type Tmn_
The internal storage of the components. 
 
const_iterator end() const 
Const overload of the above. 
 
std::ostream & operator<<(std::ostream &out, const ActionPtr &action)
Convenience: dereferences the ActionPtr to Action. 
 
The FourVector class holds relevant values in Minkowski spacetime with (+, −, −, −) metric signature. 
 
ParticleData contains the dynamic information of a certain particle. 
 
EnergyMomentumTensor operator*=(double a)
Scaling of the tensor by scalar . 
 
double operator[](std::size_t i) const 
Return ith component of the tensor.