Numerical Recipes Forum  

Go Back   Numerical Recipes Forum > Numerical Recipes Third Edition Forum > Methods: All Chapters in NR3

Reply
 
Thread Tools Rate Thread Display Modes
  #1  
Old 10-27-2010, 07:04 AM
florian101 florian101 is offline
Registered User
 
Join Date: Dec 2009
Posts: 3
indexing in rlft3.c

Hi everyone
I am not very familiar with nr but I had some problems with the fftw library recently therefore I thought I implement the fft of nr and compare it to the fftw library output... the function I suppose I have to use is

rlft3.c

however the manual totally confused me (page 519 and following) on how I actually have to provide the input... I would like to perform a 3D complex to real transform.
The first problem I have is that data[], which is one of the input arrays needs the values store with index 1 to nn1 and 1 to nn2 and 1 to nn3. Since C is indexing arrays from 0 to n-1 I don't understand that at all???
I would really appreciate if anybody could give me a quick example on how I have to provide the input

I have a function x[kx][ky][kz] with real and complex values... and I have to distribute this function between data[] and speq[]...
thanks for any help
and best regards
fl
Reply With Quote
  #2  
Old 10-27-2010, 09:53 PM
florian101 florian101 is offline
Registered User
 
Join Date: Dec 2009
Posts: 3
I found fourn.c

Hi
I think I was wrong, the program I have to use for a complex-to-real transform is fourn.c... Am I right that the input in this case is alternating between real and complex

x[0] = real1
x[1] = im1
x[2] = real2
x[3] = im2
...

best regards
florian
Reply With Quote
Reply

Thread Tools
Display Modes Rate This Thread
Rate This Thread:

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

Forum Jump


All times are GMT -5. The time now is 08:48 AM.


Powered by vBulletin® Version 3.8.6
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.