0% found this document useful (0 votes)
23 views33 pages

ECT303 Module 1 Part 1

Uploaded by

anamikanaircs11
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)
23 views33 pages

ECT303 Module 1 Part 1

Uploaded by

anamikanaircs11
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/ 33

ECT303 DIGITAL SIGNAL

PROCESSING

MODULE 1-PART I

Ms. Neethu Radha Gopan, Asst. Professor, Dept. of ECE, RSET


Syllabus
2

Part 3

Part 1

Part 2

Part 3
Digital Signal Processing
3

➢ Digital Signal Processing is defined as the processing of a signal in the digital domain
to analyze, measure, and manipulate the signal using mathematical calculations.
➢ 2 types of signal processing- Analog signal processing & Digital signal processing
Basic Elements of a Digital Signal Processing System
4
➢ Most of the signals encountered in science and engineering are analog in nature.
To perform the processing digitally, there is a need for an interface between the
analog signal and the digital processor. This interface is called an analog-to-
digital (A/D) converter. The output of the A/D converter is a digital signal that is
appropriate as an input to the digital processor.
➢ The digital signal processor may be a large programmable digital computer or a
small microprocessor programmed to perform the desired operations on the input
signal. It may also be a hardwired digital processor configured to perform a
specified set of operations on the input signal.
➢ In applications where the digital output from the digital signal processor is to be
given to the user in analog form, such as in speech communications, a digital-to-
analog (D/A) converter is used.
➢ However, there are other practical applications involving signal analysis, where
the desired information is conveyed in digital form and no D/A converter is
required.
5
Advantages of Digital Signal Processing
6

1.Flexibility-The reconfiguration in an analog system is very much tough because the


entire hardware and its component will have to be changed. On the contrary, a DSP
reconfiguration is much more comfortable as only the code, or the DSP program needs to
be flashed after making the changes according to the requirements.
2. Accuracy- The filters designed in DSP have firm control over output accuracy as
compared to analog filters.
3. Implementation in digital is much more cost effective than its analog counterpart.
4. Easy of storage & accessible transportation is possible because digital signals can be
processed offline.
5. Using the DSP method sophisticated signal processing algorithms can be implemented.
6. The interface types offered by DSP are many like UART, 12C, and others. This
helps in interfacing other ICs with the DSP.
Disadvantages of Digital Signal Processing
7

1. Higher bandwidth is required for digital communication than analog for


transmission of the same information.

2. DSP’s process signals at high speed and comprises of more top internal hardware
resources. Because of this DSP dissipates higher power as compared to analog
signal processing.

3. One needs to cautiously use the IC as per hardware and software requirements as
most of the DSP chip is very expensive
Applications
8

➢ Audio signal processing & audio compression


➢ Digital image processing & video compression
➢ Speech processing & speech recognition
➢ Telecommunication- Echo cancellation in telephone networks, Modems, Channel
multiplexing, etc.
➢ Military-Radar signal processing, Sonar signal processing, Navigation, etc.
➢ Seismology- DSP techniques are used for geophysical exploration for oil & gas,
detection of underground nuclear explosion & earthquake monitoring.
➢ Biomedicine-Medical diagnostic instrumentation such as CT, X-ray scanning, MRI ,
Spectrum analysis od EEG & ECG, etc.
➢ Remote Sensing
Discrete Time Fourier Transform (DTFT)
9

➢ Consider a finite length sequence x(n) in the figure. The DTFT is given by
𝑁−1

𝑋 𝑒 𝑗𝜔 = ෍ 𝑥(𝑛) 𝑒 −𝑗𝑤𝑛
𝑛=0
➢ It can be seen that the Fourier transform (DTFT) is continuous and periodic with
respect to 2𝜋.
➢ Hence DTFT cannot be used for computations on a digital processor. Therefore we
go for DFT.
Discrete Fourier Transform (DFT)
10

➢ DFT is a powerful computational tool which allows to evaluate the Fourier


transform X (𝑒 𝑗𝑤 ) on a digital processor.
➢ DFT is only defined for finite length sequences, hence it is a finite length discrete
transform.
➢ DTFT , X (𝑒 𝑗𝑤 ) is continuous and periodic wrt 2𝜋. Hence we take the range 0 to
2𝜋.
➢ DFT is obtained by sampling one period (0 to 2𝜋 ) of the DTFT at a finite number
of frequency points to form N samples.
➢ These N equally spaced frequency samples of DTFT are known as DFT. Hence
DFT is periodic wrt N.
Discrete Fourier Transform (DFT)
11
Discrete Fourier Transform (DFT)
12

➢ DFT provides uniformly spaced samples of the Fourier Transform 𝑋(𝑒 𝑗𝜔 ) at N



equally spaced points over the interval 0≤ 𝜔 ≤ 2π with a spacing of
𝑁
2π𝑘
➢ 𝑋 𝑘 = 𝑋(𝑒 𝑗𝜔 )ห 𝜔= , 0≤𝑘 ≤𝑁−1
𝑁
➢ For a finite duration causal sequence, DTFT is given by
𝑁−1

𝑋 𝑒 𝑗𝜔 = ෍ 𝑥(𝑛) 𝑒 −𝑗𝑤𝑛
𝑛=0
2π𝑘
➢ Replacing 𝜔 = , the N point DFT can be written as
𝑁
𝑁−1
2π𝑘
−𝑗 𝑛
𝑋 𝑘 = ෍ 𝑥(𝑛) 𝑒 𝑁 , 0≤𝑘 ≤𝑁−1
𝑛=0
Inverse Discrete Fourier Transform (IDFT)
13

➢ IDFT is computed as:


𝑁−1
1 2π𝑘
𝑗 𝑁 𝑛
𝑥 𝑛 = ෍ 𝑋(𝑘) 𝑒 , 0≤𝑛 ≤𝑁−1
𝑁
𝑘=0

➢ N≥L, L-length of the sequence x(n)


➢ IDFT is x(n) and is periodic wrt N
Notations:
X(k) = DFT[x(n)] n-time index
x(n) = IDFT[X(k)] k-frequency index
Q. Find DFT of x(n)={1,1,0,0}
14

Solution: Take N=4


𝑁−1
2π𝑘
−𝑗 𝑛
𝑋 𝑘 = ෍ 𝑥(𝑛) 𝑒 𝑁 , 0≤𝑘 ≤𝑁−1
𝑛=0
3
2π𝑘
−𝑗 4 𝑛
𝑋 𝑘 =෍ 𝑥(𝑛) 𝑒 , 0≤𝑘≤3
𝑛=0
3

𝑋 0 = ෍ 𝑥(𝑛)𝑒 0 = 𝑥 0 + 𝑥 1 + 𝑥 2 + 𝑥 3 =1 + 1 + 0 + 0 = 2
𝑛=0
3
2π π 3π
−𝑗 4 𝑛 −𝑗 2 −𝑗 2
𝑋 1 =෍ 𝑥(𝑛)𝑒 =𝑥 0 . 𝑒0 + 𝑥 1 .𝑒 +𝑥 2 . 𝑒 −𝑗π +𝑥 3 .𝑒
𝑛=0
π π
=1+1.(cos − jsin ) + 0 + 0 = 1+1(-j) = 1-j
2 2
15

3
0 −𝑗π
𝑋 2 = ෍ 𝑥(𝑛)𝑒 −𝑗π𝑛 = 𝑥 0 . 𝑒 + 𝑥 1 . 𝑒 + 𝑥 2 . 𝑒 −𝑗2π + 𝑥 3 . 𝑒 −𝑗3π
𝑛=0
= 1+1.(cos π − jsinπ) + 0 + 0 =1+1(-1) = 0
3
6π 3π 9π
−𝑗 4 𝑛 −𝑗 −𝑗
𝑋 3 =෍ 𝑥(𝑛)𝑒 = 𝑥 0 . 𝑒0 + 𝑥 1 . 𝑒 2 + 𝑥 2 . 𝑒 −𝑗3π + 𝑥 3 . 𝑒 2
𝑛=0 3π 3π
= 1+1.(cos − jsin ) + 0 + 0 = 1+1(j) = 1+j
2 2

∴ 𝑋(𝑘) ={2, 1-j, 0, 1+j}


Q. Find IDFT of Y(k)={1,0,1,0}
16

Soln:
𝑁−1 3
1 2π𝑘
𝑗 𝑁 𝑛 1 2π𝑘
𝑦 𝑛 = ෍ 𝑌(𝑘) 𝑒 = ෍ 𝑌(𝑘) 𝑒 4 𝑛 ,
𝑗
0≤𝑛≤3
𝑁 4
𝑘=0 𝑘=0
3
1 0 =
1
𝑦 0 = ෍ 𝑌(𝑘) 𝑒 𝑌 0 +Y 1 +𝑌 2 +𝑌 3
4 4
𝑘=0
1
= 1 + 0 + 1 + 0 = 0.5
4
3
1 2π𝑘
𝑗 4
1 0
π
𝑗2 𝑗π

𝑗2
𝑦 1 = ෍ 𝑌(𝑘) 𝑒 = 𝑌 0 .𝑒 + Y 1 .𝑒 + 𝑌 2 .𝑒 + 𝑌 3 .𝑒
4 4
𝑘=0
1
= 1 + 0 + 1(−1) + 0 = 0
4
17

Similarly compute 𝑦 2 and 𝑦 3

𝑦 𝑛 = {0.5, 0 , 0.5 , 0}
𝟏 𝒇𝒐𝒓 𝟎 ≤ 𝒏 ≤ 𝟐
Q. Find the DFT of x(n) = ቊ for N=4 and N=8. Plot
𝟎 𝒐𝒕𝒉𝒆𝒓𝒘𝒊𝒔𝒆
𝑿(𝒌) and ∠𝑿(𝒌).
18

Soln:
x(n)={1,1,1}
Note:
Case 1: Since N=4, zero pad the sequence to make length = 4
If, X=a+jb
∴ 𝑥 𝑛 = 1,1,1,0 |X|= 𝒂𝟐 + 𝒃𝟐
𝒃
Calculate 4 point DFT: 𝑋 𝑘 = {3, −𝑗, 1, 𝑗} ∠X= 𝒕𝒂𝒏−𝟏
𝒂
0 Also,
X(0) =3, 𝑋(0) = 3 , ∠𝑋 0 = 𝑡𝑎𝑛−1 =0
3 −𝒃
−𝟏
−1 −1 −1 1 𝜋 𝒕𝒂𝒏
X(1) = -j, 𝑋(1) = 1 , ∠𝑋 0 = 𝑡𝑎𝑛 = −𝑡𝑎𝑛 = − 𝒂
0 0 2
−𝟏
𝒃
0 = −𝒕𝒂𝒏 ( )
X(2) = 1, 𝑋(2) = 1 , ∠𝑋 0 = 𝑡𝑎𝑛−1 =0 𝒂
1
1 1 𝜋
X(3) = j, 𝑋(1) = 1 , ∠𝑋 0 = 𝑡𝑎𝑛−1 = 𝑡𝑎𝑛−1 =
0 0 2
19
Case 2: Since N=8, zero pad the sequence to make length = 8
∴ 𝑥 𝑛 = 1,1,1,0,0,0,0,0
20

❑ Calculate 8 point DFT


𝑁−1 7
2π𝑘 2π𝑘
−𝑗 𝑁 𝑛 −𝑗 8 𝑛
𝑋 𝑘 =෍ 𝑥(𝑛) 𝑒 =෍ 𝑥(𝑛) 𝑒 , 0≤𝑘≤7
𝑛=0 𝑛=0
Then draw the magnitude and phase plot
Answers for reference:
X(k) ={3, 1.707-j1.707, -j, 0.293+j0.293, 1, 0.293- j0.293, j, 1.707+j1.707}
|X(k)|= {3, 2.414, 1, 0.414, 1, 0.414, 1, 2.414}
𝜋 𝜋 𝜋 𝜋 𝜋 𝜋
∠𝑋 0 = {0, − , − , , 0, − , , }
4 2 4 4 2 4
Q. Find the N point DFT of 𝒙 𝒏 = 𝒂𝒏 , 𝟎 ≤ 𝒂 ≤ 𝟏.
21

𝑁−1
2π𝑘
−𝑗 𝑁 𝑛
𝑋 𝑘 =෍ 𝑥(𝑛) 𝑒
𝑛=0
𝑁−1 𝑁−1
2π𝑘 𝑗2π𝑘
−𝑗 𝑛 − 𝑁 )𝑛
=෍ 𝑎𝑛 𝑒 𝑁 = ෍ (𝑎𝑒 Note:
𝑁−1
𝑛=0 𝑛=0 1 − 𝑎 𝑁
෍ 𝑎𝑛 =

𝑗2π𝑘 1−𝑎
1 − (𝑎𝑒 𝑁 )𝑁 1 − 𝑎𝑁 𝑒 −𝑗2π𝑘 𝑛=0
= 𝑗2π𝑘
= 𝑗2π𝑘
− 𝑁 −
1 − 𝑎𝑒 1 − 𝑎𝑒 𝑁

1 − 𝑎𝑁
= 𝑗2π𝑘

1 − 𝑎𝑒 𝑁
Practice Problems
22

1. Compute the 8 point DFT of the sequence

𝑥 𝑛 = {0,2,4,6}

2. Compute the IDFT of

X(k)={5, 0, 1-j, 0, 1, 0, 1+j, 0}


DFT as a Linear Transformation
23
𝑁−1 𝑁−1
2π𝑘
−𝑗 𝑛
𝐃𝐅𝐓: 𝑋 𝑘 = ෍ 𝑥(𝑛) 𝑒 𝑁 = ෍ 𝑥(𝑛) 𝑊𝑁 𝑘𝑛
𝑛=0 𝑛=0
𝑁−1 𝑁−1
1 2π𝑘
𝑗 𝑁 𝑛 1
𝐈𝐃𝐅𝐓: 𝑥 𝑛 = ෍ 𝑋(𝑘) 𝑒 = ෍ 𝑋(𝑘) 𝑊𝑁 −𝑘𝑛
𝑁 𝑁
𝑘=0 𝑘=0

where 𝑊𝑁 = e−j2π/N is called twiddle factor.


➢ Let 𝑥𝑁 be the N point vector of the signal sequence x(n), n=0,1,…., N-1 and 𝑋𝑁 be
the N- point vector of frequency samples,
𝑥(0) 𝑋(0)
𝑥(1) 𝑋(1)
𝒙N = and 𝐗 N =
⋮ ⋮
𝑥(𝑁 − 1) 𝑋(𝑁 − 1)
DFT as a Linear Transformation
24

➢ Let 𝑊𝑁 be an N×N matrix given as


1 1 1 … 1
1 𝑊𝑁 𝑊𝑁 2 … 𝑊𝑁 𝑁−1
𝐖𝑁 = 1 𝑊𝑁 2 𝑊𝑁 4 … 𝑊𝑁 2(𝑁−1)
⋮ ⋮ ⋮ … ⋮
1 𝑊𝑁 𝑁−1 𝑊𝑁 2(𝑁−1) … 𝑊𝑁 (𝑁−1)(𝑁−1)
➢ The N-point DFT can be expressed as a linear transformation
𝑋𝑁 = 𝑊𝑁 . 𝑥𝑁
1
➢ IDFT is given by 𝑥𝑁 = 𝑊𝑁 −1 . 𝑋𝑁 = 𝑊𝑁 ∗ . 𝑋𝑁
𝑁
Properties of twiddle factor
25

1. Periodicity
𝑊𝑁 𝑘+𝑁 = 𝑊𝑁 𝑘

2. Symmetry
𝑁
𝑘+
𝑊𝑁 2 = −𝑊𝑁 𝑘
26

Eg: 4 point DFT, k=0 to 3

2𝜋 2𝜋 2𝜋.6
−𝑗 𝑁 −𝑗
𝑊𝑁 = 𝑊4 =𝑒 = 𝑒 −𝑗 4 Similarly 𝑊46 = 𝑒 4 = −1 = 𝑊42+4 = 𝑊42
2𝜋.0 (periodicity)
𝑘 0 −𝑗 4
𝑊4 : 𝑊4 = 𝑒 =1
2𝜋.1 𝜋
1 −𝑗 4 −𝑗 2
𝑊4 = 𝑒 =𝑒 = −𝑗
2𝜋.2
2 −𝑗
𝑊4 = 𝑒 4 = 𝑒 −𝑗𝜋 = −1
2𝜋.3 3𝜋
3 −𝑗 −𝑗
𝑊4 = 𝑒 4 = 𝑒 2 = 𝑗
2𝜋.4
𝑊44 = 𝑒 −𝑗 4 = 1 = 𝑊40+4 = 𝑊40 (periodicity)
2𝜋.5 4
−𝑗 4 3+2
𝑊45 = 𝑒 = −𝑗 = 𝑊4 = −𝑊43 (symmetry)
Q. Compute DFT of x(n)={0,1,2,3}
27

Soln:
1 1 1 1
1 𝑊4 𝑊4 2 𝑊4 3
First step is to determine 𝐖4 =
1 𝑊4 2 𝑊4 4 𝑊4 6
1 𝑊4 3 𝑊4 6 𝑊4 9
2𝜋
−𝑗 𝑁
𝑊𝑁 = 𝑒
2𝜋
−𝑗 4
𝜋
−𝑗 2 𝜋 𝜋
𝑊4 = 𝑒 =𝑒 = 𝑐𝑜𝑠 − 𝑗𝑠𝑖𝑛 = −𝑗
2 2
2𝜋
2 −𝑗 4 .2
𝑊4 = 𝑒 = 𝑒 −𝑗𝜋 = cos 𝜋 − 𝑗𝑠𝑖𝑛 𝜋 = −1
2𝜋
−𝑗 .3 −𝑗
3𝜋 3𝜋 3𝜋
𝑊4 3 = 𝑒 4 = 𝑒 2 = cos − 𝑗𝑠𝑖𝑛 =𝑗
2 2
𝑊4 4 = 𝑊4 0+4 = 𝑊4 0 = 1 (periodicity)
28

𝑊4 6 = 𝑊4 2+4 = 𝑊4 2 = −1 (periodicity)
𝑊4 9 = 𝑊41+2.(4) = 𝑊41 = −𝑗 (periodicity)

1 1 1 1 0
1 −𝑗 −1 𝑗
𝐖4 = and from question 𝐱4 = 1
1 −1 1 −1 2
1 𝑗 −1 −𝑗 3

1 1 1 1 0 6
1 −𝑗 −1 𝑗 1 −2 + 2𝑗
𝐗 4 = 𝐖4 𝐱4 = . =
1 −1 1 −1 2 −2
1 𝑗 −1 −𝑗 3 −2 − 2𝑗
Relationship of DFT to other Transforms
29

1. Relationship of DFT to Fourier transform


➢ Fourier transform of a finite duration sequence x(n) having length N is
given by, N−1

X ejω = ෍ x n e−jωn −−− −(1)


n=0
where X ejω is a continuous function of ω
𝑁−1
2π𝑘
−𝑗 𝑛
➢ DFT is given by 𝑋 𝑘 = ෍ 𝑥(𝑛) 𝑒 𝑁 −− −(2)
𝑛=0
➢ Comparing the two, we see that DFT is the sampled version of Fourier
transform
2π𝑘
𝑋 𝑘 = 𝑋(𝑒 𝑗𝜔 )ห 𝜔 = 0≤𝑘 ≤𝑁−1
𝑁
2. Relationship of DFT to z-transform
30

➢ Considering a sequence x(n) of finite duration N with z-transform


𝑁−1

𝑋 𝑧 = ෍ 𝑥(𝑛) 𝑧 −𝑛 −−−−− −(1)


𝑛=0 𝑁−1
1 2π𝑘
𝑗 𝑁 𝑛
➢ Expression for IDFT, 𝑥 𝑛 = 𝑁 ෍ 𝑋(𝑘) 𝑒 −−− −(2)
𝑘=0
➢ Substituting (2) in (1) gives
𝑁−1 𝑁−1 𝑁−1 𝑁−1
1 2π𝑘
𝑗 𝑁 𝑛 1 2π𝑘
𝑗 𝑁 𝑛 −𝑛
𝑋 𝑧 =෍ ෍ 𝑋(𝑘) 𝑒 𝑧 −𝑛 = ෍ 𝑋(𝑘) ෍ 𝑒 𝑧
𝑁 𝑁
𝑛=0 𝑘=0 𝑘=0 𝑛=0
Note:
𝑁−1 𝑁−1 𝑁−1
1 2π𝑘
𝑗 𝑁 −1 𝑛 1 − 𝑎 𝑁
𝑋 𝑧 = ෍ 𝑋(𝑘) ෍ (𝑒 𝑧 ) ෍ 𝑎𝑛 =
𝑁 1−𝑎
𝑘=0 𝑛=0
𝑛=0
31

𝑁−1 2π𝑘
𝑗
1 1 − (𝑒 𝑁 𝑧 −1 )𝑁
𝑋 𝑧 = ෍ 𝑋(𝑘) 2π𝑘 Note:
𝑁 𝑗 𝑁 −1
𝑘=0 1−𝑒 𝑧 𝑒 𝑗2π𝑘 = cos 2π𝑘 + 𝑗𝑠𝑖𝑛2π𝑘
=1
𝑁−1
1 1 − 𝑒 𝑗2π𝑘 𝑧 −𝑁
= ෍ 𝑋(𝑘) 2π𝑘
𝑁 𝑗 𝑁 −1
𝑘=0 1−𝑒 𝑧

−𝑁 𝑁−1
1−𝑧 𝑋(𝑘)
𝑋 𝑧 = ෍ 2π𝑘
𝑁 𝑗 𝑁 −1
𝑘=0 1 −𝑒 𝑧
REFERENCES
32

1. Proakis J. G. and Manolakis D. G., Digital Signal Processing, 4/e,


Pearson Education, 2007.
2. P. Ramesh Babu, Digital Signal Processing, Scitech Publications (India)
Pvt Ltd.
33 End of Part-I

THANK YOU!

You might also like