Вы находитесь на странице: 1из 31

Why digital filters?

 Digital filters can have characteristic which are not possible with analog filters, such
as truly linear phase response.
 Unlike analog filters, the performance of digital filters does not vary with
environmental changes, for example thermal variations. This eliminates the need to
calibrate periodically.
 The frequency response of a digital filter can be automatically adjusted if it is
implemented using a programmable processor, which is why they are widely used in
adaptive filters like LMS, NLMS.
 Several input signals or channels can be filtered by one digital filter without the
need to replicate the hardware.
 Both filtered and unfiltered data can be saved for future use.
 With the use of VLSI technology we can fabricate low cost, small size, and low
power digital filter.
 Digital filters can achieve thousands of times better performance than analog
filters. This makes a dramatic difference in how filtering problems are approached.
With analog filters, the emphasis is on handling limitations of the electronics, such
as the accuracy and stability of the resistors and capacitors.
Disadvantages of digital filters
 Analog filters are cheap and have a large dynamic range in both amplitude and
frequency than digital filters.
 The maximum bandwidth of signals that digital filters can handle, in real time,
is much lower than for analog filters. In real time situations, the A/D and D/A
conversion processes introduce a speed constraint on the digital filter
performance. Further, the speed of operation of filter is depends upon the
speed of digital signal processor used and on the number of arithmetic
operations that must be performed for the filtering algorithm, which increases
as the filter response is made tighter.
 Digital filters are subjected to ADC noise resulting from quantizing a
continuous signal, and to round off noise incurred during computation. With
higher order recursive filters, the accumulation of round off noise could lead to
instability.
 The design and development times for digital filters, especially hardware
development, can be much longer than for analog filters. However, once
developed the hardware and/or software can be used for other filtering or DSP
tasks with little or no modifications
 In the design of frequency-selective filters, the
desired filter characteristics are specified in the
frequency domain in terms of the desired
magnitude and phase response of the filter. In the
filter design process, we determine the
coefficients of a causal FIR or IIR filter that
closely approximates the desired frequency
response specifications.
 The issue of which type of filter to design, FIR or
IIR , depends on the nature of the problem and on
the specifications of the desired frequency
response.
Types of Digital Filter
1.FIR
2.IIR
 In practice, FIR filters are employed in filtering
problems where there is a requirement for a
linear-phase characteristic within the pass band
of the filter.
 If there is no requirement for a linear-phase
characteristic, either an IIR or an FIR filter may be
employed. However, as a general rule, an IIR filter
has lower Sidelobes in the stopband than an FIR
filter having the same number of parameters.
Causality and Its Implications
Impulse response h(n) of an ideal low pass filter
with frequency response characteristic:
 One possible solution is to introduce a large delay
no in h(n) and arbitrarily to set h(n) = 0 for n < no
However, the resulting system no longer has an
ideal frequency response characteristic. Indeed, if
we set h(n) =0 for n < n0, the Fourier series
expansion of H(w) results in the Gibbs
phenomenon. none of the ideal filter
characteristics are causal, hence all are physically
unrealizable.
h{n) for wc= π/4
What are the necessary and sufficient conditions
that a frequency response characteristic H(w)
must satisfy in order for the resulting filter to be
causal? The answer to this question is given by
the Paley-Wiener theorem

the resulting filter with frequency response


 conclusion that w e draw from the Paley -Wiener
theorem is that the magnitude function |h(w)|
can be zero at some frequencies, but it cannot be
zero over any finite band of frequencies, since the
integral then becomes infinite. Consequently, any
ideal filter is noncausal.
linear time-invariant systems specified by the
difference equation which are causal and
physically realizable.

such systems have a frequency response

The basic digital filter design problem is to approximate


any of the ideal frequency response characteristics with a
system that has the frequency response as H(w), by
properly selecting the coefficients {ak} and {bk}.
Causality implications
 Causality also places restrictions on the real and
imaginary parts of frequency response.
 causality has very important implications in the
design of frequency-selective filters. These are:
 (a) the frequency response H(w) cannot be zero,
except at a finite set of points in frequency;
 (b) the magnitude |H(w)| cannot be constant in any
finite range of frequencies and the transition from
passband to stopband cannot be infinitely sharp
 (c) the real and imaginary parts of H(w) are
interdependent and are related by the discrete Hilbert
transform. As a consequence, the magnitude |H(w)|
and phase cannot be chosen arbitrarily.
Characteristics of Practical Frequency-
Selective Filters
 Ideal filters are noncausal and hence physically
unrealizable for real-time signal processing
applications.
 Causality implies that the frequency response
characteristic H(w) of the filter cannot be zero,
except at a finite set of points in the frequency
range. In addition, H(w) cannot have an infinitely
sharp cutoff from passband to stopband, that is,
H(w) cannot drop from unity to zero abruptly.
 In any filter design problem we can specify
(1) the maximum tolerable passband ripple,
(2) the maximum tolerable stopband ripple,
(3) the passband edge frequency and
(4) the stopband edge frequency .
Based on these specifications,we can select the parameters
{ak} and {bk} in the frequency response characteristic, given
by

which best approximates the desired specification.


 The degree to which H(w) approximates the specifications
depends in part on the criterion used in the selection o f
the filter coefficients as well as on the numbers (M , N ) o f
coefficients.
Filter Design steps
 Specifications of filter
 Specifications are in form of tolerance schemes.
 Calculation of suitable filter coefficient
 Coefficients h(k) for FIR and ak and bk for IIR which best
approximates desired specifications along with number M
and N(Methods: windowing, frequency sampling,optimum
ripple method and hilbert transform method)
 Realization of filter by suitable structure
 Its to convert a given transfer function H(z) into a suitable
filter structure.(direct form structure , transversal structure,
frequency sampling structure for FIR and direct form ,
cascade and parallel form structure for IIR)
Filter Design steps
 Analysis of finite wordlength on filter performance
 Implementation of filter is required to represent the
filter coefficient using limited number of bits typically 8
to 16 bits.effect of using finite number of bits results
degradation of performance of filter hence suitable
wordlengths must be analyzed for filter coefficients
,filter variables, i/o samples and arithmetic operations
within filter.
 Implementation of filter on software & hardware
 Implementation using basic components (memory for
storing filter coefficients as well as present and past I/O ,
hardware or software multipliers, Adder or ALU)
Phase delay & group delay
 Phase Delay:
A signal consists of several frequency components.
Practical filters have non-zero phase response.
So practically the frequency components when passed
through practical digital filter experience time delay.
The phase delay is the amount of time delay each
individual frequency components of the signal suffer while
transmitted through a system (digital filter here).
Phase delay

Group delay
It is the average time delay of the frequency
components of the composite signal.
Mathematically it is defined as:
 𝝉g = -dh()/d
 “the –ve derivative of phase wrt frequency”.
For no phase distortion, the group delay should be a constant; i.e. h() must
be linear.
The phase delay = group delay if h/ is a constant.
Non linear phase characteristics of a system results in phase distortion at the
output due to alteration in the phase relationship of frequency components of
the signal during processing.
Non linear phase delay is undesirable in hi-fi systems such as video, bio-
medical, data- transmission etc.
Linear Phase Response:
 Linear Phase Response:
h    ; where  and  are constants.
 Group delay 𝝉g = -dh()/d= 
DESIGN OF FIR FILTERS
 Symmetric and Antisymmetric FIR Filters
An FIR filter of length M with input x(n) and output
y(n) is described by the difference equation

Alternatively, we can express the output sequence as


the convolution of the unit sample response h(n) of
the system with the input signal.
 The filter can also be characterized by its system
function

 A n FIR filter has linear phase if its unit sample


response satisfies the condition

 if we substitute z-1 for z and multiply both sides of


the resulting equation by z-(M-1), we obtain
Result implies that the roots of the polynomial H(z) are
identical to the roots of the polynomial H(z-1)
Impulse response of ideal digital
filters
 hlp(n) = 2fc sinc(2fcn), -∞<n<∞
 hhp(n) = §(n)-2fc sinc(2fcn), -∞<n<∞
 hbp(n) = 2fH sinc(2fHn)- 2fL sinc(2fLn), - ∞ < n < ∞
 hbp(n) = §(n)- 2fH sinc(2fHn)- 2fL sinc(2fLn), - ∞ < n <

Impulse response of low pass filter
Impulse response of highpass
filter
Impulse response of bandpass
filter
Impulse response of bandstop
filter

Вам также может понравиться