# Overlap-add method

Overlap-add method

The overlap-add method (OA, OLA) is an efficient way to evaluate the discrete convolution between a very long signal $x \left[n\right]$ with a finite impulse response (FIR) filter $h \left[n\right]$:

:

where h [m] =0 for m outside the region [1, M] .

The concept is to divide the problem into multiple convolutions of h [n] with short segmentsof $x \left[n\right]$:

:

where L is an arbitrary segment length. Then:

:$x \left[n\right] = sum_\left\{k\right\} x_k \left[n-kL\right] ,,$

and y [n] can be written as a sum of short convolutions:

:

where $y_k \left[n\right] stackrel\left\{mathrm\left\{def\left\{=\right\} x_k \left[n\right] *h \left[n\right] ,$ is zero outside the region [1,L+M-1] . And for any parameter $Nge L+M-1,,$ it is equivalent to the $N,$-point circular convolution of $x_k \left[n\right] ,$ with $h \left[n\right] ,$ in the region [1,N] .

The advantage is that the circular convolution can be computed very efficiently as follows, according to the circular convolution theorem:

where FFT and IFFT refer to the fast Fourier transform and inversefast Fourier transform, respectively, evaluated over $N$ discretepoints.

The algorithm

Fig. 1 sketches the idea of the overlap-add method. Thesignal $x \left[n\right]$ is first partitioned into non-overlapping sequences,then the discrete Fourier transforms of the sequences $y_k \left[n\right]$are evaluated by multiplying the FFT of $x_k \left[n\right]$ with the FFT of$h \left[n\right]$. After recovering of $y_k \left[n\right]$ by inverse FFT, the resultingoutput signal is reconstructed by overlapping and adding the $y_k \left[n\right]$as shown in the figure. The overlap arises from the fact that a linearconvolution is always longer than the original sequences. Note that$L$ should be chosen to have $N$ a power of 2 which makesthe FFT computation efficient. A pseudocode of the algorithm is thefollowing:

Algorithm 1 ("OA for linear convolution") Evaluate the best value of N and L H = FFT(h,N) ("zero-padded FFT") i = 1 while i <= Nx il = min(i+L-1,Nx) yt = IFFT( FFT(x(i:il),N) * H, N) k = min(i+N-1,Nx) y(i:k) = y(i:k) + yt ("add the overlapped output blocks") i = i+L end

Circular convolution with the overlap-add method

When sequence x [n] is periodic, and Nx is the period, then y [n] is also periodic, with the same period. To compute one period of y [n] , Algorithm 1 can first be used to convolve h [n] with just one period of x [n] . In the region M ≤ n ≤ Nx, the resultant y [n] sequence is correct. And if the next M-1 values are added to the first M-1 values, then the region 1 ≤ n ≤ Nx will represent the desired convolution. The modified pseudocode is:

Algorithm 2 ("OA for circular convolution") Evaluate Algorithm 1 y(1:M-1) = y(1:M-1) + y(Nx+1:Nx+M-1) y = y(1:Nx) end

Cost of the overlap-add method

The cost of the convolution can be associated to the number of complexmultiplications involved in the operation. The major computationaleffort is due to the FFT operation, which for a radix-2 algorithmapplied to a signal of length $N$ roughly calls for $C=frac\left\{N\right\}\left\{2\right\}log_2 N$complex multiplications. It turns out that the number of complex multiplicationsof the overlap-add method are:

:$C_\left\{OA\right\}=leftlceil frac\left\{N_x\right\}\left\{N-M+1\right\} ight ceilNleft\left(log_2 N+1 ight\right),$

$C_\left\{OA\right\}$ accounts for the FFT+filter multiplication+IFFT operation.

The additional cost of the $M_L$ sections involved in the circularversion of the overlap-add method is usually very small and can beneglected for the sake of simplicity. The best value of $N$can be found by numerical search of the minimum of $C_\left\{OA\right\}left\left(N ight\right)=C_\left\{OA\right\}left\left(2^m ight\right)$by spanning the integer $m$ in the range $log_2left\left(M ight\right)le mlelog_2 left\left(N_x ight\right)$.Being $N$ a power of two, the FFTs of the overlap-add methodare computed efficiently. Once evaluated the value of $N$ itturns out that the optimal partitioning of $x \left[n\right]$ has $L=N-M+1$.For comparison, the cost of the standard circular convolution of $x \left[n\right]$and $h \left[n\right]$ is:

:$C_S=N_xleft\left(log_2 N_x+1 ight\right),$

Hence the cost of the overlap-add method scales almost as $Oleft\left(N_xlog_2 N ight\right)$while the cost of the standard circular convolution method is almost$Oleft\left(N_xlog_2 N_x ight\right)$. However such functions accountsonly for the cost of the complex multiplications, regardless of theother operations involved in the algorithm. A direct measure of thecomputational time required by the algorithms is of much interest.Fig. 2 shows the ratio of the measured time to evaluatea standard circular convolution using EquationNote|Eq.1 withthe time elapsed by the same convolution using the overlap-add methodin the form of Alg 2, vs. the sequence and the filter length. Both algorithms have been implemented under Matlab. Thebold line represent the boundary of the region where the overlap-addmethod is faster (ratio>1) than the standard circular convolution.Note that the overlap-add method in the tested cases can be threetimes faster than the standard method.

frame|none|Figure 2: Ratio between the time required by ">EquationNote|Eq.1 and the time required by the overlap-add Alg. 2 to evaluatea complex circular convolution, vs the sequence length $N_x$ andthe filter length $M$.

See also

*Overlap-save method
*Weigthed Overlap Add (WOLA), an efficient filterbank method which uses FFT, that can be used to split a continuous signal stream into multiple equally-spaced subbands signal streams.

References

*Cite book
author=Rabiner, Lawrence R.; Gold, Bernard
authorlink=
coauthors=
title=Theory and application of digital signal processing
date=1975
publisher=Prentice-Hall
location=Englewood Cliffs, N.J.
isbn=0-13-914101-4
pages=pp 63-67

*Cite book
author=Oppenheim, Alan V.; Schafer, Ronald W.
authorlink=
coauthors=
title=Digital signal processing
date=1975
publisher=Prentice-Hall
location=Englewood Cliffs, N.J.
isbn=0-13-214635-5
pages=

*Cite book
author=Hayes, M. Horace
authorlink=
coauthors=
title = Digital Signal Processing
series = Schaum's Outline Series
date=1999
publisher=McGraw Hill
location=New York
isbn=0-07-027389-8
pages=

External links

* [http://www.mathworks.com Matlab] for the implementation of the overlap-add method through the function fftfilt.m.

Wikimedia Foundation. 2010.

### Look at other dictionaries:

• Overlap–add method — The overlap–add method (OA, OLA) is an efficient way to evaluate the discrete convolution of a very long signal x[n] with a finite impulse response (FIR) filter h[n]: where h[m]=0 for m outside the region [1, M]. The concept is to divide the… …   Wikipedia

• Overlap–save method — Overlap–save is the traditional name for an efficient way to evaluate the discrete convolution between a very long signal x[n] and a finite impulse response (FIR) filter h[n] …   Wikipedia

• Overlap-save method — Overlap save is the traditional name for an efficient way to evaluate the discrete convolution between a very long signal x [n] with a finite impulse response (FIR) filter h [n] ::egin{align}y [n] = x [n] * h [n] stackrel{mathrm{def{=} sum {m=… …   Wikipedia

• Overlap — may mean one of: In music theory, overlap is a synonym for reinterpretation of a chord at the boundary of two musical phrases. In railway signalling, an Overlap (railway signalling) is the length of track beyond a stop signal that is proved to be …   Wikipedia

• Method of matched asymptotic expansions — In mathematics, particularly in solving singularly perturbed differential equations, the method of matched asymptotic expansions is a common approach to finding an accurate approximation to a problem s solution. Contents 1 Method overview 2… …   Wikipedia

• List of numerical analysis topics — This is a list of numerical analysis topics, by Wikipedia page. Contents 1 General 2 Error 3 Elementary and special functions 4 Numerical linear algebra …   Wikipedia

• List of mathematics articles (O) — NOTOC O O minimal theory O Nan group O(n) Obelus Oberwolfach Prize Object of the mind Object theory Oblate spheroid Oblate spheroidal coordinates Oblique projection Oblique reflection Observability Observability Gramian Observable subgroup… …   Wikipedia

• Audio timescale-pitch modification — Time stretching is the process of changing the speed or duration of an audio signal without affecting its pitch.Pitch scaling or pitch shifting is the reverse: the process of changing the pitch without affecting the speed. There are also more… …   Wikipedia

• Time-compressed speech — is a technique used, often in advertising, to make recorded speech contain more words in a given time, yet still be understandable. Contents 1 History 2 Methods 3 Advantages 4 Disadvantages …   Wikipedia

• PSOLA — In digital signal processing techniques PSOLA stands for Pitch Synchronous Overlap Add Method.It is used in speech synthesis.ee alsoAudio timescale pitch modification.External links* [http://www.fon.hum.uva.nl/praat/manual/PSOLA.html PSOLA… …   Wikipedia

### Share the article and excerpts

##### Direct link
Do a right-click on the link above
and select “Copy Link”