- #1
SchroedingersLion
- 215
- 57
- TL;DR Summary
- I am posting this in the EE forum since electrical engineers are typically skilled with Fourier transforms.
Hi guys,
for a project I had to get involved with discrete Fourier transforms to solve PDEs.
However, the code that I implemented according to a pseudo-code from a paper did not work - it seems like I calculated integrals incorrectly.
To search the error, I tried to integrate the sin(x) function with my method, and it did not work.
I already posted the formula I used for this sine integration, as well as the code, here:
https://scicomp.stackexchange.com/questions/33886/calculate-integrals-using-numpy-fft
Does anyone know what I am doing wrong? The error does not depend on N, and after my inverse FT my signal contains nonzero imaginary parts which should not happen! Is there something wrong with my formula?
I am a bit desperate, since my deadlines are getting closer...
SL
for a project I had to get involved with discrete Fourier transforms to solve PDEs.
However, the code that I implemented according to a pseudo-code from a paper did not work - it seems like I calculated integrals incorrectly.
To search the error, I tried to integrate the sin(x) function with my method, and it did not work.
I already posted the formula I used for this sine integration, as well as the code, here:
https://scicomp.stackexchange.com/questions/33886/calculate-integrals-using-numpy-fft
Does anyone know what I am doing wrong? The error does not depend on N, and after my inverse FT my signal contains nonzero imaginary parts which should not happen! Is there something wrong with my formula?
I am a bit desperate, since my deadlines are getting closer...
SL
Last edited: