|
Geant4 11.4.0
Toolkit for the simulation of the passage of particles through matter
|
#include <MCGIDI_sampling.hpp>
Public Member Functions | |
| LUPI_HOST_DEVICE | DomainHash () |
| LUPI_HOST_DEVICE | DomainHash (std::size_t a_bins, double a_domainMin, double a_domainMax) |
| LUPI_HOST_DEVICE | DomainHash (DomainHash const &a_domainHash) |
| LUPI_HOST_DEVICE std::size_t | bins () const |
| LUPI_HOST_DEVICE double | domainMin () const |
| LUPI_HOST_DEVICE double | domainMax () const |
| LUPI_HOST_DEVICE double | u_domainMin () const |
| LUPI_HOST_DEVICE double | u_domainMax () const |
| LUPI_HOST_DEVICE double | inverse_du () const |
| LUPI_HOST_DEVICE std::size_t | index (double a_domain) const |
| LUPI_HOST_DEVICE Vector< std::size_t > | map (Vector< double > const &a_domainValues) const |
| LUPI_HOST_DEVICE void | serialize (LUPI::DataBuffer &a_buffer, LUPI::DataBuffer::Mode a_mode) |
| LUPI_HOST void | print (bool a_printValues) const |
This class stores the data needed for logarithmic hash look up of a domain. This is used to find a cross section given a projectile's energy.
Definition at line 24 of file MCGIDI_sampling.hpp.
| LUPI_HOST_DEVICE MCGIDI::DomainHash::DomainHash | ( | ) |
Default constructor used when broadcasting a Protare as needed by MPI or GPUs.
Definition at line 22 of file MCGIDI_domainHash.cc.
Referenced by DomainHash().
| LUPI_HOST_DEVICE MCGIDI::DomainHash::DomainHash | ( | std::size_t | a_bins, |
| double | a_domainMin, | ||
| double | a_domainMax ) |
| a_bins | [in] The number of bins for the hahs function. |
| a_domainMin | [in] The minimum value of the energy domain for the hash function. |
| a_domainMax | [in] The maximum value of the energy domain for the hash function. |
Definition at line 38 of file MCGIDI_domainHash.cc.
| LUPI_HOST_DEVICE MCGIDI::DomainHash::DomainHash | ( | DomainHash const & | a_domainHash | ) |
| a_domainHash | [in] The DomainHash instance to copy. |
Definition at line 52 of file MCGIDI_domainHash.cc.
|
inline |
Returns the value of the m_bins.
Definition at line 39 of file MCGIDI_sampling.hpp.
Referenced by DomainHash(), and print().
|
inline |
Returns the value of the m_domainMax.
Definition at line 41 of file MCGIDI_sampling.hpp.
Referenced by DomainHash().
|
inline |
Returns the value of the m_domainMax.
Definition at line 40 of file MCGIDI_sampling.hpp.
Referenced by DomainHash().
| LUPI_HOST_DEVICE std::size_t MCGIDI::DomainHash::index | ( | double | a_domain | ) | const |
This method returns the hash index given the domain value a_domain. If a_domain is less than m_domainMin, the returned index is 0. If a_domain is greater than m_domainMax, the returned index is m_bins + 1. Otherwise, the returned index is in the range [1, m_bins].
| a_domain | [in] The domain value that the hash index is to be returned for. |
Definition at line 71 of file MCGIDI_domainHash.cc.
Referenced by map().
|
inline |
Returns the value of the m_inverse_du.
Definition at line 44 of file MCGIDI_sampling.hpp.
Referenced by DomainHash().
| LUPI_HOST_DEVICE Vector< std::size_t > MCGIDI::DomainHash::map | ( | Vector< double > const & | a_domainValues | ) | const |
This method returns the hash indices for the requested domain values a_domainValues.
| a_domainValues | [in] The domain values. |
Definition at line 87 of file MCGIDI_domainHash.cc.
Referenced by MCGIDI::HeatedCrossSectionContinuousEnergy::HeatedCrossSectionContinuousEnergy().
| LUPI_HOST void MCGIDI::DomainHash::print | ( | bool | a_printValues | ) | const |
Prints the contents of this.
| a_printValues | [in] If true, the domain values that divide the hash indices are also printed. |
Definition at line 130 of file MCGIDI_domainHash.cc.
| LUPI_HOST_DEVICE void MCGIDI::DomainHash::serialize | ( | LUPI::DataBuffer & | a_buffer, |
| LUPI::DataBuffer::Mode | a_mode ) |
This method serializes this for broadcasting as needed for MPI and GPUs. The method can count the number of required bytes, pack this or unpack this depending on a_mode.
| a_buffer | [in] The buffer to read or write data to depending on a_mode. |
| a_mode | [in] Specifies the action of this method. |
Definition at line 114 of file MCGIDI_domainHash.cc.
|
inline |
Returns the value of the m_u_domainMax.
Definition at line 43 of file MCGIDI_sampling.hpp.
Referenced by DomainHash().
|
inline |
Returns the value of the m_u_domainMin.
Definition at line 42 of file MCGIDI_sampling.hpp.
Referenced by DomainHash().