Geant4 11.4.0
Toolkit for the simulation of the passage of particles through matter
Loading...
Searching...
No Matches
MCGIDI::Probabilities::GeneralEvaporation2d Class Reference

#include <MCGIDI_functions.hpp>

Inheritance diagram for MCGIDI::Probabilities::GeneralEvaporation2d:

Public Member Functions

LUPI_HOST_DEVICE GeneralEvaporation2d ()
LUPI_HOST GeneralEvaporation2d (GIDI::Functions::GeneralEvaporation2d const &a_generalEvaporation2d)
LUPI_HOST_DEVICE ~GeneralEvaporation2d ()
LUPI_HOST_DEVICE double evaluate (double a_x2, double a_x1) const
template<typename RNG>
LUPI_HOST_DEVICE double sample (double a_x2, double a_rngValue, RNG &&a_rng) const
LUPI_HOST_DEVICE void serialize (LUPI::DataBuffer &a_buffer, LUPI::DataBuffer::Mode a_mode)
Public Member Functions inherited from MCGIDI::Probabilities::ProbabilityBase2d_d2
LUPI_HOST_DEVICE ProbabilityBase2d_d2 ()
LUPI_HOST ProbabilityBase2d_d2 (GIDI::Functions::FunctionForm const &a_probabilty)
LUPI_HOST ProbabilityBase2d_d2 (GIDI::Functions::FunctionForm const &a_probabilty, Vector< double > const &a_Xs)
LUPI_HOST_DEVICE double evaluate (double a_x2, double a_x1) const
template<typename RNG>
LUPI_HOST_DEVICE double sample (double a_x2, double a_rngValue, RNG &&a_rng) const
template<typename RNG>
LUPI_HOST_DEVICE double sample2dOf3d (double a_x2, double a_rngValue, RNG &&a_rng, double *a_x1_1, double *a_x1_2) const
Public Member Functions inherited from MCGIDI::Probabilities::ProbabilityBase2d_d1
LUPI_HOST_DEVICE ProbabilityBase2d_d1 ()
LUPI_HOST ProbabilityBase2d_d1 (GIDI::Functions::FunctionForm const &a_probabilty)
LUPI_HOST ProbabilityBase2d_d1 (GIDI::Functions::FunctionForm const &a_probabilty, Vector< double > const &a_Xs)
LUPI_HOST_DEVICE double evaluate (double a_x2, double a_x1) const
template<typename RNG>
LUPI_HOST_DEVICE double sample (double a_x2, double a_rngValue, RNG &&a_rng) const
template<typename RNG>
LUPI_HOST_DEVICE double sample2dOf3d (double a_x2, double a_rngValue, RNG &&a_rng, double *a_x1_1, double *a_x1_2) const
Public Member Functions inherited from MCGIDI::Probabilities::ProbabilityBase2d
LUPI_HOST_DEVICE ProbabilityBase2d ()
LUPI_HOST ProbabilityBase2d (GIDI::Functions::FunctionForm const &a_probabilty)
LUPI_HOST ProbabilityBase2d (GIDI::Functions::FunctionForm const &a_probabilty, Vector< double > const &a_Xs)
LUPI_HOST_DEVICE ~ProbabilityBase2d ()
LUPI_HOST_DEVICE ProbabilityBase2dType type () const
LUPI_HOST_DEVICE String typeString () const
LUPI_HOST_DEVICE MCGIDI_VIRTUAL_FUNCTION double evaluate (double a_x2, double a_x1) const MCGIDI_TRUE_VIRTUAL
template<typename RNG>
LUPI_HOST_DEVICE MCGIDI_VIRTUAL_FUNCTION double sample (double a_x2, double a_rngValue, RNG &&a_rng) const MCGIDI_TRUE_VIRTUAL
LUPI_HOST_DEVICE void serialize (LUPI::DataBuffer &a_buffer, LUPI::DataBuffer::Mode a_mode)
template<typename RNG>
LUPI_HOST_DEVICE double sample (double a_x2, double a_rngValue, RNG &&a_rng) const
Public Member Functions inherited from MCGIDI::Probabilities::ProbabilityBase
LUPI_HOST_DEVICE ProbabilityBase ()
LUPI_HOST ProbabilityBase (GIDI::Functions::FunctionForm const &a_probabilty)
LUPI_HOST ProbabilityBase (GIDI::Functions::FunctionForm const &a_probabilty, Vector< double > const &a_Xs)
LUPI_HOST_DEVICE ~ProbabilityBase ()
LUPI_HOST_DEVICE void serialize (LUPI::DataBuffer &a_buffer, LUPI::DataBuffer::Mode a_mode)
Public Member Functions inherited from MCGIDI::Functions::FunctionBase
LUPI_HOST_DEVICE FunctionBase ()
LUPI_HOST FunctionBase (GIDI::Functions::FunctionForm const &a_function)
LUPI_HOST_DEVICE FunctionBase (int a_dimension, double a_domainMin, double a_domainMax, Interpolation a_interpolation, double a_outerDomainValue=0)
virtual LUPI_HOST_DEVICE ~FunctionBase ()=0
LUPI_HOST_DEVICE Interpolation interpolation () const
LUPI_HOST_DEVICE double domainMin () const
LUPI_HOST_DEVICE double domainMax () const
LUPI_HOST_DEVICE double outerDomainValue () const
LUPI_HOST_DEVICE void serialize (LUPI::DataBuffer &a_buffer, LUPI::DataBuffer::Mode a_mode)

Additional Inherited Members

Protected Attributes inherited from MCGIDI::Probabilities::ProbabilityBase2d
ProbabilityBase2dType m_type
Protected Attributes inherited from MCGIDI::Probabilities::ProbabilityBase
Vector< double > m_Xs

Detailed Description

Definition at line 646 of file MCGIDI_functions.hpp.

Constructor & Destructor Documentation

◆ GeneralEvaporation2d() [1/2]

LUPI_HOST_DEVICE MCGIDI::Probabilities::GeneralEvaporation2d::GeneralEvaporation2d ( )

Definition at line 2092 of file MCGIDI_functions.cc.

2092 :
2093 m_theta( nullptr ),
2094 m_g( nullptr ) {
2095
2097}

◆ GeneralEvaporation2d() [2/2]

LUPI_HOST MCGIDI::Probabilities::GeneralEvaporation2d::GeneralEvaporation2d ( GIDI::Functions::GeneralEvaporation2d const & a_generalEvaporation2d)

Definition at line 2101 of file MCGIDI_functions.cc.

2101 :
2102 ProbabilityBase2d_d2( a_generalEvaporation2d ),
2103 m_theta( Functions::parseFunction1d_d1( a_generalEvaporation2d.theta( ) ) ),
2104 m_g( parseProbability1d( a_generalEvaporation2d.g( ) ) ) {
2105
2107}
LUPI_HOST Function1d_d1 * parseFunction1d_d1(Transporting::MC const &a_settings, GIDI::Suite const &a_suite)
LUPI_HOST ProbabilityBase1d * parseProbability1d(Transporting::MC const &a_settings, GIDI::Suite const &a_suite)

◆ ~GeneralEvaporation2d()

LUPI_HOST_DEVICE MCGIDI::Probabilities::GeneralEvaporation2d::~GeneralEvaporation2d ( )

Definition at line 2112 of file MCGIDI_functions.cc.

2112 {
2113
2114 delete m_theta;
2115 delete m_g;
2116}

Member Function Documentation

◆ evaluate()

LUPI_HOST_DEVICE double MCGIDI::Probabilities::GeneralEvaporation2d::evaluate ( double a_x2,
double a_x1 ) const

Definition at line 2120 of file MCGIDI_functions.cc.

2120 {
2121
2122 return( m_g->evaluate( a_x1 / m_theta->evaluate( a_x2 ) ) );
2123}

◆ sample()

template<typename RNG>
LUPI_HOST_DEVICE double MCGIDI::Probabilities::GeneralEvaporation2d::sample ( double a_x2,
double a_rngValue,
RNG && a_rng ) const

Definition at line 2040 of file MCGIDI_headerSource.hpp.

2040 {
2041
2042 return( m_theta->evaluate( a_x2 ) * m_g->sample( a_rngValue, a_rng ) );
2043}

◆ serialize()

LUPI_HOST_DEVICE void MCGIDI::Probabilities::GeneralEvaporation2d::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.

Parameters
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 2133 of file MCGIDI_functions.cc.

2133 {
2134
2135 ProbabilityBase2d::serialize( a_buffer, a_mode );
2136 m_theta = serializeFunction1d_d1( a_buffer, a_mode, m_theta );
2137 m_g = serializeProbability1d( a_buffer, a_mode, m_g );
2138}
LUPI_HOST_DEVICE void serialize(LUPI::DataBuffer &a_buffer, LUPI::DataBuffer::Mode a_mode)
LUPI_HOST_DEVICE Functions::Function1d_d1 * serializeFunction1d_d1(LUPI::DataBuffer &a_buffer, LUPI::DataBuffer::Mode a_mode, Functions::Function1d_d1 *a_function1d)
LUPI_HOST_DEVICE Probabilities::ProbabilityBase1d * serializeProbability1d(LUPI::DataBuffer &a_buffer, LUPI::DataBuffer::Mode a_mode, Probabilities::ProbabilityBase1d *a_probability1d)

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