# FFT Spectrum Calculator for Numeric Data > Paste samples or a time/value table: amplitude and phase spectrum, peaks and a CSV. Computes the discrete Fourier transform of numeric samples of any length (exact, no truncation) and shows the single-sided amplitude and phase spectrum with a proper frequency axis, the strongest peaks with interpolated frequencies, a plot of the signal and the spectrum, and a CSV of every bin. Windows: rectangular, Hann or Hamming; optional mean removal and zero padding. For audio files use the Soundscape spectrum analyzer; this tool takes numbers. Part of the Proofline math notebook. Part of usefulweb.app (https://usefulweb.app/). Part of [Proofline](https://proofline.usefulweb.app/) (ownerApp: proofline). Results are deterministic calculations from the inputs and the listed assumptions; the API returns exactly what the web page shows. ## Use it - Human interface: https://prooflinefftspectrum.usefulweb.app/ (interactive tool at https://prooflinefftspectrum.usefulweb.app/tool) - JSON API: POST https://prooflinefftspectrum.usefulweb.app/api/v1/calculate with a JSON object of inputs (schema: https://prooflinefftspectrum.usefulweb.app/api/v1/tool) - OpenAPI: https://prooflinefftspectrum.usefulweb.app/openapi.json - MCP (Streamable HTTP): https://prooflinefftspectrum.usefulweb.app/mcp - tool `proofline_fft_spectrum` ## Inputs - samples (textarea, required): Samples - One value per line (or separated by spaces/commas), or two columns time, value with equal time steps (the sample rate then follows from the time column). At most 16384 samples. - sampleRate (number): Sample rate - Samples per second (or per unit of your x axis). Frequencies are reported in the same unit. - window (select): Window - removeMean (boolean): Remove the mean (DC) first - zeroPad (boolean): Zero-pad to the next power of two - Interpolates the spectrum on a finer grid; does not add real resolution. - peaks (integer): Peaks to list ## Method - One FFT in the code base: the radix-2 Cooley–Tukey FFT of the shared audio engine (Soundscape). Lengths that are not a power of two are transformed exactly with Bluestein’s chirp-z algorithm, whose convolution runs on that same FFT. - Single-sided amplitude: 2·|X_k| / Σw (|X_0| / Σw and the Nyquist bin without the factor 2), so a sinusoid that falls on a bin shows its true amplitude with any window. Phase atan2(Im, Re) in degrees, relative to a cosine starting at the first sample; set to 0 where the amplitude is below 10⁻⁹ of the maximum. - Frequency of bin k is k·fs/n. Peaks are local maxima; their frequency is refined by a parabola through the logarithms of the three neighbouring amplitudes. - Verified against a direct O(n²) DFT for power-of-two and other lengths, Parseval’s theorem and the exact amplitudes and phases of test sinusoids. ## Limits - Frequencies above half the sample rate fold back (aliasing) and cannot be told apart from lower ones. A finite record smears frequencies that do not fall on a bin (leakage); windows reduce but do not remove this.