0
$\begingroup$

I am very new to signal processing and want to learn the correct way of zero padding for 'n' even and odd input signals.

For example,

$N=6\;\&\;M=32$

$x(n)=[a, b, c, d, e, f]\;\;\;n=0,1,\dots,N-1$

$x_{zeros}(m)=[a, b, c, d, e, f, zeros(M-N)]\;\;\;m=0,1,\dots,M-1$

-or-

$x_{zeros}(m)=[left\;zeros\dots a, b, c, d, e, f,\dots right\;zeros]\;\;\;m=0,1,\dots,M-1$

-or-

$x_{zeros}(m)=[a, b, c,\dots zeros\;in\;the\;middle\dots d, e, f]\;\;\;m=0,1,\dots,M-1$

What to consider when the input is $\mathrm{Real}$ or $\mathrm{Complex}$ of even and odd lengths?

$\endgroup$
  • $\begingroup$ you might end up putting the M-N zeros in between c and d. $\endgroup$ – robert bristow-johnson Jan 20 '20 at 3:23
2
$\begingroup$

Zero padding changes the bin size of the DFT resulting a finer frequency resolution. It is done by appending zeros to the end of the signal because we are only artificially increasing the length to decrease the bin size, $\frac{2\pi k}{N}$. An $N$ point DFT is just evaluating the DTFT on certain frequencies. If you were to append some zeros to the front of the signal then you are doing a time shift, and a shift in time domain is modulation in the frequency domain: $x[n-k]=X(\omega)e^{-j\omega k}$.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.