The OpenD Programming Language

ExponentialVariable

$(WIKI_D Exponential).

Constructors

this
this(T scale)

Members

Functions

opCall
T opCall(G gen)
T opCall(G* gen)

Manifest constants

isRandomVariable
enum isRandomVariable;

Variables

max
enum T max;
min
enum T min;

Return Value

X ~ Exp(β)

Examples

auto rv = exponentialVar;
static assert(isRandomVariable!(typeof(rv)));
import mir.random.engine;
auto x = rv(rne);
import mir.random.engine;
Random* gen = threadLocalPtr!Random;
auto rv = ExponentialVariable!double(1);
auto x = rv(gen);

Meta