Pole mixing cancellation redux

Amazing what a good walk will do for your thought processes. I’d hardly set foot on the trail when I realized the pole mixing problem isn’t as serious a problem as I thought.

The thing about the gains depending on the control voltage is they’re correlated. All four gains change about the same amount in the same direction. But since consecutive stages have opposite signs in the pole mixing sums, that means the cancellation errors tend to cancel!

Let’s assume we calibrate all the gains to (negative) unity at some control voltage, and that at some other control voltage they’ve dropped to -0.99. Now, for a 1-pole high pass filter the coefficients are [1, 1, 0, 0, 0] . With -0.99 gains, a 1 V DC amplitude input will result in an output of 1\times1 - 1\times0.99 = 0.01, or 1% DC leakage. Not ideal but we can live with it.

How about a 4-pole HPF? The coefficients are [1, 4, 6, 4, 1] and the output is 1\times1 - 4\times0.99 + 6\times0.99^2 - 4\times0.99^3 + 1\times0.99^4, which \approx 1\times1 - 4\times0.99 + 6\times0.98 - 4\times0.97 + 1\times0.96, which comes out to… zero! No leakage at all!

A 2-pole band pass, [0, 2, 2, 0, 0], would have 2% leakage. But 2- and 3-pole HPF and 4-pole BPF all turn out to have exact cancellation of the errors and zero leakage.

That doesn’t mean there’s no deviation from the shape of a perfect filter with exact unity gain, but the deviations are small. Here, for instance, is a plot of the amplitude for a [0, 0, 4, 8, 4] BPF filter along with ten variants that have uncorrelated 2% errors and ten that have correlated 2% errors.

Amplitude vs. frequency for [0, 0, 4, 8, 4] band pass filter (blue line), ten variants with uncorrelated 2% errors (orange), and ten with correlated 2% errors (green); corner frequency is 1 kHz

The perfect mix is shown in blue. The correlated error curves are the ones in green that drop to -25 to -60 dB at 10 Hz; they’re the kind of thing you could expect with CV-dependent gain changes. The uncorrelated error curves are the ones in orange that fall to between -8 and -30 dB; you’d presumably get something like these if you had perfect gains but mixing resistors with 2% variation from nominal. Which shows that even if the gain changes are at the 2% level, you still want to match the mixing resistors at more like the 0.1% level.

So I think we’re pretty good. There’s still the apparent nonlinearity, with the calculated gains depending on the amplitudes used, but hopefully if you calibrate at a reasonable amplitude it’ll be okay.

Added 23 January 2023: I took another look at the AC coupling of the INPUT signal to the compensation mixer. It’s definitely a good idea. Here’s the INPUT (yellow) and LP4 (blue) signals when INPUT is 0 to +2 V (so is centered around +1 V) and is AC coupled, with the resonance CV turned up:

Notice the white cursor line near the top; that’s at 9 V, which (with Vcc = 12 V) is supposed to be the maximum filter output before clipping. The dashed cursor line is at 0 V and both traces are 2 V per division. The LP4 output is close to the same peak to peak amplitude (I haven’t particularly tuned it), but centered around almost 6 V. When the resonance CV is turned to zero, it doesn’t change much:

But if INPUT is DC coupled (as in the original ED design) and the resonance is turned up, look what happens to the LP4 output:

It’s centered around about 8.5 V. It goes above the 9 V limit!

And that’s with only a 0–2 V INPUT. If it’s 0–5 V and AC coupled it already exceeds the limit:

and DC coupled, well:

So we learn two things. One is a 0–5 V (or ±5 V) INPUT is too big. The design has one input jack with an attenuator but another with none, so I’m thinking of lowering the amplitude in the input section and restoring it in the output. The other is that DC coupling INPUT to the compensation mixer is a disaster when there’s a DC offset on INPUT. In my synth I’m trying to keep all audio signals zero centered, but nevertheless I’m leaving that capacitor in!

Leave a comment