# Design a Filter with Resonance

I want to design a Filter with a variable Cutoff Frequency and Resonance. However in the source I'm using there is a Bi-Quad Filter with two IIR and two FIR Filters designed like this : Furthermore I found that I can compute the coefficients for the different Filter types as stated in this table : Is there a way to alter those coefficients that i can compute the samples with a variant FIlter Resonance?

EDIT Since I'm designing this filter for a software synthesiser, with resonance I mean the typical boost or reduction of the cutoff-frequency in a variable manner. • Can you explain what you mean by "resonance" in this context ? – Paul R Nov 21 '14 at 10:39
• Edited my question. – amaik Nov 21 '14 at 10:48
• Note that a biquad filter simply is a single IIR filter. Do you know the Audio EQ Cookbook? There you'll find formulas for designing biquad filters with different cut-off frequencies and different Qs. See also this related question. – Matt L. Nov 21 '14 at 14:34
• Since you are designing a software synthesizer, I would suggest you look into nonlinear filters modelled after the classic analog synthesizer filters like Moog or Korg. The nonlinearity in the feedback path generating the resonance is the ingredient that gives you that fat resonant (and possibly even self-resonating) sound associated with analog synth filters. High resonance for linear filters will only give you a thin and boring sound, and self oscillation is not possible with a stable IIR filter. – Jazzmaniac Nov 30 '14 at 17:54

First, you need to start with in the s domain where a 2nd order transfer function (2 pole low pass filter) which can be written as follows.

H(s) = s^2 + 2zws + w^2

H(s) = s^2 + 1.414 s + 1

This filter's response and pole locations are shown here. To peak the response, simply modify zeta. Here zeta = 0.17 and omega = 1.

H(s) = s^2 + 0.34 s + 1 Then to move the frequncy, change Omega. Here zeta = 0.17 and omega = 0.39

H(s) = s^2 + 0.1326s + 0.1521 Now all that is left is to determine the z domain coefficients. To do this, use the bilinear transform as shown here. For the the last example I gave, use A=1, B=0.136, C=0.1521, D=E=0, F=1, T=2 to calculate the a's and b's.

See this page for a derivation of the equations given here. Here is a rather simple tool that can generate any 2nd order response you want.

• What is T here? – Dole Dec 18 '19 at 23:26