openPMD_raytrace_API
0.1.0
|
Generic ray, containing all the ray information being stored by the API into the openPMD file. More...
#include <ray.hh>
Inherited by raytracing::mcstas_neutron.
Public Member Functions | |
Get position | |
float | x () const |
float | y () const |
float | z () const |
void | get_position (float *xx, float *yy, float *zz) const |
void | get_position (double *xx, double *yy, double *zz) const |
void | get_position (float &xx, float &yy, float &zz) const |
Get direction | |
float | dx () const |
float | dy () const |
float | dz () const |
void | get_direction (float *x, float *y, float *z, double scale) const |
void | get_direction (double *x, double *y, double *z, double scale) const |
Get polarization for non-photons | |
float | sx () const |
float | sy () const |
float | sz () const |
void | get_polarization (float *x, float *y, float *z) const |
void | get_polarization (double *x, double *y, double *z) const |
Get s-polarization amplituded and phase for photons | |
float | sPolAx () const |
float | sPolAy () const |
float | sPolAz () const |
float | sPolPh () const |
void | get_sPolarizationAmplitude (float *x, float *y, float *z) const |
void | get_sPolarization (float *x, float *y, float *z, float *phase) const |
Get p-polarization amplitude and phase for photons | |
float | pPolAx () const |
float | pPolAy () const |
float | pPolAz () const |
float | pPolPh () const |
void | get_pPolarizationAmplitude (float *x, float *y, float *z) const |
void | get_pPolarization (float *x, float *y, float *z, float *phase) const |
Get wavelength, ray time, weight, id and status | |
Allowed status values are raytracing::kAlive and raytracing::kDead | |
float | get_wavelength () const |
float | get_time () const |
float | get_weight () const |
unsigned long long int | get_id (void) const |
particleStatus_t | get_status (void) const |
return the particle status More... | |
Setters | |
void | set_position (double x, double y, double z, double scale=1) |
scale and set the position | |
void | set_direction (double x, double y, double z, double scale=1) |
scale and set the direction | |
void | set_velocity (double x, double y, double z) |
scale and set the direction from the velocity | |
void | set_polarization (double x, double y, double z, double scale=1) |
scale and set polarization for non-photons More... | |
void | set_sPolarization (double x, double y, double z, double phase, double scale=1) |
scale and set s-polarization for photons | |
void | set_pPolarization (double x, double y, double z, double phase, double scale=1) |
scale and set p-polarization for photons More... | |
void | set_wavelength (double w) |
set wavelength | |
void | set_time (double t) |
set time | |
void | set_weight (double w) |
set weight | |
void | set_id (unsigned long long int idv) |
void | set_status (particleStatus_t s) |
Generic ray, containing all the ray information being stored by the API into the openPMD file.
This is base class provides several methods to set and manipulate the ray information in the appropriate way.
Other specific ray classes should inherit from this in order to provide more convenient methods for the user. Derived classes can be created from this and used by the users in their programs.
Unit conversions should be applied here, so that the Rays class stores information in a coherent way. There is a small inefficiency if rays are used multiple times, but the time spent in unit conversions is anyway negligible w.r.t. the simulation time.
|
inline |
|
inline |
return the particle status
|
inline |
|
inline |