From d3261e4b55838c23d9f69b6625e3c4a08f352e61 Mon Sep 17 00:00:00 2001 From: David Rotermund <54365609+davrot@users.noreply.github.com> Date: Fri, 15 Dec 2023 14:39:38 +0100 Subject: [PATCH] Update README.md Signed-off-by: David Rotermund <54365609+davrot@users.noreply.github.com> --- numpy/fft/README.md | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/numpy/fft/README.md b/numpy/fft/README.md index a7fcd8d..6cf81b9 100644 --- a/numpy/fft/README.md +++ b/numpy/fft/README.md @@ -151,6 +151,15 @@ plt.show() ``` ![image3a](image3a.png) +```python +plt.plot(t, np.imag(np.fft.ifft(fft_result))) +plt.ylabel("imag(ifft(fft(x)))") +plt.xlabel("t") +plt.title("FFT") +plt.show() +``` +![image3b](image3b.png) + ```python plt.plot(t, x - np.real(np.fft.irfft(rfft_result))) @@ -162,6 +171,17 @@ plt.show() ![image4](image4.png) + +```python +plt.plot(t, np.imag(np.fft.irfft(rfft_result))) +plt.ylabel("imag(irfft(rfft(x)))") +plt.xlabel("t") +plt.title("rFFT") +plt.show() +``` + +![image4b](image4b.png) + ## [Discrete Fourier Transform (numpy.fft)](https://numpy.org/doc/stable/reference/routines.fft.html#discrete-fourier-transform-numpy-fft) ## [Standard FFTs](https://numpy.org/doc/stable/reference/routines.fft.html#standard-ffts)