LognormSurvivalFunction Struct Reference
|
CPP API
|
mio::LognormSurvivalFunction Struct Reference
Class that defines an LognormSurvivalFunction function depending on the state age. More...
#include <state_age_function.h>
Inheritance diagram for mio::LognormSurvivalFunction:
Collaboration diagram for mio::LognormSurvivalFunction:
Public Member Functions | |
| ScalarType | eval (ScalarType state_age) override |
| Defines the value of the LognormSurvivalFunction depending on state_age. More... | |
| LognormSurvivalFunction (ScalarType init_distribution_parameter, ScalarType init_location=0, ScalarType init_scale=1) | |
| Constructs a new LognormSurvivalFunction object. More... | |
Public Member Functions inherited from mio::StateAgeFunction< ScalarType > | |
| std::unique_ptr< StateAgeFunction< ScalarType > > | clone () const |
| Clones unique pointer to a StateAgeFunction. More... | |
| ScalarType | get_distribution_parameter () const |
| Get the m_distribution_parameter object. More... | |
| ScalarType | get_location () const |
| Get the m_location object. More... | |
| virtual ScalarType | get_mean (ScalarType dt=1.0, ScalarType tol=1e-10) |
| Computes the mean value of the function using the time step size dt and some tolerance tol. More... | |
| ScalarType | get_scale () const |
| Get the m_scale object. More... | |
| std::string | get_state_age_function_type () const |
| Get type of StateAgeFunction, i.e.which derived class is used. More... | |
| virtual ScalarType | get_support_max (ScalarType dt, ScalarType tol=1e-10) |
| Computes the maximum of the support of the function using the time step size dt and some tolerance tol. More... | |
| StateAgeFunction< ScalarType > & | operator= (const StateAgeFunction< ScalarType > &other)=default |
| Copy assignment operator. More... | |
| StateAgeFunction< ScalarType > & | operator= (StateAgeFunction< ScalarType > &&other)=default |
| Move assignment operator. More... | |
| bool | operator== (const StateAgeFunction< ScalarType > &other) const |
| Comparison operator. More... | |
| void | set_distribution_parameter (ScalarType new_distribution_parameter) |
| Set the m_distribution_parameter object. More... | |
| void | set_location (ScalarType new_location) |
| Set the m_location object. More... | |
| void | set_scale (ScalarType new_scale) |
| Set the m_scale object. More... | |
| StateAgeFunction (const StateAgeFunction< ScalarType > &other)=default | |
| Copy constructor. More... | |
| StateAgeFunction (ScalarType init_distribution_parameter, ScalarType init_location=0, ScalarType init_scale=1) | |
| Constructs a new StateAgeFunction object. More... | |
| StateAgeFunction (StateAgeFunction< ScalarType > &&other)=default | |
| Move constructor. More... | |
| virtual | ~StateAgeFunction ()=default |
| Virtual destructor. More... | |
Protected Member Functions | |
| StateAgeFunction< ScalarType > * | clone_impl () const override |
| Implements clone for LognormSurvivalFunction. More... | |
Additional Inherited Members | |
Protected Attributes inherited from mio::StateAgeFunction< ScalarType > | |
| ScalarType | m_distribution_parameter |
| Parameter for function in derived class. More... | |
| ScalarType | m_location |
| Location parameter for function in derived class. More... | |
| ScalarType | m_mean |
| Mean value of the function. More... | |
| ScalarType | m_mean_tol |
| Tolerance for computation of the mean (initialize as not set). More... | |
| ScalarType | m_scale |
| Scale parameter for function in derived class. More... | |
| ScalarType | m_support_max |
| Maximum of the support of the function. More... | |
| ScalarType | m_support_tol |
| Tolerance for computation of the support (initialize as not set). More... | |
Detailed Description
Class that defines an LognormSurvivalFunction function depending on the state age.
A survival function is defined as 1 - cumulative density function. Does not support automatic differentiation.
Constructor & Destructor Documentation
◆ LognormSurvivalFunction()
|
inline |
Constructs a new LognormSurvivalFunction object.
Location and scale parameters are according to these parameters in the python package scipy.
- Parameters
-
[in] init_distribution_parameter Specifies the initial function parameter of the function. [in] init_location Location parameter of LognormSurvivalFunction. The parameter can be used to shift the function. Should be non-negative to fulfill the conditions of a StateAgeFunction. [in] init_scale Scale parameter of LognormSurvivalFunction.
Member Function Documentation
◆ clone_impl()
|
inlineoverrideprotectedvirtual |
Implements clone for LognormSurvivalFunction.
- Returns
- Pointer to StateAgeFunction.
Implements mio::StateAgeFunction< ScalarType >.
◆ eval()
|
inlineoverridevirtual |
Defines the value of the LognormSurvivalFunction depending on state_age.
- Parameters
-
[in] state_age Time at which the function is evaluated.
- Returns
- Evaluation of the function at state_age.
Implements mio::StateAgeFunction< ScalarType >.
Generated by
Public Member Functions inherited from