Professional Documents
Culture Documents
8 Kundur Overlap Save Add PDF
8 Kundur Overlap Save Add PDF
x(n) =
1 / 58
Time Domain
x(n)
x(n) = x(n + N)
a1 x1 (n) + a2 x2 (n)
x(N n)
x((n l))N
x(n)e j2ln/N
x (n)
x1 (n) x2 (n)
x1 (n)x2 (n)
P
N1
x(n)e j2k N ,
n=0
N1
X
1
N
k = 0, 1, . . . , N 1
n
X (k)e j2k N ,
n = 0, 1, . . . , N 1
k=0
Property
Notation:
Periodicity:
Linearity:
Time reversal
Circular time shift:
Circular frequency shift:
Complex conjugate:
Circular convolution:
Multiplication:
Parsevals theorem:
N1
X
2 / 58
Circular Convolution
Frequency Domain
X (k)
X (k) = X (k + N)
a1 X1 (k) + a2 X2 (k)
X (N k)
X (k)e j2kl/N
X ((k l))N
X (N k)
X1 (k)X2 (k)
1
X1 (k) X2 (k)
N P
N1
1
x1 (n) x2 (n)
X1 (k)X2 (k)
3 / 58
4 / 58
Circular Convolution
Circular Convolution
1
4
-3
-2
-1
x1 (n) x2 (n) =
10
11
12
-3
-2
-1
=
1
10
11
12
N1
X
k=0
N1
X
k=0
-3
-2
-1
10
11
12
5 / 58
Example: N = 4
n
-4 -3 -2
(n)4 0 1 2
(n)N = n
Example: N = 4
-4 -3 -2
n
(n)4 0 1 2
-1 0 1 2 3 4 5 6 7 8
3 0 1 2 3 0 1 2 3 0
-1 0 1 2 3 4 5 6 7 8
3 0 1 2 3 0 1 2 3 0
2
2
= 1 +
4
4
6 / 58
5
1
=1+
4
4
7 / 58
8 / 58
x(n) =
x(n lN)
l=
9 / 58
l=-2
-7
-6
-5
-4
-3
-2
-1
-7
-6
-5
-4
-3
-2
l=1
-1
l=-2
x (n)
x (n-2N)
...
7
-7
-6
-5
-4
-3
-2
-1
-5
x (n)
-7
l=2
x (n-2N)
+
+
1
x (n)
-6
-5
-4
-3
-2
-1
-4
-3
-2
-1
x~ (n)
-7
-6
-5
-4
-3
-2
-1
=x(n)
= x (n)
Dr. Deepa Kundur (University of Toronto)
l=1
x (n-N)
overlap
~
support length = 4 = N
-6
l=0
x (n+N)
...
l=-1
x (n+2N)
no overlap
-7
10 / 58
l=2
x (n-N)
x (n)
l=0
x (n+N)
...
1
l=-1
x (n+2N)
11 / 58
12 / 58
-7 -6 -5 -4 -3 -2 -1 0 1 2 3 4 5 6 7
x(n lN)
l=
Note: Because the support size and period size are the same, there is
no overlap when taking the periodic repetition x((n))N .
13 / 58
-7 -6 -5 -4 -3 -2 -1 0 1 2 3 4 5 6 7
1
0
-7 -6 -5 -4 -3 -2 -1 0 1 2 3 4 5 6 7
15 / 58
x((n))N
1
1
0
x(n)
1
14 / 58
1
0
16 / 58
12
8
4
0
-4
1
0
15
11
7
3
-1
12
8
4
0
-4
1
0
1
1
-7 -6 -5 -4 -3 -2 -1 0 1 2 3 4 5 6 7
13
9
5
1
-3
x((n))N
13
9
5
1
-3
14
10
6
2
-2
-7 -6 -5 -4 -3 -2 -1 0 1 2 3 4 5 6 7
x(n)
x((n))N
15
11
7
3
-1
x(n)
14
10
6
2
-2
x (n)
2
1
-7 -6 -5 -4 -3 -2 -1 0 1 2 3 4 5 6 7 ...
17 / 58
18 / 58
PN1
k=0
PN1
k=0
N1
X
x2 (n lN)
k=0
l=
x1 (k)
x2 (n k) =
k=
N1
X
N1
X
x1 (k) x2 (n k)
k=0
x1 (k)
x2 (n k)
k=0
19 / 58
20 / 58
PN1
k=0
PN1
k=0
x1 (k)x2 (n k) =
k=
N1
X
xL (n lN),
for n = 0, 1, . . . , N 1
Q: When can one recover xL (n) from xC (n)?
When can one use the DFT (or FFT) to compute linear convolution?
A: When there is no overlap in the periodic repetition of xL (n).
When support length of xL (n) N.
n = 0, 1, . . . , N 1
l=
xL (n lN)
l=
k=0
2. Compute the periodic repetition of xL (n) and window the result for
n = 0, 1, . . . , N 1:
x1 (n) x2 (n) =
21 / 58
22 / 58
For linear filtering via the DFT, for example, the signal must be
limited size due to memory requirements.
23 / 58
24 / 58
x(0)
x(4)
W8
Stage 2
Stage 3
W8
X(2)
-1
2
W8
W8
X(0)
x(6)
X(1)
-1
x(2)
-1
X(3)
-1
0
W8
x(1)
-1
X(4)
x(5)
W8
0
W8
-1
-1
0
W8
x(3)
2
W8
-1
2
x(7)
-1
W8
-1
-1
signal
input
X(6)
25 / 58
signal
output
26 / 58
Strategy:
Data Processing
Delay
X(7)
Data Acquisition
Delay
W8
0
W8
-1
X(5)
27 / 58
Overlap-Add Method
Overlap-Save Method
Assumptions:
I
I
28 / 58
Overlap-Add Method
Overlap-Add Method
Overlap-Add Method
Overlap-Add Method
Deals with the following signal processing principles:
I
Addititvity:
Overlap-Add Method
29 / 58
Overlap-Add Method
-2
-1
L=4
L=4
L=4
Input
into
blocks
length
L=4
x1(n)
* h(n)
-2
-1
L=4
x2(n)
* h(n)
1
4
-3
-2
-1
L=4
x3(n)
* h(n)
1
10
-3
-2
-1
10
x(n) is divided
non-overlapping
xm (n) each of
L.
10
-3
Overlap-Add Method
10
30 / 58
* h(n)
4
-3
x(n)
1
Each
input
block
xm (n) is individually
filtered as it is received
to produce the output
block ym (n).
+ ...
n
L=4
31 / 58
32 / 58
Overlap-Add Method
Overlap-Add Method
l=-2
x (n)
x (n+2N)
-5
-4
-3
-2
-1
-7
l=1
l=0
-6
-5
-4
-3
-2
-1
l=2
x (n-N)
x (n)
...
-7
l=-1
x (n+N)
x (n-2N)
...
7
no overlap
x~ (n)
support length = 4 = N
-7
-6
-5
-4
-3
-2
-1
= x (n)
Dr. Deepa Kundur (University of Toronto)
33 / 58
Overlap-Add Method
x(n)
* h(n)
4
-2
-1
L=4
L=4
* h(n)
-1
L=4
x2(n)
* h(n)
1
4
-3
-2
-1
L=4
x3(n)
* h(n)
1
10
-3
-2
-1
10
x(n) is divided
non-overlapping
xm (n) each of
L.
10
-2
4
-3
Input
into
blocks
length
L=4
x1(n)
-3
Overlap-Add Method
* h(n)
10
L=4
34 / 58
x(n)
-3
-2
-1
L=4
L=4
L=4
Each
input
block
xm (n) is individually
filtered as it is received
to produce the output
block ym (n).
+ ...
-2
-1
L=4
y2(n)
-2
-1
ADD
to
next
block
2
10
M-1=2
L=4
y3(n)
ADD
to
next
block
+ ...
-2
-1
L=4
35 / 58
10
-3
M-1=2
4
-3
L=4
10
-3
L=4
y1(n)
10
M-1=2
36 / 58
Overlap-Add Method
* h(n)
1
4
-3
-2
-1
L=4
L=4
L=4
y1(n)
xm (n)
10
L=4
-3
X
X
=
xm (n) h(n) =
ym (n)
-2
-1
L=4
y2(n)
-1
6
6
10
M-1=2
L=4
y3(n)
m=1
ADD
to
next
block
-2
M-1=2
4
-3
ADD
to
next
block
+ ...
-2
-1
M-1=2
L=4
37 / 58
Overlap-Add Method
Input signal:
10
-3
10
m=1
m=1
Overlap-Add Method
x(n)
38 / 58
Overlap-Add Method
Overlap-Add Method
1
1. Break the input signal x(n) into non-overlapping blocks xm (n) of length L.
-3
-2
-1
10
zeros
zeros
Output signal:
4.1
4.2
4.3
4.4
zeros
Add
points
5. Form y (n) by overlapping the last M 1 samples of ym (n) with the first
M 1 samples of ym+1 (n) and adding the result.
Add
points
39 / 58
40 / 58
Overlap-Add Method
Overlap-Add Method
If you DO NOT overlap and add, but only append the output blocks
ym (n) for m = 1, 2, . . ., then you will not get the true y (n) sequence.
points
Add
points
41 / 58
Overlap-Add Method
42 / 58
Overlap-Save Method
Overlap-Save Method
zeros
Overlap-Save Method
Overlap-[Discard] Method
zeros
zeros
43 / 58
44 / 58
Overlap-Save Method
Overlap-Save Method
Overlap-Save Method
yL(n) linear
convolution
2
result
xC (n) =
-6
-5
-4
-3
-2
-1
-7
xL (n lN) ,
| {z }
-6
-5
-4
-3
...
-2
-1
circular
convolution
result
n = 0, 1, . . . , N 1
yL(n-2N)
+
+
overlap since
N < L+M-1
Time-Domain Aliasing:
-7
yL(n-N)
yL(n)
...
yL(n+N)
yL(n+2N)
l= support=M + N 1
-7
-6
-5
-4
-3
corruption from
previous repetitions
2
1
-2
-1
45 / 58
Overlap-Save Method
yC ,m (n)
aliasing corruption
yL,m (n)
n = 0, 1, . . . , M 2
n = M 1, M, . . . , N 1
Overlap-Save Method
46 / 58
Overlap-Save Method
I
47 / 58
48 / 58
Overlap-Save Method
Overlap-Save Method
x1 (n) = {0,
|
0, . . .
{z
M 1 zeros
zeros
point
overlap
..
.
point
overlap
The last M 1 points from the previous input block must be saved
for use in the current input block.
Dr. Deepa Kundur (University of Toronto)
49 / 58
Overlap-Save Method
50 / 58
Overlap-Save Method
N = L + M 1.
Let xm (n) have support n = 0, 1, . . . , N 1.
Let h(n) have support n = 0, 1, . . . , M 1.
We zero pad h(n) to have support n = 0, 1, . . . , N 1.
1. Take N-DFT of xm (n) to give Xm (k), k = 0, 1, . . . , N 1.
2. Take N-DFT of h(n) to give H(k), k = 0, 1, . . . , N 1.
51 / 58
52 / 58
Overlap-Save Method
Overlap-Save Method
-6
-5
-4
-3
-2
-1
yL(n-N)
yL(n)
...
-7
yL(n+N)
yL(n+2N)
-7
-6
-5
-4
-3
...
+
1
yL(n-2N)
-2
-1
yC ,m (n) =
yC (n)
circular
convolution
result
-7
-6
-5
-4
-3
corruption from
previous repetitions
aliasing n = 0, 1, . . . , M 2
yL,m (n) n = M 1, M, . . . , N 1
-2
-1
53 / 58
Overlap-Save Method
= {y1 (0),
|
y1 (1), . . .
{z
= {y2 (0),
|
y2 (1), . . .
{z
= {y3 (0),
|
y3 (1), . . .
{z
54 / 58
Overlap-Save Method
y2 (n)
Discard
y3 (n)
points
Discard
points
Discard
points
55 / 58
56 / 58
Overlap-Save Method
Overlap-Save Method
Overlap-Save Method
Overlap-Save Method
2. Break the padded input signal into overlapping blocks xm (n) of length
N = L + M 1 where the overlap length is M 1.
zeros
point
overlap
point
overlap
Discard
points
Discard
points
Discard
points
57 / 58
58 / 58