Celeritas
0.5.0-86+4a8eea4
|
The result of a discrete optical interaction. More...
#include <Interaction.hh>
Public Types | |
enum class | Action { scattered , absorbed , unchanged , failed } |
Interaction result category. More... | |
Public Member Functions | |
CELER_FUNCTION bool | changed () const |
Whether the state changed but did not fail. | |
Static Public Member Functions | |
static CELER_FUNCTION Interaction | from_absorption () |
Return an interaction respresenting an absorbed process. More... | |
static CELER_FUNCTION Interaction | from_unchanged () |
Return an interaction with no change in the track state. More... | |
static CELER_FUNCTION Interaction | from_failure () |
Indicate a failure to allocate memory for secondaries. | |
Public Attributes | |
Real3 | direction |
Post-interaction direction. | |
Real3 | polarization |
Post-interaction polarization. | |
Span< TrackInitializer > | secondaries |
Emitted secondaries. | |
Action | action {Action::scattered} |
Flags for interaction result. | |
The result of a discrete optical interaction.
All optical interactions are discrete. The wavelength of a photon is only changed through absorption re-emission processes.
|
strong |
Interaction result category.
Enumerator | |
---|---|
scattered | Still alive, state has changed. |
absorbed | Absorbed by the material. |
unchanged | No state change, no secondaries. |
failed | Ran out of memory during sampling. |
|
inlinestatic |
Return an interaction respresenting an absorbed process.
Construct an interaction for an absorbed optical photon.
|
inlinestatic |
Return an interaction with no change in the track state.
Construct an interaction for edge cases where this is no state change.