Signal Processing Toolbox |
Chebyshev Type I filter design (passband ripple)
Syntax
[b,a]=
cheby1(n,Rp,Wn) [b,a]=
cheby1(n,Rp,Wn,'ftype
') [b,a]=
cheby1(n,Rp,Wn,'s
') [b,a]=
cheby1(n,Rp,Wn,'ftype
','s
') [z,p,k]=
cheby1(...) [A,B,C,D]=
cheby1(...)
Description
cheby1
designs lowpass, bandpass, highpass, and bandstop digital and analog Chebyshev Type I filters. Chebyshev Type I filters are equiripple in the passband and monotonic in the stopband. Type I filters roll off faster than type II filters, but at the expense of greater deviation from unity in the passband.
Digital Domain
[b,a] = cheby1(n,Rp,Wn)
designs an order n
Chebyshev
lowpass digital Chebyshev filter with normalized passband edge frequency Wn
and Rp
dB of peak-to-peak ripple in the passband. It returns the filter coefficients in the length n+1
row vectors b
and a
, with coefficients in descending powers of z.
Normalized passband edge frequency is the frequency at which the magnitude response of the filter is equal to -Rp
dB. For cheby1
, the normalized passband edge frequency Wn
is a number between 0 and 1, where 1 corresponds to the Nyquist frequency, radians per sample. Smaller values of passband ripple Rp
lead to wider transition widths (shallower rolloff characteristics).
If Wn
is a two-element vector, Wn
= [w1 w2]
, cheby1
returns an order 2*n
bandpass filter with passband w1
<
<
w2
.
[b,a] = cheby1(n,Rp,Wn,'
designs a highpass , lowpass, or bandstop filter, where the string ftype
')
'
ftype'
is one of the following
'
high'
for a highpass digital filter with normalized passband edge frequency Wn
'low'
for a lowpass digital filter with normalized passband edge frequency Wn
'stop'
for an order 2*n
bandstop digital filter if Wn
is a two-element vector, Wn
= [w1 w2]
. The stopband is w1
< < w2
.
With different numbers of output arguments, cheby1
directly obtains other realizations of the filter. To obtain zero-pole-gain form, use three output arguments as shown below:
[z,p,k] = cheby1(n,Rp,Wn,'
returns the zeros and poles in length ftype
')
n
column vectors z
and p
and the gain in the scalar k
.
To obtain state-space form, use four output arguments as shown below:
[A,B,C,D] = cheby1(n,Rp,Wn)
or
[A,B,C,D] = cheby1(n,Rp,Wn,'
where ftype
')
A
, B
, C
, and D
are
and u is the input, x is the state vector, and y is the output.
Analog Domain
designs an order [b,a]
= cheby1(n,Rp,Wn,'
s
')
n
lowpass analog Chebyshev Type I filter with angular passband edge frequency Wn rad/s.
It returns the filter coefficients in length n+1
row vectors b
and a
, in descending powers of s, derived from the transfer function
Angular passband edge frequency is the frequency at which the magnitude response of the filter is -Rp
dB. For cheby1
, the angular passband edge frequency Wn
must be greater than 0 rad/s.
If Wn
is a two-element vector Wn
= [w1 w2]
with w1
< w2
, then cheby1(n,Rp,Wn,'
s
')
returns an order 2*n
bandpass analog filter with passband w1
< < w2
.
[b,a] = cheby1(n,Rp,Wn,'
designs a highpass, lowpass, or bandstop filter.ftype
','s
')
You can supply different numbers of output arguments for cheby1 to directly obtain other realizations of the analog filter. To obtain zero-pole-gain form, use three output arguments as shown below.
[z,p,k] = cheby1(n,Rp,Wn,'
ors
')
returns the zeros and poles in length [z,p,k] = cheby1(n,Rp,Wn,'ftype','
s
')
n
or 2*n
column vectors z
and p
and the gain in the scalar k
.
To obtain state-space form, use four output arguments as shown below:
[A,B,C,D] = cheby1(n,Rp,Wn,'
ors
')
[A,B,C,D] = cheby1(n,Rp,Wn,'
where ftype
','s
')
A
, B
, C
, and D
are defined as
and u is the input, x is the state vector, and y is the output.
Example 1: Lowpass Filter
For data sampled at 1000 Hz, design a 9th-order lowpass Chebyshev Type I filter with 0.5 dB of ripple in the passband and a passband edge frequency of 300 Hz, which corresponds to a normalized value of 0.6:
The frequency response of the filter is
Example 2: Bandpass Filter
Design a 10th-order bandpass Chebyshev Type I filter with a passband from 100 to 200 Hz and plot its impulse response:
Limitations
For high order filters, the state-space form is the most numerically accurate, followed by the zero-pole-gain form. The transfer function form is the least accurate; numerical problems can arise for filter orders as low as 15.
Algorithm
cheby1
uses a five-step algorithm:
cheb1ap
function.
cheby1
uses bilinear
to convert the analog filter into a digital filter through a bilinear transformation with frequency prewarping. Careful frequency adjustment guarantees that the analog filters and the digital filters will have the same frequency response magnitude at Wn
or w1
and w2
.
See Also
besself
, butter
, cheb1ap
, cheb1ord
, cheby2
, ellip
chebwin | cheby2 |
© 1994-2005 The MathWorks, Inc.