mborgerding / kissfft

a Fast Fourier Transform (FFT) library that tries to Keep it Simple, Stupid
Other
1.46k stars 283 forks source link

Improve accuracy + allow mpfr::mpreal and boost's float128 #78

Open cffk opened 2 years ago

cffk commented 2 years ago

(1) Accuracy has been improved in the set up of the _twiddles array. Now sin and cos are only evaluated for angles in [-pi/4, pi/4] and all the elementary symmetries of the trig functions are preserved. This reduces the round-off error to be competitve with fftw.

(2) A key advantage of kissfft over fftw is that it can be used with non-standard floating point numbers, e.g., mpfr::mpreal and boost::multiprecision::float128. For this to "work", the math functions need to be called without the "std::" prefix to allow the specific overloads for these functions to be found. "using" clauses are added to the code so that the standard functions are still found for the standard floating point types.

dizcza commented 1 year ago

An interesting change; I'd like it's being double-checked and merged.

It seems though this repository is no longer maintained... it waits for someone to take it over and go on with KissFFTv2