DFFT(1)
π DFFT(1) β the dfft page, but make it cute π
okay so bestie, welcome to the BRL-CAD manual, section 1, and today's main character is dfft π
β¨ NAME β¨
dfft β computes fast Fourier transforms of a stream of doubles π¦
πΈ SYNOPSIS πΈ
dfft [-clpLAN] [-d dB] [width] < doubles > spectrum
π DESCRIPTION π
okay so here's the vibe: dfft reads a stream of double-precision floating-point samples from standard input, computes the real fast Fourier transform of each 1024-sample record, and writes the resulting spectrum to standard output. literally that's it and it ate π₯
β οΈ and like, both standard input and standard output must be redirected, no cap. If either one is a terminal, dfft prints a usage message and exits. it's giving "not today" π
by default the output is the periodogram-scaled log-magnitude in decibels, written as 512 double-precision values per 1024-sample record. iconic β¨
the options let you pick, like, a whole different era:
- phase output instead of magnitude π
- a linear (non-dB) magnitude scale π
- a logarithmic frequency scale π
- a third-octave critical band filter ποΈ
- normalization to the peak magnitude π
- or human-readable ASCII text π«Ά
the optional width argument? she's accepted for historical compatibility but ignored, periodt. the transform length is fixed at 1024 samples, yielding 512 output values. that's the law π
input is normally produced by a tool such as dconv(1) or dmod(1) β iykyk π§
β¨ OPTIONS β¨
-ddB β set the minimum magnitude in decibels. you give it a positive value and it gets applied as its negative, ok? magnitudes below this floor are clamped when the output is normalized. default is120, i.e.-120dB π-lβ interpolate the magnitudes onto a logarithmic frequency scale π-cβ apply a third-octave critical band filter to the magnitudes ποΈ-pβ output the phase, in units of pi, instead of the magnitude π-Nβ normalize the power spectral density so the peak is0dB (or1.0in linear mode) π-Lβ output linear magnitude rather than log-magnitude in decibels π-Aβ write human-readable ASCII text instead of binary doubles. each line holds a frequency fraction and its magnitude separated by a space π-h,-?β print a usage message and exit π«Ά
π¦ EXAMPLES π¦
Example 1. Plot a power spectrum
dfft -A -N < signal.doubles > spectrum.txt
computes the FFT of the samples in signal.doubles, normalizes the power spectral density to a 0 dB peak, and writes (frequency, magnitude) pairs as ASCII text suitable for feeding to a plotting program. plot girl summer πΈβ¨
Example 2. Critical band magnitude on a log frequency scale
dmod -m 32768 < raw.doubles | dfft -c -l > bands.doubles
scales the raw samples with dmod(1), then computes a third-octave critical-band-filtered spectrum interpolated onto a logarithmic frequency scale, producing binary doubles for further processing. pipeline? slayed π
π₯
π SEE ALSO π
brlcad(1), dconv(1), dmod(1), dauto(1), dwin(1), dstats(1)
π AUTHOR π
BRL-CAD Team π
π COPYRIGHT π
This software is Copyright (c) 1989-2026 by the United States Government as represented by U.S. Army Research Laboratory.
π BUG REPORTS π
Reports of bugs or problems should be submitted via electronic mail to devs@brlcad.org π§ β like, please actually tell them, don't just suffer in silence bestie π
okay that's the whole page!! from the BRL-CAD girlies, DFFT(1), dated 2026, mwah π send your bug mail, stay hydrated, and remember: redirect your stdin AND your stdout π«Άπ
π¦ where this page comes from
- nixpkgs unstable: brlcad 7.44.0
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms