Multiplying a signal with its own envelope

DSP, Plugin and Host development discussion.
RELATED
PRODUCTS

Post

What you described earlier was essentially a ring modulation with the envelope. The abs( ) or x^2 operation in the envelope double the frequencis of the input signal and the averaging will restrict this to lower freqs. Ringmodulating this with the original signal will shift each frequency to the left and right by it's double amount. Plus this happens not only to _one_ freuency but to the combination of all of them.

Instead you might want to look into http://en.wikipedia.org/wiki/Kalman_filter which at the price of some calculation gives you a model-driven solution to your problem. Try googling around a bit - as far as I remember, the math is no quite as bad as it looks in the wikipedia article :-)

Hope that helps!
- eth

Post

Intuitively for a pure sine input I would think that envelope follower * input signal arrangement would generate increasing amounts of odd harmonics as the frequency of the input drops relative to the time constant(s) of the follower, but for a random input..? If the input signal is truly random and if CPU is important then mebbe a moving average filter may be the place to start. (it is very early here though so apply a pinch of salt!)
ethrandil wrote: ...as far as I remember, the math is no quite as bad as it looks in the wikipedia article :-)
Wikipedia seems to have a habit of doing that!
"are we there yet?"

Post

Instead you might want to look into http://en.wikipedia.org/wiki/Kalman_filter which at the price of some calculation gives you a model-driven solution to your problem. Try googling around a bit - as far as I remember, the math is no quite as bad as it looks in the wikipedia article
Thanks - the Kalman filter was indeed what I came across first when googling around this subject. I'm kind of working my way up to it as yes, the maths is scary and I wanted to make sure I'd got a really good handle on the problem before tackling a new algorithm.
a moving average filter may be the place to start
I recoded the EWMA last night and it does indeed give good results. However to get enough smoothing it introduces lag, which leads to a bit of "VR sickness" in this app. So I think I might use a "fast" EWMA and a "slow" EWMA and then average the results (an old trick used in compressors didncha know)

Cheers
Dave

Post

Just to update this to its final conclusion:-

In the end a single EWMA filter was sufficient, but with a dynamically-adjusted smoothing coefficient that temporarily reduces the smoothing if the filter was lagging the original input too much.

Cheers
Dave

Post Reply

Return to “DSP and Plugin Development”