# Inverse fourier transform of Hermitian function, getting an imaginary part

in the cartoon below

It shows that if we take the inverse Fourier transform of a Hermitian function, real part even and imaginary part is odd we should get a purely real function in the time domain.

I tried to replicate this by taking a frequency response I have, zero padding it making it even for the real and odd in the imaginary. Shown below Although my ifft in Matlab I still have a significant imaginary component, the real is shown left and imaginary on the right. I also wrote my own script for DFT/IDFT and tested it on a sine function to make sure I get the same as Matlab. Maybe I have missed something?

• Are you using the whole input vector, or are you specifying an fft length when calling fft? Also, a simple one-sample shift will lead to a sinusoidal modulation after dft; make sure you're using the right ,fftshiftifftshift – Marcus Müller Aug 18 '16 at 11:32
• Maybe it's a numerical/rounding issue? Note that your imaginary part is 1/100th scale of the real part. – Atul Ingle Aug 18 '16 at 15:02
• I solved my issue, I had to be very careful in replicating the signal, i wrote it all on paper so i could visually see everything... Should I close the question – JS60 Aug 22 '16 at 10:29