🛠️🐜 Antkeeper superbuild with dependencies included https://antkeeper.com
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

24 lines
895 B

  1. #ifndef ALCOMPLEX_H
  2. #define ALCOMPLEX_H
  3. #include <complex>
  4. /**
  5. * Iterative implementation of 2-radix FFT (In-place algorithm). Sign = -1 is
  6. * FFT and 1 is iFFT (inverse). Fills FFTBuffer[0...FFTSize-1] with the
  7. * Discrete Fourier Transform (DFT) of the time domain data stored in
  8. * FFTBuffer[0...FFTSize-1]. FFTBuffer is an array of complex numbers, FFTSize
  9. * MUST BE power of two.
  10. */
  11. void complex_fft(std::complex<double> *FFTBuffer, int FFTSize, double Sign);
  12. /**
  13. * Calculate the complex helical sequence (discrete-time analytical signal) of
  14. * the given input using the discrete Hilbert transform (In-place algorithm).
  15. * Fills Buffer[0...size-1] with the discrete-time analytical signal stored in
  16. * Buffer[0...size-1]. Buffer is an array of complex numbers, size MUST BE
  17. * power of two.
  18. */
  19. void complex_hilbert(std::complex<double> *Buffer, int size);
  20. #endif /* ALCOMPLEX_H */