Created
January 13, 2015 12:06
-
-
Save jorge-lavin/c46a40742ea706ab5eba to your computer and use it in GitHub Desktop.
Reverse List for FFT
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# As stated in the SciPy documentation for fft http://docs.scipy.org/doc/scipy-0.14.0/reference/generated/scipy.fftpack.fft.html | |
# Note that y(-j) = y(n-j).conjugate(). | |
# This is a possible implementation of that equality. | |
import numpy as np | |
from scipy.fftpack import fft | |
x = np.linspace(-np.pi, np.pi, 201) | |
y = fft(x) | |
list_index = range(len(y)) | |
[l[i].conjugate() for i in reversed(list_index)] | |
# Now its spectrum can be computed |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment