You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
- ESM only. Use `import rfft from 'fourier-transform'` instead of `require()`.
6
+
- Returns `Float64Array` instead of `Array`.
7
+
- Returns internal buffer by default — overwritten on next call with same N. Pass an output buffer to keep results: `rfft(input, output)`.
8
+
- Fixed off-by-one in magnitude spectrum. Imaginary components were indexed as `x[N-k-1]` instead of `x[N-k]`, shifting bins with imaginary content by one. Results are now correct.
9
+
- Rejects N < 2 (previously N=1 returned empty array silently).
10
+
- Removed `asm.js` entry point.
11
+
12
+
## Added
13
+
14
+
-`fft()` named export — returns complex DFT as `{ re, im }`, N/2+1 bins, unnormalized.
15
+
- Optional output buffer parameter for both `rfft()` and `fft()`.
16
+
17
+
## Performance
18
+
19
+
- Float64Array working buffers instead of generic Array.
20
+
- Precomputed twiddle factors and bit-reversal table, cached per size.
21
+
- Zero-copy real part in `fft()` via subarray view.
22
+
-~2.7x faster than dsp.js (the original split-radix ancestor).
23
+
- On par with fft.js (indutny) in raw transform speed.
24
+
25
+
## Removed
26
+
27
+
-`asm.js` — no modern engine validates `'use asm'` anymore.
0 commit comments