A uniform one-dimensional probability density over a finite range. More...
#include <prob_dens_func.h>
Public Member Functions | |
prob_dens_uniform () | |
Create a blank uniform distribution. | |
prob_dens_uniform (double a, double b) | |
Create a uniform distribution from ![]() | |
prob_dens_uniform (const prob_dens_uniform &pdg) | |
Copy constructor. | |
prob_dens_uniform & | operator= (const prob_dens_uniform &pdg) |
Copy constructor with operator=. | |
void | set_seed (unsigned long int s) |
Set the seed. | |
void | set_limits (double a, double b) |
Set the limits of the uniform distribution. | |
virtual double | lower_limit () const |
Lower limit of the range. | |
virtual double | upper_limit () const |
Uower limit of the range. | |
virtual double | operator() () const |
Operator from the specified density. | |
virtual double | pdf (double x) const |
The normalized density. | |
virtual double | log_pdf (double x) const |
The log of the normalized density. | |
virtual double | cdf (double x) const |
The cumulative distribution function (from the lower tail) | |
virtual double | invert_cdf (double in_cdf) const |
The inverse cumulative distribution function. | |
virtual double | entropy () const |
The inverse cumulative distribution function. | |
Protected Attributes | |
double | ll |
Lower limit. | |
double | ul |
Upper limit. | |
rng_gsl | r |
The GSL random number generator. | |
A flat distribution given by for
, where
is the lower limit and
is the upper limit.
This class is experimental.
Definition at line 289 of file prob_dens_func.h.
Documentation generated with Doxygen. Provided under the
GNU Free Documentation License (see License Information).