nag_rand_chi_sq (g05sdc) generates a vector of pseudorandom numbers taken from a -distribution with degrees of freedom.
The distribution has PDF (probability density function)
This is the same as a gamma distribution with parameters
and
.
One of the initialization functions
nag_rand_init_repeatable (g05kfc) (for a repeatable sequence if computed sequentially) or
nag_rand_init_nonrepeatable (g05kgc) (for a non-repeatable sequence) must be called prior to the first call to nag_rand_chi_sq (g05sdc).
Not applicable.
nag_rand_chi_sq (g05sdc) is threaded by NAG for parallel execution in multithreaded implementations of the NAG Library.
Please consult the
Users' Note for your implementation for any additional implementation-specific information.
This example prints five pseudorandom numbers from a
-distribution with five degrees of freedom, generated by a single call to nag_rand_chi_sq (g05sdc), after initialization by
nag_rand_init_repeatable (g05kfc).
None.