Fast Fourier Transform module - wrapper for FFTPACK

The following functions are defined

fft(v)      - return the complex FFT of v
fft_inv(v)  - return the complex inverse FFT of

rfft(v)     - return the real FFT of v
rfft_inv(v) - return the real inverse FFT of v

These functions call methods of the following objects default_fft
and default_rfft, which are instances of FFT_CLASS and RFFT_CLASS
classes, respectively. Initialization for a particular length fft is
performed when a different size sequence v is supplied. If taking FFTs
of sequences with differing sizes, instantiate separate FFT_CLASS
objects for each size. The transforms are not normalized. To obtain a
normalized transform the output must be divided by len(v).

The algorithms used are:

N=len(v)

--> forward complex transform

for j=0,...,N-1

c[j]=the sum from k=0,...,N-1 of

v[k]*exp(-i*j*k*2*pi/N)

where i=sqrt(-1)

--> inverse complex transform

for j=0,...,N-1

c[j]=the sum from k=0,...,N-1 of

v[k]*exp(i*j*k*2*pi/N)

where i=sqrt(-1)

--> forward real transform

r = the sum from n=0 to n=N-1 of v[n]

if N is even set L = N/2-1   , if N is odd set L = (N-1)/2

then for m = 1,...,L

r[2*m-1] = the sum from n = 0 to n = N-1 of

v[n]*cos(m*n*2*pi/N)

r[2*m] = the sum from n = 1 to n = N-1 of

-v[n]*sin(m*n*2*pi/N)

if N is even

r[N-1] = the sum from n = 0 to n = N-1 of

(-1)**(n)*v[n]

--> inverse real transform

for N even and for n = 0,...,N-1

r[n] = v+(-1)**(N-1)*v[N-1]

plus the sum from m=1 to m=N/2-1 of

2.*v[2*m-1]*cos(m*n*2*pi/N)

-2.*v[2*m  ]*sin(m*n*2*pi/N)

for N odd and for n = 0,...,N-1

r[n] = v plus the sum from m=1 to m=(N-1)/2 of

2.*v[2*m-1]*cos(m*n*2*pi/N)

-2.*v[2*m  ]*sin(m*n*2*pi/N)

# This file was automatically generated by SWIG (http://www.swig.org).
# Version 4.0.2
#
# Do not make changes to this file unless you know what you are doing--modify
# the SWIG interface file instead.

Classes

builtins.object
CDSVector_DComplex
FFT_FLOATTYPE
RFFT_FLOATTYPE

 class CDSVector_DComplex(builtins.object) CDSVector_DComplex(*args) Methods defined here: __add__(self, *args) -> 'CDSVector< CDS::Complex< double > >' __getitem__(self, *args, **kwargs) __getslice__(self, *args, **kwargs) -> 'CDSVector< CDS::Complex< double > >' __iadd__(self, *args) -> 'CDSVector< CDS::Complex< double > >' __imul__(self, *args, **kwargs) -> 'CDSVector< CDS::Complex< double > >' __init__(self, *args)Initialize self.  See help(type(self)) for accurate signature. __isub__(self, *args) -> 'CDSVector< CDS::Complex< double > >' __itruediv__(self, *args, **kwargs) -> 'CDSVector< CDS::Complex< double > >' __len__(self, *args, **kwargs) -> 'int' __mul__(self, *args) -> 'CDSVector< CDS::Complex< double > >' __neg__(self, *args, **kwargs) -> 'CDSVector< CDS::Complex< double > >' __pow__(self, *args, **kwargs) -> 'CDSVector< CDS::Complex< double > >' __radd__(self, *args, **kwargs) -> 'CDSVector< CDS::Complex< double > >' __repr__ = _swig_repr(self) __rmul__(self, *args, **kwargs) -> 'CDSVector< CDS::Complex< double > >' __rsub__(self, *args, **kwargs) -> 'CDSVector< CDS::Complex< double > >' __rtruediv__(self, *args, **kwargs) -> 'CDSVector< CDS::Complex< double > >' __setitem__(self, *args, **kwargs) -> 'void' __str__(self, *args, **kwargs) -> 'String'Return str(self). __sub__(self, *args) -> 'CDSVector< CDS::Complex< double > >' __truediv__(self, *args) -> 'CDSVector< CDS::Complex< double > >' fromList(s, l) get(self, *args, **kwargs) -> 'CDS::Complex< double >' help(self, *args, **kwargs) -> 'String' resize(self, *args, **kwargs) -> 'void' scale(self, *args, **kwargs) -> 'void' set(self, *args, **kwargs) -> 'void' Static methods defined here: __swig_destroy__ = delete_CDSVector_DComplex(...) Data descriptors defined here: __dict__   dictionary for instance variables (if defined) __weakref__   list of weak references to the object (if defined) thisown   The membership flag

 FFT = class FFT_FLOATTYPE(builtins.object) FFT(*args, **kwargs) Methods defined here: __init__(self, *args, **kwargs)Initialize self.  See help(type(self)) for accurate signature. __repr__ = _swig_repr(self) fft(self, *args, **kwargs) -> 'CDSVector< CDS::Complex< double > >' fft_inv(self, *args, **kwargs) -> 'CDSVector< CDS::Complex< double > >' resize(self, *args, **kwargs) -> 'void' Static methods defined here: __swig_destroy__ = delete_FFT_FLOATTYPE(...) Data descriptors defined here: __dict__   dictionary for instance variables (if defined) __weakref__   list of weak references to the object (if defined) thisown   The membership flag

 class FFT_FLOATTYPE(builtins.object) FFT_FLOATTYPE(*args, **kwargs) Methods defined here: __init__(self, *args, **kwargs)Initialize self.  See help(type(self)) for accurate signature. __repr__ = _swig_repr(self) fft(self, *args, **kwargs) -> 'CDSVector< CDS::Complex< double > >' fft_inv(self, *args, **kwargs) -> 'CDSVector< CDS::Complex< double > >' resize(self, *args, **kwargs) -> 'void' Static methods defined here: __swig_destroy__ = delete_FFT_FLOATTYPE(...) Data descriptors defined here: __dict__   dictionary for instance variables (if defined) __weakref__   list of weak references to the object (if defined) thisown   The membership flag

 RFFT = class RFFT_FLOATTYPE(builtins.object) RFFT(*args, **kwargs) Methods defined here: __init__(self, *args, **kwargs)Initialize self.  See help(type(self)) for accurate signature. __repr__ = _swig_repr(self) fft(self, *args, **kwargs) -> 'CDSVector< double >' fft_inv(self, *args, **kwargs) -> 'CDSVector< double >' resize(self, *args, **kwargs) -> 'void' Static methods defined here: __swig_destroy__ = delete_RFFT_FLOATTYPE(...) Data descriptors defined here: __dict__   dictionary for instance variables (if defined) __weakref__   list of weak references to the object (if defined) thisown   The membership flag

 class RFFT_FLOATTYPE(builtins.object) RFFT_FLOATTYPE(*args, **kwargs) Methods defined here: __init__(self, *args, **kwargs)Initialize self.  See help(type(self)) for accurate signature. __repr__ = _swig_repr(self) fft(self, *args, **kwargs) -> 'CDSVector< double >' fft_inv(self, *args, **kwargs) -> 'CDSVector< double >' resize(self, *args, **kwargs) -> 'void' Static methods defined here: __swig_destroy__ = delete_RFFT_FLOATTYPE(...) Data descriptors defined here: __dict__   dictionary for instance variables (if defined) __weakref__   list of weak references to the object (if defined) thisown   The membership flag

 Functions cat(*args, **kwargs) -> 'CDSVector< CDS::Complex< double > >' cat3(*args, **kwargs) -> 'CDSVector< CDS::Complex< double > >' cat4(*args, **kwargs) -> 'CDSVector< CDS::Complex< double > >' fft(*args, **kwargs) -> 'CDSVector< CDS::Complex< double > >' method of FFT_FLOATTYPE instance fft_inv(*args, **kwargs) -> 'CDSVector< CDS::Complex< double > >' method of FFT_FLOATTYPE instance max(*args, **kwargs) -> 'CDS::Complex< double >' min(*args, **kwargs) -> 'CDS::Complex< double >' omp_get_max_threads() -> 'int' omp_get_thread_num() -> 'int' pyXplorHelp(*args) -> 'String' rfft = fft(*args, **kwargs) -> 'CDSVector< double >' method of RFFT_FLOATTYPE instance rfft_inv = fft_inv(*args, **kwargs) -> 'CDSVector< double >' method of RFFT_FLOATTYPE instance sum(*args, **kwargs) -> 'CDS::Complex< double >'

 Data FALSE = 0 PI = 3.141592653589793 TRUE = 1 __sthead_hh__ = 1 default_fft = *' at 0x7f9b6f00e0f0> > default_rfft = *' at 0x7f9b6f00e480> >