>From the docstring:
"A[0] contains the zero-frequency term (the mean of the signal)"
And yet, consistent w/ the definition given in the docstring (and included
w/ an earlier email), the code gives, e.g.:
>>> import numpy as np
>>> x = np.ones((16,)); x
array([ 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1.,
1., 1., 1.])
>>> y = np.fft.fft(x); y
array([ 16.+0.j, 0.+0.j, 0.+0.j, 0.+0.j, 0.+0.j, 0.+0.j,
0.+0.j, 0.+0.j, 0.+0.j, 0.+0.j, 0.+0.j, 0.+0.j,
0.+0.j, 0.+0.j, 0.+0.j, 0.+0.j])
i.e., the zero-th term is the sum, not the mean (which, again, is consistent
w/ the stated defining formula).
So, same ol', same ol': bug in the doc (presumably) or bug in the code?
DG
_______________________________________________
NumPy-Discussion mailing list
[email protected]
http://mail.scipy.org/mailman/listinfo/numpy-discussion