Tuned Noise Gen (.. but not as we know it Jim)

For general discussion related FlowStone
User avatar
wlangfor@uoguelph.ca
Posts: 912
Joined: Tue Apr 03, 2018 5:50 pm
Location: North Bay, Ontario, Canada
Contact:

Re: Tuned Noise Gen (.. but not as we know it Jim)

Post by wlangfor@uoguelph.ca »

this is one of the most amazing things I've ever heard, amazing. Thanks :)
My youtube channel: DSPplug
My Websites: www.dspplug.com KVRaudio flowstone products
User avatar
Spogg
Posts: 3368
Joined: Thu Nov 20, 2014 4:24 pm
Location: Birmingham, England
Contact:

Re: Tuned Noise Gen (.. but not as we know it Jim)

Post by Spogg »

Very nicely done Hugh (all in one ASM box). :ugeek:

I suspect, but I don’t know, that we don’t need such a sophisticated sinewave generating code just to make use of the method to make pitched noise. Martin’s original code aimed for a perfect sinewave, but for noise it may be overkill…

Cheers

Spogg
User avatar
HughBanton
Posts: 265
Joined: Sat Apr 12, 2008 3:10 pm
Location: Evesham, Worcestershire
Contact:

Re: Tuned Noise Gen (.. but not as we know it Jim)

Post by HughBanton »

You're right, we don't .. turns out it works just as well with triangle oscillators in positions 2 & 3 - they're half the code. Yay. But with a sin osc in position 1 we seem to get this really clean bandlimited output.

I'll carry on with it while it's got my attention, back later perhaps. (What else am I going to do ... ? :lol: )

H
User avatar
HughBanton
Posts: 265
Joined: Sat Apr 12, 2008 3:10 pm
Location: Evesham, Worcestershire
Contact:

Re: Tuned Noise Gen (.. but not as we know it Jim)

Post by HughBanton »

And finally ..

I was slightly wrong about about using triangles for oscs 2 & 3 - they introduce higher harmonics so the roll-off isn't as good. Obvious when you think about it. The way I had the design originally I reckon it produces an almost 'analogue' sound. (Whatever that's supposed to mean. :roll: .. I blame the heat).

So I've been investigating alternative, more compact, sine generators. I've researched several of MVs extensive collection of algorithms, both FS and published elsewhere - amazing resource - but found all the '2- or 3-liners' were unstable in this application, and it generally lost the plot after a few seconds.

Polynomial oscillators, I've learned this week, use a relatively simple formula to convert a regular ramp (saw-tooth) into another function, in this case a cosine. So because they start with a predictable straight-line counter they're really stable. Martin will be horrified at my maths-hacking, but I discovered I could remove the c3 constant, adjust both c1 & c2 by trial and error, and get a sufficiently cosine-ish result that seems acceptable. Which shortened each of the 3 oscillators by several lines of code. (DSP version is in the 'Polynomial Osc (HB reduction)' modules).

So here we are, reduced version. I doubt it will go any more compact than this, but I'd bet this now compares favourably with the noise + extreme filter that would be required to get this sound by the traditional method.

Snag is you can't adjust the roll off, as far as I can tell .. but maybe people can find a use for it as is.

By the way .. my original "woke up this morning" idea last Sunday was in fact for a blue mono LF random generator, not a poly noise generator at all. I've long been aware that if you get a pendulum (mathematically predictable) but insert a hinge at some point along its length, the resulting movement rapidly turns to .. Chaos. So I was aiming to emulate a 'hinged-pendulum' setup. Funny where things lead sometimes ...

H
osc_ring_assem_2.fsm
(17.74 KiB) Downloaded 976 times

PS Thanks Spogg for the 'Uber Geek' yesterday - never expected to earn one of those, you made my day!! ('Unter Hacker' more like ....)
User avatar
wlangfor@uoguelph.ca
Posts: 912
Joined: Tue Apr 03, 2018 5:50 pm
Location: North Bay, Ontario, Canada
Contact:

Re: Tuned Noise Gen (.. but not as we know it Jim)

Post by wlangfor@uoguelph.ca »

Amazing, simply amazing :)
My youtube channel: DSPplug
My Websites: www.dspplug.com KVRaudio flowstone products
k brown
Posts: 1198
Joined: Tue Aug 16, 2016 7:10 pm
Location: San Francisco, CA USA
Contact:

Re: Tuned Noise Gen (.. but not as we know it Jim)

Post by k brown »

I certainly don't follow the maths at work here, but just going by what I hear, it doesn't sound any different from white noise thru a filter with 100% keytrack. Is the whole point that this uses a lot less CPU than noise gen-plus-filter? Is there something I'm missing?
Website for the plugins : http://kbrownsynthplugins.weebly.com/
User avatar
wlangfor@uoguelph.ca
Posts: 912
Joined: Tue Apr 03, 2018 5:50 pm
Location: North Bay, Ontario, Canada
Contact:

Re: Tuned Noise Gen (.. but not as we know it Jim)

Post by wlangfor@uoguelph.ca »

k brown wrote:I certainly don't follow the maths at work here, but just going by what I hear, it doesn't sound any different from white noise thru a filter with 100% keytrack. Is the whole point that this uses a lot less CPU than noise gen-plus-filter? Is there something I'm missing?


He just doesn't understand.. "shakes head
My youtube channel: DSPplug
My Websites: www.dspplug.com KVRaudio flowstone products
k brown
Posts: 1198
Joined: Tue Aug 16, 2016 7:10 pm
Location: San Francisco, CA USA
Contact:

Re: Tuned Noise Gen (.. but not as we know it Jim)

Post by k brown »

Well, 'splain it to me - that's why I posted; how does this sound different?
Website for the plugins : http://kbrownsynthplugins.weebly.com/
User avatar
Spogg
Posts: 3368
Joined: Thu Nov 20, 2014 4:24 pm
Location: Birmingham, England
Contact:

Re: Tuned Noise Gen (.. but not as we know it Jim)

Post by Spogg »

Well done again Hugh! :ugeek:

@Kevin
Yes it’s all about CPU versus flexibility. With a filter system you still need to produce the noise in the first place, and that can be done with one sine osc with a high amount of self-feedback for phase or frequency modulation. That creates noise which is kinda white, probably sufficiently so. But if you want key-tracked filtering you of course need a filter and the tracking system, and a decent filter will use a lot more CPU than two more optimised sine wave oscillators (I think!).

But if you want flexibility in terms of resonance, slope and mode then the traditional noise-filter arrangement is the only way. So it depends on the application. I suspect in Hugh’s case for example, he might find it useful for simulating the turbulence you get when an organ pipe speaks, since that sound will inevitably be related to the pitch of the pipe.

Cheers

Spogg
k brown
Posts: 1198
Joined: Tue Aug 16, 2016 7:10 pm
Location: San Francisco, CA USA
Contact:

Re: Tuned Noise Gen (.. but not as we know it Jim)

Post by k brown »

That's what I figured - a CPU-light way of getting a similar result. Could be useful as an additional osc 'waveform' in a synth -leaving the main Noise gen for other things and not tying up the filter.

Possibly flute 'chiffs' as well.
Website for the plugins : http://kbrownsynthplugins.weebly.com/
Post Reply