[Numpy-discussion] Fourier transform
Charles R Harris
charlesr.harris at gmail.com
Mon Mar 29 18:12:56 EDT 2010
On Mon, Mar 29, 2010 at 3:00 PM, Pascal <pascal22p at parois.net> wrote:
> Hi,
>
> Does anyone have an idea how fft functions are implemented? Is it pure
> python? based on BLAS/LAPACK? or is it using fftw?
>
> I successfully used numpy.fft in 3D. I would like to know if I can
> calculate a specific a plane using the numpy.fft.
>
> I have in 3D:
> r(x, y, z)=\sum_h^N-1 \sum_k^M-1 \sum_l^O-1 f_{hkl}
> \exp(-2\pi \i (hx/N+ky/M+lz/O))
>
> So for the plane, z is no longer independant.
> I need to solve the system:
> ax+by+cz+d=0
> r(x, y, z)=\sum_h^N-1 \sum_k^M-1 \sum_l^O-1 f_{hkl}
> \exp(-2\pi \i (hx/N+ky/M+lz/O))
>
> Do you think it's possible to use numpy.fft for this?
>
>
I'm not clear on what you want to do here, but note that the term in the in
the exponent is of the form <k, x>, i.e., the inner product of the vectors k
and x. So if you rotate x by O so that the plane is defined by z = 0, then
<k, Ox> = <O.T, x>. That is, you can apply the transpose of the rotation to
the result of the fft.
Chuck
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/numpy-discussion/attachments/20100329/2ccbccb5/attachment.html>
More information about the NumPy-Discussion
mailing list