home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.lang.c
- Path: sparky!uunet!cis.ohio-state.edu!zaphod.mps.ohio-state.edu!moe.ksu.ksu.edu!mimbres.cs.unm.edu!constellation!osuunx.ucc.okstate.edu!datacomm.ucc.okstate.edu!martin
- From: martin@datacomm.ucc.okstate.edu (Martin McCormick)
- Subject: Using erand48
- Message-ID: <1992Nov19.215037.18995@osuunx.ucc.okstate.edu>
- Sender: news@osuunx.ucc.okstate.edu (USENET News System)
- Nntp-Posting-Host: datacomm.ucc.okstate.edu
- Organization: Oklahoma State University, Stillwater, OK
- Date: Thu, 19 Nov 1992 21:50:37 GMT
- Lines: 14
-
-
- I am a novice C programmer trying to use the rand48 family of functions.
- I don't know how wide-spread these functions are, but they exist on a Sun
- Sparc and also on a Dec running Untrix. What I would really like to see is
- an example of code, using this function since I am having trouble deciphering
- the man page to figure out exactly what I need to feed it in order to seed
- the function. The erand48 function returns a floating-point value between
- 0 and 1 which is exactly the type of output I want since that can be multiplied
- by a constant to produce an upper limit.
- The erand48 function requires storage for the X value, but I am
- lost as to what else is needed. Thank you for any help.
-
- Martin McCormick WB5AGZ Stillwater, OK
- O.S.U. Computer Center Data Communications Group
-