View
14
Download
0
Category
Preview:
Citation preview
Marco Marcon
Politecnico di Milano
Dipartimento di Elettronica,Informazione e Bioingegneria (DEIB)
Multimedia Signal Processing1st Module
Fundamentals of Multimedia Signal Processing
Course overviewThis module covers the fundamental tools for digital signal processing. In particular it addresses topics of signal analysis and filtering concerning audio and video data.Some aspects of Statistical Signal Processing will also be presented during the course.Participants will learn basic tools for digital signal filtering and analysis acquiring the knowledge to design specific filters and . In particular the program will be articulated in the following parts:
Review of Analog Signal Processing theory: Some fundamentals of Analog Signal Processing will be recalled (sampling,
quantization, Fourier Transform and Series, noise description...). Introduction to Discrete Signals Transforms:
The z-transform, the Discrete Time Fourier Transform and the Discrete Fourier Transform will be described with their properties and application to filter design and analysis.
Introduction to Digital Filters: This course part will cover Time-domain filter representations, transfer function
analysis, frequency response analysis, Finite and Infinite impulse response implementation; stability analysis.
Course overview Windowing and Short Time Fourier Transform:
Overview of windows and real-time processing; overlap and add, overlap and save, Short Time Fourier Transform for real time processing
Introduction to Multirate Processing: Downsampling, upsampling, polyphase filters, perfect reconstruction filter banks.
Elements of Statistical Signal Processing: Random sequences, properties and characterization. Spectral estimation, the
Periodogram, linear prediction. Introduction to estimation theory, power spectral density, parametric and nonparametric spectral estimation. Autocorrelation and autocovariance methods.
Laboratory activities Laboratory activities enable student to improve their understanding of the concepts
learnt during the lectures. The proposed examples of applications and exercises, cover audio, image and video
processing, and are based on Matlab® and the related toolboxes (Digital Signal Processing System Toolbox, Audio System Toolbox, Image acquisition toolbox, Image Processing Toolbox ).
Examples of real-time processing with embedded devices (Raspberry Pi) and Simulink will also be provided.
Course overview Laboratory activities
Laboratory activities enable student to improve their understanding of the concepts learnt during the lectures.
The proposed examples of applications and exercises are based on Matlab® and Simulink ®
Website marcon.net
E-mail Marco.marcon@polimi.it
Skype marco.marcon
Suggested books “Digital Signal Processing: System Analysis and
Design”, Paulo S. R. Diniz, Eduardo A. B. da Silva, Sergio L. Netto
“Lecture notes”, Marco Tagliasacchi Available on the website.
Matlab – Signal Processing Toolbox guide http://www.mathworks.it/help/toolbox/signal/index.html
DAFX: Digital Audio Effects, 2nd Edition, Editor: Udo Zolzer
Further Italian book suggested for Italian students not too confident with English: “Elaborazione Numerica dei Dati”, Massimiliano Laddomada – Marina Mondin
http://www.mathworks.it/help/toolbox/signal/index.html
Signals Signals are functions of independent variables that carry
information. For example:• Electrical signals --- voltages and currents in a circuit• Acoustic signals --- audio or speech signals (analog or digital)
Spectrogram
Time-domainSpeech signal
Signals• Video signals --- intensity variations in an image (e.g.
a CAT scan)
• Biological signals --- sequence of bases in a geneDNA
Its signal representation
• For electrical signal the value of voltage or current changes with time, hence time is called independent variable and voltage or current is called dependent variable
• Independent variable can be continuous— Trajectory of a space shuttle— Mass density in a cross-section of a brain
• Independent variable can be discrete— DNA base sequence— Digital image pixels
• Independent variable can be 1-D, 2-D, ••• N-D
8
What are the independent variables in these signals?(i) Speech (ii) CAT scan image (iii) DNA sequence(i) Time (ii) Spatial Location (iii) Location on DNA molecule
For this course: Focus on a single (1-D) independent variable which we call “time”.
Continuous-Time (CT) signals: x(t), t — continuous valuesDiscrete-Time (DT) signals: x[n], n — integer values only
9
• Most of the signals in the physical world are CT signals—E.g. voltage & current, pressure, temperature, velocity, etc.
10
• Examples of DT signals in nature:— DNA base sequence— Population of the n-th generation of certain species
11
• x[n], n — integer, time varies discretely
12
Ex.#1 Weekly Dow-Jonesindustrial average
Why DT? —Can be processed by modern digital computers
and digital signal processors (DSPs).
Ex.#2 digital image
13
For the most part, our view of systems will be from an input-output perspective:A system responds to applied input signals, and its response is described in terms of one or more output signals
14
• Dynamics of an aircraft or space vehicle• An algorithm for analyzing financial and economic
factors to predict bond prices• An algorithm for post-flight analysis of a space launch• An edge detection algorithm for medical images
What are the inputs and what are the outputs in above examples?
15
• An important concept is that of interconnecting systems— To build more complex systems by interconnecting
simpler subsystems— To modify response of a system
• Signal flow (Block) diagram
Cascade
Feedback
Parallel +
+
Moving from Analog to Digital World What is DSP? Converting Analog into Digital
Electronically Computationally
How Does It Work? Faithful Duplication Resolution Trade-offs
What is DSP? Converting a continuously changing waveform
(analog) into a series of discrete levels (digital)
What is DSP? The analog waveform is sliced into equal segments and
the waveform amplitude is measured in the middle of each segment
The collection of measurements make up the digital representation of the waveform
What is DSP?0
0.22 0
.44 0.
64 0.8
2 0.98 1.
11 1.2 1.24
1.27
1.24
1.2
1.11
0.98
0.82
0.64
0.44
0.22
0-0
.22
-0.4
4-0
.64
-0.8
2-0
.98
-1.1
1-1
.2-1
.26
-1.2
8-1
.26
-1.2
-1.1
1-0
.98
-0.8
2 -0.6
4 -0.4
4 -0.2
20
-2
-1.5
-1
-0.50
0.5
1
1.5
21 3 5 7 9 11 13 15 17 19 21 23 25 27 29 31 33 35 37
Converting Analog into DigitalElectronically The device that does the conversion is called an
Analog to Digital Converter (ADC) There is a device that converts digital to analog that is
called a Digital to Analog Converter (DAC)
Converting Analog into DigitalElectronically The simplest form of
ADC uses a resistance ladder to switch in the appropriate number of resistors in series to create the desired voltage that is compared to the input (unknown) voltage
V-7
V-6
V-low
V-1
V-2
V-3
V-4
V-5
V-high
SW-8
SW-7
SW-6
SW-5
SW-4
SW-3
SW-2
SW-1
Output
Converting Analog into DigitalElectronically The output of the
resistance ladder is compared to the analog voltage in a comparator
When there is a match, the digital equivalent (switch configuration) is captured
Analog Voltage
ResistanceLadder Voltage
ComparatorOutput Higher
EqualLower
Converting Analog into DigitalComputationally The analog voltage can now be compared with the
digitally generated voltage in the comparator Through a technique called binary search, the
digitally generated voltage is adjusted in steps until it is equal (within tolerances) to the analog voltage
When the two are equal, the digital value of the voltage is the outcome
Converting Analog into DigitalComputationally The binary search is a mathematical technique
that uses an initial guess, the expected high, and the expected low in a simple computation to refine a new guess
The computation continues until the refined guess matches the actual value (or until the maximum number of calculations is reached)
The following sequence takes you through a binary search computation
Binary Search Initial conditions
Expected high 5-volts Expected low 0-volts 5-volts 256-binary 0-volts 0-binary
Voltage to be converted 3.42-volts Equates to 175 binary
Analog Digital5-volts
256
0-volts 0
2.5-volts
128
3.42-volts
Unknown (175)
Binary Search Binary search algorithm:
First Guess:
Analog Digital5-volts
256
0-volts 0
128
3.42-volts
unknownNewGuessLowLowHigh =+−
2
12802
0256=+
−
Guess is Low
Binary Search New Guess (2): Analog Digital
5-volts
256
0-volts 0
1923.42-volts
unknown192128
2128256
=+−
Guess is High
Binary Search New Guess (3): Analog Digital
5-volts
256
0-volts 0
1603.42-volts
unknown160128
2128192
=+−
Guess is Low
Binary Search New Guess (4): Analog Digital
5-volts
256
0-volts 0
1763.42-volts unknown176160
2160192
=+−
Guess is High
Binary Search New Guess (5): Analog Digital
5-volts
256
0-volts 0
1683.42-volts
unknown168160
2160176
=+−
Guess is Low
Binary Search New Guess (6): Analog Digital
5-volts
256
0-volts 0
1723.42-volts
unknown172168
2168176
=+−
Guess is Low
(but getting close)
Binary Search New Guess (7): Analog Digital
5-volts
256
0-volts 0
1743.42-volts
unknown174172
2172176
=+−
Guess is Low
(but getting really, really, close)
Binary Search New Guess (8): Analog Digital
5-volts
256
0-volts 0
3.42-volts
175!175174
2174176
=+−
Guess is Right On
Binary Search The speed the binary search is accomplished depends
on: The clock speed of the ADC The number of bits resolution Can be shortened by a good guess (but usually is not
worth the effort)
How Does It Work?Faithful Duplication Now that we can slice up a waveform and convert it
into digital form, let’s take a look at how it is used in DSP
Draw a simple waveform on graph paper Scale appropriately
“Gather” digital data points to represent the waveform
Starting Waveform Used to Create Digital Data
How Does It Work?Faithful Duplication Swap your waveform data with a partner Using the data, recreate the waveform on a sheet of
graph paper
Waveform Created from Digital Data
How Does It Work?Faithful Duplication
Compare the original with the recreating, note similarities and differences
How Does It Work?Faithful Duplication Once the waveform is in digital form, the real power of
DSP can be realized by mathematical manipulation of the data
Using EXCEL spreadsheet software can assist in manipulating the data and making graphs quickly
Let’s first do a little filtering of noise
How Does It Work?Faithful Duplication Using your raw digital data, create a new table of data
that averages three data points Average the point before and the point after with the
point in the middle Enter all data in EXCEL to help with graphing
Noise Filtering Using Averaging
Raw
-150
-100
-50
0
50
100
150
0 10 20 30 40
Time
Ampl
itude
Ave before/after
-150
-100
-50
0
50
100
150
0 10 20 30 40
TimeAm
plitu
de
Chart1
0
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
Raw
Time
Amplitude
0
10
50
55
75
78
125
122
10
-20
-48
-100
-110
-130
-75
-90
-30
0
45
80
90
100
100
108
90
-8
-40
-55
-80
-45
-38
-15
-2
25
43
45
58
70
80
55
50
0
Sheet1
TimeRawAve before/aftereliminate extremes (100/-100)
0000
1102010
2503850
3556055
4756975
5789378
6125108100
712286100
8103710
9-20-19-20
10-48-56-48
11-100-86-100
12-110-113-100
13-130-105-100
14-75-98-75
15-90-65-90
16-30-40-30
17050
18454245
19807280
20909090
2110097100
22100103100
2310899100
24906390
25-814-8
26-40-34-40
27-55-58-55
28-80-60-80
29-45-54-45
30-38-33-38
31-15-18-15
32-23-2
33252225
34433843
35454945
36585858
37706970
38806880
39556255
40503550
41000
Timeevery 2ndTimeevery 3rdTimeevery 6thTimeevery 12
00000000
110250612512-110
35557812-1102490
57881018453658
712211-1002490410
9-2014-7530-38
11-1001703658
13-1302090410
15-9023108
17026-40
198029-45
2110032-2
231083545
25-83880
27-55410
29-45
31-15
3325
3545
3770
3955
410
Sheet1
Raw
Time
Amplitude
Sheet2
Ave before/after
Time
Amplitude
Sheet3
eliminate extremes (100/-100)
Time
Amplitude
every 2nd
Time
Amplitude
every 6th
Time
Amplitude
every 3rd
Time
Amplitude
every 12
Time
Amplitude
every 12th
Chart2
0
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
Ave before/after
Time
Amplitude
0
20
38.3333333333
60
69.3333333333
92.6666666667
108.3333333333
85.6666666667
37.3333333333
-19.3333333333
-56
-86
-113.3333333333
-105
-98.3333333333
-65
-40
5
41.6666666667
71.6666666667
90
96.6666666667
102.6666666667
99.3333333333
63.3333333333
14
-34.3333333333
-58.3333333333
-60
-54.3333333333
-32.6666666667
-18.3333333333
2.6666666667
22
37.6666666667
48.6666666667
57.6666666667
69.3333333333
68.3333333333
61.6666666667
35
0
Sheet1
TimeRawAve before/aftereliminate extremes (100/-100)
0000
1102010
2503850
3556055
4756975
5789378
6125108100
712286100
8103710
9-20-19-20
10-48-56-48
11-100-86-100
12-110-113-100
13-130-105-100
14-75-98-75
15-90-65-90
16-30-40-30
17050
18454245
19807280
20909090
2110097100
22100103100
2310899100
24906390
25-814-8
26-40-34-40
27-55-58-55
28-80-60-80
29-45-54-45
30-38-33-38
31-15-18-15
32-23-2
33252225
34433843
35454945
36585858
37706970
38806880
39556255
40503550
41000
Timeevery 2ndTimeevery 3rdTimeevery 6thTimeevery 12
00000000
110250612512-110
35557812-1102490
57881018453658
712211-1002490410
9-2014-7530-38
11-1001703658
13-1302090410
15-9023108
17026-40
198029-45
2110032-2
231083545
25-83880
27-55410
29-45
31-15
3325
3545
3770
3955
410
Sheet1
Raw
Time
Amplitude
Sheet2
Ave before/after
Time
Amplitude
Sheet3
eliminate extremes (100/-100)
Time
Amplitude
every 2nd
Time
Amplitude
every 6th
Time
Amplitude
every 3rd
Time
Amplitude
every 12
Time
Amplitude
every 12th
How Does It Work?Faithful Duplication Let’s take care of some static crashes that cause some
interference Using your raw digital data, create a new table of data
that replaces extreme high and low values: Replace values greater than 100 with 100 Replace values less than -100 with -100
Clipping of Static Crashes
Raw
-150
-100
-50
0
50
100
150
0 10 20 30 40
Time
Ampl
itude
eliminate extremes (100/-100)
-150
-100
-50
0
50
100
150
0 10 20 30 40
TimeAm
plitu
de
Chart3
0
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
Raw
Time
Amplitude
0
10
50
55
75
78
125
122
10
-20
-48
-100
-110
-130
-75
-90
-30
0
45
80
90
100
100
108
90
-8
-40
-55
-80
-45
-38
-15
-2
25
43
45
58
70
80
55
50
0
Sheet1
TimeRawAve before/aftereliminate extremes (100/-100)
0000
1102010
2503850
3556055
4756975
5789378
6125108100
712286100
8103710
9-20-19-20
10-48-56-48
11-100-86-100
12-110-113-100
13-130-105-100
14-75-98-75
15-90-65-90
16-30-40-30
17050
18454245
19807280
20909090
2110097100
22100103100
2310899100
24906390
25-814-8
26-40-34-40
27-55-58-55
28-80-60-80
29-45-54-45
30-38-33-38
31-15-18-15
32-23-2
33252225
34433843
35454945
36585858
37706970
38806880
39556255
40503550
41000
Timeevery 2ndTimeevery 3rdTimeevery 6thTimeevery 12
00000000
110250612512-110
35557812-1102490
57881018453658
712211-1002490410
9-2014-7530-38
11-1001703658
13-1302090410
15-9023108
17026-40
198029-45
2110032-2
231083545
25-83880
27-55410
29-45
31-15
3325
3545
3770
3955
410
Sheet1
Raw
Time
Amplitude
Sheet2
Ave before/after
Time
Amplitude
Sheet3
eliminate extremes (100/-100)
Time
Amplitude
every 2nd
Time
Amplitude
every 6th
Time
Amplitude
every 3rd
Time
Amplitude
every 12
Time
Amplitude
every 12th
Chart4
0
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
eliminate extremes (100/-100)
Time
Amplitude
0
10
50
55
75
78
100
100
10
-20
-48
-100
-100
-100
-75
-90
-30
0
45
80
90
100
100
100
90
-8
-40
-55
-80
-45
-38
-15
-2
25
43
45
58
70
80
55
50
0
Sheet1
TimeRawAve before/aftereliminate extremes (100/-100)
0000
1102010
2503850
3556055
4756975
5789378
6125108100
712286100
8103710
9-20-19-20
10-48-56-48
11-100-86-100
12-110-113-100
13-130-105-100
14-75-98-75
15-90-65-90
16-30-40-30
17050
18454245
19807280
20909090
2110097100
22100103100
2310899100
24906390
25-814-8
26-40-34-40
27-55-58-55
28-80-60-80
29-45-54-45
30-38-33-38
31-15-18-15
32-23-2
33252225
34433843
35454945
36585858
37706970
38806880
39556255
40503550
41000
Timeevery 2ndTimeevery 3rdTimeevery 6thTimeevery 12
00000000
110250612512-110
35557812-1102490
57881018453658
712211-1002490410
9-2014-7530-38
11-1001703658
13-1302090410
15-9023108
17026-40
198029-45
2110032-2
231083545
25-83880
27-55410
29-45
31-15
3325
3545
3770
3955
410
Sheet1
Raw
Time
Amplitude
Sheet2
Ave before/after
Time
Amplitude
Sheet3
eliminate extremes (100/-100)
Time
Amplitude
every 2nd
Time
Amplitude
every 6th
Time
Amplitude
every 3rd
Time
Amplitude
every 12
Time
Amplitude
every 12th
How Does It Work?Resolution Trade-offs Now let’s take a look at how sampling rates affect the
faithful duplication of the waveform Using your raw digital data, create a new table of data
and delete every other data point This is the same as sampling at half the rate
Half Sample Rate
Raw
-150
-100
-50
0
50
100
150
0 10 20 30 40
Time
Ampl
itude
every 2nd
-150
-100
-50
0
50
100
150
0 10 20 30 40
Time
Ampl
itude
Chart5
0
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
Raw
Time
Amplitude
0
10
50
55
75
78
125
122
10
-20
-48
-100
-110
-130
-75
-90
-30
0
45
80
90
100
100
108
90
-8
-40
-55
-80
-45
-38
-15
-2
25
43
45
58
70
80
55
50
0
Sheet1
TimeRawAve before/aftereliminate extremes (100/-100)
0000
1102010
2503850
3556055
4756975
5789378
6125108100
712286100
8103710
9-20-19-20
10-48-56-48
11-100-86-100
12-110-113-100
13-130-105-100
14-75-98-75
15-90-65-90
16-30-40-30
17050
18454245
19807280
20909090
2110097100
22100103100
2310899100
24906390
25-814-8
26-40-34-40
27-55-58-55
28-80-60-80
29-45-54-45
30-38-33-38
31-15-18-15
32-23-2
33252225
34433843
35454945
36585858
37706970
38806880
39556255
40503550
41000
Timeevery 2ndTimeevery 3rdTimeevery 6thTimeevery 12
00000000
110250612512-110
35557812-1102490
57881018453658
712211-1002490410
9-2014-7530-38
11-1001703658
13-1302090410
15-9023108
17026-40
198029-45
2110032-2
231083545
25-83880
27-55410
29-45
31-15
3325
3545
3770
3955
410
Sheet1
Raw
Time
Amplitude
Sheet2
Ave before/after
Time
Amplitude
Sheet3
eliminate extremes (100/-100)
Time
Amplitude
every 2nd
Time
Amplitude
every 6th
Time
Amplitude
every 3rd
Time
Amplitude
every 12
Time
Amplitude
every 12th
Chart9
0
1
3
5
7
9
11
13
15
17
19
21
23
25
27
29
31
33
35
37
39
41
every 2nd
Time
Amplitude
0
10
55
78
122
-20
-100
-130
-90
0
80
100
108
-8
-55
-45
-15
25
45
70
55
0
Sheet1
TimeRawAve before/aftereliminate extremes (100/-100)
0000
1102010
2503850
3556055
4756975
5789378
6125108100
712286100
8103710
9-20-19-20
10-48-56-48
11-100-86-100
12-110-113-100
13-130-105-100
14-75-98-75
15-90-65-90
16-30-40-30
17050
18454245
19807280
20909090
2110097100
22100103100
2310899100
24906390
25-814-8
26-40-34-40
27-55-58-55
28-80-60-80
29-45-54-45
30-38-33-38
31-15-18-15
32-23-2
33252225
34433843
35454945
36585858
37706970
38806880
39556255
40503550
41000
Timeevery 2ndTimeevery 3rdTimeevery 6thTimeevery 12
00000000
110250612512-110
35557812-1102490
57881018453658
712211-1002490410
9-2014-7530-38
11-1001703658
13-1302090410
15-9023108
17026-40
198029-45
2110032-2
231083545
25-83880
27-55410
29-45
31-15
3325
3545
3770
3955
410
Sheet1
Raw
Time
Amplitude
Sheet2
Ave before/after
Time
Amplitude
Sheet3
eliminate extremes (100/-100)
Time
Amplitude
every 2nd
Time
Amplitude
every 6th
Time
Amplitude
every 3rd
Time
Amplitude
every 12
Time
Amplitude
every 12th
How Does It Work?Resolution Trade-offs Using your raw digital data, create a new table of data
and delete every second and third data point This is the same as sampling at one-third the rate
1/2 Sample Rate
Raw
-150
-100
-50
0
50
100
150
0 10 20 30 40
Time
Ampl
itude
every 3rd
-150
-100
-50
0
50
100
150
0 10 20 30 40
Time
Ampl
itude
Chart5
0
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
Raw
Time
Amplitude
0
10
50
55
75
78
125
122
10
-20
-48
-100
-110
-130
-75
-90
-30
0
45
80
90
100
100
108
90
-8
-40
-55
-80
-45
-38
-15
-2
25
43
45
58
70
80
55
50
0
Sheet1
TimeRawAve before/aftereliminate extremes (100/-100)
0000
1102010
2503850
3556055
4756975
5789378
6125108100
712286100
8103710
9-20-19-20
10-48-56-48
11-100-86-100
12-110-113-100
13-130-105-100
14-75-98-75
15-90-65-90
16-30-40-30
17050
18454245
19807280
20909090
2110097100
22100103100
2310899100
24906390
25-814-8
26-40-34-40
27-55-58-55
28-80-60-80
29-45-54-45
30-38-33-38
31-15-18-15
32-23-2
33252225
34433843
35454945
36585858
37706970
38806880
39556255
40503550
41000
Timeevery 2ndTimeevery 3rdTimeevery 6thTimeevery 12
00000000
110250612512-110
35557812-1102490
57881018453658
712211-1002490410
9-2014-7530-38
11-1001703658
13-1302090410
15-9023108
17026-40
198029-45
2110032-2
231083545
25-83880
27-55410
29-45
31-15
3325
3545
3770
3955
410
Sheet1
Raw
Time
Amplitude
Sheet2
Ave before/after
Time
Amplitude
Sheet3
eliminate extremes (100/-100)
Time
Amplitude
every 2nd
Time
Amplitude
every 6th
Time
Amplitude
every 3rd
Time
Amplitude
every 12
Time
Amplitude
every 12th
Chart10
0
2
5
8
11
14
17
20
23
26
29
32
35
38
41
every 3rd
Time
Amplitude
0
50
78
10
-100
-75
0
90
108
-40
-45
-2
45
80
0
Sheet1
TimeRawAve before/aftereliminate extremes (100/-100)
0000
1102010
2503850
3556055
4756975
5789378
6125108100
712286100
8103710
9-20-19-20
10-48-56-48
11-100-86-100
12-110-113-100
13-130-105-100
14-75-98-75
15-90-65-90
16-30-40-30
17050
18454245
19807280
20909090
2110097100
22100103100
2310899100
24906390
25-814-8
26-40-34-40
27-55-58-55
28-80-60-80
29-45-54-45
30-38-33-38
31-15-18-15
32-23-2
33252225
34433843
35454945
36585858
37706970
38806880
39556255
40503550
41000
Timeevery 2ndTimeevery 3rdTimeevery 6thTimeevery 12
00000000
110250612512-110
35557812-1102490
57881018453658
712211-1002490410
9-2014-7530-38
11-1001703658
13-1302090410
15-9023108
17026-40
198029-45
2110032-2
231083545
25-83880
27-55410
29-45
31-15
3325
3545
3770
3955
410
Sheet1
Raw
Time
Amplitude
Sheet2
Ave before/after
Time
Amplitude
Sheet3
eliminate extremes (100/-100)
Time
Amplitude
every 2nd
Time
Amplitude
every 6th
Time
Amplitude
every 3rd
Time
Amplitude
every 12
Time
Amplitude
every 12th
How Does It Work?Resolution Trade-offs Using your raw digital data, create a new table of data
and delete all but every sixth data point This is the same as sampling at one-sixth the rate
1/6 Sample Rate
Raw
-150
-100
-50
0
50
100
150
0 10 20 30 40
Time
Ampl
itude
every 6th
-150
-100
-50
0
50
100
150
0 10 20 30 40
Time
Ampl
itude
Chart5
0
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
Raw
Time
Amplitude
0
10
50
55
75
78
125
122
10
-20
-48
-100
-110
-130
-75
-90
-30
0
45
80
90
100
100
108
90
-8
-40
-55
-80
-45
-38
-15
-2
25
43
45
58
70
80
55
50
0
Sheet1
TimeRawAve before/aftereliminate extremes (100/-100)
0000
1102010
2503850
3556055
4756975
5789378
6125108100
712286100
8103710
9-20-19-20
10-48-56-48
11-100-86-100
12-110-113-100
13-130-105-100
14-75-98-75
15-90-65-90
16-30-40-30
17050
18454245
19807280
20909090
2110097100
22100103100
2310899100
24906390
25-814-8
26-40-34-40
27-55-58-55
28-80-60-80
29-45-54-45
30-38-33-38
31-15-18-15
32-23-2
33252225
34433843
35454945
36585858
37706970
38806880
39556255
40503550
41000
Timeevery 2ndTimeevery 3rdTimeevery 6thTimeevery 12
00000000
110250612512-110
35557812-1102490
57881018453658
712211-1002490410
9-2014-7530-38
11-1001703658
13-1302090410
15-9023108
17026-40
198029-45
2110032-2
231083545
25-83880
27-55410
29-45
31-15
3325
3545
3770
3955
410
Sheet1
Raw
Time
Amplitude
Sheet2
Ave before/after
Time
Amplitude
Sheet3
eliminate extremes (100/-100)
Time
Amplitude
every 2nd
Time
Amplitude
every 6th
Time
Amplitude
every 3rd
Time
Amplitude
every 12
Time
Amplitude
every 12th
Chart11
0
6
12
18
24
30
36
41
every 6th
Time
Amplitude
0
125
-110
45
90
-38
58
0
Sheet1
TimeRawAve before/aftereliminate extremes (100/-100)
0000
1102010
2503850
3556055
4756975
5789378
6125108100
712286100
8103710
9-20-19-20
10-48-56-48
11-100-86-100
12-110-113-100
13-130-105-100
14-75-98-75
15-90-65-90
16-30-40-30
17050
18454245
19807280
20909090
2110097100
22100103100
2310899100
24906390
25-814-8
26-40-34-40
27-55-58-55
28-80-60-80
29-45-54-45
30-38-33-38
31-15-18-15
32-23-2
33252225
34433843
35454945
36585858
37706970
38806880
39556255
40503550
41000
Timeevery 2ndTimeevery 3rdTimeevery 6thTimeevery 12
00000000
110250612512-110
35557812-1102490
57881018453658
712211-1002490410
9-2014-7530-38
11-1001703658
13-1302090410
15-9023108
17026-40
198029-45
2110032-2
231083545
25-83880
27-55410
29-45
31-15
3325
3545
3770
3955
410
Sheet1
Raw
Time
Amplitude
Sheet2
Ave before/after
Time
Amplitude
Sheet3
eliminate extremes (100/-100)
Time
Amplitude
every 2nd
Time
Amplitude
every 6th
Time
Amplitude
every 3rd
Time
Amplitude
every 12
Time
Amplitude
every 12th
How Does It Work?Resolution Trade-offs Using your raw digital data, create a new table of data
and delete all but every twelfth data point This is the same as sampling at one-twelfth the rate
1/12 Sample Rate
Raw
-150
-100
-50
0
50
100
150
0 10 20 30 40
Time
Ampl
itude
every 12th
-150
-100
-50
0
50
100
150
0 10 20 30 40
Time
Ampl
itude
Chart5
0
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
Raw
Time
Amplitude
0
10
50
55
75
78
125
122
10
-20
-48
-100
-110
-130
-75
-90
-30
0
45
80
90
100
100
108
90
-8
-40
-55
-80
-45
-38
-15
-2
25
43
45
58
70
80
55
50
0
Sheet1
TimeRawAve before/aftereliminate extremes (100/-100)
0000
1102010
2503850
3556055
4756975
5789378
6125108100
712286100
8103710
9-20-19-20
10-48-56-48
11-100-86-100
12-110-113-100
13-130-105-100
14-75-98-75
15-90-65-90
16-30-40-30
17050
18454245
19807280
20909090
2110097100
22100103100
2310899100
24906390
25-814-8
26-40-34-40
27-55-58-55
28-80-60-80
29-45-54-45
30-38-33-38
31-15-18-15
32-23-2
33252225
34433843
35454945
36585858
37706970
38806880
39556255
40503550
41000
Timeevery 2ndTimeevery 3rdTimeevery 6thTimeevery 12
00000000
110250612512-110
35557812-1102490
57881018453658
712211-1002490410
9-2014-7530-38
11-1001703658
13-1302090410
15-9023108
17026-40
198029-45
2110032-2
231083545
25-83880
27-55410
29-45
31-15
3325
3545
3770
3955
410
Sheet1
Raw
Time
Amplitude
Sheet2
Ave before/after
Time
Amplitude
Sheet3
eliminate extremes (100/-100)
Time
Amplitude
every 2nd
Time
Amplitude
every 6th
Time
Amplitude
every 3rd
Time
Amplitude
every 12
Time
Amplitude
every 12th
Chart12
0
12
24
36
41
every 12
Time
Amplitude
every 12th
0
-110
90
58
0
Sheet1
TimeRawAve before/aftereliminate extremes (100/-100)
0000
1102010
2503850
3556055
4756975
5789378
6125108100
712286100
8103710
9-20-19-20
10-48-56-48
11-100-86-100
12-110-113-100
13-130-105-100
14-75-98-75
15-90-65-90
16-30-40-30
17050
18454245
19807280
20909090
2110097100
22100103100
2310899100
24906390
25-814-8
26-40-34-40
27-55-58-55
28-80-60-80
29-45-54-45
30-38-33-38
31-15-18-15
32-23-2
33252225
34433843
35454945
36585858
37706970
38806880
39556255
40503550
41000
Timeevery 2ndTimeevery 3rdTimeevery 6thTimeevery 12
00000000
110250612512-110
35557812-1102490
57881018453658
712211-1002490410
9-2014-7530-38
11-1001703658
13-1302090410
15-9023108
17026-40
198029-45
2110032-2
231083545
25-83880
27-55410
29-45
31-15
3325
3545
3770
3955
410
Sheet1
Raw
Time
Amplitude
Sheet2
Ave before/after
Time
Amplitude
Sheet3
eliminate extremes (100/-100)
Time
Amplitude
every 2nd
Time
Amplitude
every 6th
Time
Amplitude
every 3rd
Time
Amplitude
every 12
Time
Amplitude
every 12th
How Does It Work?Resolution Trade-offs What conclusions can you draw from the changes in
sampling rate? At what point does the waveform get too corrupted by
the reduced number of samples? Is there a point where more samples does not appear to
improve the quality of the duplication?
How Does It Work?Resolution Trade-offs
Bit Resolution
High Bit Count
Good Duplication
Slow
Low Bit Count
Poor Duplication
Fast
Sample Rate High Sample Rate
Good Duplication
Slow
Low Sample Rate
Poor Duplication
Fast
WHERE is DSP?A signal is any variable that carries information.
Examples of the types of signals of interest are: Speech (telephony, radio, everyday communication) Biomedical signals (EEG brain signals) Sound and music Video and image Radar signals (range and bearing).Digital signal processing (DSP) is concerned with the
digital representation of signals and the use of digital processors to analyze, modify, or extract information from signals.
WHY DSP?Many signals in DSP are derived from analogue signals which have
been sampled at regular intervals and converted into digital form. The key advantages of DSP over analogue processing are:
Guaranteed accuracy (determined by the number of bits used) Perfect reproducibility No drift in performance due to temperature or age Takes advantage of advances in semiconductor technology Greater flexibility (can be reprogrammed without modifying
hardware) Superior performance (linear phase response possible, and filtering algorithms can be made adaptive)
Sometimes information may already be in digital form.
DSP disadvantages Speed and cost (DSP design and hardware may be
expensive, especially with high bandwidth signals) Finite wordlength problems (limited number of bits
may cause degradation).
DSP application areas Image processing (pattern recognition, robotic vision,
image enhancement, facsimile, satellite weather map, animation)
Instrumentation and control (spectrum analysis, position and rate control, noise reduction, data compression)
Speech and audio (speech recognition, speechsynthesis, text to speech, digital audio, equalisation)
Military (secure communication, radar processing, sonar processing, missile guidance)
DSP application areas (cont.) Telecommunications (echo cancellation, adaptive
equalisation, spread spectrum, video conferencing, data communication)
Biomedical (patient monitoring, scanners, EEG brainmappers, ECG analysis, X-ray storage and enhancement).
An example: CDs Information on a compact disk is recorded on a spiral
track as a succession of pits (106 bits/mm2). The recording or mastering process is depicted below:
CD Recording process Analogue signal in each stereo channel is sampled at
44.1 kHz and digitised to 16 bits (96 dB dynamic range), resulting in 32 bits per sampling instant.
Encoded using a two-level Reed-Solomon code to enable errors to be corrected or concealed during reproduction.
An EFM (eight-to-fourteen) modulation scheme translates each byte in the stream to a 14 bit code, which is more suitable for disc storage (eliminates adjacent 1’s, etc.)
The resulting bit stream is used to control a laser beam, which records information on the disc.
CD audio signal reconstruction
CD Audio signal reconstruction (cont.) Track optically scanned at 1.2 m/s Signal is demodulated, errors detected and (if
possible) corrected. If correction is not possible, errors are concealed by interpolation or muting.
This results in a series of 16 bit words, each representing a single audio sample. These samples could be applied directly to a DAC and analogue lowpass filtered
CD Audio signal reconstruction (cont.) However, this would require high specification lowpassfilters (20 kHz frequencies must be reduced by 50 dB), and the filter should have linear phase. To avoid this, signals are upsampled by a factor of 4. This makes the output of the DAC smoother, simplifying the analogue filtering requirements.
The use of a digital filter also allows a linear phase response, reduces chances of intermodulation, and yields a filter that varies with clock rate.
Multimedia Signal Processing�1st Module�Fundamentals of Multimedia Signal ProcessingCourse overviewCourse overviewCourse overviewSuggested booksSignalsSignalsTHE INDEPENDENT VARIABLESTHE INDEPENDENT VARIABLESCT SignalsDT SignalsMany human-made DT SignalsSYSTEMSEXAMPLES OF SYSTEMSSYSTEM INTERCONNECTIONSMoving from Analog to Digital WorldWhat is DSP?What is DSP?What is DSP?Converting Analog into Digital�ElectronicallyConverting Analog into Digital�ElectronicallyConverting Analog into Digital�Electronically�Converting Analog into Digital�ComputationallyConverting Analog into Digital�ComputationallyBinary SearchBinary SearchBinary SearchBinary SearchBinary SearchBinary SearchBinary SearchBinary SearchBinary SearchBinary SearchHow Does It Work?�Faithful DuplicationStarting Waveform Used to Create Digital DataHow Does It Work?�Faithful DuplicationWaveform Created from Digital DataHow Does It Work?�Faithful DuplicationHow Does It Work?�Faithful DuplicationHow Does It Work?�Faithful DuplicationNoise Filtering Using AveragingHow Does It Work?�Faithful DuplicationClipping of Static CrashesHow Does It Work?�Resolution Trade-offsHalf Sample RateHow Does It Work?�Resolution Trade-offs1/2 Sample RateHow Does It Work?�Resolution Trade-offs1/6 Sample RateHow Does It Work?�Resolution Trade-offs1/12 Sample RateHow Does It Work?�Resolution Trade-offsHow Does It Work?�Resolution Trade-offsWHERE is DSP?WHY DSP?DSP disadvantagesDSP application areasDSP application areas (cont.)An example: CDsCD Recording processCD audio signal reconstructionCD Audio signal reconstruction (cont.)CD Audio signal reconstruction (cont.)
Recommended