I'm currently testing the fft package from numpy. I created an artificial centro-symmetric image and I made a 2D FFT on it, I took the imaginary part and remarked that this is not equal to zero. I don't understand why, do you have any idea? Maybe there is something that I miss when I goes from 1D radial profile to a 2D image, I really don't know...
NEW UPDATE (new example) :
import numpy as np
from scipy import interpolate
import matplotlib.pyplot as plt
I_min = 1.774E-6 #min(y_intensity[y_intensity!=0])
y = np.ones(50) #y_intensity[:50]
xv_3 = np.linspace(0,0.005,len(y))*1E3# x_intensity[:50]*1E3
new_r = np.linspace(-100,100,2**8)
interpol_index = interpolate.interp1d(xv_3, y)
X, Y = np.meshgrid(new_r,new_r)
profilegrid3 = np.ones(X.shape, float)
for i, x in enumerate(X[0, :]):
for k, z in enumerate(Y[:, 0]):
current_radius = np.sqrt(x**2 + z**2)
cond=np.logical_or(current_radius>=max(xv_3),current_radius<=min(xv_3))
if cond == True :
profilegrid3[i, k] = I_min
else :
profilegrid3[i, k] = interpol_index(current_radius)
plt.figure()
plt.imshow(np.imag(np.fft.ifftshift(np.fft.fft2(np.fft.fftshift(profilegrid3)))))
plt.colorbar()
plt.show()
Image :
Imaginary Part :

