Bsoft 2.1.4
Bernard's software package
fft_tool.h File Reference
#include "rwimg.h"

Functions

int fft_1D_forward (Bimage *p)
 
int fft_1D_backward (Bimage *p)
 
int fft_2D_forward (Bimage *p)
 
int fft_2D_backward (Bimage *p)
 
int farfarig (Bimage *p, int ifl)
 With MIXRIG and SCRAMRIG fast Fourier transform a 2D image. More...
 
int mixrig (Bimage *p, int ifl)
 With FARFARIG and SCRAMRIG fast Fourier transform a 2D image. More...
 
int scramrig (Bimage *p)
 With FARFARIG and MIXRIG fast Fourier transform a 2D image. More...
 
int abtori (Bimage *p)
 Changes direct Fourier transform representation. More...
 
int ritoab (Bimage *p)
 Changes direct Fourier transform representation. More...
 
int zeroes (Bimage *p)
 
int rephase_orig (Bimage *p)
 Shifting the origin by half the complex image size. More...
 

Detailed Description

Author
P.L. Bellon, F. Cantele and S. Lanzavecchia Dip. Chimica Strutturale e Stereochimica Inorganica Via Venezian 21, 20133 Milano, Italy
Date
Created: 7 04 2003
Modified: 07 07 2005

Function Documentation

◆ abtori()

int abtori ( Bimage p)

Changes direct Fourier transform representation.

Parameters
*pimage
Returns
int 0
This subroutine changes the way in which a direct transform 
is represented; from the conventional form Txryr, Txiyr,
Txryi, Txiyi (here called a,b,c,d ) it produces a new 
representation in which real and imaginary parts
are calculated, for the frequencies of the type f(Kx,Ky)
and f(Kx,-Ky) .      
Coefficients are addressed by pointers in this way:
pp1 --> real f(Kx,Ky)       pp2 --> imaginary f(Kx,Ky)
pp3 --> imaginary f(Kx,-Ky) pp4 --> real f(Kx,-Ky)

◆ farfarig()

int farfarig ( Bimage p,
int  ifl 
)

With MIXRIG and SCRAMRIG fast Fourier transform a 2D image.

Parameters
*pimage
ifldirection of transformation (-1 = direct / 1 = inverse)
Returns
int 0

◆ fft_1D_backward()

int fft_1D_backward ( Bimage p)

◆ fft_1D_forward()

int fft_1D_forward ( Bimage p)

◆ fft_2D_backward()

int fft_2D_backward ( Bimage p)

◆ fft_2D_forward()

int fft_2D_forward ( Bimage p)

◆ mixrig()

int mixrig ( Bimage p,
int  ifl 
)

With FARFARIG and SCRAMRIG fast Fourier transform a 2D image.

Parameters
*pimage
ifldirection of transformation (0 = direct / 1 = inverse)
Returns
int 0

◆ rephase_orig()

int rephase_orig ( Bimage p)

Shifting the origin by half the complex image size.

Parameters
*pimage
Returns
int 0
Coefficients are addressed by pointers in this way:
pp1 --> real f(Kx,Ky)      pp2 --> imaginary f(Kx,-Ky)
pp3 --> imaginary f(Kx,Ky) pp4 --> real f(Kx,-Ky)

◆ ritoab()

int ritoab ( Bimage p)

Changes direct Fourier transform representation.

Parameters
pimage
Returns
int 0
This subroutine changes the representation of the
direct transform: from real & imaginary parts to the 
conventional one; here a,b,c,d ,pointed by pp1,pp2,
pp3 and pp4, have the following meaning:
a=TXrYr    b=TXiYi    c=TXrYi    d=TXiYr
where TX(Y)r(i) means real (imaginary) part of the coefficients 
obtained by a direct transform computed along the X (Y) direction.
A quartet a,b,c,d is defined for each point of the reciprocal
space in the first quadrant (i.e. points with positive Kx & Ky
coordinates.     

◆ scramrig()

int scramrig ( Bimage p)

With FARFARIG and MIXRIG fast Fourier transform a 2D image.

Parameters
*pimage
Returns
int 0
Rearrange each row in the complex image.

◆ zeroes()

int zeroes ( Bimage p)
Parameters
*pimage
Returns
int 0