|
|
Finite Precision Analysis |
|
Flash Menu
|
General Information The digital function selection features on the face of the main control panel assume perfect infinite precision arithmetic. Your digital filter may reside in a low cost processor with very limited precision resulting in computational errors. Therefore, the digital filter you designed may not perform as well in your target processor as it did in Filter Solutions main control panel. To help you determine how your designed filter will perform, Filter Solutions allows you to do a finite precision analysis using finite precision arithmetic, different digital forms, and different numeric digital formats. The digital Transfer Function display resulting from selecting "Transfer Function" on the main control panel when in digital mode has a button called "Test". Selecting this Test button brings up a menu for time response, frequency response, and pole zero plot. All three of these items will perform the indicated task on the displayed Z transform in the same precision and form as it is shown. The ideal digital filter function is displayed in the background for comparison purposes. If the precision of the target processor is not precisely known, it may be estimated what number of base 10 significant digits is equivalent to the target precision. This number should then be placed in the "Sig Dig" box in the upper right of the Transfer Function display. The range of this number must be from 1 to 16. Filter Solutions also offers signed and unsigned fixed and floating point Z transforms. If your processor precision is known to be fixed or floating point and the number of bits of precision are know, you may select one of these options and enter the bits of precision in the "Sig Bits" box in the upper right. You may then begin your analysis. When using decimal or floating point, Filter Solutions calculates the resolution of each computation and rounds accordingly. When using fixed point, Filter Solutions calculates the resolution based upon the range and significant bits, and applies this resolutions throughout the simulation. Since IIR filters do not necessarily maintain the same resolution for all computations, be cautious when interpreting fixed point IIR test results. Of the three form selections available, Standard, Cascade, and Parallel, the Standard form is the least accurate. Errors due to finite precision may make the filter go unstable, result in excessive noise, or diminish attenuation. The Cascade form usually works better than the Parallel form for Bilinear transformation, and the Parallel form usually works better than the Cascade form for Impulse Invariant and Step Invariant transformation. However, you since this is not always the case, you should test your filter in both the Parallel and Cascade mode to determine the best form selection. Since Filter Solutions is capable of producing C code for the Cascade and Parallel forms just as easily it can for the Standard forms, the Standard form is not recommended except for very simple filters. Since FIR filters are not as susceptible to fixed precision errors, only the Standard form is supported for FIR filters. |
Fixed Precision Error Example
You wish to place a third order band pass Butterworth filter in your target processor that has roughly three digits of precision. The corner frequencies of the filter are at 1 and 2 Hz, and the sample rate is 50 Hz. You have chosen the Bilinear transformation with Alias Correction. Here is the transfer function for each form.
![]() |
![]() |
![]() |
Pole Zero Plots
Below are the Pole Zero plots for each form at three significant digits. The dark blue poles and zeros indicate the ideal pole zero placement for this filter The Standard form is totally unacceptable! Three of the six poles reside outside the unit circle indicating a very unstable filter. The cascade form succeeds in placing poles and zeros very close to the ideal location. The Parallel form secedes in positioning the poles properly, but misses some with the zeros. The Cascade form is clearly the ideal choice for this filter.
![]() Standard Form |
![]() Cascade Form |
|
|
Frequency Response
Below are the frequency traces for the magnitude and group delay for each form with the ideal digital filter in dark blue. . Once again, the Standard form is totally unacceptable! The Cascade form is is only slightly in error, and the Parallel form exhibits error in the transmission zero at 0 Hz. These traces all agree with the pole zero plots above, and support our conclusion that the Cascade form is the best form to use for this filter.
![]() Standard Form |
![]() Cascade Form |
|
|
Time Response
Below is the time trace for the step response for each form with the ideal digital filter in dark blue. The Standard form is completely unstable, as predicted by the pole zero plot! The Cascade form is is only slightly in error, and the Parallel form exhibits noise. These traces further support our conclusion that the Cascade form is the best form to use for this filter.
![]() Standard Form |
![]() Cascade Form |
|
|