Main Content

Digital Filter Design

Design and implement digital FIR and IIR filters

  • Digital Filter Design block

Libraries:
DSP System Toolbox / Filtering / Filter Designs

Description

Use this block to design, analyze, and efficiently implement floating-point filters.

The Digital Filter Design block implements a digital Finite Impulse Response (FIR) or Infinite Impulse Response (IIR) filter that you design by using the Filter Designer (filterDesigner) app. This block provides the same filter implementation as the Discrete FIR Filter or Biquad Filter blocks.

You must specify whether the block performs frame-based or sample-based processing on the input by setting the Input processing parameter. The block applies the specified filter to each channel of a discrete-time input signal and outputs the result. The outputs of the block numerically match the outputs of the Discrete FIR Filter or Biquad Filter block and the MATLAB® filter function. For more information, see Getting Started with Filter Designer.

These blocks also implement digital filters, but serve slightly different purposes:

  • Discrete FIR Filter (Simulink) and Biquad Filter— Use to efficiently implement floating-point or fixed-point filters that you have already designed. These blocks provide the same exact filter implementation as the Digital Filter Design block.

  • Filter Realization Wizard — Use to implement floating-point or fixed-point filters built from Sum, Gain, and Unit Delay blocks. You can either design the filter within this block, or import the coefficients of a filter that you designed elsewhere.

Examples

Ports

Input

expand all

Signal to filter, specified as a vector or matrix of real values. When given matrix input, the block treats each column as an independent channel.

The sample rate, Fs, that you specify in the filter designer app must be identical to the sample rate of the input to the Digital Filter Design block. When the sampling frequencies do not match, the Digital Filter Design block returns a warning message and inherits the sample rate of the input block.

Data Types: single | double

Output

expand all

Filtered signal, returned as a vector or a matrix of real values.

Data Types: single | double

Parameters

Dialog Box

For more information about the parameters in this dialog box, see Using Filter Designer.

Block Characteristics

Data Types

double | single

Direct Feedthrough

no

Multidimensional Signals

no

Variable-Size Signals

no

Zero-Crossing Detection

no

More About

expand all

Extended Capabilities

Version History

Introduced before R2006a

expand all