Note: This page has been translated by MathWorks. Please click here

To view all translated materals including this page, select Japan from the country navigator on the bottom of this page.

To view all translated materals including this page, select Japan from the country navigator on the bottom of this page.

Filter input signal in frequency domain

The `dsp.FrequencyDomainFIRFilter`

System object™ implements frequency-domain, fast Fourier transform (FFT)-based
filtering to filter a streaming input signal. In the time domain, the filtering operation
involves a convolution between the input and the impulse response of the finite impulse
response (FIR) filter. In the frequency domain, the filtering operation involves the
multiplication of the Fourier transform of the input and the Fourier transform of the impulse
response. The frequency-domain filtering is efficient when the impulse response is very long.
This object uses the overlap-save and overlap-add methods to perform the frequency-domain
filtering. For filters with a long impulse response length, the latency inherent to these two
methods can be significant. To mitigate this latency, the
`dsp.FrequencyDomainFIRFilter`

object partitions the impulse response into
shorter blocks and implements the overlap-save and overlap-add methods on these shorter
blocks. To partition the impulse response, set the PartitionForReducedLatency property to
`true`

. For more details on these two methods and on reducing latency
through impulse response partitioning, see Algorithms.

To filter the input signal in the frequency domain:

Create the dsp.FrequencyDomainFIRFilter object and set its properties.

Call the object with arguments, as if it were a function.

To learn more about how System objects work, see What Are System Objects? (MATLAB).

`fdf = dsp.FrequencyDomainFIRFilter`

`fdf = dsp.FrequencyDomainFIRFilter(num)`

`fdf = dsp.FrequencyDomainFIRFilter(Name,Value)`

creates a
frequency domain FIR filter System
object™ that filters each channel of the input signal independently over time in the
frequency domain using the overlap-save or overlap-add method.`fdf`

= dsp.FrequencyDomainFIRFilter

creates a frequency domain FIR filter object with the Numerator property set to
`fdf`

= dsp.FrequencyDomainFIRFilter(num)`num`

.

```
dsp.FrequencyDomainFIRFilter(fir1(400,2 * 2000 /
8000));
```

creates a frequency domain FIR filter System
object with each specified property set to the specified value. Enclose each
property name in single quotes. You can use this syntax with any previous input argument
combinations.`fdf`

= dsp.FrequencyDomainFIRFilter(`Name,Value`

)

`dsp.FrequencyDomainFIRFilter('Method','Overlap-add');`

`fdfOut = fdf(input)`

filters the input signal
and outputs the filtered signal. The object filters each channel of the input signal
independently over time in the frequency domain.`fdfOut`

= fdf(input)

To use an object function, specify the
System
object as the first input argument. For
example, to release system resources of a System
object named `obj`

, use
this syntax:

release(obj)

Specific to dsp.FrequencyDomainFIRFilter

Common to All System Objects

`step` | Run System object algorithm |

`clone` | Create duplicate System object |

`getNumInputs` | Number of inputs required to call the System object |

`getNumOutputs` | Number of outputs from calling the System object |

`isLocked` | Determine if System object is locked |

`release` | Release resources and allow changes to System object property values and input characteristics |

`reset` | Reset internal states of System object |

[1] Stockham, T. G., Jr. "High Speed
Convolution and Correlation." *Proceedings of the 1966 Spring Joint Computer
Conference, AFIPS,* Vol 28, 1966, pp. 229–233.

Was this topic helpful?