ffts-sys 0.1.1

Rust binding for ffts (The Fastest Fourier Transform in the South)
Documentation

ffts-sys

Bindings generated with bindgen (using the tutorial verbatim).

Instructions

Build and install ffts:

  1. Clone https://github.com/sevagh/ffts
  2. Build and install it (instructions available in repo)
  3. Run cargo test

Test

The test is transliterated from the C test.

C test out

build $ ./ffts_test
 Sign |      Size |     L2 Error
------+-----------+-------------
  -1  |         2 | 8.659561E-17
  -1  |         4 | 1.145552E-16
  -1  |         8 | 1.210162E-08
  -1  |        16 | 2.220916E-08
  -1  |        32 | 2.396272E-08
  -1  |        64 | 2.272872E-08
  -1  |       128 | 1.940460E-08
  -1  |       256 | 2.081312E-08
  -1  |       512 | 2.045939E-08
  -1  |      1024 | 2.079071E-08
  -1  |      2048 | 2.074052E-08
  -1  |      4096 | 2.124981E-08
  -1  |      8192 | 2.086463E-08
  -1  |     16384 | 2.071494E-08
  -1  |     32768 | 2.062090E-08
  -1  |     65536 | 2.054694E-08
  -1  |    131072 | 2.060355E-08
  -1  |    262144 | 2.054523E-08
   1  |         2 | 8.659561E-17
   1  |         4 | 1.145552E-16
   1  |         8 | 1.210162E-08
   1  |        16 | 2.220916E-08
   1  |        32 | 2.396272E-08
   1  |        64 | 2.272872E-08
   1  |       128 | 1.940460E-08
   1  |       256 | 2.081312E-08
   1  |       512 | 2.045939E-08
   1  |      1024 | 2.079071E-08
   1  |      2048 | 2.074052E-08
   1  |      4096 | 2.124981E-08
   1  |      8192 | 2.086463E-08
   1  |     16384 | 2.071494E-08
   1  |     32768 | 2.062090E-08
   1  |     65536 | 2.054694E-08
   1  |    131072 | 2.060355E-08
   1  |    262144 | 2.054523E-08

Rust test out

ffts-sys $ cargo test -- --nocapture
   Compiling ffts-sys v0.1.0 (/home/sevagh/repos/ffts-rs/ffts-sys)
    Finished dev [unoptimized + debuginfo] target(s) in 1.38s
     Running target/debug/deps/ffts_sys-e69ee569605f50b9

running 2 tests
test bindgen_test_layout_max_align_t ... ok
  -1  |         2 | 8.659561E-17
  -1  |         4 | 1.145552E-16
  -1  |         8 | 1.210162E-8
  -1  |        16 | 2.220916E-8
  -1  |        32 | 2.396272E-8
  -1  |        64 | 2.272872E-8
  -1  |       128 | 1.940460E-8
  -1  |       256 | 2.081312E-8
  -1  |       512 | 2.045939E-8
  -1  |      1024 | 2.079072E-8
  -1  |      2048 | 2.074052E-8
  -1  |      4096 | 2.124981E-8
  -1  |      8192 | 2.086463E-8
  -1  |     16384 | 2.071494E-8
  -1  |     32768 | 2.062090E-8
  -1  |     65536 | 2.054694E-8
  -1  |    131072 | 2.060355E-8
  -1  |    262144 | 2.054523E-8
   1  |         2 | 8.659561E-17
   1  |         4 | 1.145552E-16
   1  |         8 | 1.210162E-8
   1  |        16 | 2.220916E-8
   1  |        32 | 2.396272E-8
   1  |        64 | 2.272872E-8
   1  |       128 | 1.940460E-8
   1  |       256 | 2.081312E-8
   1  |       512 | 2.045939E-8
   1  |      1024 | 2.079072E-8
   1  |      2048 | 2.074052E-8
   1  |      4096 | 2.124981E-8
   1  |      8192 | 2.086463E-8
   1  |     16384 | 2.071494E-8
   1  |     32768 | 2.062090E-8
   1  |     65536 | 2.054694E-8
   1  |    131072 | 2.060355E-8
   1  |    262144 | 2.054523E-8
test tests::test_ffts_errors ... ok

test result: ok. 2 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out

   Doc-tests ffts-sys

running 0 tests

test result: ok. 0 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out