Gaussian Noise

Mr. M's icon

The Tutorial 17 (Data Structures And Probability) has a nice hands-on approach to creating random numbers in a gaussian distribution. I wonder if you can do the same with noise~-signals? I've tried (see the attached patcher), but it doesn't seem to work.

I'm aware of that you can filter noise to make certain frequencies more prevailing than others. But I would really like to hear (and work with) what a truly gaussian noise-color might sound like!

Max Patch
Copy patch and select New From Clipboard in Max.

All suggestions are very welcome!

AlexHarker's icon

A couple of things:

1 - that's not a very accurate transform to a gaussian distribution. To be honest, I not convinced it can really be described as gaussian in any strict sense - it's just a rough approximation.

A much better method is:

2 - Although the *amplitude* distribution of Gaussian noise is by definition Gaussian, that doesn't have any bearing on its correlation (which may be of different types). If you do not correlate the noise, then it will be white noise, and therefore uncoloured. In this regard it might not be worth your while investigating this, as perceptually the result is very similar to white noise with a flat amplitude distribution.

HTH

Alex

Chris Muir's icon

Peter Castine's Litter Pro package has a gaussian generator.

Mr. M's icon

Thanx for the replies! :)

I guess I was a bit fast on that one - I'm just obsessed with distributions these days... a whole new territory to explore. I bet I have to research it further... But thanx again!

kittykitty's icon

a-gaussnoise~ sounds good.

Jan M's icon

Just in case someone is still folowing this, here is a little patch that I use as an abstraction to generate gaussian noise. It applies the Box Müller tranform and was orinally written by Andy Farnell in PureData (http://aspress.co.uk/sd/practical15.php)as part of his book Designing Sound.

Max Patch
Copy patch and select New From Clipboard in Max.

Peter Castine's icon

Box-Muller is a relatively expensive way of generating Gaussian derivatives. I had a significant performance improvement in lp.gsss~ (the Gaussian noise generator from Litter Power) when I adapted the Kinderman-Ramage algorithm.

As to the original question: you could generate Gaussian noise by summing an infinite number of uniform noise sources. But that would cost a lot more CPU.-|

FWIW, one widely-used statistics package approximated a Gaussian distribution by summing a dozen uniform derivates. That's about as costly as Box-Muller, just less accurate. It does, however, have the [possible] advantage that real "outliers" (extreme values) will never be generated. The extreme values that can occasionally be generated will play havoc with some MSP patches.

In general, you don't really want to "listen" to Gaussian noise. Subjectively it can hardly be distinguished from flat white noise. Its primary raison d’être is for things like dithering.

aceslowman's icon

Has anyone found a relatively inexpensive way to get a Gaussian distribution in gen~?