summaryrefslogtreecommitdiffstats
path: root/lib/libc/gen/rand48.3
diff options
context:
space:
mode:
authorsheldonh <sheldonh@FreeBSD.org>2000-03-02 09:14:21 +0000
committersheldonh <sheldonh@FreeBSD.org>2000-03-02 09:14:21 +0000
commit329223e6f229a55ee8fed800f358f30e994ed749 (patch)
tree5d5e6c715ccfb778a29f10e1ea16f06731edbda8 /lib/libc/gen/rand48.3
parent05f0a865546b5e0b902987be72a75a7b0ef85d09 (diff)
downloadFreeBSD-src-329223e6f229a55ee8fed800f358f30e994ed749.zip
FreeBSD-src-329223e6f229a55ee8fed800f358f30e994ed749.tar.gz
Remove single-space hard sentence breaks. These degrade the quality
of the typeset output, tend to make diffs harder to read and provide bad examples for new-comers to mdoc.
Diffstat (limited to 'lib/libc/gen/rand48.3')
-rw-r--r--lib/libc/gen/rand48.39
1 files changed, 6 insertions, 3 deletions
diff --git a/lib/libc/gen/rand48.3 b/lib/libc/gen/rand48.3
index 86e7a2f..ac7e33e 100644
--- a/lib/libc/gen/rand48.3
+++ b/lib/libc/gen/rand48.3
@@ -50,7 +50,8 @@
The
.Fn rand48
family of functions generates pseudo-random numbers using a linear
-congruential algorithm working on integers 48 bits in size. The
+congruential algorithm working on integers 48 bits in size.
+The
particular formula employed is
r(n+1) = (a * r(n) + c) mod m
where the default values are
@@ -64,7 +65,8 @@ computational step is to perform a single iteration of the algorithm.
.Fn drand48
and
.Fn erand48
-return values of type double. The full 48 bits of r(n+1) are
+return values of type double.
+The full 48 bits of r(n+1) are
loaded into the mantissa of the returned value, with the exponent set
such that the values produced lie in the interval [0.0, 1.0).
.Pp
@@ -119,7 +121,8 @@ also initializes the internal buffer r(n) of
and
.Fn mrand48 ,
but here all 48 bits of the seed can be specified in an array of 3 shorts,
-where the zeroth member specifies the lowest bits. Again,
+where the zeroth member specifies the lowest bits.
+Again,
the constant multiplicand and addend of the algorithm are
reset to the default values given above.
.Fn seed48
OpenPOWER on IntegriCloud