Celeritas 0.6.0-93+develop.7a7d9941
Loading...
Searching...
No Matches
Public Member Functions | List of all members
celeritas::optical::PrimaryGenerator Class Reference

Sample optical photons from user-configurable distributions. More...

#include <PrimaryGenerator.hh>

Public Member Functions

CELER_FUNCTION PrimaryGenerator (PrimaryDistributionData const &data)
 Construct from optical materials and distribution parameters.
 
template<class Generator >
CELER_FUNCTION optical::TrackInitializer operator() (Generator &rng)
 Sample an optical photon from the distributions.
 

Detailed Description

Sample optical photons from user-configurable distributions.

Todo:
Support runtime-configurable distributions instead of hardcoding

Member Function Documentation

◆ operator()()

template<class Generator >
CELER_FUNCTION optical::TrackInitializer celeritas::optical::PrimaryGenerator::operator() ( Generator rng)
inline

Sample an optical photon from the distributions.

Todo:
There are a couple places in the code where we resample the polarization if orthogonality fails: possibly add a helper function to reduce duplication

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