Remix.run Logo
ajross 4 days ago

> At the root of the fast transform is the simple fact that

Actually... no? That's a constant factor optimization; the second expression has 75% the operations of the first. The FFT is algorithmically faster. It's O(N·log2(N)) in the number of samples instead of O(N²).

That property doesn't come from factorization per se, but from the fact that the factorization can be applied recursively by creatively ordering the terms.

srean 4 days ago | parent | next [-]

It's the symmetry that gives recursive opportunities to apply the optimization. It's the same optimization folded over and over again. Butterfly diagrams are great for understanding this. https://news.ycombinator.com/item?id=45291978 has pointers to more in depth exploration of the idea.

emil-lp 4 days ago | parent | prev [-]

Well, actually ... Summation is linear time, multiplication is superlinear (eg n log n in number of digits).

Meaning that this takes k summations and one multiplication rather than k multiplications and k summations.

... Where k is the number of terms.

ajross 4 days ago | parent [-]

"Digits" are constant in an FFT (or rather ignored, really, precision is out of scope of the algorithm definition).

Obviously in practice these are implemented as (pairs of, for a complex FFT, though real-valued DCTs are much more common) machine words in practice, and modern multipliers and adders pipeline at one per cycle.