| Signal Processing Toolbox | Search  Help Desk |
| zp2sos | Examples See Also |
Conversion of zero-pole-gain to second-order sections.
Syntax
[sos,g]= zp2sos(z,p,k)[sos,g] = zp2sos(z,p,k,'order')[sos,g] = zp2sos(z,p,k,'order','scale')sos = zp2sos(...)
Description
zp2sos converts a zero-pole-gain representation of a given system to an equivalent second-order section representation.
[sos,g] = zp2sos(z,p,k)
finds a matrix sos in second-order section form with gain g equivalent to the zero-pole-gain system represented by input arguments z, p, and k. Vectors z and p contain the zeros and poles of the system H(z), not necessarily in any order:
z and p, respectively, and k is a scalar gain. The zeros and poles must be real or complex conjugate pairs. sos is an L-by-6 matrix:
sos is the maximum of the ceiling of n/2 and the ceiling of m/2.
[sos,g] = zp2sos(z,p,k,'order')
specifies the order of the rows in sos, where order is:
down, to order the sections so the first row of sos contains the poles closest to the unit circle
up, to order the sections so the first row of sos contains the poles farthest from the unit circle (default)
[sos,g] = zp2sos(z,p,k,'order','scale')
specifies the desired scaling of the gain and the numerator coefficients of all second-order sections, where scale is:
none, to apply no scaling (default)
inf, to apply infinity-norm scaling
two, to apply 2-norm scaling
up-ordering minimizes the probability of overflow in the realization. Using 2-norm scaling in conjunction with down-ordering minimizes the peak round-off noise.
sos = zp2sos(...)
embeds the overall system gain, g, in the first section, H1(z), so that
Example
Find a second-order section form of a Butterworth lowpass filter:[z,p,k] = butter(5,0.2); sos = zp2sos(z,p,k);
Algorithm
zp2sos uses a four-step algorithm to determine the second-order section representation for an input zero-pole-gain system:
.cplxpair function.
.zp2sos groups real poles into sections with the real poles closest to them in
absolute value. The same rule holds for real zeros.
.zp2sos normally orders the sections with poles closest to the unit
circle last in the cascade. You can tell zp2sos to order the sections in the
reverse order by specifying the down flag.
.zp2sos scales the sections by the norm specified in the 'scale' argument.
For arbitrary H(
), the scaling is defined by:
or 2. See the references for details on the scaling.
See Also
cplxpair |
Group complex numbers into complex conjugate pairs. |
sos2zp |
Conversion of second-order sections to zero-pole-gain. |
ss2sos |
Conversion of state-space to second-order sections. |
tf2sos |
Conversion of transfer function to second-order sections. |
zp2ss |
Conversion of zero-pole-gain to state-space. |
zp2tf |
Conversion of zero-pole-gain to transfer function. |
References
[1] Jackson, L.B. Digital Filters and Signal Processing. 3rd ed. Boston: Kluwer Academic Publishers, 1996. Chapter 11. [2] Mitra, S.K. Digital Signal Processing: A Computer-Based Approach. New York: McGraw-Hill, 1998. Chapter 9. [3] Vaidyanathan, P.P. "Robust Digital Filter Structures." Handbook for Digital Signal Processing. S.K. Mitra and J.F. Kaiser, ed. Chapter 7. New York: John Wiley & Sons, 1993.