FOURIER Function (LibreOffice Calc)
Compute LibreOffice Calc Fourier transforms with explicit real/imaginary input, inverse normalization, polar output and small reproducible DFT checks.
Verification status: Ten ordinary Fourier component and inverse/polar checks were recalculated in LibreOfficeDev 26.8.0.0.alpha0 (2c87e51eeaa2b413ff4ae097b2705eea1995d8e5) using headless XLSX import and forced recalculation. Exact identities, typed inputs/results and controls were checked. LibreOffice 26.8.1.1 was source-reviewed only; no stable-release or GUI array-entry execution is claimed. How formula examples are checked
Quick answer: =INDEX(FOURIER(H2:H5;TRUE());1;1) returned 10 in the tested development build.
Availability and version history
- Introduced: LibreOffice 6.3, explicitly stated in function-specific Help.
- Supported in: 26.8 Help and 26.8.1.1 registration; no retirement is established.
- Scope: Desktop Calc, English semicolon-separated formulas. The documented
ORG.LIBREOFFICE.FOURIERnamespace is outside OpenFormula 1.3. - Checked: October 14, 2026. Ten listed examples were recalculated in LibreOfficeDev 26.8.0.0.alpha0 using headless XLSX import. Stable releases, 26.8.1.1 and GUI array entry were not executed.
What FOURIER returns
FOURIER computes a discrete Fourier transform of a numeric sequence. It returns a two-column array: real and imaginary components by default, or magnitude and phase when Polar is TRUE. The input grouping flag tells Calc how to read the source; it does not turn the returned spectrum into a horizontal two-row result. Function Help.
Syntax and arguments
FOURIER(Array; GroupedByColumns [; Inverse [; Polar [; MinimumMagnitude]]])
Square brackets mark optional arguments; do not type them. Array contains real values in one column or row, or real and imaginary components in two columns or rows. GroupedByColumns is required: TRUE reads columns, FALSE reads rows. Inverse defaults to FALSE; TRUE selects the inverse transform. Polar defaults to FALSE. MinimumMagnitude defaults to zero and is used only for polar output to suppress small components. Complex input is represented by two numeric components, not strings such as “1+i”.
Worksheet setup
Enter the real sequence 1, 2, 3, 4 down H2:H5 and the same sequence across H7:K7. For the three-point complex example, enter:
| Row | L: real | M: imaginary |
|---|---|---|
| 2 | 1 | 1 |
| 3 | 0 | -1 |
| 4 | 2 | 0 |
Ten reproducible examples
The native column is from LibreOfficeDev 26.8.0.0.alpha0, build 2c87e51eeaa2b413ff4ae097b2705eea1995d8e5, using headless XLSX import and forced recalculation. Decimal values are rounded to twelve places; quoted text excludes the surrounding quotation marks from the returned value.
| Formula | Independent reference | LibreOfficeDev result |
|---|---|---|
=INDEX(FOURIER(H2:H5;TRUE());1;1) |
10 |
10 |
=INDEX(FOURIER(H2:H5;TRUE());2;1) |
-2 |
-2 |
=INDEX(FOURIER(H2:H5;TRUE());2;2) |
2 |
2 |
=INDEX(FOURIER(H2:H5;TRUE());4;2) |
-2 |
-2 |
=INDEX(FOURIER(FOURIER(H2:H5;TRUE());TRUE();TRUE());3;1) |
3 |
3 |
=INDEX(FOURIER(H2:H5;TRUE();FALSE();TRUE());2;1) |
2.828427124746 |
2.828427124746 |
=INDEX(FOURIER(H2:H5;TRUE();FALSE();TRUE());2;2) |
2.356194490192 |
2.356194490192 |
=INDEX(FOURIER(H7:K7;FALSE());3;1) |
-2 |
-2 |
=INDEX(FOURIER(L2:M4;TRUE());2;1) |
-0.866025403784 |
-0.866025403784 |
=INDEX(FOURIER(H2:H5;TRUE();FALSE();TRUE();3);2;1) |
0 |
0 |
Practical worksheet
The real sequence 1, 2, 3, 4 has forward-transform components 10, −2+2i, −2 and −2−2i. The first output row is the zero-frequency or DC component, equal to the sum 10. Result row 2 corresponds to frequency index 1, not frequency index 2. =INDEX(FOURIER(H2:H5;TRUE());2;2) selects the imaginary part 2. This separation of frequency row and component column is essential when checking a spectrum.
Advanced interpretation and checks
The forward reference uses X[k]=Σ x[j] exp(−2πijk/N), with j and k from 0 through N−1. The inverse changes the sign and divides by N. The nested inverse example recovers the third original value, 3, from the Cartesian forward result. Do not feed a magnitude/phase result directly into the inverse: the input parser would treat those two columns as real and imaginary components. For the second frequency component, magnitude is √8 and phase is 3π/4 radians. A polar cutoff of 3 suppresses that component to zero magnitude and phase. Inspected callback.
Boundaries and troubleshooting
The three-point complex example demonstrates a non-power-of-two length; the retained source chooses among FFT algorithms rather than requiring every sequence length to be a power of two. All input components must be numeric, and the grouping orientation permits at most two component columns or rows. Those invalid-input guards were source-checked rather than executed. Floating-point residuals near an ideal zero are expected. A magnitude cutoff is a reporting choice that can also remove a real small signal, so choose it according to the data scale. The tests select scalar components and do not establish a GUI array-entry workflow.
Related functions
Official evidence and checking scope
- Function-specific Help
- Complete versioned callback
- English native-name registration
- Normalization and polar conversion
- FFT selection and output shape
The saved formula identities, local input values and typed results were reconciled. The stale SUM cache changed to 3 and the uncached SUM returned 7. Saved formulas use ORG.LIBREOFFICE.FOURIER for this operation. The examples establish only the listed development-build results; unexecuted guards and current-source behavior remain separately scoped.