# fft-test **Mercurial revision 5786:5c8b45563631 | 2026-08-04** --- ## Description `fft-test` is a utility developed as part of the **T-UGO tools (2006-2011)** under the **Unstructured Ocean Grid initiative**. It tests the **equivalence between FFT implementations** in the **FFTPACK** and **GSL (GNU Scientific Library)** libraries. This tool is primarily intended for **validation and comparison** purposes, ensuring consistency between the two FFT libraries. > **Note:** This program does not accept command-line arguments. It runs predefined tests internally. --- ## Output The program will output the results of the FFT transformations for both libraries, allowing you to compare their equivalence. Example output: ``` vvv --- n=5 j=4 --- vvv FFTPACK results 0 0 0 0 1 GSL FFT results 1 0.309017 0.951057 -0.809017 0.587785 ^^^ --- n=5 j=4 --- ^^^ ``` --- ## Notes 1. **Dependencies:** - **FFTPACK**: A widely used library for computing Fast Fourier Transforms (FFTs). - **GSL (GNU Scientific Library)**: A numerical library for C and C++ programmers, providing FFT routines for real data. 2. **Test Cases:** - The program tests FFT transformations for arrays of sizes `n=4` and `n=5`. - For each size, it tests impulse responses (e.g., `value = 1` if `i == j`, else `0`). 3. **Output Interpretation:** - The output displays the FFT results for both libraries side by side. - Users can visually compare the results to ensure equivalence. 4. **Purpose:** - This tool is **not intended for production use** but rather for **debugging and validation** of FFT implementations. --- ## See Also - [FFTPACK](https://www.netlib.org/fftpack/): A library for computing Fast Fourier Transforms. - [GNU Scientific Library (GSL)](https://www.gnu.org/software/gsl/): A numerical library for C and C++ programmers. - [T-UGO Tools](https://www.t-ugo.org/): Unstructured Ocean Grid initiative tools.