comp.lang.ada
 help / color / mirror / Atom feed
From: "Robert I. Eachus" <rieachus@attbi.com>
Subject: Re: Building on Random_Float?
Date: Sun, 26 May 2002 23:24:52 GMT
Date: 2002-05-26T23:24:52+00:00	[thread overview]
Message-ID: <3CF1701E.9020902@attbi.com> (raw)
In-Reply-To: mailman.1020976203.6044.comp.lang.ada@ada.eu.org

Mars Gralia wrote:

> Ada Wizards and Gentle Folk,
> 
> I would like a high-level Ada95 design that allows me to build a
> layered series of random number generators which ultimately use
> Ada.Numerics.Float_Random.  Could you please provide me one?
> 
> Details are given below.


I guess I don't see your problem.  Generators are and should be limited, 
because of the mischief that can come from making a copy of one.  (The 
mechanism for states insures that you can save, copy, etc. generator 
states, but that random sequences from a generator have guaranteed 
properties between resets.

But there is nothing to prevent you from creating a normal generator 
that is also limited with a uniform generator (or two) as components.
I say or two because the best normal distribution generator I know uses 
two uniform variates.  But remember if you do use two generators, to get 
full benefit, you need to initialize (reset) them using different 
sources of randomness.

My current email address is rieachus@attbi.com.





  reply	other threads:[~2002-05-26 23:24 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-05-09 20:29 Building on Random_Float? Mars Gralia
2002-05-26 23:24 ` Robert I. Eachus [this message]
  -- strict thread matches above, loose matches on Subject: below --
2002-05-10 19:36 Building on Random Float? Mike Brenner
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox