Digital Signal Processing Lecture+5,+January+20th
Digital Signal Processing Lecture+5,+January+20th
Faculty of Engineering
Winter 2017
Schedule: Laboratories
Matlab tutorials: January 23rd January 27th
4 Lab sessions:
Reports are due one week after the lab session. To be submitted to locker #
206, 2nd floor of TEB
Schedule: Laboratories
Section 003: Tuesday 9:30 a.m. 12:30 p.m. TAs: Farid, Anastasiia
Section 004: Thursday 4:30 p.m. 7:30 p.m. TAs: Soulaimane, Yousef
Section 005: Friday 12:30 p.m. 3:30 p.m. TAs: Samantha, Hessam
Section 006: Wednesday 2:30 p.m. 5:30 p.m. TAs: Samantha, Hessam
Section 007: Wednesday 11:30 a.m. 2:30 p.m. TAs: Farid, Anastasiia
Section 008: Monday 2:30 p.m. 5:30 p.m. TAs: Soulaimane, Yousef
Topic 2: Discrete-Time Signals and Systems
Discrete-Time Signals
Discrete-Time Systems
y(n) := T [x(n)] ,
Identity system:
y(n) = x(n).
1
y(n) = [x(n + 1) + x(n) + x(n 1)] .
3
Discrete-Time Systems
Example: Accumulator
n
X
y(n) = x(k) = x(n) + x(n 1) + x(n 2) + . . .
k= 1
The output y(n) is determined by current input x(n) and initial condition
y(n 1).
An adder:
A constant multiplier:
Block Diagram Representation of DT Systems
Basic building blocks:
A signal multiplier:
System:
A DT system is said to be static (or memoryless) if the output at any instant n depends
(at most) on the input at the current time n, but not on past or future values of the input.
In other words, in memoryless systems, y(n) may depend on x(n) but not on x(i) where
i 6= n.
y(n) = ax(n),
P
m
y(n) = x(n k), Accumulator with finite memory
k=0
P
1
y(n) = x(n k), Accumulator with infinite memory
k=0
Time-Invariant vs. Time-Variant Systems
x(n) y(n)
T
The system is time-invariant if for any k 2 Z, the response to input x(n k) is y(n k),
x(n k) y(n k)
T
The system is called time-variant or time-varying if it is not time-invariant; in other
words, if there exists at least one x(n) and at least one k 2 Z such that
x1 y1
T
x2 y2
T
The system is linear if and only if its response to input sequence 1 x1 (n) + 2 x2 (n), where
1, 2 R is 1 y1 (n) + 2 y2 (n)
The system T is linear if y(n) y 0 (n) for any x1 (n), x2 (n), and any a1 , a2 2 R.
Linear vs. Nonlinear Systems
Example 2.2.5 (from Proakis & Manolakis, 2007): Determine if the following systems are
linear or nonlinear.
y(n) = nx(n) = n (1 x1 (n) + 2 x2 (n)) = 1 nx1 (n) + 2 nx2 (n) = 1 y(n) + 2 y(n).
6= 1 y(n) + 2 y(n).
Informal Definition: A system is called causal if its current output does not depend on
future values of input. Otherwise, the system is noncausal.
Definition: A system is said to be causal if the output of the system y(n) at any given
time instant n depends only on present and past inputs x(n), x(n 1), x(n 2), . . . , but
does not depend on future inputs x(n + 1), x(n + 2), etc.
Real-time signal processing is always causal. If a signal is recorded and processed o-line
(not in real time), a noncausal SP algorithms can be implemented.
Causal vs. Noncausal Systems
Example 2.2.6 (from Proakis & Manolakis, 2007): Determine if the following
systems are causal or noncausal
P
n
(b.) y(n) = x(k). Answer: causal
k= 1
Any practically useful system must be stable (at least in some sense).
Interconnection of DT Systems
Two basic types:
Cascade interconnection
Parallel interconnection
Interconnection of DT Systems
Cascade interconnection:
In general,
T2 T1 6= T1 T2
T2 T1 = T1 T2 .
Interconnection of DT Systems
Parallel interconnection:
where
Tp [x(n)] = T1 + T2
Topic 2: Discrete-Time Signals and Systems
Discrete-Time Signals
Discrete-Time Systems
x1 y1
T
x2 y2
T
The system is linear if and only if its response to input sequence 1 x1 (n) + 2 x2 (n), where
1, 2 R is 1 y1 (n) + 2 y2 (n)
x(n) y(n)
T
The system is time-invariant if for any k Z, the response to input x(n k) is y(n k),
x(n k) y(n k)
T
Analysis of DT Linear Time-Invariant Systems
How to calculate a response of LTI system using superposition principle:
X
x(n) = ck xk (n).
k
xk yk
T 8k
One reason is that it is straightforward to represent any DT signal x(n) in the form
X
x(n) = ck (n k).
k
Analysis of DT Linear Time-Invariant Systems
Let x(n), n 2 {. . . , 1, 0, 1, 2, . . .} be an arbitrary DT signal. Let x(k) is the value of x(n)
at k-th instant.
The signal x(k) (n k) is equal to x(n) at k-th instant and equal to zero everywhere else.
Analysis of DT Linear Time-Invariant Systems
+1
X
x(n) = x(k) (n k), nZ
k= 1
Analysis of DT Linear Time-Invariant Systems
Example 2.3.1 (from Proakis & Manolakis, 2007): Consider a finite-duration se-
quence
x(n) = {2, 4, 0, 3}
"
Resolve the sequence x(n) into a sum of weighted impulse sequences.
Answer:
x(n) = 2 (n + 1) + 4 (n) + 3 (n 2).
Analysis of DT Linear Time-Invariant Systems
How to calculate a response of LTI system using superposition principle:
h(n) := T [ (n)] ,
(n) h(n)
T
Due to time invariance, the response of the system to the delayed elementary input
(n k) is h(n k), for each k Z.
h(n k) := T [ (n k)] ,
(n k) h(n k)
T
Analysis of DT Linear Time-Invariant Systems
Applying the superposition principle, we have
+1
X +1
X
x(n) = x(k) (n k) y(n) = x(k)h(n k)
k= 1 k= 1
T
P
+1
The response of an initially relaxed system to input x(n) = x(k) (n k) is
k= 1
" +1
# +1 +1
X X X
y(n) = T [x(n)] = T x(k) (n k) = x(k)T [ (n k)] = x(k)h(n k),
k= 1 k= 1 k= 1
where h(n) = T [ (n)] is the response of a relaxed LTI system to the unit sample sequence.
The function
h(n) := T [ (n)]
is called the impulse response. It represents the response of the relaxed LTI system to the
unit sample sequence (n).
Analysis of DT Linear Time-Invariant Systems
Convolution sum:
+1
X
y(n) = x(k)h(n k) (CS)
k= 1
where h(n) = T [ (n)] is the response of a relaxed LTI system to the unit sample sequence.
The impulse response function is the response of a relaxed LTI system to the unit sample
sequence,
h(n) := T [ (n)]
Formula (CS) allows to compute a response of a relaxed LTI system to an arbitrary input
signal x(n) based on systems impulse response.