Skip to content

signal.Fft.Function.fft

Christian d'Heureuse edited this page Jun 6, 2026 · 2 revisions

dsp-collection / signal/Fft / fft

Function: fft()

function fft(x, direction?): ComplexArray;

Computes the FFT of an array of complex numbers.

Depending on the application, the output values must be normalized.

Parameters

x

ComplexArray

The input values. The array can have any length, but when it's a power of 2, the computation is faster.

direction?

boolean = true

true for FFT (forward FFT), false for iFFT (inverse FFT).

Returns

ComplexArray

The result of the FFT, without any normalization. The returned array has the same length as the input array.

Clone this wiki locally