Approach to Filter Design

DSP, Plugin and Host development discussion.
Post Reply New Topic
RELATED
PRODUCTS

Post

So I got this itch to learn about building filter plug-ins. I have been using Will Pirkle's Designing Audio FX Plug-ins in C++ as my main motivation, with the frequently mentioned DSP resources to supplement it. I've gotten to the point where I have a good understanding of how to approach z-plane design of IIR filters, but still get challenged on how to derive the coefficient equations that is ultimately implemented in code.

However, from all of my reading, I get the impression that a typical approach to designing a digital filter is to take a well known analog filter counterpart and just transform it to it's comparable digital equivalent - thus avoiding much of the theory and math. In other words - many of the common filters have already been designed and simply using the references online is sufficient.

So my question is - how are filters being innovated today? When somebody like Fabfilter builds Saturn 2, or Ableton adds new 'analog sounding' filters, or Sylenth is known for it's awesome 'warm' filters, what are they doing beyond what I stated above? Do they focus more on writing more efficient C++ so they can render higher order filters? Do they do something else magical to get a 'warmer' analog sound?

Or am I completely mistaken in my assumption that much of these problems have already been solved and all of these filter designers are designing brand new filters and deriving brand new coefficient equations?

I don't really know anybody else who does this kind of stuff to compare notes with - so would love anybody to comment on their thoughts (or approaches) to this stuff.

Thanks,
EG

Post

First, this book is not great, bad code mainly.

Digital filters are not just IIR filters, that's just a tiny fraction of the world of filters, the ones called LTI. It easier to design them on analog counterparts, because it is quite easy to make them stable as well. You can design them directly in the digital domain (with Remez algorithm for instance), but yes, it is limited.
If you want more, then you will have to use non linear filters. That's where the warmth comes from (even harmonics mainly, odd ones sound metallic).

Post

Hi Matt - thanks for the reply. I think fundamentally as a hobbyist, I'm looking for a structured path to experiment with in this area and I got the impression the LTI/IIR filters were the best first step. But in reality, it look like (at this stage) I just go copy some equations from a book and code them up, which isn't much fun.

I'd much rather have a series of challenges that build on each other as I navigate through filter design. Is there a canonical approach to learning this stuff and/or a suggest path. It would be fun to explore a certain class/type/problem, code it up and test it and then peel the onion back to the next level of interesting exploration.

Would love any suggestions on the right approach to a self defined curriculum for this. I have access to most of the popular books/paper/websites, but really have no clue as to what is practical and useful to build as a beginner. And my only references are the well polished commercial plug-ins from many of the developers here, and those are way to advanced for me right now. Any suggestions?

Post

I'm biaised because I started signal processing when I was a child, so I may not know the best way to do what you are thinking of...
One way is to reuse something existing (may I present my DSP library...), play with the components, and then start implementing your own. For instance, you can start with an EQ that you want to reproduce (analog EQ), and skip all the non linear parts. Then you start integrating them as a post processing stage, and then you design the full circuit with the non linearities as a partial derivative problem and solve it...

Post

eegee, like you said, you can avoid designing a filter in Z-domain by finding transfer function of the system and finally a difference equation (i.e. using bilinear transform). I'm ok with electronics, so I prefer to design filters as circuits and then to discretize them. The "warmth" you are talking about is coming from non-linearity, which means that superposition of input signals is not equivalent to superposition of resulting output signals - that's for example how tube amplifiers work. (I.e. if you have A(t) + B(t) at the input, the output won't be the same as output produced from A(t) plus output from B(t). Unfortunately I don't have knowledge about designing nonlinear filters.

Getting to challenges - If you are familiar with electronics, try finding transfer functions of well known analog circuits, especially filters and discretizing them. Start from something as simple as RC lowpass filter, then bandpass filters etc, then proceed to more complex circuits. You can use tools like wolfram alpha to simplify the transfer function and the resulting z-transform to save yourself from too much algebra. The advantage of bilinear transform is that if you have a stable system in s-domain, it will be also stable in Z-domain. Turn the circuits into FIR filters by applying bilinear transform to the transfer functions you have derived and hear them! Good luck with your endeavours!

Post Reply

Return to “DSP and Plugin Development”