The rand(x) function returns a pseudo random number in the interval (0:1). See random for more details.