SMJE3163 DSP2026_Week1
Week 1
Introduction to
Digital Signal
Processing
1
1.1 Introduction to Digital Signal
Processing (DSP)
1) Signals, Systems, and DSP
Signals Signals convey some information through its
physical variation pattern.
Signal Processing concerns with the representation, transformation,
manipulation of signals and the extraction of the
information containing signals.
Digital Signal Processing of analog signals by digital computer/
Processing devices.
Benefits of DSP Flexibility, High Reliability, Consistency
9
Speech sound waveforms
/a, あ/ sound /I, い/ sound
物理量の変化パターンを通じて
情報
を担うもの
Types of Signal
Analog Signal Discrete-Time Signal Digital Signal
• Continuous time and • Discrete-time and • Discrete time, discrete in
continuous value continuous value value
• Eg: human voice, music • Eg: The internal state of • Eg: mp3/JPEG/PNG file etc
from live instrument a sampler before the
values are "rounded"
into bits
Types of Signals
Time
Continuous-Time Discrete-Time
Continuous- Discrete-Time
Analog Signal
Amplitude
Value Signal
Discrete-Value Digital Signal
2) DSP system Configurations
analog Digital analog
signal ADC DAC
Computer signal
ADC: DAC:
Analog Digital Digital Analog
Converter Converter
DSP System TYPE 1: Manipulate input signal to generate output
signal
A-D Converter
analog
signal *
time index
n
series of binary
codes
* During the value is held constant, the value is quantized and converted it to binary code. [Tan-Ch.2]
Quantization and Binary Code Generation
Q(x)
Binary code
111 3Δ
110 2Δ
101 Δ
-7Δ/2 -5Δ/2 -3Δ/2 -Δ/2
100 x
Δ/2 3Δ/2 5Δ/2
011 -Δ
010 -2Δ
001 -3Δ
000 -4Δ Δ:quantization step size
Characteristics of bipolar quantization (rounding)
D-A Converter
DA Conversion
zero-
order- Smoothing analog
Binary Code Decoding
hold filter signal
00001010
00101101
10001001
01001110
.
.
n
series of binary codes
DAC interpolates the values between the sampled values.
Staircase reconstruction followed by the smoothing filter is most commonly used
Discrete-Time System
Input x(n) Discrete-Time Output y(n)
System
“Sample-by sample” processing:
The output sample y(n) is computed, when the input x(n) is
available at the input, and the computation must complete before
the next sample x(n+1) appears at the input port.
Other DSP System Configurations
Send to
analog
ADC
Digital Processed / Display
signal results / Pattern
Computer Recognition
etc.
DSP TYPE 2: Manipulating signal to get (estimate) parameters
which characterize the input signal. No DAC device.
This Photo by Unknown Author is licensed under CC BY
Other DSP System Configurations
Digital analog
DAC signal
This Photo by Unknown Author is licensed under CC BY-SA-NC
Computer
DSP TYPE 3: Computer generates analog
output signal
No ADC system
This Photo by Unknown Author is licensed under CC BY
3) Applications of DSP
• Tasks of DSP:
• ►Filtering/Separation
• ►Enhancement of target signal
• ►Noise Cancellation
• ►Spectrum Estimation
• ►Characterization of Signals for pattern recognition
• ►Data Reduction without losing signal quality
26
Fields of DSP Application
• ►Consumer/Commercial/Multi-Media
• ►Audio-Speech/ Image/ Video Processing
• ►Communication System
• ►Medical/Bio Science
• ►Industrial Use
• ►Scientific Analysis
• ►Military/Radar Sonar etc.
• ►Space
27
Separation of Speech Signals
Mixed signal
Microphone array system
Experiment movie Separated voices
by Microphone Array
System
Processing
by
Microphone
array
Mobile Robot
Microphone array
(Keio Univ. Hamada & Nakazawa Labs 2012)
Specific Speaker Tracking under Noisy environment
Super-resolution image reconstruction
Real sequence of Acquired 20
images Images:
176×110
Super
Resolution
Image
352×220
Section 1.2
Recap: Intro to Digital Signal Processing and
Overview of Discrete-time Systems
for Filter Design
1) Signal Sampling, Discretization, Quantization
2) Overview of Discrete-time Systems
34
Recap:
DSP • Use of digital processing e.g. computer/DSP processor to perform
signal processing operations
• to digitally analyze & manipulate an analog signal, it must be digitized
Signal Sampling with an analogue to digital converter (ADC)
• sampling is carried in 2 stages: (i) Discretization ii) Quantization
Discretization • signal is divided with equal intervals of time and each interval
is represented by amplitude
Quantization • Each amplitude measurement is approximated by a value
from a finite set
From Signal to System
analog Digital analog
signal ADC DAC
Computer signal
Sampling and Reconstruction
• Nyquist-Shannon theorem: to accurately reconstruct an analog signal, the sampling rate must be at
least twice the highest frequency component present in the signal; fs > 2fmax
• Ideal Models: Theoretical DSP analysis and derivations are performed on discrete-time signal models
that assume no amplitude inaccuracies (no quantization error).
• Real-World Constraints: Practical numerical methods require a quantized signal, which is produced
by an Analog-to-Digital Converter (ADC).
From Signal to System
analog Digital analog
signal ADC DAC
Computer signal
Processing Engine: Digital Methods
• Common Goal: (most common) enhancement of input signal via filtering
• Output formats:
• frequency spectrum/set of statistics/quantized signal to be converted to analog via DAC
From Signal to System
analog Digital analog
signal ADC DAC
Computer signal
Digital filter
• How it works:
• Consists of a linear transformation of a number of surrounding samples around the current
sample of the input or output signal
• A filter can be represented by:
• Block diagram → derive a sample processing algorithm for hardware implementation
• Mathematical derivations
• A difference equation (time-domain implementation)
• A collection of zeros and poles (Z-domain analysis)
• An impulse response/Step response
Course Outcome (CO)
By the end of this course you should be able to
►CO3:
Demonstrate the ability to design
digital filter using appropriate
methods
39
Course Outcome (Cont.)
►CO2:
Analyse signals using correlation and time-frequency transform methods
40
2) Overview: Discrete-time Systems
2-1) Description of Linear Time-Invariant (LTI) discrete-time
systems
a) Difference equation,
b) Block diagram
c) Impulse (Unit-Sample) Response
d) System function
4-1 Description of discrete-time systems
►a) Difference equation (1st order system)
Input signal Output Signal
Discrete-Time
(sequence) System y(n)
𝑥(n)
Eg. 1) Non-recursive System (FIR – Finite impulse response)
𝑦 𝑛 = 𝑏0 𝑥 𝑛 + 𝑏1 𝑥 𝑛 − 1 + 𝑏2 𝑥 𝑛 − 2 (1.1)
Eg. 2) Recursive System (IIR – Infinite Impulse Response)
𝑦 𝑛 = 𝑎𝑦 𝑛 − 1 + 𝑏0 𝑥 𝑛 + 𝑏1 𝑥 𝑛 − 1 (1.2)
►b) Block diagram:
Three basic operations:
Unit delay, Multiplier (Gain), Adder (Sum)
𝑏
𝑧 −1 +
(a) unit delay (b) Multiplier (c) Adder
(Gain) (Sum)
𝑏
Σ
Block diagram of system (1.1)
𝑥(n-1) 𝑥(n-2)
𝑥(n)
𝑧 −1 𝑧 −1
𝑏0 𝑏1 𝑏2
+ + 𝑦(n)
Eg. 1) Non-recursive System
𝒚 𝒏 = 𝒃𝟎 𝒙 𝒏 + 𝒃𝟏 𝒙 𝒏 − 𝟏 + 𝒃𝟐 𝒙 𝒏 − 𝟐 (1.1)
Block diagram of system (1.2)
𝑏0 𝑦(n)
𝑥(n)
+ +
𝑧 −1 𝑧 −1
𝑥(n-1) 𝑦(n-1)
𝑏1 𝑎
Eg. 2) Recursive System
𝒚 𝒏 = 𝒂𝒚 𝒏 − 𝟏 + 𝒃𝟎 𝒙 𝒏 + 𝒃𝟏 𝒙 𝒏 − 𝟏 (1.2)
►c) Impulse (Unit-Sample) Response
characterizes discrete-time system completely. This means that the
output for any input can be computed by using solely impulse response.
Unit impulse function
1 , 𝑛=0
𝛿 𝑛 =ቐ
0 , 𝑛≠0
unit Discrete-Time Impulse
impulse response
System
𝛿(n) h(n)
**to find h(n) Replace the input x(n) with a unit impulse 𝛿(n), and the resulting output y(n) becomes h(n).
The Impulse (Unit-Sample) Response
𝛿 𝑛 : ℎ(𝑛):
unit − sample Impulse (unit-sample) response
𝑛 𝑛
𝑛=0 𝑛=0
Due to linearity property, if one knows the unit-sample
response of an LTI system one can compute system’s
response to any input.
Copyright © 2014 McGraw-Hill
Education. Permission required for
reproduction or display
Eg. 1) Non-recursive System
𝒚 𝒏 = 𝒃𝟎 𝒙 𝒏 + 𝒃𝟏 𝒙 𝒏 − 𝟏 + 𝒃𝟐 𝒙 𝒏 − 𝟐 (1.1)
Q.1 Find the impulse Response from the difference
eq. (1.1)
n<0 h(n)=0,
n=0 h(0)=b0, n=1 h(1)=b1,
n=2 h(2)=b2, n≧3 h(n)=0
Since the length of above response is finite, this type of
system is referred to as finite impulse response (FIR)
system/filter.
Eg. 2) Recursive System
𝒚 𝒏 = 𝒂𝒚 𝒏 − 𝟏 + 𝒃𝟎 𝒙 𝒏 + 𝒃𝟏 𝒙 𝒏 − 𝟏 (1.2)
Q.2 Find the impulse Response from the difference eq. (1.2)
n<0 h(n)=0,
n=0 h(0)=b0, n=1 h(1)=a b0 + b1
n=2 h(2)=a(ab0 + b1 ), n=3 h(3)=a2(a b0 + b1 ),
……. endless,
Since the length of this impulse is infinite, this type of system is
referred to as infinite impulse response (IIR) system/filter.
►System/Transfer function:
The ratio of input and output in the z-domain
z-transform: System function:
𝑛=∞
𝑌 𝑧
𝑋 𝑧 = 𝑥 𝑛 𝑧 −𝑛 𝐻 𝑧 =
𝑋 𝑧
𝑛=−∞
System functions of Ex.1) and Ex.2) are given by:
Ex1) 𝐻 𝑧 = 𝑏0 + 𝑏1 𝑧 −1 + 𝑏2 𝑧 −2 (1.3)
𝑏0 +𝑏1 𝑧 −1
Ex2) 𝐻 𝑧 = (1.4)
1−𝑎𝑧 −1
Review: Frequency Response
Frequency Response
►Definition:
The complex-valued gain 𝐻 𝑒 𝑗Ω of the system for the input 𝑒 𝑗Ω𝑛
𝑒 𝑗Ω𝑛 Discrete-Time
System 𝐻 𝑒 𝑗Ω 𝑒 𝑗Ω𝑛
Frequency response can be found from the system function
𝐻 𝑧 by
𝐻 𝑒 𝑗Ω = 𝐻 𝑧 ȁ𝑧=𝑒 𝑗Ω (1.5)
The polar form of frequency response gives the magnitude response
𝐴 Ω and the phase response 𝜃 Ω .
𝐻 𝑒 𝑗Ω = 𝐴 Ω 𝑒 𝑗𝜃 Ω (1.6)
𝑦 𝑛 = 𝑏0 𝑥 𝑛 + 𝑏1 𝑥 𝑛 − 1 + 𝑏2 𝑥 𝑛 − 2 (1.1)
Q1. Compute the frequency response of the system (1.1) with the parameters,
b0=1, b1=2, b2=1.
The polar form of frequency response gives the magnitude response
𝐴 Ω and the phase response 𝜃 Ω .
𝐻 𝑒 𝑗Ω = 𝐴 Ω 𝑒 𝑗𝜃 Ω (1.6)
𝑦 𝑛 = 𝑏0 𝑥 𝑛 + 𝑏1 𝑥 𝑛 − 1 + 𝑏2 𝑥 𝑛 − 2 (1.1)
𝐻 𝑧 = 𝑏0 + 𝑏1 𝑧 −1 + 𝑏2 𝑧 −2 (1.3)
b0=1, b1=2, b2=1.
Solution:
Substituting the parameters into (1.3) gives
𝐻 𝑧 = 1 + 2𝑧 −1 + 𝑧 −2 (1.7)
and
𝐻 𝑒 𝑗Ω = 1 + 2𝑒 −𝑗Ω + 𝑒 −𝑗2Ω (1.8)
= 𝑒 −𝑗Ω 𝑒 𝑗Ω +2 + 𝑒 −𝑗Ω = 𝑒 −𝑗Ω 2 + 2cosΩ (1.9)
Recap from Circuit & Signal: The Frequency Response 𝑯(𝝎)
Definition
LTI system
𝑗𝜔𝑛 𝐻(𝜔)
𝑥 𝑛 =𝑒 𝑦 𝑛 = 𝐻(𝜔)𝑒 𝑗𝜔𝑛
𝝎 = angular frequency for analog system
𝑯 𝝎 : frequency response of the system.
■ Discrete Time Fourier Transform (DTFT) of the unit-sample
response h(n) of the system,
■It can be found from the system function H(z).
Recap from C&S: The Frequency Response 𝑯(𝑒 𝑗Ω )
Ω = frequency for discrete time system
Definition
LTI system
𝑗Ω
𝑗Ω𝑛 𝐻(𝑒 ) 𝑦 𝑛 = 𝐻(𝑒 𝑗Ω )𝑒 𝑗Ω𝑛
𝑥 𝑛 =𝑒
𝑗Ω
𝑯 𝑒 : frequency response of the system.
■ DTFT of the unit-sample response h(n) of
the system,
■It can be found from the system function H(z).
For system (1.1) with the parameters, b0=1, b1=2, b2=1.
𝑦 𝑛 = 𝑏0 𝑥 𝑛 + 𝑏1 𝑥 𝑛 − 1 + 𝑏2 𝑥 𝑛 − 2 (1.1)
The computed frequency response (magnitude and phase) are:
→ The magnitude of 𝐻 𝑒 𝑗Ω is
A Ω = 𝐻 𝑒 𝑗Ω = 2 1 + cosΩ (1.10),
→ and the phase response of 𝐻 𝑒 𝑗Ω is
θ Ω = ∠𝐻 𝑒 𝑗Ω = −Ω (1.11)
5
Magnitude 4
Response 3
0 Ω
0 π
0
Ω
-0.5
Phase -1
Response[rad] -1.5
-2
-2.5
-3
-3.5
System (1.1) with 𝑏0 = 1, 𝑏1 = 2, 𝑏2 = 1
Q.2
Compute the frequency response of system (1.1) with the
parameters, b0= -1, b1=2, b2=-1.
Solution:
Substituting the parameters into (1.3) gives
𝐻 𝑧 = −1 + 2𝑧 −1 − 𝑧 −2 (1.12)
and
𝐻 𝑒 𝑗Ω = −1 + 2𝑒 −𝑗Ω − 𝑒 −𝑗2Ω (1.13)
= 𝑒 −𝑗Ω −𝑒 𝑗Ω +2 − 𝑒 −𝑗Ω
= 𝑒 −𝑗Ω 2 − 2cosΩ (1.14)
5
4
Magnitude
Response 3
0 Ω
0 π
0 Ω
-0.5
Phase -1
Response[rad] -1.5
-2
-2.5
-3
-3.5
System (1.1) with 𝑏0 = −1, 𝑏1 = 2, 𝑏2 = −1
Output Response by Frequency Response
Graph
Q.3
Find a rough output signal of the system (1.1) with 𝑏0 = 1, 𝑏1 = 2, 𝑏2 = 1
when the input is:
2𝜋
𝑥 𝑛 = cos 𝑛
3
The magnitude of 𝐻 𝑒 𝑗Ω is
A Ω = 𝐻 𝑒 𝑗Ω = 2 1 + cosΩ = 2(1-0.5) = 1
and the phase response of 𝐻 𝑒 𝑗Ω is
2𝜋
θ Ω = ∠𝐻 𝑒 𝑗Ω = −Ω = − 3
So the output is
2𝜋 2𝜋 2𝜋
𝑦 𝑛 = cos( 3 𝑛 − ) = cos( 3 𝑛 − 1 )
3
5
Magnitude 4
Response 3
0 Ω
0 π
0
Ω
-0.5
Phase -1
Response[rad] -1.5
-2
-2.5
-3
-3.5
System (1.1) with 𝑏0 = 1, 𝑏1 = 2, 𝑏2 = 1
Summary of Week 1
We have discussed:
• ADC/DAC
• What is sampling, discretization, quantization, Nyquist-
Shannon theorem
• Review of Discrete-time System for filter design
89
What’s Next?
Next, we focus Filter Design Methods
in the discrete-time domain.
►Relationship between characteristics of discrete-
time signal processing and overall analog system 90
But first…Next will be…
►Frequency Response
► Time Domain Sampling & Reconstruction
► Discrete Time Signal & LTI
► LTI Discrete Time System & Discrete Convolution
► Z Transform
► DTFT, System Function, Frequency Response
Then only will be:
► Analogue Discrete Time System
► FIR
► IIR
91