Celeritas 0.7.0-dev.245+develop.a7be925e
Loading...
Searching...
No Matches
Classes | Public Member Functions | List of all members
celeritas::optical::SimTrackView Class Reference

Simulation properties for a single track. More...

#include <SimTrackView.hh>

Classes

struct  Initializer
 Data for initializing the simulation state. More...
 

Public Member Functions

 SimTrackView (NativeCRef< SimParamsData > const &params, NativeRef< SimStateData > const &, TrackSlotId)
 Construct from local data.
 
SimTrackViewoperator= (Initializer const &)
 Initialize the simulation state.
 
void status (TrackStatus)
 Set whether the track is active, dying, or inactive.
 
void add_time (real_type delta)
 Add the time change over the step.
 
void increment_num_steps ()
 Increment the total number of steps.
 
void reset_step_limit ()
 Reset step limiter at the beginning of a step.
 
void reset_step_limit (StepLimit const &sl)
 Reset step limiter at the beginning of a step.
 
bool step_limit (StepLimit const &sl)
 Limit the step by this distance and action.
 
void step_length (real_type length)
 Update the current limiting step.
 
void post_step_action (ActionId action)
 Force the limiting action to take.
 
size_type num_steps () const
 Total number of steps taken by the track.
 
real_type time () const
 Time elapsed in the lab frame since the start of the event [s].
 
TrackStatus status () const
 Whether the track is inactive, alive, or being killed.
 
real_type step_length () const
 Get the current limiting step.
 
ActionId post_step_action () const
 Access post-step action to take.
 
size_type max_steps () const
 Maximum number of steps before killing the track.
 

Detailed Description

Simulation properties for a single track.

Member Function Documentation

◆ post_step_action()

void celeritas::optical::SimTrackView::post_step_action ( ActionId  action)
inline

Force the limiting action to take.

This is used by intermediate kernels (such as discrete_select_track ) that dispatch to another kernel action before the end of the step without changing the step itself.

◆ reset_step_limit()

void celeritas::optical::SimTrackView::reset_step_limit ( StepLimit const sl)
inline

Reset step limiter at the beginning of a step.

The action can be unset if and only if the step is infinite.

◆ step_limit()

bool celeritas::optical::SimTrackView::step_limit ( StepLimit const sl)
inline

Limit the step by this distance and action.

If the step limits are the same, the original action is retained.

Returns
Whether the given limit is the new limit.

The documentation for this class was generated from the following file: