Main Content

Multiband Parametric EQ

Multiband parametric equalizer

Since R2021b

  • Multiband Parametric EQ block

Libraries:
Audio Toolbox / Filters

Description

The Multiband Parametric EQ block performs multiband parametric equalization independently across each channel of input using specified center frequencies, gains, and quality factors. You can configure this block with up to 10 bands. You can add low-shelf and high-shelf filters as well as highpass (low-cut) and lowpass (high-cut) filters.

Examples

Ports

Input

expand all

Audio input to the equalizer, specified as one of the following:

  • Matrix input –– The block treats each column of the input as an independent channel.

  • Vector input –– The block treats the input as having a single channel.

Data Types: single | double

Output

expand all

Audio output from the equalizer, returned as a matrix. If you specify the input as a matrix, the block returns the output with the same size as matrix input. If you specify the input as a vector then the output is N-by-1 matrix.

Data Types: single | double

Parameters

expand all

Main

Order of individual equalizer bands, specified as an even positive integer. All equalizer bands have the same order.

Number of equalizer bands, specified as an integer in the range [1,10]. The number of equalizer bands does not include shelving filters, highpass filters, or lowpass filters.

Select this parameter to specify frequencies from the input port.

Center frequencies of equalizer bands in Hz, specified as a row vector of length equal to Number of bands. The vector consists of real scalars in the range 0 to Input sample rate (Hz)/2.

Tunable: Yes

Dependencies

To enable this parameter, set Specify input frequencies from input port to off.

Select this parameter to specify peak gains from input port.

Peak or dip filter gains, specified as a row vector of length equal to Number of bands in dB. The vector consists of real scalars in the range [–inf,20].

Tunable: Yes

Dependencies

To enable this parameter, set Specify peak gains from input port to off.

Select this parameter to specify quality factors from the input port.

Quality factors of equalizer bands, specified as a row vector of length equal to Number of bands.

Tunable: Yes

Dependencies

To enable this parameter, set Specify quality factor from input port to off.

Select this parameter to specify sample rate from the input port.

Input sample rate, specified as a positive scalar in Hz.

Tunable: Yes

Dependencies

To enable this parameter, set Inherit sample rate from input port to off.

This button plots the filter responses of low-shelf, high-shelf, highpass (low-cut), and lowpass (high-cut) filters in a magnitude (dB) vs. frequencies (Hz) plot.

Note

The block does not support filter visualization if any parameters are specified from input ports or the sample rate is inherited.

Name of the variable in the base workspace to contain the filter when it is exported. The name must be a valid MATLAB® variable name.

When you select this parameter, exporting the filter overwrites the variable specified by the Variable name parameter if it already exists in the base workspace. If you do not select this parameter and the specified variable already exists in the workspace, exporting the filter creates a new variable with an underscore and a number appended to the variable name. For example, if the variable name is var and it already exists, the exported variable will be named var_1.

Export the filter to the base workspace in the variable specified by the Variable name parameter.

Tips

  • You cannot export the filter if you have enabled the Inherit sample rate from input parameter and the model is not running.

  • You cannot export the filter if you are specifying filter characteristics from input ports.

Advanced

Select this parameter to add a low-shelf filter to your equalizer.

Select this parameter to specify the cutoff frequency of the low-shelf filter from the input port.

Dependencies

To enable this parameter, set Add low-shelf filter to on.

The cutoff frequency of the low-shelf filter, specified as a scalar greater than or equal to 0 in Hz.

Tunable: Yes

Dependencies

To enable this parameter, set Add low-shelf filter to on and Specify low-shelf cutoff from input port to off.

Select this parameter to specify low-shelf slope from the input port.

Dependencies

To enable this parameter, set Add low-shelf filter to on.

The slope of the low-shelf filter, specified as a positive scalar.

Tunable: Yes

Dependencies

To enable this parameter, set Add low-shelf filter to on and Specify low-shelf slope from input port to off.

Select this parameter to specify the gain of the low-shelf filter from the input port.

Dependencies

To enable this parameter, set Add low-shelf filter to on.

The gain of the low-shelf filter, specified as a real scalar.

Tunable: Yes

Dependencies

To enable this parameter, set Add low-shelf filter to on and Specify low-shelf gain from input port to off.

Select this parameter to add a high-shelf filter to your equalizer.

Select this parameter to specify the cutoff frequency of the high-shelf filter from the input port.

Dependencies

To enable this parameter, set Add high-shelf filter to on.

The cutoff frequency of the high-shelf filter, specified as a scalar greater than or equal to 0 in Hz.

Tunable: Yes

Dependencies

To enable this parameter, set Add high-shelf filter to on and Specify high-shelf cutoff from input port to off.

Select this parameter to specify the slope of the high-shelf filter from the input port.

Dependencies

To enable this parameter, set Add high-shelf filter to on.

The slope of the high-shelf filter, specified as a positive scalar.

Tunable: Yes

Dependencies

To enable this parameter, set Add high-shelf filter to on and Specify high-shelf slope from input port to off.

Select this parameter to specify the gain of the high-shelf filter from the input port.

Dependencies

To enable this parameter, set Add high-shelf filter to on.

The gain of the high-shelf filter, specified as a real scalar.

Tunable: Yes

Dependencies

To enable this parameter, set Add high-shelf filter to on and Specify high-shelf gain from input port to off.

Select this parameter to add a lowpass filter to your equalizer.

Select this parameter to specify the cutoff frequency of the lowpass filter from the input port.

Dependencies

To enable this parameter, set Add lowpass filter to on.

The cutoff frequency of the lowpass filter, specified as a scalar greater than or equal to 0 in Hz.

Tunable: Yes

Dependencies

To enable this parameter, set Add lowpass filter to on and Specify lowpass cutoff from input port to off.

Select this parameter to specify the slope of the lowpass filter from the input port.

Dependencies

To enable this parameter, set Add lowpass filter to on.

The slope of the lowpass filter, specified as a real scalar in the range [0:6:48] in dB/octave. Values that are not multiples of 6 are rounded to the nearest multiple of 6.

Tunable: Yes

Dependencies

To enable this parameter, set Add lowpass filter to on and Specify lowpass slope from input port to off.

Select this parameter to add a highpass filter to your equalizer.

Select this parameter to specify the cutoff frequency of the highpass filter cutoff from the input port.

Dependencies

To enable this parameter, set Add highpass filter to on.

The cutoff frequency of the highpass filter, specified as a real scalar greater than or equal to 0 in Hz.

Tunable: Yes

Dependencies

To enable this parameter, set Add highpass filter to on and Specify highpass cutoff from input port to off.

Select this parameter to specify the slope of the highpass filter from the input port.

Dependencies

To enable this parameter, set Add highpass filter to on.

The slope of the highpass filter, specified as a real scalar in the range [0:6:48] in dB/octave. Values that are not multiples of 6 are rounded to the nearest multiple of 6.

Tunable: Yes

Dependencies

To enable this parameter, set Add highpass filter to on and Specify highpass slope from input port to off.

Oversample toggle, specified as one of the following:

  • off –– Run the multiband parametric equalizer at the input sample rate.

  • on –– Run the multiband parametric equalizer at two times the input sample rate. Oversampling minimizes the frequency-warping effects introduced by the bilinear transformation.

A halfband interpolator implements oversampling before equalization. A halfband decimator reduces the sample rate back to the input sampling rate after equalization.

Type of simulation to run, specified as one of the following:

  • Interpreted execution –– Simulate model using the MATLAB interpreter. This option shortens startup time and has simulation speed comparable to Code generation. In this mode, you can debug the source code of the block.

  • Code generation –– Simulate model using generated C code. The first time you run a simulation, Simulink® generates C code for the block. The C code is reused for subsequent simulations as long as the model does not change. This option requires additional startup time but the speed of the subsequent simulations is faster than Interpreted execution.

Tunable: No

Block Characteristics

Data Types

double | single

Direct Feedthrough

no

Multidimensional Signals

no

Variable-Size Signals

yes

Zero-Crossing Detection

no

Extended Capabilities

C/C++ Code Generation
Generate C and C++ code using Simulink® Coder™.

Version History

Introduced in R2021b