[SciPy-dev] FFT docstrings (was: Scipy Tutorial (and updating it))
Tom Grydeland
tom.grydeland@gmail....
Mon Dec 15 17:13:49 CST 2008
On Fri, Dec 12, 2008 at 9:19 PM, <jh@physics.ucf.edu> wrote:
> There's room and need for a bit more, since FFTs are among the most
> used and abused methods out there. Recall that our audience is one
> level below likely users. There's need for a short intro to the
> whole concept on the module page (I added one), which each routine
> page should refer to (but I haven't put those references in).
>
> Also, the current routine examples satisfy a mathematician but do not
> give insight into what the FT actually *does*, i.e., extract the
> periodic content of a signal. Also, an example should show the most
> basic use, i.e., taking the modulus and the arctan of the inputs to
> get the amplitude and phase of the contributing sinusoids. Too many
> people take the real part of an FFT and think they've got the
> amplitude. If you did a sine wave of amplitude 2 in 8 points, you
> could show in a simple example how to pull that out of the fft. For
> the complex case, point out that you have to fold (or double) the
> first half of the output, etc., since the negative frequencies get
> half the signal for real inputs. Then refer to rfft. Note that many
> users will not at first understand why (or even that) we have rfft,
> since most packages do not provide it, which is why it is worth some
> explanation.
>
> Doing all this consistently across the many routines would be very
> valuable. The rfft vs. fft explanation might best belong on the
> module page, since there are several routines for each. Then the
> routines themselves can have relatively spare pages. The formulae
> themselves might best go on the module page, for the same reason.
I've started on the module page, along the direction you outlined
above, not complete and no examples quite yet, but if people think it
looks okay, I can try to trim down the specific routines a bit as
well.
How can I make cross-references to `fft` in other functions refer to
numpy.fft[.fftpack].fft, instead of numpy.fft? I believe the current
package should be searched before parents for cross-references.
> --jh--
--
Tom Grydeland
<Tom.Grydeland@(gmail.com)>
More information about the Scipy-dev
mailing list