An improved design method for the third-octave GEQ using symmetric band filters, called SGE3, is proposed in this section. Furthermore, similar design methods are used to provide a design for a novel Bark band GEQ (SGEB). In the proposed GEQ designs, the band filters have a symmetric magnitude response on the logarithmic frequency scale, as suggested in [
22]. This symmetry affects primarily the shape of the band filter magnitude response at high frequencies, which allows the band filters to have a specific gain at the Nyquist limit. In our previous GEQ designs, the Nyquist gain of the band filters was 1.0, i.e., 0 dB, which forced some of the band filters to have a very asymmetric magnitude-response peak [
3,
6].
The design formulas for the symmetric band filters were obtained by modifying those suggested by Orfanidis [
31] so that the filter gain at DC (i.e., 0 Hz) was unity and the gain
at the Nyquist limit was adjustable instead of prescribed based on the analog filter counterpart [
22,
31]. The transfer function of the resulting second-order band filter, implemented with the structure in
Figure 2, is:
where
. For the third-octave design
, and for the Bark design
. The filter coefficients are calculated as:
using the following variables:
The following variables are also used to simplify the above formulas:
where
is the linear peak gain of the filter,
is the gain of the filter at the bandwidth boundaries,
is the bandwidth,
is the center frequency, and
kHz is the sampling rate. The linear filter gains
are obtained by converting the optimized dB gains
to linear gain factors:
The Nyquist gain for each band filter was calculated with the help of a sufficiently highly oversampled parametric EQ filter emulating the shape of an analog filter, as proposed in [
22]. The sample rate was set to 10 MHz, and the filter gain was evaluated at 22.05 kHz, which was the Nyquist limit
at the sample rate of 44.1 kHz. The gain estimated this way was used as the Nyquist gain
of the band filter. A polynomial approximation for the dependency of the Nyquist gain could be used to simplify the design of the symmetric band filters [
22]. Thus, the oversampling method for the Nyquist gain was used only to determine the required polynomial coefficients.
3.1. Third-Octave GEQ using Symmetric Band Filters
The used third-octave center frequencies (spaced equidistantly on a logarithmic scale starting from 1 kHz in each direction) and the optimized bandwidths leading to the best overall performance of the GEQ are shown in
Table 1. The nominal bandwidths for the proposed third-octave equalizer were obtained with
so that the boundaries of the bands coincided with the center frequencies of the neighboring bands. However, the bandwidths marked with an asterisk in
Table 1 were modified from the nominal values in order to account for the frequency warping near the Nyquist limit. The modifications resulted in optimized bandwidths with regard to target magnitude shapes obtained with oversampling. The resulting band filter shapes are seen in
Figure 4a, where the squares indicate the gain at the bandwidth boundaries as specified by the parameter
c.
Appropriate parameter values must be selected for the WLS design to be accurate. These are the number of iterations, the prototype gain used to obtain the initial interaction matrix
, the parameter
c defining the gain at the bandwidth boundaries, and the weighting factors for each band [
3,
6,
22]. The value for each of these parameters was chosen jointly with an optimization loop in MATLAB. For the optimization, 8192 command gain configurations were applied: half of these were random extreme gain settings with each command gain being zero or ±12 dB, and the other half were random settings, where the command gains were integers in the range [−12 12]. Different parameter combinations were used to design a GEQ for each command gain configuration, and the maximum approximation error was calculated (see
Section 5 for the error definition). Next, the maximum value and the mean of the maximum errors were computed for each setting combination, as also the number of cases where the error exceeded the allowed error of ±1 dB. Finally, the optimal parameter values were selected based on the best obtained results, giving more weight to the random integer cases than to the extreme command gain configuration.
Based on the parameter optimization, the number of iterations was set to one; the prototype gain was set to 11 dB; the band-boundary parameter was set to
; but no weighting factors were used, i.e., the weight for all bands was one. The value for the parameter
c was reduced slightly compared to the third-octave GEQ in [
3], which resulted in narrower peak filters. The widths of the filters were a compromise between their ability to produce flat regions in their magnitude response and, on the other hand, large gain changes between neighboring bands. The prototype gain was used to calculate the initial interaction matrix, and since the prototype gain was predefined, the initial interaction matrix could be calculated beforehand and stored [
6].
The value of the prototype gain was not as crucial here as, for example, in [
22], where no iterative step was used. Due to the iterative step, where a new interaction matrix was determined based on the first set of optimized filter gains, the initial WLS solution could be seen as a frequency-dependent, improved prototype gain vector. The first iterative step had the biggest effect on the optimized gains [
3], and thus, it was useful in improving the accuracy of the GEQ. However, during the optimization, further iterative steps, while improving the accuracy in certain cases, actually decreased the accuracy overall. This might be because there were only 61 design points in the entire audible frequency range, in which case, the WLS solution optimized these points while simultaneously neglecting the frequency areas between them.
For the third-octave design, the magnitude response of the first 22 band filters always stayed at approximately 0 dB at the Nyquist limit, whereas the remaining band filters benefited from adjusting the gain
as a function of the peak gain
, as seen in
Figure 5a. The polynomial approximation utilized third-order polynomials for bands
:
The polynomial coefficients
, obtained for each band filter using curve fitting in MATLAB, are shown in
Table 2. This way, the peak dB gain
was the only parameter that had to be provided when designing the band filters for the SGE3 design. Note that the coefficients
and
were always zero, since the values given by the curve fitting were so small that they could be rounded to zero. The polynomial approximation produced accurate results compared to the targets shown in
Figure 5a, with the maximum error being
dB for the 31st band and less than
dB for the other bands.
3.2. Bark Band Equalizer
This section tackles the design of a GEQ with a Bark frequency division of bands using symmetric band filters. The design principles were primarily the same as in the third-octave design above, with a few modifications. The main challenge of the Bark GEQ design was the fact that the Bark center frequencies were not equidistantly spaced on the logarithmic frequency scale, as was the case with octave and third-octave designs.
Figure 6 illustrates this difference by showing the center frequency of each band on a logarithmic frequency scale.
Figure 6a shows that the third-octave center frequencies were located on a straight line, whereas in
Figure 6b, the Bark center frequencies formed a nonlinear curve. The numerical data for these plots are given in
Table 1 and
Table 3.
In addition to the Bark center frequencies,
Table 3 gives the bandwidths selected for the band filters. Note that while the center frequencies were selected according to the standard definition [
23], the bandwidths were not. This was due to the nature of the least-squares GEQ design: by choosing the bandwidths in
Table 3, the user could control the GEQ at the Bark center frequencies to obtain greater overall accuracy. For best accuracy, the band filter’s right bandwidth boundaries had to coincide with the center frequency of the adjacent band filter. This was achieved by setting the bandwidths of the first 23 bands to
. Since this method could not be applied to the last band filter, its left edge was matched with the center frequency of the penultimate band filter. The resulting band filter responses are shown in
Figure 4b.
The Bark EQ design utilized the same filters as the third-octave EQ, and thus, the values for the same parameters had to be optimally chosen. Since the uneven spacing of the Bark center frequencies required the band filters of the GEQ to have different bandwidths, a consequent implication was that the parameter c had to be frequency dependent. Additionally, this complication led to more iteration rounds, a different initial prototype gain, and a non-constant weighting matrix for good accuracy. The parameter optimization was performed in the same way as in the third-octave case above. The only difference was that instead of 4096 random extreme cases (command gains at zero or ±12 dB), only 2048 such gain configurations were used since the results from the random integer gain configurations were eventually emphasized.
Based on the optimization, the parameter
c was set to
for the first band and to
for bands 2–24. This way, the leakage of the relatively wide first band filter to its neighboring bands was better controlled. An additional step to improve the accuracy of the Bark GEQ at low frequencies applied frequency-dependent weighting values to the WLS solution. The best accuracy, from among the many choices tested, was achieved when the weighting matrix in (
3) was:
Finally, the Bark EQ design used two iteration steps. The initial interaction matrix was first constructed with a prototype gain of 1 dB, after which (
3) was calculated thrice: the interaction matrix for the second and third iteration rounds was obtained using the optimized gains from the first and second WLS solution, respectively. The final solution yielded the optimized band filter dB gains that were then converted to linear gain factors that were used to update the band filter coefficients.
Similarly to the third-octave case, the filter design required the Nyquist gain. In order to have the filter peak gain as the sole input (since the center frequencies and bandwidths were set constants), the Nyquist gain was again approximated with a third-order polynomial based on the peak gain (see (
16)). Excessively oversampled versions of the Bark band filters were designed, and their responses were evaluated at 22.05 kHz in order to obtain the necessary data for MATLAB’s curve fitting tool. The Nyquist gains of the first 18 bands were observed to be always approximately zero and thus did not need to be changed. The Nyquist gain relative to the peak gain of bands 19–24, however, were approximated: their target shapes are shown in
Figure 5b, and the corresponding polynomial coefficients are given in
Table 4. Note that similarly to the third-octave case, coefficients
and
were zero for all filters. For the Bark EQ, the polynomial approximation of the Nyquist gains was highly accurate with the error being less than
dB for all bands in comparison to the target curves in
Figure 5b.