Discrete-time Systems in the Time Domain Domain Chapter 4 Chapter - - PowerPoint PPT Presentation

discrete time systems in the time domain domain
SMART_READER_LITE
LIVE PREVIEW

Discrete-time Systems in the Time Domain Domain Chapter 4 Chapter - - PowerPoint PPT Presentation

Discrete-time Systems in the Time Domain Domain Chapter 4 Chapter 4 Sections 4.1 - 4.7 Dr. Iyad Jafar Outline Outline Definition Examples Classification of Discrete-time Systems Impulse and Step Responses Linear


slide-1
SLIDE 1

Discrete-time Systems in the Time Domain Domain

Chapter 4 Chapter 4 Sections 4.1 - 4.7

  • Dr. Iyad Jafar
slide-2
SLIDE 2

Outline Outline

Definition Examples Classification of Discrete-time Systems Impulse and Step Responses Linear Time-Invariant Systems (LTI)

F D l LTI D T

Finite-Dimensional LTI Discrete-Time

Systems y

2

slide-3
SLIDE 3

Def Definition nition

A discrete-time system is a process that transforms a

given input sequence x[n] into another output sequence g p q p q y[n] with desirable properties.

y[n] T(x[n])

  • Discrete-time systems may have more then one input

y y p and/or output

3

slide-4
SLIDE 4

Exam Examples ples

Accumulator

The output y[n] at any instant of time n is the sum of all p y[ ] y previous samples up to instant n. h h f h

  • r, the output at instant n is the

sum of the current sample and the previous output y[n-1]

4

slide-5
SLIDE 5

Exam Examples ples

The M-point Moving Average (MA) Filter

The output y[n] at any instant n is the average of the p y[ ] y g current sample x[n] and the previous M-1 samples. I d f h d h It is used for smoothing rapid variations in the input sequence.

1.5 x[n] y[n] 0.5 1 [ n ] y[ ]

  • 0.5

x[

M=3

5

5 10 15 20

  • 1

n

slide-6
SLIDE 6

Exam Examples ples

The M-point Moving Average (MA) Filter

Example 3.1: Show that y[n] can be written as p y[ ] y[n] = y[n-1] + 1/M (x[n] – x[n-M])

6

slide-7
SLIDE 7

Exam Examples ples

The Linear Interpolator

Used to estimate sample values between pairs of adjacent p p j sample values of a discrete-time sequence. Factor-of-2 Interpolator Factor of 2 Interpolator Factor-of-3 Interpolator

7

slide-8
SLIDE 8

Exam Examples ples

The Linear Interpolator

U li

3 4 ] 3 4 ]

Up-sampling

1 2 x[ n ] 1 2 y[ n ] 2 4 6 8 10 12 n 2 4 6 8 10 12 n

Interpolation

3 4 1 2 z[ n ]

8

2 4 6 8 10 12 n

slide-9
SLIDE 9

Classification of Discre Classification of Discrete-time Syst

  • time Systems

ems

Linearity

In a linear system, if y1[n] is the output due to x1[n] and y , y1[ ] p

1[ ]

y2[n] is the output due to x2[n], then for an input the output is given by for all possible values of α, β and n Example 3.2: a) y[n] = n x[n] ) y[ ] [ ] b) [ ] = ( [ ])2 b) y[n] = (x[n])2

9

slide-10
SLIDE 10

Classification of Discre Classification of Discrete-time Syst

  • time Systems

ems

Shift-invariant

For a shift-invariant system, if y1[n] is the output due to y , y1[ ] p the input x1[n], then the output to an input sequence is basically where no is an integer. If the independent variable is time, the system is called time-invariant system. y Generally, in time-invariant systems, the output of the system does not depend on the time at which the input is y p p applied.

10

slide-11
SLIDE 11

Classification of Discre Classification of Discrete-time Syst

  • time Systems

ems

Shift-invariant

Example 3.3: Determine whether the following p g systems are time-invariant. a) y[n] = x[n] – x[n-3] a) y[n] x[n] x[n 3] b) y[n] = n x[n] c)

x[n / L] , n = 0, L, 2L, 3L ... y[n] 0 , otherwise

⎨ ⎩

11

slide-12
SLIDE 12

Classification of Discre Classification of Discrete-time Syst

  • time Systems

ems

Causality

A system is said to be causal if the computation of the y p

  • utput sample no depends on the input samples in x[n]

for n ≤ no.

  • Example

3 4: Determine whether the following Example 3.4: Determine whether the following systems are causal. a) y[n] = x[n] – x[n-5] b) y[n] = x[n] - 4 x[n+5] c) y[n] = x[3 – n] ) y[ ] [ ]

12

slide-13
SLIDE 13

Classification of Discre Classification of Discrete-time Syst

  • time Systems

ems

Stability

There are many definitions for stability. In this course, a y y , system is said to be bounded-input bounded-output (BIBO) if for every bounded-input sequence ( ) y p q the output is also bounded. E ample 3 5: Th l t i t BIBO t It Example 3.5: The accumulator is not a BIBO system. It is not stable when the input is x[n] = u[n].

13

slide-14
SLIDE 14

Classification of Discre Classification of Discrete-time Syst

  • time Systems

ems

Passive and Lossless Systems

A discrete-time system is said to be passive if y p

2 2

y[n] x[n]

and it is said to be lossless if

n n

  • 2

2 n n

y[n] x[n]

Example 3.6: Consider the system y[n] = a x[n – N], N > 0.

14

slide-15
SLIDE 15

Classification of Discre Classification of Discrete-time Syst

  • time Systems

ems

Memory Systems

A system is a memory (dynamic) system if the y y ( y ) y computation of the output requires storing samples from the input. Otherwise, it is a static system. p , y y[n] = 2 x[n] y[n] = x[n] + x[n 2] y[n] = x[n] + x[n-2]

Recursive Systems

A system is said to be recursive when the computation of the output sample requires the knowledge of the previous output sample(s). y [n] = y[n-3] + 6 x[n] y y y[n] = x[n] - x[n-3]

15

slide-16
SLIDE 16

Im Impulse pulse and St and Step R ep Responses sponses

Systems are usually characterized by stimulating them

with typical signals. The response of the system reflects yp g p y the properties of the system for similar sequences.

The response of a discrete-time system to a unit sample δ[ ] i

ll d h i l sequence δ[n] is called the unit sample response or simply, the impulse response, and is denoted by h[n].

The response of a discrete-time system to a unit step

p y p sequence μ[n] is called the unit step response or simply, the step response, and is denoted by s[n]. p p , y [ ]

16

slide-17
SLIDE 17

Im Impulse pulse and St and Step R ep Responses sponses

Example 3.7: a) y[n] = α x[n] + α x[n+1] + α x[n-1] + α x[n-2] a) y[n]

α1 x[n] + α2 x[n+1] + α3 x[n-1] + α4 x[n-2] The impulse response of the system is obtained by setting x[n] = δ[n] x[n] = δ[n] h[n] = α δ[n] + α δ[n+1] + α δ[n 1] + α δ[n 2] = h[n] h[n] = α1 δ[n] + α2 δ[n+1] + α3δ[n-1] + α4δ[n-2] = h[n] h[n] = {α2 , α1 , α3 , α4 } b) y[n] = x[n] + (x[n-1] + x[n+1]) /2 h[n] = δ[n] + 0.5 δ[n - 1] + 0.5 δ[n + 1] h[n] = {0.5, 1 , 0.5} , -1 ≤ n ≤ 1

17

slide-18
SLIDE 18

Linear Time-In Linear Time-Invariant Syst riant Systems ems

Linear Time-Invariant (LTI) System -A system satisfying

both the linearity and the time-invariance properties both the linearity and the time invariance properties

LTI systems are mathematically easy to analyze and

h i d l d i characterize, and consequently, easy to design

There are highly useful signal processing algorithms have

g y g p g g been developed utilizing this class of systems over the last several decades

Linear

time-invariant systems can be completely characterized by their impulse response h[n] In other words characterized by their impulse response h[n]. In other words, the output of a LTI system for any sequence can be computed by knowing its impulse response! We show this in the y g p p following slides.

18

slide-19
SLIDE 19

Linear Time-In Linear Time-Invariant Syst riant Systems ems

Let h[n] denote the impulse response of a LTI discrete-

time system time system

We compute its output y[n] for the input

0 δ + 2 +1 δ 1 δ 2 + 0 7 δ x[n] = 0.5δ[n + 2] +1.5δ[n −1] − δ[n − 2] + 0.75δ[n − 5]

As the system is linear, we can compute its outputs

for each member of the input separately and add the individual outputs to determine y[n].

Since the system is time-invariant δ[n + 2] → h[n + 2]

[ ] [ ]

δ[n −1] → h[n −1] δ[n − 2] → h[n − 2] δ[n 2] → h[n 2] δ[n − 5] → h[n − 5]

19

slide-20
SLIDE 20

Linear Time-In Linear Time-Invariant Syst riant Systems ems

Likewise, as the system is linear

0 5δ[n + 2] → 0 5h[n + 2] 0.5δ[n + 2] → 0.5h[n + 2] − δ[n − 2] → −h[n − 2] 1 5δ[ h 1.5δ[n −1] →1.5h[n −1] 0.75δ[n − 5] → 0.75h[n − 5]

Hence because of the linearity property we get

y[n] = 0.5h[n + 2] +1.5h[n −1]− h[n − 2] + 0.75h[n − 5]

Now, any arbitrary input sequence x[n] can be expressed as a

linear combination of delayed and advanced unit sample y p sequences in the form

20

slide-21
SLIDE 21

Linear Time-In Linear Time-Invariant Syst riant Systems ems

The response of the LTI system to an input x[k]δ[n − k] will

be x[k]h[n − k]. Hence, the response y[n] to an input be x[k]h[n k]. Hence, the response y[n] to an input will be which can be alternately written as

As we discussed in Chapter 2 this summation is called the As we discussed in Chapter 2, this summation is called the

convolution sum of the sequences x[n] and h[n] and represented compactly as represented compactly as

21

slide-22
SLIDE 22

Linear Time-In Linear Time-Invariant Syst riant Systems ems

Properties of Convolution 1. The convolution between a length-M and length-N 1. The convolution between a length M and length N sequence has a length of M + N – 1 2 The convolution between a sequence defined over N1 ≤ n ≤ 2. The convolution between a sequence defined over N1 ≤ n ≤ M1 and a sequence defined over N2 ≤ n ≤ M2extends over N1 + N2 ≤ n ≤ M1+ M2

1 2 1 2

3. Convolution is commutative 4. Convolution is distributive 5. Convolution is associative

22

slide-23
SLIDE 23

Linear Time-In Linear Time-Invariant Syst riant Systems ems

Stability of LTI Systems

A LTI system is stable if its impulse response h[n] is A LTI system is stable if its impulse response h[n] is absolutely summable, i.e.

Proof (page 159):

n

S | h[n]|

Proof (page 159):

23

slide-24
SLIDE 24

Linear Time-In Linear Time-Invariant Syst riant Systems ems

Stability of LTI Systems

Example 3.8: Investigate the stability of the system whose impulse response is h[n] = Bn u[ n 1] impulse response is h[n] = -B u[-n -1].

24

slide-25
SLIDE 25

Linear Time-In Linear Time-Invariant Syst riant Systems ems

Causality of LTI Systems

A LTI system is said to be causal if its impulse response h[n] is A LTI system is said to be causal if its impulse response h[n] is also a causal sequence, i.e. h[n] = 0 , n < 0. Proof (page 161) Proof (page 161)

25

slide-26
SLIDE 26

Linear Time-In Linear Time-Invariant Syst riant Systems ems

Interconnection of LTI Systems

1.

Cascade Connection: The impulse response h[n] of the

1.

Cascade Connection: The impulse response h[n] of the cascade of two system with impulse response h1[n] and h2[n] is A typical application for cascading systems is the identification of the inverse system h2[n] for some system y y h1[n] such that

26

slide-27
SLIDE 27

Linear Time-In Linear Time-Invariant Syst riant Systems ems

Interconnection of LTI Systems

Example 3 9: Determine the inverse system for h[n] = u[n] Example 3.9: Determine the inverse system for h[n] = u[n].

27

slide-28
SLIDE 28

Linear Time-In Linear Time-Invariant Syst riant Systems ems

Interconnection of LTI Systems

2.

Parallel Connection: the impulse response h[n] of two

2.

Parallel Connection: the impulse response h[n] of two systems with impulse response h1[n] and h2[n] that are connected in parallel is

28

slide-29
SLIDE 29

Linear Time-In Linear Time-Invariant Syst riant Systems ems

Interconnection of LTI Systems

Example 3 10: Determine the impulse response of the Example 3.10: Determine the impulse response of the system shown below if

h [n] = δ[n] + 0 5 δ[n 1]

h3[n]

h1[n] = δ[n] + 0.5 δ[n-1] h2 [n] = 4 δ[n] h [ ] = (0 5)n [ ]

h1[n] h [n] + x[n] y[n]

h3[n] = (0.5)n u[n]

h2[n]

29

slide-30
SLIDE 30

Linear Time-In Linear Time-Invariant Syst riant Systems ems

LTI systems may have finite impulse response (FIR) such that

h[n] = 0 for n < N1 and n > N2. Such systems usually h[n] 0 for n N1 and n

  • N2. Such systems usually

correspond to non-recursive systems and the convolution sum is given by g y

2 1

N k N

y[n] h[k] x[n-k]

FIR systems require finite number of multiplications and additions

1

k N

additions Example 3.11: Impulse response of moving average filter

M 1

1 y[n] x[n-k]

M 1

1 h[n] [n-k]

30

k 0

y[ ] [ ] M

k 0

[ ] [ ] M

slide-31
SLIDE 31

Linear Time-In Linear Time-Invariant Syst riant Systems ems

On the other hand, some LTI systems have infinite impulse

response (IIR) such that h[n] is infinite in length. Such response (IIR) such that h[n] is infinite in length. Such systems usually correspond to recursive systems and the convolution sum is given by g y

n

y[n] h[k] x[n-k] ∑

Note how the number of computations are finite but the

k 0

y[n] h[k] x[n k]

Note how the number of computations are finite but the complexity increases as n increases.

31

slide-32
SLIDE 32

Finit Finite-Dimensional L

  • Dimensional LTI Discre

I Discrete-Time ime S t S t Sys ystems ems

One popular and important class of LTI systems can be

expressed by a linear constant coefficient difference equation (LCCDE) of the form

  • r, after rearranging for y[n]

where dk and pk are constants where dk and pk are constants

The order of the difference equation is max(M,N)

q

Such systems are usually IIR systems in general

32

slide-33
SLIDE 33

Finit Finite-Dimensional L

  • Dimensional LTI Discre

I Discrete-Time ime S t S t Sys ystems ems

Example 3.12:

a) y[n] = 2 x[n] – 3x[n-1] + 4 x[n-2] b) y[n] = 5y[n-1] + x[n] – 3 x[n-3] b) y[n] 5y[n 1] x[n] 3 x[n 3] c) y[n] = 0.5 y[n-3] + x[n] / y[n-1]

33

slide-34
SLIDE 34

Finit Finite-Dimensional L

  • Dimensional LTI Discre

I Discrete-Time ime S t S t Sys ystems ems

For a LTI system described by a LCCDE, we can determine

the output y[n] in response to an arbitrary sequence x[n] recursively. Example 3.13: if x[n] = u[n] and y[n] = y[n-1] + 2 x[n], determine y[n] 0 ≤ n ≤ 3 assuming y[-1] = 0. n = 0 y[0] = y[-1] + 2 x[0] = 2 n = 1 y[1] = y[0] + 2 x[1] = 4 n = 1 y[1] = y[0] + 2 x[1] = 4 n = 2 y[2] = y[1] + 2 x[2] = 6

  • n = 3 y[3] = y[2] + 2 x[3] = 8

However, can we find y[n] in a closed form

, y[ ] expression?

34

slide-35
SLIDE 35

Finit Finite-Dimensional L

  • Dimensional LTI Discre

I Discrete-Time ime S t S t Sys ystems ems

The solution of a LCCDE can be expressed as The

complementary (homogeneous natural transient)

The

complementary (homogeneous, natural, transient) solution yc[n] depends on the nature of the system

The particular (non-homogeneous, forced response, steady

t t ) l ti [ ] d d th f f [ ] state) solution yp[n] depends on the form of x[n]

35

slide-36
SLIDE 36

Finit Finite-Dimensional L

  • Dimensional LTI Discre

I Discrete-Time ime S t S t Sys ystems ems

Computation of yc[n] Assumes x[n] = 0 and yc[n] = λn , thus, the LCCDE becomes The polynomial factors into (λ λ )(λ λ )

= 0 with each λ

The polynomial factors into (λ-λ1)(λ-λ2)… = 0, with each λi

satisfying the equation. Also, any combination of the solution also works also works.

Thus, the complementary solution becomes

with αi are constants determined from the initial conditions

36

slide-37
SLIDE 37

Finit Finite-Dimensional L

  • Dimensional LTI Discre

I Discrete-Time ime S t S t Sys ystems ems

In case the root has multiplicity of L, the complementary

solution becomes Example 3.14: Determine the complementary solution of Example 3.14: Determine the complementary solution of y[n] = 2 y[n-1] - y[n-2] – 2 x[n].

37

slide-38
SLIDE 38

Finit Finite-Dimensional L

  • Dimensional LTI Discre

I Discrete-Time ime S t S t Sys ystems ems

Computation of yp[n] The particular solution assumes the same form of x[n] scaled

by β

x[n] = A u[n] yp[n] = β u[n] x[n] = An u[n] yp[n] = β An u[n] x[n] = A cos(ωon) yp[n] = β cos(ωon)

If the assumed solution for yp[n] is the same as the

homogeneous solution, the assumed solution is multiplied by n

x[n] = 3n u[n] and yh[n] = 3n +2n yp[n] = β n 3n u[n]

38

slide-39
SLIDE 39

Finit Finite-Dimensional L

  • Dimensional LTI Discre

I Discrete-Time ime S t S t Sys ystems ems

Example 3.15: Solve the following LCCDE

y[n] = 3 y[n-1] + 4y[n-2] + x[n] + 2 x[n-1] given that x[n] = 3n u[n] and y[-1] = y[-2] = 0 g y y

39

slide-40
SLIDE 40

Finit Finite-Dimensional L

  • Dimensional LTI Discre

I Discrete-Time ime S t S t Sys ystems ems

Example 3.16: Solve the following LCCDE

y[n] = 4 y[n-1] - 4y[n-2] + x[n] given that x[n] = 4 u[n] and y[-1] = y[-2] = 1 g y y

40

slide-41
SLIDE 41

Finit Finite-Dimensional L

  • Dimensional LTI Discre

I Discrete-Time ime S t S t Sys ystems ems

Example 3.17: Solve the following LCCDE

y[n] = -2 y[n-1] + 3 y[n-2] - x[n-1] given that x[n] = 2 (-3)n u[n] and y[-1] = y[-2] = 0 g y y

41

slide-42
SLIDE 42

Finit Finite-Dimensional L

  • Dimensional LTI Discre

I Discrete-Time ime S t S t Sys ystems ems

Stability of LTI Systems - Revisited

A BIBO stable system has bounded output for every possible bounded input. For a system described by an LCCDE with the output y y p it can be proven that the system is stable if |λk| < 1 it can be proven that the system is stable if |λk| < 1. Proof (page 172)

42

slide-43
SLIDE 43

Matlab Matlab

  • Related functions
  • conv
  • deconv

deconv

  • impz
  • stepz
  • filter

43