$A \times B$ is an r.e.(recursively enumerable) set, I want to show that $A$ (or $B$) is r.e. ($A$ and $B$ are nonempty)
I need to find a formula. I've got an idea that I should use the symbolic definition of an r.e. set. That is, writing a formula for the function that specifies $A$ or $B$, assuming a formula exists for $A \times B$. I guess I must use Gödel number somewhere.
I should've mentioned that I asked this question over there (Computer Science) but since I am more interested in mathematical arguments and looking for formulas, I'd ask it here as well.
If $A\times B$ is recursively enumerable then there exists a bounded formula $\varphi(x,y,z)$ such that $\langle a,b\rangle\in A\times B$ if and only if $\exists z\varphi(a,b,z)$ is true.
Then we have that $a\in A$ if and only if $\exists b\exists z\varphi(a,b,z)$.
Therefore $A$ is definable by a $\Sigma_1$ formula, and therefore recursively enumerable.