summaryrefslogtreecommitdiffstats
path: root/dft.txi
diff options
context:
space:
mode:
authorBryan Newbold <bnewbold@robocracy.org>2017-02-20 00:05:36 -0800
committerBryan Newbold <bnewbold@robocracy.org>2017-02-20 00:05:36 -0800
commit5bea21e81ed516440e34e480f2c33ca41aa8c597 (patch)
tree653ace1b8fe0a9916d861d35ff8f611b46c80d37 /dft.txi
parent237c6e380aebdcbc70bd1c9ecf7d3f6effca2752 (diff)
downloadslib-upstream/3a4.tar.gz
slib-upstream/3a4.zip
Import Upstream version 3a4upstream/3a4
Diffstat (limited to 'dft.txi')
-rw-r--r--dft.txi90
1 files changed, 90 insertions, 0 deletions
diff --git a/dft.txi b/dft.txi
new file mode 100644
index 0000000..20b73a7
--- /dev/null
+++ b/dft.txi
@@ -0,0 +1,90 @@
+@code{(require 'dft)} or
+@code{(require 'Fourier-transform)}
+@ftindex dft, Fourier-transform
+
+@code{fft} and @code{fft-1} compute the Fast-Fourier-Transforms
+(O(n*log(n))) of arrays whose dimensions are all powers of 2.
+
+@code{sft} and @code{sft-1} compute the Discrete-Fourier-Transforms
+for all combinations of dimensions (O(n^2)).
+
+
+@defun sft array prot
+
+
+@defunx sft array
+@var{array} is an array of positive rank. @code{sft} returns an
+array of type @var{prot} (defaulting to @var{array}) of complex numbers comprising
+the @dfn{Discrete Fourier Transform} of @var{array}.
+@cindex Discrete Fourier Transform
+@end defun
+
+
+@defun sft-1 array prot
+
+
+@defunx sft-1 array
+@var{array} is an array of positive rank. @code{sft-1} returns an
+array of type @var{prot} (defaulting to @var{array}) of complex numbers comprising
+the inverse Discrete Fourier Transform of @var{array}.
+@end defun
+
+
+@defun fft array prot
+
+
+@defunx fft array
+@var{array} is an array of positive rank whose dimensions are all
+powers of 2. @code{fft} returns an array of type @var{prot} (defaulting to
+@var{array}) of complex numbers comprising the Discrete Fourier Transform of
+@var{array}.
+@end defun
+
+
+@defun fft-1 array prot
+
+
+@defunx fft-1 array
+@var{array} is an array of positive rank whose dimensions are all
+powers of 2. @code{fft-1} returns an array of type @var{prot} (defaulting
+to @var{array}) of complex numbers comprising the inverse Discrete Fourier
+Transform of @var{array}.
+@end defun
+
+@code{dft} and @code{dft-1} compute the discrete Fourier transforms
+using the best method for decimating each dimension.
+
+
+@defun dft array prot
+
+
+@defunx dft array
+@code{dft} returns an array of type @var{prot} (defaulting to @var{array}) of complex
+numbers comprising the Discrete Fourier Transform of @var{array}.
+@end defun
+
+
+@defun dft-1 array prot
+
+
+@defunx dft-1 array
+@code{dft-1} returns an array of type @var{prot} (defaulting to @var{array}) of
+complex numbers comprising the inverse Discrete Fourier Transform of
+@var{array}.
+@end defun
+
+@noindent
+@code{(fft-1 (fft @var{array}))} will return an array of values close to
+@var{array}.
+
+@example
+(fft '#(1 0+i -1 0-i 1 0+i -1 0-i)) @result{}
+
+#(0.0 0.0 0.0+628.0783185208527e-18i 0.0
+ 0.0 0.0 8.0-628.0783185208527e-18i 0.0)
+
+(fft-1 '#(0 0 0 0 0 0 8 0)) @result{}
+
+#(1.0 -61.23031769111886e-18+1.0i -1.0 61.23031769111886e-18-1.0i
+ 1.0 -61.23031769111886e-18+1.0i -1.0 61.23031769111886e-18-1.0i)
+@end example