DSP Configurations. responded with: thus the system function for this filter would be

Similar documents
ECE4270 Fundamentals of DSP Lecture 20. Fixed-Point Arithmetic in FIR and IIR Filters (part I) Overview of Lecture. Overflow. FIR Digital Filter


Numbering Systems. Computational Platforms. Scaling and Round-off Noise. Special Purpose. here that is dedicated architecture

(Refer Slide Time: )

Lecture 19 IIR Filters

Analysis of Finite Wordlength Effects

DSP Design Lecture 2. Fredrik Edman.

DFT & Fast Fourier Transform PART-A. 7. Calculate the number of multiplications needed in the calculation of DFT and FFT with 64 point sequence.

DHANALAKSHMI COLLEGE OF ENGINEERING DEPARTMENT OF ELECTRICAL AND ELECTRONICS ENGINEERING EC2314- DIGITAL SIGNAL PROCESSING UNIT I INTRODUCTION PART A

E : Lecture 1 Introduction

IT DIGITAL SIGNAL PROCESSING (2013 regulation) UNIT-1 SIGNALS AND SYSTEMS PART-A

ECE503: Digital Signal Processing Lecture 6

An Fir-Filter Example: Hanning Filter

APPLIED SIGNAL PROCESSING

Determining Appropriate Precisions for Signals in Fixed-Point IIR Filters

Digital Filter Structures. Basic IIR Digital Filter Structures. of an LTI digital filter is given by the convolution sum or, by the linear constant

FINITE PRECISION EFFECTS 1. FLOATING POINT VERSUS FIXED POINT 3. TYPES OF FINITE PRECISION EFFECTS 4. FACTORS INFLUENCING FINITE PRECISION EFFECTS

Combinational Logic Design Arithmetic Functions and Circuits

Discrete-time signals and systems

Implementation of Discrete-Time Systems

EE 123: Digital Signal Processing Spring Lecture 23 April 10

Lecture 7 - IIR Filters

Introduction to Digital Signal Processing

LECTURE NOTES DIGITAL SIGNAL PROCESSING III B.TECH II SEMESTER (JNTUK R 13)

HARDWARE IMPLEMENTATION OF FIR/IIR DIGITAL FILTERS USING INTEGRAL STOCHASTIC COMPUTATION. Arash Ardakani, François Leduc-Primeau and Warren J.

Fundamentals of the DFT (fft) Algorithms

Frequency-domain representation of discrete-time signals

NCU EE -- DSP VLSI Design. Tsung-Han Tsai 1

ELEG 305: Digital Signal Processing

ELEG 305: Digital Signal Processing

Convolution. Define a mathematical operation on discrete-time signals called convolution, represented by *. Given two discrete-time signals x 1, x 2,

VALLIAMMAI ENGINEERING COLLEGE. SRM Nagar, Kattankulathur DEPARTMENT OF INFORMATION TECHNOLOGY. Academic Year

DIGITAL SIGNAL PROCESSING UNIT III INFINITE IMPULSE RESPONSE DIGITAL FILTERS. 3.6 Design of Digital Filter using Digital to Digital

Oversampling Converters

REAL TIME DIGITAL SIGNAL PROCESSING

DISCRETE-TIME SIGNAL PROCESSING

Digital Signal Processing Lecture 8 - Filter Design - IIR

Course Name: Digital Signal Processing Course Code: EE 605A Credit: 3

Number Representation and Waveform Quantization

Vel Tech High Tech Dr.Ranagarajan Dr.Sakunthala Engineering College Department of ECE

Digital Systems Roberto Muscedere Images 2013 Pearson Education Inc. 1

Design IIR Filters Using Cascaded Biquads

MATH Dr. Halimah Alshehri Dr. Halimah Alshehri

Low Power, High Speed Parallel Architecture For Cyclic Convolution Based On Fermat Number Transform (FNT)

Optimum Ordering and Pole-Zero Pairing of the Cascade Form IIR. Digital Filter

The Cooper Union Department of Electrical Engineering ECE111 Signal Processing & Systems Analysis Final May 4, 2012

DESIGN OF QUANTIZED FIR FILTER USING COMPENSATING ZEROS

Polyphase filter bank quantization error analysis

Pre-Scaling to Avoid Overflow and Maintain Maximum Precision in Fixed-Point Multiplication

R13 SET - 1

Analysis and Synthesis of Weighted-Sum Functions

CHANNEL PROCESSING TWIN DETECTORS CHANNEL PROCESSING TWIN DETECTORS CHANNEL PROCESSING TWIN DETECTORS CHANNEL PROCESSING TWIN DETECTORS

Universiti Malaysia Perlis EKT430: DIGITAL SIGNAL PROCESSING LAB ASSIGNMENT 5: DIGITAL FILTER STRUCTURES

Roundoff Noise in Digital Feedback Control Systems

4.0 Update Algorithms For Linear Closed-Loop Systems


Homework #1 Solution

1 1.27z z 2. 1 z H 2

Optimum Ordering and Pole-Zero Pairing. Optimum Ordering and Pole-Zero Pairing Consider the scaled cascade structure shown below

UNIT - III PART A. 2. Mention any two techniques for digitizing the transfer function of an analog filter?

Question Bank. UNIT 1 Part-A

Fall 2011, EE123 Digital Signal Processing

Z - Transform. It offers the techniques for digital filter design and frequency analysis of digital signals.

ENGIN 112 Intro to Electrical and Computer Engineering

Digital Filter Structures

COMBINATIONAL LOGIC FUNCTIONS

UNIT 1. SIGNALS AND SYSTEM

Practical Considerations in Fixed-Point FIR Filter Implementations

Discrete-Time Systems

FPGA Resource Utilization Estimates for NI PXI-7854R. LabVIEW FPGA Version: 8.6 NI-RIO Version: 3.0 Date: 8/5/2008

Experiment 13 Poles and zeros in the z plane: IIR systems

FILTER DESIGN FOR SIGNAL PROCESSING USING MATLAB AND MATHEMATICAL

Optimizing the Representation of Intervals

Notes for Chapter 1 of. Scientific Computing with Case Studies

Digital Wideband Integrators with Matching Phase and Arbitrarily Accurate Magnitude Response (Extended Version)

A Simple Architectural Enhancement for Fast and Flexible Elliptic Curve Cryptography over Binary Finite Fields GF(2 m )

EE482: Digital Signal Processing Applications

Ch. 7: Z-transform Reading

Design and Implementation of REA for Single Precision Floating Point Multiplier Using Reversible Logic

Using Mason's Rule to Analyze DSP Networks

International Association of Scientific Innovation and Research (IASIR) (An Association Unifying the Sciences, Engineering, and Applied Research)

Arithmetic and Error. How does error arise? How does error arise? Notes for Part 1 of CMSC 460

Lecture 16: Filter Design: Impulse Invariance and Bilinear Transform

1. Calculation of the DFT

Let H(z) = P(z)/Q(z) be the system function of a rational form. Let us represent both P(z) and Q(z) as polynomials of z (not z -1 )

SECTION 2: BLOCK DIAGRAMS & SIGNAL FLOW GRAPHS

FAST FIR ALGORITHM BASED AREA-EFFICIENT PARALLEL FIR DIGITAL FILTER STRUCTURES

Cost/Performance Tradeoffs:

EE 354 Fall 2013 Lecture 10 The Sampling Process and Evaluation of Difference Equations

DSP Algorithm Original PowerPoint slides prepared by S. K. Mitra

Recursive, Infinite Impulse Response (IIR) Digital Filters:

Design of Low Power, High Speed Parallel Architecture of Cyclic Convolution Based on Fermat Number Transform (FNT)

DIGITAL FILTERS Analysis, Design, and Applications by A. Antoniou ERRATA. Page 10, Table 1.1: The upper limit of the summation should be K.

1 Floating point arithmetic

Determining Appropriate Precisions for Signals in Fixed-point IIR Filters

FPGA Resource Utilization Estimates for NI crio LabVIEW FPGA Version: 8.6 NI-RIO Version: 3.0 Date: 8/5/2008

3 Finite Wordlength Effects

Quantum Carry-Save Arithmetic

Lecture 7. Floating point arithmetic and stability

Logic and Computer Design Fundamentals. Chapter 5 Arithmetic Functions and Circuits

Transcription:

DSP Configurations In this lecture we discuss the different physical (or software) configurations that can be used to actually realize or implement DSP functions. Recall that the general form of a DSP function is a ratio of polynomials in z -. For example when we used Matlab to design a Butterworth filter, the program returned an a vector and a b vector, When we executed the Matlab instruction responded with: >>[b,a] = butter(4,wn), Matlab b = 0.0048 0.093 0. 0289 0.093 0.0048 a =.0000-2.3695 2.340 -.0547 0.874 thus the system function for this filter would be H(z) = 0.0048z -0 + 0.93z - + 0.0289z -2 + 0.093z -3 + 0.0048z -4 z -0-2.3695z - + 2.340z -2 -.0547z -3 + 0.874z -4 (Note the symmetry of the numerator. We will come back to this later.) We found that we could actually implement this filter, either in hardware or software, with the following block diagram, recalling that the forward terms constitute the b vector and the feedback terms are made up of (- the denominator terms) and z - represents one unit delay. z - z - z - z -.0048.093.0289.093.0048 ADDER -0.874.0547-2.340 2.3695 z - z - z - z -

Note that the string of delay operations resembles a tapped delay line, leading to the description of the complexity of the circuit in terms of the number of taps. A simpler form which accomplishes the same function is the flow diagram. The direct form I flow diagram for this filter is 0.0048 z - 0.093 2.3695 z - z - 0.0289-2.340 z - z - 0.093.0547 z - z - z - 0.0048-0.874 From this form we can easily calculate the number of arithmetic operations additions, multiplies and delay operations. Each branch with an arrow and a number causes a multiplication (even if the number is ), each node with two arrows converging requires an addition, and each z - requires a delay element. The form above results directly from the system function H(z). However, the system function can be rearranged a number of ways, by suitable factoring of the numerator and denominator and rearranging the factors. To illustrate, let us consider a simpler system function, borrowed from a textbook, which has been chosen because it lends itself to factoring and rearranging. 2

Consider H(z) = + 2z - + z -2 0.75z - +0.25z -2 The direct form I realization of this H(z) is z - 2 0.75 z - z - -0.25 z - The two sections can be interchanged, thus making it possible to combine the delay elements, thereby reducing the number of delay elements (essentially storage locations). This is the direct form II. 0.75-0.25 z - 2 z - We can factor the numerator and denominator of H(z) = + 2z - + z -2 0.75z - +0.25z -2 Getting H(z) = + 2z - + z -2 = (+ z - )(+z - ) = ( + z - ) ( + z - ) 0.75z - +0.25z -2 ( - 0.5z - )(-0.25z - ) (-0.5z - ) ( 0.25z - ) Which leads to the form: - z- z z - z - 0.5 0.25 3

This is called a cascade form, and as before, the forward and reverse paths can be interchanged, combining the delay elements, leading to: z - z - 0.5 0.25 Note that the sections in the two forms above could be interchanged to form even more variations. Another form can be found by factoring the polynomials, using partial fractions, getting: H(z ) = 8 + 8-25 -0.5Z - -0.25z - This form can be realized by the following parallel structure 8 8 0.5 z - - z -25 0.25 4

FIR systems. Recall that for FIR systems, the denominator term is just a =. Thus we have only the numerator to synthesize. Let us assume we have a system function consisting only of the numerator of the filter we used earlier. Then H(z) = 0.0048z -0 + 0.93z - + 0.0289z -2 + 0.093z -3 + 0.0048z -4. Note the symmetry of the coefficients. We can synthesize this function using the following flow diagram: z - z -.0048 z - z -.093.0289 With this form, we need four delay elements, but only 3 multiply and 2 add operations, or (N/2 + ) multiply and N/ 2 adds for a fourth order response. This helps to compensate for the fact that the FIR structures generally require more stages for a given filter response than the IIR. We have discussed various ways in which the system functions can be broken down and rearranged. Let us now look at reasons for choosing certain forms. One of the major reasons for choosing different arrangements of the system function involves the effect of coefficient quantization. When we set up the system function for a DSP system, say a digital filter, we tacitly assume infinite precision that is, we don t worry about the precision of the coefficients that are calculated. In fact, there is a limit to the precision, because the digital computer we use to make the calculations has a finite word length, which limits the precision of the calculated numbers. However, the word length is long enough that the limit of the precision doesn t affect the filter response. The calculated filter response exactly satisfies the stated requirements, as far as we can tell. 5

However, an actual digital filter or other DSP design may not be implemented on a standard digital computer. It may be in a system with an embedded microcontroller or other processor with a word length much smaller than the traditional PC. Therefore, it is instructive to consider the effect of the limited precision caused by the limited word length. Incidentally, this is exactly parallel to the component tolerance problem in analog circuits. Case history. Theoretical and experimental work shows that different configurations respond quite differently to the limited precision resulting from the quantization of the coefficients. In particular, it has been found that the direct forms are quite sensitive to the finite precision of the coefficients. This is caused by the fact that the coefficients affect all the poles and zeros, making the actual performance quite different from the desired result. Here is the frequency response of a 2 th order elliptic filter with coefficients unquantized and a direct form realization: With 6 bit coefficients using a parallel form, the response is essentially the same. With a direct form, and 6-bit quantization, the following frequency response results: 6

It is apparent that the response degrades substantially, and is essentially unusable with a direct form. For FIR systems, which depend only on the zeros of the system function, the response is not nearly so degraded by coefficient quantization, and the direct forms are commonly used. Roundoff noise. Computations made in DSP systems will not, in general give results that can be exactly represented by the finite-length words in the computer being used. The difference between the computed results and the value obtained by rounding off to the nearest valid binary value is treated as noise, and since it varies from one computation to the next, its effect it is usually analyzed as if it is random noise. Statistical analyses are employed to analyze the effect of the noise. It can be shown that the effect of roundoff noise is influenced by the pairing of the second order sections into which the basic direct form can be converted. Recall that we factored the simple second order system function into two numerator and two denominator factors. Then we separated them into two first order sections by pairing one numerator factor with one denominator factor: H(z) = + 2z - + z -2 = (+ z - )(+z - ) = ( + z - ) ( + z - ) 0.75z - +0.25z -2 ( - 0.5z - )(-0.25z - ) (-0.5z - ) ( 0.25z - ) 7

We could have adopted a different pairing, which would have not made any difference in this simple case because both numerator factors are the same. However, in the general case it is possible to construct several different pairings, and the effect of roundoff noise is different for each pairing. In addition, the treatment of noise varies with the configuration of the system function used. Noise introduced by the quantization step at each stage of a system is effectively filtered by succeeding stages. Thus the effect of roundoff noise depends on the choice of form direct, parallel, cascade, etc. Theoretical analysis of this effect is difficult, however, and it is not possible, in general, to predict which form of the system function will give the best results in accommodating roundoff noise. We are not prepared to go into these factors in further detail,, but will simply state that the treatment of error due to roundoff noise is another reason for considering forms of the system function of a DSP system, other than the basic direct forms. Overflow. Another reason for considering the ordering of the factors of a system transfer function is the problem of overflow. As we have noted, two of the basic operations done in DSP are addition and multiplication. In either type of computation, it is entirely possible that the result will be too large for the word size of the computer system involved. Without some corrective action, over flow will cause very serious errors. It can modify the sign bit, or change the magnitude drastically. The order in which the sections of a transfer function are calculated affects the overflow problem, but as with some of the other problems we have noted, it isn t possible, in general, to predict the correct order. Simulation and test cases will probably be necessary. In general, the usual approach to eliminating the overflow problem is to scale the inputs so that overflow doesn t occur at any node in the system. There are several somewhat formal strategies for choosing where and how to scale the signal levels. Another approach allows saturation, in which the magnitude of a signal at a node is limited to full scale of the word size, and there is no carry out to the higher bit. The 8

use of floating point arithmetic and a double-length accumulator in the DSP system greatly reduces the overflow problem, as larger operands can be accommodated. The Fast Fourier Transform. This is another of the major uses of Digital Signal Processing. We used it to compute the frequency content of a filtered and unfiltered signal when we designed filters via Matlab. As we have seen earlier, the simplified form of the FFT and its inverse are represented by the two equations: N- = (/N) X[k]W N kn the synthesis equation n=0 and N- X[k] = W N kn the analysis equation n = 0 where the notation is simplified by the substitution W N = e -j(2 /N). In carrying out these two equations, the lengthy computation is broken down into smaller and smaller blocks, ending up with a series of 2 x 2 complex computations. Thus, the format of the computations for the FFT is entirely different from that for a standard linear difference equation or its z-transform. The repeated breaking down of the formulas, called decimation, results in a flow diagram like that below: 9

The X-shaped operations shown above occur throughout the FFT process and are called butterflies. 0