From: ara.t.howard@... Date: 2006-06-07T07:48:39+09:00 Subject: Re: Strange behaviour of Rb-Gsl random numbers (Windows one-click installer) On Wed, 7 Jun 2006 Nuralanur@aol.com wrote: > Dear all, > > I've installed Rb-gsl for the Ruby-one click installer, > and tried GSL::Rng.new.uniform to get a random number. > This works, but always gives the same number: > > > > require "gsl" > > res=[] > for k in 0..20 > res< end > p res > >> res=[0.999741748906672, 0.999741748906672, 0.999741748906672, > 0.999741748906672, 0.999741748906672, 0.999741748906672, 0.999741748906672, > 0.999741748906672, 0.999741748906672, 0.999741748906672, 0.999741748906672, > 0.999741748906672, 0.999741748906672, 0.999741748906672, 0.999741748906672, > 0.999741748906672, 0.999741748906672, 0.999741748906672, 0.999741748906672, > 0.999741748906672, 0.999741748906672] > > Why ? > > Thank you, > > best regards, > > Axel i confirmed it - this works on my windows box: jib:~ > ruby -r gsl -e' include GSL; r = Rng.alloc Rng::TAUS, 1; p Array.new(20).map!{ r.uniform } ' [0.186914603225887, 0.951039797859266, 0.545435771113262, 0.0746261349413544, 0.22921886225231, 0.522971297148615, 0.0927675529383123, 0.511819139821455, 0.339204750722274, 0.793815617682412, 0.00488071935251355, 0.342924846103415, 0.296411268645898, 0.933765491936356, 0.208252872806042, 0.0223858365789056, 0.256050609983504, 0.684481433359906, 0.983118103351444, 0.441584395710379] regards. -a -- suffering increases your inner strength. also, the wishing for suffering makes the suffering disappear. - h.h. the 14th dali lama