gsl_rng   xtlang


Defined in:  https://github.com/digego/extempore/tree/v0.8.9/libs/contrib/gsl.xtm

Implementation

;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;; make a stupidly simple default rng
;; gsl_rng state maintained by closure
(bind-func gsl_rng
  (let ((rngs (gsl_rng_types_setup))
  (rng (gsl_rng_alloc (pref rngs 0))))
    (lambda ()
      (gsl_rng_uniform rng))))


Back to Index

Similar Entries