Products & Services Industries Academia Support User Community Company

Learn more about Signal Processing Toolbox   

window (filter design method) - FIR filter using windowed impulse response

Syntax

h = window(d,'window',fcnhndl)
h = window(d,win)

description

h = window(d,'window',fcnhndl) designs an FIR filter using the specifications in filter specification object d. Depending on the specification type of d, the returned filter is either a single-rate digital filter — a dfilt, or a multirate digital filter — an mfilt.

fcnhndl is a handle to a filter design function that returns a window vector, such as the hamming or blackman functions. fcnarg is an optional argument that returns a window. You pass the function to window. Refer to example 1 in the following section to see the function argument used to design the filter.

h = window(d,win) designs a filter using the vector you supply in win. The length of vector win must be the same as the impulse response of the filter, which is equal to the filter order plus one.

Example

Construct a lowpass filter specification object of order 10 with a cutoff frequency of 12 kilohertz. We use a sampling frequency of 48 kilohertz. Next we use a function handle to the function Kaiser to provide the window.

d=fdesign.lowpass('n,fc',10,12000,48000);
Hd=window(d,'window',@kaiser);
fvtool(Hd);

See Also

design, designmethods, fdesign

  


Recommended Products

Includes the most popular MATLAB recorded presentations with Q&A sessions led by MATLAB experts.

 © 1984-2009- The MathWorks, Inc.    -   Site Help   -   Patents   -   Trademarks   -   Privacy Policy   -   Preventing Piracy   -   RSS