ACTS
Experiment-independent tracking
Loading...
Searching...
No Matches
Acts::Navigator Class Reference

Steers the propagation through the geometry by providing the next surface to be targeted. More...

#include <Acts/Propagator/Navigator.hpp>

Classes

struct  Config
 The navigator configuration. More...
struct  Options
 The navigator options. More...
struct  State
 Nested State struct. More...

Public Types

using ExternalSurfaces = std::vector<GeometryIdentifier>
using GeometryVersion = TrackingGeometry::GeometryVersion
 Type alias for geometry version enumeration.
using NavigationBoundaries
 Type alias for navigation boundary candidates container.
using NavigationCandidates
 Type alias for generic navigation candidates container.
using NavigationLayers = boost::container::small_vector<NavigationTarget, 10>
 Type alias for navigation layer candidates container.
using NavigationSurfaces
 Type alias for navigation surface candidates container.
enum struct  Stage : int { initial = 0 , surfaceTarget = 1 , layerTarget = 2 , boundaryTarget = 3 }
 The navigation stage. More...

Public Member Functions

 Navigator (Config cfg, std::shared_ptr< const Logger > _logger=getDefaultLogger("Navigator", Logging::Level::INFO))
 Constructor with configuration object.
bool checkTargetValid (const State &state, const Vector3 &position, const Vector3 &direction) const
 Check if the current target is still valid.
const SurfacecurrentSurface (const State &state) const
 Get the current surface from navigation state.
const TrackingVolumecurrentVolume (const State &state) const
 Get the current volume from navigation state.
const IVolumeMaterialcurrentVolumeMaterial (const State &state) const
 Get material properties of the current volume.
bool endOfWorldReached (const State &state) const
 Check if navigation has reached the end of the world (no current volume).
void handleSurfaceReached (State &state, const Vector3 &position, const Vector3 &direction, const Surface &surface) const
 Handle the surface reached.
Result< void > initialize (State &state, const Vector3 &position, const Vector3 &direction, Direction propagationDirection) const
 Initialize the navigator state.
State makeState (const Options &options) const
 Create a navigation state from options.
bool navigationBreak (const State &state) const
 Check if navigation should be interrupted.
NavigationTarget nextTarget (State &state, const Vector3 &position, const Vector3 &direction) const
 Get the next target surface.
const SurfacestartSurface (const State &state) const
 Get the starting surface from navigation state.
const SurfacetargetSurface (const State &state) const
 Get the target surface from navigation state.

Detailed Description

Steers the propagation through the geometry by providing the next surface to be targeted.

The Navigator is part of the propagation and responsible for steering the surface sequence to encounter all the relevant surfaces which are intersected by the trajectory.

The current navigation stage is cached in the state struct and updated when necessary. If any surface in the extrapolation flow is hit, it is set to the navigation state, such that other actors can deal with it.

The current target surface is referenced by an index which points into the navigation candidates. The navigation candidates are ordered by the path length to the surface. If a surface is hit, the state.currentSurface pointer is set. This actors to observe that we are on a surface.

Member Typedef Documentation

◆ ExternalSurfaces

◆ GeometryVersion

Type alias for geometry version enumeration.

◆ NavigationBoundaries

Initial value:
boost::container::small_vector<NavigationTarget, 4>

Type alias for navigation boundary candidates container.

◆ NavigationCandidates

Initial value:
boost::container::small_vector<NavigationTarget, 10>

Type alias for generic navigation candidates container.

◆ NavigationLayers

using Acts::Navigator::NavigationLayers = boost::container::small_vector<NavigationTarget, 10>

Type alias for navigation layer candidates container.

◆ NavigationSurfaces

Initial value:
boost::container::small_vector<NavigationTarget, 10>

Type alias for navigation surface candidates container.

Member Enumeration Documentation

◆ Stage

enum struct Acts::Navigator::Stage : int
strong

The navigation stage.

Enumerator
initial 
surfaceTarget 
layerTarget 
boundaryTarget 

Constructor & Destructor Documentation

◆ Navigator()

Acts::Navigator::Navigator ( Config cfg,
std::shared_ptr< const Logger > _logger = getDefaultLogger("Navigator", Logging::Level::INFO) )
explicit

Constructor with configuration object.

Parameters
cfgThe navigator configuration
_loggera logger instance

Member Function Documentation

◆ checkTargetValid()

bool Acts::Navigator::checkTargetValid ( const State & state,
const Vector3 & position,
const Vector3 & direction ) const

Check if the current target is still valid.

This function checks if the target is valid.

Parameters
stateThe navigation state
positionThe current position
directionThe current direction
Returns
True if the target is valid

◆ currentSurface()

const Surface * Acts::Navigator::currentSurface ( const State & state) const

Get the current surface from navigation state.

Parameters
stateThe navigation state
Returns
Pointer to current surface, or nullptr if none

◆ currentVolume()

const TrackingVolume * Acts::Navigator::currentVolume ( const State & state) const

Get the current volume from navigation state.

Parameters
stateThe navigation state
Returns
Pointer to current volume, or nullptr if none

◆ currentVolumeMaterial()

const IVolumeMaterial * Acts::Navigator::currentVolumeMaterial ( const State & state) const

Get material properties of the current volume.

Parameters
stateThe navigation state
Returns
Pointer to volume material, or nullptr if no volume or material

◆ endOfWorldReached()

bool Acts::Navigator::endOfWorldReached ( const State & state) const

Check if navigation has reached the end of the world (no current volume).

Parameters
stateThe navigation state
Returns
True if end of world is reached

◆ handleSurfaceReached()

void Acts::Navigator::handleSurfaceReached ( State & state,
const Vector3 & position,
const Vector3 & direction,
const Surface & surface ) const

Handle the surface reached.

This function handles the surface reached.

Parameters
stateThe navigation state
positionThe current position
directionThe current direction
surfaceThe surface reached

◆ initialize()

Result< void > Acts::Navigator::initialize ( State & state,
const Vector3 & position,
const Vector3 & direction,
Direction propagationDirection ) const
nodiscard

Initialize the navigator state.

This function initializes the navigator state for a new propagation.

Parameters
stateThe navigation state
positionThe start position
directionThe start direction
propagationDirectionThe propagation direction
Returns
Indication if the initialization was successful

◆ makeState()

State Acts::Navigator::makeState ( const Options & options) const

Create a navigation state from options.

Parameters
optionsThe navigation options
Returns
A new navigation state

◆ navigationBreak()

bool Acts::Navigator::navigationBreak ( const State & state) const

Check if navigation should be interrupted.

Parameters
stateThe navigation state
Returns
True if navigation break flag is set

◆ nextTarget()

NavigationTarget Acts::Navigator::nextTarget ( State & state,
const Vector3 & position,
const Vector3 & direction ) const

Get the next target surface.

This function gets the next target surface for the propagation.

Parameters
stateThe navigation state
positionThe current position
directionThe current direction
Returns
The next target surface

◆ startSurface()

const Surface * Acts::Navigator::startSurface ( const State & state) const

Get the starting surface from navigation state.

Parameters
stateThe navigation state
Returns
Pointer to start surface, or nullptr if none

◆ targetSurface()

const Surface * Acts::Navigator::targetSurface ( const State & state) const

Get the target surface from navigation state.

Parameters
stateThe navigation state
Returns
Pointer to target surface, or nullptr if none