So I want a function that is zero on the reals only on the prime integers and which doesn't depend on knowing the primes. I construct:
$$f(x) = e^{-x^2} - \sum\limits_{n=2}^\infty e^{-n^2} \frac{ \sin(\pi x)^2 }{ n^2\sin(\pi x/n)^2}$$
Which has zeros on the real line only on the positive and negative prime integers.
( $c_n(x)=\frac{\sin(\pi x)^2}{n^2\sin(\pi x/n)^2}$ has a well defined Taylor series and can be defined everywhere. It is $1$ when $x$ is a multiple of $n$ and 0 otherwise. The exponentials are just to make the whole thing converge.)
So my question is, is a function like this useful? As in, would it tell us anything about the primes?
Edit: if it is analytic, as well as zeros on the real axis it will have many complex zeros.
I also note that it is quite "easy" to convert this into a series of the form: $f(x)=\sum\limits_{k=0}^\infty a_{k} x^{k}$ where the coefficients $a_{2k} =\frac{(-1)^k}{k!} - \sum\limits_{n=2}^\infty c^{(2k)}_n(0)e^{-n^2}$. It begins $f(x)=0.981-0.97722x^2+...$ although you would need a lot of terms when $x$ is big!!! But we could say $f^{-1}(0)\subset$primes.
Edit 2: I think the function actually also has zeros at points very close to the primes and only the zeros where $f'(x)<0$ are primes. (Basically every second zero.) This works equally well replacing the exponentials with $1/x^2$.