Class Acts::DirectNavigator

class DirectNavigator

DirectNavigator class.

This is a fully guided navigator that progresses through a pre-given sequence of surfaces.

This can either be used as a validation tool, for truth tracking, or track refitting

Public Types

using SurfaceIter = std::vector<const Surface*>::iterator
using SurfaceSequence = std::vector<const Surface*>

The sequentially crossed surfaces.

Public Functions

inline DirectNavigator(std::unique_ptr<const Logger> _logger = getDefaultLogger("DirectNavigator", Logging::INFO))
inline const Surface *currentSurface(const State &state) const
inline void currentSurface(State &state, const Surface *surface) const
inline const TrackingVolume *currentVolume(const State &state) const
inline const IVolumeMaterial *currentVolumeMaterial(const State &state) const
inline State makeState(const Surface *startSurface, const Surface *targetSurface) const
inline bool navigationBreak(const State &state) const
inline void navigationBreak(State &state, bool navigationBreak) const
inline void resetState(State &state, const GeometryContext&, const Vector3&, const Vector3&, NavigationDirection, const Surface *ssurface, const Surface *tsurface) const

Reset state.

Parameters
  • state – is the state to reset

  • ssurface – is the new starting surface

  • tsurface – is the target surface

inline const Surface *startSurface(const State &state) const
template<typename propagator_state_t, typename stepper_t>
inline void status(propagator_state_t &state, const stepper_t &stepper) const

Navigator status call.

Template Parameters
  • propagator_state_t – is the type of Propagatgor state

  • stepper_t – is the used type of the Stepper by the Propagator

Parameters
  • state[inout] is the mutable propagator state object

  • stepper[in] Stepper in use

template<typename propagator_state_t, typename stepper_t>
inline void target(propagator_state_t &state, const stepper_t &stepper) const

Navigator target call.

Template Parameters
  • propagator_state_t – is the type of Propagatgor state

  • stepper_t – is the used type of the Stepper by the Propagator

Parameters
  • state[inout] is the mutable propagator state object

  • stepper[in] Stepper in use

inline bool targetReached(const State &state) const
inline void targetReached(State &state, bool targetReached) const
inline const Surface *targetSurface(const State &state) const

Public Members

double tolerance = s_onSurfaceTolerance

The tolerance used to define “surface reached”.

struct Initializer

Nested Actor struct, called Initializer.

This is needed for the initialization of the surface sequence

Public Types

using result_type = this_result

Public Functions

Initializer() = default

Defaulting the constructor.

template<typename propagator_state_t, typename stepper_t, typename navigator_t>
inline void operator()(propagator_state_t &state, const stepper_t&, const navigator_t&, result_type &r, const Logger&) const

Actor operator call.

Template Parameters
  • statet – Type of the full propagator state

  • stepper_t – Type of the stepper

  • navigator_t – Type of the navigator

Parameters
  • state – the entire propagator state

  • r – the result of this Actor

Public Members

SurfaceSequence navSurfaces = {}

The Surface sequence.

struct this_result

Actor result / state.

Public Members

bool initialized = false
struct State

Nested State struct.

It acts as an internal state which is created for every propagation/extrapolation step and keep thread-local navigation information

Public Members

const Surface *currentSurface = nullptr

Navigation state - external interface: the current surface.

const TrackingVolume *currentVolume = nullptr

Navigation state: the current volume.

bool navigationBreak = false

Navigation state - external interface: a break has been detected.

SurfaceIter navSurfaceIter = navSurfaces.begin()

Iterator the next surface.

SurfaceSequence navSurfaces = {}

Externally provided surfaces - expected to be ordered along the path.

const Layer *startLayer = nullptr

Navigation state - starting layer.

const Surface *startSurface = nullptr

Navigation state - external interface: the start surface.

const TrackingVolume *startVolume = nullptr

Navigation state: the start volume.

const Layer *targetLayer = nullptr

Navigation state - target layer.

bool targetReached = false

Navigation state - external interface: target is reached.

const Surface *targetSurface = nullptr

Navigation state - external interface: the target surface.

const TrackingVolume *targetVolume = nullptr

Navigation state: the target volume.