# How to calculate spacing in k-space after DFT of spatial signal

Note: In the following i'm going to use t as a time variable [s] and x as a spatial variable [m].

I'm currently working with the Discrete Fourier Transform (DFT), in order to get frequency information about my input signal. To be more precise, i am using the Fast Fourier Transform (FFT) for computational efficiency, using pythons numpy.fft package to do that.

When applying a DFT to a discrete signal of N-point, one transforms those N signal points to N transformed points. Simply speaking, each of those complex numbers we obtain from the DFT represent the a certain frequency of the signal, so one thing one has to be aware of is to properly calculate the spacing in the frequency space, in order to correctly correlate the DFT coefficients to specific frequencies.

For example: When i have a time signal f(t) at N discrete points, each with a constant spacing of dt, then i can calculate the spacing in frequency space $\Delta\omega = f_s/N$, where $f_s= 1/dt$ is the 'sampling rate' and N the number of signal points. This can be achieved easily with the fft-built in function (python) 'fftfreq': https://docs.scipy.org/doc/numpy/reference/generated/numpy.fft.fftfreq.html which outputs an array in frequency domain with the above mentioned correct frequency spacing up to the 'Nyquisit Limit', when being applied to a time domain vector.

My issue comes in, when i do not have a time signal f(t), but rather a spatial signal f(x). Now, after applying a Fourier Transform (or rather a DFT), the signal does not gets transformed to frequency space $\omega, [1/s]$, but to reciprocal space $k, [1/m]$, correct? That is, since we have a signal in space, the resulting 'frequencies' now measure the number of periods per space unit [1/m]. But how am i dealing with this fact considering my DFT calculation?

Looking at the Nyquisit Limit yields: $\omega_{Ny} = \frac{1}{2 dt}$ or in k-space $k_{Ny} = \frac{\pi}{\Delta x}$, respectively. So obviously, i have to calculate the k-domain (i.e. the spacing in k-sapce) differently when having a f(x) signal, instead of f(t). How do i calculate the k-spacing? Given the fact, that the Nyquisit-Limits only differ by a factor $2\pi$, i would naively say, that the k-spacing can by calculated with: $$\Delta k = \Delta\omega\cdot 2\pi = \frac{2\pi}{dt\cdot N}$$

Am i missing something, or is this the correct k-spacing when transforming a spatial signal f(x)? In that case, the corresponsing python fft-method 'fftfreq' would have to be adjusted in terms of that factor, right?

Thanks for any help.