ACTS
Experiment-independent tracking
Loading...
Searching...
No Matches
detray::euler_rotation< algebra_t > Struct Template Reference

Helper struct to perform an euler rotation for a given vector All rotation operations are counterclockwise. More...

#include <detray/utils/axis_rotation.hpp>

Public Types

using algebra_type = algebra_t
 Algebra backend used for the rotations.
using scalar_type = dscalar<algebra_t>
 Scalar type used for the Euler angles.
using vector3_type = dvector3D<algebra_t>
 Three-dimensional vector type used for the axes and input.

Public Member Functions

std::pair< vector3_type, vector3_type > operator() () const
vector3_type operator() (const vector3_type &v0) const
 Apply the z-x-z Euler rotations to a vector.

Public Attributes

scalar_type alpha {0.f}
 First rotation angle, about the initial z axis.
scalar_type beta {0.f}
 Second rotation angle, about the rotated x axis.
scalar_type gamma {0.f}
 Third rotation angle, about the twice-rotated z axis.
vector3_type x {1.0f, 0.f, 0.f}
 Following the z-x-z convention.
vector3_type z {0.f, 0.f, 1.f}
 Initial z axis used to construct the rotated frame.

Detailed Description

template<concepts::algebra algebra_t>
struct detray::euler_rotation< algebra_t >

Helper struct to perform an euler rotation for a given vector All rotation operations are counterclockwise.

Member Function Documentation

◆ operator()() [1/2]

template<concepts::algebra algebra_t>
std::pair< vector3_type, vector3_type > detray::euler_rotation< algebra_t >::operator() ( ) const
Returns
Get the new x and z axis

◆ operator()() [2/2]

template<concepts::algebra algebra_t>
vector3_type detray::euler_rotation< algebra_t >::operator() ( const vector3_type & v0) const

Apply the z-x-z Euler rotations to a vector.

Parameters
v0vector to be rotated
Returns
Get the rotated vector