Lecture 2 Review of Discrete-Time Signal and System Analysis

You might also like

Download as pdf or txt
Download as pdf or txt
You are on page 1of 41

Digital Signal Processing (ECN-312)

Lecture 2 (Review of discrete-time signal and system analysis)

Dheeraj Kumar

dheeraj.kumar@ece.iitr.ac.in

January 9, 2023
Table of Contents

1 Discrete-time signals: Sequences

2 Discrete-time systems
Types of discrete-time systems

3 Linear time-invariant (LTI) systems

2 / 41
Table of Contents

1 Discrete-time signals: Sequences

2 Discrete-time systems
Types of discrete-time systems

3 Linear time-invariant (LTI) systems

3 / 41
Mathematical representation of discrete-time
signals

❑ Discrete-time signals are represented mathematically as


sequences of numbers
❑ x = {x[n]}, −∞ < n < ∞
❑ n is an integer
❑ When x[n] is generated by sampling an analog signal xa (t) at time
nT (n is an integer)
❑ x[n] = xa (nT ), −∞ < n < ∞
❑ T : sampling period, T1 : sampling frequency

4 / 41
Continuous-time to discrete-time signal

5 / 41
Some basic sequences

6 / 41
Arbitrary sequence as a sum of scaled delayed
impulses

❑ An arbitrary sequence can be represented as a sum of scaled,


delayed impulses
❑ x[n] = ∞
P
k =−∞ x[k ]δ[n − k ]

❑ p[n] = a−3 δ[n + 3] + a1 δ[n − 1] + a2 δ[n − 2] + a7 δ[n − 7]

7 / 41
Exponential sequences

❑ Exponential sequences are extremely important in representing


and analyzing linear time-invariant discrete-time systems
❑ x[n] = Aαn
❑ A and α can be real or complex
❑ If A and α are real numbers, then the sequence is real
❑ If 0 < α < 1 and A is positive → sequence values are positive and
decrease with increasing n
❑ If −1 < α < 0 → sequence values alternate in sign, but decrease in
magnitude with increasing n
❑ If |α| > 1 → sequence grows in magnitude as n increases

8 / 41
Exponential sequences

9 / 41
Sinusoidal sequences

❑ General form: x[n] = Acos(ω0 n + ϕ)


❑ A and ϕ are real constants

10 / 41
Exponentially weighted sinusoidals

❑ Exponential sequence x[n] = Aαn with complex α has real and


imaginary parts that are exponentially weighted sinusoids
❑ α = |α|ejω0
❑ A = |A|ejϕ

x[n] = Aαn = |A|ejϕ |α|n ejω0 n
= |A||α|n ej(ω0 n+ϕ)
= |A||α|n cos(ω0 n + ϕ) + j|A||α|n sin(ω0 n + ϕ)

❑ |α| > 1 → sequence oscillates with an exponentially growing


envelope
❑ |α| < 1 → sequence oscillates with an exponentially decaying
envelope
❑ |α| = 1 → complex exponential sequence
❑ x[n] = |A|ej(ω0 n+ϕ) = |A|cos(ω0 n + ϕ) + j|A|sin(ω0 n + ϕ)
❑ Real and imaginary parts of x[n] vary sinusoidaly with n
11 / 41
exponentially weighted sinusoidals

12 / 41
Periodicity of sinusoidal sequences

❑ By analogy with the continuous-time case, ω0 is called the


frequency of the complex sinusoid or complex exponential
❑ ϕ is called the phase
❑ But n can only take integer values
❑ Some important differences between the properties of discrete-time
and continuous-time sinusoidal sequences
❑ In the continuous-time case, a sinusoidal signal is always periodic
ω0
with frequency 2π
❑ Not always the case for discrete-time signals

13 / 41
Periodicity of sinusoidal sequences

❑ For discrete-time sequence to be periodic


❑ x[n] = x[n + N], for all n
❑ The period N must be an integer
❑ Acos(ω0 n + ϕ) = Acos(ω0 n + ω0 N + ϕ) → ω0 N = 2πk
❑ Where k is an integer
❑ All discrete-time sinusoidal sequences are NOT periodic
2πk
❑ Only those are for which ω0 can be expressed as N , where, k and
N are integers

14 / 41
Frequency of sinusoidal sequences

❑ Consider a frequency ω0 + 2π of a discrete-time sinusoid x[n]


x[n] = Aej(ω0 +2π)n


= Aejω0 n ej2πn = Aejω0 n

❑ Complex exponential/sinusoidal sequences with frequencies


ω0 + 2πr , where r is an integer, are indistinguishable from one
another
❑ For discrete-time signals, we need only consider frequencies in an
interval of length 2π
❑ −π < ω0 ≤ π or 0 < ω0 ≤ 2π

15 / 41
Task: Periodicity and frequency of sinusoidal
sequence examples

❑ Check if the following discrete time sequences are periodic or not?


❑ If periodic, find their fundamental time period T0 (the minimum
value after which the sequence repeats)
1. x[n] = cos( 2πn
12 )
8πn
2. x[n] = cos( 31 )
3. x[n] = cos( n6 )

16 / 41
An observation about periodicity and frequency
of sinusoidal sequences

2πk
❑ Periodicity: x[n] = Acos(ω0 n + ϕ) is periodic if ω0 = N , where, k
and N are integers
❑ Frequency: Sinusoidal sequences with frequencies ω0 + 2πr ,
where r is an integer, are indistinguishable from one another
❑ Combining above two properties: There are N distinguishable
frequencies for which the corresponding sequences are periodic
with period N
2πk
❑ ωk = N ,k = 0, 1, 2, ..., N − 1

17 / 41
Table of Contents

1 Discrete-time signals: Sequences

2 Discrete-time systems
Types of discrete-time systems

3 Linear time-invariant (LTI) systems

18 / 41
Discrete-time system definition

❑ A transformation or operator that maps an input sequence with


values x[n] into an output sequence with values y [n]
❑ y [n] = T {x[n]}

19 / 41
Discrete-time system examples

❑ Ideal delay system


❑ y [n] = x[n − nd ], −∞ < n < ∞
❑ nd is a fixed positive integer called the delay of the system
❑ If nd is negative → system would shift the input to the left by |nd |
samples
❑ Time advance
❑ Moving average system
1
PM2
❑ y [n] = M1 +M2 +1 k =−M1 x[n − k ]

20 / 41
Table of Contents

1 Discrete-time signals: Sequences

2 Discrete-time systems
Types of discrete-time systems

3 Linear time-invariant (LTI) systems

21 / 41
Memoryless system

❑ A system is referred to as memoryless if the output y [n] at every


value of n depends only on the input x[n] at the same value of n
❑ y [n] = (x[n])2 for all values of n

22 / 41
Linear system

❑ The class of linear systems is defined by the principle of


superposition
❑ Let T {x1 [n]} = y1 [n] and T {x2 [n]} = y2 [n] be the inputs and
corresponding outputs of a system
❑ The system T is linear if and only if
❑ T {x1 [n] + x2 [n]} = T {x1 [n]} + T {x2 [n]} = y1 [n] + y2 [n]
❑ Called additivity property
❑ T {ax[n]} = aT {x[n]} = ay [n], where a is an arbitrary constant
❑ Called homogeneity or scaling property
❑ Combination of these two properties: principle of superposition
❑ T {ax1 [n] + bx2 [n]} = aT {x1 [n]} + bT {x2 [n]} = ay1 [n] + by2 [n]
❑ a and b are arbitrary constants

23 / 41
Task: check if a system is linear

❑ Check if the ideal delay and the moving average systems


discussed earlier are linear or not?
❑ Accumulator system
Pn
❑ y [n] = k =−∞ x[k ]
Pn
❑ T {x1 [n]} = y1 [n] → y1 [n] = k =−∞ x1 [k ]
Pn
❑ T {x2 [n]} = y2 [n] → y2 [n] = k =−∞ x2 [k ]
❑ Let x3 [n] = ax1 [n] + bx2 [n]

n
X n
X
y3 [n] = x3 [k ] = (ax1 [k ] + bx2 [k ])
k =−∞ k =−∞
n
X n
X
=a x1 [k ] + b x2 [k ]
k =−∞ k =−∞

= ay1 [n] + by2 [n]

24 / 41
Time-invariant system

❑ A system for which a time shift or delay of the input sequence


causes a corresponding shift in the output sequence
❑ Let T {x[n]} = y [n]
❑ Then T {x[n − n0 ]} = y [n − n0 ] for all integer n0

25 / 41
Task: check if a system is time-invariant

❑ For accumulator system, let x1 [n] = x[n − n0 ]


Pn−n0
❑ y [n − n0 ] = k =−∞ x[k ]

n
X n
X
y1 [n] = x1 [k ] = x[k − n0 ]
k =−∞ k =−∞
n−n
X0
= x[k1 ] = y [n − n0 ]
k1 =−∞

❑ by substituting k1 = k − n0
❑ Check if a compressor system (y [n] = x[Mn], for some positive
integer M and −∞ < n < ∞) is time invariant
❑ Creates the output sequence by selecting every M th sample and
discarding the remaining M − 1

26 / 41
Causality

❑ A system is causal if y [n0 ] depends only on the input sequence


values for n ≤ n0
❑ For every choice of n0
❑ If x1 [n] = x2 [n] for n ≤ n0 , then y1 [n] = y2 [n] for n ≤ n0
❑ The system is non-anticipative

27 / 41
Task: causality example

❑ Forward difference system: y [n] = x[n + 1] − x[n]


❑ Non-causal
❑ Backward difference system: y [n] = x[n] − x[n − 1]
❑ Causal
❑ Check if the following systems are causal:
❑ Ideal delay system
❑ Moving average system
❑ Accumulator system
❑ Compressor system

28 / 41
Table of Contents

1 Discrete-time signals: Sequences

2 Discrete-time systems
Types of discrete-time systems

3 Linear time-invariant (LTI) systems

29 / 41
LTI system

❑ A system that is linear as well as time-invariant


❑ Principle of superposition
❑ Every signal can be represented as a linear combination of delayed
impulses
❑ A LTI system can be completely characterized by its impulse
response h[n]
❑ Given h[n], the output y [n] for any arbitrary input x[n] can be
computed

30 / 41
Output of an LTI system as convolution sum



n X o
y [n] = T {x[n]} = T x[k ]δ[n − k ]
k =−∞

X
= x[k ]T {δ[n − k ]}
k =−∞
X∞ ∞
X
= x[k ]hk [n] = x[k ]h[n − k ]
k =−∞ k =−∞
= x[n] ∗ h[n]

❑ The convolution sum

31 / 41
Convolution sum example

32 / 41
Convolution sum example

33 / 41
Convolution sum example

34 / 41
Another interpretation of convolution sum

❑ The preceding interpretation emphasizes that the convolution sum


is a direct result of linearity and time-invariance
❑ In previous example, the convolution sum found the entire signal
y [n]
❑ i.e., values of y [n] for −∞ < n < ∞
❑ Many a times we may wish to calculate y [k ] for some particular
value of k
❑ For such applications, the above interpretation is computationally
expensive
❑ A useful computational interpretation
❑ y [n] (i.e., the nth value of the output) is obtained by multiplying x[k ]
by h[n − k ], −∞ < k < ∞
❑ Expressed as a function of k
❑ For any fixed value of n, sum all the values of x[k ]h[n − k ], with k
as counting index

35 / 41
How to obtain h[n − k ]

36 / 41
Convolution sum example 2

❑ x[n] = an u[n]
(
1, 0≤n ≤N −1
❑ h[n] = u[n] − u[n − N] =
0, Otherwise
❑ For n < 0

❑ No overlap → y [n] = 0

37 / 41
Convolution sum example 2

❑ For 0 ≤ n < N


n
X n
X
y [n] = x[k ]h[n − k ] = ak
k =0 k =0
1− an+1
=
1−a

38 / 41
Convolution sum example 2

❑ For n ≥ N


n
X n
X
y [n] = x[k ]h[n − k ] = ak
k =n−N+1 k =n−N+1
an−N+1 − an+1 n−N+1 1 − a
N
= =a
1−a 1−a

39 / 41
Convolution sum example 2


0, n<0


1−an+1
❑ y [n] = 1−a ,   0≤n<N
an−N+1 1−aN ,

n≥N

1−a

40 / 41
Thanks.

You might also like