MATLAB Plot of FT(Cos) Displays Weird Impulse It is known that:
$$
\mathcal{F}\{\cos(2\pi t)\}=\frac{\delta(f-1)+\delta(f+1)}{2}
$$
However, on MATLAB, I used F=fftshift(fft(x))/N;  to obtain the FT of $\cos(2\pi t)$ and I obtained the following:

My question is why does each $\delta$ appear to be made up of two thin close parallel lines. Note that I have used $1024$ sample points and constructed $f$ a vector from $-51.2$Hz to $51.2$Hz and $t$ a vector from $-5$ to $5$.
That's because Matlab preforms FFT, the formula that you referred to is the FT of your signal, the difference between the two can be derived by convolving the DTFT (which has the same form of the FT) with the sinc function, which in your case is close to a delta function.  For that reason you get a slight different frequancy domain from the theory you would expect