1FFT(3)                User Contributed Perl Documentation               FFT(3)
2
3
4

NAME

6       PDL::FFT - FFTs for PDL
7

DESCRIPTION

9       FFTs for PDL.  These work for arrays of any dimension, although ones
10       with small prime factors are likely to be the quickest.
11
12       For historical reasons, these routines work in-place and do not recog‐
13       nize the in-place flag.  That should be fixed.
14

SYNOPSIS

16               use PDL::FFT qw/:Func/;
17
18               fft($real, $imag);
19               ifft($real, $imag);
20               realfft($real);
21               realifft($real);
22
23               fftnd($real,$imag);
24               ifftnd($real,$imag);
25
26               $kernel = kernctr($image,$smallk);
27               fftconvolve($image,$kernel);
28

ALTERNATIVE FFT PACKAGES

30       Various other modules - such as PDL::FFTW and PDL::Slatec - contain FFT
31       routines.  However, unlike PDL::FFT, these modules are optional, and so
32       may not be installed.
33

FUNCTIONS

35       fft
36
37         Signature: ([o,nc]real(n); [o,nc]imag(n))
38
39       Complex FFT of the "real" and "imag" arrays [inplace]
40
41       ifft
42
43         Signature: ([o,nc]real(n); [o,nc]imag(n))
44
45       Complex Inverse FFT of the "real" and "imag" arrays [inplace]
46
47       realfft()
48
49       One-dimensional FFT of real function [inplace].
50
51       The real part of the transform ends up in the first half of the array
52       and the imaginary part of the transform ends up in the second half of
53       the array.
54
55               realfft($real);
56
57       realifft()
58
59       Inverse of one-dimensional realfft routine [inplace].
60
61               realifft($real);
62
63       fftnd()
64
65       N-dimensional FFT (inplace)
66
67               fftnd($real,$imag);
68
69       ifftnd()
70
71       N-dimensional inverse FFT
72
73               ifftnd($real,$imag);
74
75       fftconvolve()
76
77       N-dimensional convolution with periodic boundaries (FFT method)
78
79               $kernel = kernctr($image,$smallk);
80               fftconvolve($image,$kernel);
81
82       fftconvolve works inplace, and returns an error array in kernel as an
83       accuracy check -- all the values in it should be negligible.
84
85       See also PDL::ImageND::convolveND, which performs speed-optimized con‐
86       volution with a variety of boundary conditions.
87
88       The sizes of the image and the kernel must be the same.  kernctr cen‐
89       tres a small kernel to emulate the behaviour of the direct convolution
90       routines.
91
92       The speed cross-over between using straight convolution
93       (PDL::Image2D::conv2d()) and these fft routines is for kernel sizes
94       roughly 7x7.
95
96       convmath
97
98         Signature: ([o,nc]a(m); [o,nc]b(m))
99
100       Internal routine doing maths for convolution
101
102       cmul
103
104         Signature: (ar(); ai(); br(); bi(); [o]cr(); [o]ci())
105
106       Complex multiplication
107
108       cdiv
109
110         Signature: (ar(); ai(); br(); bi(); [o]cr(); [o]ci())
111
112       Complex division
113

BUGS

115       Where the source is marked `FIX', could re-implement using phase-shift
116       factors on the transforms and some real-space bookkeeping, to save some
117       temporary space and redundant transforms.
118

AUTHOR

120       This file copyright (C) 1997, 1998 R.J.R. Williams
121       (rjrw@ast.leeds.ac.uk), Karl Glazebrook (kgb@aaoepp.aao.gov.au), Tuomas
122       J. Lukka, (lukka@husc.harvard.edu).  All rights reserved. There is no
123       warranty. You are allowed to redistribute this software / documentation
124       under certain conditions. For details, see the file COPYING in the PDL
125       distribution. If this file is separated from the PDL distribution, the
126       copyright notice should be included in the file.
127
128
129
130perl v5.8.8                       2006-12-02                            FFT(3)
Impressum