1 Digital Signal Processing DiscreteTime Systems Dr. Dung Trung Vo Telecommunication Divisions Department of Electrical and Electronics September, 2013 InputOutput Rules Discretetime system: is a processor that transforms an input sequence of discretetime samples x(n) into an output sequence of samples y(n): Samplebysample processing: Block processing methods: Functional mapping: Linear systems: this mapping becomes a linear transformation x0, x1, x2, x3,..., xn,...Hy0, y1, y2, y3,..., yn,... y Hx y Hx CuuDuongThanCong.com https:fb.comtailieudientucntt2 Example 1: y(n)= 2x(n), samplebysample processing Example 2: y(n)= 2x(n)+3x(n − 1)+4x(n − 2), block processing Example 3: y(n)= x(2n) InputOutput Rules x0, x1, x2, x3,...,H2x0,2x1,2x2,2x3,..., x0, x1, x2, x3, x4, x5, x6,...Hx0, x2, x4, x6,... Linear system: has the property that the output signal due to a linear combination of two or more input signals can be obtained by forming the same linear combination of the individual outputs. if y1(n) and y2(n) are the outputs due to the inputs x1(n) and x2(n), then the output due to the linear combination of inputs is given by the linear combination of outputs Testing linearity: Linearity and Time Invariance x(n) a1x1(n) a2x2(n) y(n) a1y1(n) a2 y2(n) CuuDuongThanCong.com https:fb.comtailieudientucntt3 Example 4: Test the linearity of the discretetime systems defined by and Linearity and Time Invariance y(n) 2x(n)3 y(n) x2(n) Time Invariance system: is a system that remains unchanged over time. This implies that if an input is applied to the system today causing a certain output to be produced, then the same output will also be produced tomorrow if the same input is applied Right translation: Testing time invariance: delaying the input causes the output to be delayed by the same amount: Linearity and Time Invariance CuuDuongThanCong.com https:fb.comtailieudientucntt4 Example 5: Test the time invariance of the discretetime systems defined by and Linearity and Time Invariance y(n) nx(n) y(n) x(2n) Impulse response of an LTI system: Linear timeinvariant systems are characterized uniquely by their impulse response sequence h(n), which is defined as the response of the system to a unit impulse δ(n). Transform function: Samplebysample processing: Impulse Response (n) Hh(n) 0, 0 1, 0 ( ) if n if n n 1,0,0,0,...Hh0,h1,h2,h3,... CuuDuongThanCong.com https:fb.comtailieudientucntt5 Delayed impulse responses: time invariance implies Impulse Response (n D) Hh(n D) Impulse response of an LTI system: linearity implies Arbitrary input: {x(0), x(1), x(2), . . . } can be thought of as the linear combination of shifted and weighted unit impulses: Its output: Impulse Response (n)(n 1)(n 2) Hh(n) h(n 1) h(n 2) y(n) x(0)h(n) x(1)h(n 1) x(2)h(n 2)... x(n) x(0)(n) x(1)(n 1) x(2)(n 2)... CuuDuongThanCong.com https:fb.comtailieudientucntt6 LTI form of convolution: Summation could extend over negative values of m, depending on the input signal. Direct form of convolution: Impulse Response m y(n) x(m)h(n m) m y(n) h(m)x(n m) FIR: has impulse response h(n) that extends only over a finite time interval, say 0 ≤ n ≤ M, and is identically zero beyond that Filter order: M Filter length: length of the impulse response vector h = h0 , h1, . . . , hM Impulse response coefficients: h = h0 , h1, . . . , hM are referred to by various names, such as filter coefficients, filter weights, or filter taps FIR filtering equation: FIR and IIR Filters M m y n h m x n m 0 ( ) ( ) ( ) L M 1 h h0,h1,h2,h3,...,hM ,0,0,0,... CuuDuongThanCong.com https:fb.comtailieudientucntt7 IIR: has an impulse response h(n) of infinite duration, defined over the infinite interval 0 ≤ n < ∞ IIR filtering equation: Constant coefficient linear difference equations: This IO equation is not computationally feasible. Therefore, we must restrict our attention to a subclass of IIR filters, namely, those filter coefficients are coupled to each other through constant coefficient linear difference equations: Difference equation for y(n): FIR and IIR Filters 0 ( ) ( ) ( ) m y n h m x n m L i i M i h n aih n i b n i 1 1 ( ) ( ) ( ) L i i M i y n ai y n i b x n i 1 1 ( ) ( ) ( ) Example 6: Determine the impulse response h of the following FIR filters FIR and IIR Filters ) ( ) ( ) ( 4) ) ( ) 2 ( ) 3 ( 1) 5 ( 2) 2 ( 3) b y n x n x n a y n x n x n x n x n CuuDuongThanCong.com https:fb.comtailieudientucntt8 Example 7: Determine the IO difference equation of an IIR filter whose impulse response coefficients h(n) are coupled to each other by the difference equation FIR and IIR Filters h(n) h(n 1)(n) Example 8: Suppose the filter coefficients h(n) satisfy the difference equation where a is a constant. Determine the IO difference equation relating a general input signal x(n) to the corresponding output y(n). FIR and IIR Filters h(n) ah(n 1)(n) CuuDuongThanCong.com https:fb.comtailieudientucntt9 Causal signal: A causal or rightsided signal x(n) exists only for n ≥ 0 and vanishes for all negative times n ≤ −1 Anticausal signal: An anticausal or leftsided signal exists only for n ≤ −1 and vanishes for all n ≥ 0. Mixed signal: A mixed or doublesided signal has both a leftsided and a rightsided part LTI systems can also be classified in terms of their causality properties depending on whether their impulse response h(n) is causal, anticausal, or mixed Causality Description: a system is stable if the output remains bounded by some bound |y(n)| ≤ B if its input is bounded, say |x(n)| ≤ A. Necessary and sufficient condition: Stability is absolutely essential in hardware or software implementations of LTI systems because it guarantees that the numerical operations required for computing the IO convolution sums or the equivalent difference equations remain well behaved and never grow beyond bounds. The concepts of stability and causality are logically independent, but are not always compatible with each other Stability n h(n) CuuDuongThanCong.com https:fb.comtailieudientucntt10 Example 9: Consider the following four examples of h(n): Stability Homework: provided in class Stability CuuDuongThanCong.com https:fb.comtailieudientucntt
Digital Signal Processing Discrete-Time Systems Dr Dung Trung Vo Telecommunication Divisions Department of Electrical and Electronics September, 2013 Input/Output Rules Discrete-time system: is a processor that transforms an input sequence of discrete-time samples x(n) into an output sequence of samples y(n): Sample-by-sample processing: H x0 , x1, x2 , x3 , , xn , y0 , y1, y2 , y3 , , yn , Block processing methods: Functional mapping: y H x Linear systems: this mapping becomes a linear transformation CuuDuongThanCong.com y Hx https://fb.com/tailieudientucntt Input/Output Rules Example 1: y(n)= 2x(n), sample-by-sample processing H x0 , x1, x2 , x3 , , 2x0 ,2x1,2x2 ,2x3 , , Example 2: y(n)= 2x(n)+3x(n − 1)+4x(n − 2), block processing Example 3: y(n)= x(2n) H x0 , x1, x2 , x3 , x4 , x5 , x6 , x0 , x2 , x4 , x6 , Linearity and Time Invariance Linear system: has the property that the output signal due to a linear combination of two or more input signals can be obtained by forming the same linear combination of the individual outputs if y1(n) and y2(n) are the outputs due to the inputs x1(n) and x2(n), then the output due to the linear combination of inputs x(n) a1 x1 (n) a2 x2 (n) is given by the linear combination of outputs y(n) a1 y1 (n) a2 y2 (n) Testing linearity: CuuDuongThanCong.com https://fb.com/tailieudientucntt Linearity and Time Invariance Example 4: Test the linearity of the discrete-time systems defined by y(n) x(n) and y(n) x (n) Linearity and Time Invariance Time Invariance system: is a system that remains unchanged over time This implies that if an input is applied to the system today causing a certain output to be produced, then the same output will also be produced tomorrow if the same input is applied Right translation: Testing time invariance: delaying the input causes the output to be delayed by the same amount: CuuDuongThanCong.com https://fb.com/tailieudientucntt Linearity and Time Invariance Example 5: Test the time invariance of the discrete-time systems defined by y(n) nx(n) and y(n) x(2n) Impulse Response Impulse response of an LTI system: Linear time-invariant systems are characterized uniquely by their impulse response sequence h(n), which is defined as the response of the system to a unit impulse δ(n) 1, if 0, if ( n) Transform function: n0 n0 H (n) h(n) Sample-by-sample processing: H 1,0,0,0, h0 , h1, h2 , h3 , CuuDuongThanCong.com https://fb.com/tailieudientucntt Impulse Response Delayed impulse responses: time invariance implies H (n D) h(n D) Impulse Response Impulse response of an LTI system: linearity implies H (n) (n 1) (n 2) h(n) h(n 1) h(n 2) Arbitrary input: {x(0), x(1), x(2), } can be thought of as the linear combination of shifted and weighted unit impulses: x(n) x(0) (n) x(1) (n 1) x(2) (n 2) Its output: y(n) x(0)h(n) x(1)h(n 1) x(2)h(n 2) CuuDuongThanCong.com https://fb.com/tailieudientucntt Impulse Response LTI form of convolution: y(n) x(m)h(n m) m Summation could extend over negative values of m, depending on the input signal Direct form of convolution: y(n) h(m) x(n m) m FIR and IIR Filters FIR: has impulse response h(n) that extends only over a finite time interval, say ≤ n ≤ M, and is identically zero beyond that h0 , h1, h2 , h3 , , hM ,0,0,0, Filter order: M Filter length: length of the impulse response vector h = [h0 , h1, , hM] Lh M Impulse response coefficients: h = [h0 , h1, , hM] are referred to by various names, such as filter coefficients, filter weights, or filter taps FIR filtering equation: M y (n) h(m) x(n m) m 0 CuuDuongThanCong.com https://fb.com/tailieudientucntt FIR and IIR Filters IIR: has an impulse response h(n) of infinite duration, defined over the infinite interval ≤ n < ∞ IIR filtering equation: y (n) h(m) x(n m) m 0 Constant coefficient linear difference equations: This I/O equation is not computationally feasible Therefore, we must restrict our attention to a subclass of IIR filters, namely, those filter coefficients are coupled to each other through constant coefficient linear difference equations: M L i 1 i 1 h(n) h(n i) bi (n i) Difference equation for y(n): M L i 1 i 1 y (n) y (n i) bi x(n i) FIR and IIR Filters Example 6: Determine the impulse response h of the following FIR filters CuuDuongThanCong.com a) y (n) x(n) 3x(n 1) x(n 2) x(n 3) b) y (n) x(n) x(n 4) https://fb.com/tailieudientucntt FIR and IIR Filters Example 7: Determine the I/O difference equation of an IIR filter whose impulse response coefficients h(n) are coupled to each other by the difference equation h(n) h(n 1) (n) FIR and IIR Filters Example 8: Suppose the filter coefficients h(n) satisfy the difference equation h(n) ah(n 1) (n) where a is a constant Determine the I/O difference equation relating a general input signal x(n) to the corresponding output y(n) CuuDuongThanCong.com https://fb.com/tailieudientucntt Causality Causal signal: A causal or right-sided signal x(n) exists only for n ≥ and vanishes for all negative times n ≤ −1 Anti-causal signal: An anticausal or left-sided signal exists only for n ≤ −1 and vanishes for all n ≥ Mixed signal: A mixed or double-sided signal has both a left-sided and a rightsided part LTI systems can also be classified in terms of their causality properties depending on whether their impulse response h(n) is causal, anticausal, or mixed Stability Description: a system is stable if the output remains bounded by some bound |y(n)| ≤ B if its input is bounded, say |x(n)| ≤ A Necessary and sufficient condition: h( n) n Stability is absolutely essential in hardware or software implementations of LTI systems because it guarantees that the numerical operations required for computing the I/O convolution sums or the equivalent difference equations remain well behaved and never grow beyond bounds The concepts of stability and causality are logically independent, but are not always compatible with each other CuuDuongThanCong.com https://fb.com/tailieudientucntt Stability Example 9: Consider the following four examples of h(n): Stability Homework: provided in class CuuDuongThanCong.com https://fb.com/tailieudientucntt 10 ... Causal signal: A causal or right-sided signal x(n) exists only for n ≥ and vanishes for all negative times n ≤ −1 Anti-causal signal: An anticausal or left-sided signal exists only for n ≤... the time invariance of the discrete-time systems defined by y(n) nx(n) and y(n) x(2n) Impulse Response Impulse response of an LTI system: Linear time-invariant systems are characterized... unit impulse δ(n) 1, if 0, if ( n) Transform function: n0 n0 H (n) h(n) Sample-by-sample processing: H 1,0,0,0, h0 , h1, h2 , h3 , CuuDuongThanCong.com https://fb.com/tailieudientucntt