16 #ifdef ACTS_COORDINATE_TRANSFORM_PLUGIN
18 #include ACTS_COORDINATE_TRANSFORM_PLUGIN
28 struct coordinate_transformation {
44 const ParVector_t& pars,
46 ActsVectorD<3> globalPosition;
49 parameters2globalMomentum(pars), globalPosition);
50 return globalPosition;
62 static ActsVectorD<3> parameters2globalMomentum(
const ParVector_t& pars) {
67 momentum << p * sin(theta) * cos(phi), p * sin(theta) * sin(phi),
84 static ParVector_t global2curvilinear(
const ActsVectorD<3>& ,
85 const ActsVectorD<3>&
mom,
90 parameters << 0, 0,
phi(mom),
theta(mom),
111 const ActsVectorD<3>&
pos,
112 const ActsVectorD<3>& mom,
double charge,
113 double time,
const Surface& s) {
116 ActsVectorD<2> localPosition;
117 s.globalToLocal(gctx, pos, mom, localPosition);
119 result << localPosition(0), localPosition(1),
phi(mom),
theta(mom),
120 ((
std::abs(charge) < 1
e-4) ? 1. : charge) / mom.norm(),
time;
127 static double parameters2charge(
const ParVector_t& pars) {
135 #endif // ACTS_COORDINATE_TRANSFORM_PLUGIN