Finding the Fourier transform of shifted rect function

5.7k Views Asked by At

This is my procedure but I am unsure if I did the right thing after talking with some of my peers.

$$f(x) =\mathrm{rect}\bigg|\frac{x-x_0}{a} \bigg|= \begin{cases} 0 & \bigg|\frac{x-x_0}{a} \bigg|>1/2 \\ 1/2 & \bigg|\frac{x-x_0}{a} \bigg| = 1/2 \\ 1 & \bigg|\frac{x-x_0}{a} \bigg|<1/2 \end{cases} $$

Since the values with $1/2$ are an integral from some point $p$ to that same point $p$ we don't need to care about that part. Therefore, we only need to integrate over the points where the function is $1$. That is, points where

$$\bigg|\frac{x-x_0}{a} \bigg| < 1/2$$

$$-1/2 < \frac{x-x_0}{a} < 1/2$$

$$\frac{-a}{2}+x_0<x<\frac{a}{2} + x_0$$

$$F(k)= \int_{\frac{-a}{2}+x_0}^{\frac{a}{2}+x_0} e^{ikx} \mathrm{d}x = \frac{e^{ikx_0}(e^{ika/2}-e^{-ika/2})}{ik} = e^{ikx_0} \frac{\sin(ak/2)}{k}$$

I was told the solution should be only

$$\sin(ak/2)/k$$

1

There are 1 best solutions below

0
On

If function $f(x)$ yields a Fourier transform defined as $F(k) = \int_{-\infty}^{\infty} f(x) \, \mathrm{e}^{\mathrm{i}kx} \, \mathrm{d}x$, then it can be shown that a shifted function $f(x-x_0)$ yields a Fourier transform $F(k) \mathrm{e}^{\mathrm{i}kx_0}$. This can be seen by observing the definition of the inverse Fourier transform:

$$f(x) = \frac{1}{2\pi}\int_{-\infty}^{\infty}F(k) \, \mathrm{e}^{-\mathrm{i}kx} \, \mathrm{d}k$$

Note how $x$ here is not the variable of integration, and so we are free to replace $x$ with anything else. If we make the substitution $x \rightarrow x-x_0$, we observe

$$f(x - x_0) = \frac{1}{2\pi}\int_{-\infty}^{\infty}F(k) \, \mathrm{e}^{-\mathrm{i}k(x - x_0)} \, \mathrm{d}k$$

Note how the exponent can be factored, giving

$$f(x-x_0) = \frac{1}{2\pi}\int_{-\infty}^{\infty} \left(F(k)\mathrm{e}^{\mathrm{i}kx_0} \right) \, \mathrm{e}^{-\mathrm{i}kx} \, \mathrm{d}k$$

Where it can be seen that $f(x - x_0)$ is the inverse Fourier transform of $F(k)\mathrm{e}^{\mathrm{i}kx_0}$, which therefore means that $F(k)\mathrm{e}^{\mathrm{i}kx_0}$ is the Fourier transform of $f(x-x_0)$.

So, yes, we expect a $\mathrm{e}^{\mathrm{i}kx_0}$ factor to appear when finding the Fourier transform of a shifted input function. In your case, we expect the Fourier transform of the rectangular function from your question to be

$$\frac{2}{k}\sin \left(\frac{ak}{2}\right) \mathrm{e}^{\mathrm{i}kx_0}$$

As a reality check, if we set the shift to zero, we should re-obtain the FT of the unshifted function.

Note how the effect of shifting the input function alters the complex phase of the FT, but has no impact on the complex magnitude of the FT.