next up previous contents index
Next: Problems with the basic Up: random.cc Previous: random.cc   Contents   Index

TCL interface

Each of the concrete random number types have been declared with TCLTYPE, so random generator objects can be created at the TCL level. See newman.tcl, or test-dist.tcl for an example.

Using the unuran type, one can easily set up arbitrary distribution functions at runtime.

unuran rand
rand.set_gen {distr=cont; pdf="x^2"; domain=(0,10)}



Russell Standish 2016-09-02