Let $a_1, a_2,..., a_{2n} \geq 1$ be $2n$ distinct positive integers such that at least two of them are even. Show that the polynomial $$(X^2-a_1)(X^2-a_2)...(X^2-a_{2n})-1$$ is irreducible over $\mathbb{Z}(X)$.
The approach I've started using to solve this problem: assume $f(X) = g(X)h(X)$ over $\mathbb{Z}$. By Gauss's lemma we may assume that $g,h$ are monic with integral coefficients, and then I'm comparing the degree of both polynomials to try an get a contradiction of the assumption. Can someone give me a few more hints as to how to arrive at such a contradiction?
Write $f(X)=g_1(X)g_2(X)\cdots g_m(X)$ with $g_i$ monic and irreducible. Note that $f(-X)=f(X)$. Hence, if $g(X)$ is an irreducible factor of $f(X)$, then so is $g(-X)$. Thus $g(X)\mapsto g(-X)$ induces an involutory permutation $\sigma\in S_m$ such that $g_i(-X)= g_{\sigma i}(X)$. If $\sigma i\ne i$, then these two contribute $g_i(0)g_{\sigma i}(0)=g_i(0)^2\equiv 1\pmod 4$ to $f(0)$. As $f(0)=a_1\cdots a_{2n}-1\equiv 3\pmod 4$, there must be at least one $g_j$ that is not paired, i.e., that is a fixpoint under $\sigma$, i.e., $g_j(-X)=g_j(X)$. Equivalently $g_j(X)=h(X^2)$ for some $h\in\Bbb Z[X]$. Note that $|h(a_1)|=|h(a_2)|=\ldots=|h(a_{2n})|=1$, hence at least one of $h(X)+1$, $h(X)-1$ has $n$ distinct (positive integer) roots. It follows that $\deg h\ge n$ and $\deg g_j\ge 2n$. By the same reasoning, $g_i(X)g_{\sigma i}(X)$ has degree $\ge 2n$ when $i$ is not a fixpoint. As $\deg f=4n$, the only possibilities are
However, in the latter case, $h_1(a_i)h_2(a_i)=f(\sqrt{a_i})=-1$ so that $h_2(a_i)=-h_1(a_i)$ at $2n$ distinct places. It follows that $h_2(X)=-h_1(X)$, contradicting them both being monic.