33 namespace distributionModels
49 minValue_(distributionModelDict_.template lookup<scalar>(
"minValue")),
50 maxValue_(distributionModelDict_.template lookup<scalar>(
"maxValue")),
51 d_(distributionModelDict_.template lookup<scalar>(
"d")),
52 n_(distributionModelDict_.template lookup<scalar>(
"n"))
62 minValue_(p.minValue_),
63 maxValue_(p.maxValue_),
79 const scalar minValueByDPowN =
pow(minValue_/d_, n_);
80 const scalar
K = 1 -
exp(-
pow(maxValue_/d_, n_) + minValueByDPowN);
82 return d_*
pow(minValueByDPowN -
log(1 - K*y), 1/n_);
dimensionedScalar log(const dimensionedScalar &ds)
Random & rndGen_
Reference to the random number generator.
A list of keyword definitions, which are a keyword followed by any number of values (e...
virtual scalar sample() const
Sample the distributionModel.
CGAL::Exact_predicates_exact_constructions_kernel K
Macros for easy insertion into run-time selection tables.
Type sample01()
Advance the state and return a sample of a given type from a.
dimensionedScalar exp(const dimensionedScalar &ds)
RosinRammler(const dictionary &dict, Random &rndGen)
Construct from components.
defineTypeNameAndDebug(exponential, 0)
Rosin-Rammler distributionModel.
dimensionedScalar pow(const dimensionedScalar &ds, const dimensionedScalar &expt)
virtual scalar minValue() const
Return the minimum value.
virtual ~RosinRammler()
Destructor.
virtual scalar meanValue() const
Return the mean value.
A library of runtime-selectable distribution models.
virtual scalar maxValue() const
Return the maximum value.
addToRunTimeSelectionTable(distributionModel, exponential, dictionary)