Book: The Art of VA Filter Design 2.1.0

DSP, Plug-in and Host development discussion.
1eqinfinity
KVRist
201 posts since 29 Apr, 2012

Post Tue Jun 12, 2018 6:48 am

Z1202 wrote:It's a bit strange to me that the diode ladder model sounds much better than transistor in your experiments. In my experience it's rather the other way around, although this might be subjective.
Maybe I missed something, have to look closer. But by better I mean given the same overdrive approach (overdriving the input and using transparent waveshapers) one sounds more interesting than the other, and vice versa.

User avatar
aciddose
KVRAF
12054 posts since 7 Dec, 2004

Re: Book: The Art of VA Filter Design 2.0.0alpha

Post Tue Jun 12, 2018 3:12 pm

1eqinfinity wrote:Sure it's different. It may have seemed as if I was drawing a general conclusion, but I was referring to the transistor model actually ;)
This is a general conclusion. You're assuming "this method isn't interesting with respect to X filter type" which is 100% untrue in reality. You're likely drawing your conclusion from an implementation which is incomplete.
Free plug-ins for Windows, MacOS and Linux. Xhip Synthesizer v8.0 and Xhip Effects Bundle v6.7.

1eqinfinity
KVRist
201 posts since 29 Apr, 2012

Re: Book: The Art of VA Filter Design 2.0.0alpha

Post Wed Jun 13, 2018 3:48 am

Ah, I see. You mean that this method can yield interesting results for this filter type if the nonlinearities are implemented differently. Ok, understood.

ncthom
KVRist
34 posts since 1 Mar, 2017 from Boston, MA

Re: Book: The Art of VA Filter Design 2.0.0alpha

Post Wed Jun 20, 2018 11:13 am

Thank you Vadim for the update!

I'd like to ask another quick question on the phaser detailed in Chapter 6. I have a working implementation of the phaser shown in figure 6.4 following from my earlier posts in this thread, and it sounds quite nice. I am noticing, though, that at high feedback values, the filter gain can be pretty intense (both near DC and at the resonant peaks).

Following from section 4.3 about the feedback path in a ladder filter, I expect that I should be able to attenuate the input signal by some factor such that at high feedback values, DC and the resonant peaks stay near a gain of 0dB, but I can't figure that value out. I tried working out the analog transfor function and evaluating it at s = 0, following from the same steps used in section 4.1. I've sort of arbitrarily tried multiplying the input signal by (1 / (1 + k)) as well as (1 - k * A) where A is (2g - 1)^4 from resolving the feedback loop for a series of allpasses, and neither seem appropriate.

For example, here's a quick analysis tapping my filter after the last allpass (cutoff at 440Hz, k = 0.44), before mixing with the dry signal:
Image

Ideally I'd like to find the gain factor that translates that magnitude response down to where the peaks are at 0dB. But I'm not sure where to go from here. How can I derive the appropriate attenuation factor here? Or am I on the wrong approach in general?

Thank you!

Z1202
KVRian
971 posts since 12 Apr, 2002

Re: Book: The Art of VA Filter Design 2.0.0alpha

Post Wed Jun 20, 2018 12:37 pm

ncthom wrote:Ideally I'd like to find the gain factor that translates that magnitude response down to where the peaks are at 0dB.
A hint: look at formula 11.2a. Personally though, I don't like having the peaks at 0dB all the time, since at high resonance the peaks are also very narrow and that may sound like a huge drop in volume. It's a bit tricky, as depending on the input material the peaks may get too loud or the whole thing may get too quiet. So one option would be not to introduce any compensation and leave it to the user to adjust the level to the desired value, but that's really a design decision.

Edit: off the top of my head I'm not sure how the amplitude and phase response should look at the last allpass, but the amplitude response looks to me as if you're having an odd number of stages and the phase response as if you're having an even number of stages. As I said, I'm not 100% sure, but it looks suspicious.

ncthom
KVRist
34 posts since 1 Mar, 2017 from Boston, MA

Re: Book: The Art of VA Filter Design 2.0.0alpha

Post Thu Jun 21, 2018 5:54 am

Oh boy, I hadn't given the 2.0.0 update a good look yet, I was still working off of the previous version of the book. This expanded chapter is amazing, the answer's right there :) Thank you!!

Quick note: Found a typo in Section 11.5 at the end of page 487: "the amplitude response are lcoated at frequencies"

And yes, you're right, I found a silly off-by-one error in the feedback loop calculation that led to those graphs.

User avatar
Ichad.c
KVRian
1049 posts since 8 Feb, 2012 from South - Africa

Re: Book: The Art of VA Filter Design 2.0.0alpha

Post Thu Jun 21, 2018 8:36 am

Z1202 wrote: Edit: off the top of my head I'm not sure how the amplitude and phase response should look at the last allpass, but the amplitude response looks to me as if you're having an odd number of stages and the phase response as if you're having an even number of stages. As I said, I'm not 100% sure, but it looks suspicious.
A typical analog phaser has equal stages but the feedback is around an unequal number of stages. Of about 20 or so phaser schematics I skimmed over at one stage, 95% follow that pattern to some extent. Equal stage feedback seems to be more common in digital, not that that makes it wrong in any way, just different. I do agree that the peaks don't sound great when kept at 0dB all the time, the overall level is a bit of a fudge-factor in practice.

Nice feedback example:

https://www.electrosmash.com/mxr-phase90

Z1202
KVRian
971 posts since 12 Apr, 2002

Re: Book: The Art of VA Filter Design 2.0.0alpha

Post Thu Jun 21, 2018 9:48 am

Ichad.c wrote:
Z1202 wrote: Edit: off the top of my head I'm not sure how the amplitude and phase response should look at the last allpass, but the amplitude response looks to me as if you're having an odd number of stages and the phase response as if you're having an even number of stages. As I said, I'm not 100% sure, but it looks suspicious.
A typical analog phaser has equal stages but the feedback is around an unequal number of stages. Of about 20 or so phaser schematics I skimmed over at one stage, 95% follow that pattern to some extent. Equal stage feedback seems to be more common in digital, not that that makes it wrong in any way, just different. I do agree that the peaks don't sound great when kept at 0dB all the time, the overall level is a bit of a fudge-factor in practice.

Nice feedback example:

https://www.electrosmash.com/mxr-phase90
That's a good remark. Although I'm not sure if it's really that typical (IIRC e.g. for mxr these are mods rather than original versions, but I might be wrong), it does result in interesting sound. I wanted to mention this in the book, but somehow forgot to ;)

However, as for the graphs, it seemed suspicious to me that the phase response went over a multiple of 360 degrees, while the amplitude response at infinity was the "opposite" of the one at DC, which hinted at a possible inconsistency (although as I said I'm not sure if that's really impossible for certain values of the feedback amount). I don't think that depends on a mismatch between feedback and feedforward path orders.

User avatar
Ichad.c
KVRian
1049 posts since 8 Feb, 2012 from South - Africa

Re: Book: The Art of VA Filter Design 2.0.0alpha

Post Fri Jun 22, 2018 11:32 pm

Z1202 wrote:
Ichad.c wrote:
Z1202 wrote: Edit: off the top of my head I'm not sure how the amplitude and phase response should look at the last allpass, but the amplitude response looks to me as if you're having an odd number of stages and the phase response as if you're having an even number of stages. As I said, I'm not 100% sure, but it looks suspicious.
A typical analog phaser has equal stages but the feedback is around an unequal number of stages. Of about 20 or so phaser schematics I skimmed over at one stage, 95% follow that pattern to some extent. Equal stage feedback seems to be more common in digital, not that that makes it wrong in any way, just different. I do agree that the peaks don't sound great when kept at 0dB all the time, the overall level is a bit of a fudge-factor in practice.

Nice feedback example:

https://www.electrosmash.com/mxr-phase90
That's a good remark. Although I'm not sure if it's really that typical (IIRC e.g. for mxr these are mods rather than original versions, but I might be wrong), it does result in interesting sound. I wanted to mention this in the book, but somehow forgot to ;)
Those are all original versions(revisions), not DIY mods. The Phase90 is one of the top 3 most famous phasers of all time, personally I would say it is the most famous pedal due to Pink Floyd and van Halen, the only other one that comes close to its pedigree is the Smallstone. It has been mostly in production for the past 44 years, modifications/revisions were made through the years, due to user requests, parts becoming obsolete and modern manufacturing techniques, the Smallstone has a similar amount of revisions. So I would say that feedback around unequal stages is a classic sound ;-)

P.S. I think the prevalence of unequal stage feedback is simply due to a lot of phasers being built with inverting opamp allpasses like the Phase90, transistor(Univibe) and OTA(Smallstone) are more rare. The Smallstone is equal stage feedback btw. Something like the Ross Flanger(1979), inverting opamp, has 5 stages with global feedback but the output is taken by the 4th stage. Phasers are fun!

neotec
KVRist
239 posts since 22 Jan, 2007 from Germany

Re: Book: The Art of VA Filter Design 2.0.0alpha

Post Mon Jul 09, 2018 1:28 pm

OT @Vadim I just stumbled upon your v2 ... will have to read it tonight or tomorrow. Oh, and if you want to credit me using my real name, it's 'René Jeschke'. :-)

And an idea: a filter structure that I missed in your first version is a Linkwitz-Riley crossover SVF filter. It's basically #order integrators where each feeds back into the input. The cool thing is, you can just plug in any analogue 's'-domain coeffs into the feedback paths and realize any transfer function. They are basically my go-to filters for everything. See https://www.rane.com/pdf/linriley.pdf and http://jahonen.kapsi.fi/Audio/Papers/Statevariable.pdf for the analogue explanation. This can be transferred to digital using TPT just like the schematics show. Dunno if this is of any interest.

The feedback path looks like this (from my Java prototyping library, getS() returns the 'state', getF() returns, I think you called it 'G' in your book). It calculates the (parallel) feedback for n-integrators using the LR-SVF topology. I.e. having 4 units, setting `double[] r = {4, 6, 4, 1 + q}` realizes a simple ladder filter. Each integrator's output is then s^3 down to 1, with s^4 resulting from the feedback. Pretty neat thing IMHO.

Code: Select all

public static double zdfFeedbackP(ZDFUnit[] units, double[] r, double input)
{
  double s = 0, f = 0;
  double st = 0, ft = 1;
  for (int i = 0; i < units.length; i++)
  {
    double fi = units[i].getF();
    double fs = units[i].getS();
    st = st * fi + fs;
    ft *= fi;
    s += st * r[i];
    f += ft * r[i];
  }
  return (s + f * input) / (1 + f);
  // or, as usual (input - s) / (1 + f) for directly getting the high-pass output
}
... when time becomes a loop ...
---
Intel i7 3770k @3.5GHz, 16GB RAM, Windows 7 / Ubuntu 16.04, Cubase Artist, Reaktor 6, Superior Drummer 3, M-Audio Audiophile 2496, Akai MPK-249, Roland TD-11KV+

Z1202
KVRian
971 posts since 12 Apr, 2002

Re: Book: The Art of VA Filter Design 2.0.0alpha

Post Mon Jul 09, 2018 9:21 pm

neotec wrote:OT @Vadim I just stumbled upon your v2 ... will have to read it tonight or tomorrow. Oh, and if you want to credit me using my real name, it's 'René Jeschke'. :-)
I will in the next update :wink:
neotec wrote:And an idea: a filter structure that I missed in your first version is a Linkwitz-Riley crossover SVF filter. It's basically #order integrators where each feeds back into the input. The cool thing is, you can just plug in any analogue 's'-domain coeffs into the feedback paths and realize any transfer function.
They are covered in rev 2 (p.271). I'm not sure if they have a clear official name though. I guess the closest to the "official name" is "controllable canonical form".

Z1202
KVRian
971 posts since 12 Apr, 2002

Re: Book: The Art of VA Filter Design 2.0.0alpha

Post Tue Oct 30, 2018 7:56 am

The book has been updated to 2.1.0
http://www.native-instruments.com/filea ... _2.1.0.pdf

Just little additions:
- Generalized ladder filters
- Elliptic filters of order 2^N
- Steepness estimation of elliptic shelving filters

Z1202 wrote:
Mon Jul 09, 2018 9:21 pm
neotec wrote:OT @Vadim I just stumbled upon your v2 ... will have to read it tonight or tomorrow. Oh, and if you want to credit me using my real name, it's 'René Jeschke'. :-)
I will in the next update :wink:
Done :wink:

Edit: while we're on the subject, this talk is covering some of the book's materials on a qualitative level:
https://www.youtube.com/watch?v=0pAxQIUGT4w

User avatar
discoDSP
KVRAF
3716 posts since 18 Jul, 2002

Re: Book: The Art of VA Filter Design 2.1.0

Post Tue Oct 30, 2018 7:59 am

discoDSP Plug-Ins | Synths | Sampler | Effects

Z1202
KVRian
971 posts since 12 Apr, 2002

Re: Book: The Art of VA Filter Design 2.1.0

Post Tue Oct 30, 2018 8:02 am

discoDSP wrote:
Tue Oct 30, 2018 7:59 am
Amazing work! :tu: Mirror at https://www.discodsp.net/VAFilterDesign_2.1.0.pdf
Thanks for mirroring! The link updated.

User avatar
discoDSP
KVRAF
3716 posts since 18 Jul, 2002

Re: Book: The Art of VA Filter Design 2.1.0

Post Tue Oct 30, 2018 8:05 am

My pleasure :)
discoDSP Plug-Ins | Synths | Sampler | Effects

Return to “DSP and Plug-in Development”