Is it possible to flip a signal's spectrum around DC? I have a simple spectrum that I made up (MATLAB code):

spectrum =   [-1+4i 0+3i 1+2i 2+1i 3+0i 4-1i 5-2i 6-3i 7-4i 8-5i]
timeDomain = ifft(spectrum);

I looked on this website (http://www.dsprelated.com/showarticle/51.php) and the given proof states this can be done in 3 ways:

  1. Invert the Q channel (14)
  2. Swap the I and Q channels (15)
  3. Invert the I channel (16)

I tried those 3 ways on my signal:

1) Invert the Q channel

negQtd   = real(timeDomain) - 1j * imag(timeDomain);
negQSpec = fft(negQtd)


[-1-4i 8+5i 7+4i 6+3i 5+2i 4+1i 3+0i 2-1i 1-2i 0-3i]

2) Swap the I and Q channels

swapTD   = imag(timeDomain) + 1j * real(timeDomain);
swapSpec = fft(swapTD)


[4-1i -5+8i -4+7i -3+6i -2+5i -1+4i -0+3i 1+2i 2+1i 3+0i]

3) Invert the I channel

negItd   = -1 * real(timeDomain) + 1j * imag(timeDomain);
negISpec = fft(negItd)


[1+4i -8-5i -7-4i -6-3i -5-2i -4-1i -3-0i -2+1i -1+2i -0+3i]

Each of these does flip the spectrum of the signal, but it also modifies the spectrum:

1) Inverting Time Domain Q channel also negates/inverts the Frequency Domain Imaginary part.

2) Swapping the I and Q channels also swaps the Frequency Domain Real and Imaginary parts.

3) Inverting the Time Domain I channel also negates/inverts the Frequency domain Real part.

Is there some other way to simply flip the spectrum around DC or should I try a two step process?

  • $\begingroup$ One way to do this is time reversal. Matlab (just scale ifft so you dont need to worry about writing code for circular time reversal): length(spectrum)*ifft(timeDomain) $\endgroup$ Aug 5 '15 at 5:53
  • $\begingroup$ Perhaps the material at: dsprelated.com/showarticle/37.php might be of some help to you. $\endgroup$ Aug 5 '15 at 10:27

The article Handling Spectral Inversion in Baseband Processing that you refer to in your question is not about simple inversion of the frequency axis, but it is about inversion of the frequency axis and conjugation in the frequency domain. This is necessary because due to different mixing conventions in several conversion stages, the upper and lower side-bands can be exchanged, and the two side-bands exhibit conjugate symmetry, because the transmitted signal is real-valued. So one side-band can be obtained from the other by inverting the frequency axis and by additional complex conjugation (in the frequency domain).

This process of inversion and conjugation in the frequency domain corresponds to complex conjugation of the complex baseband signal in the time domain, which is equivalent to simply inverting the $Q$ component. Since a phase shift of $180$ degrees is irrelevant, one can equivalently invert the $I$ component. A phase shift of $90$ degrees corresponds to a multiplication with $j$ in the time domain, and if this phase shift can be tolerated, you get the additional option of swapping the $I$ and $Q$ channels.

If you want pure inversion of the frequency axis without conjugation, then you indeed need to invert the time axis of the corresponding time domain signal (as pointed out in a comment by @curiousStudent). Luckily this is usually not needed in practice because this can't be done easily in a real-time system.

As a final note, all three options in your question do flip the magnitudes of the spectra around DC, it is just the phases that behave differently in all three cases.

  • $\begingroup$ "Luckily this is usually not needed in practice because this can't be done easily in a real-time system." :-) $\endgroup$ Dec 23 '19 at 12:50

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.