Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

There are 5 coefficients that the user must set: b0, b1, b2, a1, and a2 (a0 is always assumed to be 1). Audio Weaver does not check for stability and care must be used when computing the filter coefficients. There are several variants of Biquad filters. The simples – Biquad – has a single stage and implements the different equation shown above. BiquadCascade implements N stages of filtering with each channel using the same coefficients. BiquadNCascade implements N stages with each channel have its own set of coefficients. Finally, BiquadSmoothed implements a single Biquad stage with coefficient smoothing on a block-by-block basis.

 

Image RemovedImage Added

FIR

 

Time domain FIR filter

Specify filter length in module properties

Image RemovedImage Added

Biquad

 

Second order IIR filter.

5 filter coefficients are specified.

No smoothing.

Image RemovedImage Added

BiquadCascade

 

Multiple Biquad filters in series.

The number of filters is specified in module properties.

The same coefficients are used per channel.

Image RemovedImage Added

BiquadSmoothed

 

Second order IIR filter.

5 filter coefficients are specified.

Smoothed on a block-by-block basis

Image RemovedImage Added

BiquadNCascade

 

Multiple Biquad filters in series.

The number of filters is specified in module properties.

Different coefficients are used per channel.

Image RemovedImage Added

FIR Sparse

 

Sparse FIR filter in which most values are zero.

Less convolution cycles than normal FIR

Image RemovedImage Added

FIR Sparse Reader

 

Sparse FIR that connects to a delay state writer.

Convolution is based on a pointer rather than a separate FIR buffer.

 

Image RemovedImage Added

FIR Sparse Reader Fract16

 

Like FIR Sparse Reader except half the memory.

Data is converted to fract16 for computations and has a conversion for the output if necessary.

...

The High Precision modules are designed to be drop in replacements for the non-high precision filters. That way, numerical problems can be resolved by replacing the offending filter with its high precision version.

Image RemovedImage Added

BiqudSmoothedHP

Smoothly varying Biquad

Image RemovedImage Added

ButterworthFilterHP

Butterworth lowpass, highpass, and allpass filters

Image RemovedImage Added

BiquadCascadeHP

Cascade of N Biquad stages

Image RemovedImage Added

GraphicEQBandHP

Single band of a graphic equalizer

Image RemovedImage Added

SOFControlHP

Controllable second order filter with design equations

Image RemovedImage Added

SOFCascadeHP

Cascade of second order filters each with design equations

Image RemovedImage Added

SecondOrderFilterHP

Single second order filter with design equations

Image RemovedImage Added

VolumeControlHP

Fletcher Munson volume control with loudness compensation

...

The crossover filter module (XoverNway) is actually a subsystem consisting of multiple individual modules. The module properties give the option to construct the crossover using standard Biquads or high precision Biquads:

...

The graphic equalizer gives the option of using standard precision or high precision filters.

Here is an example of the benefits of the high precision filter. The system in the example has a peaking filter at 20 Hz with a gain of 6 dB and a Q of 2 and operates at a 48 kHz sample rate. The total harmonic distortion and noise (THD+N) for different input frequencies is plotted below. First for standard Biquad filters

...

And now with a high precision filter, notice that the noise floor is reduced significantly – by up to 90 dB at low frequencies.

...

For the interested reader, this measurement is performed by passing sine waves of different frequencies through the filter. Apply a notch filter at the output which removes the sine wave and then measure the RMS energy in the residual. This residual energy equals the THD+N. The measurement is repeated for many different frequencies and the plot reflects the measured THD+N at each input frequency. 

Common Filter Modules

The following filters are found as modules with no folder in the Filters directory. This is because they are the most common types of filters, which cover most general cases of filtering needs.

ButterworthFilter

This module implements lowpass, highpass, or allpass filters using a Butterworth design. The filters have a gain of 0 dB in the passband and are then monotonically decreasing in the stopband. The filter order is specified under module properties and ranges from 1st order (6dB/octave) to 10th order (60dB/octave). The filter order can only be changed in Design mode. Specify the filter type on the inspector (lowpass, highpass, or allpass) as well as the cutoff frequency, in Hz. Since these parameters are on the inspector, the filter type and cutoff frequency can be changed at run-time. Unfortunately, the ButterworthFilter does not have coefficient smoothing and there may be discontinuities when coefficients are updated.

Figure 3 - Butterworth lowpass filter frequency response as a function of filter order. The filter order goes from 1st order (least steep line) to 10th order (steepest line). The cutoff frequency is 100 Hz and the sample rate is 48 kHz

Figure 4 - Butterworth high filter frequency response as a function of filter order. The filter order goes from 1st order (least steep line) to 10th order (steepest line). The cutoff frequency is 100 Hz and the sample rate is 48 kHz

SecondOrderFilterSmoothed

This module is the most frequently used filter among all of the

...

SecondOrderFilterSmoothed

This module is the most frequently used filter among all of the Audio Weaver modules. It implements a 2nd order Biquad filter and includes design equations for 20 different filter types. The filter type and high-level design parameters (frequency, gain, and Q) can be changed at run-time using the inspector:

 

...

Depending on the filter type, some parameters are not used. See the table below for the filter types available and which control parameters are applicable.

Pass Through

filterType = 0

 

Applicable parameters: none.

 

Biquad coefficients are set to b0=1, b1=0, b2=0, a1=0, and a2=0. The filter runs and consumes processing but the output equals the input.

 

Image Added

 

Gain

filterType = 1

 

Applicable parameters: gain

 

A simple gain with coefficients set to b0=undb20(gain), b1=0, b2=0, a1=0, and a2=0

Image Added

1st order Butterworth lowpass filter

filterType = 2

 

Applicable parameters: freq

Image Added

2nd order Butterworth lowpass

filterType = 3

 

Applicable parameters: freq

Image Added

1st order Butterworth highpass

filterType = 4

 

Applicable parameters: freq

Image Added

2nd order Butterworth highpass

filterType = 5

 

Applicable parameters: freq

Image Added

1st order allpass

filterType = 6

 

Applicable parameters: freq

Image Added

2nd order allpass

filterType = 7

 

Applicable parameters: freq and Q

Image Added

2nd order low shelf

filterType = 8

 

Applicable parameters: freq and gain

 

 Use as a low frequency tone control

Image Added

2nd order low shelf with Q

filterType = 9

 

Applicable parameters: freq, gain, and Q

Image Added

2nd order high shelf

filterType = 10

 

Applicable parameters: freq and gain

 

Use as a high frequency tone control

 

Image Added

2nd order high shelf with Q

filterType = 11

 

Applicable parameters: freq, gain, and Q

Image Added

2nd order peaking / parametric

filterType = 12

 

Applicable parameters: freq, gain, and Q

 

Commonly used for generic equalization since it has controllable frequency, gain, and Q settings. 

Image Added

2nd order notch

filterType = 13

 

Applicable parameters: freq and Q

Image Added

2nd order bandpass filter

filterType = 14

 

Applicable parameters: freq and Q

Image Added

1st order Bessel lowpass filter

filterType = 15

 

Applicable parameters: freq

Image Added

1st order Bessel highpass filter

filterType = 16

 

Applicable parameters: freq

1st order asymmetrical low shelf

filterType = 17

 

Applicable parameters: freq and gain

1st order asymmetrical high shelf

filterType = 18

 

Applicable parameters: freq and gain

1st order symmetrical low shelf

filterType = 19

 

Applicable parameters: freq and gain

1st order symmetrical high shelf

filterType = 20

 

Applicable parameters: freq and gain

...