Re: [PD] Box Muller Gaussian noise - Rain Sound

2008-03-17 Thread [EMAIL PROTECTED]
Hi Andy, Andy Farnell wrote: JFYI the application is rainfall. Many papers I read describe rainfall as Gaussian. maybe mine is a simplistic approach, but shouldn't this be one of the cases in which measuring the spectrum of true rainfall sounds and trying to emulate it with one of spectrum

Re: [PD] Box Muller Gaussian noise - Rain Sound

2008-03-17 Thread Andy Farnell
Hey Alberto, Thanks for the ideas. What this bit is for.. its not the noisy background you get to rain, 1/x noise (everyone loves that sound, sometimes called comfort noise), but I'm looking at the effect of very light rain when it's on your window and you can hear every individual drop. Apart

Re: [PD] Box Muller Gaussian noise

2008-03-17 Thread Steffen Juul
Hey Andy, On 16/03/2008, at 23.12, Andy Farnell wrote: I just neatened that up into an abstration + help Thanks for wrapping it up. All vanilla I don't think [ln~] is vanilla. But [expr~ ln($v1)] could maybe do, as it's shipped with vanilla. Best, Steffen

Re: [PD] Box Muller Gaussian noise

2008-03-17 Thread Andy Farnell
Okay thanks for nfo. @ Miller, please, could we get [abs~] and [ln~] into vanilla. I think we all agree they are bread and butter objects. cheers, Andy On Mon, 17 Mar 2008 16:59:08 +0100 Steffen Juul [EMAIL PROTECTED] wrote: Hey Andy, On 16/03/2008, at 23.12, Andy Farnell wrote: I

Re: [PD] Box Muller Gaussian noise

2008-03-17 Thread Roman Haefeli
On Mon, 2008-03-17 at 16:21 +, Andy Farnell wrote: @ Miller, please, could we get [abs~] and [ln~] into vanilla. I think we all agree they are bread and butter objects. i do agree. btw: thank you all for this very interesting thread. it was very insightful. i really liked following it,

Re: [PD] Box Muller Gaussian noise

2008-03-17 Thread marius schebella
Andy Farnell wrote: Okay thanks for nfo. @ Miller, please, could we get [abs~] and [ln~] into vanilla. I think we all agree they are bread and butter objects. and ~, =~, ~, =~ thnks, marius. ___ PD-list@iem.at mailing list UNSUBSCRIBE and

Re: [PD] Box Muller Gaussian noise

2008-03-16 Thread Martin Peach
Andy Farnell wrote: Could a stats mathematician please help me check this. (attached) Well I'm not one but... I'm following the Box Muller formula for getting a cheap Gaussian distribution (instead of adding up 12 sources a la central limit method).

Re: [PD] Box Muller Gaussian noise

2008-03-16 Thread Charles Henry
On Sun, Mar 16, 2008 at 10:30 AM, Andy Farnell [EMAIL PROTECTED] wrote: Also, I have no idea how to check the distribution. It sounds the same as uniform noise and looks the same in the spectrograph? What gives? Do I need to average over a very long time or something to see any

Re: [PD] Box Muller Gaussian noise

2008-03-16 Thread Charles Henry
On Sun, Mar 16, 2008 at 11:16 AM, Martin Peach [EMAIL PROTECTED] wrote: (gaussianoise has occasional values that exceed [-1 ... 1], which I suppose is normal...white noise is always on [-1...1]) That's true. With the Box-Muller method, there is the log(~U1) term, but you can always just add

Re: [PD] Box Muller Gaussian noise

2008-03-16 Thread Lawrence Joseph
Hi, Could a stats mathematician please help me check this. (attached) I'm following the Box Muller formula for getting a cheap Gaussian distribution (instead of adding up 12 sources a la central limit method). http://www.dspguru.com/howto/tech/wgn.htm Does this look right? I agree that

Re: [PD] Box Muller Gaussian noise

2008-03-16 Thread Martin Peach
Charles Henry wrote: On Sun, Mar 16, 2008 at 11:16 AM, Martin Peach [EMAIL PROTECTED] wrote: (gaussianoise has occasional values that exceed [-1 ... 1], which I suppose is normal...white noise is always on [-1...1]) That's true. With the Box-Muller method, there is the log(~U1) term, but

Re: [PD] Box Muller Gaussian noise

2008-03-16 Thread Martin Peach
Oh no that's wrong isn't it :( The log is necessary to keep the distribution normal, and the range is going to get wider the closer to zero the radius is allowed to get. The attached patch has a scale adjustment... Still I wonder what kind of distribution gaussianoise2 gives, it's not just

Re: [PD] Box Muller Gaussian noise

2008-03-16 Thread marius schebella
from the first equation that andy posted, I produced a gem representation. the box muller noise seems wrong, because it does not use the whole range but is shifted to the negative side. note, this is not a distribution of frequencies, but of noise values.. marius. Martin Peach wrote: Oh no

Re: [PD] Box Muller Gaussian noise

2008-03-16 Thread Andy Farnell
GEM is broken here, but thanks for the info Marius. I'm reading through the docs for R at the moment. It makes lovely plots, but haven't figured how to get my data in to it yet... JFYI the application is rainfall. Many papers I read describe rainfall as Gaussian. I know from physical analysis

Re: [PD] Box Muller Gaussian noise

2008-03-16 Thread Charles Henry
(sorry for the duplicate, Martin!) The Box-Muller method (I've always thought it was just Ross who did this one) is a classic trick. It probably goes back even to Gauss--who knows and who cares pdf of Gaussian: f(x)= k * e^-(x^2/ (2*sigma^2)) k is a normalization constant--which we will

Re: [PD] Box Muller Gaussian noise

2008-03-16 Thread Charles Henry
On Sun, Mar 16, 2008 at 2:49 PM, Charles Henry [EMAIL PROTECTED] wrote: our cdf (cumulative dist function) G(Z)=P( Zr^2 )= integral ( r^2 = 0 to Z, 1/sigma^2 * e^-(r^2/sigma^2) d(r^2) G(Z)=1 - e^-(Z/sigma^2) Take U1=Z on [0,1] , take U2 on [0,1] Actually, it makes more sense for U1 to be

Re: [PD] Box Muller Gaussian noise

2008-03-16 Thread Martin Peach
Here's a histogram generator (binner) that shows the distribution of [gaussianoise]. Using it I can quickly see that [gaussianoise2] is too peaked around zero and that [gaussianoise3] chops the tails off when the scale is low. If you have uniformly distributed raindrops falling, any given area

Re: [PD] Box Muller Gaussian noise

2008-03-16 Thread Charles Henry
So, we can find g(r) independently by integrating with respect to theta. we get g(r)= 1/sigma^2 * e^-(r^2/sigma^2) Ah, here's a missing factor of 2 in the exponent. That should be g(r)= 1/sigma^2 * e^-(r^2/ ( 2*sigma^2) ) And the correct formulae are x=r*cos(theta) = sigma * sqrt(-2 * ln

Re: [PD] Box Muller Gaussian noise

2008-03-16 Thread Andy Farnell
Wow, that's a gorgeous demonstraton Martin! Everything becomes clear as time - infinity :) And somehow our little Earthling brains are able to spot this signature distribution as we listen to rainfall. Now I'm getting how uniform fall leads to a Gaussian bell around the mean for an area over

Re: [PD] Box Muller Gaussian noise

2008-03-16 Thread Andy Farnell
I just neatened that up into an abstration + help All vanilla Replaced [abs~] More efficient [q8-sqrt~] seens fine No need for pi multiplier as is implicit in [cos~] radians (?) Martins histogram in separate GOP abs If I made a mistake please correct and repost. a. On Sun, 16 Mar 2008

Re: [PD] Box Muller Gaussian noise

2008-03-16 Thread Uğur Güney
# Hi, sorry for jumping into the conversation. I am doing my statistical physics homework and can not read whole mails just skim read them and saw terms like uniform distribution and gaussian distribution. I thought it could be worth to mention the central limit theorem which says that the

Re: [PD] Box Muller Gaussian noise

2008-03-16 Thread Charles Henry
One thing I've been thinking of lately for pd is to synthesize a impulse train with the poisson process. Many natural phenomena, like the timing of rain drops, can be simulated with the poisson process. It's just one of those ubitquitous relations that pops up everywhere. A poisson process

Re: [PD] Box Muller Gaussian noise

2008-03-16 Thread Andy Farnell
On Sun, 16 Mar 2008 18:11:50 -0500 Charles Henry [EMAIL PROTECTED] wrote: My interest in making an impulse train is to make the impulses, which will have subtle deviations about a central frequency, and process them through a filter (formant). Would be useful. It's certainly common, saw this