# Find a function by its Fourier coefficients

Suppose $x[n]$ ($n$ integers) is periodic with period 8 and its Fourier coefficients are $$a_k = \cos(k\pi /4) + \sin(3k\pi /4).$$

Prove $x[n] = 4\delta[n-1] + 4\delta[n-7] + 4j\delta[n-3] - 4j\delta[n-5]$ where $\delta[n]$ takes zero everywhere except $n=0$ at which it takes $1$.

• Your $x[n]$ isn't periodic. Do you mean the period-8 extension of it? – Austin A. Oct 20 '15 at 12:35
• Yes. $x[n]$ is the extension one. – jachilles Oct 20 '15 at 12:38

Since the Discrete Fourier Transform (DFT) is a bijection, you can prove this by taking the forward transform of $x[n]$ rather than the inverse transform of $a_k$. I might recommend this approach as it is easy to transform the $\delta$ functions.
I take the sum from $n = 0$ to $n = 7$; the function $x[n]$ is automatically extended periodically with period 8. \begin{align} \mathcal{F}(x[n]) &:= \frac{1}{8} \sum_{n = 0}^8 x[n] e^{-2 \pi i k n / 8} \\ &= \frac{1}{8} \left( 4 e^{-2\pi ik/8} + 4i e^{-6\pi ik/8} - 4ie^{-10\pi ik/8} + 4e^{-14\pi ik/8} \right) \\ &= \frac{1}{8} \left( (4 e^{-\pi i k/4} + 4 e^{-7\pi i k/4}) + (4i e^{-3\pi i k/4} - 4i e^{-5\pi i k/4}) \right)\\ &= \frac{1}{8} \left( 4(e^{-\pi i k /4} + e^{\pi i k/4}) + 4i(e^{-3\pi i k/4} - e^{3\pi i k/4})\right)\\ &= \frac{1}{8} \left( 8\cos(\pi k /4) + 8\sin(3\pi k/4) \right)\\ &= \cos(\pi k /4) + \sin(3\pi k/4). \end{align}