Linear convolution and circular convolution are closely related mathematical operations used in signal processing. While they have distinct definitions and applications, they can be related under certain conditions.
If we consider a linear convolution of two signals, x[n]
and h[n]
, and zero-pad both signals to a length N
that is greater than or equal to the sum of their individual lengths, the resulting circular convolution of the zero-padded signals will be identical to the original linear convolution.
Mathematically:
- Let
x_zp[n]
andh_zp[n]
be the zero-padded versions ofx[n]
andh[n]
, respectively. - If
N ≥ length(x[n]) + length(h[n])
, then:x[n] * h[n] = x_zp[n] * h_zp[n] mod N
- Zero Padding: By adding zeros to the end of the signals, we effectively extend their length. This ensures that when we perform circular convolution, the overlapping portions of the signals do not "wrap around" and interfere with each other.
- Modulus Operation: The
mod N
operation in circular convolution ensures that the indices stay within the range0
toN-1
. This is crucial for preventing aliasing and ensuring that the result is equivalent to linear convolution.
- DFT-Based Convolution: The DFT can be used to efficiently compute circular convolution. By zero-padding the signals and using the DFT, we can effectively perform linear convolution using the frequency domain.
- Filter Design: Circular convolution is often used in the design of finite impulse response (FIR) filters. By understanding the relationship between linear and circular convolution, we can design filters that meet specific requirements.
Linear convolved sequence using built-in function:
1 3 6 9 7 4
Circular convolution result using FFT:
1 3 6 9 7 4