 |
ATLAS Offline Software
|
Go to the documentation of this file.
4 #ifndef ACTSINTEROPS_UNITCONVERTER_H
5 #define ACTSINTEROPS_UNITCONVERTER_H
9 #include "GaudiKernel/SystemOfUnits.h"
12 #include "Acts/Definitions/Units.hpp"
13 #include "Acts/Definitions/Algebra.hpp"
14 #include "Acts/Definitions/Common.hpp"
22 using namespace Acts::UnitLiterals;
24 return energyCnv * athenaE;
29 using namespace Acts::UnitLiterals;
31 return energyCnv * actsE;
36 using namespace Acts::UnitLiterals;
38 return lengthCnv * athenaL;
43 using namespace Acts::UnitLiterals;
45 return lengthCnv * actsL;
49 inline constexpr
double timeToActs(
const double athenaT) {
50 using namespace Acts::UnitLiterals;
52 return timeCnv * athenaT;
57 using namespace Acts::UnitLiterals;
59 return timeCnv * actsT;
75 const double athenaTime =0.) {
91 return std::make_pair(std::move(
pos),
timeToAthena(actsPos[Acts::eTime]));
98 using namespace Acts::UnitLiterals;
114 return std::make_pair(std::move(threeMom),
energyToAthena(actsMom[Acts::eEnergy]));
constexpr double energyToActs(const double athenaE)
Converts an energy scalar from Athena to Acts units.
Acts::Vector4 convertPosToActs(const Amg::Vector3D &athenaPos, const double athenaTime=0.)
Converts a position vector & time from Athena units into Acts units.
constexpr double timeToAthena(const double actsT)
Converts a time unit from Acts to Athena units.
constexpr double energyToAthena(const double actsE)
Converts an energy scalar from Acts to Athena units.
constexpr double timeToActs(const double athenaT)
Converts a time unit from Athena to Acts units.
constexpr double lengthToAthena(const double actsL)
Converts a length scalar from Acts to Athena units.
Acts::Vector4 convertMomToActs(const Amg::Vector3D &threeMom, const double mass=0.)
Converts a three momentum vector from Athena together with the associated particle mass into an Acts ...
std::pair< Amg::Vector3D, double > convertPosFromActs(const Acts::Vector4 &actsPos)
Converts an Acts 4-vector into a pair of an Athena spatial vector and the passed time.
Amg::Vector3D convertDirFromActs(const Acts::Vector3 &actsDir)
Converts a direction vector from acts units into athena units.
std::pair< Amg::Vector3D, double > convertMomFromActs(const Acts::Vector4 &actsMom)
Converts an Acts four-momentum vector into an pair of an Athena three-momentum and the paritcle's ene...
Acts::Vector3 convertDirToActs(const Amg::Vector3D &athenaDir)
Converts a direction vector from athena units into acts units.
Eigen::Matrix< double, 3, 1 > Vector3D
constexpr double lengthToActs(const double athenaL)
Converts a length scalar from Acts to Athena units.
The AlignStoreProviderAlg loads the rigid alignment corrections and pipes them through the readout ge...