TITLE: Function and Fourier transform vanish on an interval
QUESTION [11 upvotes]: I'm no expert on these things (and this may not be cutting edge research level; it's really motivated by this MSE question), but it seems that there are non-zero measures (and also functions (?), I would think) on $\mathbb R$ such that both the function and its Fourier transform vanish on an interval. This is usually mentioned in the context of Beurling's work on spectral gaps.

(1) Is there a nice snappy way to see this? (2) How regular can such an $f$ be? Could it be a Schwartz function?

REPLY [8 votes]: Over at MSE (see linked question), user1952009 (= reuns on MO) has given a very elegant construction of a Schwartz function with this property. I am reproducing his/her answer here.
Let $g,h\in C_0^{\infty}$ with support contained in $[1/3,1/2]$, and write $\widehat{h}_n=\int_0^1 h(x)e^{-2\pi inx}\, dx$ for the discrete Fourier coefficients of $h$, viewed as a $1$-periodic function $h_p$. Let
$$
f(x)=\sum_{n=-\infty}^{\infty} \widehat{h}_n g(x-n) .
$$
Then
$$
\widehat{f}(\xi)= \sum \widehat{h}_n e^{2\pi in\xi}\widehat{g}(\xi) = h_p(\xi)\widehat{g}(\xi) .
$$
Thus $f$ is as desired; this calculation also confirms that $f\in\mathcal S$.