ROSS
Functions
ross-random.c File Reference
#include <ross.h>

Go to the source code of this file.

Functions

tw_rngtw_rand_init (uint32_t v, uint32_t w)
 
long tw_rand_integer (tw_rng_stream *g, long low, long high)
 
unsigned long tw_rand_ulong (tw_rng_stream *g, unsigned long low, unsigned long high)
 
long tw_rand_binomial (tw_rng_stream *g, long N, double P)
 
double tw_rand_exponential (tw_rng_stream *g, double Lambda)
 
double tw_rand_pareto (tw_rng_stream *g, double shape, double scale)
 
double tw_rand_gamma (tw_rng_stream *g, double shape, double scale)
 
long tw_rand_geometric (tw_rng_stream *g, double P)
 
double tw_rand_normal01 (tw_rng_stream *g, unsigned int *rng_calls)
 
double tw_rand_normal_sd (tw_rng_stream *g, double Mu, double Sd, unsigned int *rng_calls)
 
long tw_rand_poisson (tw_rng_stream *g, double Lambda)
 
double tw_rand_lognormal (tw_rng_stream *g, double mean, double sd, unsigned int *rng_calls)
 
double tw_rand_weibull (tw_rng_stream *g, double mean, double shape)
 

Function Documentation

long tw_rand_binomial ( tw_rng_stream g,
long  N,
double  P 
)

Definition at line 53 of file ross-random.c.

References tw_rand_unif.

double tw_rand_exponential ( tw_rng_stream g,
double  Lambda 
)

Definition at line 69 of file ross-random.c.

References tw_rand_unif.

Referenced by phold_event_handler(), phold_init(), phold_pre_run(), and tw_rand_gamma().

Here is the caller graph for this function:

double tw_rand_gamma ( tw_rng_stream g,
double  shape,
double  scale 
)

Definition at line 81 of file ross-random.c.

References tw_rand_exponential(), and tw_rand_unif.

Here is the call graph for this function:

long tw_rand_geometric ( tw_rng_stream g,
double  P 
)

Definition at line 141 of file ross-random.c.

References tw_rand_unif.

tw_rng* tw_rand_init ( uint32_t  v,
uint32_t  w 
)

Definition at line 7 of file ross-random.c.

References rng_init().

Referenced by tw_pe_init().

Here is the call graph for this function:

Here is the caller graph for this function:

long tw_rand_integer ( tw_rng_stream g,
long  low,
long  high 
)

NOTE: Don't pass negative values to low!

Definition at line 21 of file ross-random.c.

References tw_rand_unif.

Referenced by phold_event_handler(), and phold_pre_run().

Here is the caller graph for this function:

double tw_rand_lognormal ( tw_rng_stream g,
double  mean,
double  sd,
unsigned int *  rng_calls 
)

Definition at line 209 of file ross-random.c.

References tw_rand_normal01().

Here is the call graph for this function:

double tw_rand_normal01 ( tw_rng_stream g,
unsigned int *  rng_calls 
)

Definition at line 152 of file ross-random.c.

References tw_error(), TW_LOC, tw_rng_stream::tw_normal_flipflop, tw_rng_stream::tw_normal_u1, tw_rng_stream::tw_normal_u2, tw_opi, and tw_rand_unif.

Referenced by tw_rand_lognormal(), and tw_rand_normal_sd().

Here is the call graph for this function:

Here is the caller graph for this function:

double tw_rand_normal_sd ( tw_rng_stream g,
double  Mu,
double  Sd,
unsigned int *  rng_calls 
)

Definition at line 182 of file ross-random.c.

References tw_rand_normal01().

Here is the call graph for this function:

double tw_rand_pareto ( tw_rng_stream g,
double  shape,
double  scale 
)

Definition at line 75 of file ross-random.c.

References tw_rand_unif.

long tw_rand_poisson ( tw_rng_stream g,
double  Lambda 
)

Definition at line 188 of file ross-random.c.

References tw_rand_unif.

unsigned long tw_rand_ulong ( tw_rng_stream g,
unsigned long  low,
unsigned long  high 
)

Definition at line 37 of file ross-random.c.

References tw_rand_unif.

double tw_rand_weibull ( tw_rng_stream g,
double  mean,
double  shape 
)

Definition at line 215 of file ross-random.c.

References tw_rand_unif.