Skip to content

signal.Fft.Function.iFftRealHalfOpt

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

dsp-collection / signal/Fft / iFftRealHalfOpt

Function: iFftRealHalfOpt()

function iFftRealHalfOpt(
   x, 
   len, 
   inclNyquist?): Float64Array;

Defined in: signal/Fft.ts:329

Computes the inverse FFT for a real signal. Optimized version.

This version is optimized for real numbers. The time-consuming FFT algorithm is only performed with half the array size of the output signal.

The length of the output array must be even.

This is an inverse function of fftRealSpectrum().

Parameters

x

ComplexArray

An array of complex numbers that define the amplitudes and phases of the sinusoidal frequency components. This corresponds to the normalized lower half of the FFT output. It can include an additional entry for the nyquist frequency component. If this array is longer than required, the extra values are ignored. If it is shorter, the missing values are assumed to be zero.

len

number

Output signal length. Must be even.

inclNyquist?

boolean = false

If true, the value at x[len / 2] is included in the inverse FFT.

Returns

Float64Array

An array of real numbers that represent the signal which is the sum of the sinusoidal components.

Clone this wiki locally