Prove that the given polynomial is irreducible in $\mathbb{Z}[X]$.

Show that if $p$ is a prime and $\gcd(n_1,...,n_p)=d$, then $$\dfrac{(\sum_{k=1}^px^{n_k})-p}{x^d-1}$$ is irreducible in $\mathbb{Z}[X]$.

All I can do is to write the numerator as $\sum(x^{n_k}-1)$ to prove it is really in $\mathbb{Z}[X]$ by doing the factorization, but I have no idea in this example how to use that "p is prime" after the factorization. Would someone give me a hint?


Step 1: Let $g(x)=\dfrac{\sum_{k=1}^p(x^{n_k}-1)}{x^d-1}$

Consider $g(x+1)$ .

Step 2: Using $d=\gcd(n_1,n_2,\ldots ,n_k)$ show that $h(x)=g(x+1)$ is a polynomial over $\Bbb Z$.

Step 3: Apply Eisenstein Criterion on $h(x+d)$ using prime $p$ to show it is irreducible.

Then $h(x+d)=g(x+d+1)$.

Step 4: Use $g(x) $ is irreducible $\iff g(x+k)$ is irreducible for any $k\in \Bbb N$.


Here I post a "delicate" answer I've found:

Consider this polynomial in $\mathbb{C}$. It's not hard to show that all roots have norm $>1$. But in $\mathbb{Z}[X]$, if we could decompose it as the product of 2, the constant term of each should $>1$, which is impossible, as $p$ is prime...