Signal Processing Toolbox |
Phase response of digital filters
Syntax
[phi,w] = phasez(b,a,n) [phi,w] = phasez(b,a,n,'whole') phi = phasez(b,a,w) [phi,f] = phasez(b,a,n,fs) [phi,f] = phasez(b,a,n,'whole',fs) phi = phasez(b,a,f,fs) [phi,w,s] = phasez(...) [phi,f,s] = phasez(...) phasez(b,a,...) phasez(Hd)
Description
[phi,w] = phasez(b,a,n)
returns the n
-point phase response vector phi
and the n
-point frequency reponse vector w
(in radians/sample) of the filter defined by numerator coefficients b
and denominator coefficients a
. The phase response is evaluated at n
equally spaced points around the upper half of the unit circle. If n
is omitted, it defaults to 512.
[phi,w] = phasez(b,a,n,'whole')
uses n
equally spaced points around the whole unit circle.
phi = phasez(b,a,w)
returns the phase response at frequencies specified in vector w
(in radians/sample). The frequencies are normally between 0 and .
[phi,f] = phasez(b,a,n,fs) and [phi,f] = phasez(b,a,n,'whole',fs)
return the phase vector f
(in Hz), using the sampling frequency fs
(in Hz).
phi = phasez(b,a,f,fs)
returns the phase response at the frequencies specified in vector f
(in Hz), using the sampling frequency fs
(in Hz)..
[phi,w,s] = phasez(...) and [phi,f,s] = phasez(...)
return plotting information, where s
is a structure with fields you can change to display different frequency response plots.
phasez(b,a,...)
with no output arguments, plots the phase response of the filter in the current filter window.
phasez(Hd)
plots the phase response of the filter and displays the plot in fvtool
. The input Hd
is a dfilt
filter object.
Example 1
Plot the phase response of a constrained least squares FIR filter:
The same example using a dfilt
filter object and displaying the result in fvtool
, where you can perform more analyses, is
Example 2
Plot the phase response of an elliptic filter:
See Also
freqz
, fvtool
, phasedelay
, grpdelay
phasedelay | pmcov |
© 1994-2005 The MathWorks, Inc.