# All About Audio Equalization: Solutions and Frontiers
## 3 Parametric Equalizers
### Second Order Shelving Filters  
Here, we show a technique to design a second order low shelving filter, which is often used in parametric equalizer design [19; 28; 31; 32; 35]. The design method differs slightly from the approach for first order design since the lowpass to lowpass transformation is performed in the s domain, to keep the maths slightly simpler. The transfer function of a second order analog shelving filter with crossover frequency \(f_{\text{c}}\) is given by [3],  
\[H_{\text{LS,1}}(s)=\frac{s^{2}+\sqrt{2G}\omega_{0}s+G\omega_{0} ^{2}}{s^{2}+\sqrt{2}\omega_{0}s+\omega_{0}^{2}}, \tag{12}\]  
where \(s=j\omega,\omega_{0}=2\pi f_{\text{c}}\), and \(G\) is the gain at DC (\(\omega=0\)). Note that if the \(\sqrt{2}\) in the numerator and denominator of Equation (12) is replaced with a larger number, then resonant low shelving filters are produced, which have a bump in the magnitude response before the roll-off. The square magnitude of this filter is  
\[|H_{\text{LS,1}}(s)|^{2}=\frac{G^{2}\omega_{0}^{4}+\omega^{4}}{ \omega_{0}^{4}+\omega^{4}}, \tag{13}\]  
so that the square magnitude at the crossover frequency is equal to the arithmetic mean of the square magnitudes at \(\omega=0\) and \(\omega=\infty\). However, as discussed in Section 3.1 generally this is not what is wanted. To correct this, we need to find the frequency where the low shelf's square magnitude is the geometric mean of 1 and \(G^{2}\), which is \(G\). So we solve  
\[G=|H_{\text{LS,1}}(s)|^{2}=\frac{G^{2}\omega_{0}^{4}+\omega^{4} }{\omega_{0}^{4}+\omega^{4}}\rightarrow\omega=G^{1/4}\omega_{0}. \tag{14}\]  
So make the replacement \(\omega\to G^{1/4}\omega\) in the low shelf filter, to create a new low shelf \(H_{\text{LS,2}}(s)\). That way, \(|H_{\text{LS,2}}(\omega_{0})|^{2}=|H_{\text{LS,1}}(G^{1/4}\omega_{0})|^{2}=G\). This results in  
Figure 2: Magnitude responses of a low (blue) and high (red) shelf filter with a 12-dB gain and 1-kHz crossover frequency, and the cascade of the two filters (black). \[H_{\text{LS},2}(s)=\frac{\left(G^{1/4}s\right)^{2}+\sqrt{2G}\omega_{0}(G^{1/4}s)+G \omega_{0}{}^{2}}{\left(G^{1/4}s\right)^{2}+\sqrt{2}\omega_{0}(G^{1/4}s)+\omega_ {0}{}^{2}}=\frac{s^{2}+\sqrt{2}\omega_{0}G^{1/4}s+G^{1/2}\omega_{0}{}^{2}}{s^{ 2}+\sqrt{2}\omega_{0}G^{-1/4}s+G^{-1/2}\omega_{0}{}^{2}}\;. \tag{15}\]  
To convert to the digital domain, we use the bilinear transform. We make the following substitutions  
\[s=\frac{z-1}{z+1},\omega_{0}\rightarrow\Omega=\tan(\omega_{\text{c}}/2), \tag{16}\]  
So  
\[H_{\text{LS}}(z)= \frac{\left(\frac{z-1}{z+1}\right)^{2}+\sqrt{2}\Omega G^{1/4} \left(\frac{z-1}{z+1}\right)+G^{1/2}\Omega^{2}}{\left(\frac{z-1}{z+1}\right)^ {2}+\sqrt{2}\Omega G^{-1/4}\left(\frac{z-1}{z+1}\right)+G^{-1/2}\Omega^{2}} \tag{17}\] \[= G^{1/2}\frac{G^{1/2}\Omega^{2}+\sqrt{2}\Omega G^{1/4}+1+2(G^{1/ 2}\Omega^{2}-1)z^{-1}+(G^{1/2}\Omega^{2}-\sqrt{2}\Omega G^{1/4}+1)z^{-2}}{G^{1 /2}+\sqrt{2}\Omega G^{1/4}+\Omega^{2}+2(\Omega^{2}-G^{1/2})z^{-1}+(G^{1/2}- \sqrt{2}\Omega G^{1/4}+\Omega^{2})z^{-2}}, \tag{18}\]  
which satisfies all the conditions for the desired low shelving filter. The second order high shelving filter can be derived in the same way, and as with first order shelving filter designs, is equal to the gain \(G\) times the reciprocal of the second order low shelving filter:  
\[H_{\text{HS}}(z) =G^{1/2}\frac{G^{1/2}+\sqrt{2}\Omega G^{1/4}+\Omega^{2}-2[G^{1/2} -\Omega^{2}]z^{-1}+(G^{1/2}-\sqrt{2}\Omega G^{1/4}+\Omega^{2})z^{-2}}{G^{1/2} \Omega^{2}+\sqrt{2}\Omega G^{1/4}+1+2[G^{1/2}\Omega^{2}-1]z^{-1}+(G^{1/2} \Omega^{2}-\sqrt{2}\Omega G^{1/4}+1)z^{-2}} \tag{19}\] \[=G/H_{\text{LS}}(z). \tag{20}\]  
\[|H_{\text{LS,1}}(s)|^{2}=\frac{G^{2}\omega_{0}^{4}+\omega^{4}}{ \omega_{0}^{4}+\omega^{4}}, \tag{13}\]0 Magnitude responses of second order low shelving filters with complementary gains: \(\pm 12\) dB (green), \(\pm 8\) dB (blue), and \(\pm 4\) dB (red). The vertical dashed line indicates the crossover frequency (1 kHz). Cf.