Python Forum
correctly indexing ffts, and plotting the results in imshow
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
correctly indexing ffts, and plotting the results in imshow
#1
I am confused about the correct ordering of indices after taking an fft down the columns of a matrix.

If I have 2D data in the matrix psi_hat_kxt and I take its FFT down columns and FFT-shift the result, np.fft.fftshift(np.fft.fft(psi_hat_kxt, axis=0)),
where are the negative frequencies located? Shouldn't they be in the top half of the resulting array? If so, when I plot the result (squared element-wise to get real data) using imshow, is there an implicit up-down flip somewhere?

The full context is in my stackoverflow question here.
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  matplotlib animate imshow kiyoshi7 0 5,269 Jul-14-2018, 09:22 PM
Last Post: kiyoshi7

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020