0% found this document useful (0 votes)
53 views20 pages

Multirate Signal Processing, DSV2: Our Website Contains The Slides

- This document provides information about a course on Multirate Signal Processing including the lecture times, website links, homework and grading policies, software requirements, and an overview of topics to be covered. - Key topics include downsampling and upsampling of signals, filter banks, applications in areas like audio/image coding, and using Python for homework assignments. Students will learn how to design sampling rate converters and filter banks to solve problems in multirate signal processing. - The course will use Linux and require students to install Ubuntu either in a dual boot configuration or virtual machine to complete Python assignments, as Linux is better suited for programming than Windows.

Uploaded by

saradhi
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
53 views20 pages

Multirate Signal Processing, DSV2: Our Website Contains The Slides

- This document provides information about a course on Multirate Signal Processing including the lecture times, website links, homework and grading policies, software requirements, and an overview of topics to be covered. - Key topics include downsampling and upsampling of signals, filter banks, applications in areas like audio/image coding, and using Python for homework assignments. Students will learn how to design sampling rate converters and filter banks to solve problems in multirate signal processing. - The course will use Linux and require students to install Ubuntu either in a dual boot configuration or virtual machine to complete Python assignments, as Linux is better suited for programming than Windows.

Uploaded by

saradhi
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 20

Multirate Signal Processing, DSV2

Introduction
Lecture: Mi., 9-10:30 HU 010

Seminar: Do. 9-10:30, K2032 (bi-weekly)

Our Website contains the slides

www.tu-ilmenau.de/mt →
Lehrveranstaltungen → Master → Multirate
Signal Processing

We also have a Moodle 2 website, at

https://moodle2.tu-
ilmenau.de/course/view.php?id=395

which will contain the newest slides and the


weekly quiz assignments (to be done
individually).

There will be bi-weekly homework


assignments, which will count 30% towards
the fnal grade. The quizzes are part o3 the
homework, and will count as 25% o3 the
homework. To pass the course you need to
pass the fnal exam.

We have Python Homework, which can be


done in groups o3 max. 3 people.

The course has 5 LP (Credit Points), each LP


is about 2-3 hours per week, which means
we have 10-15 hours total per week or about
20 hours 3or 2 weeks (the homework cycle).

We will use the system Moodle2 3or


in3ormation exchange and 3or our quiz
assignments, at:
https://moodle2.tu-ilmenau.de/login/index.php

where you need to sign up.

Prerequisite: the course Advanced


Digital Signal Processing or DSP2, or the
corresponding knowledge.

Python is a very high level programming


language, which contains the convenience
and capabilities o3 Matlab/Octave, but is a
3ull fedged programming language with
many more capabilities and libraries. It is
Open Source and hence 3ree to download
and use. It can be installed under Windows,
but under Linux it is already installed, and
additional libraries are more easily installed
under Linux. In general programming is
much easier under Linux, because that is an
operating system made 3or scientists,
engineers, and programmers, unlike
Windows, which is made 3or ofce
applications.

Hence we will use Linux, and only support


Linux (you can use Windows but then you
are on your own).

Linux is also Open Source, and can be 3reely


downloaded and used (unlike Windows,
which is closed source and costs about 100
eur per copy!) Linux can be easily installed
as a dual boot system or on “VirtualBox” as
a virtual system on your Laptop or PC, 3or
instance by downloading the system 3rom
www.ubuntu.com – Download -Overview.
Download either “Desktop” 3or laptops or
desktop computers, or Ubuntu-Flavours –
Ubuntu Mate 3or Netbooks or the
Raspberry Pi. Then burn it to a USB stick or
SD card, and then start the installation 3or
instance by restarting the PC, keep F2 or F12
or so constantly pressed to get into the Boot
menu, and then choose “start 3rom USB” or
such. From there you can install Ubuntu as a
dual boot.

Alternatively, you can also install Linux


under “Virtual Box” on your PC or Laptop
or Netbook, which is a virtual machine (a
program which acts like a diferent
computer).

Here is a short installation guide:


-Install in Windows:

Install VirtualBox and VirtualBox-Extensions from virtualbox.org


Download .iso image from www.ubuntu.com or https://ubuntu-mate.org/download/ (for
lightweight laptops) to usb stick or the PC hard drive

-Start VirtualBox, Setup "New Machine" using the iso image. After finishing,
remove the iso image (if it is on the hard drive, rename it to avoid the
installation to start again)

-Before starting the virtual machine in VirtualBox:

Set RAM and Number of CPU's high, in Settings-System-Processor

(http://askubuntu.com/questions/365615/how-do-i-enable-multiple-cores-in-my-
virtual-enviroment)
-After starting the virtual machine, install guest additions. Open a terminal
Window, e.g. with keyboard shortcut Strg-Alt-T. Then type:

sudo apt install virtualbox-guest-additions-iso

cd /media/schuller/VBOXADDITIONS...

sudo sh ./VBoxLinuxAdditions.run

(See: wiki.ubuntuusers.de/VirtualBox/Installation)

-Then restart the virtual machine.

Press (right)Strg-F for full screen mode

-Activate external Devices for the virtual machine:

USB: On top menu bar of the VirtualBox go to Devices-USB click for


checkmark

Webcam: on the VirtualBox menu bar go to Devices-Webcam, click for


checkmark.
Scientifc Literature Work
When reading papers, check each
in3ormation you deem as important by
reading the corresponding references and
check them by checking their re3erences,
until you reach the source o3 the
in3ormation.

For in3ormation that is claimed as original,


do an internet search on similar results.

For formulas, check them by


programming them (e.g. in Python), and
see i3 you can reproduce the results
presented in the paper. I3 there is not
enough in3ormation to reproduce the results,
or the results difer signifcantly, that is a
bad sign.

For paper writing, re3erence every


in3ormation that you deem important or
relevant to the source where you‘ve got your
in3ormation 3rom. These re3erences are
important 3or reproducible research, and
they are also the „currency“ o3 science,
because scientists get their reputation 3rom
other people re3erencing them. Omitting
them is like „stealing“ or cheating.

I3 you are presenting algorithms or


programs, present them in 3ormulas or
pseudo-code in such a way that other people
can reproduce your results (again,
reproducable research). Check your
formulas by programming them yoursel3,
and see i3 they work. I3 you get error
messages or wrong results, this shows that
your 3ormula has a problem.
-Goal of the course: To be able to solve
problems in the area o3 Multirate Signal
Processing, like how to design sampling rate
converters or flter banks.

-Approach: Memorize only the most basic


3acts or properties, like the defnition o3 the
z-trans3orm, then know how to use them
(like how to derive the z-trans3orm o3 a
delayed signal). This is a skill.

As an Engineer, we need to get something to


work or to function in the end.
Engineering is also like applied physics, we
need the theory and then the
experimental verifcationn

It is recommended to read the slides


before a lecture, such that we can answer
questions during the lecture, and include
the answers in the slides. Hence the slides
will be kept in editing mode.

I will read each paragraph, and then ask 3or


questions.

I will also show simple Python examples.


Bring your Laptops, such that you can
try out these examples at the same
time!

Course Book: Gilbert Strang, Truong


Nguyen: “Wavelets and Filter Banks”

Ein deutsches Buch:

N. Fliege, "Multiraten-Signalverarbeitung:
Theorie und Anwendungen", Teubner,
Stuttgart, 1993

Lectures (as opposed to pure electronic


learning) have the advantage that we can
talk to each other, and that in this way the
content can be tailored to your background.
So you should ask questions, and also short
discussions are benefcial in this way.
What is Multirate Signal Processing?

Multirate: meaning diferent sampling


rates, as 3rom using downsampling or
upsampling. In flter banks, we reduce the
sampling rate a3ter fltering a signal, which
reduces the bandwidth. For reconstruction
and obtaining the original sampling rate, we
need to up-sample and flter (3or
interpolation) the signal.

Where is Multirate Signal Processing used?

For instance in coding and compression


algorithms, like the

 so-called Modifed Discrete Cosine


Trans3orm (MDCT) flter bank in audio
coding, or the

 Discrete Cosine Trans3orm (DCT) in


image or video coding

 Channel coding (OFDM), where a channel


is divided into many narrower channels
with lower data rates and hence longer
symbol duration, to reduce problems
with multipath/refections

 Example o3 a discrete time signal:

Typical sampling rate o3 audio 3rom a CD:

44100 samples/second, or

44.1 Khz sampling rate.

Python example 3or a live plot o3 a


microphone signal:

python pyrecplotanimation.py
 The Nyquist theorem tells us: Our
signal needs to be band limited to
less than half the sampling
frequency, here: less than 22.05
kHz. Half the sampling frequency
is also called the Nyquist
frequencyn
 For time discrete signals we only use
normalized frequencies, normalized to
the sampling frequency or the
Nyquist frequency. For the latter, the
normalized 3requency o3 1 would be the
Nyquist 3requency. O3ten you also fnd
π as the Nyquist Frequency.
 Simple sample rate conversion example:
Sampling rate conversion o3 an audio
signal 3rom 44.1 kHz (3rom a CD) down to
32 kHz on the computer. The signal at
44.1 kHz sampling rate has all
3requencies strictly below 22.05 kHz
(because o3 the Nyquist Theorem). A
signal at 32 Khz sampling rate needs all
3requencies strictly below 16 kHz.
Observe: here we lose the highest
3requency components (16kHz-22 kHz,
which is basically okay since human
hearing is usually only up to about 16
kHz). Be3ore down-sampling we have to
remove these high-3requency
components by low pass fltering.

 Upsampling: The other way around, 3rom


32 kHz to 44.1 kHz sampling rate.
Observe: here we obtain a new
3requency range 3rom 16kHz to 22 kHz,
which should contain no signal
components. Here we have to low pass
the up-sampled signal to these 16 kHz.

 This up- and down-sampling are the


basic building blocks o3 multirate signal
processing.

 The 3ollowing picture shows the basic


building blocks 3or low-pass fltering and
down-sampling by a 3actor o3 N, and up-
sampling by a 3actor o3 N 3ollowed by low
pass fltering:
Downsampler by N
Low
Signal Pass N

N Low
Pass Signal

Upsampler by N

Observe: We can do this down-


sampling and upsampling without loss o3
in3ormation (meaning the reconstructed
signal is identical to the lowpass signal),
i3 we obey the Shannon-Nyquist law.
This means the low pass (LP) needs to
be an ideal low pass with (normalized to
the Nyquist 3requency at the higher
sampling rate) cutof 3requency 1/N.
In this way we can per3ectly reconstruct the
lowest 1/N th o3 our signals spectrum.
Example: We have an audio signal with a
sampling rate o3 32 kHz and hence an audio
bandwidth o3 less than 16 kHz. For N=2 we
low pass flter it to 8 kHz, to remove the
3requencies at and above the new Nyquist
3requency o3 8 kHz. Then we can
downsample it by a 3actor o3 N=2 (by
dropping every second sample), to obtain an
audio signal at a sampling rate o3 16 kHz.

We can the upsample the audio signal back


to 32 kHz, by a 3actor o3 2, by insterting a 0
a3ter each sample, which produces “alias”
components above 8 kHz, and then low pass
flter the signal, again with our lowpass with
cutof 3requency o3 8 kHz, to remove the
alias components. This results in the same
audio signal with bandwidth o3 8 kHz, but
now at 32 kHz sampling rate.

The 3ollowing picture shows a flter bank


with critical sampling, which means its
downsampling rate N is identical to the
number o3 subbandsn It is the principal tool
3or multirate signal processing, frst the
analysis flter bank:
h N−1 (n) N y ↓n NN −1 (m)
0,

x (n)
Input h N −2 (n) N

Signal .
.
.

h0 (n) N y ↓n N (m)
0,0


Convolution L−1
L
↓N
y (m)= ∑ x (mN +n0 −n)hk (n)
∑ x(n−l)⋅hk (l) n0
n=0
l =0

Observe: For each time step m we obtain a


spectrum, and 3or each subband we obtain a
narrow bandwidth time signal. So depending
on our perspective, we have a set o3 spectra,
or a set o3 narrow bandwidth time signal.

This is why we also call this a


time/frequency representation.

Remember: The flter boxes symbolize a


convolution o3 the signal x (n) with the
impulse response h(n) o3 length L o3 each
flter, be3ore downsampling:
L−1
x ( n)∗h( n )= ∑ x ( n−l )⋅h( l )
l=0

where the sum is assumed to go over only


the parts where x (n) and h(n) are defned.

Downsampling by N means we replace n


by mN +n0 , with m the index m at the
lower sampling rate, and n0 the phase
index,
L−1
↓N
y n0 (m)= ∑ x(mN +n0 −n)hk (n)
n=0

The analysis flter bank decomposes the


signal into diferent 3requency bands.
Observe that each 3requency band has a
lower sampling rate, which is possible
because they have a lower bandwidth. Using
the “bandpass Nyquist” theorem we can
reconstruct the original signal 3rom the
subbands!
y N −1 (m)
g N −1 (n)
N

x^ (n)
N g N −2 (n)
Rec.
. +
Signal
.
y 0 (m) .
N −1

N g 0 (n) x^ (n)= ∑ x k (n)


k =0

L−1
N ↑N
x k (n):= y ↑
0, k (n)∗g k (n)= ∑ y 0, k (n−n ' )⋅g k (n ' )
n ' =0

To reconstruct the original 3rom the diferent


3requency bands, we need the synthesis
flter bank:

To simpli3y notation we dropped the


downarrow and phase index 3or the subband
signals y k (m) .

Observe: The flters a3ter the up-


sampling take on the role o3 the lowpass
flter in the conventional Nyquist
theorem, to block the alias components.
They “fsh out” the correct 3requency
image out o3 the aliased images 3or that
subband. All the subbands are then
added up to reconstruct the original
signal.

Example 3or our 2-band system: We


have N=2, original sampling rate 32
kHz. Then the low pass branch
corresponds to our low pass example
above, which reconstructs the signal
3rom 0 to 8 kHz. We now also have a
high pass branch, which in addition
reconstructs the 3requency 3rom 8kHz to
16 kHz. We add the two subbands in the
synthesis flter bank to obtain the 3ull
bandwidth signal 3rom 0 to 16 kHz.
For the playback of sound (with the functon “sound”),
also the sofware package “sox” needs to be installed
from the sofware package manager under iinux!
In the command line with
sudo apt-get install sox

You might also like