CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > General Forums > Main CFD Forum

Complex FFT for real data

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   November 12, 2011, 15:53
Default Complex FFT for real data
  #1
Senior Member
 
Hisham's Avatar
 
Hisham Elsafti
Join Date: Apr 2011
Location: Braunschweig, Germany
Posts: 257
Blog Entries: 10
Rep Power: 17
Hisham is on a distinguished road
Dear All,

I use a code based on Numerical recipes implementation of complex FFT. I work with real data. In my work, I do not need to use the FFT heavily, and therefore, I do not wish to invest a lot of time for increasing efficiency of solution or implementing other code.

To do 1-D forward FT of real data, I add zeros to the imaginary components and add zeros to both real and imaginary components until the vector length is N=2^n. After the transform, I consider data from 0 to N/2.

My problem is the IFFT. I pad zeros until N = 2^n and make sure that values are conjugate mirrored about the vector center. That is: Value[N-n-1] = conj Value[n].

After I do the IFFT, I expect the result to be only real values (img components should be zeros more or less). Nevertheless, this is not what happens. The imaginary components have values as if it were a normal complex IFFT.

Any suggestions are appreciated.

Best regards,
Hisham
Hisham is offline   Reply With Quote

Reply

Tags
fft, ifft


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
export data at nodes Meenu FLUENT 1 December 30, 2011 02:24
Problem in running ICEM grid in Openfoam Tarak OpenFOAM 6 September 9, 2011 18:51
Complex .stl data for volume meshing in ICEM CFD Nils_H ANSYS Meshing & Geometry 5 September 2, 2011 09:39
How to update polyPatchbs localPoints liu OpenFOAM Running, Solving & CFD 6 December 30, 2005 18:27
fft of unsteady solution K S Chang Main CFD Forum 6 January 15, 2004 07:42


All times are GMT -4. The time now is 12:22.