An open source method of characteristics neutron transport code.
MaxOpticalLength Class Reference

A class used to calculate the maximum optical path length across all segments in the Geometry. More...

#include <TrackTraversingAlgorithms.h>

Public Member Functions

 MaxOpticalLength (TrackGenerator *track_generator)
 Constructor for MaxOpticalLength calls the TraverseSegments constructor and sets the max optical path length to zero. More...
 
void execute ()
 Determines the maximum optical path length for the TrackGenerator provided during construction. More...
 
void onTrack (Track *track, segment *segments)
 Calculates the optical path length for the provided segments and updates the maximum optical path length if necessary. More...
 

Additional Inherited Members

- Protected Member Functions inherited from TraverseSegments
 TraverseSegments (TrackGenerator *track_generator)
 Constructor for the TraverseSegments class assigns the TrackGenerator and pulls relevant information from it.
 
virtual ~TraverseSegments ()
 Destructor for TraverseSegments.
 
void loopOverTracks (MOCKernel *kernel)
 Loops over Tracks, applying the provided kernel to all segments and the functionality described in onTrack(...) to all Tracks. More...
 
void loopOverTracksByStackTwoWay (TransportKernel *kernel)
 Loops over all 3D Tracks using axial on-the-fly ray tracking by z-stack, going forward then backward on each 3D Track. More...
 
template<class KernelType >
MOCKernelgetKernel ()
 
- Protected Attributes inherited from TraverseSegments
TrackGenerator_track_generator
 
TrackGenerator3D_track_generator_3D
 
double * _global_z_mesh
 
int _mesh_size
 
segmentationType _segment_formation
 

Detailed Description

A class used to calculate the maximum optical path length across all segments in the Geometry.

"src/TrackTraversingAlgorithms.h"

A MaxOpticalLength allocates SegmentationKernels to temporarily store segment data. The segments are then traversed afterwards and the maximum optical path length is calculated.

Constructor & Destructor Documentation

◆ MaxOpticalLength()

MaxOpticalLength::MaxOpticalLength ( TrackGenerator track_generator)

Constructor for MaxOpticalLength calls the TraverseSegments constructor and sets the max optical path length to zero.

Parameters
track_generatorThe TrackGenerator to pull tracking information from

Member Function Documentation

◆ execute()

void MaxOpticalLength::execute ( )
virtual

Determines the maximum optical path length for the TrackGenerator provided during construction.

The maximum optical path length is initialized to infinity for segmentation within the TrackGenerator and then SegmentationKernels are allocated to store temporary segmnents. Tracks are traversed and onTrack(...) is applied, calculating a maximum optical length and setting it on the TrackGenerator.

Implements TraverseSegments.

◆ onTrack()

void MaxOpticalLength::onTrack ( Track track,
segment segments 
)
virtual

Calculates the optical path length for the provided segments and updates the maximum optical path length if necessary.

Parameters
trackThe track associated with the segments
segmentsThe segments for which the optical path length is calculated

Implements TraverseSegments.


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