04 Discrete-Time Signal and System

download 04 Discrete-Time Signal and System

of 57

description

Time signal

Transcript of 04 Discrete-Time Signal and System

  • UEEA 2183

    DIGITAL SIGNAL PROCESSINGJAN 2016

    1

  • TOPIC 2

    Discrete-Time Signal and System

    2

  • Frequency of Sinusoidal Sequences Consider 1 = cos 1 + and 2 = cos 2 +

    with 0 1 < 2 and 2 2 2 + 1where k is any positive integer.

    If 2 = 1 + 2,then 2 = cos 2 + = cos 1 + 2 + = cos 1 + + 2= cos 1 + = 1

    3

  • Frequency of Sinusoidal Sequences Thus, 1 = cos is the same as

    2 = cos + 2 where k is an integer. It is similar to cos = cos + 2 , i.e., a cosine function

    is the same when it is shifted by integer values of 2. E.g., the signal 1 = cos 0.1 is the same as the

    signal 2 = cos 2.1 = cos 0.1 + 2 . E.g. 3 = cos 1.9 = cos 2 0.1= cos 2 cos 0.1 + sin 2 sin 0.1= cos 0.1 = 1

    4

  • Frequency of Sinusoidal Sequences Consider 1 = cos 1 and 2 = cos 2

    with 0 1 < and 2 2. Let 2 = 2 1,

    then 2 = cos 2 1 = cos 1 = 1 Hence, a sinusoidal sequence with 2 in the range 2 2 assumes the identity of a sinusoidalsequence with 1 = 2 2 in the range 0 1 < .

    The frequency is called the folding frequency.

    5

  • Frequency of Sinusoidal Sequences

    6

  • Frequency of Sinusoidal Sequences The frequency of oscillation of = A cos

    increases as increases from 0 to , and then thefrequency of oscillation decreases as increases from to 2.

    Therefore, for discrete-time sinusoidal sequence, thehighest frequency possible is = radians/sample. Atthis frequency, there are 2 samples for 1 complete cycle.

    7

  • Frequency of Sinusoidal Sequences The time variable, t of the continuous-time signal is

    related to the time variable, n of the discrete-time signalonly at discrete-time instant, tn given by

    = = = 2where Ts = sampling interval

    fs = sampling frequency, = 1 = sampling angular frequency, = 2

    8

  • Frequency of Sinusoidal Sequences Given = sin 2 = sin .

    The corresponding discrete-time signal is

    = sin = sin 2 = sin where = 2

    = is the normalized angular frequency

    of (unit is radians per sample). Analog sinusoidal functions with different frequencies may

    have the identical sampled signals with same period.9

  • Frequency of Sinusoidal Sequences E.g. sin 0.3 and sin 0.1 have the same period

    20Ts2

    0.3 = 203 20.1 = 201 , even though sin 0.3has a rate of change 3 times as fast as sin 0.1 .

    E.g. Consider 3 sequences generated by uniformlysampling the 3 cosine functions of frequencies 3 Hz, 7 Hzand 13 Hz, respectively with sampling rate of 10 Hz.1 = cos 6 , 1 = cos 0.62 = cos 14 , 2 = cos 1.43 = cos 26 , 3 = cos 2.6

    10

  • Frequency of Sinusoidal Sequences

    1 = solid line, 2 = dashed line, 3 = dashed-dot line11

  • Frequency of Sinusoidal Sequences From the plots, each sequence has exactly the same

    sample value for any given n. It can be verified that2 = cos 1.4 = cos 2 0.6 = cos 0.63 = cos 2.6 = cos 2 + 0.6 = cos 0.6Therefore, 1 , 2 and 3 are identical.

    A continuous-time sinusoidal signal of higher frequencyacquiring the identity of a sinusoidal sequence of lowerfrequency after sampling is called aliasing.

    12

  • Frequency of Sinusoidal Sequences Given = cos 2 and = cos 2 . In general, the family of continuous-time sinusoids

    , = cos 2 + 2 , k = 0, 1, 2, leads to identical sampled signals:, = cos 2 + 2 = cos 2 + 2= cos 2=

    13

  • Frequency of Sinusoidal Sequences E.g. sin 0.1 with sampling period Ts = 1 (fs = 1) can

    have the following continuous-time sinusoids:sin + 2 = sin 0.1 + 2 1 = sin 0.1 2 when k = -1= sin 0.1 when k = 0= sin 0.1 + 2 when k =1which are sin 0.1 , sin 2.1 , sin 1.9 and so on.where =

    = 0.1

    1= 0.1

    Since 0.1 has the smallest magnitude, the frequency ofthe digital sinusoid sin 0.1 is 0.1 rad/s. 14

  • Frequency of Sinusoidal Sequences Since where

    = digital frequency

    = analog frequency

    Relationship of the frequencies between digital andanalog sinusoid. Digital

    /Ts

    Analog0

    Ts__ 2

    Ts__

    Ts-__2

    Ts__-

    Ts-__

    Ts__

    15

  • Frequency of Sinusoidal SequencesExample 1Find the frequency of the digital signal sin 4.4 if thesampling period is Ts = 0.1.

    Solutionsin 4.4 = sin 4 + 0.4 = sin 0.4 =

    = = 0.40.1 = 4 /

    16

  • Frequency of Sinusoidal SequencesExample 2Determine the discrete-time signal v[n] obtained byuniformly sampling a continuous-time signal va(t) composedof a weighted sum of 5 sinusoidal signals of frequencies30 Hz, 150 Hz, 170 Hz, 250 Hz and 330 Hz, at a samplingrate of 200 Hz, as given below:

    = 6 cos 60 + 3 sin 300 + 2 cos 340+ 4 cos 500 + 10 sin 66017

  • Frequency of Sinusoidal SequencesSolution

    = = = 200 = 6 cos 0.3 + 3 sin 1.5 + 2 cos 1.7+ 4 cos 2.5 + 10 sin 3.3= 6 cos 0.3 + 3 sin 2 0.5 + 2 cos 2 0.3 + 4 cos 2 + 0.5 + 10 sin 4 0.7 = 6 cos 0.3 3 sin 0.5 + 2 cos 0.3+ 4 cos 0.5 10 sin 0.7= 8 cos 0.3 + 5 cos 0.5 + 0.6435 10 sin 0.7

    18

  • Frequency of Sinusoidal Sequences The components3 sin 1.5 , 2 cos 1.7 , 4 cos 2.5 , 10 sin 3.3 have

    been aliased into the components3 sin 0.5 , 2 cos 0.3 , 4 cos 0.5 , 10 sin 0.7 .

    The resulting discrete-time sequence composed of only 3sinusoidal sequences of : 0.3, 0.5 and 0.7.

    19

  • Frequency of Sinusoidal Sequences Identical discrete-time signal is also generated by

    uniformly sampling at a 200 Hz sampling rate thefollowing continuous-time signals: = 8 cos 60 + 5 cos 100 + 0.6435

    10 sin 140and = 2 cos 60 + 4 cos 100 + 10 sin 260+6 cos 460 + 3 sin 700

    20

  • Linear Systems A linear system obeys the homogeneity and superposition

    principles. Homogeneity means if the system output is given

    input , then given input , the output is a . Superposition principle states that if input 1 and2 produces output 1 and 2 respectively, thenan input of 1 + 2 produce an output 1 + 2 .

    Thus a linear system fed with the input a1 + 2 willproduce the output a1 + b2 .

    21

  • Linear Systems A useful property of linear systems is frequency

    preservation. If the input contains several frequencies,then the output will contain only those frequencies.

    Non-linear system does not preserve frequencies.E.g. = 2. With = sin ,

    = 2 = 1 cos 22which does not contain the original frequency .

    22

  • Time Invariant Systems A time invariant system is one where system properties do

    not change with time. The only effect of time-shifting an input will just result in a

    corresponding time-shift of the output. An example of a time-invariant system with output

    = + 2 1If the input is delayed by 0, then the output is

    0 + 2 0 1 = 0which is the output delayed by 0.

    23

  • Time Invariant Systems An example of a time-dependent system with output

    = 1 + 0.5 If the input is delayed by 0, then the output is

    0 1 + 0.5 0 0 Time invariant system also preserves frequencies. Time-shifting the input frequency components will only

    affect the phase of the output components.

    24

  • Time Invariant Systems Linear Time-Invariant (LTI) systems are easy to analyze,

    since Fourier techniques allow us to decompose anysignals into sums of sinusoids. The output is a weightedsum of the same sinusoids shifted in phase.

    The time-invariance property ensures that for a specifiedinput, the output of the system is independent of the timethe input is being applied.

    25

  • Other System Properties LTI systems also possess the properties of association

    and commutation. The associative property allows us to break a big

    system into smaller ones and analyse separately. The commutative property means that the order of

    cascaded subsystems in a large system can berearranged without affecting the final output.

    Causal systems are those where there is no output untilthe application of an input.

    26

  • Other System Properties Thus the present output of causal systems only depends

    on present and past samples of the input. Changes in output samples do not precede changes in

    the input samples. A stable system is one which produces a finite or

    bounded output if the input is bounded. Such systems are sometimes described as bounded input

    bounded output (BIBO).

    27

  • Other System Properties E.g. Given an output

    = +1 1 +=0

    , 0where 1 = initial condition.If > 1, lim

    =

    The system is unstable since the output is unboundedgiven a bounded input.

    28

  • Other System Properties E.g. Given the output of the M-point moving average filter

    = 1=0

    1

    For a bounded input < = 1

    =0

    1

    1=0

    1

    < 1

    < indicating that the system is BIBO stable.

    29

  • Other System Properties An invertible system is one where can be used to

    determine . An example of a non-invertible system is one with = 2. If output is 4, input can be 2.

    A memoryless system is one where the output dependsonly on the present input.

    30

  • Digital Signals as Sum of Impulses Any digital signal can be represented as a series of

    impulses, = + 2 + 2 + 1 + 1 + 0 + 1 1 + 2 2 +

    or For causal signals,

    = =

    ==0

    31

  • Digital Signals as Sum of Impulses In graphical form, the signal

    is just a sum of the variousweighted impulses:

    1-1 0n

    x[n]

    1-1 0n

    x[-1] [n+1]

    1-1 0n

    x[0] [n]

    1-1 0n

    x[1] [n-1]

    32

  • Impulse Response When the unit impulse, is inputted into an LTI system,

    the output is called the natural or impulse response, of the system.

    0n

    LTISystem

    0n

    33

  • Impulse ResponseExample 3Work out the first 4 sample values of the impulse responsefrom the filter shown.

    SolutionHere, = 0.9 1 + By setting = , the impulse response is

    = 0.9 1 + x[n]

    z-1-0.9

    y[n]+_

    34

  • Impulse ResponseThe system is causal. Therefore,

    0 = 0.9 1 + 0 = 0 + 1 = 1 1 = 0.9 0 + 1 = 0.9 1 + 0 = 0.9 2 = 0.9 1 + 2 = 0.9 0.9 + 0 = 0.81 3 = 0.9 2 + 3 = 0.9 0.81 + 0 = 0.729

    The impulse response oscillates about zero and decays astime passes by.

    35

  • Digital Convolution Consider the digital signal shown:

    Suppose it is passed through an LTI system with impulseresponse shown:

    1 23

    -10n

    x[n]

    -1

    1 2

    0 nh[n]

    36

  • Digital Convolution The output due to the first non-zero component of is weighted by 1 and shifted left one step becauseof homogeneity and time invariance properties of LTIsystems.

    The next output due to the second non-zero component of is weighted by 0 with no time shift.

    01

    -1

    2

    n

    x[-1] h[n+1]

    0

    2

    -2

    4

    n

    x[0] h[n]

    37

  • Digital Convolution Similarly the output due to 1 is 1 1 , and the

    output due to the last non-zero input component is 2 2 .

    Since the LTI system also obeys the superpositionprinciple, the total non-zero output due to is

    = 1 + 1 + 0 + 1 1 + 2 238

  • Digital Convolution0

    0

    0

    1

    -1

    2

    2

    -2

    4

    3

    -3

    6

    n

    n

    n

    x[1] h[n-1]

    x[0] h[n]

    x[-1] h[n+1]

    0 -1

    1

    -2

    n

    x[2] h[n-2]

    0

    1

    -2

    n

    y[n]13

    0

    7

    39

  • Digital Convolution In general, the output due to an input from an LTI system

    with impulse response is just

    = =

    This is called the digital convolution of with . It isdone by flipping the impulse response (time-reversing it), thenshifting, multiplying it with and summing the products.

    Thus the output of any digital LTI system is just the digitalconvolution of the input with the systems impulse response.

    40

  • Digital ConvolutionExample 4The impulse response of an LTI system is

    0 = 2; 1 = 1; 2 = 1and = 0 for all other .Input is:

    1 = 1; 0 = 2; 1 = 3; 2 = 1and zero elsewhere.Find the output 2 .

    41

  • Digital ConvolutionSolution

    2 = =1

    2

    2 = 1 3 + 0 2 + 1 1 + 2 0= 1 0 + 2 1 + 3 1 + 1 2= 142

  • Averaging Systems Suppose we have a signal which fluctuates greatly, like

    stock prices, and we want to smooth out the signal. We can do this by using a moving average filter. For

    example, a 5-point moving average filter will output

    = 0.2 + 2 + + 1 + + 1 + 2 Any short-term fluctuations will be made smaller because

    only 20% of each sample value contributes to the output.43

  • Averaging Systems This filter can be obtained by time convolving the input

    with the impulse response

    = 0.2 2 20 In general, if we want a 2 + 1 point moving average

    filter, we can design the filter to have the impulse response

    = 1/ 2 + 1 0 44

  • Averaging Systems Note that the filter is non-causal since it requires future

    inputs for present output. This is not a problem if we pre-record the data first, or we

    delay the output until all the inputs required are available.

    45

  • Properties of Convolution Commutative: =

    Given the definition of the convolution sum:

    = = =

    Substituting = , we get =

    =

    = 46

  • Properties of Convolution Distributive: 1 + 2 = 1 + 2 1 + 2 =

    =

    1 + 2 =

    =

    1 + =

    2 = 1 + 2 47

  • Properties of Convolution Associative: = =

    =

    =

    = =

    =

    48

  • Properties of ConvolutionSubstituting = ,=

    =

    =

    = =

    = 49

  • Properties of Convolution Two subsystems in parallel is equivalent to a single

    system with impulse response the sum of the 2subsystem impulse responses.

    50

  • Transient Response When a signal is applied to a system, the output will

    experience a start-up transient before settling to thesteady-state response.

    A stop transient is also generated when the input isremoved.

    Transients are important because they mask the steady-state response, and may also be large enough to damagethe system.

    51

  • Transient Response If a system is described with a difference equation

    =0

    ==0

    where = input of the system = output of the system

    , = constantsmax(N, M) = order of the discrete-time system

    (order of the difference equation)52

  • Transient Response If the system is assumed to be causal, then

    = =1

    0 +

    =0

    0

    provided 0 0. The output response consists of 2 components

    = + where = complementary or homogeneous solution

    = particular solution53

  • Transient Response The transient or natural response is given by the

    homogeneous solution or zero-input ( = 0) response.=0

    =0 The steady-state or forced response is given by the

    particular solution ( 0 ) or zero-state response(response with initial state of zero).

    54

  • Transient Response The transient response is caused by the non-zero initial

    conditions in the system decaying to zero. The steady-state response is due entirely to the input

    signal. Convolving the input with the impulse response of an LTI

    system produces the total response from the system.

    55

  • Transient ResponseExample 5A causal FIR discrete-time system is characterized by animpulse response = 4,5,6,3 , 0 3 . Itsoutput samples for an input are then computed using

    = 4 5 1 + 6 2 3 3For a unit step sequence input,

    0 = 4 0 = 4 1 = 4 1 5 0 = 1 2 = 4 2 5 1 + 6 0 = 5

    56

  • Transient Response 3 = 4 3 5 2 + 6 1 3 0 = 2 4 = 4 4 5 3 + 6 2 3 1 = 2 5 = 4 5 5 4 + 6 3 3 2 = 2

    It follows from the above that = 2 for 3, or theoutput has reached the steady-state at = 3.The output samples for = 0,1,2 are composed of thesamples of the transient and the steady-state responses.

    57

    UEEA 2183DIGITAL SIGNAL PROCESSINGTOPIC 2Frequency of Sinusoidal SequencesFrequency of Sinusoidal SequencesFrequency of Sinusoidal SequencesFrequency of Sinusoidal SequencesFrequency of Sinusoidal SequencesFrequency of Sinusoidal SequencesFrequency of Sinusoidal SequencesFrequency of Sinusoidal SequencesFrequency of Sinusoidal SequencesFrequency of Sinusoidal SequencesFrequency of Sinusoidal SequencesFrequency of Sinusoidal SequencesFrequency of Sinusoidal SequencesFrequency of Sinusoidal SequencesFrequency of Sinusoidal SequencesFrequency of Sinusoidal SequencesFrequency of Sinusoidal SequencesFrequency of Sinusoidal SequencesLinear SystemsLinear SystemsTime Invariant SystemsTime Invariant SystemsTime Invariant SystemsOther System PropertiesOther System PropertiesOther System PropertiesOther System PropertiesOther System PropertiesDigital Signals as Sum of ImpulsesDigital Signals as Sum of ImpulsesImpulse ResponseImpulse ResponseImpulse ResponseDigital ConvolutionDigital ConvolutionDigital ConvolutionDigital ConvolutionDigital ConvolutionDigital ConvolutionDigital ConvolutionAveraging SystemsAveraging SystemsAveraging SystemsProperties of ConvolutionProperties of ConvolutionProperties of ConvolutionProperties of ConvolutionProperties of ConvolutionTransient ResponseTransient ResponseTransient ResponseTransient ResponseTransient ResponseTransient ResponseTransient Response