let float_lp =
(* let max = ~-. (float (1 lsl (Sys.word_size -2))) in *)
(* let max = ~-. (float (1 lsl 30)) in *)
let max = float (1 lsl 29) *. 2. in (* works both on 32 and 64 bits, comments welcome *)
fun prng ->
float (Random.State.bits prng) /. max