There is a solution by @Elrod here to get the random numbers distribution over (0,1):
prevfloat(1.0)*(1-rand())