design_filter

Table of Contents
Synopsis
Options
Example

Synopsis

design_filter [input file0] -o [output file] [-h ] [-forder int] [-double ] [-o ofile]

designfilter computes the coefficients of a FIR filter with a given frequency response. The user supplies the frequency response as a vector of evenly spaced gains ranging from 0 to half the sampling frequency. The length of this vector must be a power of 2. The filter coefficients can be used by the \Ref{sigfilter} program.

Options

-h

Options help

-forder

int Order of FIR filter. This must be ODD. Sensible values range from 19 (quick but with a shallow rolloff) to 199 (slow but with a steep rolloff). The default is 199.

-double

Design a filter suitable for double (zero-phase) filtering

-o

ofile output filter file

Example

Designing a bandpass filter

The frequency response vector must be placed in a file, in either ascii of EST headered format. For example:

EST_File fvector

version 1

DataType ascii

length 128

EST_Header_End

0.0

0.0

.....[etc]

1.0

1.0

1.0

.....[etc]

0.0

0.0

0.0

.....[etc]

And the filter is simply designed using

$ design_filter -o filter.coefficients filter.freq_response

where filter.freq_response is the above file, and filter.coefficients is the output file which can be used by \Ref{sigfilter}.