Newsgroups: sci.image.processing
Path: cantaloupe.srv.cs.cmu.edu!das-news2.harvard.edu!news2.near.net!ll.mit.edu!vdd.VLSI.LL.MIT.EDU!bloom-beacon.mit.edu!spool.mu.edu!sgiblab!swrinde!pipex!uunet!munnari.oz.au!yoyo.aarnet.edu.au!frodo.cc.flinders.edu.au!calvin!davidh
From: davidh@ist.flinders.edu.au (David Howard,Ph3751,Rm368)
Subject: Re: Anyone has the src for generating Gaussi
Sender: @frodo.cc.flinders.edu.au
Message-ID: <1994Nov17.073436.41937@frodo.cc.flinders.edu.au>
Date: Thu, 17 Nov 1994 07:34:36 GMT
Reply-To: davidh@ist.flinders.edu.au
References: <3a3l32$529@narnia.ccs.neu.edu>
Organization: Flinders University of S.A.
Lines: 58

From sibel@ccs.neu.edu (sibel z. tari) writes:
>FOR EACH PIXEL Img(i,j)
>Noise = (a+b+c-1.5)*2;  where a,b,c are random numbers in >[0,1]
    
Sibel, you're appealing to the Central Limit Theorem to say
that "Noise" is APPROXIMATELY gaussian.  You're going to 
need to average a lot more than three iid samples for that!

What you've described is a cut down version of the following
"ancient" technique for generating normally distributed
variates.  This is to sum twelve samples from the uniform
distribution on [0, 1] and subtract 6 from the sum.  This
technique is a quick and dirty method and should not be used
if the tails of the distribution are important in your
simulations.  I can't tell from the original post if this is
the case.

There is a much better way to obtain normal variates and
that is by inverting the cumulative distribution of the 
normal.  This is textbook stuff so you can look it up.  Try
any of the following:

Monte Carlo Methods by Hammersley & Handscomb.

Stochastic Simulation by Ripley

Numerical Recipes in C by Press et al.

Not intended to be an exhaustive list :-)

Cheers,

David.

p.s. The last time I offered source for this problem I was
     "flamed".  I hope the person who flamed me has written
     the FAQ entry for this problem by now.
  
---
David Howard

Discipline of Mathematics
School of Information Science and Technology
The Flinders University of South Australia

PO Box 2100 
Adelaide  SA  5001
Australia

e-mail: davidh@maths.flinders.edu.au
phone:  (08) 201 3751


There we stood, two against a thousand ...

    ... and they were the toughest pair we ever fought!


