prrng 1.12.1
Loading...
Searching...
No Matches
prrng::gamma_distribution Class Reference

Gamma distribution. More...

#include <prrng.h>

Public Member Functions

 gamma_distribution (double k=1, double scale=1)
 Constructor.
 
template<class T >
pdf (const T &x)
 Probability density function.
 
template<class T >
cdf (const T &x)
 Cumulative density function.
 
template<class T >
quantile (const T &p)
 Quantile (the inverse of the cumulative density function).
 

Detailed Description

Gamma distribution.

Only available when compiled with PRRNG_USE_BOOST.

References:

Definition at line 1343 of file prrng.h.

Constructor & Destructor Documentation

◆ gamma_distribution()

prrng::gamma_distribution::gamma_distribution ( double  k = 1,
double  scale = 1 
)
inline

Constructor.

Parameters
kShape parameter \( \k \).
scaleScale parameter \( \theta \).

Definition at line 1351 of file prrng.h.

Member Function Documentation

◆ cdf()

template<class T >
T prrng::gamma_distribution::cdf ( const T &  x)
inline

Cumulative density function.

Only available when compiled with PRRNG_USE_BOOST (e.g. using the CMake target prrng::use_boost).

Parameters
xCoordinates.
Returns
Cumulative density for each x.

Definition at line 1390 of file prrng.h.

◆ pdf()

template<class T >
T prrng::gamma_distribution::pdf ( const T &  x)
inline

Probability density function.

Only available when compiled with PRRNG_USE_BOOST (e.g. using the CMake target prrng::use_boost).

Parameters
xCoordinates.
Returns
Probability density for each x.

Definition at line 1366 of file prrng.h.

◆ quantile()

template<class T >
T prrng::gamma_distribution::quantile ( const T &  p)
inline

Quantile (the inverse of the cumulative density function).

Only available when compiled with PRRNG_USE_BOOST (e.g. using the CMake target prrng::use_boost).

Parameters
pProbability [0, 1].
Returns
Quantile for each p.

Definition at line 1413 of file prrng.h.


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