A simple wrapper for FFTW, using Guile's FFI.

Daniel Llorens 7436aa25a9 Add README 1 year ago
mod f6b0450256 Remove local SRFI-64 3 years ago
test 827af41efb Fail the test script if any test fails 4 years ago
README.md 7436aa25a9 Add README 1 year ago
test-me.scm 99d8805dcd Initial commit 4 years ago

README.md

guile-ffi-fftw is a minimal set of Guile FFI bindings for FFTW's ‘guru interface’,

www.fftw.org/fftw3_doc/Guru-Interface.html#Guru-Interface

It provides two functions:

  • fftw-dft! rank sign in out
  • fftw-dft rank sign in

These bindings being minimal, there is no support for computing & reusing plans, or split r/i transforms, or anything other than straight complex DFTs. There is a basic test suite using SRFI-64. Contributions are welcome.

I think the bindings provide a good example of how to interface from Guile with array libraries taking dense arrays as arguments. FFTW is nice in this respect, because it supports arbitrary strides —which should be the norm really!

There is another set of bindings by Mikael Djurfeldt,

https://savannah.gnu.org/projects/guile-fftw

But it only does up to 2D DFTs and is particular about array strides (based on my reading of the code), while fftw-dft! and fftw-dft do DFTs of any rank and place no restriction on strides. This comes through no effort on my part; it is a feature of FFTW's. Also guile-ffi-fftw uses the FFI, while guile-fftw uses a C extension, which you need to build, etc.